Manuscript Offprint
arXiv:2610.28302Learning Normal Coordinates on Riemannian Manifolds with Flow Charts
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
Abstract
Riemannian manifolds are powerful models for problems with non-Euclidean structure. Recent work in geometric machine learning has focused on training deep neural networks to learn Riemannian metrics from high-dimensional data. However, many geometric algorithms require repeated evaluations of the exponential and logarithmic maps, whose high computational cost restricts the utility of learned Riemannian manifolds in practice. We propose to address this cost by training a conditional invertible neural network, called a flow chart, to approximate normal coordinates around points on a given Riemannian manifold. With this approach, the exponential and logarithmic maps can be approximated by fast Euclidean operations in the model's learned coordinate space. Our main contribution is an efficient loss function for training flow charts that is nonnegative and, under suitable domain assumptions, is zero precisely when the chart is normal. Across sixteen synthetic and data-derived geometries, flow charts are competitive with a specialized neural geodesic interpolator for logarithmic map estimation, while also being able to estimate the exponential map. When pretrained, flow charts provide a median speedup of over numerical baselines at comparable logarithmic map estimation error, and their learned coordinates improve the accuracy of a numerical geodesic solver.
1 Introduction
Many real-world problems can be modeled effectively with Riemannian manifolds whose metric encodes feasible state transitions (Diepeveen et al., 2024b; Wurgaft et al., 2026; Sun et al., 2025). These transitions are represented by shortest paths, called geodesics, so that problems like trajectory inference (Kapuśniak et al., 2024) and probabilistic inference (Girolami and Calderhead, 2011; Williams et al., 2025) can be expressed through geodesic computations. When the geometry is known a priori through domain constraints, geodesics can be computed in closed form or simulated numerically (Lee, 2018; Miolane et al., 2020). However, recent work in geometric machine learning has focused on learning metrics directly from data (Sun et al., 2025; Jones and Lanners, 2026; Bamberger et al., 2026) using neural networks. While these methods offer exciting new avenues for geometric deep learning (Bronstein et al., 2021), these neural metrics present computational challenges that limit their downstream utility.
The two computations that are fundamental to Riemannian algorithms are the exponential and logarithmic maps. These maps play the role of addition and subtraction of points on a manifold, so Riemannian extensions of classical algorithms such as PCA and regression (Fletcher, 2011; Fletcher et al., 2004) evaluate them repeatedly. On general manifolds, neither map has a closed form and both must be solved for numerically. The exponential map is often computed as the solution to a differential equation, like the geodesic equation or Hamilton's equations (Hairer et al., 2006), both of which can be simulated efficiently with automatic differentiation (Williams et al., 2025). However, the simulation updates depend on the metric's derivative, which can be unreliable for
Preprint.

Figure 1: Illustration of normal coordinate charts and our method, using our notation in Section 3 and Section 4. The purple and green symbols correspond to the same points and p on the manifold in the top left, and the red curve is the geodesic between them. The tangent-space and coordinate plots depict the same blue region of the manifold in different numerical representations. The top row shows the standard approach to defining normal coordinates through the logarithmic map and the bottom shows our approach. Our method introduces flow charts and trains them to satisfy the identity in purple to learn normal coordinates.
learned metrics whose value may change rapidly (Arvanitidis et al., 2019). The logarithmic map is the inverse of the exponential map, and requires solving for the geodesic interpolation between two points at a time (Hennig and Hauberg, 2014; Rygaard and Hauberg, 2026). Although this cost can be amortized with neural networks (Kapuśniak et al., 2024; Kelshaw and Magri, 2024), these methods take both endpoints as input and so they are not able to evaluate the exponential map. We explore a different approach to computing both maps based on learning a coordinate system that simplifies their computations, called Riemann normal coordinates.
Normal coordinates are an important tool for calculations in Riemannian geometry (Lee, 2018, page 78). Within a suitable neighborhood of a point, geodesics through that point become straight lines in coordinate space, and so the exponential and logarithmic maps can be computed in closed form with addition and subtraction. However, normal coordinates are most often defined in terms of the exponential and logarithmic maps, and methods for computing them rely on the numerical approximations of these maps (Brun et al., 2005; Lin and Zha, 2008). We build on an alternative characterization of normal coordinates that does not depend on either map.
We propose a novel approach for parameterizing and learning normal coordinates on a Riemannian manifold using flow charts, which are conditional invertible neural networks that represent coordinate charts. Our main contribution is an efficient loss function for training flow charts whose value is nonnegative and equals zero over a geodesic ball if and only if the chart is normal. In our experiments, we first show that flow charts trained with the normal loss can recover the logarithmic map accurately at fixed base points on both synthetic manifolds and geometries derived from data. We then show that charts trained over many base points generalize to unseen ones and achieve median logmap query speedups of over GP Arvanitidis et al. (2019) and over GEORCE Rygaard and Hauberg (2026) across sixteen geometries, and exponential-map query speedups of on the seven high-dimensional geometries at comparable error. Finally, we show that GEORCE can compute more accurate logarithmic maps if applied in the flow chart's learned coordinate space rather than in data coordinates.
(Arvanitidis et al., 2019). These curve parameterizations include splines (Arvanitidis et al., 2022; Karczewski et al., 2026), the posterior mean of a Gaussian process (Arvanitidis et al., 2019), and neural networks (Kapuśniak et al., 2024). While these methods do not learn normal coordinates directly, they offer normal coordinate estimates as their initial velocities. This approach is also how classical data-driven methods for learning normal coordinates operate, where solutions are derived from shortest paths on a graph over data points (Brun et al., 2005; Lin and Zha, 2008). These approaches are different from our method in that we learn normal coordinates directly whereas the other methods recover them as a byproduct.
More broadly, flow charts are related to methods that use neural networks to amortize the cost of expensive geometric computations. The most relevant method is metric flow matching (MFM), which parameterizes the geodesic between two endpoints with a neural network (Kapuśniak et al., 2024). This method learns a geodesic interpolant by minimizing the energy of a parametric curve between the two endpoints under the given metric. Other methods parameterize the geodesic distance function instead. Kelshaw and Magri (2024) and Li et al. (2024) train a network to satisfy the eikonal equation of a given metric. These methods are able to recover the logarithmic map using the gradient of the distance function. Flow charts are also neural network based, but they parameterize normal coordinate charts, which are a more general structure that naturally model the exponential map, logarithmic map and Riemannian distance at once.
Like flow charts, there are other methods that represent a geometry for data using invertible neural network architectures. The pullback metric through a normalizing flow has been used as a geometric model of data (Diepeveen, 2024; Diepeveen et al., 2024a) and is useful for counterfactual explanations (Dombrowski et al., 2021) and interpolations (Fadel et al., 2021). However, each of these methods represents its geometry with a single chart. Multi-chart methods instead cover the data with a finite mixture of flow-based charts (Kalatzis et al., 2021; Sidheekh et al., 2022; Paik et al., 2022; Yu et al., 2026), but are limited in the geometries they can represent because they use a fixed number of charts. Our method differs from these approaches in that it is defined on a given Riemannian manifold, instead of defining its own geometry, and parameterizes a continuous family of charts that can be expanded at any point on the manifold, instead of a discrete set of points.
3 Background
In this section we review basic notation and terminology that will be used in the paper. We intentionally emphasize the coordinate dependence of geometric objects because our method will parameterize a coordinate system. See Lee (2003, 2018) for a reference on differential geometry.
Let be an -dimensional smooth manifold that represents the abstract space that contains data. A coordinate chart is a bijective map from a neighborhood of an abstract point to a subset of on which geometric objects admit numeric representations. We assume that the region of that data is observed in can be represented by one coordinate system, , and denotes the point in the -coordinate system, so that a dataset contains the -coordinates of a collection of points. Subscripts denote the coordinate system in which a geometric object on is represented. For example, represents the components of a tangent vector , and represents the components of a covector . The notation denotes the Jacobian matrix of at .
A Riemannian metric is a point-dependent inner product between two tangent vectors represented by a symmetric positive-definite matrix at each . The cometric defines an inner product between cotangent vectors and is represented by . The pair is called a Riemannian manifold, on which geometric objects like shortest paths, called geodesics, are uniquely defined by .
A curve starting at an initial point with velocity is a geodesic if it satisfies an ODE called the geodesic equation. The solution of this ODE is called the exponential map. Given the initial conditions , the exponential map returns the point obtained from simulating the geodesic equation for 1 unit of time, . Rescaling the initial velocity with some obtains other points on the geodesic, .
Let be a ball of -radius that is small enough for to be a diffeomorphism on . Then is a geodesic ball on centered at . The logarithmic map, , is the inverse of on . If a point is outside of the geodesic ball, there may be many geodesics connecting and , in which case the logarithmic map is not unique.
Riemann normal coordinates (or “normal coordinates”) are a coordinate system in which geodesics through the base point are radial lines from the origin. Let be a geodesic ball centered at and let be a g-orthogonal matrix at , which satisfies . A normal coordinate chart on maps to , where , so that maps to . See Figure 1. Normal coordinate charts are invertible on their domains, with inverse , and are uniquely defined up to the choice of . Because is the identity map, the Jacobian of the inverse coordinate transformation at the origin is .
4 Method
We present a novel approach for learning normal coordinate charts on Riemannian manifolds. Our method represents coordinate charts using a conditional invertible neural network and is trained with a loss that renders the flow chart approximately normal.
4.1 Flow chart
We parameterize coordinate charts using a conditional invertible neural network, called a flow chart.
Definition 1 (Flow chart). Let be the coordinate representation of the manifold in the coordinate system. A flow chart is a map with parameters satisfying two conditions.
-
For every base point , the map is a diffeomorphism, with inverse denoted by .
-
Every base point maps to the origin of its own chart, for all .
We denote as the coordinate representation of under the chart .
In practice, we use normalizing flow architectures with fast inverses to parameterize flow charts (Rezende and Mohamed, 2015; Papamakarios et al., 2021; Durkan et al., 2019).
Flow charts and normalizing flows are closely related in that they both learn coordinate spaces where expensive computations on are simplified. From a geometric perspective, normalizing flows learn a coordinate chart so that the pushforward density of a complicated target probability distribution equals the density of a simple prior. This way, sampling from the target reduces to sampling from the prior. Similarly, given a target metric , flow charts will be trained so that the coordinate representation, , satisfies an identity that implies the chart is normal. For a flow chart that is centered at , its coordinate representation of the metric at a point is given by the following tensor transformation rule (Lee, 2018):
Note that the particular coordinate representation depends on the base point and that we do not write the dependence of on for brevity.
4.2 Normal flow chart
Our main observation is that normal coordinate charts can be identified as flow charts satisfying the identity in the following proposition.
Proposition 2 (Normal chart identity). Let be a Riemannian manifold with global coordinate system , be a point, be a geodesic ball centered at , be an open set containing , and be a coordinate chart, where represents the coordinate of , , and is star-shaped with respect to the origin. Let denote the metric's components. We say that is normal on if it is the restriction to of a normal coordinate chart on . Then,
This identity is Gauss’s lemma written in normal coordinates and serves as a definition of normal coordinates in physics (Müller et al., 1999), but, to our knowledge, has not been used in a machine learning context. See Section A for a proof.
The advantage of this characterization of normality is that the identity can be checked with any flow chart and only requires matrix-vector products with the metric and Jacobian-vector products with the flow chart. Additionally, as illustrated by Figure 1, when a flow chart satisfies the normal chart identity, the exponential and logarithmic maps can be recovered in closed form on the domain where the identity holds:
We train a flow chart to satisfy Equation (2) at a given by optimizing its parameters to minimize the residual of the identity.
Proposition 3 (Normal loss). Let be a Riemannian manifold, be a flow chart with parameters , be an open set containing , and be a probability density restricted to , and assume over the set. Additionally, let and let be the density of the pushforward distribution through , and assume is star-shaped about the origin. The normal loss over for is,
where . The integrand is defined to be zero at . The normal loss satisfies and if and only if is normal on .
See Section A for a proof. The integrand is the squared -norm of the difference between the two sides of the normal chart identity, divided by the squared norm of to remove the quadratic dependence on the distance from the origin. We discuss the importance of this scaling in Section 4.3. Note that one can train with multiple if amortization is desired because flow charts are conditional neural networks. The main challenges in training with the normal loss stem from selecting the neighborhood and distribution . This selection is not trivial because Proposition 3 places geometric conditions on , and the data might not come with a natural coupling to inform how to sample .
4.3 Practical considerations
Suppose the user has access to a dataset of points and selects a subset containing base points . The main practical challenge in training with Proposition 3 is determining how to sample given , or equivalently by a change of variables given , to estimate the normal loss. To satisfy the assumptions of Proposition 3, this sampler should be restricted to a neighborhood of on which there exists a normal solution, and have positive density in this region. Let us first consider how to satisfy the latter, as it can be satisfied independently of the former. Given a procedure for sampling pairs of points , we propose to draw coordinates to estimate the normal loss by sampling on the chord between and , and adding a small amount of Gaussian noise. This amounts to selecting to be the distribution of , where . In our experiments, we select to be small relative to the chord length (see Section D.1.1). This sampler provides coverage along the endpoint chords and around the origin.
In theory, every x should be restricted to a neighborhood of that satisfies the assumptions of Proposition 3 so that the minimizer of the normal loss is normal. On simple manifolds, like the sphere or torus, this neighborhood is known a priori, but in general it is unknown and determined by whether or not the exponential is a diffeomorphism on the region. In this general setting, we propose to draw x from D using a heuristic that depends on , like Euclidean k nearest neighbors. This choice is motivated by our overarching goal of making flow charts a useful model for estimating solutions to geodesic queries by generalization from the pairs seen at training time. However, decoupling the geometry from the training pairs can cause numerical issues that stem from the relative scale of coordinates seen by the model. Figure 2 illustrates this.
The figure shows two geometries built from data with coordinate curves of learned flow charts, contained within a fixed radius coordinate ball that approximate geodesic balls. Panel (a) shows a diffusion geometry Jones and Lanners (2026), whose metric is designed so that paths through regions
• Samples —— Coordinate curves ★ Base points

(a) Diffusion geometry metric
(b) Neighbor coordinate norms

(c) Normalizing flow pullback metric
(d) Neighbor coordinate norms
Figure 2: The scale of coordinates seen by a flow chart during amortized training depends jointly on how endpoint pairs are selected and the underlying geometry. (a) shows a diffusion geometry and (c) the pullback metric through a normalizing flow with a uniform prior, overlaid with the coordinate curves of learned flow charts contained in fixed radius coordinate balls. (b) and (d) show the distributions of coordinate norms for the nearest neighbors of each base point. The coordinates of endpoints selected with nearest neighbors have a scale that varies substantially across base points in (b), but is more comparable in (d) because in (a), coordinate balls tend to expand in the data space where observations are concentrated.
supported by data are shorter than paths away from data (Hauberg et al., 2012; Arvanitidis et al., 2016; Kapuśniak et al., 2024; Sun et al., 2025). Panel (c) shows the pullback metric through a normalizing flow with a uniform prior that is fit to the data (Dombrowski et al., 2021; Diepeveen, 2024), whose Riemannian volume density approximates the probability density of data. The colored background in (c) shows the intensity of the volume density in green, and the inverse volume density in blue for (a). We can see that the size of the coordinate balls and the Riemannian volume density on each geometry relate to the density of data in opposite ways. This behavior has practical implications for the scale of z that the model sees during training for a fixed endpoint sampling strategy. For example, to generate this figure we sample from the Euclidean k nearest neighbors to select x given . (b) and (d) show the distribution of the norms of the neighbor coordinates for each base point. There is more variation across the relative scales in (b) than (d), meaning that the model and optimization procedure must be robust to this variation. This was our motivation for dividing the normal loss integrand by the squared norm of z, which removes its explicit quadratic dependence on coordinate scale. In early experimentation, we found that it was difficult to scale our approach to geometries over images and suspect that the variation in coordinate scales contributed to these difficulties. We leave the investigation of other endpoint samplers for future work.
5 Experiments
Our experiments test the accuracy of charts trained at fixed base points, their performance after pretraining over base points, and their use as coordinates for a numerical solver. The experimental details are given in Section D and the full results for all tested settings are given in Section E.
Geometries We evaluate on six families of manifolds with closed-form exponential and logarithmic maps: spheres, flat tori, hyperbolic spaces, manifolds of symmetric positive-definite matrices, Grassmann manifolds, and special orthogonal groups. Each manifold is used in a low dimensional version, with , and a high dimensional version, with , and is observed through a nonlinear change of coordinates so that the observed coordinates are not already normal. We also use three two-dimensional point clouds, a disk, two moons and nested circles, with the RBF metric of Kapuśniak et al. (2024), and a diffusion geometry built from alanine dipeptide data ( ), learned with Riemannian metric matching (Bamberger et al., 2026). For these four data geometries, the reference logmap is computed with a GP solver (Arvanitidis et al., 2019) in double precision. Each geometry has at most 128 test base points with 1,024 queries per base point on the closed form manifolds and 512 on the data geometries, before discarding queries without a valid reference solution. For each base point , let denote the indices of the remaining queries and let denote the subset for which a method successfully produces a solution.
Flow chart architecture The flow chart we use in these experiments is a conditional neural spline flow (Durkan et al., 2019) with L rational quadratic spline coupling layers, each with 8 bins on in both low and high dimensions. Before each coupling layer, we place a parametric elementwise scale and shift that is conditioned on the base point encoder and a dense invertible linear map (with an LU parameterization). Each coupling layer parameterizes its spline using a FiLM conditioned (Perez et al., 2018) residual network with three residual blocks. The conditioning is computed with a separate residual network that encodes the base point into a 64-dimensional feature vector for all coupling layers. The network widths and other architectural choices are given in Section D.1.1.
We optimize the normal loss with the Adam optimizer (Kingma and Ba, 2015) for 2,000,000 steps with a learning rate of with a linear warmup over the first 100 steps and linear decay to 0 for the last half of training, and a batch size of 512. When training over many base points, we found that it was beneficial to include multiple endpoints per base point and used 16 base points with 32 endpoints each. We clip gradients to unit norm and maintain an exponential moving average of the parameters with decay 0.999. We evaluated on held-out validation pairs every 500 steps and retain the checkpoint with the lowest validation loss. The smaller four-layer charts used for the MFM comparison on data geometries used a constant learning rate after warmup and stopped early after 50,000 steps without validation improvement.
5.1 Evaluation
Logarithmic map The baselines we consider are all based on geodesic interpolation. The first is metric flow matching (MFM) (Kapuśniak et al., 2024), which uses a neural network to parameterize a curve that is guaranteed to start at and end at . This network uses the same gated residual architecture as the flow chart's base point encoder. Since flow charts use an expensive, invertible neural network architecture compared to MFM's unrestricted architecture, we vary the number of blocks and hidden sizes of the MFM to construct two baselines. The first has a similar parameter count of a four-layer flow chart (“parameter matched”), and the second has a comparable compute time (“time matched”). The MFM baselines were trained by minimizing the energy for 2,000,000 steps, using the same optimization procedure as the flow charts. The other two are the Gaussian process solver (GP) of Arvanitidis et al. (2019) and GEORCE (Rygaard and Hauberg, 2026), which solve for the geodesic between the endpoints by refining a curve parameterized by intermediate accelerations and points respectively. MFM serves as a fast, approximate baseline that can benefit from pretraining, while GP and GEORCE are numerical references that must be re-solved for each new pair of endpoints.
We train flow charts using the normal loss, and MFM by minimizing the energy of its curves. In the non-amortized setting, we train a separate chart with coupling layers at each of four test base points, using training queries separate from its test queries. For the runtime experiments, we separately vary chart capacity over using the wider coupling networks described in Section D.1.1.
Let be a method's logmap solution and the reference solution for query at . We measure accuracy using the root mean squared error over the successful queries, , and normalize it by the RMS norm of the reference logmaps to account for differences in scale across geometries to obtain the normalized RMSE, . Dropping the dependence on for brevity, these quantities are defined as:
For each geometry, we report the mean of across base points and its standard error. We also report the wall clock time, , which is measured in microseconds per query on one NVIDIA A16 in single precision, with compilation and preprocessing excluded.
Exponential map We use the same geometries to evaluate the exponential map. Let be a test triplet, where is known in closed form or estimated by the reference GP solver. Given and , each method is tasked with recovering the endpoint . The baselines simulate the geodesic with initial position and velocity by integrating Hamilton's equations with Euler, Heun, Tsit5 (Tsitouras, 2011) and Dopri8 (Prince and Dormand, 1981) with ranges of

Figure 3: Mean logmap normalized RMSE at four fixed base points with error bars indicating one standard error. All methods were evaluated on the same four randomly selected test base points, and use their most favorable settings. The charts use L = 32 coupling layers, the GP uses K = 16 intermediate accelerations, and GEORCE uses K = 32 intermediate knot points. All methods achieve low error, and the individually fitted flow chart achieves error comparable to the GP and GEORCE baselines, with mean error below 0.0032 on every geometry. The pretrained chart has higher error than the individually fitted chart on six of the seven high-dimensional geometries.

Figure 4: Amortized logmap accuracy relative to MFM. Each bar denotes the mean of the L = 4 flow chart or a parameter matched or time matched MFM at the same held out base points. Error bars indicate one standard error. In most settings the flow chart outperforms the baselines, but the parameter matched method performs best in the high dimensional synthetic geometries.
steps selected to cap the total number of cometric evaluations at 129. We use the implementation of these solvers provided by the Diffrax library (Kidger, 2021).
Let be a method's endpoint solution for query at . We measure accuracy using the root mean squared error over the successful queries, , and normalize it by the RMS Euclidean distance from the base point to the reference endpoints to obtain the normalized RMSE, :
For this experiment, a query is successful if the method returns a finite endpoint. The reference scale uses all queries in and is shared across methods. For each geometry, we report the mean of across base points and its standard error, both multiplied by 100, and the mean wall clock time per query, .
Logarithmic map
Exponential map

Below 1: solver faster | Above 1: flow chart faster
Figure 5: Comparison of time needed to achieve similar error between flow charts and numerical methods. For each comparison, is the lowest error level that both methods can reach among the settings we tested. Each dot is the numerical method's solve time divided by the chart's solve time, using each method's fastest setting with error at most . Values above one favor the chart. Flow charts are faster than the numerical baselines, except for exponential-map computation on the low-dimensional data geometries, whose metrics are fast to evaluate.
Runtime comparisons We also compare the runtimes of the methods needed to achieve a common accuracy. For the logarithmic map, we compare pretrained flow charts with GP and GEORCE, and for the exponential map we compare them with the ODE solvers. All methods are timed on the same NVIDIA A16 gpu in the same way, and we sweep over various batch sizes to solve multiple GP and GEORCE queries at once, and report the time for the fastest batch size. For each geometry and comparison, we find the lowest error threshold that both methods can reach among their tested settings, then compare their fastest settings that meet this threshold. See Section D.4 for details.
5.2 Results
Figure 3 shows that a flow chart trained at a fixed base point can recover the logarithmic map to a degree comparable to the baselines. Over 4 base points and 1024 and 512 test queries for closed form and data-driven geometries, respectively, the flow chart achieved an average error below 0.0032, and the pretrained flow chart outperformed GEORCE on 11 of the 16 geometries. The chart is more accurate than GEORCE on all sixteen geometries, but slightly less accurate than GP on the high dimensional manifolds. These results empirically validate the correctness of training flow charts for the normal loss.
Figure 4 compares the performance of a flow chart with against the MFM baselines. The flow chart is more accurate than both MFMs on all nine geometries with . On the seven geometries with , its error is within a factor of 2.1 of time-matched MFM, and is lower on four of them. This could be because the flow chart has a restrictive neural network architecture, so it needs more parameters than MFM's unconstrained architecture to achieve the same accuracy.
For the logarithmic map, Figure 5 shows that the amortized flow chart is up to faster than GP and faster than GEORCE, with median speedups of and across the sixteen geometries. On the high dimensional closed form manifolds, the speedups are against GP and against GEORCE. On alanine dipeptide, both comparisons use a threshold of 2.58 on the mean of , which the chart reaches faster than GP and faster than GEORCE.
For the exponential-map comparison in Figure 5, we vary the chart size and the number of steps used by each ODE solver. For each geometry, we select the fastest chart and the fastest setting across all four ODE solvers whose mean is at most . Each point shows the ODE runtime divided by the chart runtime, so values above one favor the chart. For the exponential map on the seven geometries with , Figure 5 shows that flow charts are faster than the ODE solvers to achieve comparable error, and on the two dimensional point clouds, the ODE solvers are faster than the charts. Here, the fastest solver takes 0.14–0.49 times the runtime of the fastest chart. Section D.4.1 reports the exponential-map errors and the comparison at a fixed runtime budget.
5.3 Flow chart preconditioner
Finally, we show that pretrained flow charts can be used to refine the logmap solution of GEORCE. Flow charts learn a coordinate space where geodesics are approximated by radial lines through the origin. We hypothesize that this behavior can make the task of solving for geodesics simpler to boost the performance of numerical methods. We test this by comparing the performance of GEORCE in the data space and in the coordinate space. Let be a test base point and one of its queries. We encode the query with the pretrained flow chart, and use GEORCE to solve for the geodesic from to under the coordinate representation of the metric, . We use the same test base points and queries, knot counts, stopping tolerance, iteration cap and precision as for GEORCE in the data coordinates. The pretrained flow chart has coupling layers and we run GEORCE at knot counts . Table 1 shows that solving GEORCE in the learned coordinate space consistently improves its performance.
Table 1: GEORCE in data coordinates and in the coordinates of a pretrained flow chart. Columns vary GEORCE's knot count . Each cell reports the mean of across base points in data coordinates followed by an arrow and the value in chart coordinates. The bold numbers above the arrows show the ratio between the two numbers. Solving in chart coordinates consistently lowers error.
| Geometry | K = 4 | K = 8 | K = 16 | K = 32 | ||||
|---|---|---|---|---|---|---|---|---|
| High-dimensional closed-form manifolds | ||||||||
| Sphere 30 | 14.44 | 5.47 | 7.76 | 3.10 | 4.14 | 1.66 | 2.16 | 0.87 |
| Flat torus 30 | 7.26 | 1.91 | 4.03 | 1.10 | 2.16 | 0.60 | 1.12 | 0.31 |
| Hyperbolic 30 | 11.34 | 5.11 | 6.47 | 2.92 | 3.51 | 1.57 | 1.84 | 0.81 |
| SPD 28 | 8.28 | 2.73 | 4.46 | 1.58 | 2.39 | 0.85 | 1.25 | 0.44 |
| Grassmann 30 | 8.06 | 2.76 | 4.44 | 1.59 | 2.38 | 0.86 | 1.24 | 0.45 |
| Rotations 28 | 7.30 | 2.14 | 4.05 | 1.23 | 2.16 | 0.67 | 1.13 | 0.35 |
| Data geometries | ||||||||
| Disk | 1.66 | 0.24 | 1.00 | 0.19 | 0.58 | 0.16 | 0.34 | 0.15 |
| Two moons | 3.64 | 0.45 | 2.16 | 0.34 | 1.23 | 0.30 | 0.71 | 0.28 |
| Nested circles | 3.56 | 0.44 | 2.19 | 0.32 | 1.29 | 0.26 | 0.79 | 0.24 |
| Alanine dipeptide | 8.81 | 1.47 | 4.92 | 0.82 | 2.61 | 0.44 | 1.35 | 0.23 |
6 Conclusion
We introduced flow charts, which are conditional invertible neural networks that learn normal coordinates on a given Riemannian manifold. Our training objective is non-negative and vanishes precisely at normal coordinate charts, under suitable domain assumptions, enabling direct approximations of both the exponential and logarithmic maps. Across synthetic and data-derived geometries, flow charts approximate the maps on par with numerical methods, while being substantially faster when pretrained on data, and they are comparable in performance to MFM for computing the logarithmic map. The main limitation of our method is that it requires heuristics to select training points and that our method can only answer local geodesic queries. Future work could address these limitations by investigating different training strategies, using flow charts to define their own geometry, and by re-centering charts along longer geodesics to answer queries beyond a single chart’s domain.
AI use statement
The research ideas and the design of the method and loss functions originated with the authors. We used ChatGPT and Claude to assist with designing and carrying out experiments, writing and debugging code, running jobs, analyzing results, and producing figures. These tools also helped optimize computational performance, including the efficient computation of geodesic accelerations described in the appendix. We used them to suggest draft proofs, check derivations, and proofread the manuscript. We personally checked the experimental setup, results, and proofs, and take responsibility for the final content of this work, including all AI-assisted text, claims, code, and figures.
References
Georgios Arvanitidis, Lars K Hansen, and Søren Hauberg. A locally adaptive normal distribution. Advances in Neural Information Processing Systems, 29, 2016.
Georgios Arvanitidis, Søren Hauberg, Philipp Hennig, and Michael Schober. Fast and robust shortest paths on manifolds learned from data. In The 22nd International Conference on Artificial Intelligence and Statistics, pages 1506–1515. PMLR, 2019.
Georgios Arvanitidis, Miguel González-Duque, Alison Pouplin, Dimitrios Kalatzis, and Soren Hauberg. Pulling back information geometry. In Gustau Camps-Valls, Francisco J. R. Ruiz, and Isabel Valera, editors, Proceedings of The 25th International Conference on Artificial Intelligence and Statistics, volume 151 of Proceedings of Machine Learning Research, pages 4872–4894. PMLR, 28–30 Mar 2022. URL https://proceedings.mlr.press/v151/arvanitidis22b.html.
Jacob Bamberger, Adam Gosztolai, Pierre Vandergheynst, Michael M. Bronstein, and Iolo Jones. Riemannian metric matching for scalable geometric modeling of distributions. In Proceedings of the 43rd International Conference on Machine Learning, volume 306 of Proceedings of Machine Learning Research, pages 6108–6127. PMLR, 2026. URL https://proceedings.mlr.press/v306/bamberger26a.html.
James Bradbury, Roy Frostig, Peter Hawkins, Matthew James Johnson, Yash Katariya, Chris Leary, Dougal Maclaurin, George Necula, Adam Paszke, Jake VanderPlas, Skye Wanderman-Milne, and Qiao Zhang. JAX: composable transformations of Python+NumPy programs, 2018. URL http://github.com/jax-ml/jax.
Michael M. Bronstein, Joan Bruna, Taco Cohen, and Petar Veličković. Geometric deep learning: Grids, groups, graphs, geodesics, and gauges. arXiv preprint arXiv:2104.13478, 2021.
Anders Brun, Carl-Fredrik Westin, Magnus Herberthson, and Hans Knutsson. Fast manifold learning based on Riemannian normal coordinates. In Heikki Kalviainen, Jussi Parkkinen, and Arto Kaarna, editors, Image Analysis, pages 920–929, Berlin, Heidelberg, 2005. Springer Berlin Heidelberg. ISBN 978-3-540-31566-7.
Ricardo J. G. B. Campello, Davoud Moulavi, and Jörg Sander. Density-based clustering based on hierarchical density estimates. In Pacific-Asia Conference on Knowledge Discovery and Data Mining, pages 160–172. Springer, 2013.
Willem Diepeveen. Pulling back symmetric Riemannian geometry for data analysis. arXiv preprint arXiv:2403.06612, 2024.
Willem Diepeveen, Georgios Batzolis, Zakhar Shumaylov, and Carola-Bibiane Schönlieb. Score-based pullback Riemannian geometry: Extracting the data manifold geometry using anisotropic flows. arXiv preprint arXiv:2410.01950, 2024a.
Willem Diepeveen, Carlos Esteve-Yagüe, Jan Lellmann, Ozan Öktem, and Carola-Bibiane Schönlieb. Riemannian geometry for efficient analysis of protein dynamics data. Proceedings of the National Academy of Sciences, 121(33):e2318951121, 2024b.
Manfredo Perdigão do Carmo. Riemannian Geometry. Mathematics: Theory & Applications. Birkhäuser Boston, 1992. ISBN 978-0-8176-3490-2.
Ann-Kathrin Dombrowski, Jan E. Gerken, and Pan Kessel. Diffeomorphic explanations with normalizing flows. In ICML Workshop on Invertible Neural Networks, Normalizing Flows, and Explicit Likelihood Models, 2021. URL https://openreview.net/forum?id=ZBR9EpE16G4.
Conor Durkan, Artur Bekasov, Iain Murray, and George Papamakarios. Neural spline flows. In Advances in Neural Information Processing Systems, volume 32, 2019. URL https://proceedings.neurips.cc/paper_files/paper/2019/hash/7ac71d433f282034e088473244df8c02-Abstract.html.
Bradley Efron. Tweedie's formula and selection bias. Journal of the American Statistical Association, 106(496):1602–1614, 2011.
Samuel G. Fadel, Sebastian Mair, Ricardo da Silva Torres, and Ulf Brefeld. Principled interpolation in normalizing flows. In Machine Learning and Knowledge Discovery in Databases. Research Track, pages 116–131. Springer, 2021.
P. Thomas Fletcher, Conglin Lu, Stephen M. Pizer, and Sarang Joshi. Principal geodesic analysis for the study of nonlinear statistics of shape. IEEE Transactions on Medical Imaging, 23(8):995–1005, 2004.
Thomas Fletcher. Geodesic regression on Riemannian manifolds. In Proceedings of the Third International Workshop on Mathematical Foundations of Computational Anatomy-Geometrical and Statistical Methods for Modelling Biological Shape Variability, pages 75–86, 2011.
Mark Girolami and Ben Calderhead. Riemann manifold Langevin and Hamiltonian Monte Carlo methods. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 73(2):123–214, 2011. doi: 10.1111/j.1467-9868.2010.00765.x. URL https://rss.onlinelibrary.wiley.com/doi/abs/10.1111/j.1467-9868.2010.00765.x.
Ernst Hairer, Christian Lubich, and Gerhard Wanner. Geometric Numerical Integration: Structure-Preserving Algorithms for Ordinary Differential Equations, volume 31 of Springer Series in Computational Mathematics. Springer, second edition, 2006.
Søren Hauberg, Oren Freifeld, and Michael J. Black. A geometric take on metric learning. In Advances in Neural Information Processing Systems, volume 25, 2012.
Philipp Hennig and Søren Hauberg. Probabilistic solutions to differential equations and their application to Riemannian statistics. In Artificial Intelligence and Statistics, pages 347–355. PMLR, 2014.
Iolo Jones and David Lanners. Computing diffusion geometry. arXiv preprint arXiv:2602.06006, 2026.
Dimitris Kalatzis, Johan Ziruo Ye, Jesper Wohlert, and Søren Hauberg. Multi-chart flows. arXiv preprint arXiv:2106.03500, 2021.
Kacper Kapuśniak, Peter Potaptchik, Teodora Reu, Leo Zhang, Alexander Tong, Michael Bronstein, Avishek J. Bose, and Francesco Di Giovanni. Metric flow matching for smooth interpolations on the data manifold. In Advances in Neural Information Processing Systems, volume 37, pages 135011–135042, 2024.
Rafal Karczewski, Markus Heinonen, Alison Pouplin, Søren Hauberg, and Vikas K. Garg. The spacetime of diffusion models: An information geometry perspective. In International Conference on Learning Representations, 2026. URL https://openreview.net/forum?id=qCsbYJZRA5.
Tero Karras, Miika Aittala, Timo Aila, and Samuli Laine. Elucidating the design space of diffusion-based generative models. In Advances in Neural Information Processing Systems, volume 35, 2022.
Daniel Kelshaw and Luca Magri. Computing distances and means on manifolds with a metric-constrained eikonal approach. arXiv preprint arXiv:2404.08754, 2024.
Patrick Kidger. On Neural Differential Equations. PhD thesis, University of Oxford, 2021.
Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In International Conference on Learning Representations, 2015. URL https://arxiv.org/abs/1412.6980.
John M. Lee. Introduction to Smooth Manifolds, volume 218 of Graduate Texts in Mathematics. Springer, 2003. doi: 10.1007/978-0-387-21752-9.
John M. Lee. Introduction to Riemannian Manifolds, volume 176 of Graduate Texts in Mathematics. Springer, second edition, 2018. ISBN 978-3-319-91754-2. doi: 10.1007/978-3-319-91755-9.
Yiming Li, Jiacheng Qiu, and Sylvain Calinon. A Riemannian take on distance fields and geodesic flows in robotics. arXiv preprint arXiv:2412.05197, 2024.
Tong Lin and Hongbin Zha. Riemannian manifold learning. IEEE Transactions on Pattern Analysis and Machine Intelligence, 30(5):796–809, 2008. doi: 10.1109/TPAMI.2007.70735.
Leland McInnes, John Healy, and Steve Astels. hdbscan: Hierarchical density based clustering. Journal of Open Source Software, 2(11):205, 2017.
Nina Miolane, Nicolas Guigui, Alice Le Brigant, Johan Mathe, Benjamin Hou, Yann Thanwerdas, Stefan Heyder, Olivier Peltre, Niklas Koep, Hadi Zaatiti, Hatem Hajri, Yann Cabanes, Thomas Gerald, Paul Chauchat, Christian Shewmake, Daniel Brooks, Bernhard Kainz, Claire Donnat, Susan Holmes, and Xavier Pennec. Geomstats: A Python package for Riemannian geometry in machine learning. Journal of Machine Learning Research, 21(223):1–9, 2020. URL https://www.jmlr.org/papers/v21/19-027.html.
James Morrill, Patrick Kidger, Lingyi Yang, and Terry Lyons. Neural controlled differential equations for online prediction tasks. arXiv preprint arXiv:2106.11028, 2021. doi: 10.48550/arXiv.2106.11028. URL https://arxiv.org/abs/2106.11028.
Uwe Müller, Christian Schubert, and Anton van de Ven. A closed formula for the Riemann normal coordinate expansion. General Relativity and Gravitation, 31(11):1759–1768, 1999. doi: 10.1023/A:1026718301634.
Feliks Nüske, Hao Wu, Jan-Hendrik Prinz, Christoph Wehmeyer, Cecilia Clementi, and Frank Noé. Markov state models from short non-equilibrium simulations — Analysis and correction of estimation bias. The Journal of Chemical Physics, 146(9):094104, 2017.
Taejin Paik, Jaemin Park, and Jung Ho Park. Atlas flow: compatible local structures on the manifold. arXiv preprint arXiv:2210.14149, 2022.
George Papamakarios, Eric Nalisnick, Danilo Jimenez Rezende, Shakir Mohamed, and Balaji Lakshminarayanan. Normalizing flows for probabilistic modeling and inference. Journal of Machine Learning Research, 22(57):1–64, 2021.
Fabian Pedregosa, Gaël Varoquaux, Alexandre Gramfort, Vincent Michel, Bertrand Thirion, Olivier Grisel, Mathieu Blondel, Peter Prettenhofer, Ron Weiss, Vincent Dubourg, Jake Vanderplas, Alexandre Passos, David Cournapeau, Matthieu Brucher, Matthieu Perrot, and Édouard Duchesnay. Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12:2825–2830, 2011.
Ethan Perez, Florian Strub, Harm de Vries, Vincent Dumoulin, and Aaron Courville. FiLM: Visual reasoning with a general conditioning layer. In Proceedings of the AAAI Conference on Artificial Intelligence, 2018. URL https://ojs.aaai.org/index.php/AAAI/article/view/11671.
Peter J. Prince and John R. Dormand. High order embedded Runge–Kutta formulae. Journal of Computational and Applied Mathematics, 7(1):67–75, 1981.
G. N. Ramachandran, C. Ramakrishnan, and V. Sasisekharan. Stereochemistry of polypeptide chain configurations. Journal of Molecular Biology, 7(1):95–99, 1963.
Danilo Jimenez Rezende and Shakir Mohamed. Variational inference with normalizing flows. In Francis R. Bach and David M. Blei, editors, Proceedings of the 32nd International Conference on Machine Learning, ICML 2015, Lille, France, 6-11 July 2015, volume 37 of JMLR Workshop and Conference Proceedings, pages 1530–1538. JMLR.org, 2015. URL http://proceedings.mlr.press/v37/rezende15.html.
Frederik Möbius Rygaard and Søren Hauberg. GEORCE: a fast new control algorithm for computing geodesics. Information Geometry, 9(1):167–224, 2026. doi: 10.1007/s41884-026-00192-9.
Sahil Sidheekh, Chris B. Dock, Tushar Jain, Radu Balan, and Maneesh K. Singh. VQ-Flows: Vector quantized local normalizing flows. In Proceedings of the Thirty-Eighth Conference on Uncertainty in Artificial Intelligence, volume 180 of Proceedings of Machine Learning Research, pages 1835–1845. PMLR, 2022.
Xingzhi Sun, Danqi Liao, Kincaid MacDonald, Yanlei Zhang, Guillaume Huguet, Guy Wolf, Ian Adelstein, Tim G. J. Rudner, and Smita Krishnaswamy. Geometric-aware generative autoencoders for warped Riemannian metric learning and generative modeling on data manifolds. In Proceedings of the 28th International Conference on Artificial Intelligence and Statistics, volume 258 of Proceedings of Machine Learning Research, pages 1018–1026. PMLR, 2025.
Charalampos Tsitouras. Runge–Kutta pairs of order 5(4) satisfying only the first column simplifying assumption. Computers & Mathematics with Applications, 62(2):770–775, 2011.
Christoph Wehmeyer and Frank Noé. Time-lagged autoencoders: Deep learning of slow collective variables for molecular kinetics. The Journal of Chemical Physics, 148(24):241703, 2018.
Bernardo Williams, Hanlin Yu, Hoang Phuc Hau Luu, Georgios Arvanitidis, and Arto Klami. Geodesic slice sampler for multimodal distributions with strong curvature. arXiv preprint arXiv:2502.21190, 2025.
Daniel Wurgaft, Can Rager, Matthew Kowal, Vasudev Shyam, Sheridan Feucht, Usha Bhalla, Tal Haklay, Eric Bigelow, Raphael Sarfati, Thomas McGrath, Owen Lewis, Jack Merullo, Noah Goodman, Thomas Fel, Atticus Geiger, and Ekdeep Singh Lubana. Manifold steering reveals the shared geometry of neural network representation and behavior. arXiv preprint arXiv:2605.05115, 2026.
Hanlin Yu, Søren Hauberg, Marcelo Hartmann, Arto Klami, and Georgios Arvanitidis. Learning geometry and topology via multi-chart flows. In Proceedings of the 29th International Conference on Artificial Intelligence and Statistics, volume 300 of Proceedings of Machine Learning Research, pages 2962–2970. PMLR, 2026. URL https://proceedings.mlr.press/v300/yu26c.html.
Supplementary Materials
A Proofs
Lemma 4 (Contracted Christoffel symbols). Let be a -dimensional Riemannian manifold, be a coordinate system, be a point, be a tangent vector and let denote the Christoffel symbols of its Levi-Civita connection at . Let denote the contraction . Then
where V is constant with respect to the directional derivative and the Euclidean gradient .
Proof. The Christoffel symbols of the Levi-Civita connection are given by
Contracting with makes the first two terms equal because of the metric is symmetric. Therefore
Converting this expression to matrix notation, and passing the derivatives through yields the result.
Proposition 2 (Normal chart identity). Let be a Riemannian manifold with global coordinate system , be a point, be a geodesic ball centered at , be an open set containing , and be a coordinate chart, where represents the coordinate of , , and is star-shaped with respect to the origin. Let denote the metric's components. We say that is normal on if it is the restriction to of a normal coordinate chart on . Then,
Proof. First we will show that when is normal, we have that using Gauss's lemma. Since is normal, we have that , where . By the chain rule, we have that . Suppose and for some . Recall Gauss's lemma (do Carmo, 1992, Chapter 3, Lemma 3.5), which says that for and in the domain of , we have that for every , the following expression holds
where denotes the Jacobian matrix of the exponential map evaluated at . Then for , the LHS can be rewritten as follows
And the RHS can be written as
Since is arbitrary, we are left with the identity, .
Next, we will prove that the identity implies that is normal. The proof follows in three steps.
① The identity near 0 forces , and so is g-orthogonal.
② The identity on forces , and so is a geodesic.
③ ① + ②
① First we show that the identity implies that is -orthogonal. Let be a unit length vector, , and let be small enough for the vector to be contained in . The identity then reads as . Dividing by , and letting , we get that . Since is arbitrary, , and so , which states that is -orthogonal.
② Next we will show that the identity implies that is a geodesic. Writing the Christoffel contraction from lemma 4 at gives
Under the identity, each of the two terms in the bracket equals zero.
Let . For the first term, consider the directional derivative . Expanding the expression and rearranging terms yields
where is the Jacobian matrix of at .
For the second term, consider . This can be expanded and rearranged to yield
Plugging both terms in gives the expression for the Christoffel contraction in terms of :
Since is open, and for all , . So we have .
Now suppose that , and let for be a curve. Note that by star shapedness. We will show that is a geodesic on . Let be the velocity vector of the curve, and note that and . By definition of a geodesic, is a geodesic if and only if it has zero covariant acceleration, . Expanding the term, we find that its components are 0:
The second to last step follows from bilinearity of . The covariant acceleration of is therefore 0 and is a geodesic. By coordinate invariance, is also a geodesic.
③ Recall the initial value form of geodesics, , where is an initial velocity and is the starting point. The initial velocity of our geodesic is . Equating the expressions gives
If we can invert the expression at , then we are done, but before doing so we must verify that lies in a domain on which is invertible.
Recall that the geodesic ball is defined as , where . The proof is done if we show that so that Equation (21) can be inverted. By ①, is -orthogonal and so , and so an equivalent condition to is .
Consider the curve , which is continuous on and takes values in . Whenever , the vectors and both lie in and satisfy , so the injectivity of on gives .
If , this would hold for every , and continuity would give , whose norm satisfies and contradicts the strict inequality that defines . Therefore , and so . This means that admits a unique inverse, giving us the result
Proposition 3 (Normal loss). Let be a Riemannian manifold, be a flow chart with parameters , be an open set containing , and be a probability density restricted to , and assume over the set. Additionally, let and let be the density of the pushforward distribution through , and assume is star-shaped about the origin. The normal loss over for is,
where . The integrand is defined to be zero at . The normal loss satisfies and if and only if is normal on .
Proof. We drop the dependence on for brevity. Let denote the amount by which the normal chart identity Equation (2) fails at .
contains the components of a covector, because is the covector associated with the vector and is the gradient of a function, so contains the components of the covector . Therefore is the difference of two covectors components. This means that its squared -norm is defined by .
First we will show that the integrand of Equation (4) is this squared g-norm divided by . Expanding the square norm gives
Dividing by and writing gives , which is the integrand of Equation (4) for .
Since is positive definite, the integrand is a squared norm divided by a positive number, so it is nonnegative for , and it is zero at by definition. Its expectation under is therefore nonnegative, which gives . For , the integrand equals zero if and only if .
Next we will show that if and only if is normal on . The set is open, contains , lies in the geodesic ball , and has star shaped image , so by Proposition 2, is normal on if and only if vanishes on . If vanishes on then the integrand vanishes on the support of , so . Conversely, if then the integrand, which is nonnegative and continuous on , has zero expectation under , and is positive on because is positive on and is a diffeomorphism. A nonnegative continuous function with zero expectation under a positive density on an open set vanishes on that set, so for all , and holds trivially.
B Datasets
All of the datasets are split into a training, validation and test set using a split. The size and dimensionality of each dataset are listed below.
| Alanine dipeptide | Disk | Two moons | Nested circles | |
|---|---|---|---|---|
| n | 30 | 2 | 2 | 2 |
| Elements | 750,000 | 500,000 | 500,000 | 500,000 |
Alanine dipeptide The dataset consists of 750,000 snapshots of a molecule over three 250 ns trajectories (Nüske et al., 2017; Wehmeyer and Noé, 2018). Each snapshot contains the three-dimensional positions of 10 heavy atoms (the full molecule has 12 extra hydrogen atoms that are not measured) so that each data point is a vector in . The three trajectories were processed to have the same centroid and orientation, which removes 6 degrees of freedom. We remove the time ordering by shuffling the data, and preprocess by centering and scaling the data by a single scalar so the coordinates have unit root mean square spread.
This dataset is highly structured. As mentioned, the data is preprocessed to shift and orient each trajectory to the same view, so the data manifold is restricted to a 24 dimensional submanifold. Additionally, the mean distance between pairs of atoms across snapshots can be used to determine whether or not each pair is bonded. This yields a graph structure over the atoms in 3d space that characterizes the shape of the molecule. Most of the shape is captured by two main backbone dihedral angles, and , which represent most of the variation of the molecule. As such, it is common to project the data points down to the Ramachandran plot (Ramachandran et al., 1963), which is a 2d torus whose axes are each of the dihedral angles. The projection of data onto this plane organizes into clusters that, at a high level, represent the different shapes that the molecule transitions in and out of during a trajectory. For this reason, the Ramachandran plane is often used during evaluation to interpret trajectories.
Synthetic datasets The three synthetic datasets are point clouds of 500,000 points in , each generated with a fixed random seed. The two moons and the nested circles are generated with the make_moons, with a noise standard deviation of 0.06, and make_circles, with an inner radius of 0.5 and a noise standard deviation of 0.04, from Scikit-learn (Pedregosa et al., 2011). We generate the disk data from a density proportional to on the unit disk using rejection sampling. After the split, each dataset is centered and scaled by a single scalar so that the training set has unit root mean square spread, and the same transform is applied to the validation and test sets.
Licenses and data permissions The alanine trajectories are publicly provided by the Computational Molecular Biology Group at Freie Universität Berlin through mdshare under CC BY 4.0, which permits reuse with attribution. The remaining datasets are generated synthetically; no human participants are involved. The MFM reference implementation and Jaxtyping use the MIT license; JAX, Equinox, Optax, and Diffrax use Apache 2.0; NumPy, SciPy, and Scikit-learn use BSD 3-Clause; tqdm uses MPL 2.0 and MIT; and Matplotlib uses its PSF-based license.
C Geometries
We test our method on synthetic metrics that admit closed form solutions, RBF metrics on three point clouds, and a metric learned from alanine dipeptide with Riemannian metric matching (Bamberger et al., 2026).
C.1 Synthetic metrics
We generate data on the six synthetic manifolds in Table 2, whose exponential maps, logarithmic maps and geodesic distances are known in closed form. Normal coordinates would already give a valid solution at their center, so we apply a nonlinear change of coordinates before presenting the data to our method. For each manifold, we construct one fixed observed coordinate system , then sample base points at which we train the normal chart . The observed coordinates are shared across base points. See Figure 6 for a visual overview.
Let and let be the injectivity radius. Let for a point and for a -orthonormal frame at that point.
Dataset and provider's license statement: https://markovmodel.github.io/mdshare/ALA2/ and https://markovmodel.github.io/mdshare/.
M

Normal chart at the data center
Normal chart at the reference point
Change of coordinates
Observed coordinates
Figure 6: Synthetic data generation. We sample in normal coordinates at the data center (orange), express the same points in normal coordinates at the reference point (blue), and apply to obtain observed coordinates (purple). The learned chart is centered at a sampled base point , whose observed coordinates are .
We center the normal coordinates at a fixed reference point and sample base points around a data center . We choose at distance from in a uniform direction :
For a point p in the geodesic ball of radius around , let s be a normal coordinate chart at and x be another coordinate system, defined by
is fixed and invertible. When , these coordinates cover all of . We use the metric in the observed coordinates.
To construct , we compose four random orthogonal maps and three elementwise nonlinear maps in the order
Each applies the following invertible map to an input coordinate c:
We draw independently for each coordinate and each . and are chosen to standardize each coordinate based on a batch of data at initialization. We use the same for all base points and data splits.
To sample base points, we draw tangent coordinates at the data center from
Around each base point we train on a geodesic ball of radius when , or otherwise. For finite , we redraw until this entire ball lies inside the domain of :
We then generate base points from independent accepted draws,
At each , we train on the geodesic ball
To sample a point in this ball, we independently draw and , then set
This generative process defines with positive density throughout . For each base point, we draw , and training, validation and test points respectively.
C.2 RBF Metric
The synthetic datasets of the exponential map experiment in Section D.2 use the RBF metric of metric flow matching (MFM) (Kapuśniak et al., 2024). This metric is constructed so that geodesics avoid regions without data.
where is a radial basis function network with centers , bandwidths and weights , and is an offset. Although Kapuśniak et al. (2024) state a more general diagonal metric, their released code fits a single network and applies it to every coordinate.
The centers are selected as the K-means centroids of the training set. Let denote the root mean square spread of the k-th cluster per coordinate. We set with .
Let denote points drawn at random from the training set. We select the weights by solving the following optimization problem
The fit makes on the data, so is close to there and grows to away from it. This makes paths that leave the data have large lengths, so geodesics will tend to stay close to the data. We set following MFM, where is evaluated at the fitted weights and averaged over the validation set in place of the training points.
C.3 Diffusion geometry
Figure 2(a) was built with non-parametric diffusion geometries built from 2d point clouds (Jones and Lanners, 2026, Section 3.1). The pointclouds we use come from samples from three toy datasets depicting an uneven concentration on a disk, two moons, and nested circles Section B. The disk has density proportional to on and both the two moons and nested circles have Gaussian noise standard deviations 0.06 and 0.04, respectively, with circle radii 1 and 0.5.
Let denote the point cloud. We build a Markov chain over the cloud from a variable-bandwidth Gaussian kernel supported on each point's 32 nearest neighbors,
Table 2: Overview of synthetic manifolds. , are tangent vectors on each manifold. Dims lists the tested intrinsic dimensions.
| Space / element | Metric | Exp. map | Log. map | Distance | Inj. radius | Dims |
|---|---|---|---|---|---|---|
| Sphere | ||||||
| . | ||||||
| Flat torus | ||||||
| . [] denotes equivalence modulo ; wrap selects the representative in . | ||||||
| Hyperbolic | ||||||
| \langle V,W\rangle_L = \sum_{i=1}^n V^i W^i - V^{n+1}W^{n+1}.\text{Tangents satisfy } \langle \mathbf{p}_0,V\rangle_L=0; r=\sqrt{\langle V,V\rangle_L}, \theta=\operatorname{arccosh}(-\langle \mathbf{p}_0,\mathbf{p}_1\rangle_L). | ||||||
| SPD matrices | ||||||
| , with symmetric tangents ; dimension . We use . . | ||||||
| Grassmannian | ||||||
| represents a subspace, ; dimension . We use . ; thin SVD , with arctan acting on the diagonal of . | ||||||
| Rotation group | ||||||
| ; dimension . We use . Tangents have the form . | ||||||
where is the bandwidth function and is a kernel density estimate. The bandwidth of at each point is the root-mean-square distance to the point’s seven nearest neighbors. We choose the scale and intrinsic dimension estimate jointly following the procedure of Jones and Lanners (2026). For each , we average the kernel weights and compute the slope of this average on a log-log scale. We select the value of with the largest slope and set to twice that slope. Since the local bandwidths depend on the sampling density, we first use this procedure to estimate the density, update the bandwidths, and then repeat it to obtain the values of and used in . The symmetrized row sums of , normalized to sum to one, form the measure over the cloud.
We compute the leading, for the disk and for the other two datasets, eigenfunctions of and store their values on the cloud in the matrix , which satisfies . The eigenfunctions are the smoothest functions on the cloud, so replacing the values of each coordinate function by removes its noisiest components (Jones and Lanners, 2026, Computational Note 7).
The geometry corresponding to the point cloud is given through the carré du champ of the smoothed coordinates. It is a covariance under one step of the Markov chain (Jones and Lanners, 2026, Equation 6) given by,
We average the per-point tensors once under P, symmetrize them, and divide all of them by the median over the cloud of the largest eigenvalue.
Finally, the cometric is defined as a soft, Gaussian weighted average of the CDC over the point cloud
(38)
where and is 0.08 for the disk and the median distance to the eighth neighbor for the two moons and nested circles datasets. is an extra factor to have the geometry behave well away from the support of the data. For two moons and nested circles, and for the disk,
with .
Chart fitting for the diffusion illustration For Figure 2, we fit one chart per displayed base point to its 4,096 nearest neighbors within the same connected component, excluding the base point. Each chart has four affine coupling layers with dense linear mixing, two gated conditioner blocks of width 32, and a one-block base point encoder of width 16 with 8 output features. We use metric preconditioning and center inputs at the base point, scaling by the median neighbor distance measured with . We minimize the normal loss with Adam at a constant learning rate of and unit gradient clipping, using FP64 chart parameters and batches of 64 endpoints (128 for the disk). Let be the median encoded neighbor norm at initialization. We train for 5,000 steps with , then restart Adam from the best checkpoint with for another 2,000 steps on moons and circles or 5,000 on the disk. Every 100 steps we evaluate fixed independent bridge draws on the same training endpoints and retain the lowest-loss checkpoint for the current . The cloud seed is 0 and the three chart initialization seeds are 0, 1, 2.
Normalizing-flow pullback illustration For the pullback panel of Figure 2, we fit an unconditional flow to the uneven-concentration dataset by maximum likelihood under a standard Gaussian prior, using the four-layer affine coupling architecture described above. We compose its encoder with the componentwise standard Gaussian CDF, , and define the pullback metric , whose volume density equals the fitted data density. We freeze this metric and fit one flow chart at each of the same three base points, using the diffusion illustration’s chart architecture and training procedure with FP32.
For both geometries, we decode coordinate grids restricted to disks of a common radius within each panel, orient the grids using rotation-only ICA on encoded neighbors, and overlay the same 600 observations. The backgrounds use separate logarithmic color scales: blue shows inverse volume density for the diffusion metric, and green shows volume density for the pullback metric. Panels (b) and (d) show normalized histograms of the learned coordinate norms of each base point's 4,096 nearest neighbors, using 40 equally spaced bins shared across base points within each geometry. Colors identify corresponding base points across the geometry panels and histograms.
C.4 Riemannian metric matching
For higher dimensional datasets, we use Riemannian metric matching (RMM) (Bamberger et al., 2026) to learn its geometry. Let denote the transition distribution at time of Brownian motion started at , let denote the joint distribution of a data point and its noised version, let denote the marginal of the noised point, and let denote the posterior over the clean point given the noised one. The posterior mean is the denoiser
and the geometry is the family of cometrics, indexed by , given by the scaled posterior covariance
where the second equality is Tweedie’s formula for the posterior covariance (Efron, 2011). This is the mean centered carré du champ of RMM. At a noised point the covariance spans the directions along which clean data that could have produced vary, so the cometric is aligned with the data manifold. RMM fits a parametric cometric, , to the target by minimizing the following regression:
(42)
The second expression is tractable to optimize provided that we can compute the denoiser. For this, we either pretrain a denoiser, or download a pretrained denoiser from the internet, which we denote by .
C.4.1 Low rank parameterization
We parameterize the cometric using the approximately low rank parameterization of RMM:
where is the unconstrained output of a neural network, and .
We train with incorporated into the objective, which yields
(44)
C.4.2 Denoiser architecture
We train a denoiser for alanine dipeptide. The denoiser is parameterized by a residual network, and predicts the clean point under additive Gaussian corruption, so its noise argument is the variance used by RMM. The denoiser uses the parameterization of Karras et al. (2022), where . Here, is a trainable neural network conditioned on the noise variance, and the fixed functions , , and scale its input, its output, and the skip connection, respectively. We set the reference standard deviation of the coordinates to , since every dataset is standardized to unit root mean square spread, giving
The network is a linear layer from to width , followed by residual blocks of width , and a linear layer back to whose weights are initialized to zero so that the denoiser starts as the identity map. The embedding for , , is built from 32 Fourier features of at the frequencies for , whose cosines and sines are passed through two linear layers with a SiLU between them. Each residual block is conditioned on the embeddings using FiLM (Perez et al., 2018),
where is initialized to zero so that each block also starts as the identity. We use , , and , which is about 5M parameters. See Table 3 for the denoiser and cometric architectures and training details.
Denoiser training We train the denoiser on the training split with the denoising loss of Karras et al. (2022), which weights the squared error by ,
We draw log-uniformly over [0.01, 5]. We train with Adam, clip gradients to unit global norm, and ramp the learning rate linearly over the first 1,000 steps. We train the denoiser for a maximum of 1,000,000 steps. We keep an exponential moving average of the weights with decay 0.999, evaluate its loss on the validation split every 1,000 steps with early stopping enabled, and select the averaged checkpoint with the lowest validation loss. A run stops once 50,000 steps pass without an improvement in the validation loss. We sweep the peak learning rate over with three seeds each, and select the run whose selected checkpoint has the smallest loss on the validation split.
Cometric architecture The cometric shares the exact same architecture as the denoiser, except that the last layer maps to a larger vector of size to produce the matrix , following Section C.4.1. The cometric does not use the coefficients , , and , so is the output of the network evaluated at directly. We use a full rank parameterization with and set .
Cometric training We train the cometric on the training data with the objective from Section C.4.1, centered on the selected denoiser. The optimization procedure is identical to how we trained the denoiser.
D Experiment details
Here we give the details of our experiments.
Timing details We measure wall clock time for all of the experiments in this paper in the same way. This method takes a compiled JAX program as input, with its inputs already in device memory, so that compilation time and other preprocessing steps are not included in the reported time. The program is run once as a warmup, and then 5 times after, from which we report the median time. All timings are reported on one NVIDIA A16 in float32 and every program is implemented in JAX (Bradbury et al., 2018) and compiled by XLA with its default settings.
D.1 Logarithmic map experiment details
We generate data on each manifold following the procedure in Section C.1. For each manifold, we generate 2048 basepoints for training the amortized models, 64 for validation and 128 for testing.
Table 3: Denoiser and cometric architectures and training on alanine dipeptide.
| Property | Alanine dipeptide |
|---|---|
| Residual network architecture | |
| Dimension | 30 |
| Width | 512 |
| Residual blocks | 8 |
| Embedding size | 128 |
| Total parameters (M) | 5.32 |
| Denoiser | |
| Training points | 525,000 |
| Validation points | 75,000 |
| Test points | 150,000 |
| Noise range | [0.01, 5] |
| Batch size | 512 |
| Maximum training steps | 1,000,000 |
| EMA decay | 0.999 |
| Selected learning rate | |
| Selected step | 245,000 |
| Validation loss | 6.336 |
| Test loss | 6.361 |
| Cometric | |
| Rank | 30 |
| Floor | |
| Total parameters (M) | 5.76 |
| Selected learning rate | |
| Selected step | 251,000 |
| Validation loss | |
| Test loss | |
For each base point, we sample 1024 associated endpoints to train the MFM and flow chart with. These methods are then evaluated on endpoints of the 128 test base points. All methods use the same test endpoints. The closed form manifolds provide exact references. The data geometries use the reference solutions described in Section D.2. After reference filtering, the two moons has queries at 124 test base points and the other geometries have queries at all 128. We report the mean of and its standard error across the test base points, separately for each manifold and dimension.
D.1.1 Methods
Our baselines employ geodesic interpolation to retrieve normal coordinate and logmap estimates. These methods parameterize a curve that starts at a base point and ends at a query point , and approximate a geodesic by minimizing its energy or solving the geodesic equation. The iterative algorithms (GP and GEORCE) are run until the relative decrease of their energy between iterations falls below a tolerance , and are all parameterized and optimized in float32. Each solver is stopped at 1,000 max iterations, and fails if its solution is nonfinite or the solver reaches this cap without meeting its stopping criterion. Failed queries are left out of both the wall clock time and the errors.
GP We implement the fixed-point solver of Arvanitidis et al. (2019), which represents a curve by a Gaussian-process posterior mean conditioned on its endpoints and acceleration vectors at uniformly spaced times between 0 and 1, with the endpoints included. We use a straight-line prior mean, a squared-exponential kernel with length scale , and for numerical stability in FP32, acceleration regularization of . The model iteratively infers the acceleration of the posterior mean of a Gaussian process, that is conditioned on the endpoint conditions and the accelerations.
Table 4: Sizes of the amortized models and the wall clock cost of computing 1024 normal coordinate estimates at a fixed base point.
| n | Flow chart | MFM, parameter matched | MFM, time matched | |||||
|---|---|---|---|---|---|---|---|---|
| Parameters | μs | Width × blocks | Parameters | μs | Width × blocks | Parameters | μs | |
| 2 | 187,504 | 0.98 | 64 × 15 | 188,674 | 1.51 | 64 × 9 | 113,410 | 1.01 |
| 3 | 191,296 | 1.00 | 64 × 15 | 188,867 | 1.71 | 64 × 6 | 75,971 | 0.97 |
| 4 | 195,104 | 1.05 | 96 × 7 | 197,572 | 1.39 | 64 × 6 | 76,164 | 1.01 |
| 28 | 291,296 | 1.33 | 96 × 10 | 288,604 | 2.05 | 64 × 6 | 80,796 | 1.32 |
| 30 | 299,728 | 1.35 | 128 × 6 | 309,790 | 1.58 | 64 × 9 | 118,814 | 1.30 |
GEORCE We also use the GEORCE (Rygaard and Hauberg, 2026) algorithm to solve for a geodesic interpolation. This approach parameterizes the geodesic with knot points, but uses an iterative algorithm to solve for the knot points without assuming any particular curve parameterization. GEORCE recovers the geodesic interpolation by solving the discretized energy as a control problem with boundary constraints. GEORCE returns knot points rather than a curve, so we interpolate its knots with the piecewise cubic Hermite interpolant with backward differences of Morrill et al. (2021) for evaluation. The initial velocity of GEORCE is the forward difference , where at the times are the knots that are solved for with the algorithm.
Metric flow matching (MFM) Our neural network baseline is MFM (Kapuśniak et al., 2024). This method parameterizes each curve as follows:
where is a neural network. We construct as a gated residual network. MFM is trained to minimize the energy . The training procedure is identical to the flow chart's, below.
We choose the number of blocks and hidden size separately for two MFM baselines. The first has a parameter count modestly close to that of the four-layer flow chart, and the second has a comparable time to compute the fast normal coordinate estimates of Section D.1.2 for a batch of 1024 queries. For the flow chart, this is , and for MFM it is . Table 4 lists the model sizes and computation times. Times are microseconds per query on an NVIDIA A16 in FP32.
Flow chart The flow chart used for the amortized MFM comparison and the preconditioner is a conditional neural spline flow (Durkan et al., 2019) with 4 rational quadratic spline coupling layers, each with 8 bins on in both low and high dimensions, that is initialized to be close to the identity transformation. Before each coupling layer, we place a parametric elementwise scale and shift that is conditioned on the base point encoder and a dense invertible linear map (with an LU parameterization). Each coupling layer parameterizes its spline using a FiLM conditioned (Perez et al., 2018) residual network with three residual blocks of width 32. The conditioning is computed with a separate residual network that encodes the base point into a 64-dimensional feature vector for all coupling layers with 8 gated residual blocks of width 64. The fixed-base-point and runtime experiments use the wider coupling networks described in Section D.3. We train our method with the normal loss in Proposition 3 under the sampling distribution of Section 4.2, with .
We minimize this loss with Adam in single precision at a learning rate of with linear warmup over the first 100 steps. Each training batch holds 16 base points with 32 endpoints each, for a total of 512 pairs, so the base point encoder is evaluated 16 times per step and the coupling layers on every pair. For each pair we draw one time and according to the sampling distribution in Section 4.2. Gradient updates are clipped to have unit norm. We keep an exponential moving average of the parameters with decay 0.999, and this average is the model we evaluate and report. The validation loss is evaluated on held out pairs every 500 steps. The learning rate is constant until step 1,000,000 and then decays linearly to zero at step 2,000,000, where training ends, and we keep the average with the lowest validation loss.
D.1.2 Evaluation metrics
Recall that each method we test takes as input a base point , and query points, , and produces a set of coordinates, , and tangent vectors, , representing the normal coordinates and log map solutions. In this section, we review how each method produces the coordinates and tangent vector solutions. The baseline methods, and our method, offer a curve from the base point to a query point at , that after training approximates a geodesic. We use each of these curves to construct a fast logmap and normal coordinate solution.
Method solutions The fast logmap estimate is simply the initial velocity of the curve, and the corresponding normal coordinate is the logmap scaled by a g-orthogonal matrix. Let be this matrix. Then the fast logmap and normal coordinate solutions corresponding to a method applied to base point and query are
For the flow chart, whose curve is , the fast normal coordinate is the chart's own output, , and the fast logmap is as described in Section 3.
The GP and GEORCE methods fail if the solution is not finite, or the solver stops before meeting its stopping criterion within the maximum number of iterations. We write to denote the indices of the queries of base point at which the method does not fail, and for the indices of queries with valid reference solutions. MFM and the flow chart fail at a query only if its solution is not finite. Each method is graded on its own successful queries. The failed fraction is below 0.72% for each numerical logmap setting, and no evaluated chart logmap query fails.
Evaluation metrics We evaluate the solutions against the ground truth coordinates and logarithmic maps, and .
Wallclock Since we are concerned with speed, we time how long it takes (in wall clock time) to compute the solutions, as measured by Section D. We let denote the wall clock time to compute the solutions and for every , divided by , so that is a time per query. Since is not known in advance, we first run the method on all queries of to find it, and then time a second run on the queries in alone.
For the GEORCE and GP baselines, includes the time to solve for the curve. does not include the time to pretrain the flow chart and MFM on the training set. For the flow chart, the time to compute the base point encoding is included in the time.
Because a batch of queries iterates until its slowest curve stops, we sweep over batch sizes in for each of the GP and GEORCE, at each knot count and geometry on the first 16 test base points and take the batch size with the smallest mean of over these base points. The flow chart and both MFMs are evaluated at a batch size of 1024. On this best batch size, we record the time and peak memory usage of every test base point. Table 5 lists the batch sizes selected for the GP and GEORCE.
We report the mean of over the test base points.
Logmap To evaluate the logmap solutions, we compute the normalized RMSE defined in Section 5.1. We compute the root mean squared g-norm error between the logmap solution and the ground truth
We divide by the reference scale , which uses all queries in and is shared across methods. We average over base points with valid readings and report its mean and standard error multiplied by 100.
Table 5: Batch sizes selected for the GP and GEORCE at each knot count , the size with the smallest mean of over the first 16 test base points.
| Manifold | n | GP | GEORCE | ||||||
|---|---|---|---|---|---|---|---|---|---|
| K=4 | 8 | 16 | 32 | K=4 | 8 | 16 | 32 | ||
| Sphere | 2 | 1024 | 1024 | 1024 | 1024 | 1024 | 1024 | 1024 | 512 |
| Flat torus | 2 | 1024 | 1024 | 1024 | 1024 | 1024 | 1024 | 1024 | 1024 |
| Hyperbolic | 2 | 1024 | 1024 | 1024 | 512 | 1024 | 1024 | 1024 | 1024 |
| SPD | 3 | 1024 | 1024 | 1024 | 512 | 1024 | 512 | 256 | 128 |
| Grassmann | 4 | 512 | 128 | 64 | 64 | 64 | 64 | 64 | 64 |
| Rotations | 3 | 1024 | 1024 | 1024 | 64 | 256 | 64 | 64 | 64 |
| Sphere | 30 | 64 | 64 | 64 | 64 | 64 | 128 | 64 | 64 |
| Flat torus | 30 | 64 | 128 | 64 | 64 | 64 | 128 | 128 | 64 |
| Hyperbolic | 30 | 64 | 64 | 64 | 64 | 64 | 128 | 64 | 64 |
| SPD | 28 | 128 | 64 | 64 | 64 | 64 | 64 | 64 | 64 |
| Grassmann | 30 | 64 | 64 | 64 | 64 | 64 | 64 | 64 | 64 |
| Rotations | 28 | 128 | 64 | 64 | 64 | 64 | 64 | 64 | 64 |
Table 6: Number of test queries that fail for the GP and GEORCE at each knot count , out of 131,072 queries per geometry, 1,024 at each of the 128 test base points.
| Manifold | n | GP | GEORCE | ||||||
|---|---|---|---|---|---|---|---|---|---|
| K=4 | 8 | 16 | 32 | K=4 | 8 | 16 | 32 | ||
| Sphere | 2 | 246 | 32 | 3 | 0 | 0 | 0 | 0 | 0 |
| Flat torus | 2 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Hyperbolic | 2 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| SPD | 3 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Grassmann | 4 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Rotations | 3 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Sphere | 30 | 592 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Flat torus | 30 | 18 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Hyperbolic | 30 | 151 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| SPD | 28 | 199 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Grassmann | 30 | 41 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Rotations | 28 | 21 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
D.1.3 Accuracy comparisons
Amortized accuracy In this experiment, we pretrain a flow chart and the two MFMs described in Table 4 on the training set of each geometry, and then evaluate them on the test set. Each is trained once, from one seed, so the error bars measure variation across base points. For the baselines, we evaluate them directly on the test set. We sweep the knot count of the GP and GEORCE, over .
To estimate the uncertainty in the ratios of Figure 4, we resample the held out base points with replacement 10,000 times, using the same base points for the flow chart and MFM in each sample. We compute the ratio of mean errors for each sample and report the 2.5th and 97.5th percentiles.
Fixed base point accuracy We evaluate the numerical baselines in Figure 3 at the same four base points as the non-amortized flow charts, with indices 26, 44, 67 and 100. For each baseline, we select the knot count with the lowest mean of over all test base points, which gives for the GP and for GEORCE on all sixteen geometries. Each flow chart is trained once, from one seed, so the error bars measure variation across base points. The training queries at these base points are separate from the test queries, as described in Section D.3.
Convergence of the baselines Table 6 shows the number of test queries that fail, for the GP and GEORCE at each knot count over all test queries of all test base points.
D.2 Exponential map experiment details
D.2.1 Data and geometry
We use the twelve closed form manifolds of Section C.1, three geometries constructed from synthetic datasets using the MFM RBF metric, and the diffusion geometry of alanine dipeptide learned with RMM as described in Section B. After pretraining each RMM geometry, we fix , so the flow charts, the ODE solvers, and the ground truth all use the cometric .
Synthetic datasets The synthetic datasets have 500,000 points total, and are split into a training, validation and test set with a (70, 10, 20) split. We use the RBF metric from MFM, which we detail in Section C.2. The ground truth is generated in FP64 but the experiments are run in FP32.
Data selection To select endpoints, we sample from each base point based on proximity. For this, we first run clustering on each dataset (except for alanine dipeptide due to its size) and give each point a label corresponding to its connected component. This clustering is done with the HDBSCAN (Campello et al., 2013; McInnes et al., 2017) algorithm from Scikit-learn (Pedregosa et al., 2011). We run it separately on each split, with a minimum cluster size of 1% of the split and 16 samples per core point, and allow a single cluster. Points that are labeled as noise are given the label of their nearest neighbor with a label. We give all points in alanine dipeptide the same cluster label.
Then, given a base point that is drawn uniformly from the data split, we select an endpoint by drawing uniformly from the Euclidean nearest neighbors with the same cluster label as . is the number of points in the split. We use throughout so that each flow chart sees 10% of the data in the split. The base points and endpoints are drawn from the same data split.
D.2.2 Flow chart architecture and training details
For the MFM comparison and the flow chart preconditioner, we use the four-layer architecture of Section D.1.1. We train these flow charts for at most 2,000,000 steps, with early stopping on the data geometries. On the data geometries, the learning rate remains constant after warmup, and training stops after 100 validation checks (50,000 steps) without improvement. For the capacity sweep, we use the training procedure of Section D.3, without early stopping. We train with a batch containing 16 base points, with 32 endpoints for each. During evaluation, we measure the average loss over the base points of the validation set, each with a single endpoint drawn from the same procedure with a fixed random seed.
We set , where is the median Euclidean distance from a base point to its -th nearest neighbor within its cluster, which is the radius of the region that endpoints are drawn from. We empirically evaluate this over 64 base points before training.
D.2.3 Evaluation set generation
This experiment evaluates different methods on triplets , where . On the synthetic manifolds, the logmap is known in closed form. On the data geometries, we estimate it using the initial velocity of the GP method of Section D.1.1. On each data geometry, we sample endpoint pairs according to the procedure in Section D.2.1 over the test set. We draw base points uniformly from the test set and endpoints for each, without replacement, under a fixed random seed, which gives 65,536 triplets per dataset before the discards below. The triplets are computed in FP64 before evaluation and saved to file, except that on the RMM geometries the network and its derivatives are evaluated in FP32, while the GP iteration and all linear algebra remain in FP64 for numerical stability. We found that in FP32, the GP method consistently diverged. For all of the geometries, we use acceleration nodes, a length scale of , and an acceleration regularizer of .
Since the norm of the logmap solution is supposed to equal the geodesic distance between the base point and the query, the logmap solution can be refined by estimating the length and rescaling. Let be the length of the GP curve, which we estimate with Simpson's rule on 101 evenly spaced times. The improved solution is
Once the curve is fit, we save this refined logmap solution as , together with the entire curve so that we can evaluate against it. We do not include a solution if the GP did not converge, or if (for the synthetic datasets) the GP crosses low data density regions, which we measure with the RBF metric's network from Section C.2, keeping a curve only if at 101 evenly spaced times along it. The GP converges when every squared fixed point residual falls below within 500 iterations. Table 7 lists the number of retained test triplets. On these geometries, the errors measure agreement with the numerical reference, so we compare the GP baseline with the same solver using more acceleration nodes.
Efficient acceleration computation for GP on RMM cometrics For metric parameterized via Section C.4.1, solving for geodesic interpolations for the GP is expensive because every acceleration evaluation differentiates through a cometric solve. However, by taking advantage of the structure of the metric, we can avoid derivative through the inverse. At each of its nodes, the GP evaluates the geodesic acceleration from the position and velocity of the curve there. If it is computed using the expression from Equation (5), this differentiates the metric , which is the inverse of the cometric.
Instead, we compute the acceleration from Hamilton’s equations. Let be the momentum. Under the low rank parameterization, Hamilton’s equations for are
where no gradient flows through p. Differentiating in time gives
where is the directional derivative of at along . This expression of the acceleration is cheap to compute because it requires a single linear solve, for , which is never differentiated. Every derivative can be computed cheaply with Jacobian vector products of vector Jacobian products.
D.2.4 Methods
The baselines simulate the geodesic with initial position and velocity by integrating Hamilton's equations for Hamiltonian ,
from to , so that . On the RMM geometry, we directly parameterize the cometric, so each update does not require a matrix inversion. Only the initial momentum requires an inversion. We integrate with four fixed-step solvers from diffrax (Kidger, 2021) of increasing order, Euler, Heun, Tsit5 (Tsitouras, 2011), and Dopri8 (Prince and Dormand, 1981), which cost one, two, six, and thirteen evaluations of Equation (54) per step, plus one more at the first step for Tsit5 and Dopri8 and one evaluation of the cometric at to form . We run each solver with equal steps over . For a solver that costs evaluations per step, we sweep 5 step counts spaced geometrically from 1 to and rounded, which gives for Euler, for Heun, for Tsit5, and for Dopri8. These choices are so that no baseline evaluates the cometric more than 129 times. On the data geometries, we also use the solver's interpolation to record the state at the 50 times used for the reference curve. A query fails if the solver returns a nonfinite endpoint. The solvers are run in FP32.
The flow chart computes as described in Section 3.
D.2.5 Evaluation metrics
For each method, we compute and as defined in Section 5.1. The numerator uses the queries in for which the method returns a finite endpoint. The reference scale uses all queries in and is shared across methods. We average over base points with valid readings and report its mean and standard error multiplied by 100.
We time every method with the procedure of Section D. Let be the wall clock time to compute the endpoints at a test base point , divided by the number of queries, so that is a time per query. Before discarding queries without a valid reference solution, there are 1,024 queries per base point on the closed form manifolds and 512 on the data geometries. For the flow chart, includes encoding once, and the chart reuses this encoding for all of its queries. For the ODE solvers, includes forming the initial momenta. Every method evaluates the queries of a base point in parallel on a GPU, and we report , the mean of over test base points.
D.3 Capacity and fixed base point experiments
We vary the capacity of the flow chart and compare amortized and non-amortized training on the closed form manifolds, the three synthetic datasets, and alanine dipeptide. We use both the low and high dimensional closed form manifolds, where the logarithmic and exponential maps are known in closed form. On the data geometries, we use the numerical references of Section D.2. See Section C.1, Section C.2 and Section B for a description of each dataset, the geometry they define, and how the training, validation and test sets are generated. Each dataset produces a set of base points, and for each base point, produces query points from which to train or evaluate with. An element of each dataset consists of a triplet of the form , where and are the solution to the logarithmic and exponential maps respectively.
We train flow charts on this data in two different settings. The first is an amortized setting over base points, where we train on base points for each dataset, each with associated query points. During evaluation, we compute and over a set of held out test base points, each with unseen query points before discarding those without a valid reference solution.
The second is a non-amortized setting where we train a flow chart at a single test base point. These test base points are selected at random (with a fixed random seed) from the held out test base points from each dataset. For each of these base points, we construct a training set of query points that is separate from its test query points. On the closed form datasets, we sample new query points at the base point with the sampling procedure of Section C.1, independently of the test query points. On the synthetic and bio datasets, the training query points are the nearest neighbors of the base point in the training set, selected as in Section D.2.1. The base point is a test point and its training query points are training points, so a flow chart never trains on a test query point. Table 7 lists for each dataset.
For Figure 3, we compute at each of these four base points using the same test queries as for the amortized flow chart.
D.3.1 Flow-chart architecture
In all of these experiments, we use a modified version of the conditional neural spline flow of Section D.1.1. We keep the conditioned elementwise scale and shift and the invertible linear map that are placed before each coupling layer, and change the coupling layer and the width of its conditioner. Each coupling layer transforms an input into , where the spline is a rational quadratic spline with 8 bins on , and the 23 spline parameters, the scale and the shift are all predicted by a FiLM conditioned residual network with 3 blocks and hidden width of 64. The scale is passed through a softplus so that the flow chart is close to the identity transformation at initialization.
In the amortized setting, the base point encoder is a residual network with 8 gated residual blocks of width 64 that encodes the base point into a 64-dimensional feature vector for all coupling layers. In the non-amortized setting, the base point is fixed, so the base point encoder has a single gated residual block. We vary the capacity of the amortized flow chart through the number of coupling layers, , and use for the accuracy comparison at fixed base points.
Table 7: Sizes of the training and test sets. On the synthetic and bio datasets, every point of the training set is a base point and its query points are its nearest neighbors with the same cluster label. The last column is the number of test triplets that remain out of after the discards of Section D.2.
| Dataset | n | Test triplets | |||||
|---|---|---|---|---|---|---|---|
| Sphere | 2/30 | 2,048 | 1,024 | 128 | 1,024 | 262,144 | 131,072 |
| Flat torus | 2/30 | 2,048 | 1,024 | 128 | 1,024 | 262,144 | 131,072 |
| Hyperbolic | 2/30 | 2,048 | 1,024 | 128 | 1,024 | 262,144 | 131,072 |
| SPD | 3/28 | 2,048 | 1,024 | 128 | 1,024 | 262,144 | 131,072 |
| Grassmann | 4/30 | 2,048 | 1,024 | 128 | 1,024 | 262,144 | 131,072 |
| Rotations | 3/28 | 2,048 | 1,024 | 128 | 1,024 | 262,144 | 131,072 |
| Disk | 2 | 350,000 | 35,000 | 128 | 512 | 35,000 | 65,536 |
| Two moons | 2 | 350,000 | 35,000 | 128 | 512 | 35,000 | 62,221 |
| Nested circles | 2 | 350,000 | 35,000 | 128 | 512 | 35,000 | 65,041 |
| Alanine dipeptide | 30 | 525,000 | 52,500 | 128 | 512 | 52,500 | 65,529 |
D.3.2 Training
We train every flow chart with the procedure of Section D.1.1, with a budget of 2,000,000 steps, learning rate decay and no early stopping. All non-amortized flow charts reported here and all amortized flow charts with reached the full budget. On two moons, the amortized fits with and diverged after 1,154,500 and 1,292,500 steps respectively. We evaluate these flow charts using their best checkpoints selected before divergence. On the geometries whose cometric is learned with RMM, we fix . In both settings, we set on the closed form datasets as in Section D.1.1, and on the synthetic and bio datasets as in Section D.2. In the amortized setting, each training batch contains 16 base points with 32 query points each. In the non-amortized setting there is a single base point, so each training batch contains 512 query points drawn uniformly from the training points of that base point. On the closed form datasets, the validation loss in the non-amortized setting is evaluated on a validation set containing 1,024 independently sampled points. On the synthetic and bio datasets, this validation set consists of the nearest neighbors of the base point in the validation set, selected as in Section D.2.1, where is the number of points in the validation set.
D.3.3 Evaluation
We evaluate every flow chart in the same way as the flow charts of the experiments above. On every geometry, we compute the mean of or across base points as described in Sections D.1.2 and D.2. On the synthetic and bio datasets, the ground truth normal coordinates of a test triplet are .
In the amortized setting, we evaluate the flow chart at all test base points. In the non-amortized setting, we evaluate each flow chart at its own base point and report the mean over the flow charts. For the accuracy comparison at fixed base points, we evaluate the flow charts and numerical baselines at the same base points.
D.3.4 Baselines
Closed form manifolds ODE Solvers We run the ODE solvers of Section D.2 on the closed form manifolds in both low and high dimensions. All queries of a test base point are solved in a single batch.
Closed form manifolds MFM and GP, GEORCE See Section D.1.
Data manifolds ODE Solvers See Section D.2.
Table 8: Sizes of the MFM baselines on the synthetic and bio datasets.
| Dataset | Flow chart | MFM, parameter matched | MFM, time matched | ||||||
|---|---|---|---|---|---|---|---|---|---|
| n | Parameters | μs | Size | Parameters | μs | Size | Parameters | μs | |
| Disk | 2 | 187,504 | 1.85 | 64 × 15 | 188,674 | 2.20 | 64 × 12 | 151,042 | 1.82 |
| Two moons | 2 | 187,504 | 1.92 | 64 × 15 | 188,674 | 2.23 | 64 × 12 | 151,042 | 1.87 |
| Nested circles | 2 | 187,504 | 1.89 | 64 × 15 | 188,674 | 2.22 | 64 × 12 | 151,042 | 1.87 |
| Alanine dipeptide | 30 | 305,008 | 2.34 | 128 × 6 | 309,790 | 2.74 | 64 × 7 | 93,726 | 2.29 |
Table 9: Parameter counts of the amortized flow charts used in the capacity sweep for each number of coupling layers .
| Datasets | n | L = 4 | 8 | 16 | 32 |
|---|---|---|---|---|---|
| Sphere, torus, hyperbolic | 2 | 319,232 | 533,760 | 962,816 | 1,820,928 |
| SPD, rotations | 3 | 326,616 | 548,464 | 992,160 | 1,879,552 |
| Grassmann | 4 | 334,016 | 563,200 | 1,021,568 | 1,938,304 |
| SPD, rotations | 28 | 516,416 | 926,464 | 1,746,560 | 3,386,752 |
| Sphere, torus, hyperbolic, Grassmann | 30 | 532,032 | 957,568 | 1,808,640 | 3,510,784 |
| Disk, two moons, nested circles | 2 | 319,232 | 533,760 | 962,816 | 1,820,928 |
| Alanine dipeptide | 30 | 532,032 | 957,568 | 1,808,640 | 3,510,784 |
Data manifolds MFM and GP, GEORCE We run the methods of Section D.1.1 on the synthetic and bio datasets, and evaluate them as in Section D.1.2 on the test triplets of Section D.2 that were not discarded. The batch sizes of the GP and GEORCE are selected from .
The two MFMs are matched to the flow chart of Section D.2 on each dataset, with the time measured on the 512 queries of a test base point, and Table 8 lists their sizes. They are trained on the same training pairs as that flow chart, with the same training procedure as Section D.1. We train these MFMs for 2,000,000 steps with learning rate decay and no early stopping.
D.3.5 Experiments
This experiment measures how the errors of a flow chart depend on its capacity, and how much of the error is due to amortization. For every dataset of Table 7, we use an amortized flow chart at each for the runtime comparisons. For the accuracy comparison at fixed base points, we use non-amortized flow charts with , one at each base point. Every other choice is held fixed across , and a flow chart in the non-amortized setting differs from the amortized flow chart of the same in its base point encoder and its training data alone. Each flow chart is trained once, from one seed.
We compare against the baselines of the experiments above, evaluated on the same test triplets. For the logarithmic map, these are the GP, GEORCE and the two MFMs of Section D.1.1, and for the exponential map they are the ODE solvers of Section D.2. The two MFMs are selected to have the same parameter count and time as the flow chart used in the original experiment, and not the size of the ablation models.
Table 9 contains the parameter count of the amortized flow chart for each dimension and .
D.3.6 Scaling with dimension
Figure 7 shows that the cost of a pretrained flow chart also scales favorably with dimension compared with the numerical baselines. Across the closed form manifolds that have low and high dimensional variants, the smallest and largest chart sizes only take 1.30 to 1.63 times longer to run in high dimensions while the GP grows by 3.0 to and GEORCE by 3.8 to (at ).

Figure 7: Increase in time per logmap query from the low dimensional to the high dimensional version of each manifold. Each method uses the same architecture or knot count in both dimensions.
D.4 Matching and solver resolution
To compare runtimes at matched accuracy, we set the error threshold to the larger of the minimum mean errors in the two sweeps. The mean error is the mean of or across base points for the logarithmic or exponential map respectively. Within each sweep, we select the fastest setting whose mean error is at most . We report the speedup as the runtime of the baseline divided by that of the flow chart. This comparison uses the test errors to select settings and describes their measured performance. We do not interpolate between settings. To compare errors at matched cost, we fix the flow chart and select the ODE setting with the lowest error among those whose runtime does not exceed that of the chart. Table 10 lists the settings selected for the comparisons in Figure 5.
On the two dimensional sphere, several ODE settings have very large finite errors, and the errors do not consistently decrease as the number of steps increases. The matched comparison in Figure 5 uses Heun with 64 steps. These results show instability on this geometry, but we have not identified its cause. The conclusions about the exponential map in high dimensions do not depend on this geometry.
Table 10: Settings selected for the runtime comparisons in Figure 5. For each numerical method, is the number of coupling layers in the chart used in that comparison. is the number of knots for GP or GEORCE, and is the number of ODE steps. Each comparison selects the fastest chart and numerical settings whose mean normalized RMSE is at most .
| Geometry | Logarithmic map | Exponential map | |||||
|---|---|---|---|---|---|---|---|
| GP | GEORCE | ODE | |||||
| Solver | |||||||
| Sphere 2 | 16 | 16 | 4 | 32 | 16 | Heun | 64 |
| Flat torus 2 | 8 | 16 | 4 | 32 | 16 | Tsit5 | 2 |
| Hyperbolic 2 | 8 | 16 | 4 | 32 | 16 | Tsit5 | 2 |
| SPD 3 | 16 | 16 | 4 | 32 | 32 | Dopri8 | 1 |
| Grassmann 4 | 32 | 16 | 4 | 32 | 32 | Dopri8 | 1 |
| Rotations 3 | 32 | 16 | 4 | 32 | 32 | Tsit5 | 2 |
| Sphere 30 | 32 | 8 | 32 | 32 | 32 | Heun | 8 |
| Flat torus 30 | 32 | 16 | 16 | 32 | 32 | Dopri8 | 2 |
| Hyperbolic 30 | 32 | 8 | 32 | 32 | 32 | Tsit5 | 2 |
| SPD 28 | 32 | 8 | 32 | 32 | 32 | Heun | 8 |
| Grassmann 30 | 32 | 8 | 32 | 32 | 32 | Dopri8 | 1 |
| Rotations 28 | 32 | 8 | 32 | 16 | 32 | Tsit5 | 2 |
| Disk | 8 | 16 | 4 | 32 | 4 | Dopri8 | 1 |
| Two moons | 16 | 16 | 4 | 32 | 16 | Tsit5 | 2 |
| Nested circles | 4 | 16 | 4 | 32 | 16 | Dopri8 | 2 |
| Alanine dipeptide | 32 | 8 | 32 | 32 | 32 | Heun | 3 |
D.4.1 Exponential map errors and runtime budget
For the exponential map, the flow chart with achieves a mean between 0.15 and 2.51 across the seven geometries with , including on alanine dipeptide. We also compare flow charts and ODE solvers when the ODE solvers are limited to the runtime of the chart. Within this budget, the mean of the most accurate solver is 6.1–195 times that of the flow chart on the high dimensional closed form manifolds, and 3.5 times that of the flow chart on alanine dipeptide. The solvers can reach lower errors if given more time. Figure 9 gives the errors and runtimes at every chart size and ODE step count.
D.5 Flow chart preconditioner
For Table 1, we use the pretrained flow charts with four coupling layers described in Section D.1.1. For each base point, we express the metric in the chart coordinates using Equation (1), encode each query, and run GEORCE between the origin and the encoded query. We map the initial velocity back to data coordinates through to obtain the logmap estimate. We use the same knot counts and stopping criterion as GEORCE in data coordinates. We report the mean of across base points and the ratio of the mean errors at each knot count. GEORCE successfully returns a solution for every query in this comparison in both data and chart coordinates.
At , the mean of is reduced by on the six high dimensional closed form manifolds, and by on the data geometries. The improvement holds at all four knot counts, with factors of across the 40 settings. This suggests that the flow chart learns a space in which the numerical errors associated with GEORCE are reduced. We compare the methods at equal knot counts, so these evaluations do not establish a runtime improvement.
E Complete experimental results
We summarize the results over all geometries and tested settings in three figures. Figures 8 and 9 show the accuracy and time per query for the logarithmic and exponential maps respectively. Figure 10 shows the effect of flow chart capacity and amortization.
Chart: L = 4, 8, 16, 32
GP: K = 4, 8, 16, 32
GEORCE: K = 4, 8, 16, 32
Chart (MFM comparison)
MFM, parameter matched
MFM, time matched




Mean
Time per query ( s)
Figure 8: Logarithmic map accuracy and runtime across all sixteen geometries. Each point gives the mean of , with one standard error across base points. The points for the four flow chart sizes and the four knot counts of the GP and GEORCE are joined by lines. The open diamond denotes the smaller flow chart used for the MFM comparison, shown alongside both MFM baselines. Both axes use logarithmic scales, with ranges chosen separately for each geometry. A black cross marks a setting with failed queries, which are excluded when computing its error.
Chart: L = 4, 8, 16, 32
Heun: S = 1, 3, 8, 23, 64
Dopri8: S = 1, 2, 3, 5, 9
Euler: S = 1, 3, 11, 38, 128
Tsit5: S = 1, 2, 5, 10, 21




Mean
Time per query (μs)
Figure 9: Exponential map accuracy and runtime across all sixteen geometries. Each point gives the mean of , with one standard error across base points. The curves show every flow chart size and ODE step count listed in the legend. Both axes use logarithmic scales, with ranges chosen separately for each geometry. A black cross marks a setting with nonfinite endpoints, which are excluded when computing its error. We retain all finite errors. The large errors on the two dimensional sphere show that several ODE settings are unstable on this geometry. All flow chart queries with valid references return finite endpoints.
| Amortized chart | Fixed-base chart | |||||||
|---|---|---|---|---|---|---|---|---|
| Sphere 2 | 0.1 | 0.11 | 0.088 | 0.088 | 0.033 | 0.018 | 0.03 | 0.026 |
| Flat torus 2 | 0.081 | 0.035 | 0.031 | 0.057 | 0.017 | 0.016 | 0.02 | 0.015 |
| Hyperbolic 2 | 0.055 | 0.042 | 0.035 | 0.032 | 0.019 | 0.02 | 0.021 | 0.025 |
| SPD 3 | 0.14 | 0.088 | 0.059 | 0.035 | 0.087 | 0.036 | 0.019 | 0.031 |
| Grassmann 4 | 0.94 | 0.2 | 0.13 | 0.074 | 0.39 | 0.058 | 0.039 | 0.035 |
| Rotations 3 | 0.094 | 0.039 | 0.035 | 0.029 | 0.055 | 0.019 | 0.03 | 0.025 |
| Sphere 30 | 21 | 13 | 3.3 | 1.9 | 12 | 3.7 | 0.87 | 0.23 |
| Flat torus 30 | 6.7 | 2.7 | 0.37 | 0.16 | 4.9 | 0.99 | 0.33 | 0.18 |
| Hyperbolic 30 | 18 | 9.4 | 6.1 | 3.8 | 11 | 3.6 | 1.1 | 0.28 |
| SPD 28 | 9.8 | 3.1 | 2.5 | 1.7 | 6.6 | 1.8 | 0.7 | 0.32 |
| Grassmann 30 | 10 | 3.7 | 2.9 | 2.5 | 7.5 | 1.6 | 0.62 | 0.3 |
| Rotations 28 | 9.2 | 4.3 | 3.4 | 2.5 | 6.1 | 1.6 | 0.55 | 0.31 |
| Disk | 0.16 | 0.15 | 0.16 | 0.17 | 0.12 | 0.12 | 0.12 | 0.12 |
| Two moons | 0.47 | 0.53 | 0.32 | 0.33 | 0.31 | 0.31 | 0.31 | 0.31 |
| Nested circles | 0.33 | 0.31 | 0.32 | 0.31 | 0.3 | 0.3 | 0.3 | 0.3 |
| Alanine dipeptide | 4.4 | 2.8 | 2.3 | 1.9 | 1.4 | 0.58 | 0.36 | 0.29 |
| 4 | 8 | 16 | 32 | 4 | 8 | 16 | 32 | |
| Coupling layers L | Coupling layers L | |||||||

Figure 10: Effect of flow chart capacity and amortization. The panels show the mean of for amortized and non-amortized flow charts, evaluated on the same four test base points at each chart size. The two panels share a logarithmic color scale.