Loading…
Glossary term
A neural network designed to work on data structured as nodes and connections.
A GNN works on data shaped as a graph: nodes joined by edges, like molecules, social networks or road maps. In each layer every node collects information from its neighbors and updates itself.
After a few layers, each node's representation reflects its wider neighborhood.
One round of neighbor averaging
import numpy as np
features = np.array([[1.0], [3.0], [5.0]])
neighbors = {0: [1], 1: [0, 2], 2: [1]}
new = np.array([features[neighbors[i]].mean(axis=0) for i in range(3)])GNNs are used in drug discovery, recommendation, fraud detection and traffic prediction.