Generative Adversarial Imitation from Observation

Faraz Torabi, Garrett Warnell, Peter StonearXiv 2018

Abstract

Imitation learning traditionally requires access to expert actions, which limits its applicability to datasets like online videos where only states are visible. We present Generative Adversarial Imitation from Observation (GAIfO), a framework that enables agents to learn complex behaviors by matching the state-transition distribution of an expert. By utilizing an adversarial approach, GAIfO achieves performance comparable to state-of-the-art methods that rely on explicit action data, unlocking the potential of learning from visual demonstrations.

Introduction

Reinforcement Learning (RL) is a powerful tool for autonomous agents, but designing effective reward functions for complex tasks is notoriously difficult. Imitation Learning (IL) bypasses this by allowing agents to learn directly from expert demonstrations. However, standard IL algorithms, such as Behavioral Cloning or Inverse Reinforcement Learning, require demonstrations consisting of both states and actions $(s, a)$.

This reliance on action data is a significant bottleneck. It renders vast amounts of potential training data—such as online videos of humans performing tasks—useless, as the internal control signals of the demonstrator are hidden. The sub-field of Imitation from Observation (IfO) attempts to solve this by learning from state-only data. Previous IfO methods often suffer from compounding errors or require strict temporal alignment. GAIfO addresses these issues through a robust, distribution-matching framework.

Methodology

GAIfO builds upon Generative Adversarial Imitation Learning (GAIL) but modifies the objective to operate over state transitions $(s, s')$ instead of state-action pairs. This allows the model to learn without ever seeing the expert's internal control signals.

The GAIfO architecture: The discriminator $D$ distinguishes between expert (Demonstrator) and imitator state transitions $(s, s')$, while the policy $\pi$ (generator) learns to produce transitions that mimic the expert.

The framework consists of two primary components:

  1. The Discriminator: A neural network trained to differentiate between state transitions $(s, s')$ from the expert and those produced by the agent.
  2. The Generator (Policy): The agent's policy, updated via Trust Region Policy Optimization (TRPO). The agent receives a reward based on its ability to deceive the discriminator.

This approach ensures that the agent learns the underlying dynamics and goals of the task by matching the overall distribution of transitions, rather than attempting a step-by-step temporal match. This makes GAIfO particularly effective for cyclic tasks like walking or hopping.

Experimental Evaluation

The authors evaluated GAIfO using the OpenAI Gym framework and the PyBullet physics simulator across several continuous control tasks: InvertedDoublePendulum, InvertedPendulumSwingup, Hopper, and Walker2D. Experiments were conducted using both low-dimensional state features (e.g., joint angles) and high-dimensional visual data (raw pixels).

Key Results

GAIfO demonstrated superior performance compared to common IfO baselines like Behavioral Cloning from Observation (BCO) and Time Contrastive Networks (TCN).

Final average normalized scores for the InvertedDoublePendulum task. GAIfO (blue) consistently reaches near-expert performance (1.0) across varying amounts of demonstration data, significantly outperforming BCO and TCN.

In low-dimensional settings, GAIfO achieved scores near 1.0, matching the performance of GAIL despite the latter's access to expert actions. In visual-only settings, GAIfO successfully extracted task goals from raw pixels, matching the performance of experts trained on similar visual inputs. This proves the algorithm successfully extracted the task goal purely from visual observation.

Discussion and Limitations

A key insight from this work is that matching state-transition distributions is more effective than strict time-alignment. Furthermore, on-policy learning helps the agent recover from errors, a common failure mode for off-policy cloning methods like BCO.

However, learning from visual data remains challenging due to partial observability (e.g., hidden physical properties like mass). Future work could integrate policy entropy regularization to improve exploration and robustness, potentially further closing the gap between observation-only and action-aware imitation learning.

Summary updated

BibTeX
@misc{torabi2018generative,
  author = {Faraz Torabi and Garrett Warnell and Peter Stone},
  title = {{Generative Adversarial Imitation from Observation}},
  year = {2018},
  eprint = {1807.06158},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1807.06158},
}
Figure