Think2Drive: Efficient Reinforcement Learning by Thinking in Latent World Model for Quasi-Realistic Autonomous Driving (in CARLA-v2)

Qifeng Li, Xiaosong Jia, Shaobo Wang, Junchi YanarXiv 2024

Abstract

Real-world autonomous driving (AD), particularly in urban environments, is characterized by a "long-tail" of complex corner cases. The CARLA v2 simulator introduces 39 such common-event scenarios, providing a quasi-realistic testbed that challenges existing rule-based and model-free reinforcement learning (RL) planners. We present Think2Drive, the first model-based RL method for AD that achieves expert-level proficiency in CARLA v2. By utilizing a Recurrent State-Space Model (RSSM) as a latent world model, Think2Drive acts as a neural simulator, allowing the agent to "think" and train entirely within a compact latent space. This approach significantly boosts training efficiency, enabling expert-level performance within just three days on a single A6000 GPU. We also introduce CornerCase-Repository, a benchmark for scenario-based evaluation, and a new Weighted Driving Score (WDS) to better reflect actual driving performance.

Introduction

Autonomous driving has seen significant progress, yet navigating dense urban environments remains difficult due to unpredictable events—pedestrians emerging from blind spots, sudden braking by lead vehicles, or complex intersection maneuvers. The CARLA Leaderboard v2 (CARLA v2) was developed to address these challenges, featuring significantly longer routes and a high density of "common-event" scenarios.

Existing approaches often rely on rigid rule-based systems that fail to generalize to the diversity of CARLA v2, or model-free RL methods that are notoriously data-inefficient. Think2Drive addresses these limitations by shifting the learning process from the heavy, slow simulator into a fast, differentiable latent world model.

Methodology: Thinking in Latent Space

The core innovation of Think2Drive is the decoupling of environment perception from policy learning through a world model.

The Latent World Model (RSSM)

Think2Drive employs a Recurrent State-Space Model (RSSM) to learn the dynamics of the environment. Instead of interacting directly with the heavy CARLA simulator during every training step, the model learns to predict transitions in a low-dimensional latent space using Bird's-Eye View (BEV) semantic masks. This "neural simulator" captures the physics and logic of the driving environment, such as vehicle movements and traffic light states, much more efficiently than raw pixels.

Training the Planner

Once the world model is established, the driving policy (the planner) is trained through "imagination." The agent performs hundreds of parallel rollouts within the latent world model. This paradigm allows the agent to experience and learn from millions of simulated driving steps in a fraction of the time required by traditional simulators.

Key Technical "Bricks"

To ensure robust performance in complex scenarios, several specialized techniques were implemented:

  • Policy Reset: To prevent the agent from converging on overly conservative "local optima" (e.g., refusing to move to avoid any risk), the planner's weights are periodically re-initialized.
  • Termination-Priority Sampling: The training process prioritizes sequences leading to failures or collisions, ensuring the model learns most from its mistakes.
  • Automated Scenario Generation: Long routes are decomposed into scenario-dense snippets, maximizing the agent's exposure to critical corner cases.

Experimental Results

We evaluated Think2Drive on the newly proposed CornerCase-Repository, which includes 1,600 training and 390 evaluation routes focused on specific edge cases.

Performance comparison on the CornerCaseRepo benchmark.

As shown in the table above, Think2Drive achieves a Driving Score of 83.8, significantly outperforming the previous state-of-the-art model-free agent, Roach (57.5). Notably, Think2Drive is the first method to achieve a 100% route completion rate on the challenging CARLA v2 scenarios. The model also demonstrates superior safety, with drastically lower collision rates across pedestrians, vehicles, and layout obstacles compared to the baseline. While the primary model uses privileged information, it can successfully serve as a teacher for raw-sensor "student" models (Think2Drive + TCP).

Conclusion

Think2Drive demonstrates that model-based RL is a highly efficient and effective paradigm for autonomous driving in complex, quasi-realistic environments. By "thinking" in a latent world model, the system achieves unprecedented performance on CARLA v2 with minimal computational resources. Future work will focus on bridging the perception gap by training the world model directly from raw sensor data and expanding the diversity of scenarios to further approach real-world complexity.

Summary updated

BibTeX
@misc{li2024think,
  author = {Qifeng Li and Xiaosong Jia and Shaobo Wang and Junchi Yan},
  title = {{Think2Drive: Efficient Reinforcement Learning by Thinking in Latent World Model for Quasi-Realistic Autonomous Driving (in CARLA-v2)}},
  year = {2024},
  eprint = {2402.16720},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2402.16720},
}
Figure