Table of Contents
Fetching ...

TeraSim: Uncovering Unknown Unsafe Events for Autonomous Vehicles through Generative Simulation

Haowei Sun, Xintao Yan, Zhijie Qiao, Haojie Zhu, Yihao Sun, Jiawei Wang, Shengyin Shen, Darian Hogue, Rajanikant Ananta, Derek Johnson, Greg Stevens, Greg McGuire, Yifan Wei, Wei Zheng, Yong Sun, Yasuo Fukai, Henry X. Liu

TL;DR

TeraSim addresses the insufficiency of existing AV simulators to reliably uncover unknown unsafe events and to provide scalable, statistically sound crash-rate estimates. It combines a Naturalistic Driving Environment (NDE) with a Naturalistic and Adversarial Driving Environment (NADE) in an API-driven co-simulation framework, enabling realistic long-horizon traffic while adversarially amplifying rare but critical events. The framework demonstrates the ability to reveal hidden failure modes and to produce quantitative crash-rate metrics, validated through large-scale demonstrations with CARLA and Autoware in a real-world testing facility. By being open-source and integration-friendly, TeraSim aims to become a practical tool for researchers, developers, and policymakers to strengthen AV safety evaluation and standardization efforts.

Abstract

Traffic simulation is essential for autonomous vehicle (AV) development, enabling comprehensive safety evaluation across diverse driving conditions. However, traditional rule-based simulators struggle to capture complex human interactions, while data-driven approaches often fail to maintain long-term behavioral realism or generate diverse safety-critical events. To address these challenges, we propose TeraSim, an open-source, high-fidelity traffic simulation platform designed to uncover unknown unsafe events and efficiently estimate AV statistical performance metrics, such as crash rates. TeraSim is designed for seamless integration with third-party physics simulators and standalone AV stacks, to construct a complete AV simulation system. Experimental results demonstrate its effectiveness in generating diverse safety-critical events involving both static and dynamic agents, identifying hidden deficiencies in AV systems, and enabling statistical performance evaluation. These findings highlight TeraSim's potential as a practical tool for AV safety assessment, benefiting researchers, developers, and policymakers. The code is available at https://github.com/mcity/TeraSim.

TeraSim: Uncovering Unknown Unsafe Events for Autonomous Vehicles through Generative Simulation

TL;DR

TeraSim addresses the insufficiency of existing AV simulators to reliably uncover unknown unsafe events and to provide scalable, statistically sound crash-rate estimates. It combines a Naturalistic Driving Environment (NDE) with a Naturalistic and Adversarial Driving Environment (NADE) in an API-driven co-simulation framework, enabling realistic long-horizon traffic while adversarially amplifying rare but critical events. The framework demonstrates the ability to reveal hidden failure modes and to produce quantitative crash-rate metrics, validated through large-scale demonstrations with CARLA and Autoware in a real-world testing facility. By being open-source and integration-friendly, TeraSim aims to become a practical tool for researchers, developers, and policymakers to strengthen AV safety evaluation and standardization efforts.

Abstract

Traffic simulation is essential for autonomous vehicle (AV) development, enabling comprehensive safety evaluation across diverse driving conditions. However, traditional rule-based simulators struggle to capture complex human interactions, while data-driven approaches often fail to maintain long-term behavioral realism or generate diverse safety-critical events. To address these challenges, we propose TeraSim, an open-source, high-fidelity traffic simulation platform designed to uncover unknown unsafe events and efficiently estimate AV statistical performance metrics, such as crash rates. TeraSim is designed for seamless integration with third-party physics simulators and standalone AV stacks, to construct a complete AV simulation system. Experimental results demonstrate its effectiveness in generating diverse safety-critical events involving both static and dynamic agents, identifying hidden deficiencies in AV systems, and enabling statistical performance evaluation. These findings highlight TeraSim's potential as a practical tool for AV safety assessment, benefiting researchers, developers, and policymakers. The code is available at https://github.com/mcity/TeraSim.

Paper Structure

This paper contains 24 sections, 1 equation, 4 figures.

Figures (4)

  • Figure 1: TeraSim Architecture.
  • Figure 2: Panoramic view across different simulators with synchronized traffic. (a). TeraSim traffic generation. (b). Mcity real world. (c). Mcity CARLA digital twin. (d). Autoware Universe.
  • Figure 3: Example adversity generation. (a) Construction zone. (b) Vehicle adversity. (c) Cyclist adversity. (d) Pedestrian adversity.
  • Figure 4: A collision scenario in TeraSim with an Autoware-controlled AV. An aggressive cut-in triggers abrupt braking of AV, followed by cautious acceleration and a rear-end collision. The top row shows CARLA’s car-following view, while the bottom row presents Autoware’s bird’s-eye view. Corresponding columns capture the same timestamp. The sequence unfolds from (a) to (e).