Transductive vs Inductive Learning in GNNs - davidlabee/Graph4Air GitHub Wiki

Understanding the distinction between transductive and inductive learning is essential when designing experiments and evaluating generalization strategies in Graph Neural Networks (GNNs).


Learning Paradigms

Term Description
Transductive Learning The GNN has access to the entire graph structure (nodes and edges) during training. It uses labels from a subset of nodes and predicts the labels of the remaining (unlabeled) nodes within the same graph.
Inductive Learning The GNN is trained on one or more graphs and is evaluated on completely unseen graphs or subgraphs. Neither test nodes nor their edges are visible during training.

Masking Strategies in Transductive Learning

In transductive setups, masking strategies are used to avoid information leakage from test nodes during training. The following table outlines common approaches:

Masking Strategy What It Does Purpose
Target Masking Only Loss is computed only on nodes included in the training mask. Prevents label leakage, but does not stop test node information from leaking through message passing.
Feature Masking of Test Nodes Test node features are set to zero or a neutral value during training. Prevents test nodes from contributing meaningful information to neighboring training nodes.

Interpolation Scenario

When the goal is purely interpolation — that is, predicting missing labels within a single known graph — applying only target masking is a commonly accepted and practical approach. However, it is important to acknowledge that this setup allows for some degree of information flow from test nodes to training nodes through shared edges. Such leakage is acceptable only if the objective is not to measure out-of-sample generalization, but rather to leverage all available structure and features to fill in missing values within the same graph.

⚠️ **GitHub.com Fallback** ⚠️