NeurIPS 2026
Temporal Gradient Inversion for Private Trajectory Reconstruction in Embodied Reinforcement Learning
Sudip Bhujel1, Shanghao Shi2, Ruiquan Huang1, Ning Zhang2, Yang Xiao1
1University of Kentucky2Washington University in St. Louis
Abstract
Distributed learning in embodied reinforcement-learning agents offers a degree of privacy by retaining raw sensor data on-device and transmitting only policy gradients to the server. Yet temporal structure can amplify this leakage beyond single-frame attacks. We introduce Temporal Reconstruction Attack on Consecutive Encodings (TRACE), an amortized temporal gradient-inversion attack that autoregressively reconstructs the sequence of private observation-action trajectories from per-step policy-learning gradients.
The attack exploits two structural signals ignored by prior single-frame methods: (i) cross-time correlation between successive embodied gradients, which we formalize via a conditional mutual-information bound, and (ii) closed-form action recovery from policy-head gradient structure, which we prove exact when standard entropy regularization is sufficiently small. On held-out embodied scenes, TRACE reaches 18.8 dB PSNR with near-perfect action recovery at 3–4.5 ms per reconstructed frame, dominating the learning-based baseline across all reconstruction metrics and exceeding optimization attacks while running orders of magnitude faster. Further evaluation demonstrates TRACE's broader applicability across recurrent, residual, and compact transformer victim architectures, multi-modal inputs, and larger discrete action spaces. Defense experiments suggest that protecting temporal gradient streams may require sequence-aware privacy mechanisms.
Trajectory leakage

Why a stream leaks more than a frame
Gradient-inversion attacks have mostly been studied on a single batch: one gradient in, one image out. An embodied agent is different. It shares a gradient at every step of a trajectory, and consecutive observations come from the same room, seen from nearly the same pose.
A single-frame attacker throws that redundancy away. TRACE keeps it: each reconstruction becomes context for the next, so the attacker gets a better prior with every gradient it reads. Pixel error falls and fidelity rises as the trajectory gets longer. We call this the temporal reconstruction gain.

At a glance
18.8dB
PSNR on held-out scenes
100%
Action accuracy, PPO and A2C
3–4.5ms
Per reconstructed frame
~6,900×
Minimum speedup over optimization attacks
- Amortized and autoregressive
- A trained inverter conditions on the previous reconstruction and the current gradient to emit the next observation and action. No per-sample optimization, so a frame takes milliseconds rather than minutes.
- Two structural signals
- Cross-time correlation between successive gradients, bounded via conditional mutual information, and closed-form action recovery from the policy head, proven exact when entropy regularization is small.
- Beyond the base setting
- Holds up across recurrent, residual, and compact transformer victims, multi-modal inputs, larger discrete action spaces, and aggregated gradients.
- What it means for defenses
- Per-step perturbation is not enough. Protecting a gradient stream calls for sequence-aware privacy mechanisms.
Attack pipeline

The attacker sits at the server and receives one policy-learning gradient per environment step; it never sees the agent's camera. Because TRACE is amortized, there is no per-sample optimization: attacking a new trajectory is a single forward pass per step.
01
Gradient encoder
Compresses each per-step policy gradient into a compact latent token.
02
Image encoder
Embeds the reconstructions TRACE has already produced for earlier steps, so the model carries a visual memory of the scene.
03
Causal temporal transformer
Reads gradient tokens and image tokens interleaved in time. Causal masking means step t only sees steps up to t, matching what an online attacker would have.
04
Residual decoder and action head
Reconstructs the observation and predicts the action at every step. The action is also exposed in closed form by the policy-head gradient.
Because the inverter conditions on its own earlier reconstructions, small errors could snowball over a long rollout. Training is exposure-aware, so errors do not compound as the trajectory grows.
Results
We evaluate on point-goal navigation in AI2-THOR. The victim sees 84×84 RGB frames and picks one of five discrete actions; the attacker sees only the per-step policy gradients. Below is one held-out trajectory and what TRACE recovers from its gradient stream.
















Comparison with gradient-inversion baselines
| Method | MSE ↓ | PSNR ↑ | SSIM ↑ | LPIPS ↓ | Act. Acc. ↑ | Time / frame |
|---|---|---|---|---|---|---|
| DLG | 0.289 | 5.47 | 0.043 | 1.224 | 16.6% | 31.0 s |
| Inverting Gradients | 0.161 | 8.73 | 0.166 | 0.766 | 31.5% | 39.3 s |
| Learning to Invert | 0.023 | 16.79 | 0.529 | 0.671 | 100% | 1.2 ms |
| TRACE | 0.014 | 18.77 | 0.627 | 0.362 | 100% | 4.5 ms |
DLG and Inverting Gradients optimize a dummy input per sample; Learning to Invert is a learned single-frame inverter. All three are adapted from supervised classification with an actor-critic surrogate loss. PSNR in dB; means over held-out sequences, standard deviations are in the paper. Bold marks the best value per column.
The optimization attacks spend 30–75 seconds per frame and still land near noise. Learning to Invert is fast and gets the action right, but inverting each gradient in isolation caps its image quality. TRACE adds about 2 dB PSNR over it, raises SSIM by roughly 0.1, and nearly halves LPIPS, the perceptual distance, while staying within a few milliseconds per frame.
Generality across victims
The leakage is not an artifact of one small CNN. We retrain a separate attacker for each PPO victim below, with no data augmentation, covering a larger action space (K = 10), a compact vision transformer, residual IMPALA-style networks, a recurrent policy, and a victim with multi-modal inputs.
| Victim | K | MSE ↓ | PSNR ↑ | SSIM ↑ | LPIPS ↓ | Act. Acc. ↑ |
|---|---|---|---|---|---|---|
| CNN | 10 | 0.013 | 18.92 | 0.610 | 0.372 | 99.5% |
| Tiny ViT | 5 | 0.048 | 13.99 | 0.456 | 0.543 | 99.0% |
| IMPALA-style CNN | 5 | 0.007 | 21.85 | 0.725 | 0.244 | 97.4% |
| Wider IMPALA CNN | 5 | 0.007 | 22.36 | 0.773 | 0.208 | 98.5% |
| CNN + GRU | 5 | 0.015 | 18.62 | 0.565 | 0.390 | 97.5% |
| Multi-modal CNN | 5 | 0.011 | 19.78 | 0.697 | 0.335 | 97.4% |
K is the number of discrete actions. Bold marks the best reconstruction.
More capacity does not protect the victim. The wider IMPALA network leaks the most, reaching 22.4 dB PSNR. The Tiny ViT is the hardest case for image reconstruction, yet its actions are still recovered 99% of the time. Across every architecture, action accuracy stays above 97%.
Defenses
We test the standard per-step defenses a deployment might reach for: quantizing the gradient, pruning gradient entries, adding Gaussian noise, and DP-SGD with per-sample clipping. The question is how strong each one has to be before TRACE stops working.








































Attack quality under each defense
| Defense | Setting | MSE ↓ | PSNR ↑ | SSIM ↑ | LPIPS ↓ | Act. Acc. ↑ |
|---|---|---|---|---|---|---|
| No defense | — | 0.018 | 18.9 | 0.628 | 0.374 | 99.9% |
| Quantization | ||||||
| 8-bit | 0.020 | 18.5 | 0.619 | 0.384 | 99.9% | |
| 4-bit | 0.075 | 12.4 | 0.422 | 0.645 | 37.9% | |
| 2-bit | 0.091 | 11.3 | 0.380 | 0.689 | 19.4% | |
| Pruning (keep %) | ||||||
| 90% | 0.018 | 18.9 | 0.628 | 0.374 | 99.9% | |
| 50% | 0.018 | 18.9 | 0.628 | 0.374 | 99.9% | |
| 10% | 0.018 | 18.8 | 0.624 | 0.371 | 99.9% | |
| Gaussian noise (σ) | ||||||
| 0.001 | 0.018 | 18.8 | 0.626 | 0.376 | 99.8% | |
| 0.01 | 0.023 | 18.1 | 0.599 | 0.401 | 94.9% | |
| 0.1 | 0.049 | 14.2 | 0.438 | 0.572 | 59.9% | |
| DP-SGD (ε, δ = 10⁻⁵) | ||||||
| ε = 10 | 0.069 | 12.2 | 0.345 | 0.658 | 21.4% | |
| ε = 5 | 0.069 | 12.1 | 0.342 | 0.663 | 21.4% | |
| ε = 1 | 0.071 | 12.0 | 0.346 | 0.658 | 17.6% | |
Highlighted cells mark settings where the attack clearly degrades. Pruning settings give the fraction of gradient entries kept.
Pruning does almost nothing: keeping only 10% of the PPO gradient leaves PSNR at 18.8 dB and action accuracy at 99.9%. 8-bit quantization and σ ≤ 0.01 noise are similarly harmless. The attack only breaks under 4-bit or coarser quantization, σ = 0.1 noise, or DP-SGD, where action accuracy falls toward the 20% chance level for five actions. Protecting a gradient stream likely needs sequence-aware privacy mechanisms rather than per-step perturbation.
Citation
@inproceedings{bhujel2026trace,
title = {Temporal Gradient Inversion for Private Trajectory Reconstruction in Embodied Reinforcement Learning},
author = {Bhujel, Sudip and Shi, Shanghao and Huang, Ruiquan and Zhang, Ning and Xiao, Yang},
booktitle = {Advances in Neural Information Processing Systems (NeurIPS)},
year = {2026},
eprint = {2609.30258},
archivePrefix = {arXiv},
primaryClass = {cs.LG},
url = {https://trace-gia.github.io/}
}