arXiv:2610.24258cs.LGOct 2026

Manuscript Offprint

arXiv:2610.24258

Dynamic Neural Optimal Transport for Subset Alignment

Austin J. Brockmeier, Bilal Riaz

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

ABSTRACT

We study optimal transport between distributions when only a subset of the target population is relevant to the source. The goal is to map the source distribution to a reweighted target distribution whose density ratio with respect to the full target lies in [0,c][0, c]. This constraint enables the transported distribution to select an appropriate target subpopulation while limiting how strongly any region of the target can be emphasized. We propose a dynamic neural optimal transport framework for this setting using two neural networks. The first parameterizes a time-dependent potential whose spatial gradient defines the velocity field and whose terminal value enforces the density-ratio constraint. The second parameterizes an interpolation between the source distribution and the learned terminal distribution. Unlike prior neural dynamic optimal transport methods, which typically assume a fixed terminal distribution, our formulation learns the terminal distribution within the support of the target. We demonstrate the method on positive-unlabeled learning, unpaired domain translation, and trajectory inference, where meaningful alignments exist between source and target distributions, but direct distribution matching is inappropriate because the target contains additional or irrelevant components.

1 Introduction

Distribution alignment is a problem of immense importance across machine learning, statistics, and optimization. Wasserstein distance and ff-divergences are two widely used families of measures of disparity between distributions. Given source and target distributions μ\mu and ν\nu defined on subsets of a convex set Ω⊆Rd\Omega \subseteq \mathbb{R}^d, specifically on supp⁡(μ)\operatorname{supp}(\mu) and supp⁡(ν)\operatorname{supp}(\nu), respectively, the objective of optimal transport is to obtain a mapping T:supp⁡(μ)→supp⁡(ν)T : \operatorname{supp}(\mu) \to \operatorname{supp}(\nu) from the source distribution to the target distribution that minimizes the expected transport cost, thereby characterizing the Wasserstein distance. This can be relaxed by mapping the source to a distribution near the target, using an ff-divergence to quantify the disparity between the output of the map and the target distribution. In particular, we consider a dynamic deterministic formulation of TT that uses a neural network to parameterize the velocity field. We also use a particular choice of ff-divergence that constrains the mapped density to lie within a subset of supp⁡(ν)\operatorname{supp}(\nu) while satisfying a prescribed density-ratio bound. While previous work has studied relaxed neural optimal transport with static transport maps (Gazdieva et al., 2023; Choi et al., 2023, 2024a) and unbalanced dynamic optimal transport with mass growth (Neklyudov et al., 2023b), there is no existing neural dynamic optimal transport (OT) formulation that learns a map from the source distribution to a subset of the target distribution.

Specifically, our formulation of support subset alignment relies on a relaxation of the Benamou-Brenier problem, formulated in terms of a probability path ρt\rho_t and velocity field vt\mathbf{v}_t (Benamou & Brenier, 2000; Santambrogio, 2015;

∗^{*}Research was sponsored by the Department of the Navy, Office of Naval Research under ONR award numbers N00014-21-1-2300 and N00014-24-1-2259. Any opinions, findings, and conclusions or recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of the Office of Naval Research.

†^{\dagger}bilalria@udel.edu

‡^{\ddagger}ajbrock@udel.edu

A PREPRINT

Figalli & Glaudo, 2023). For probability measures μ,ν∈P(Ω)\mu, \nu \in \mathcal{P}(\Omega), the semi-relaxed dynamic OT problem we study is

inf⁡ρt,vt∫01Ex∼ρt[12∥vt(x)∥2]dt,s.t.∂tρt(x)+div(ρt(x)vt(x))=0,ρ0=μ,ρ1≤cν,(1)\inf_{\rho_{t},\mathbf{v}_{t}}\int_{0}^{1}\mathbb{E}_{\mathbf{x}\sim\rho_{t}}\left[\frac{1}{2}\|\mathbf{v}_{t}(\mathbf{x})\|^{2}\right]dt,\quad s.t.\quad\partial_{t}\rho_{t}(\mathbf{x})+\mathrm{div}(\rho_{t}(\mathbf{x})\mathbf{v}_{t}(\mathbf{x}))=0,\rho_{0}=\mu,\rho_{1}\leq c\nu, \tag{1}

where the initial marginal constraint ρ0=μ\rho_0 = \mu is preserved, whereas the terminal marginal ρ1\rho_1 is allowed to vary subject to the density-ratio constraint ρ1/ν∈[0,c]\rho_1/\nu \in [0, c]. This allows some regions of supp(ν)\text{supp}(\nu) to be up-weighted while others are down-weighted or removed. The relaxed terminal constraint is equivalent to a partial optimal transport relaxation of static optimal transport using ff-divergences, as introduced by Séjourné et al. (2023). The case c=1c = 1 corresponds to prescribing the endpoint marginal as ρ1=ν\rho_1 = \nu. Under suitable regularity, weak solutions of the continuity equation induce deterministic flows via mass conservation (Villani et al., 2009, p. 15), while locally Lipschitz flows induce unique probability paths (Villani, 2021, Theorem 5.34).

In practice, when only samples are available, we use neural networks to parameterize both the velocity field vtv_t and the probability path ρt\rho_t. Dynamic neural OT is closely connected to flow matching, diffusion-type models, trajectory inference, and generative modeling (Lipman et al., 2023; Liu et al., 2023; Albergo & Vanden-Eijnden, 2023; Tong et al., 2020; Neklyudov et al., 2023a,b).

To position our formulation, we introduce necessary notation and discuss unbalanced optimal transport (UOT) and the dynamic version. Let P(X)\mathcal{P}(\mathcal{X}) and M+(X)\mathcal{M}_+(\mathcal{X}) denote probability and finite nonnegative measures on X⊆Ω\mathcal{X} \subseteq \Omega. For a map SS, S#μS_{\#} \mu is the pushforward; for π∈M+(X×Y)\pi \in \mathcal{M}_+(\mathcal{X} \times \mathcal{Y}), (pr⁡X)#π(\operatorname{pr}_{\mathcal{X}})_{\#} \pi and (pr⁡Y)#π(\operatorname{pr}_{\mathcal{Y}})_{\#} \pi are its marginals. We write ν~≪ν\tilde{\nu} \ll \nu if ν(A)=0⇒ν~(A)=0\nu(A) = 0 \Rightarrow \tilde{\nu}(A) = 0. When absolutely continuous, we use the same symbol for a measure and its density; thus, if dν~=ν~(x)dxd\tilde{\nu} = \tilde{\nu}(\mathbf{x}) d\mathbf{x} and dν=ν(x)dxd\nu = \nu(\mathbf{x}) d\mathbf{x}, then dν~/dν=ν~/νd\tilde{\nu}/d\nu = \tilde{\nu}/\nu on {ν>0}\{\nu > 0\}. We use ρt\rho_t, vt\mathbf{v}_t, and gtg_t for time-varying measures, velocity fields, and growth fields, respectively, and E\mathbb{E} for expectations under probability measures.

Unbalanced optimal transport (UOT) generalizes balanced OT (Santambrogio, 2015) by allowing transport between finite nonnegative measures μ∈M+(X)\mu \in \mathcal{M}_+(\mathcal{X}) and ν∈M+(Y)\nu \in \mathcal{M}_+(\mathcal{Y}) for which μ(X)\mu(\mathcal{X}) and ν(Y)\nu(\mathcal{Y}) need not be equal. Let f1,f2:R+→R∪{+∞}f_1, f_2 : \mathbb{R}_+ \to \mathbb{R} \cup \{+\infty\} be proper, convex, lower semicontinuous functions satisfying f1(1)=f2(1)=0f_1(1) = f_2(1) = 0. Given π∈M+(X×Y)\pi \in \mathcal{M}_+(\mathcal{X} \times \mathcal{Y}), define μ~=(pr⁡X)#π\tilde{\mu} = (\operatorname{pr}_{\mathcal{X}})_{\#} \pi and ν~=(pr⁡Y)#π\tilde{\nu} = (\operatorname{pr}_{\mathcal{Y}})_{\#} \pi. The UOT problem is then stated as (Frogner et al., 2015; Séjourné et al., 2023)

WUOT{f1,f2}(μ,ν)=inf⁡π∈M+(X×Y)∫X×Yc(x,y)dπ(x,y)+γ1Df1(μ~∥μ)+γ2Df2(ν~∥ν),(2)\mathcal{W}_{\mathrm{U O T}}^{\{f_{1},f_{2}\}}(\mu,\nu)=\inf_{\pi\in\mathcal{M}_{+}(\mathcal{X}\times\mathcal{Y})}\int_{\mathcal{X}\times\mathcal{Y}}\mathbf{c}(\mathbf{x},\mathbf{y})d\pi(\mathbf{x},\mathbf{y})+\gamma_{1}\mathcal{D}_{f_{1}}(\tilde{\mu}\|\mu)+\gamma_{2}\mathcal{D}_{f_{2}}(\tilde{\nu}\|\nu), \tag{2}

where γ1,γ2>0\gamma_1, \gamma_2 > 0, and Df1\mathcal{D}_{f_1} and Df2\mathcal{D}_{f_2} denote the ff-divergences corresponding to f1f_1 and f2f_2, respectively. Even when μ\mu and ν\nu are probability measures, the optimal solution of equation 2 is generally not a coupling of μ\mu and ν\nu. Thus, UOT relaxes the strict marginal equality constraints of OT by replacing them with ff-divergence penalties, making it applicable to general finite nonnegative measures. UOT has also been used to estimate transport maps TT using neural network parameterizations (Yang & Uhler, 2019; Choi et al., 2023, 2024a; Gazdieva et al., 2023, 2024).

Dynamic UOT handles general positive measures by explicitly modeling mass creation and destruction through a scalar growth field gtg_t (Chizat et al., 2018b,a), and has been applied to problems in generative modeling and trajectory inference (Neklyudov et al., 2023a,b, 2024). Dynamic UOT between μ,ν∈M+\mu, \nu \in \mathcal{M}_+ is

inf⁡ρt,vt,gt∫01∫Ω[∥vt(x)∥2+gt2(x)2]dρt(x)dt,s.t.∂∂tρt(x)+div(ρt(x)vt(x))=gt(x)ρt(x),ρ0=μ,ρ1=ν.(3)\inf_{\rho_{t},\mathbf{v}_{t},g_{t}}\int_{0}^{1}\int_{\Omega}\left[\frac{\left\|\mathbf{v}_{t}(\mathbf{x})\right\|^{2}+g_{t}^{2}(\mathbf{x})}{2}\right]d\rho_{t}(\mathbf{x})dt,\text{s.t.}\frac{\partial}{\partial t}\rho_{t}(\mathbf{x})+\mathrm{div}(\rho_{t}(\mathbf{x})\mathbf{v}_{t}(\mathbf{x}))=g_{t}(\mathbf{x})\rho_{t}(\mathbf{x}),\rho_{0}=\mu,\rho_{1}=\nu. \tag{3}

Thus, UOT penalizes deviations from prescribed marginals, whereas dynamic UOT modifies the continuity equation through a mass growth term. When μ\mu and ν\nu are probability measures and mass creation/destruction is not needed, one may set gt=0g_t = 0, recovering balanced dynamic OT.

Positioning and contributions. Unlike UOT, which allows positive measures and relaxes marginal constraints, and dynamic UOT, which models mass creation/destruction but preserves marginals, our dynamic subset alignment preserves the source mass and transports it to a terminal distribution supported on a subset of the target support and within a density-ratio bound of the target. This is achieved by replacing the terminal marginal equality constraint with an f-divergence-based penalty, which recovers balanced OT as a special case. We derive a dual dynamic formulation whose potential identifies the selected target subset and whose gradient defines the transport velocity. We use neural network-based parameterizations of the velocity field and path distribution to achieve the alignment and subset selection. Furthermore, we demonstrate the framework on unpaired domain translation, PU-learning, and trajectory inference problems.

References (100)

Couldn't load all references. Reload the page to try again.