node2coords: Graph Representation Learning with Wasserstein Barycenters

Effrosyni Simou, Dorina Thanou, Pascal FrossardIEEE Trans. Signal Inf. Process. Over Networks 2020

Abstract

In order to perform network analysis tasks, representations that capture the most relevant information in the graph structure are needed. However, existing methods do not learn representations that can be interpreted in a straightforward way and that are robust to perturbations to the graph structure. In this work, we address these two limitations by proposing node2coords, a representation learning algorithm for graphs, which learns simultaneously a low-dimensional space and coordinates for the nodes in that space. The patterns that span the low dimensional space reveal the graph's most important structural information. The coordinates of the nodes reveal the proximity of their local structure to the graph structural patterns. In order to measure this proximity by taking into account the underlying graph, we propose to use Wasserstein distances. We introduce an autoencoder that employs a linear layer in the encoder and a novel Wasserstein barycentric layer at the decoder. Node connectivity descriptors, that capture the local structure of the nodes, are passed through the encoder to learn the small set of graph structural patterns. In the decoder, the node connectivity descriptors are reconstructed as Wasserstein barycenters of the graph structural patterns. The optimal weights for the barycenter representation of a node's connectivity descriptor correspond to the coordinates of that node in the low-dimensional space. Experimental results demonstrate that the representations learned with node2coords are interpretable, lead to node embeddings that are stable to perturbations of the graph structure and achieve competitive or superior results compared to state-of-the-art methods in node classification.

Introduction

Graph representation learning—the process of mapping nodes to low-dimensional vectors—is fundamental to modern network analysis. However, established methods like DeepWalk or node2vec often function as "black boxes." They suffer from two primary limitations: a lack of physical interpretability (the meaning of specific embedding dimensions is unclear) and instability (minor structural changes can lead to drastic shifts in embeddings).

The node2coords algorithm addresses these challenges by leveraging Optimal Transport (OT) theory. By creating a geometry-aware embedding space, it ensures that node representations are both stable and physically interpretable.

The node2coords Architecture

The core of node2coords is an autoencoder designed to learn a small set of "graph structural patterns" that act as a basis for the entire graph.

The node2coords autoencoder architecture uses a Wasserstein barycentric layer in the decoder to reconstruct node connectivity descriptors.

The model operates as follows:

  1. Input: It takes "node connectivity descriptors" ($Z_n$), which are vectors capturing a node's local neighborhood (e.g., hop-based connectivity).
  2. Encoder ($E$): A linear layer followed by a softmax activation maps these descriptors into a low-dimensional space ($M_S$). This space is spanned by $S$ learned structural patterns.
  3. Decoder: The decoder utilizes a novel Wasserstein barycentric layer. It reconstructs the original node connectivity as a weighted average (barycenter) of the learned patterns.
  4. Coordinates: The weights ($\Lambda$) used to form these barycenters serve as the node embeddings. Because these are calculated using Wasserstein distance—which accounts for graph geometry via diffusion distance—the coordinates directly quantify a node's proximity to specific structural archetypes.

Structural Patterns and Interpretability

Unlike standard autoencoders that treat input dimensions as independent, node2coords is geometry-aware. By using the Wasserstein distance, the model recognizes that nodes are similar if their neighborhoods are "close" in the graph's manifold, even without identical edge sets.

Visualization of two graph structural patterns ($m_1, m_2$) and their resulting Wasserstein barycenter, illustrating how local structures are represented as mixtures of archetypes.

This approach provides built-in interpretability. For instance, in social network analysis, embedding dimensions can correspond to specific communities. A node's coordinate then represents its "membership percentage" or structural proximity to those communities.

Experimental Evaluation

The authors evaluated node2coords on synthetic Stochastic Block Models (SBM) and real-world datasets including Zachary’s Karate Club, PolBooks, and Citeseer4.

Stability and Robustness

A key finding is the model's superior stability. When edges were randomly added or removed, node2coords exhibited significantly lower "embedding drift" compared to methods like DeepWalk or node2vec. While other embeddings fluctuated wildly under noise, node2coords changed linearly and predictably, as the global "landmark" patterns remain relatively stable.

Performance

Despite the constraints imposed for interpretability, node2coords achieves competitive or superior results in community detection and node classification. It particularly excels in low-dimensional settings. For the PolBooks dataset, it outperformed competitors in identifying "neutral" books because its structural landmarks were more distinct and meaningful.

Conclusion

node2coords introduces a robust framework for graph representation learning that prioritizes geometry and interpretability. While the computational complexity of Sinkhorn iterations ($O(N^2)$) presents a challenge for massive graphs, the stability and clarity of the resulting embeddings offer significant advantages for dynamic or noisy real-world networks. Future work may focus on optimizing these operations for web-scale data and applying the method to track evolving node roles in temporal graphs.

Summary updated

BibTeX
@article{simou2020node,
  author = {Effrosyni Simou and Dorina Thanou and Pascal Frossard},
  title = {{node2coords: Graph Representation Learning with Wasserstein Barycenters}},
  journal = {IEEE Trans. Signal Inf. Process. Over Networks},
  year = {2020},
  url = {https://openreview.net/forum?id=L5Jrjjml3vc},
}
Figure