Scientific observations such as probability distributions, trees and covariance matrices call for generative models that respect their non-Euclidean geometry. While flow matching has been extended to manifolds by utilizing geodesics and velocities, such manifold structures are not available in a general metric space. We introduce FréchetFlow, a generative modeling framework for metric space-valued data that requires neither linear operations nor a smooth manifold structure. A key feature of the proposed approach is that we utilize well-established Euclidean flows to learn the joint distribution of distances to a set of landmarks, whereupon new objects are reconstructed from generated landmark representations. The reconstruction step utilizes weighted Fréchet means of reference objects, drawing on Fréchet regression. We establish Wasserstein error bounds that connect accuracy of the generated object distributions to the placement of landmarks, flow approximation and reconstruction error and prove consistency under finite second moments. This leads to convergence rates that depend on the metric complexity of the target objects, tail moments and fitting accuracy. Experiments show competitive accuracy with established flow matching methods in Euclidean simulations and lower Wasserstein errors than specifically tailored methods for several scientific datasets. Across simulation settings, we find that generation error decreases as sample size increases.
Figures & tables
Figure 1: FréchetFlow for locations on a tree with three unit branches meeting at o and shortest-path distance. (a) Each observed point gives a vector Zi⋆=ϕL(Yi) of distances to the three leaves. Colors link leaves and vector entries. (b) The dashed arrow supplies observed representations for flow fitting; Gaussian draws produce new representations Z∼Q . (c) Neural weights wη(Z) yield a weighted Fréchet mean, using the same leaves as references. The displayed distances and weights give a generated point 0.4 units along the right branch; its distances to the three leaves match the sampled representation Z .
Target
n
FM baseline
FréchetFlow
Eight Gaussians
500
0.0940(0.0218)
0.0932(0.0213)
2000
0.0666(0.0151)
0.0679(0.0141)
10,000
0.0559(0.0110)
0.0533(0.0121)
Two moons
500
0.0656(0.0180)
0.0660(0.0191)
2000
0.0463(0.0108)
0.0460(0.0110)
10,000
0.0380(0.0111)
0.0362(0.0098)
Table 1: Empirical W2 for two-dimensional Euclidean targets. Entries are means with sample standard deviations in parentheses.
Figure 2: Training observations and generated samples at n=10,000 . The left and right groups show eight Gaussians and two moons, respectively; within each group, panels show the training sample, FM baseline ( Lipman et al., 2023 ) and FréchetFlow. Each panel displays 2000 observations or generated draws.
n
Metric graph
Phylogenetic trees
Cubical space
500
0.1577(0.0514)
0.1621(0.0270)
0.1256(0.0247)
2000
0.1008(0.0413)
0.1150(0.0178)
0.0891(0.0148)
10,000
0.0876(0.0330)
0.0994(0.0120)
0.0726(0.0129)
Table 2: Empirical W2 for FréchetFlow on a metric graph, in phylogenetic tree space and in a CAT(0) cubical space. Entries are means with sample standard deviations in parentheses. The ground metrics are graph shortest path distance, Billera–Holmes–Vogtmann distance and the intrinsic product metric, respectively.
Figure 3: Graph, whole-tree and cubical simulations at n=10,000 . Panels (a)–(b) display graph densities for the training and generated samples on a common scale; (c)–(d) show two observed and two generated trees. Panels (e)–(g) compare generated branch subdensities with the generating law, (h) compares topology probabilities and (i)–(j) compare marginal internal branch length distributions. Panels (k)–(l) display 2000 training and generated cubical objects in within-cell coordinates; (m) compares cell probabilities. Probability and distribution summaries use all 5000 generated objects from the displayed fits. The dashed curves and dark bars denote the generating laws.
Dataset
Comparison method
Comparison W2
FréchetFlow W2
Earthquakes
RFM
0.1379(0.0230)
0.1280(0.0188)
Fires
RFM
0.1055(0.0249)
0.1277(0.0332)
Floods
RFM
0.1424(0.0254)
0.1426(0.0282)
Volcanoes
RFM
0.3188(0.0600)
0.3104(0.0644)
MERFISH
WFM
0.6407(0.0091)
0.5797(0.0063)
ABIDE
DiffeoCFM
5.2946(0.0396)
5.1756(0.0660)
Table 3: Empirical W2 on the scientific datasets. Entries are means with sample standard deviations in parentheses over ten paired partitions; smaller values indicate greater accuracy. The ground metrics are great-circle distance in radians for the Earth datasets, neighborhood Wasserstein distance for MERFISH and normalized Cholesky distance for ABIDE. RFM and WFM denote Riemannian and Wasserstein flow matching, respectively.
Figure 4: Earth locations and generated samples in a Mollweide projection. Rows show earthquakes, fires, floods and volcanoes; columns show training observations, Riemannian FM and FréchetFlow. Panels display 2000 points, or 663 for volcanoes to match the training count. Table 3 reports evaluation against held-out observations over all ten partitions.
Figure 5: MERFISH cell neighborhoods and ABIDE connectivity, each using a shared partition across methods. (a)–(c) Cell expression densities in the first two principal components, with equal weight per neighborhood and common axes, color scale and Gaussian smoothing bandwidth chosen from the training data. (d) Means of the 16 cell expression vectors in held-out and generated neighborhoods, plotted in the same principal components. (e) Empirical cumulative distributions of distances from training and generated networks to the training Fréchet mean under normalized Cholesky distance. (f)–(h) Entrywise mean correlation matrices with common region ordering and color scale. WFM denotes Wasserstein flow matching.
Figure S1: Six trees corresponding to points in the branch-length square for topology AB/CD and its collapsed boundary trees. The left internal branch has length a and the right has length b . Blue branch lengths are drawn proportionally, while all terminal branch lengths remain fixed across panels. T1–T4 are the four reference trees; T5 and T6 illustrate possible reconstructed trees.
Figure S2: Geometry of the cubical dataset. Each point is a pair of positions on two three-branch metric trees. The nine branch pairs form nine square cells, and the 4×4=16 vertex pairs serve as landmarks and reference points. The red points illustrate a sample in C23 .
Despite the remarkable empirical success of flow-matching models, their statistical generalization guarantees remain underdeveloped. Existing analyses often impose restrictive assumptions on the estimated velocity field and yield convergence rates that fail to reflect the intrinsic low-dimensional structure common in real data, such as natural images and molecular geometries. In this work, we study the statistical generalization of flow-matching models for learning an unknown distribution Pdata from finitely many samples. We derive finite-sample error bounds on the learned generative distribution, measured in the Wasserstein-p distance, for all p≥1. Specifically, given n i.i.d. samples from Pdata, we show that, for every d>dp∗(Pdata) and appropriately chosen network architectures and hyperparameters, the learned distribution PFM satisfies Wp(PFM,Pdata)≲n−1/d+n−1/(2p)(log(1/ξ))1/(2p) with probability at least 1−ξ, where dp∗(Pdata) denotes the Wasserstein-p dimension of the target measure. Our results demonstrate that flow matching naturally adapts to the intrinsic geometry of data and mitigates the curse of dimensionality, as the convergence exponent depends on the intrinsic rather than ambient dimension. These guarantees remain meaningful in high-dimensional regimes and provide a theoretical explanation for the empirical success of flow matching on structured data distributions under substantially more relaxed assumptions than those in existing analyses.
Saptarshi Chakraborty, Quentin Berthet, Peter L. Bartlett
Department of Statistics, University of Michigan · Google DeepMind · Department of Statistics, University of California, Berkeley +1
Flow matching has emerged as a simulation-free alternative to diffusion-based generative modeling, producing samples by solving an ODE whose time-dependent velocity field is learned along an interpolation between a simple source distribution (e.g., a standard normal) and a target data distribution. Flow-based methods often exhibit greater training stability and have achieved strong empirical performance in high-dimensional settings where data concentrate near a low-dimensional manifold, such as text-to-image synthesis, video generation, and molecular structure generation. Despite this success, existing theoretical analyses of flow matching assume target distributions with smooth, full-dimensional densities, leaving its effectiveness in manifold-supported settings largely unexplained. To this end, we theoretically analyze flow matching with linear interpolation when the target distribution is supported on a smooth manifold. We establish a non-asymptotic convergence guarantee for the learned velocity field, and then propagate this estimation error through the ODE to obtain statistical consistency of the implicit density estimator induced by the flow-matching objective. The resulting convergence rate is near minimax-optimal, depends only on the intrinsic dimension, and reflects the smoothness of both the manifold and the target distribution. Together, these results provide a principled explanation for how flow matching adapts to intrinsic data geometry and circumvents the curse of dimensionality.
Shivam Kumar, Yixin Wang, Lizhen Lin
Booth School of Business, University of Chicago · Department of Statistics, University of Michigan · Department of Mathematics, University of Maryland, College Park
Many scientific datasets, such as molecular conformational ensembles or single-cell tissue measurements, are naturally modeled as meta-distributions: distributions over probability measures on non-Euclidean domains. Existing generative methods largely assume Euclidean geometry and fail to capture this structure. We introduce Riemannian Wasserstein Entropic Flow Matching (RWEFM), a generative framework on the Wasserstein space P2(M) of a Riemannian manifold (M,g). RWEFM is trained by regressing a neural vector field onto Riemannian optimal transport velocities, using McCann displacement interpolations as conditional paths. We confirm theoretically that this construction leads to a valid flow matching approach on P2(M) and introduce the Riemannian Entropic Map, a GPU-efficient approximation of the optimal transport map on manifolds. Our experiments show that by respecting the intrinsic geometry of the data, RWEFM can generate whole single-cell samples in hyperspherical latent spaces and protein conformational ensembles on the torus. As RWEFM requires only a geodesic distance and a projection operator, it is not restricted to manifolds with closed-form geometry, which we demonstrate by generating distributions on a general triangulated mesh.
Doron Haviv, Edward De Brouwer, Rishabh Anand +4
Genentech Inc., South San Francisco, CA. · Yale University, New Haven, CT.