Package sentence :: Module coupleddataset :: Class CoupledDataSet
[hide private]
[frames] | no frames]

Class CoupledDataSet

source code

     object --+    
              |    
dataset.DataSet --+
                  |
                 CoupledDataSet
Known Subclasses:

A coupled data set contains all possible couples of parallel sentences of a simple dataset

Instance Methods [hide private]
 
__init__(self, **kwargs)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
DataSet
get_single_set(self, critical_attribute=None)
Reconstructs the original data set, with only one sentence per entry.
source code
DataSet
get_single_set_with_soft_ranks(self, attribute1='', attribute2='', critical_attribute='rank_soft_predicted')
Reconstructs the original data set, with only one sentence per entry.
source code
DataSet
get_single_set_with_hard_ranks(self, critical_attribute=None)
Reconstructs the original data set, with only one sentence per entry.
source code
 
get_nested_attribute_names(self) source code

Inherited from dataset.DataSet: __eq__, __iter__, add_attribute_vector, append_dataset, clone, compare, confirm_attributes, ensure_judgment_ids, get_all_attribute_names, get_annotations, get_attribute_names, get_discrete_attribute_values, get_head_sentences, get_multisource_strings, get_parallelsentences, get_parallelsentences_per_sentence_id, get_parallelsentences_with_judgment_ids, get_singlesource_strings, get_size, get_tail_sentences, get_target_strings, get_translations_count_vector, import_target_attributes_onsystem, merge_dataset, merge_dataset_symmetrical, merge_references_symmetrical, modify_singlesource_strings, modify_target_strings, remove_ties, select_attribute_names, split, write_singlesource_strings_file

Inherited from dataset.DataSet (private): _retrieve_attribute_names

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Instance Variables [hide private]
[ParallelSentence, ...] parallelsentences
a list of the contained parallel sentence instances

Inherited from dataset.DataSet: attribute_names, attribute_names_found

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, **kwargs)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Parameters:
  • parallelsentence_list - the parallelsentences to be wrapped in the dataset
  • attributes_list - if the names of the attributes for the parallelsentences are known, they can be given here, in order to avoid extra processing. Otherwise they will be computed when needed. @type [str, ...]
  • annotations - Not implemented @type list
  • existing_item (DataSet or [CoupledParallelSentence, ...])
Overrides: object.__init__

get_single_set(self, critical_attribute=None)

source code 

Reconstructs the original data set, with only one sentence per entry.

Returns: DataSet
Simple dataset that contains the simplified parallel sentences

get_single_set_with_soft_ranks(self, attribute1='', attribute2='', critical_attribute='rank_soft_predicted')

source code 

Reconstructs the original data set, with only one sentence per entry.

Returns: DataSet
Simple dataset that contains the simplified parallel sentences

get_single_set_with_hard_ranks(self, critical_attribute=None)

source code 

Reconstructs the original data set, with only one sentence per entry.

Returns: DataSet
Simple dataset that contains the simplified parallel sentences

get_nested_attribute_names(self)

source code 
Overrides: dataset.DataSet.get_nested_attribute_names