Learning to Predict Graphs with Fused Gromov-Wasserstein Barycenters

Luc Brogat-Motte, Rémi Flamary, Céline Brouard, Juho Rousu, Florence d'Alché-Buc

Introduction

Supervised Graph Prediction (SGP) involves mapping an arbitrary input—such as a chemical spectrum or a vector of features—to a structured graph. This task is inherently challenging because the output space is discrete, combinatorial, and consists of graphs with varying sizes. Traditional approaches typically rely on computationally expensive energy-based models or unsupervised generative models like VAEs, which often struggle with specific supervised mapping tasks and require significant manual engineering.

Methodology: Conditional FGW Barycenters

The authors propose a novel framework that treats graph prediction as a regression problem. The core idea is to model the predicted graph as a conditional Fused Gromov-Wasserstein (FGW) barycenter.

Overview of the SGP pipeline: an input x is mapped to weights α(x) over a simplex of template graphs, and the final graph z is computed as the FGW barycenter.

The Loss Function and Model

The framework utilizes the FGW distance, which allows for the comparison of graphs with different numbers of nodes by simultaneously accounting for node features and internal structural connectivity. The prediction $f(x)$ is defined as a barycenter of $M$ template graphs. An input $x$ is mapped to a set of weights $\alpha(x)$ that dictate the contribution of each template to the final output.

The authors explore two estimators:

  1. Non-parametric: Employs Kernel Ridge Regression to determine weights, supported by theoretical proofs for consistency and excess risk bounds.
  2. Parametric: Uses a Neural Network to predict weights $\alpha(x)$ while learning the template graphs themselves via stochastic gradient descent.

Key Properties

A significant advantage of this approach is resolution independence. The number of nodes $n$ in the predicted graph is a user-defined hyperparameter that is independent of the model parameters. This allows a single trained model to generate graphs of varying sizes (e.g., 10 nodes or 100 nodes) using the same learned weights. Furthermore, the use of barycenters enables smooth graph interpolation, allowing the model to represent transitions between different topologies by "blending" structures rather than simply selecting from a library.

Experimental Evaluation

The model was evaluated on both synthetic and real-world datasets:

  • Synthetic SBM Dataset: Testing the ability to interpolate structure as a 1D input $x$ determines the community count in a Stochastic Block Model (SBM).
  • Metabolite Identification: Predicting molecular structures from tandem mass (MS/MS) spectra using the GNPS public spectral library (4138 labeled samples).

Key Results

The FGW-based method demonstrated strong performance, particularly in the complex task of metabolite identification.

Comparison of the FGW-based method against standard kernels and fingerprints on the metabolite identification task.

As shown in the results, the FGW approach outperformed the standard Weisfeiler-Lehman (WL) graph kernel and achieved competitive results (Top-10 accuracy of ~53%) compared to expert-engineered molecular fingerprints. Notably, it significantly surpassed state-of-the-art deep generative models like MoFlow, highlighting the effectiveness of the barycentric approach for supervised tasks with minimal manual engineering.

Conclusion and Future Work

By framing graph regression within the "Implicit Loss Embedding" (ILE) framework, this work provides a solid statistical foundation for OT-based graph methods. While the current model requires the number of nodes $n$ to be pre-specified, future iterations could incorporate secondary models to estimate $n(x)$ dynamically. Additionally, scaling to more complex, non-repetitive structures may involve increasing template diversity or feature sophistication.

Summary updated

BibTeX
@inproceedings{brogatmotte2022learning,
  author = {Luc Brogat-Motte and Rémi Flamary and Céline Brouard and Juho Rousu and Florence d'Alché-Buc},
  title = {{Learning to Predict Graphs with Fused Gromov-Wasserstein Barycenters}},
  booktitle = {International Conference on Machine Learning},
  year = {2022},
  url = {https://openreview.net/forum?id=NHcOsY2C0Qi},
}
Figure