Stochastic Variance Reduction for Policy Gradient Estimation

Tianbing Xu, Qiang Liu, Jian PengarXiv 2017

TL;DR

This paper tackles the problem of high variance in policy gradient estimation for reinforcement learning, which hinders sample efficiency. They introduce SVRPO, a novel method that combines Stochastic Variance Reduced Gradient (SVRG) with Trust Region Policy Optimization (TRPO) to significantly improve learning speed and final performance on complex robotic control tasks.

What Problem Does This Paper Address?

Reinforcement learning (RL) agents learn by trial and error, aiming to maximize cumulative rewards. Policy gradient (PG) methods are a popular class of RL algorithms that directly optimize a policy (how an agent acts given a state) to achieve this goal. However, a major challenge with PG methods is the high variance in their gradient estimates. Imagine trying to steer a car by only getting feedback on how much you over- or under-steered after a long drive – it's hard to pinpoint the exact adjustments needed. This high variance means agents need a lot of data (samples) to learn effectively, making them "sample inefficient." This is particularly problematic in complex environments like robotics, where collecting data can be expensive and time-consuming. While TRPO is a state-of-the-art PG method that improves stability, it still suffers from this fundamental variance issue.

Methods

The core innovation of this paper is the integration of Stochastic Variance Reduced Gradient (SVRG) into the Trust Region Policy Optimization (TRPO) framework.

  • TRPO (Trust Region Policy Optimization): TRPO is a sophisticated policy gradient method that addresses stability by constraining policy updates within a "trust region." This prevents drastic changes that could destabilize learning. It uses a surrogate objective function and a KL divergence constraint to ensure that new policies are not too different from the old ones.
  • SVRG (Stochastic Variance Reduced Gradient): SVRG is an optimization technique designed to reduce the variance of gradient estimates in large-scale machine learning problems. It achieves this by maintaining a "snapshot" of the model parameters from a previous iteration. The gradient is then estimated using a combination of the pre-calculated gradient at the snapshot and a mini-batch of current samples. This "control variate" approach significantly reduces the noise in the gradient estimate.

The proposed method, SVRPO (Stochastic Variance Reduced Policy Optimization), uses SVRG to compute the policy gradient within the TRPO's trust region optimization framework. This means that instead of using a noisy, high-variance gradient estimate from a small batch of samples, SVRPO uses the more stable SVRG estimate. Additionally, SVRPO utilizes a sub-sampled Fisher information matrix for the Newton conjugate gradient update, which balances computational cost with accuracy.

Datasets

The experiments were conducted on several challenging robotic control tasks within the Mujoco physics simulator. These tasks include:

  • Swimmer
  • Walker
  • Hopper
  • Half-Cheetah
  • Ant
  • Humanoid

The paper does not introduce new datasets but rather uses these established benchmarks to evaluate the performance of their proposed method against existing state-of-the-art algorithms.

Key Insights and Ideas

  • Variance is the Bottleneck: The paper strongly suggests that the high variance of policy gradient estimates is the primary reason for poor sample efficiency in existing methods, even advanced ones like TRPO.
  • SVRG as a Powerful Variance Reducer: Applying SVRG directly to the policy gradient estimation within TRPO yields substantial improvements. This highlights the general applicability of variance reduction techniques beyond standard supervised learning.
  • Fisher Information Matters for Acceleration: The use of the Fisher information matrix (or its approximation) in the trust region update is crucial for accelerating convergence. Without it, even with variance reduction, learning can be significantly slower.
  • Implicit Exploration: The use of mini-batch updates and sub-sampled Fisher information introduces small, controlled noise. This noise can act as an "implicit exploration" mechanism, helping the agent discover better parameter regions without the risks of large, erratic policy changes.

Key Results

SVRPO consistently outperforms TRPO in terms of sample efficiency and final performance across most of the tested Mujoco tasks.

  • Swimmer: SVRPO converges much faster, achieving higher returns using less than 40% of the samples required by TRPO.
  • Hopper: SVRPO achieves similar results to TRPO in 500 iterations with fewer than 200 iterations, and reaches a significantly higher final return.
  • Walker: SVRPO needs only about 40% of TRPO's samples for similar returns and achieves a much higher final return (around 4000 vs. TRPO's 2900).
  • Ant: SVRPO demonstrates improved sample efficiency and a better final return (around 3000 vs. TRPO's 2200).
  • Humanoid: SVRPO achieves similar or slightly better returns than TRPO within 1000 iterations.
  • Half-Cheetah: SVRPO shows a similar final return to TRPO.

The paper also includes figures (Fig. 2 and Fig. 3) that visually demonstrate the benefits of variance reduction (SVRG vs. SGD) and the use of Fisher information matrix for accelerated convergence.

Limitations and Future Work

  • Computational Cost of Fisher Information: While beneficial, computing the Fisher information matrix can be computationally expensive. The paper addresses this by using a sub-sampled version, but further optimizations might be needed for extremely large-scale problems.
  • Hyperparameter Tuning: Like most RL algorithms, SVRPO likely has hyperparameters that require careful tuning (e.g., mini-batch size, number of inner loop iterations). The paper mentions searching for these parameters.
  • Future Work: The authors suggest that their SVRPO method opens doors for developing more scalable and efficient policy optimization methods. They also mention extending the work to robotic learning problems with large state spaces and complex control policies, potentially using virtual observations. The implicit exploration mechanism is also highlighted as a promising area for further investigation.

Summary updated

BibTeX
@misc{xu2017stochastic,
  author = {Tianbing Xu and Qiang Liu and Jian Peng},
  title = {{Stochastic Variance Reduction for Policy Gradient Estimation}},
  year = {2017},
  eprint = {1710.06034},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1710.06034},
}
Figure