Effective Structural Encodings via Local Curvature Profiles

Lukas Fesser, Melanie Weber

TL;DR

This paper introduces Local Curvature Profiles (LCP), a novel structural encoding for Graph Neural Networks (GNNs) based on discrete Ricci curvature. By endowing nodes with summary statistics of their local geometric neighborhood, LCP provably increases GNN expressivity beyond the standard Weisfeiler-Lehman test and significantly outperforms existing encoding and graph-rewiring techniques across various benchmarks.

What Problem Does This Paper Address?

Graph Neural Networks (GNNs) are the workhorse of graph machine learning, but they have two major "Achilles' heels." First is representational power: standard message-passing GNNs cannot distinguish between certain non-isomorphic graphs (a limit known as the 1-WL test). Second are the twin demons of over-smoothing (features becoming indistinguishable in deep networks) and over-squashing (information bottlenecks in long-range dependencies).

Researchers often use Positional Encodings (PE)—which tell a node where it is in the graph—and Structural Encodings (SE)—which describe what the node's neighborhood looks like—to fix these issues. However, we still don't know which structural properties are the most effective to encode. This paper argues that geometry, specifically discrete curvature, is the missing piece of the puzzle.

Methods

The authors propose Local Curvature Profiles (LCP). The core idea is to use Ollivier-Ricci Curvature (ORC), a concept from discrete geometry that measures how "well-connected" neighborhoods are by looking at the optimal transport cost between them.

Figure 1: Computing ORC.

Instead of just using curvature to prune or add edges (a common technique called "rewiring"), LCP treats it as a feature. For every node, the authors calculate the ORC for all incident edges and create a 5-dimensional feature vector containing the min, max, mean, standard deviation, and median of those curvatures. This LCP is then concatenated with the node's original features.

The authors compare LCP against several standard approaches, as summarized in their overview table:

Comparison of LCP with other popular positional and structural encodings.

Datasets

The authors evaluated their method on a wide range of standard benchmarks:

  • Graph Classification: Enzymes, IMDB-Binary, Mutag, and Proteins.
  • Node Classification: Cora, Citeseer, Cornell, Texas, and Wisconsin.
  • Long-Range Benchmarks: Peptides-func and Peptides-struct from the Long-Range Graph Benchmark (LRGB).

Key Insights and Ideas

  • Geometric Expressivity: The authors prove that LCP makes GNNs strictly more expressive than the 1-WL test. A classic example is the Rooke and Shrikhande graphs—two graphs that look identical to standard GNNs but have different local curvatures. LCP allows a GNN to tell them apart.
LCP distinguishes the Rooke and Shrikhande graphs where standard message-passing fails.
  • Complementarity is Key: One of the most important findings is that Local SE (like LCP) and Global PE (like Laplacian Eigenvectors) are complementary. Combining them yields better results than using either alone, suggesting they capture fundamentally different types of graph information.
  • Encoding > Rewiring: While curvature-based rewiring (like BORF) is popular for fixing bottlenecks, this paper shows that using curvature as a feature (LCP) actually leads to higher accuracy.
  • Depth Support: LCP helps mitigate over-smoothing, allowing GCNs to maintain better performance as the number of layers increases compared to standard models.

Key Results

  • Graph Classification Dominance: LCP outperformed all other encoding methods on every graph classification dataset tested. For GCN and GAT architectures, LCP increased mean accuracy by 10% to 20% compared to using no encodings.
  • State-of-the-Art Combinations: In 14 out of 18 tested scenarios, combining LCP with Random Walk positional encodings led to the highest overall accuracy.
  • Efficiency vs. Accuracy: While ORC is computationally expensive ($O(|E|d_{max}^3)$), the authors show that cheaper geometric approximations like Forman-Ricci Curvature still provide significant boosts, offering a scalable alternative for massive graphs.

Limitations and Future Work

Despite its success, the authors note that the exact relationship between LCP and the higher-order $k$-WL hierarchy remains an open theoretical question. Additionally, the effectiveness of LCP varies across different GNN architectures, suggesting that the "optimal" way to integrate geometric information might be architecture-dependent. Future work could involve a more granular analysis of how graph topology (e.g., sparsity vs. density) dictates which specific curvature notion works best.

Summary updated

Abstract

Structural and Positional Encodings can significantly improve the performance of Graph Neural Networks in downstream tasks. Recent literature has begun to systematically investigate differences in the structural properties that these approaches encode, as well as performance trade-offs between them. However, the question of which structural properties yield the most effective encoding remains open. In this paper, we investigate this question from a geometric perspective. We propose a novel structural encoding based on discrete Ricci curvature (Local Curvature Profiles, short LCP) and show that it significantly outperforms existing encoding approaches. We further show that combining local structural encodings, such as LCP, with global positional encodings improves downstream performance, suggesting that they capture complementary geometric information. Finally, we compare different encoding types with (curvature-based) rewiring techniques. Rewiring has recently received a surge of interest due to its ability to improve the performance of Graph Neural Networks by mitigating over-smoothing and over-squashing effects. Our results suggest that utilizing curvature information for structural encodings delivers significantly larger performance increases than rewiring.
BibTeX
@inproceedings{fesser2024effective,
  author = {Lukas Fesser and Melanie Weber},
  title = {{Effective Structural Encodings via Local Curvature Profiles}},
  booktitle = {International Conference on Learning Representations},
  year = {2024},
  url = {https://openreview.net/forum?id=GIUjLsDP4Z},
}
Figure