Multi-task Learning and Catastrophic Forgetting in Continual Reinforcement Learning

João Ribeiro, Francisco S. Melo, João Dias · OpenReview

Introduction

In Deep Reinforcement Learning (RL), agents are typically designed as specialists, excelling at a single task but failing to generalize to others. For instance, an agent trained to play Space Invaders cannot inherently play Demon Attack, despite both being bottom-up shooters. Furthermore, training a specialist on a new task often leads to catastrophic forgetting, where new weight updates overwrite and erase previous expertise. This paper explores whether multi-task learning can provide a "head start" for new tasks and if Elastic Weight Consolidation (EWC) can mitigate forgetting during continual learning.

Methodology

The researchers extended the GA3C (GPU-based Asynchronous Advantage Actor-Critic) algorithm to support multi-tasking and memory retention. The architecture consists of three primary components:

  • Hybrid Architecture: A shared "trunk" of convolutional layers extracts general visual features, while multiple task-specific "heads" handle action and value estimations for different games.
  • Environment Handlers: A modular interface allows the agent to interact with multiple Atari 2600 environments asynchronously.
  • Elastic Weight Consolidation (EWC): To prevent forgetting, EWC introduces a penalty to the loss function when learning new tasks. This penalty anchors weights that were critical for previous tasks, preserving established knowledge.

Experimental Setup

The study utilized three structurally similar Atari 2600 shooters via OpenAI Gym:

  1. Space Invaders (Source Task 1)
  2. Demon Attack (Source Task 2)
  3. Phoenix (The target "New" Task)

Agents were evaluated based on their ability to transfer knowledge to Phoenix and their ability to retain performance on the source tasks after training on the new one.

Key Insights and Results

Representational Synergy and Transfer

Multi-task training forces the agent to develop robust, high-level internal representations. Because shared layers must satisfy multiple games, they learn features that are more general and less overfit to a single layout. The researchers found a clear Transfer Advantage: the HybridNet (trained on both Space Invaders and Demon Attack) outperformed single-task specialists when moved to Phoenix.

As shown in the training curves, after 50,000 episodes on Phoenix, HybridNet achieved an average score of 8,587.3, significantly higher than the scores achieved by SpaceNet (~6,136) and DemonNet (~6,006).

Mitigating Catastrophic Forgetting

Without EWC, agents' scores on original games plummeted to near zero after learning a new task. However, with EWC (using hyperparameter $\lambda = 50$), agents maintained significant performance. For example, on Space Invaders, the EWC-enabled agent maintained a score of ~547, while the non-EWC agent dropped to 80. While EWC can slightly slow the learning of new tasks due to weight "stubbornness," the multi-task agent still consistently outperformed single-task specialists.

Conclusion and Future Work

This research demonstrates that multi-task pre-training combined with EWC provides a viable path toward continual RL. Future work should address the limitations of small sample sizes by running multiple seeds and explore the efficacy of these methods across more diverse task sets (e.g., moving from shooters to platformers). Additionally, evaluating newer mitigations like Learning Without Forgetting (LWF) could further optimize the stability-plasticity balance.

Summary updated

BibTeX
@inproceedings{ribeiro2019multi,
  author = {João Ribeiro and Francisco S. Melo and João Dias},
  title = {{Multi-task Learning and Catastrophic Forgetting in Continual Reinforcement Learning}},
  booktitle = {GCAI},
  year = {2019},
  doi = {10.29007/g7bg},
}
Figure