Provably Convergent Policy Gradient Methods for Model-Agnostic Meta-Reinforcement Learning

Alireza Fallah, Aryan Mokhtari, Asuman E. OzdaglararXiv 2020 · arXiv · OpenReview

Introduction

Meta-learning, or "learning to learn," has emerged as a powerful paradigm for creating agents capable of rapid adaptation. In the context of Reinforcement Learning (RL), the goal is to find a base policy that can be fine-tuned to a specific task using only a few samples. Model-Agnostic Meta-Learning (MAML) is the leading framework for this objective, aiming to optimize a meta-policy such that a single gradient step on a new task leads to near-optimal performance.

While MAML has seen significant empirical success in supervised learning tasks like computer vision, its application to RL has historically lacked a rigorous theoretical foundation. This paper addresses this gap by identifying a fundamental bias in existing Meta-RL implementations and proposing Stochastic Gradient Meta-Reinforcement Learning (SG-MRL), the first MAML-based RL algorithm with provable convergence guarantees.

The Challenge: The Hidden Bias in Meta-RL

In standard RL, we rarely have access to exact gradients because the environment's transition dynamics are often unknown and the space of possible trajectories is infinite. Instead, we rely on stochastic gradient estimates derived from a finite batch of sampled trajectories.

In the MAML framework, the meta-gradient is calculated by taking the derivative of a loss function that itself depends on a "task-specific" policy updated via a stochastic gradient step. The authors discovered that this "stochastic gradient in the inner loop" introduces a non-vanishing bias. Because the probability distribution of the trajectories sampled for the meta-update depends on the initial policy, standard gradient estimators fail to account for the mathematical ripple effect of the initial update. Without correcting this bias, the algorithm cannot be guaranteed to converge to an optimal solution, regardless of how much data is collected.

The SG-MRL Algorithm

To resolve this, the authors introduce SG-MRL, which utilizes a novel debiased gradient estimator. The core innovation lies in the inclusion of a correction term that accounts for the dependency between the initial policy parameters and the trajectory distribution of the adapted policy.

Key components of the SG-MRL approach include:

  1. Debiased Estimator: The meta-gradient update is augmented with a term involving the log-probability of trajectories, effectively neutralizing the bias introduced by the inner-loop stochastic update.
  2. Hessian Integration: The method incorporates second-order information (the Hessian of the reward function) to ensure the update direction accurately reflects the geometry of the meta-objective.
  3. Multi-Step Generalization: While the primary theory focuses on a single adaptation step, the authors extend their framework to accommodate multiple stochastic gradient steps at test time, providing a more flexible tool for complex task adaptation.

Theoretical Contributions

This work provides the first iteration and sample complexity analysis for model-agnostic meta-reinforcement learning. The authors prove that SG-MRL converges to an $\epsilon$-first-order stationary point—a point where the gradient is effectively zero.

The theory establishes that as long as the learning rate is appropriately scaled and the batch size is sufficiently large, SG-MRL will reliably find a local optimum. These bounds provide a roadmap for practitioners to determine the number of samples and iterations required to achieve a desired level of accuracy in meta-training.

Empirical Results

The authors evaluated SG-MRL against standard MAML across several high-dimensional robotics benchmarks using the MuJoCo physics engine and 2D navigation tasks.

  • Half-Cheetah (Random Direction): In this task, a robot must learn to run either forward or backward based on task-specific feedback. SG-MRL achieved a meta-test reward of 580.1, significantly outperforming the standard MAML baseline of 465.6.
  • Stability and Efficiency: Despite the additional mathematical complexity of the debiasing term, SG-MRL only increased per-iteration computation time by approximately 5%. Furthermore, SG-MRL demonstrated superior stability when the number of adaptation steps was increased, whereas standard MAML's performance often stagnated or fluctuated.
  • Navigation and Swimmer: Across 2D-Navigation and the MuJoCo Swimmer environment, SG-MRL consistently reached higher reward plateaus faster than biased alternatives.

Conclusion and Future Work

SG-MRL bridges the gap between the empirical utility of Meta-RL and its theoretical understanding. By identifying and correcting the non-vanishing bias in stochastic meta-gradients, this work provides a robust framework for developing reliable meta-learning agents.

Future research directions include relaxing the assumption of bounded gradients for complex neural networks and exploring "saddle-point avoidance" to ensure convergence to local maxima rather than just stationary points. Additionally, integrating these convergence guarantees with sophisticated exploration strategies remains a vital frontier for the field.

Summary updated

Abstract

We consider Model-Agnostic Meta-Learning (MAML) methods for Reinforcement Learning (RL) problems, where the goal is to find a policy using data from several tasks represented by Markov Decision Processes (MDPs) that can be updated by one step of stochastic policy gradient for the realized MDP. In particular, using stochastic gradients in MAML update steps is crucial for RL problems since computation of exact gradients requires access to a large number of possible trajectories. For this formulation, we propose a variant of the MAML method, named Stochastic Gradient Meta-Reinforcement Learning (SG-MRL), and study its convergence properties. We derive the iteration and sample complexity of SG-MRL to find an $\epsilon$-first-order stationary point, which, to the best of our knowledge, provides the first convergence guarantee for model-agnostic meta-reinforcement learning algorithms. We further show how our results extend to the case where more than one step of stochastic policy gradient method is used at test time. Finally, we empirically compare SG-MRL and MAML in several deep RL environments.
BibTeX
@misc{fallah2020provably,
  author = {Alireza Fallah and Aryan Mokhtari and Asuman E. Ozdaglar},
  title = {{Provably Convergent Policy Gradient Methods for Model-Agnostic Meta-Reinforcement Learning}},
  year = {2020},
  eprint = {2002.05135},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2002.05135},
}
Figure