653be87728a9420fbd980d0d6024451c892ef721,torch_geometric/nn/glob/sort.py,,global_sort_pool,#Any#Any#Any#,5
Before Change
else:
expand_batch_x = torch.full(size=(B, k, D), fill_value=fill_value)
expand_batch_x[:, :N, :] = batch_x
batch_x = expand_batch_x.contiguous()
batch_x[batch_x == fill_value] = 0
x = batch_x.view(B, k * D)
After Change
batch_x = batch_x[:, :k].contiguous()
else:
expand_batch_x = batch_x.new_full((B, k - N, D), fill_value)
batch_x = torch.cat([batch_x, expand_batch_x], dim=1)
batch_x[batch_x == fill_value] = 0
x = batch_x.view(B, k * D)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances
Project Name: rusty1s/pytorch_geometric
Commit Name: 653be87728a9420fbd980d0d6024451c892ef721
Time: 2019-01-28
Author: matthias.fey@tu-dortmund.de
File Name: torch_geometric/nn/glob/sort.py
Class Name:
Method Name: global_sort_pool
Project Name: OpenNMT/OpenNMT-py
Commit Name: c13a558767cbc19b612968eb4d01a1f26d5df688
Time: 2017-06-10
Author: wangqian5730@gmail.com
File Name: onmt/Models.py
Class Name: NMTModel
Method Name: _fix_enc_hidden
Project Name: osmr/imgclsmob
Commit Name: 57c40574673c3d0d35076234d3e55b46a3be5891
Time: 2018-08-23
Author: osemery@gmail.com
File Name: pytorch/models/nasnet.py
Class Name: BranchSeparablesReduction
Method Name: forward