A 160x Faster Method to Compare AI Datasets Beats the Gold Standard
New closed-form projections turn a classical geometry tool into a fast dataset-distance that beats existing sliced variants while running orders of magnitude faster than OTDD.
ProTakeaways
- New AISTATS 2026 paper defines Busemann functions on Wasserstein space with closed forms for 1D and Gaussian cases.
- Characterizes when geodesics between distributions extend to infinity, a prerequisite for the projection operator.
- Introduces SWB1DG and SWBG, two new Sliced-Wasserstein distances for labeled datasets built on these closed forms.
- Correlates with OTDD at roughly 0.88 Spearman on CIFAR-10, versus 0.72 for the previous sliced variant SOTDD.
- Runs about 160x faster than OTDD on transfer learning tasks while matching classification accuracy.
- Code released at github.com/clbonet/Busemann_Functions_in_the_Wasserstein_Space.
Comparing two labeled datasets, say MNIST against Fashion-MNIST, sounds easy until you actually try it. The standard method, Optimal Transport Dataset Distance (OTDD), treats each class as a probability distribution and solves nested optimal transport problems. It works, but it scales roughly cubically with sample count and class count. A new AISTATS 2026 paper proposes a much faster alternative built on a piece of classical Riemannian geometry that had never been fully worked out for probability distributions: the Busemann function.
An old tool meets a curved space
The Busemann function is the generalization of a hyperplane to curved spaces. In flat Euclidean space, projecting a point onto a direction is just an inner product. On a manifold with geodesics that extend to infinity, the Busemann function plays the same role. It has been used in hyperbolic geometry for Principal Component Analysis, prototype-based classification, decision boundaries, neural network layers, and as a projection operator for Sliced-Wasserstein distances.
The natural next step is to run this machinery on the Wasserstein space, the space of probability distributions equipped with optimal transport as its distance. The catch: the Wasserstein space is not geodesically complete, which prevents defining the Busemann function along every geodesic. A geodesic between two distributions can hit a wall (like two clusters of particles crossing) and fail to extend to infinity.
Nailing down when the geometry works
The authors first characterize exactly when a geodesic in Wasserstein space can be extended to infinity, called a geodesic ray. The results are clean:
- For absolutely continuous distributions, the geodesic is a ray if and only if the optimal transport map is the gradient of a 1-convex function.
- For one-dimensional distributions, it is a ray if and only if the difference of quantile functions is non-decreasing.
- For discrete 1D distributions with equal sample counts, the geometric condition reduces to particles not crossing.
- For Gaussians in any dimension, a Loewner-order condition on the covariance matrices suffices.
With rays in hand, they derive closed-form expressions for the Busemann function in two important cases: one-dimensional distributions and Gaussians. In 1D, it reduces to an inner product between quantile functions. For Gaussians, it becomes a formula involving means and covariance square roots. No optimization needed at inference.
Two new sliced distances
These closed forms unlock efficient projections from probability distributions down to the real line, which is exactly what the Sliced-Wasserstein trick needs. The authors define two new distances for labeled datasets, treating a dataset as a distribution over (feature, class-conditional-distribution) pairs:
- SWB1DG: projects class-conditional distributions to 1D first, then uses the 1D Busemann closed form.
- SWBG: approximates each class as a Gaussian (optionally after dimensionality reduction) and uses the Bures-Wasserstein Busemann closed form.
Both approximate integrals over random projections using Monte Carlo. SWB1DG has complexity O(Ln(log n + d)) for L projections and n samples, matching the fastest existing sliced variant SOTDD.
Correlation with OTDD and a speed win
On CIFAR-10 subdataset pairs, the paper measures how well each cheap distance correlates with the expensive OTDD ground truth. With 5000 projections, SWB1DG hits Spearman correlation around 0.88 and Pearson around 0.88, versus roughly 0.72 and 0.75 for SOTDD. The Busemann variants dominate SOTDD across all projection counts tested, from 10 up to 10000.
The transfer learning experiment is where the practical case gets clear. Given k-shot Fashion-MNIST or USPS as target and MNIST as source, the flow minimizes a chosen distance to augment the target dataset, then a LeNet-5 is trained on the concatenation. Accuracy is comparable to OTDD, but the timing table tells the real story for a 10-shot MNIST-to-Fashion-MNIST run:
| Method | Runtime (seconds) |
|---|---|
| OTDD | 2294 |
| SOTDD | 14.15 |
| SWB1DG | 14.00 |
That is roughly a 160x speedup over OTDD, with the sliced Busemann variant matching or beating SOTDD on correlation and accuracy.
Where it breaks and what is next
SWBG is heavier than SWB1DG because it requires computing matrix square roots, giving O(LCd'^3) overhead. The Gaussian approximation is a real assumption, class distributions that are strongly multimodal will lose information under it. The 1D variant sidesteps this but throws away structure by projecting distributions to scalars before comparing. Concurrent work by Piening and Beinert arrives at a similar 1D construction from a different angle, suggesting this is the right shape for the problem.
Code is available in the authors' GitHub repository, along with the reference implementation of SOTDD used for baseline comparisons. If you have been avoiding OTDD-based analyses because of the cost, this is a drop-in replacement worth trying, especially for dataset distillation, transfer learning setups, or any workflow that needs many pairwise dataset distances.