The Weisfeiler–Lehman (WL) test is a classical graph-comparison procedure that iteratively refines node labels from neighborhood information. It provides a useful yardstick for graph neural network expressiveness: GIN can distinguish every pair of graphs that the WL test can distinguish. section 11.5.4
In graph neural networks for drug-target affinity prediction:
- GIN uses sum aggregation, a learnable ε parameter for balancing a node's own features against neighbor features, and an MLP for nonlinear transformation. section 11.5.4
- GIN is theoretically more expressive than GCN and GAT, although greater expressiveness can overfit limited training data. section 11.5.4
mol_nn1 = nn.Sequential(
nn.Linear(num_features_mol, num_features_mol),
nn.ReLU(),
nn.Linear(num_features_mol, num_features_mol)
)
self.mol_conv1 = GINConv(mol_nn1)A compact PyTorch Geometric pattern shows how an MLP is wrapped in GINConv to implement a WL-aligned graph layer. section 11.5.4
