7633129ba8d5f0e28bd6b6d6027b14352482ef31,fairseq/data/token_block_dataset.py,TokenBlockDataset,prefetch,#TokenBlockDataset#Any#,104

Before Change


        return len(self.slice_indices)

    def prefetch(self, indices):
        indices.sort()
        total_size = 0
        for idx in indices:
            s, e = self.slice_indices[idx]
            total_size += e - s

After Change


            ds_idx
            for index in indices
            for start_ds_idx, _, end_ds_idx in [self.block_to_dataset_index[index]]
            for ds_idx in range(start_ds_idx, end_ds_idx + 1)
        })
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 3

Instances


Project Name: elbayadm/attn2d
Commit Name: 7633129ba8d5f0e28bd6b6d6027b14352482ef31
Time: 2019-01-04
Author: myleott@fb.com
File Name: fairseq/data/token_block_dataset.py
Class Name: TokenBlockDataset
Method Name: prefetch


Project Name: nipy/dipy
Commit Name: 1515fa64e1c94bca111980ed71b0423b891c5189
Time: 2015-11-13
Author: garyfallidis@gmail.com
File Name: dipy/reconst/dsi.py
Class Name:
Method Name: create_qtable


Project Name: biolab/orange3
Commit Name: 398bcc6b3332753cedba2b9bdeb4393ce9341b9c
Time: 2013-02-13
Author: janez.demsar@fri.uni-lj.si
File Name: Orange/widgets/visualize/owboxplot.py
Class Name: OWBoxPlot
Method Name: sorting_update