Abstract
In graph representation learning, it is important that the complex geometric structure of the input graph, e.g. hidden relations among nodes, is well captured in embedding space. However, standard Euclidean embedding spaces have a limited capacity in representing graphs of varying structures. A promising candidate for the faithful embedding of data with varying structure is product manifolds of component spaces of different geometries (spherical, hyperbolic, or euclidean). In this paper, we take a closer look at the structure of product manifold embedding spaces and argue that each component space in a product contributes differently to expressing structures in the input graph, hence should be weighted accordingly. This is different from previous works which consider the roles of different components equally. We then propose WEIGHTED-PM, a data-driven method for learning embedding of heterogeneous graphs in weighted product manifolds. Our method utilizes the topological information of the input graph to automatically determine the weight of each component in product spaces. Extensive experiments on synthetic and real-world graph datasets demonstrate that WEIGHTED-PM is capable of learning better graph representations with lower geometric distortion from input data, and performs better on multiple downstream tasks, such as word similarity learning, top-$k$ recommendation, and knowledge graph embedding.
Introduction
Standard graph learning models typically map complex relational data into "flat" Euclidean spaces. However, real-world graphs often exhibit non-Euclidean properties: hierarchical structures (like citation networks) resemble trees and expand exponentially, fitting better in hyperbolic space (negative curvature), while cyclical structures (like molecular rings) map more naturally to spherical space (positive curvature).
While "product manifolds"—spaces that combine these geometries—have been explored, previous approaches treated all geometric components as equally significant. This "one-size-fits-all" weighting is inefficient for heterogeneous graphs where one structural type might dominate. For instance, a graph that is 90% tree-like but 10% cyclical would be poorly represented by a 50/50 split between hyperbolic and spherical components.
Proposed Method: WEIGHTED-PM
The authors introduce WEIGHTED-PM, a framework that automatically learns the optimal importance (weight) for each geometric subspace based on the graph's unique topology.
The method consists of four key stages:
- Hierarchical Coarsening: Using Graph Convolutional Networks (GCNs) and pooling layers, the model generates multi-scale views of the graph to identify high-level structural patterns.
- Attention-Based Gating: A multi-head self-attention mechanism processes these coarsened views to calculate "influence scores" ($s_1, s_2, s_3$) for each curvature type.
- Weighted Distance Metric: The model employs a weighted sum of squared distances across the constituent subspaces, allowing the embedding space to adapt its geometry to the data.
- Optimization: Training is conducted via Riemannian Stochastic Gradient Descent (R-SGD) to ensure parameters remain on the manifold surfaces during optimization.
Experimental Evaluation
The model was evaluated across synthetic benchmarks (pure Trees, Cycles, and Mixed structures) and several real-world datasets:
- Graph Reconstruction: CsPhDs (academic networks), Power (electrical grids), and Cities (geospatial data).
- Downstream Tasks: Knowledge Graph completion (FB15k-237, WN18RR), Recommendation Systems (MovieLens-1M, LastFM-20K), and Word Similarity (WS-353).
Key Results and Insights
WEIGHTED-PM consistently outperformed standard product manifold (PM) methods and pure Euclidean models.
- Reduced Distortion: As shown in the results table, WEIGHTED-PM reduced geometric distortion by 28.4% on the Power dataset and 15.6% on the CsPhDs dataset compared to unweighted baselines.
- Geometric Adaptability: In the Power dataset, the model learned an optimal weight ratio of approximately 5:1 between hyperbolic and spherical components, reflecting the grid's strong hierarchical backbone interspersed with cyclical loops.
- Efficiency: By selecting the "correct" geometry, the model achieves high accuracy even at lower dimensions (e.g., $d=10$), whereas Euclidean models require significantly higher dimensionality to capture similar structural nuances.
Conclusion
WEIGHTED-PM demonstrates that treating curvature as a learnable, weighted feature significantly improves graph representation. While the hierarchical pooling adds some computational overhead, the gains in accuracy and compactness are substantial. Future research may explore manifolds with sectional curvatures that vary continuously across the space or adapt the model for dynamic graphs where topology evolves over time.
Summary updated