Improving Environment Robustness of Deep Reinforcement Learning Approaches for Autonomous Racing Using Bayesian Optimization-based Curriculum Learning

Rohan Banerjee, Prishita Ray, Mark CampbellarXiv 2023 · DOI

Abstract

Deep Reinforcement Learning (RL) agents frequently fail when encountering environmental conditions outside their training distribution. This research explores the application of Bayesian Optimization (BO) to automate the design of training curricula for autonomous racing. By treating the training schedule as an optimization problem, the authors demonstrate that a BO-driven "syllabus" significantly enhances agent robustness. In a modified CarRacing-v0 environment featuring variable track curvature and obstacles, agents trained via BO outperformed both baseline PPO and manually designed curricula, achieving higher rewards and superior safety metrics.

Introduction: The Challenge of Generalization

While Deep RL has achieved remarkable success in simulated environments, the "generalization gap" remains a significant barrier to real-world deployment. An agent trained on a simple track may fail catastrophically when faced with sharp turns or unexpected obstacles. Curriculum Learning—the strategy of presenting tasks in increasing order of difficulty—offers a potential solution. However, manually designing these curricula is often unintuitive and labor-intensive. This paper proposes an automated approach using Bayesian Optimization to discover optimal training paths.

Methodology: Automating the Syllabus

The authors frame curriculum design as a black-box optimization problem. The curriculum is represented as a series of "changepoints" over time, where environment parameters are adjusted.

  1. Bayesian Optimization (BO): Given the high computational cost of training RL agents, BO provides an efficient search mechanism. It utilizes a Gaussian Process (GP) to model the relationship between different curricula and the resulting agent performance.
  2. Acquisition Function: The Upper Confidence Bound (UCB) acquisition function is employed to balance the exploration of new training schedules with the exploitation of known high-performing ones.
  3. Base Algorithm: Proximal Policy Optimization (PPO) serves as the underlying RL algorithm, trained according to the schedules suggested by the BO framework.

Experimental Setup

The study utilizes a modified version of the OpenAI Gym CarRacing-v0 environment, a 2D top-down simulator.

The modified CarRacing-v0 environment featuring varying track curvatures and static obstacles.

The environment was modified to include static rectangular obstacles. Two primary parameters control the difficulty:

  • Turn Rate ($\kappa$): Determines the sharpness of track curves.
  • Obstacle Probability ($p$): Determines the density of obstacles.

Agents were evaluated on a set of "Hard" environments characterized by high curvature and high obstacle density.

Key Results and Robustness

The BO-based curriculum demonstrated clear superiority over both the default PPO baseline and a manually engineered curriculum.

Mean evaluation reward across various environment settings, comparing Default, Manual, and BO-based training.

As shown in the figure above, the BO-trained agent maintains higher performance across all difficulty settings. Notably, it does not just excel at the "hard" tasks it was optimized for but shows improved robustness across the entire spectrum of environment configurations.

Training Scheme Test Setting Average Reward Time on Grass (Lower is better)
PPO-Default Hard $368 \pm 181$ 0.343
Manual Curriculum Hard $667 \pm 167$ 0.082
BO Curriculum Hard $696 \pm 113$ 0.032

The BO agent achieved nearly double the reward of the default agent on hard tracks. Furthermore, it exhibited much more disciplined driving behavior, spending approximately 10 times less time on the grass compared to the baseline.

Insights and Future Directions

The success of the BO curriculum suggests that the optimal learning path for an RL agent is often non-intuitive to human designers. While the manual curriculum focused on minimizing collisions, the BO-discovered path allowed the agent to learn a better balance between speed and safety, covering more distance while maintaining high precision.

Future work could address the computational overhead of the BO process and explore more stable objective functions, such as averaging performance across multiple training checkpoints. Additionally, extending this framework to dynamic environments with moving obstacles or other agents represents a promising next step for autonomous racing research.

Summary updated

BibTeX
@misc{banerjee2023improving,
  author = {Rohan Banerjee and Prishita Ray and Mark Campbell},
  title = {{Improving Environment Robustness of Deep Reinforcement Learning Approaches for Autonomous Racing Using Bayesian Optimization-based Curriculum Learning}},
  year = {2023},
  eprint = {2312.10557},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2312.10557},
}
Figure