Evaluating Graph Generative Models with Graph Kernels: What Structural Characteristics Are Captured?

Martijn Gösgens, Alexey Tikhonov, Liudmila ProkhorenkovaTMLR 2024

Abstract

For many practical problems, it is important to measure similarity between graphs. This can be done via graph kernels. One particular application where the choice of a graph kernel is essential is assessing the quality of graph generative models. However, despite the vast number of graph kernels available in the literature, only basic kernels are usually considered for generative model evaluation. In this paper, we fill this gap and analyze how different graph kernels perform as an ingredient in the pipeline of generative model performance evaluation. To conduct a detailed analysis, we propose a framework for comparing graph kernels in terms of which high-level structural properties they are sensitive to: heterogeneity of degree distribution, the presence of community structure, the presence of latent geometry, and others. For this, we design continuous transitions between random graph models that affect a particular property and measure which graph kernel is sensitive to the corresponding change. We show that using such diverse models with the corresponding transitions is crucial for evaluation: many kernels can successfully capture some properties and fail on others. We also found some well-known kernels that show good performance in our experiments but have been previously overlooked in the literature on evaluating graph generative models.

Introduction

Evaluating graph generative models—crucial for fields ranging from drug discovery to social network analysis—is notoriously difficult. Standard evaluation pipelines typically rely on Maximum Mean Discrepancy (MMD) combined with a graph kernel to measure the distance between a set of generated graphs and a reference set. However, these metrics often act as "black boxes," failing to reveal which specific structural features (e.g., community clusters, degree variance, or latent geometry) are actually being compared. This lack of transparency means a generative model could fail to produce essential structural properties yet still receive a favorable evaluation score if the chosen kernel is insensitive to those features.

Methodology: A Framework for Sensitivity Analysis

To address this gap, this research introduces a rigorous framework to "stress-test" graph kernels using continuous interpolations between different random graph models. The authors define a parameter $\theta \in [0, 1]$ that controls the strength of a specific structural property. For instance, $\theta = 0$ might represent a standard Erdős-Rényi (ER) graph with no inherent structure, while $\theta = 1$ represents a graph with a strong specific property, such as high clustering or power-law degree distributions.

By measuring the Spearman correlation between the MMD values and the degree of structural change ($\theta$), the framework quantifies exactly how sensitive a kernel is to a specific shift. This approach allows researchers to identify the "blind spots" of popular kernels.

Sensitivity of MMD to structural transitions (theta). The high Spearman correlation (r ≈ 0.95) indicates a kernel that effectively captures the structural shift.

The study tested several prominent kernels across diverse synthetic models, including:

  • Chung-Lu (CL) for degree heterogeneity.
  • Planted Partition (PP) for community structure.
  • Random Geometric (RG) for latent geometry.
  • Spherical Complementarity (SC) for bipartite-like structures.

Key Insights and Results

The Weisfeiler-Leman Blind Spot

One of the most significant findings is the limitation of the popular Weisfeiler-Leman (WL) kernel. While it is the "gold standard" for graph isomorphism and excellent at detecting degree distributions, it proved almost entirely insensitive to latent geometry and community structure. This makes WL a potentially poor choice for evaluating models in domains like molecular modeling, where spatial arrangement and clustering are paramount.

The Robustness of the Shortest Path Kernel

In contrast, the Shortest Path (SP) kernel emerged as a surprisingly robust all-rounder. It was the only kernel to maintain high sensitivity (correlation > 0.9) across all tested structural properties, effectively capturing both local and global topology. Despite being an older method often overlooked in recent generative literature, its performance suggests it should be a staple in evaluation pipelines.

Spectral and Scalability Considerations

Spectral methods like NetLSD showed promise but exhibited "non-monotonic" behavior in dimensionality tests, sometimes perceiving graphs as more similar even as they became structurally more distinct. Regarding scalability, for larger graphs ($n=1000$), NetLSD-heat and WL-OA (Optimal Assignment) remained computationally feasible, whereas the Graphlet kernel became prohibitively expensive.

Conclusion

This work demonstrates that no single kernel is a universal solution for graph evaluation. While the Shortest Path kernel offers the most consistent sensitivity across diverse properties, the choice of kernel should ultimately be informed by the specific structural characteristics relevant to the application domain. Future research may benefit from combining multiple kernels to create a more robust "super-metric" that covers the blind spots of individual methods.

Summary updated

BibTeX
@article{gosgens2024evaluating,
  author = {Martijn Gösgens and Alexey Tikhonov and Liudmila Prokhorenkova},
  title = {{Evaluating Graph Generative Models with Graph Kernels: What Structural Characteristics Are Captured?}},
  journal = {Accepted by TMLR},
  year = {2024},
  url = {https://openreview.net/forum?id=d9MhajJT04},
}
Figure