01b293b84fd2b1eeb80a01afe44d341d9c9c6486,torch_geometric/sparse/sparse.py,,SparseTensor,#Any#Any#Any#,5
Before Change
def SparseTensor(indices, values, size):
if values.is_cuda:
A = getattr(cuda_sparse, values.__class__.__name__)
else:
A = getattr(sparse, values.__class__.__name__)
return A(indices, values, size)
After Change
A = getattr(cuda_sparse, values.type().split(".")[-1])
else:
print(values)
A = getattr(sparse, values.type().split(".")[-1])
return A(indices, values, size)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances
Project Name: rusty1s/pytorch_geometric
Commit Name: 01b293b84fd2b1eeb80a01afe44d341d9c9c6486
Time: 2018-04-29
Author: matthias.fey@tu-dortmund.de
File Name: torch_geometric/sparse/sparse.py
Class Name:
Method Name: SparseTensor
Project Name: scipy/scipy
Commit Name: 17b6f7b145780fc0cd973a9436a81f9b5fe43e35
Time: 2015-05-07
Author: archibald@astron.nl
File Name: tools/refguide_check.py
Class Name:
Method Name: main
Project Name: facebookresearch/pytext
Commit Name: 4cc3e86337eb28ff8987dbfcaba38816451502b9
Time: 2019-04-30
Author: egaudet@fb.com
File Name: pytext/config/serialize.py
Class Name:
Method Name: config_from_json