Abstract
As self-driving systems become better, simulating scenarios where the autonomy stack may fail becomes more important. Traditionally, those scenarios are generated for a few scenes with respect to the planning module that takes ground-truth actor states as input. This does not scale and cannot identify all possible autonomy failures, such as perception failures due to occlusion. In this paper, we propose AdvSim, an adversarial framework to generate safety-critical scenarios for any LiDAR-based autonomy system. Given an initial traffic scenario, AdvSim modifies the actors' trajectories in a physically plausible manner and updates the LiDAR sensor data to match the perturbed world. Importantly, by simulating directly from sensor data, we obtain adversarial scenarios that are safety-critical for the full autonomy stack. Our experiments show that our approach is general and can identify thousands of semantically meaningful safety-critical scenarios for a wide range of modern self-driving systems. Furthermore, we show that the robustness and safety of these systems can be further improved by training them with scenarios generated by AdvSim.
Introduction
Testing self-driving vehicles (SDVs) in the real world is expensive, dangerous, and often fails to encounter the "long tail" of rare, high-risk events. While simulation is a standard alternative, most existing simulators focus on standard traffic conditions where modern autonomy stacks already perform well. To ensure true safety, we must find the edge cases where systems fail. AdvSim addresses this by automatically generating thousands of physically realistic, safety-critical scenarios to push self-driving systems to their limits.
The Challenge of Safety-Critical Simulation
Traditional methods for generating safety-critical scenarios often suffer from two major flaws:
- Ignoring Perception: Many simulators assume the SDV has perfect knowledge of actor states. In reality, crashes often stem from perception failures, such as a vehicle being hidden behind an obstacle (occlusion).
- Physical Unreality: Automated attacks on SDV planners frequently create "teleporting" cars or impossible maneuvers that would never occur in the real world, rendering the test results less meaningful.
AdvSim overcomes these hurdles by simulating directly from raw sensor data (LiDAR) and ensuring all adversarial maneuvers follow the laws of physics.
Methodology
AdvSim treats the self-driving system as a black box, requiring only the planned trajectory output rather than internal code access. The framework follows a four-step pipeline:
- Trajectory Perturbation: Real traffic logs are modified by altering the path of an "actor of interest." To maintain realism, a kinematic bicycle model is used to ensure the new path respects physical limits on acceleration and steering.
- Realistic LiDAR Simulation: Instead of simply moving a 3D bounding box, AdvSim re-renders the point cloud. It removes the actor from its original position, fills the resulting "shadow," and places the actor in its new position, correctly recalculating occlusions and sensor reflections.
- Adversarial Optimization: Using black-box optimization (such as Bayesian Optimization), the system searches for maneuvers that maximize a "failure cost," which includes collisions, traffic rule violations, and high-jerk driving.
- Full-Stack Evaluation: By updating the LiDAR data, AdvSim tests the SDV’s perception, forecasting, and planning modules simultaneously.
Key Results and Insights
AdvSim was evaluated using the UrbanScenarios dataset, identifying over 4,000 safety-critical scenarios across 5,000 driving logs. Key findings include:
- Perception as a Vulnerability: Many successful adversarial attacks were not just about aggressive maneuvers but about moving in ways that caused the SDV's perception system to lose track of actors due to new occlusions.
- Increased Collision Rates: On modern planners like P3 and NMP, AdvSim increased collision rates from approximately 10% in original data to between 30% and 42%.
- Robust Training: Integrating AdvSim-generated scenarios into the training process significantly improved safety. For the P3 model, the collision rate on adversarial tests dropped from 32.0% to 17.7% without sacrificing performance in normal traffic.
- Transferability: Scenarios that caused failures in modular autonomy stacks often caused failures in end-to-end neural planners, suggesting that certain traffic configurations are inherently difficult for current AI architectures.
Conclusion
AdvSim demonstrates that high-fidelity sensor simulation combined with physically constrained adversarial optimization can uncover thousands of failure modes in modern autonomy stacks. By attacking the full stack rather than just the planner, AdvSim provides a more realistic and rigorous testing ground, ultimately leading to more robust and safer self-driving systems.
Summary updated