90e643c7a3727afef2caf932281e6ae91d62aac5,examples/cluster_gcn_ppi.py,Net,forward,#Net#Any#Any#,36

Before Change


        self.lin3 = torch.nn.Linear(4 * 256, train_dataset.num_classes)

    def forward(self, x, edge_index):
        x = F.elu(self.conv1(x, edge_index) + self.lin1(x))
        x = F.elu(self.conv2(x, edge_index) + self.lin2(x))
        x = self.conv3(x, edge_index) + self.lin3(x)
        return x

After Change


        self.convs.append(SAGEConv(hidden_channels, out_channels))

    def forward(self, x, edge_index):
        for conv, batch_norm in zip(self.convs[:-1], self.batch_norms):
            x = conv(x, edge_index)
            x = batch_norm(x)
            x = F.relu(x)
            x = F.dropout(x, p=0.2, training=self.training)
        return self.convs[-1](x, edge_index)


device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
model = Net(in_channels=train_dataset.num_features, hidden_channels=1024,
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: rusty1s/pytorch_geometric
Commit Name: 90e643c7a3727afef2caf932281e6ae91d62aac5
Time: 2020-06-07
Author: matthias.fey@tu-dortmund.de
File Name: examples/cluster_gcn_ppi.py
Class Name: Net
Method Name: forward


Project Name: rusty1s/pytorch_geometric
Commit Name: f4622e59a087d04bc0628b52c33f0cc9f296223e
Time: 2020-12-24
Author: matthias.fey@tu-dortmund.de
File Name: examples/film.py
Class Name: Net
Method Name: forward


Project Name: rusty1s/pytorch_geometric
Commit Name: e7512f6bd434ef89296298a8bd16044917d7ce68
Time: 2020-09-23
Author: matthias.fey@tu-dortmund.de
File Name: examples/gcn2.py
Class Name: Net
Method Name: forward