Theory and Applications to Trajectory Inference
2026-04-13

The fundamental challenge: We observe where cells are at each time point, but never how individual cells move between them.
Non-identifiability: Infinitely many path measures \(\nu\) are consistent with any finite set of marginals \(\mu_{t_1}, \ldots, \mu_{t_T}\).
Standard practice: evaluate TI methods by marginal reconstruction on held-out snapshots
Common metrics: EMD (\(W_1\)), \(W_2\), SWD, MWD, MMD
Why this is fundamentally limited:
\(\Rightarrow\) Need a metric that acts directly on distributions over trajectories


Empirical failure modes:
Metrics inconsistency: Marginals are insufficient statistics for path measures. Different metrics lead to different rankings across (or for the same) snapshots.
Petal trajectories: marginal metrics at each validation time \(\tau\)
Petal dataset, \(\tau = 0.75\):
Marginals are nearly identical — yet the trajectories are qualitatively different!
Only a path-level metric can expose this discrepancy.

Key idea: Treat path measures as first-class citizens and estimate KL divergence directly between them.
Our contributions:
FKL estimator — tractable KL divergence between probability measures on function space, via infinite-dimensional flow theory (FFM)
Benchmark — systematic study showing five widely-used marginal metrics produce inconsistent rankings
Empirical validation — FKL provides coherent, consistent rankings aligned with visual judgement
Let \(\mathcal{H}\) be a real separable Hilbert space with inner product \(\langle \cdot, \cdot \rangle_{\mathcal{H}}\) and countable ONB \(\{e_k\}_{k \in \mathbb{N}}\).
For \(K \in \mathbb{N}\), define the canonical projection \(\pi_K : \mathcal{H} \to \mathbb{R}^K\) by: \[\pi_K(x) = \bigl(\langle x, e_1 \rangle, \ldots, \langle x, e_K \rangle\bigr)\]
Consider two independent \(\mathcal{H}\)-valued random variables:
The Cameron–Martin space is represented as \(\mathcal{H}_C\).
Construct the linear interpolation between \(X_0\) and \(X_1\): \[X_t = (1-t) X_0 + t X_1, \quad t \in [0,1], \qquad \mu_t = \mathrm{Law}(X_t)\]
A velocity field \(v : \mathcal{H} \times [0,1] \to \mathcal{H}\) generates the path \((\mu_t)\) via the continuity equation: \[\int_{\mathcal{H}} \varphi(x,1)\,d\mu_1 - \int_{\mathcal{H}} \varphi(x,0)\,d\mu_0 = \int_0^1 \int_{\mathcal{H}} \bigl(\partial_t \varphi + \langle v_t(x), \nabla_x \varphi \rangle\bigr)\,d\mu_t\,dt\]
Training: minimize the tractable conditional flow-matching loss
Generation: simulate the learned ODE \(\partial_t \phi_t(x) = v_\theta(\phi_t(x), t)\) from \(x \sim \mu_0\)
Setup: two distributions \(\nu^A\) and \(\nu^B\) on \(\mathcal{H}\), sharing Gaussian reference \(\mu_0 = \mathcal{N}(0, C)\).
\[\mathrm{KL}(\nu^A \| \nu^B) = \begin{cases} \displaystyle \int_{\mathcal{H}} \log \frac{d\nu^A}{d\nu^B}\,d\nu^A & \text{if } \nu^A \ll \nu^B \\ +\infty & \text{otherwise} \end{cases}\]
Two assumptions required:
Under Assumptions 2.1–2.2, for \(t \in [0,1)\), we assume absolute continuity \(\mu^A_t \ll \mu^B_t\) with density ratio \(r_t(x) := \frac{d\mu^A_t}{d\mu^B_t}(x)\).
Lemma 3.4: Under mild regularity, the KL divergence between path measures is: \[\mathrm{KL}(\nu^A \| \nu^B) = \int_0^1 \int_{\mathcal{H}} \langle v_t^A(x) - v_t^B(x), \nabla_x \log r_t(x) \rangle_{\mathcal{H}} \, d\mu_t^A(x) \, dt\]
The score difference \(\nabla_x \log r_t(x)\) is computed via a reference measure \(\rho_t\): \[\nabla_x \log r_t(x) = \nabla_x \log \frac{d\mu_t^A}{d\rho_t}(x) - \nabla_x \log \frac{d\mu_t^B}{d\rho_t}(x)\]
For \(K \in \mathbb{N}\), define projected measures \(\hat{\mu}^{A,B}_{t,K} = (\hat{\pi}_K)_\# \mu^{A,B}_t\).
The projected density ratio is \(r^K_t = \frac{d\hat{\mu}^A_{t,K}}{d\hat{\mu}^B_{t,K}} = \mathbb{E}_{P^B}[r_t \mid \mathcal{G}_K]\), with \(\mathcal{G}_K = \sigma(\hat{\pi}^K(X_t))\).
From the weak continuity equation with \(r^K_0 = 1\) (\(P^B\)-a.s.): \[\mathrm{KL}(\nu^A_K \| \nu^B_K) = \int_0^1 \int_{\mathcal{H}} \left(\partial_t \log r^K_t(x) + \langle v^A_t(x), \nabla_x \log r^K_t(x) \rangle \right) d\mu^A_t(x)\,dt\]
From the continuity equation: \[\int_0^1 \int_{\mathcal{H}} \partial_t \log r^K_t(x)\,d\mu^A_t(x)\,dt = -\int_0^1 \int_{\mathcal{H}} \langle v^B_t(x), \nabla_x \log r^K_t(x) \rangle\,d\mu^A_t(x)\,dt\]
Substituting back: \[\mathrm{KL}(\nu^A_K \| \nu^B_K) = \int_0^1 \int_{\mathcal{H}} \langle v^A_t(x) - v^B_t(x),\, \nabla_x \log r^K_t(x) \rangle\,d\mu^A_t(x)\,dt\]
Note that \(\mathrm{KL}(\nu^A_K \| \nu^B_K) \to \mathrm{KL}(\nu^A \| \nu^B)\) as \(K \to \infty\).
The logarithmic gradients can be expressed as: \[\nabla_x \log \frac{d\mu^{A,B}_t}{d\rho_t}(x) = \frac{t}{(1-t)^2} C^{-1} \mathbb{E}_{P^{A,B}}[X_1 \mid X_t = x]\]
For the linear interpolation used in FFM: \[v^{A,B}_t(x) = \frac{1}{1-t}\mathbb{E}_{P^{A,B}}[X_1 \mid X_t = x] - \frac{x}{1-t}\]
\(\Rightarrow\) The log-gradient of \(r_t = \frac{d\mu^A_t}{d\mu^B_t}\) can be expressed entirely in terms of \(v^A_t - v^B_t\).
\[\boxed{\mathrm{KL}(\nu^A \| \nu^B) = \int_0^1 \int_{\mathcal{H}} \frac{t}{1-t} \left\| v^A_t(x) - v^B_t(x) \right\|^2_{\mathcal{H}_{\mu_0}} d\mu^A_t(x)\,dt}\]
Interpretation: KL divergence between two trajectory distributions is quantified by the difference in their velocity fields, integrated over time and over \(\mu^A_t\).
Step 1 — Train a velocity field network, conditioning on the class:
Given trajectory samples from \(\nu^A\) and \(\nu^B\), train \(v^A_\theta\) and \(v^B_\theta\) with a class-conditional FFM loss.
Step 2 — Monte Carlo estimation of FKL:
No ODE integration required — cost proportional to a single forward pass through two networks.
Architecture: Mesh-Informed Neural Operator (MINO) — transformer version
Projection: all computations use \(K\)-mode truncation of the ONB \(\{e_k\}\)
Noise: trace-class noise (Matérn or rougher data covariance) rather than white noise
Asymmetry: both \(\mathrm{KL}(\nu^A \| \nu^B)\) and \(\mathrm{KL}(\nu^B \| \nu^A)\) are reported:
Consider \(\nu^A = \mathcal{N}(m^A, R)\) and \(\nu^B = \mathcal{N}(m^B, R)\) on \(\mathcal{H} = L^2(\mathbb{T}; \mathbb{R})\) with Matérn covariance \(R\).
Closed-form KL: \[\mathrm{KL}(\nu^A \| \nu^B) = \frac{1}{2}\|m^A - m^B\|^2_{\mathcal{H}_R}\]
Setting \(m^A = \cos(2\pi x)\), \(m^B = 0\); ONB \(\{e_k(x) = e^{2\pi i k \cdot x}\}\) with \(\mathcal{K}e_k = \lambda_k e_k\), \(\lambda_k = \sigma^2(4\pi^2 k^2 + \tau^2)^{-\alpha}\).
Validation: FKL estimator closely matches the closed-form value, and is resolution invariant.
| Case | \(D\) | \(f\) | \(s\) | Fwd Analytic | Fwd Estim. | Rev Analytic | Rev Estim. |
|---|---|---|---|---|---|---|---|
| 1 | 1 | 1 | 0.5 | 3.64 | 3.95 | 3.64 | 3.88 |
| 2 | 1 | 1 | 1.5 | 32.79 | 32.61 | 32.79 | 33.31 |
| 3 | 1 | 3 | 1.5 | 50.00 | 49.58 | 50.00 | 49.00 |
| 4 | 1 | 5 | 1.5 | 103.74 | 104.46 | 103.74 | 100.58 |
| 5 | 2 | 1 | 0.5 | 7.29 | 6.77 | 7.29 | 6.72 |
| 6 | 3 | 1 | 0.5 | 10.93 | 10.48 | 10.93 | 10.49 |
| 7 | 5 | 1 | 0.5 | 18.22 | 22.32 | 18.22 | 22.28 |
| 8 | 10 | 1 | 0.5 | 36.43 | 45.12 | 36.43 | 45.73 |
Gaussian Measure: analytic vs estimated functional KL.

Two SDEs with same diffusion, different drifts: \[A: dY_t = c^A Y_t\,dt + g\,dW_t, \qquad B: dY_t = c^B Y_t\,dt + g\,dW_t\]
Girsanov’s theorem + Itô isometry give the closed-form KL: \[\mathrm{KL}(\nu^A \| \nu^B) = \frac{(c^A - c^B)^2}{2g^2} \left[ (M_0 + S_0)\,\frac{e^{2c^A} - 1}{2c^A} + \frac{g^2 D}{2c^A}\!\left(\frac{e^{2c^A} - 1}{2c^A} - 1\right) \right]\]
where \(M_0 = \|Y_0\|^2\), \(S_0 = \text{Tr}(\Sigma_0)\).
Our FKL estimates match this ground truth closely across all tested settings.
| Case | \(D\) | \(c_A\) | \(c_B\) | \(g\) | Fwd Analytic | Fwd Estim. | Rev Analytic | Rev Estim. |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | 0.01 | 1.50 | 0.75 | 8.93 | 8.87 | 54.71 | 53.77 |
| 2 | 1 | 0.10 | 2.00 | 0.75 | 15.89 | 13.89 | 186.19 | 200.64 |
| 3 | 2 | 0.01 | 1.50 | 0.75 | 17.86 | 18.05 | 109.43 | 127.67 |
| 4 | 3 | 0.01 | 1.50 | 0.75 | 26.79 | 34.58 | 164.14 | 145.06 |
| 5 | 5 | 0.01 | 1.50 | 1.00 | 26.34 | 32.82 | 158.22 | 135.28 |
Linear SDE: analytic (Girsanov) vs estimated FKL.



| Method | Paradigm | Key property |
|---|---|---|
| SBIRR | Schrödinger Bridge | Gradient fields + stochasticity; iterative ref. refinement |
| vSB | Schrödinger Bridge | Vanilla IPF-based; snapshot matching |
| MSBM | Multi-marginal SB | Iterative Markovian Fitting; multi-snapshot constraints |
| MFL | Mean-Field Langevin | Path-space optimization; min-entropy w.r.t. Wiener measure |
| AM | Action Matching | Minimizes kinetic energy; optional entropic variant |
| TIGON | ODE-based | Neural ODE; dynamic unbalanced OT + growth |
Reference: VAL = resampled ground-truth trajectories (oracle upper bound)
| Metric | Acronym | Type | Property |
|---|---|---|---|
| Earth Mover’s Distance | EMD (\(W_1\)) | OT | Geometry-aware |
| 2-Wasserstein Distance | \(W_2\) | OT | Quadratic cost |
| Sliced Wasserstein Distance | SWD | OT | Random projections |
| Max-sliced Wasserstein | MWD | OT | Max-sliced variant |
| Maximum Mean Discrepancy | MMD | Kernel | RBF kernel; bandwidth-dependent |
\[W_p(\mu,\nu) = \left(\inf_{\gamma\in\Pi(\mu,\nu)}\int \|x-y\|^p\,d\gamma\right)^{1/p}\] \[\mathrm{MMD}^2(\mu,\nu) = \mathbb{E}_{x,x'\sim\mu}[k(x,x')] - 2\,\mathbb{E}_{x\sim\mu,y\sim\nu}[k(x,y)] + \mathbb{E}_{y,y'\sim\nu}[k(y,y')]\]
Limitation: All these metrics operate on marginals — blind to temporal coupling structure.
Lotka–Volterra
Repressilator
Petal
Ground-truth trajectories available \(\Rightarrow\) FKL computed against true path measure
Embryoid Body (EB)
Human Embryonic Stem Cell (hESC)
No ground-truth trajectories on real data. We use SBIRR as reference: it models differentiation via gradient fields with stochasticity, matching biological intuition of Waddington’s landscape.






CD analysis ranks marginal-metric methods by significance:
In general, marginal metrics are not significant. FKL provides principled ranking even when CD gives weak guidance.

The non-identifiability principle:
Any finite set of marginals is consistent with infinitely many path measures.
Methods that connect point clouds (TIGON) can score well on marginals while generating unrealistic temporal behavior.
SB methods (vSB, MSBM) focus on snapshot matching and provide limited control over intermediate dynamics unless additional structure is imposed (as in SBIRR).
Only FKL can distinguish them.
| Method | LV Fwd | LV Rev | Repr Fwd | Repr Rev | Petal Fwd | Petal Rev |
|---|---|---|---|---|---|---|
| VAL | 7.85 ± 0.43 | 7.82 ± 0.41 | 5.21 ± 0.08 | 5.19 ± 0.08 | 4.00 ± 0.04 | 3.88 ± 0.05 |
| SBIRR | 30.6 ± 0.3 | 32.5 ± 0.7 | 13.4 ± 0.3 | 16.1 ± 0.3 | 21.5 ± 0.2 | 34.3 ± 0.6 |
| vSB | 89.8 ± 2.5 | 87.4 ± 2.4 | 31.2 ± 0.6 | 31.4 ± 0.6 | 24.0 ± 0.3 | 37.1 ± 0.8 |
| MSBM | 56.5 ± 2.8 | 37.3 ± 1.0 | 30.5 ± 0.7 | 19.8 ± 0.2 | 13.6 ± 0.1 | 16.1 ± 0.2 |
| MFL | 38.7 ± 0.7 | 153.4 ± 9.9 | 26.4 ± 0.5 | 35.8 ± 0.5 | 42.3 ± 1.1 | 81.5 ± 5.6 |
| AM | 35.2 ± 0.7 | 49.1 ± 1.6 | 27.4 ± 0.4 | 435.8 ± 17.4 | 16.9 ± 0.4 | 32.7 ± 0.9 |
| TIGON | 66.6 ± 3.1 | 51.3 ± 0.8 | 18.8 ± 0.3 | 17.0 ± 0.1 | 40.0 ± 3.1 | 17.8 ± 0.3 |
\(\mathrm{KL}(\nu^A \| \nu^B)\): penalizes reference support not covered by \(\nu^B\) \(\;\Rightarrow\;\) mode coverage
\(\mathrm{KL}(\nu^B \| \nu^A)\): penalizes mass that \(\nu^B\) places outside the reference \(\;\Rightarrow\;\) hallucination
When \(\mathrm{KL}(\nu^B \| \nu^A) \gg \mathrm{KL}(\nu^A \| \nu^B)\), the method generates trajectories unsupported by the reference.


EB dataset — FKL prefers MFL (fwd) and MSBM (rev); TIGON scores highest on some marginal metrics at \(\tau=0.25\) but has FKL = 126, the worst by far.
hESC dataset — MFL achieves lowest forward FKL (95.1); TIGON wins most marginal metrics at \(\tau=0.25\) but scores FKL = 288.5, the worst.
| Dataset | Method | Marginal Winner? | FKL Best? |
|---|---|---|---|
| EB | MFL | Partial | ✓ (fwd) |
| EB | TIGON | At \(\tau=0.25\) | ✗ (worst) |
| hESC | MFL | No | ✓ (fwd) |
| hESC | TIGON | At \(\tau=0.25\) | ✗ (worst) |
Problem: Marginal-based TI evaluation is fundamentally limited by non-identifiability and inconsistency
Theoretical contribution: FKL — a tractable KL estimator between probability measures on function space: \[\mathrm{KL}(\nu^A \| \nu^B) = \int_0^1 \int_{\mathcal{H}} \frac{t}{1-t} \|v^A_t(x) - v^B_t(x)\|^2_{\mathcal{H}_{\mu_0}} \,d\mu^A_t\,dt\]
Empirical finding: Five standard marginal metrics yield inconsistent, often misleading rankings
Take-home message: FKL provides a coherent evaluation metric aligned with visual inspection and quantifies differences in dynamics between trajectory distributions
Thank you!
Paper: Relative Entropy Estimation in Function Space: Theory and Applications to Trajectory Inference
WANG Chao, NEPOTE Luca, FRANZESE Giulio, MICHIARDI Pietro — EURECOM
Preliminary work under review at ICML.