Self-supervised Graph-level Representation Learning with Local and Global Structure

Minghao Xu, Hang Wang, Bingbing Ni, Hongyu Guo, Jian Tang

Graph Neural Networks (GNNs) have revolutionized how we analyze complex, structured data like molecular structures and social networks. However, training these models typically requires massive amounts of labeled data. In scientific fields such as drug discovery, obtaining these labels is incredibly expensive and time-consuming.

Self-supervised learning (SSL) offers a compelling solution by allowing models to learn from unlabeled data. Yet, most existing graph SSL methods focus exclusively on local structure. They train the AI to ensure that a graph and a slightly modified version of itself end up close together in the model's internal map (the "latent space"). What these methods miss is the global semantic structure. In the real world, molecules aren't just random variations of one another; they belong to broader functional families and hierarchical categories. If an AI doesn't understand these broader "neighborhoods" of data, its representations won't be as effective for complex downstream tasks.

To address this gap, researchers have introduced GraphLoG (Local-instance and Global-semantic Learning), a new self-supervised framework that learns graph representations by capturing both local instance-level similarities and global hierarchical semantic structures.

The GraphLoG Framework: Local and Global Learning

GraphLoG operates through a powerful dual-objective approach that bridges the micro and macro structures of graph data.

1. Local-instance Learning

This component uses a standard "contrastive" approach. It forces the model to recognize that a graph and its augmented counterpart (for example, a molecule with a few atoms masked or edges dropped) are fundamentally the same "instance."

Local-instance structure

2. Global-semantic Learning

This is GraphLoG's core innovation. The model maintains hierarchical prototypes—essentially cluster centers at different levels of abstraction. Think of this as a taxonomic tree where the model learns to group similar graphs into "species," "genera," and "families."

Global-semantic structure

To make this global learning work at scale, the authors developed an efficient online Expectation-Maximization (EM) algorithm:

  • E-step: For a small batch of graphs, the model estimates which "prototypes" (clusters) they belong to.
  • M-step: The model updates both the GNN parameters and the prototypes themselves to better fit the underlying data distribution.

Because this process is "online," it doesn't need to process the entire dataset of millions of graphs simultaneously, making it highly computationally efficient.

Datasets and Key Results

The model was rigorously evaluated using a "pre-train then fine-tune" strategy across two major scientific domains:

  • Chemistry Domain: GraphLoG was pre-trained on 2 million unlabeled molecules from the ZINC15 database. It was then fine-tuned on 8 benchmarks from MoleculeNet (e.g., predicting blood-brain barrier penetration or viral inhibition). GraphLoG achieved state-of-the-art performance, outperforming previous self-supervised methods on 6 out of 8 tasks and securing a 2.1% average performance gain (ROC-AUC).
  • Biology Domain: Pre-trained on 395,000 protein ego-networks, the model was evaluated on its ability to predict 40 fine-grained biological functions across 8 different species, achieving a 1.7% average performance gain.

Importantly, GraphLoG is architecture-agnostic. While the authors primarily used the Graph Isomorphism Network (GIN), they demonstrated that GraphLoG improves performance across various GNN architectures, including GCN, GraphSAGE, and GAT.

Key Insights

  • Hierarchy Matters: Real-world data is often hierarchical (like the ATC classification system for drugs). By explicitly modeling this hierarchy with prototypes, GraphLoG creates a latent space that more accurately reflects reality.
  • Local + Global = Synergy: The local and global objectives are highly complementary. The local objective ensures the latent space is "smooth" (similar things are mapped closely), while the global objective ensures it is "structured" (meaningful groups are distinctly separated).
  • Scalable Discovery: The online EM approach allows the model to "discover" the semantic categories of a dataset without any human labels, even when the dataset contains millions of examples.

Limitations and Future Work

While highly effective, GraphLoG has a few areas for future refinement. The depth of the hierarchy and the number of clusters are currently hyperparameters that must be set manually. Additionally, the authors suggest that future work could involve better unifying the pre-training and fine-tuning phases to make the transition even more seamless.

Beyond chemistry and biology, the GraphLoG framework holds immense promise for other fields reliant on complex network data, such as sociology, physics, and material science.

Summary updated

BibTeX
@inproceedings{xu2021self,
  author = {Minghao Xu and Hang Wang and Bingbing Ni and Hongyu Guo and Jian Tang},
  title = {{Self-supervised Graph-level Representation Learning with Local and Global Structure}},
  booktitle = {International Conference on Machine Learning},
  year = {2021},
}
Figure