Model-based Adversarial Imitation Learning

Nir Baram, Oron Anschel, Shie MannorarXiv 2016

Introduction

Imitation Learning (IL) seeks to train agents to perform complex tasks by mimicking expert demonstrations, bypassing the need for manually engineered reward functions. However, standard approaches face significant hurdles. Behavioral Cloning (BC) suffers from covariate shift, where compounding errors lead the agent into unfamiliar states. Inverse Reinforcement Learning (IRL) is often computationally prohibitive and ill-posed. Generative Adversarial Imitation Learning (GAIL) offers a model-free alternative but relies on high-variance reinforcement learning estimators like REINFORCE, necessitating extensive environment interaction.

Methodology: Model-based Adversarial Imitation Learning (MAIL)

The proposed Model-based Adversarial Imitation Learning (MAIL) framework addresses these limitations by integrating a forward model of environment dynamics into the adversarial learning loop.

Architecture and Differentiability

MAIL consists of three primary components: a policy $\pi$, a discriminator $D$, and a forward model $f$. The discriminator $D(s, a)$ is trained to distinguish between expert state-action pairs and those generated by the learner. The forward model $f(s, a)$ predicts the subsequent state $s_{t+1}$ given the current state and action.

The MAIL architecture utilizes a forward model $f(s, a)$ to create a fully differentiable trajectory, allowing for direct gradient-based policy updates.

By employing the re-parametrization trick for stochastic policies and leveraging the learned forward model for state transitions, the entire trajectory becomes a differentiable graph. This enables the use of backpropagation to update the policy directly. Instead of relying on sparse rewards or high-variance RL estimators, MAIL minimizes the sum of discriminator probabilities along a path, providing dense supervision at every timestep.

Key Insights

MAIL's effectiveness stems from two main factors:

  1. Variance Reduction: Direct gradient updates through the forward model significantly reduce the variance compared to likelihood-ratio estimators used in model-free adversarial methods.
  2. Decomposed Logic: The discriminator effectively learns to evaluate both the quality of the state (where to be) and the quality of the action (what to do), guiding the policy more precisely toward the expert distribution.

Experimental Results

The researchers evaluated MAIL on the MuJoCo physics simulator using the Hopper and Walker tasks. Expert trajectories were generated via Trust Region Policy Optimization (TRPO). To assess sample efficiency, performance was measured across varying dataset sizes (4, 11, 18, and 25 trajectories).

Performance comparison of Behavioral Cloning, GAIL, and MAIL across different expert dataset sizes on Hopper and Walker tasks.

As shown in the results table, MAIL consistently outperforms both BC and GAIL. Notably, with only 4 expert trajectories, MAIL achieves near-expert performance (e.g., ~3669 on Hopper), whereas BC fails to learn a viable policy (~50). In the Walker task, MAIL's score of 6916 with 4 trajectories significantly exceeds GAIL's 4877, demonstrating superior sample efficiency.

Discussion and Future Work

While MAIL demonstrates state-of-the-art performance, it is sensitive to the accuracy of the forward model. Inaccurate predictions can lead to misleading gradients, hindering convergence. Furthermore, as the policy evolves, it visits new state-space regions, requiring continuous updates to both the discriminator and the forward model. Future research will focus on stabilizing this "moving target" training and improving the robustness of the learned dynamics model.

Summary updated

BibTeX
@misc{baram2016model,
  author = {Nir Baram and Oron Anschel and Shie Mannor},
  title = {{Model-based Adversarial Imitation Learning}},
  year = {2016},
  eprint = {1612.02179},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1612.02179},
}
Figure