Module Import alias Import alias Import alias Import alias Import alias ImportFrom alias ImportFrom alias FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Return Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad decorator_list Expr Call AttributeLoad NameLoad attr Str NameLoad ClassDef bases AttributeLoad NameLoad attr body FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str With Call NameLoad NameLoad Str NameStore body Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str decorator_list FunctionDef arguments args NameParam defaults body If BoolOpAnd Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad SubscriptLoad SubscriptLoad SubscriptLoad AttributeLoad NameLoad attr Index Str Index Str Index Num Assign NameStore Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr CompareIn Str NameLoad Expr Call AttributeLoad NameLoad attr CompareIn Str NameLoad Expr Call AttributeLoad NameLoad attr CompareIn Str NameLoad Expr Call AttributeLoad NameLoad attr CompareEq Call NameLoad SubscriptLoad NameLoad Index Str Call NameLoad SubscriptLoad NameLoad Index Str Expr Call AttributeLoad NameLoad attr CompareEq Call NameLoad SubscriptLoad NameLoad Index Str Call NameLoad SubscriptLoad NameLoad Index Str decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr CompareIn Str NameLoad Expr Call AttributeLoad NameLoad attr CompareIn Str NameLoad Expr Call AttributeLoad NameLoad attr CompareIn Str NameLoad Expr Call AttributeLoad NameLoad attr CompareEq Call NameLoad SubscriptLoad NameLoad Index Str Call NameLoad SubscriptLoad NameLoad Index Str Expr Call AttributeLoad NameLoad attr CompareEq Call NameLoad SubscriptLoad NameLoad Index Str Call NameLoad SubscriptLoad NameLoad Index Str decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword NameLoad Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr BoolOpAnd Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr BoolOpAnd Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr BoolOpAnd Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr BoolOpAnd Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list decorator_list If CompareEq NameLoad Str body Expr Call AttributeLoad NameLoad attr
N/A N/A unittest N/A yaml N/A os N/A shutil N/A marmot marmot.representations.wmt_representation_generator WMTRepresentationGenerator marmot.experiment.import_utils build_object join_with_module_path N/A N/A loader node N/A N/A N/A  define custom tag handler to join paths with the path of the marmot module  N/A module_path N/A N/A N/A os path dirname N/A N/A N/A marmot representations tests __file__ N/A resolved N/A N/A loader construct_scalar node N/A N/A N/A N/A os path join module_path resolved N/A N/A N/A N/A yaml add_constructor !join join_with_module_path WMTRepresentationGeneratorTests N/A N/A unittest TestCase N/A setUp N/A N/A self N/A N/A N/A module_path N/A N/A N/A os path dirname __file__ N/A N/A self module_path module_path N/A test_config N/A N/A N/A os path join module_path test_config.yaml N/A N/A open test_config r cfg_file N/A N/A N/A self config N/A N/A yaml load N/A N/A cfg_file read N/A N/A self wmt_target N/A N/A N/A os path join module_path test_data/EN_ES.tgt_ann.train N/A N/A self wmt_source N/A N/A N/A os path join module_path test_data/EN_ES.source.train N/A N/A self tmp_dir N/A N/A N/A os path join module_path tmp_dir N/A tearDown N/A N/A self N/A N/A N/A N/A N/A N/A N/A os path exists N/A self tmp_dir N/A N/A N/A os path isdir N/A self tmp_dir N/A N/A N/A N/A shutil rmtree N/A self tmp_dir N/A test_load_from_config N/A N/A self N/A N/A N/A generator N/A build_object N/A N/A N/A N/A self config N/A representations N/A training N/A 0 N/A data_obj N/A N/A generator generate N/A N/A N/A self assertTrue N/A target data_obj N/A N/A N/A self assertTrue N/A source data_obj N/A N/A N/A self assertTrue N/A tags data_obj N/A N/A N/A self assertTrue N/A N/A len N/A data_obj N/A target N/A len N/A data_obj N/A source N/A N/A N/A self assertTrue N/A N/A len N/A data_obj N/A target N/A len N/A data_obj N/A tags N/A test_no_saved_files N/A N/A self N/A N/A N/A generator N/A WMTRepresentationGenerator N/A self wmt_target N/A self wmt_source N/A data_obj N/A N/A generator generate N/A N/A N/A self assertTrue N/A target data_obj N/A N/A N/A self assertTrue N/A source data_obj N/A N/A N/A self assertTrue N/A tags data_obj N/A N/A N/A self assertTrue N/A N/A len N/A data_obj N/A target N/A len N/A data_obj N/A source N/A N/A N/A self assertTrue N/A N/A len N/A data_obj N/A target N/A len N/A data_obj N/A tags N/A test_save_files N/A N/A self N/A N/A N/A generator N/A WMTRepresentationGenerator N/A self wmt_target N/A self wmt_source tmp_dir N/A self tmp_dir persist True N/A data_obj N/A N/A generator generate N/A target N/A N/A N/A os path join N/A self tmp_dir EN_ES.tgt_ann.train.target N/A tags N/A N/A N/A os path join N/A self tmp_dir EN_ES.tgt_ann.train.tags N/A source N/A N/A N/A os path join N/A self tmp_dir EN_ES.source.train.txt N/A N/A N/A self assertTrue N/A N/A N/A N/A os path exists N/A self tmp_dir N/A N/A N/A os path isdir N/A self tmp_dir N/A N/A N/A self assertTrue N/A N/A N/A N/A os path exists target N/A N/A N/A os path isfile target N/A N/A N/A self assertTrue N/A N/A N/A N/A os path exists tags N/A N/A N/A os path isfile tags N/A N/A N/A self assertTrue N/A N/A N/A N/A os path exists source N/A N/A N/A os path isfile source N/A N/A N/A N/A __name__ __main__ N/A N/A N/A N/A unittest main