PIML-RHC as a Control Method: A Physics-Informed Transformer Policy for Real-Time Eco-Driving
A physics-informed receding-horizon Transformer trained through differentiable longitudinal vehicle dynamics, distilling mixed discrete-continuous optimal control into a single bounded forward pass.
Paper·ACC 2026 · IEEE Xplore·May 2026
Why This Matters for Your Business
- Heavy-vehicle eco-driving has to pick gears and torque over a long horizon, and it still has to finish inside a real-time budget.
- PIML-RHC trains a fixed-depth Transformer through a differentiable vehicle model, so each step is one forward pass instead of an iterative solver.
- Against real-time NMPC it holds energy and tracking, with smoother torque. Desktop inference is about 4 to 5 ms, and a Raspberry Pi 4B stays inside a 50 to 100 ms supervisory cycle.
Overview
Heavy-duty vehicle eco-driving is a constrained optimal control problem with long look-ahead horizons, mixed discrete and continuous actuation (discrete gear selection paired with continuous engine torque and braking), and strict real-time execution budgets. Classical dynamic programming suffers from state-action discretization limits, while online Nonlinear Model Predictive Control (NMPC) relies on iterative solvers whose worst-case execution time (WCET) can vary with active constraints and solver conditioning.
This paper introduces PIML-RHC, a physics-informed receding-horizon control method in which a fixed-depth Transformer policy is trained end-to-end through a differentiable longitudinal vehicle dynamics model. The policy distills long-horizon, reference-conditioned optimization into a single non-iterative forward pass with predictable per-step computation.
Read full paper on IEEE Xplore
Method summary
At each control step, the policy receives a past context window and a future preview horizon containing road grade, vehicle parameters, current speed, and a preview-based served target trajectory. It outputs a horizon plan of engine torque, braking effort, and discrete gear selections, applying the first action in receding-horizon fashion.
To train across mixed discrete and continuous actions, discrete gear choices use a straight-through Gumbel-Softmax estimator: the forward pass evaluates exact discrete gear ratios inside the physical rollout, while the backward pass routes differentiable gradients through the relaxed categorical distribution. The training objective separates tradeable performance terms (tractive energy, speed tracking, torque smoothness, and braking effort) from fixed-weight, non-negotiable physical guardrails (engine RPM operating envelope and stall prevention).
| Component | Formulation | Role in control loop |
|---|---|---|
| Policy | Fixed-depth Transformer encoder | Single-pass receding-horizon plan over torque, brake, and gear |
| Discrete gears | Straight-through Gumbel-Softmax | Exact discrete gearing in forward physics with differentiable backprop |
| Tradeable loss | Uncertainty-weighted multi-objective | Balances tractive energy, speed tracking, and torque smoothness |
| Guardrails | Fixed-weight physical penalties | Enforces RPM bounds, stall avoidance, and shift regularity |
Distilling long-horizon predictive control into a fixed-depth forward pass replaces iteration-dependent solver latency with bounded per-step execution while jointly optimizing discrete gearing and continuous propulsion.
Key findings
Evaluated across 50 multi-grade tracks against optimized real-time iteration NMPC (acados), heuristic NMPC, finite-grid dynamic programming, lookup tables, and classical P/PID baselines, PIML-RHC matches or improves upon NMPC energy efficiency and tracking accuracy while achieving substantially higher torque smoothness (drivability).
Because the policy optimizes gear shifts and continuous torque jointly through differentiable physics rather than decoupling gear scheduling into an external heuristic, it learns anticipatory coasting and smooth torque transitions across grade changes. On desktop CPU, inference completes in roughly 4 to 5 ms per step, and hardware-in-the-loop validation on an embedded Raspberry Pi 4B demonstrates real-time closed-loop execution compatible with standard 50 to 100 ms supervisory automotive control cycles.
Full manuscript and experimental details
The full formulation, curriculum schedule, multi-stage Pareto benchmarks, nonparametric statistical tests, and embedded hardware-in-the-loop timing analyses are available in the published paper on IEEE Xplore.