SafeGen: Goal-Conditioned Video Diffusion of Safety-Critical Scenarios for VLM-Based Autonomous Driving

Jiangfan Liu, Zexuan Cui, Tianyuan Zhang, Zonglei Jing, Zonghao Ying, Yaoyuan Zhang, Jiakai Wang, Xiaoqi Jiang, Aishan Liu, Xianglong LiuarXiv 2026

TL;DR

SafeGen is a novel goal-conditioned video diffusion framework designed to rigorously test Vision-Language Model-based Autonomous Driving (VLMAD) systems by generating realistic, safety-critical scenarios. By anchoring a catastrophic end-state (like a collision) and generating the video trajectory backward, SafeGen creates physically plausible and temporally coherent edge cases that expose deep reasoning flaws in modern driving models.

What Problem Does This Paper Address?

Vision-Language Models (VLMs) are increasingly being integrated into autonomous driving (AD) systems due to their impressive open-world reasoning capabilities. However, evaluating how these VLMADs handle rare, high-risk scenarios—particularly interactions with Vulnerable Road Users (VRUs) like pedestrians or cyclists—remains a massive challenge.

Traditional safety testing relies heavily on simulators. Unfortunately, simulators suffer from a severe "sim-to-real gap": their synthetic textures look fake, and their rigid, pre-programmed agent behaviors fail to capture the chaotic, nuanced dynamics of real-world human-vehicle interactions. On the flip side, standard generative video models are too open-ended; you cannot easily force them to generate a specific, precise collision to stress-test a system. SafeGen bridges this gap by generating photorealistic, safety-critical videos directly from real-world benign driving logs.

Methods

SafeGen treats scenario generation as a boundary-conditioned state-evolution problem. Instead of predicting the future from the first frame forward, it determines a dangerous outcome and fills in the blanks. The framework operates in two primary phases:

  1. Context Grounded End State Reasoning: SafeGen uses a VLM to analyze a benign driving video alongside spatial priors (depth maps and semantic segmentation). The VLM identifies latent vulnerabilities in the scene (e.g., an occlusion zone) and selects a critical last frame. It then generates a structured "catastrophic end-state specification" ($\mathbf{s}$), which includes a description of the adversarial scenario, a detailed portrait of the VRU, and a target placement region.
  2. End State Conditioned Video Evolution: A text-to-image diffusion model generates the adversarial VRU based on the VLM's description. SafeGen then uses depth-aware geometric projection to place this agent into the scene at an optimal coordinate that minimizes the Time-to-Collision (TTC). After seamlessly blending the agent into the final frame using multi-round inpainting, a boundary-conditioned video diffusion model (First-Last-Frame-to-Video, or FLF2V) interpolates the intermediate frames. This ensures the video smoothly and realistically evolves from a safe driving state into a collision.
Figure 2: Overview of the proposed SafeGen framework for safety-critical scenario video generation.

Datasets

The authors evaluated SafeGen using the following datasets:

  • nuScenes: A standard, large-scale real-world driving dataset. SafeGen used benign driving logs from nuScenes to generate 850 distinct safety-critical evaluation scenarios.
  • VRU-Accident: An independent, unseen benchmark dataset containing real-world human-vehicle accidents from various camera viewpoints (including third-person perspectives). This was used to test if fine-tuning a model on SafeGen-generated data actually improves its real-world safety reasoning.

Key Insights and Ideas

  • The Power of Backward Generation: Standard forward-prediction models naturally gravitate toward safe, high-probability trajectories. By deterministically anchoring a catastrophic end-state as a strong supervisory signal, SafeGen forces the video generation process to naturally escalate threats in a kinematically plausible way.
  • Semantic Blending Bypasses Anomaly Detection: Because SafeGen's VLM tailors the adversarial agent to the context (e.g., putting a pedestrian in a safety vest within a construction zone), the generated agents blend perfectly into the environment. They don't trigger simple visual anomaly alarms in the driving models; instead, they exploit high-level semantic and planning blind spots.
Figure 3: Safety-critical scenario videos generated by SafeGen across construction, rain, and different traffic orientations.
  • Cascading Failures: SafeGen doesn't just cause isolated perception errors. By compressing the reaction window (TTC < 0.5s) and forcing extreme deceleration requirements, it induces cascading failures across the entire perception, prediction, and planning pipeline of VLMADs.

Key Results

The authors evaluated SafeGen against three representative VLMADs (Dolphins, DriveLMM-o1, and EM-VLM4AD) and compared it to state-of-the-art baselines like ScenGE and AdvSim.

  • Efficacy in Exposing Flaws: SafeGen improved the Judge Overall Score (JOS)—a metric that uses a high-capacity VLM to evaluate an AD agent's understanding and decision-making—by an average of 24.25% across all tested models, proving it is significantly better at finding critical safety flaws.
  • Downstream Utility: Fine-tuning the Dolphins VLMAD on SafeGen-generated data led to a 15.9% average improvement in accuracy on the unseen real-world VRU-Accident dataset.
  • Human Validation: In a human-in-the-loop simulator study with 30 licensed drivers, SafeGen's scenarios were rated as substantially more realistic and behaviorally plausible than simulator-based baselines, successfully inducing genuine surprise and safety pressure.

Limitations and Future Work

While highly effective, SafeGen currently focuses primarily on single-agent (VRU) interactions. Real-world traffic often involves complex, multi-agent dynamics (e.g., multiple aggressive vehicles and pedestrians interacting simultaneously). The authors note that extending this goal-conditioned diffusion framework to multi-agent settings is a key direction for future work. Additionally, a slight viewpoint mismatch exists when transferring data to benchmarks that include third-person perspectives, which slightly limits absolute performance ceilings during downstream fine-tuning.

Summary updated

BibTeX
@misc{liu2026safegen,
  author = {Jiangfan Liu and Zexuan Cui and Tianyuan Zhang and Zonglei Jing and Zonghao Ying and Yaoyuan Zhang and Jiakai Wang and Xiaoqi Jiang and Aishan Liu and Xianglong Liu},
  title = {{SafeGen: Goal-Conditioned Video Diffusion of Safety-Critical Scenarios for VLM-Based Autonomous Driving}},
  year = {2026},
  eprint = {2607.19701},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2607.19701},
}
Figure