7b205efea6b504de04311bc55d109cd28d8f3e0c,OpenNMT/preprocess.py,,main,#,227

Before Change




    print("Saving data to \"" + opt.save_data + "-train.t7\"...")
    torch.save(opt.save_data + "-train.t7",
               {"dicts": dicts,
                "train": train,
                "valid": valid})


if __name__ == "__main__":
    main()

After Change


        saveVocabulary("target", dicts["tgt"]["words"], opt.save_data + ".tgt.dict")

    if opt.features_vocabs_prefix is None:
        saveFeaturesVocabularies("source", dicts["src"]["features"], opt.save_data)
        saveFeaturesVocabularies("target", dicts["tgt"]["features"], opt.save_data)

Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 2

Instances


Project Name: OpenNMT/OpenNMT-py
Commit Name: 7b205efea6b504de04311bc55d109cd28d8f3e0c
Time: 2016-12-21
Author: alerer@fb.com
File Name: OpenNMT/preprocess.py
Class Name:
Method Name: main


Project Name: maciejkula/spotlight
Commit Name: bc51dbc0c56f68ed30857755026633f78eef1ae8
Time: 2017-08-20
Author: maciej.kula@gmail.com
File Name: examples/bloom_embeddings/example.py
Class Name:
Method Name: run


Project Name: tensorlayer/tensorlayer
Commit Name: 5307ae3f7d1c4b6bd2285f946db82d944f3844db
Time: 2019-02-19
Author: jingqing.zhang15@imperial.ac.uk
File Name: examples/text_classification/tutorial_imdb_fasttext.py
Class Name:
Method Name: train_test_and_save_model