caf9f875d5e2abd044e7fc286f837ef40a484e82,train.py,,main,#,275

Before Change



    // Load train and validate data.
    print("Loading train and validate data from "%s"" % opt.data)
    train = torch.load(opt.data + ".train.pt")
    valid = torch.load(opt.data + ".valid.pt")
    print(" * number of training sentences: %d" % len(train))
    print(" * maximum batch size: %d" % opt.batch_size)

    // Load checkpoint if we resume from a previous training.
    if opt.train_from:

After Change



    // Load train and validate data.
    train_dataset = load_dataset("train")
    valid_dataset = load_dataset("valid")
    print(" * maximum batch size: %d" % opt.batch_size)

    // Load checkpoint if we resume from a previous training.
    if opt.train_from:
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: OpenNMT/OpenNMT-py
Commit Name: caf9f875d5e2abd044e7fc286f837ef40a484e82
Time: 2017-12-21
Author: nasa4836@gmail.com
File Name: train.py
Class Name:
Method Name: main


Project Name: elbayadm/attn2d
Commit Name: ff68a9ef501e7286501dba1719024dfaaab4b473
Time: 2018-06-15
Author: myleott@fb.com
File Name: eval_lm.py
Class Name:
Method Name: main