Normalizing Flows are Capable Trajectory Planners

Zhaohui Wang, Bo Xu, Yingzhi Tang, He Liu, Chen BaiNeurIPS 2026

TL;DR

While autonomous driving has embraced Diffusion and Flow Matching to predict human-like paths, these models are sluggish, mathematically opaque, and run on one-way streets. This paper brings Normalizing Flows out of retirement to build BiDrive—a real-time (50 FPS) trajectory planner that calculates exact probabilities for its decisions and uses invertible math to instantly "nudge" dangerous paths to safety at test time.

What Problem Does This Paper Address?

Human driving is inherently multimodal: at an intersection, turning left or going straight can both be valid, while splitting the difference puts you into a lamppost. Early deterministic models struggled with this, averaging valid paths into disastrous compromises.

Recently, the field turned to generative heavyweights like Diffusion Models and Flow Matching to capture diverse driving behaviors. While great at generating options, they hit a practical "trilemma" when deployed on real cars:

  1. High Latency: Multi-step iterative denoising is too slow for split-second highway reactions.
  2. Intractable Probabilities: Because they cannot output the exact mathematical likelihood of a generated path, engineers have to slap on brittle, ad-hoc heuristic rules to pick the "best" trajectory.
  3. Irreversibility: Their mapping from noise to data is a one-way street. If a sampled trajectory clips a curb, you can't analytically map that error back to fix it—you essentially have to roll the dice again.
Figure 1: Comparison of different generative trajectory planning paradigms. (a) Perceptual de- coupled learning-based model. (b) Previous methods rely on multi-step iterative generation and their generative mapping is fundamentally irreversible. (c) In contrast, BiDrive introduces NFs into end-to-end autonomous driving. It inherently achieves one-step generation and its strict bijection of NFs establishes invertible mapping.

Normalizing Flows (NFs)—models built on chains of strictly invertible, differentiable functions—theoretically solve both probability tracking and reversibility. However, expressive NFs have historically been ignored in planning because decoding them point-by-point (autoregressively) is just as slow as diffusion.

Methods

The authors introduce BiDrive, the first Normalizing Flow-based end-to-end autonomous planner, built in three distinct stages:

  • The Probabilistic Teacher (TarDrive): First, standard multi-view camera and vehicle-status encoders extract scene context. Conditioned on this context, a Masked Autoregressive Flow (MAF) learns to map human trajectories into Gaussian mixture noise via causal masked attention. Thanks to the change-of-variables theorem, it computes exact log-likelihoods during training, replacing heuristic trajectory scoring with rigorous Maximum Likelihood Estimation (MLE).
  • Bidirectional Knowledge Distillation: Because TarDrive decodes paths sequentially, it runs at a sluggish 16 FPS. To break this bottleneck, the authors train a parallel, one-step Inverse Autoregressive Flow (IAF) student network. By aligning the student's hidden states and probability density dynamics with the teacher's in reverse order, they compress the expressive prior into a single-pass generator.
  • Invertible Trajectory Refinement: Because BiDrive is a strict mathematical bijection (a clean two-way street between latent noise and physical trajectories), it unlocks analytical test-time optimization. The authors define differentiable physics rewards—penalizing collisions and uncomfortable jerks while encouraging forward speed—and backpropagate gradients directly into the Gaussian latent space ($\Delta z$). Two quick gradient-ascent steps smoothly bend a risky trajectory into a safe, compliant one without any extra training.
Figure 2: Overall architecture of the proposed BiDrive. (a) During training, a Masked Autoregressive Flow maps human trajectories into a Gaussian mixture noise, providing exact likelihoods. (b) We distill the autoregressive MAF teacher into a one-step IAF student for real-time inference. (c) The strict bijection enables test-time latent refinement via physical rewards for safe trajectory correction.

Datasets

The authors evaluate their models on two closed-loop autonomous driving benchmarks:

  • NAVSIMv1 (navtest): Used to benchmark overall safety, comfort, ego progress, and Predictive Driver Model Score (PDMS).
  • NAVSIMv2 (navtest): A reactive closed-loop benchmark designed to test error-recovery capabilities in highly dynamic traffic scenarios, evaluated via Extended PDMS (EPDMS).

(Note: Underlying training split specifics are deferred to the paper's appendix and not detailed in the main text.)

Key Insights and Ideas

  • Exact Likelihood Beats Heuristics: Instead of guessing which sampled path is best using hand-crafted anchor rules, NFs let the planner isolate top candidates and select the exact trajectory sitting at the highest probability density of human behavior.
  • Physics in Latent Space: Because the mapping is invertible, test-time safety checks don't require "regenerate-and-test" fallbacks. Differentiable repulsion fields around nearby cars translate directly into tiny nudges in latent noise, reshaped back into smooth trajectories—provided you regularize the update so it doesn't drift out of the Gaussian prior.
  • Goldilocks Refinement: More test-time optimization isn't always better. Pushing latent refinement past 2 iterations to 3 actually drops overall performance: the car over-optimizes for safety buffers and becomes timid, hurting forward progress.
  • Distillation Fixes Sequential Drift: Compressing the autoregressive teacher into a one-step student didn't just triple the frame rate; it boosted accuracy by eliminating the sequential error accumulation that plagues point-by-point decoding.

Key Results

BiDrive achieves state-of-the-art performance while running purely on camera inputs—outperforming heavier baselines that rely on both cameras and LiDAR:

  • Speed & Efficiency: Distillation accelerates inference from TarDrive's 16 FPS to 50 FPS (34.2 GFlops, 52M parameters).
  • NAVSIMv1: BiDrive hits 90.0 PDMS, beating camera+LiDAR generative planners like GoalFlow (85.7) and DiffusionDrive (88.1), as well as vision-only MeanFuser (89.0). Adding reinforcement learning (BiDrive-RL) pushes this to 91.4 PDMS.
  • NAVSIMv2: BiDrive reaches 86.4 EPDMS (and 86.8 with RL), outperforming DiffusionDrive (84.8) and MeanFuser (86.0) in reactive traffic.
  • Qualitative Edge: In complex geometries like roundabouts and dense traffic, baselines produce jagged or prematurely truncated paths, whereas BiDrive hugs lane centerlines smoothly and maintains confident forward progress.
Figure 3: Visualization of trajectories on bird’s eye view. × indicates that the trajectory is away from the center line or not smooth, while ✓represents an accurate trajectory. The results highlight that BiDrive generates higher-quality trajectories compared to other methods. Û Zoom in for details.

Limitations and Future Work

The authors note two main hurdles. First, the foundational TarDrive model is slow and suffers from sequential error accumulation during autoregressive decoding. Second, while BiDrive fixes both speed and accuracy, its training pipeline is still tethered to that pre-trained TarDrive teacher. For future work, the team plans to explore teacher-free, single-pass Normalizing Flow architectures and push for even richer multimodal diversity in complex driving scenarios.

Summary updated

Abstract

Generative models such as Diffusion Models and Flow Matching have improved multimodal trajectory planning in autonomous driving, but still suffer from inference latency and the lack of tractable probability densities, relying on heuristic trajectory selection. We propose BiDrive, a real-time end-to-end planning framework based on Normalizing Flows (NFs). By leveraging invertibility and exact likelihood estimation, BiDrive directly evaluates trajectory probabilities in a single forward pass, enabling principled maximum-likelihood-based decision making. To address the autoregressive bottleneck of expressive flows, we further develop a bidirectional distillation framework that compresses an autoregressive flow into a one-pass generator, achieving real-time inference (50 FPS) while preserving modeling capacity. The autoregressive model is used only during training as a probabilistic teacher. In addition, we introduce a latent-space optimization mechanism that incorporates differentiable safety and dynamic constraints for efficient test-time trajectory refinement. Experiments on NAVSIM closed-loop benchmarks demonstrate state-of-the-art performance in both safety and efficiency, highlighting the potential of Normalizing Flows for real-time trajectory planning.
BibTeX
@inproceedings{wang2026normalizing,
  author = {Zhaohui Wang and Bo Xu and Yingzhi Tang and He Liu and Chen Bai},
  title = {{Normalizing Flows are Capable Trajectory Planners}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=dQpk6rwXp8},
}
Figure