Sliced Inner Product Gromov-Wasserstein Distances

Xiaoyun Gong, Gabriel Rioux, Ziv Goldfeld

TL;DR

This paper introduces a scalable "slicing" framework for the Inner Product Gromov-Wasserstein (IGW) distance, a metric used to align datasets residing in entirely different dimensional spaces. By deriving the first closed-form solution for the 1D IGW problem and pairing it with a rotationally invariant projection method, the authors bypass the curse of dimensionality. They provide a provably convergent optimization algorithm that makes high-dimensional geometric data alignment computationally practical.

What Problem Does This Paper Address?

Aligning datasets that live in completely different spaces—such as text embeddings generated by different language models with different dimensionalities—is a fundamental challenge in machine learning. The Gromov-Wasserstein (GW) distance solves this by comparing the intrinsic geometry (like pairwise relationships) of the datasets rather than direct feature-to-feature matches.

Unfortunately, standard GW is computationally brutal: it requires solving a nonconvex quadratic optimization problem and suffers heavily from the curse of dimensionality. For standard optimal transport, researchers use "slicing"—projecting high-dimensional data onto random 1D lines where the problem simplifies to basic sorting—to achieve massive speedups. However, GW has lacked a parallel slicing framework because, until now, the GW problem did not admit a closed-form solution even in one dimension.

This paper specifically addresses this gap for the Inner Product GW (IGW) variant.

Methods

The authors bridge the gap between slicing and geometric alignment through three key innovations:

  1. Univariate IGW Closed-Form Solution: The authors prove that the 1D IGW problem can be solved exactly. For uniformly distributed discrete points, the optimal alignment reduces beautifully to a simple sorting problem (either matching the sorted points directly or in reverse order).
  2. Rotationally Invariant Sliced IGW ($\underline{\text{IGW}}$): Simply averaging random 1D projections breaks rotational invariance, a core property of the original IGW. To fix this, the authors introduce an outer optimization step over the Stiefel manifold, which finds the optimal orthogonal transformation to align the spaces before slicing them.
  3. Constraint-Dissolving Subgradient Method: Optimizing a nonconvex, nonsmooth objective over the Stiefel manifold is notoriously difficult. The authors adapt a "constraint dissolving" technique that transforms the manifold-constrained problem into an unconstrained one, providing formal convergence guarantees to a Riemannian critical point.

Datasets

The methods were evaluated using text embeddings from several standard natural language processing datasets:

  • amazon-polarity & ag-news: Used to compare the geometric representations of 23 distilled BERT student models against a teacher model (bert-base-uncased).
  • arXiv-summarization & IMDB: Combined with ag-news to generate synthetic user profiles representing three distinct writing styles (Formal, Journalistic, and Informal) for heterogeneous data clustering.

Key Insights and Ideas

  • The 1D Breakthrough: Demonstrating that 1D IGW reduces to sorting unlocks the entire slicing paradigm for geometric dataset alignment, mirroring the practical success story of Sliced Wasserstein distances.
  • The Analyticity Catch: Sliced IGW is proven to be a valid pseudometric. However, to guarantee that a sliced distance of zero means the high-dimensional datasets are truly identical geometrically, the distributions must have analytic characteristic functions (e.g., compactly supported data) or be supported on a lattice. Without these structural conditions, slicing can theoretically lose information.
  • Manifold Correction: The inclusion of the Stiefel manifold optimization ensures that the metric remains robust against arbitrary rotations of the underlying datasets, distinguishing it from standard Sliced Wasserstein approaches.

Key Results

  • Theoretical Validation: Numerical experiments confirmed that the Monte Carlo approximation error scales at the predicted theoretical rate of $O(\sqrt{\log(m)/m})$, where $m$ is the number of random slices.
  • LLM Representation Comparison: Sliced IGW successfully tracked representation alignment trends across 23 different language models without requiring the restrictive Gaussian assumptions needed by previous closed-form baselines.
  • Heterogeneous Clustering: In a challenging text clustering task where user data was encoded using different models (mixing 384-dimensional and 768-dimensional spaces), Sliced IGW significantly outperformed Gaussian IGW. Sliced IGW achieved Adjusted Rand Index (ARI) scores up to 0.61 and purity scores up to 0.83, compared to Gaussian IGW's lower ARI of 0.41 and purity of 0.67.

Limitations and Future Work

  • Cost Specificity: The closed-form 1D solution derived here is strictly tied to the inner product cost. Finding similar univariate closed forms for other popular GW variants (such as the standard quadratic distance cost) remains an open challenge.
  • Computational Overhead: The outer optimization over the Stiefel manifold adds computational complexity compared to standard Sliced Wasserstein distances. Developing more efficient Riemannian optimization algorithms is highlighted as a crucial next step.
  • Topological Constraints: The equivalence between Sliced IGW and standard IGW relies on strict mathematical conditions (analyticity or lattice support). Exploring broader distribution classes that satisfy this equivalence without these assumptions is an open area of research.

Summary updated

BibTeX
@inproceedings{gong2026sliced,
  author = {Xiaoyun Gong and Gabriel Rioux and Ziv Goldfeld},
  title = {{Sliced Inner Product Gromov-Wasserstein Distances}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=j9kxvPRZEw},
}
Figure