Normalizing Flow Maps¶
Normalizing Flow Maps (NFM; Ruscio et al., 2026) learn a two-time invertible pushforward \(f_{s,t}\) along a prescribed probability path. The endpoint map \(f_{0,1}\) is a normalizing flow with an exact change-of-variables likelihood, while intermediate time pairs provide few-step transport.
The torchregress tabular implementation uses time-conditioned affine coupling layers. For an admissible pair \(s<t\),
The forward endpoint transports Gaussian noise to targets: \(y=f_{0,1}(z\mid c)\) with \(z\sim\mathcal N(0,I)\). Sampling uses this forward map; likelihood evaluation uses its inverse and inverse log Jacobian. Each time argument can independently be a scalar or one value per batch row.
Training combines pointwise flow-map matching,
with the endpoint NLL. This is a lean tabular instantiation, not the image-scale autoregressive NFM of the paper.
arch="tarflow" enables a more ambitious tokenized variant: explicit context
and time tokens followed by one token per target coordinate, with a causal
multi-layer Transformer and exact sequential inversion. tarflow_layers
controls the number of transformer blocks per map layer and tarflow_heads
the attention heads. This is a tabular refinement, not the image-scale
autoregressive architecture.
from torchregress.models import NormalizingFlowMap
nfm = NormalizingFlowMap(n_features=2, context_dim=64, n_layers=4)
loss = nfm.training_loss(context, target)
logp = nfm.log_prob(context, target)
samples = nfm.sample(context, n_samples=128) # [B, S, 2]
When to use it¶
| Property | NFM | standard flow | CFM |
|---|---|---|---|
| Exact conditional NLL | ✅ | ✅ | ❌ |
| Invertible at intermediate times | ✅ | ❌ | ❌ |
| Few-step transport | ✅ | composition only | ODE |
| Mature tabular implementation | newer | mature | newer |
| Noise-aware measurement model | ❌ | via NoiseAwareDensityLoss |
❌ |
NFM is a research direction for combining exact likelihoods with flow-map few-step transport. For routine tabular regression with calibrated NLL, NSF remains the safer default; test NFM when few-step/consistency behavior matters.
References¶
| # | Reference |
|---|---|
| 1 | F. M. Ruscio et al. "Normalizing Flow Maps." 2026. |
| 2 | N. M. Boffi et al. "Flow map matching with stochastic interpolants." 2024. |
| 3 | Y. Lipman et al. "Flow Matching for Generative Modeling." 2022. |