455a0dc9a98212089a7201a025670c33a1770f67,torch_geometric/nn/functional/spline_gcn_test.py,SplineGcnTest,test_backward,#SplineGcnTest#,92
Before Change
vertices = [[0, 0], [1, 1], [-2, 2], [-3, -3], [4, -4]]
edges = [[0, 0, 0, 0], [1, 2, 3, 4]]
adj = mesh_adj(torch.FloatTensor(vertices), torch.LongTensor(edges))
features = torch.FloatTensor([[1, 2], [3, 4], [5, 6], [7, 8], [9, 10]])
weight = torch.arange(0.5, 0.5 * 25, step=0.5).view(12, 2, 1)
features_in = Variable(features, requires_grad=True)
weight = Variable(weight, requires_grad=True)
features_out = spline_gcn(
adj,
features_in,
weight,
kernel_size=[3, 4],
max_radius=sqrt(16 + 16),
degree=1)
features_out.mean().backward()
print(features_in.grad.size())
After Change
max_radius=sqrt(16 + 16),
degree=1)
test = gradcheck(op, (features, weight), eps=1e-6, atol=1e-4)
self.assertTrue(test)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 10
Instances
Project Name: rusty1s/pytorch_geometric
Commit Name: 455a0dc9a98212089a7201a025670c33a1770f67
Time: 2017-10-23
Author: matthias.fey@tu-dortmund.de
File Name: torch_geometric/nn/functional/spline_gcn_test.py
Class Name: SplineGcnTest
Method Name: test_backward
Project Name: rusty1s/pytorch_geometric
Commit Name: 6627e8f74bc46a294dda7d6b12260883a63f038b
Time: 2018-01-12
Author: matthias.fey@tu-dortmund.de
File Name: torch_geometric/nn/functional/pool/pool_test.py
Class Name: PoolTest
Method Name: test_backward
Project Name: rusty1s/pytorch_geometric
Commit Name: bbf7f4e4b8462c18cad91529dad6d86c3945c776
Time: 2017-10-23
Author: matthias.fey@tu-dortmund.de
File Name: torch_geometric/nn/functional/spline_gcn_test.py
Class Name: SplineGcnTest
Method Name: test_edgewise_spline_gcn_backward