e89329d6657e0dbc35d93f663363141ac2da5cdb,fairseq/sequence_generator.py,SequenceGenerator,generate_batched_itr,#SequenceGenerator#Any#Any#Any#Any#Any#Any#Any#,54

Before Change


            maxlen_b = self.maxlen

        for sample in data_itr:
            s = utils.make_variable(sample, volatile=True, cuda=cuda)
            if "net_input" not in s:
                continue
            input = s["net_input"]
            srclen = input["src_tokens"].size(1)

After Change


            maxlen_b = self.maxlen

        for sample in data_itr:
            s = utils.move_to_cuda(sample) if cuda else sample
            if "net_input" not in s:
                continue
            input = s["net_input"]
            srclen = input["src_tokens"].size(1)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 3

Instances


Project Name: elbayadm/attn2d
Commit Name: e89329d6657e0dbc35d93f663363141ac2da5cdb
Time: 2018-06-15
Author: myleott@fb.com
File Name: fairseq/sequence_generator.py
Class Name: SequenceGenerator
Method Name: generate_batched_itr


Project Name: elbayadm/attn2d
Commit Name: e89329d6657e0dbc35d93f663363141ac2da5cdb
Time: 2018-06-15
Author: myleott@fb.com
File Name: fairseq/sequence_scorer.py
Class Name: SequenceScorer
Method Name: score_batched_itr