liveBook · Manning

Jumping knowledge network

As explained in Graph Neural Networks in Action

A jumping knowledge network is a graph neural network architecture that combines representations produced at multiple layers to capture information from different neighborhood ranges.

A jumping knowledge network (JK-Net) combines representations from multiple graph-convolution layers so each node can use information from different neighborhood ranges. This is useful when graph structure varies across regions: some nodes benefit from nearby context, while others need deeper neighborhoods. section 3.2.2

Standard neighborhood aggregation applies a layer’s aggregation behavior throughout the model. JK instead retains outputs from several layers and combines them after message passing, allowing the final representation to reflect node- and subgraph-specific context. section 3.2 section 3.2.2

Choose the combination mode according to the representation and dimensionality trade-offs:

  • cat concatenates all layer outputs along the feature dimension, preserving information from every layer while increasing output dimensionality. section 3.2.2
  • max pools across layer outputs, selecting the largest value for each feature and reducing the influence of less informative signals. section 3.2.2
  • lstm uses a bidirectional LSTM to learn attention scores over the layer outputs. section 3.2.2

Adding JK to a PyG GCN

Create two GCNConv layers, store each layer output in a list, and pass that list to JumpingKnowledge(mode='cat'). In the demonstrated flow, the first output is activated with ReLU, both outputs are retained, and the combined representation is returned. section 3.2.2

JK is a flexible aggregation strategy rather than a guaranteed improvement. In the reported GCN comparison, JK achieved a lower F1 score than the baseline but a slightly lower log loss, illustrating that evaluation metrics can disagree. section 3.2.2

How Graph Neural Networks in Action covers it

How deep it goes
Explains three layer-combination modes and demonstrates a PyG GCN implementation, without deriving their underlying optimization.
Examples
Uses a two-layer PyG GCN example and compares baseline GCN with JK-enhanced GCN classification metrics.
What it assumes
Assumes familiarity with graph convolution and neighborhood aggregation while illustrating the layer-output collection procedure.
What you can do after
Apply it via PyTorch Geometric by collecting intermediate layer outputs and selecting a JumpingKnowledge aggregation mode.
How it connects
Connects jumping knowledge to GCNs, GraphSAGE, neighborhood aggregation, and node representation learning.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Graph Neural Networks in Action. The section links point to the parts of the book it draws on.