NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Hierarchical Graph Capsule Network

Jinyu Yang, Peilin Zhao, Yu Rong, Chaochao Yan, Chunyuan Li, Hehuan Ma, Junzhou Huang

Abstract

Hierarchical Graph Capsule Network (HGCN) is a novel framework designed to capture the "part-whole" relationships in graph-structured data. By disentangling node features into multiple latent capsules and employing structure-aware Transformation GNNs (TGNNs) for hierarchical routing, HGCN overcomes the limitations of traditional graph pooling methods. Evaluated across 11 biological and social benchmarks, HGCN achieves state-of-the-art performance, demonstrating superior ability in modeling complex hierarchical structures.

Introduction

While standard Graph Neural Networks (GNNs) excel at modeling local node neighborhoods, they often struggle to capture the hierarchical structure inherent in many real-world graphs—such as atoms forming functional groups in molecules or individuals forming specific communities in social networks. Existing solutions typically rely on graph pooling, which often suffers from two major gaps: feature entanglement and the failure to model complex "part-whole" relationships where the orientation or properties of a sub-part determine the identity of the larger structure.

Methods

The Hierarchical Graph Capsule Network (HGCN) introduces three main innovations to address these challenges:

  1. Disentangled Graph Capsules: Each node is represented by $K$ independent capsules rather than a single large embedding. Each capsule captures a specific latent factor. A "squash" function ensures the capsule vector's length represents the probability of a feature's existence.
  2. Transformation GNNs (TGNNs) for Voting: Unlike traditional Capsule Networks that use simple transformation matrices, HGCN uses TGNNs. This allows the model to consider local structure when deciding how "parts" contribute to the "whole," improving accuracy and memory efficiency.
  3. Iterative Routing-by-Agreement: A dynamic routing mechanism assigns lower-level capsules to higher-level ones based on the alignment of their "votes."
  4. Auxiliary Graph Reconstruction: A decoder attempts to reconstruct the original adjacency matrix from learned capsules, serving as a regularizer to maintain spatial awareness.
Overview of the HGCN architecture showing the disentanglement process, TGNN-based voting, and hierarchical routing.

Results

HGCN was evaluated on 11 benchmarks, including biological graphs (e.g., MUTAG, PROTEINS, ENZYMES) and social graphs (e.g., COLLAB, IMDB). The model consistently outperformed traditional GNNs (GCN, GIN) and previous graph capsule attempts (CapsGNN, GCAPS-CNN).

Notably, on the complex ENZYMES dataset, HGCN improved accuracy by 16.17% over previous capsule-based methods. Ablation studies confirmed that both the disentanglement and reconstruction components are critical for performance.

Performance comparison of HGCN against kernel-based and GNN-based methods on biological datasets.

Conclusion

HGCN successfully integrates the "part-whole" reasoning of Capsule Networks into the GNN paradigm. By using structure-aware voting and feature disentanglement, it provides a robust framework for hierarchical graph classification. While the iterative routing process adds computational complexity, the gains in accuracy on complex topological structures make it a significant advancement in the field. Future work may explore more sophisticated disentanglement and scaling to even larger graphs.

Summary updated

BibTeX
@inproceedings{yang2021hierarchical,
  author = {Jinyu Yang and Peilin Zhao and Yu Rong and Chaochao Yan and Chunyuan Li and Hehuan Ma and Junzhou Huang},
  title = {{Hierarchical Graph Capsule Network}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2021},
  doi = {10.1609/aaai.v35i12.17268},
}
Figure