Deep Reinforcement Learning Without Experience Replay, Target Networks, or Batch Updates

Mohamed Elsayed, Gautham Vasan, A. Rupam Mahmood

TL;DR

This paper introduces "stream-x" algorithms, a novel class of deep reinforcement learning (RL) methods that can learn effectively from a continuous stream of experience without relying on computationally expensive replay buffers or batch updates. These algorithms overcome the notorious "stream barrier" of instability and failure to learn, achieving sample efficiency comparable to traditional batch RL methods and even outperforming them in some challenging environments.

What Problem Does This Paper Address?

Traditional reinforcement learning, especially in its deep learning incarnations, heavily relies on storing past experiences in a "replay buffer" and processing them in batches. While this approach has led to significant advancements, it comes with substantial computational and memory overheads. This makes it unsuitable for resource-constrained environments like edge devices, or applications where real-time adaptation is critical, such as robotics or systems with limited communication. Furthermore, the reliance on batching can introduce instability and hinder learning in streaming scenarios where data arrives sequentially. This paper tackles the challenge of enabling deep RL to learn effectively and stably from a continuous stream of data, mimicking natural learning processes, without the need for batching or experience replay.

Methods

The authors introduce a suite of "stream-x" algorithms (stream Q, stream AC, stream TD) that are designed for streaming learning. The core of their approach lies in a set of common techniques that address the inherent instability of online updates:

  • Eligibility Traces: These are used to form multi-step methods, allowing for better credit assignment than one-step updates, which is crucial for stable learning in streaming settings.
  • Sparse Initialization: Randomly initializing most weights to zero at the start of training helps improve sample efficiency and reduce forgetting.
  • Layer Normalization: Applied to pre-activations, this technique stabilizes learning dynamics by ensuring similar distributions across layers, even with non-stationary data.
  • Overshooting-bounded Gradient Descent (ObGD): A novel optimizer that adaptively adjusts step sizes to prevent large, destabilizing updates, particularly when dealing with single samples. This is a key innovation for maintaining stability in streaming RL.
  • Data Scaling: Rewards and observations are scaled to improve numerical stability and prevent issues arising from large target values.

These techniques are combined to create algorithms that can learn from individual samples without storing them.

Datasets

The authors evaluate their methods on a variety of standard RL benchmarks:

  • MuJoCo Gym: A suite of continuous control tasks.
  • DM Control Suite: Another set of continuous control tasks.
  • Atari 2600: A collection of classic arcade games.
  • Electricity Transformer Temperature Dataset (ETTm2): A real-world time series dataset for temporal prediction.

Key Insights and Ideas

  • The "Stream Barrier" is the Real Problem: The paper argues that the primary reason for the lack of streaming deep RL isn't just sample inefficiency, but rather a fundamental instability issue that causes algorithms to fail or perform poorly.
  • Streaming RL Can Be Stable and Efficient: Contrary to common belief, the proposed stream-x algorithms demonstrate that deep RL can learn stably and achieve sample efficiency comparable to, or even better than, batch RL methods.
  • A Unified Set of Techniques is Key: The success of stream-x algorithms stems from a combination of techniques (sparse initialization, eligibility traces, layer normalization, ObGD, data scaling) that work synergistically to overcome the stream barrier.
  • ObGD is Crucial for Stability: The Overshooting-bounded Gradient Descent (ObGD) optimizer is highlighted as a particularly important component for achieving stable learning in streaming settings.
  • Reviving Streaming RL: The paper aims to revitalize the field of streaming RL, making it a viable option for resource-constrained and real-time applications.

Key Results

  • Overcoming Stream Barrier: The stream-x algorithms successfully overcome the instability issues that plague existing streaming and batch RL methods when applied in a streaming fashion, as demonstrated by stable learning curves in challenging environments like MuJoCo Gym and Atari.
  • Competitive Sample Efficiency: In several MuJoCo environments, stream AC(λ) shows sample efficiency comparable to or better than batch RL methods like PPO.
  • State-of-the-Art Performance: In the DM Control Dog environments, stream AC(λ) achieved the best known model-free performance.
  • Robustness in Atari: Stream Q(λ) demonstrated strong performance on Atari games, often outperforming its streaming counterpart (DQN1) and being competitive with DQN.
  • Stability in Extended Runs: Stream AC(λ) showed superior stability over extended training periods (20M time steps) compared to batch RL methods like PPO and SAC, which exhibited performance degradation.
  • Single Hyperparameter Set: Remarkably, the stream-x algorithms achieved these results across various tasks and algorithms using a single set of hyperparameters, indicating their generalizability and ease of use.

Limitations and Future Work

  • Focus on Model-Free: The current work primarily focuses on model-free RL methods. The authors suggest exploring how their approach can be extended to model-based methods to further improve sample efficiency.
  • Off-Policy Exploration: While stream Q(λ) is an off-policy algorithm, the paper primarily experiments with on-policy methods. Further investigation into a broader range of off-policy methods, potentially with importance sampling, is suggested.
  • Continual Learning Connections: The authors note that techniques beneficial for streaming RL, like LayerNorm, are also effective in continual learning. They suggest that insights from continual learning might further improve streaming RL, and vice-versa.
  • Step-Size Adaptation: Exploring more advanced step-size adaptation techniques could further enhance the optimizer's performance.
  • Parallelized RL: The insights gained from this work could be relevant for improving stability in parallelized RL settings.

Summary updated

BibTeX
@inproceedings{elsayed2024deep,
  author = {Mohamed Elsayed and Gautham Vasan and A. Rupam Mahmood},
  title = {{Deep Reinforcement Learning Without Experience Replay, Target Networks, or Batch Updates}},
  booktitle = {FITML @ NeurIPS},
  year = {2024},
  url = {https://openreview.net/forum?id=yqQJGTDGXN},
}
Figure