4e43734dd0b7f1c026069af64151a8f52f41060d,torch_geometric/nn/conv/gat_conv.py,GATConv,forward,#GATConv#Any#Any#,86
Before Change
edge_index, _ = add_self_loops(edge_index, num_nodes=x.size(0))
x = torch.mm(x, self.weight).view(-1, self.heads, self.out_channels)
return self.propagate(edge_index, x=x, num_nodes=x.size(0))
def message(self, edge_index_i, x_i, x_j, num_nodes):
// Compute attention coefficients.
alpha = (torch.cat([x_i, x_j], dim=-1) * self.att).sum(dim=-1)
After Change
\right)\right)}
{\sum_{k \in \mathcal{N}(i) \cup \{ i \}}
\exp\left(\mathrm{LeakyReLU}\left(\mathbf{a}^{\top}
[\mathbf{\Theta}\mathbf{x}_i \, \Vert \, \mathbf{\Theta}\mathbf{x}_k]
\right)\right)}.
Args:
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances
Project Name: rusty1s/pytorch_geometric
Commit Name: 4e43734dd0b7f1c026069af64151a8f52f41060d
Time: 2019-07-03
Author: matthias.fey@tu-dortmund.de
File Name: torch_geometric/nn/conv/gat_conv.py
Class Name: GATConv
Method Name: forward
Project Name: rusty1s/pytorch_geometric
Commit Name: 6503eb6ed7e37b65aabf0dd7bcc23e7bbb293dd7
Time: 2019-07-29
Author: matthias.fey@tu-dortmund.de
File Name: torch_geometric/nn/conv/tag_conv.py
Class Name: TAGConv
Method Name: forward
Project Name: rusty1s/pytorch_geometric
Commit Name: 14fb6e1972270849d06f9eaad7aa9ec158d6308f
Time: 2020-07-01
Author: matthias.fey@tu-dortmund.de
File Name: torch_geometric/nn/conv/pna_conv.py
Class Name: PNAConv
Method Name: forward