In the Presence of Enemies: Improving RL Driving Agents With Adversarial Testing and Retraining

Autonomous driving systems (ADS) are safety‐critical applications that must be thoroughly tested before deployment. Traditional testing methods often rely on static environment configurations or centralized dynamic approaches, which struggle to capture the complexity of real‐world driving interactions. Recent work using reinforcement learning (RL) has explored dynamic testing by controlling non‐playable characters (NPCs) as adversarial agents. Although this type of agents represents a viable approach in simple cases, it becomes ineffective in complex scenarios, where the adversarial agent must also know how to navigate the environment. In this work, we propose a two‐step approach to improve the robustness of the ADS under test (ego ADS) through adversarial training. First, we train an adversarial ADS, initialized from the weights of the ego ADS and guided by a reward function that balances competent driving patterns with adversarial intent. This allows the adversarial to avoid useless collisions with other NPCs and to focus its attention towards the target ADS. In the second step, we retrain the ego ADS in the presence of the adversarial ADS, enabling it to learn from difficult yet avoidable failures. We evaluate our approach across five driving scenarios across two simulators and compare it to a purely adversarial ADS trained using a proximity‐based reward. Our results show that the adversarial ADS induces significantly more failures than the purely adversarial ADS, with the failures being valid and leading to improvements in the ego ADS after retraining, without causing regressions in nominal driving performance.

Authors

Institutions

Publication Details

Journal
Software Testing Verification and Reliability
Published
2026-12-01
DOI
https://doi.org/10.1002/stvr.70034
Primary Topic
Adversarial Robustness in Machine Learning
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
article

In the Presence of Enemies: Improving RL Driving Agents With Adversarial Testing and Retraining

Paolo Tonella, Matteo Biagiola, Andrea Doreste
Software Testing Verification and Reliability
Adversarial Robustness in Machine Learning
article

In the Presence of Enemies: Improving RL Driving Agents With Adversarial Testing and Retraining

Paolo Tonella, Matteo Biagiola, Andrea Doreste
article en

Abstract

Autonomous driving systems (ADS) are safety‐critical applications that must be thoroughly tested before deployment. Traditional testing methods often rely on static environment configurations or centralized dynamic approaches, which struggle to capture the complexity of real‐world driving interactions. Recent work using reinforcement learning (RL) has explored dynamic testing by controlling non‐playable characters (NPCs) as adversarial agents. Although this type of agents represents a viable approach in simple cases, it becomes ineffective in complex scenarios, where the adversarial agent must also know how to navigate the environment. In this work, we propose a two‐step approach to improve the robustness of the ADS under test (ego ADS) through adversarial training. First, we train an adversarial ADS, initialized from the weights of the ego ADS and guided by a reward function that balances competent driving patterns with adversarial intent. This allows the adversarial to avoid useless collisions with other NPCs and to focus its attention towards the target ADS. In the second step, we retrain the ego ADS in the presence of the adversarial ADS, enabling it to learn from difficult yet avoidable failures. We evaluate our approach across five driving scenarios across two simulators and compare it to a purely adversarial ADS trained using a proximity‐based reward. Our results show that the adversarial ADS induces significantly more failures than the purely adversarial ADS, with the failures being valid and leading to improvements in the ego ADS after retraining, without causing regressions in nominal driving performance.

Software Testing Verification and ReliabilityVol. 37(1)
University of St.Gallen (CH), Università della Svizzera italiana (CH)
Adversarial Robustness in Machine Learning
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon
In the Presence of Enemies: Improving RL Driving Agents With Adversarial Testing and Retraining — Paolo Tonella, Matteo Biagiola, et al. · Software Testing Verification and Reliability (2026) | TGRS Research Map | TGRS