Learning to Navigate in Complex Environments

Piotr Mirowski, Razvan Pascanu, Fabio Viola, Hubert Soyer, Andy Ballard, Andrea Banino, Misha Denil, Ross Goroshin, Laurent Sifre, Koray Kavukcuoglu, Dharshan Kumaran, Raia Hadsell

Autonomous navigation is a cornerstone of intelligent behavior, but training reinforcement learning (RL) agents to navigate complex 3D environments from raw pixel data remains notoriously difficult. Researchers at DeepMind have demonstrated that augmenting RL agents with self-supervised auxiliary tasks—specifically depth prediction and loop closure detection—dramatically improves both data efficiency and task performance. Their resulting "Nav A3C" agent approaches human-level performance in complex mazes, implicitly learning to localize and reason spatially without requiring explicit mapping or coordinate supervision.

The Challenge of Pixel-to-Action Navigation

Training an agent to navigate using only raw sensory input presents three primary hurdles:

  1. Sparse Rewards: In large environments, an agent might only receive a reward upon reaching a distant goal. This provides very little gradient signal during the early stages of learning.
  2. Partial Observability: The agent only sees what is directly in its first-person field of view. To succeed, it must maintain a robust internal memory of the environment's broader layout.
  3. Dynamic Environments: In scenarios where the goal moves every episode, the agent cannot simply memorize a static path. It must learn an "explore-then-exploit" strategy: searching the environment for the goal and then remembering how to return to it efficiently.

While traditional robotics often relies on Simultaneous Localization and Mapping (SLAM) to explicitly infer geometry and position, this research investigates whether these navigational abilities can emerge end-to-end from a policy optimizing for reward.

Methodology: The Nav A3C Agent

The researchers built their approach on the Asynchronous Advantage Actor-Critic (A3C) framework, introducing the Nav A3C agent. The architecture features stacked LSTMs (a two-layer setup) to handle memory at different timescales, such as short-term velocity integration versus long-term goal location tracking. Furthermore, the agent receives multimodal inputs: alongside RGB frames, it processes its own relative velocity, the previous action taken, and the previous reward.

The core innovation lies in augmenting the agent with self-supervised auxiliary tasks that share the base representation but utilize distinct loss functions:

  • Depth Prediction: The agent is trained to predict a low-resolution depth map from its RGB input. This forces the convolutional encoder to learn about 3D geometry and obstacle avoidance. Interestingly, treating depth prediction as a classification task (discretizing depth into 8 bands) proved more effective than standard regression.
  • Loop Closure Classification: Inspired by SLAM, the agent predicts whether its current location has been visited before within the current trajectory. This encourages the agent to integrate velocity signals and recognize spatial landmarks.

Environments and Training

The study utilized DeepMind Lab, a first-person 3D environment, to evaluate the agents across several maze configurations. These included static mazes with fixed layouts and goals, random goal mazes where the target moves every episode, and an "I-Maze" designed specifically to test memory and the ability to choose between symmetric paths.

First-person 3D views and corresponding 2D top-down trajectory maps across different maze configurations.

Key Insights and Results

The addition of auxiliary tasks provided a "dense" training signal. Even if the agent had not yet found the goal, it learned useful visual and spatial representations simply by predicting depth and loop closures. This led to several impressive outcomes:

  • Human-Level Performance: The Nav A3C agent reached human-level performance on static mazes and achieved approximately 91% of human scores on small random-goal mazes.
  • Data Efficiency and Robustness: On static mazes, the auxiliary tasks allowed the agent to reach high performance in a fraction of the steps required by a standard A3C baseline. The learning process also became significantly more robust to hyperparameter variations.
  • Rapid Re-acquisition: In random goal tasks, once the agent found the goal for the first time in an episode, the time it took to find it again dropped significantly, proving it had successfully memorized the new location.
  • Implicit Localization: By training a separate position decoder (used only for analysis, not training), the authors discovered that the agent's LSTM hidden states accurately represented its $(x, y)$ coordinates. The agent implicitly "knew" where it was without ever being taught coordinates.

Furthermore, predicting depth from the top LSTM layer—the layer dictating the policy—was more effective than predicting it directly from the convolutional encoder. This suggests that spatial structure becomes deeply integrated into the agent's decision-making process.

Limitations and Future Directions

While the stacked LSTM architecture is powerful, its memory capacity is inherently limited. For truly massive or procedurally generated mazes that change entirely every episode, the agent might require external memory structures, such as Differentiable Neural Computers (DNCs).

Additionally, while the agent implicitly learns SLAM-like properties, it does not build a persistent, human-readable map. Future work could explore hybrid approaches that combine the geometric precision of classical SLAM systems with the flexible, reward-driven behavior of end-to-end RL agents.

Summary updated

BibTeX
@inproceedings{mirowski2017learning,
  author = {Piotr Mirowski and Razvan Pascanu and Fabio Viola and Hubert Soyer and Andy Ballard and Andrea Banino and Misha Denil and Ross Goroshin and Laurent Sifre and Koray Kavukcuoglu and Dharshan Kumaran and Raia Hadsell},
  title = {{Learning to Navigate in Complex Environments}},
  booktitle = {International Conference on Learning Representations},
  year = {2017},
  url = {https://openreview.net/forum?id=SJMGPrcle},
}
Figure