Learning to Drive from Simulation without Real World Labels.

Alex Bewley, Jessica Rigley, Yuxuan Liu, Jeffrey Hawke, Richard Shen, Vinh-Dieu Lam, Alex Kendall · DOI

TL;DR

This paper tackles the "reality gap" in autonomous driving by developing a method to transfer a driving policy trained in simulation to the real world without requiring any real-world driving labels. They achieve this by jointly learning an image-to-image translation model and a control policy, demonstrating successful lane following on both rural and urban roads.

What Problem Does This Paper Address?

Training autonomous driving systems in simulation offers numerous advantages: it's safe, cheap, and allows for the creation of diverse and challenging scenarios. However, models trained solely in simulation often fail in the real world due to the "reality gap" – the difference in visual appearance between simulated and real environments. This gap makes it difficult to directly apply simulation-trained policies to real vehicles. While many efforts focus on making simulations more photorealistic, this paper addresses the problem by learning a mapping that makes the driving policy invariant to visual differences, effectively bridging the gap without needing real-world driving data.

Methods

The core of the proposed method is a deep learning architecture that combines image-to-image translation with an end-to-end driving policy. The approach leverages recent advances in unsupervised image-to-image translation, specifically using a cycle-consistent adversarial network.

Here's a breakdown of the key components:

  • Image Translation: The model learns to translate images from the simulated domain ($X_{sim}$) to the real domain ($X_{real}$) and vice-versa. This is achieved using a pair of encoders and decoders, forming a variational autoencoder (VAE) structure. A common latent space ($Z$) is learned, which is intended to capture the semantic content of the image independent of its domain.
  • Domain Discriminators: Two-scale discriminators are used to ensure that the translated images match the appearance distribution of the target domain.
  • Controller: A convolutional neural network controller takes the latent representation ($Z$) from the image translator and predicts a steering command ($\hat{c}$). This controller is trained using expert driving labels only from the simulation domain.
  • Joint Learning with Multiple Losses: The entire system is trained end-to-end using a combination of losses:
  • Reconstruction Loss: Ensures images can be reconstructed within their own domain.
  • Cyclic Reconstruction Loss: Enforces cycle consistency, meaning an image translated to another domain and back should resemble the original. This is crucial for learning a shared latent space.
  • Control Loss: An L1 loss between the predicted steering and the ground-truth simulation steering. This is the primary signal for learning the driving task.
  • Cyclic Control Loss: An L1 loss between the predicted steering and the steering predicted when the image is translated to the other domain and then encoded. This encourages the control policy to be invariant to domain translation.
  • Adversarial Loss (LSGAN): Used to improve the realism of translated images.
  • Perceptual Loss: Leverages a pre-trained VGG network to encourage consistent semantic content between original and translated images.
  • Latent Reconstruction Loss: Aims to make the latent representation ($Z$) domain-invariant.

The key novelty lies in jointly learning the image translation and the control policy, with the control loss shaping the latent space to be useful for driving, and the cyclic control loss ensuring this learned representation is robust to domain shifts.

Datasets

  • Simulation Domain: A procedurally generated rural driving environment was used to create a training dataset of approximately 60,000 image-label pairs. The environment allowed for variations in factors like cloud cover, rainfall, and time of day, though these were fixed for the specific training setup. An expert autopilot agent generated the control labels.
  • Real-World Domain:
    • Rural Road: A 250m private rural road in the UK was used for data collection and closed-loop testing.
  • Urban Road: Public urban roads in Cambridge, UK, were used for further closed-loop testing.

The paper notes that the real-world dataset had a significantly different steering distribution compared to simulation, with a strong bias towards driving straight. To address this, they employed data balancing techniques by splitting the data into eight bins based on steering angle and upsampling to ensure equal representation.

Key Insights and Ideas

  • Domain Invariance through Joint Learning: The most significant insight is that by jointly optimizing for image translation and a control task, the model can learn a latent representation that is inherently invariant to domain differences. The control loss actively shapes this latent space.
  • Cyclic Control Loss is Key: The cyclic control loss, which ensures the steering prediction is consistent even after translating an image to the other domain and back, proved particularly important for robust transfer.
  • Simulation's Advantage in Exploring State Space: The ability to control the simulation environment allowed the researchers to generate training data in states that might be rare or dangerous in the real world, leading to more robust policies.
  • Open-Loop Metrics are Insufficient: The study highlights a critical finding: standard open-loop metrics (like MAE and Balanced MAE) showed a weak correlation with actual closed-loop driving performance, underscoring the need for better evaluation methods.
  • Visual Translation Success is Paramount: Qualitative results showed that the success of the driving policy was highly dependent on the quality of the visual translation. When the translation accurately captured road curvature and structure, the driving policy performed well.

Key Results

  • Successful Rural Driving: The proposed method achieved no interventions over 3km of driving on a rural road, outperforming all baseline methods in closed-loop testing.
  • Successful Urban Driving: The system was demonstrated to successfully perform lane following on public UK urban roads, even under varying weather conditions.
  • Baseline Performance: Simple transfer (simulation model directly applied to real images) performed poorly. Real-to-Sim translation (translating real images to simulation domain) also struggled. Sim-to-Real translation (translating simulation images to real domain for training) showed some improvement but was still inferior to the proposed method.
  • Loss Ablation: The study showed that all loss terms played a significant role in reducing error, with the exception of the cyclic control factor, which was found to have a less pronounced effect in their specific ablation study.

Limitations and Future Work

  • Open-Loop Metric Limitations: The paper explicitly states that standard open-loop metrics are not reliable predictors of real-world performance and calls for further research in this area.
  • Dependence on Visual Translation Quality: The success of the driving policy is heavily reliant on the accuracy of the image-to-image translation. Failures in translation can lead to driving failures.
  • Future Work Suggestions:
    • Improving open-loop metrics for better evaluation.
  • Incorporating temporal motion consistency for more robust control.
  • Exploring more complex driving tasks beyond lane following.
  • Investigating how to handle more significant domain shifts or more complex real-world scenarios.

Summary updated

BibTeX
@inproceedings{bewley2018learning,
  author = {Alex Bewley and Jessica Rigley and Yuxuan Liu and Jeffrey Hawke and Richard Shen and Vinh-Dieu Lam and Alex Kendall},
  title = {{Learning to Drive from Simulation without Real World Labels.}},
  booktitle = {ICRA},
  year = {2018},
  doi = {10.1109/icra.2019.8793668},
}
Figure