Generative predecessor models for sample-efficient imitation learning

Yannick Schroecker, Mel Vecerík, Jonathan Scholz

Introduction

Imitation learning (IL) typically falls into two camps: Behavioral Cloning (BC) and Distribution Matching (like GAIL). BC is simple supervised learning (copying the expert's actions), but it suffers from "covariate shift"—small errors accumulate, leading the robot into unfamiliar states where it doesn't know what to do. Distribution Matching methods like GAIL are more robust because they provide a "reward" for staying near the expert's path, but they rely on adversarial training (GANs), which is notoriously unstable and requires millions of environment interactions.

To address the need for an imitation learning algorithm that is both stable and sample-efficient enough to work on real-world physical robots, researchers introduce GPRIL (Generative Predecessor Models for Imitation Learning). GPRIL is a novel algorithm that helps robots learn from experts by "imagining" the paths that lead to successful outcomes. By using generative models to understand which actions lead back to expert-demonstrated states, the agent learns to correct its own mistakes, achieving state-of-the-art performance with orders of magnitude more sample efficiency than previous methods.

Methods: Generative Predecessor Models

The core innovation of GPRIL is the Generative Predecessor Model. Instead of just learning what the expert did at state $s$, the agent learns a model of the "history" that leads to $s$.

  1. Predecessor Modeling: The agent uses Masked Autoregressive Flows (MAF)—a type of generative model—to learn the distribution of state-action pairs $(s, a)$ that eventually lead to a future state $s'$.
  2. "Jumpy" Transitions: During self-supervised interaction, the agent records transitions. It doesn't just look at the next step; it samples future states $j$ steps away (where $j$ follows a geometric distribution). This allows the model to reason about long-term consequences.
  3. Data Augmentation: To train the policy, the agent takes expert-demonstrated states and uses its generative model to "hallucinate" corrective state-action pairs that would lead back to those expert states.
  4. Maximum Likelihood Objective: Unlike GAIL, which uses a discriminator to create a reward, GPRIL uses a direct maximum likelihood approach. This makes training significantly more stable.

Tasks and Key Results

The researchers evaluated GPRIL on three challenging robotic manipulation tasks:

  • Simulated Clip Insertion: A robot arm must flex an elastic clip to fit it into a plug.
  • Simulated Peg Insertion: Inserting a peg into a hole mounted on a moving pan-tilt unit (adding variability in the target position).
  • Real-World Peg Insertion: A physical robot arm performing the same peg-in-hole task using kinesthetic teaching for demonstrations.
Task and Performance Overview

Key Insights

  • Corrective Behavior is Key: The "aha" moment is that an agent doesn't just need to know the "right" move; it needs to know how to get back to the "right" path when it drifts. By modeling predecessors, GPRIL explicitly trains the agent to move toward the expert's distribution.
  • Stability over Adversarialism: By replacing the adversarial "cat-and-mouse" game of GANs with a stable generative model (MAF), the authors achieved much faster convergence.
  • Learning from States Alone: GPRIL can function even if the expert's actions are unknown. If you only have a video of a successful task (states), GPRIL can still learn the policy by figuring out which of its own actions lead to those observed states.

Performance Gains

  • Massive Efficiency Gains: In the clip insertion task, GPRIL reached a high success rate using several orders of magnitude fewer environment interactions than GAIL.
  • Robustness to Sparsity: GPRIL performed remarkably well even when demonstrations were "sparsified" (e.g., only providing every 10th state or even just the final successful state). GAIL, by contrast, became highly unstable with very sparse data.
  • Real-World Success: The authors successfully trained a real robot to perform peg insertion in a variable environment. This is a significant milestone, as many RL/IL algorithms fail to transfer from simulation to the messy reality of physical hardware.

Limitations and Future Work

While more stable than GAIL, the authors noted that tuning hyperparameters on a real robot remains difficult and time-consuming. In real-world tests, the variability in the pan-tilt unit's reporting occasionally caused failures, suggesting the need for more robust sensor integration or better exploration noise design. Furthermore, the current method relies on a simple exploration strategy; integrating more sophisticated exploration could further improve performance in complex environments.

Summary updated

BibTeX
@inproceedings{schroecker2019generative,
  author = {Yannick Schroecker and Mel Vecerík and Jonathan Scholz},
  title = {{Generative predecessor models for sample-efficient imitation learning}},
  booktitle = {International Conference on Learning Representations},
  year = {2019},
}
Figure