Robust Visual Imitation Learning with Inverse Dynamics Representations

Siyuan Li, Xun Wang, Rongchang Zuo, Kewu Sun, Lingfei Cui, Jishiyu Ding, Peng Liu, Zhe Ma

Presented at AAAI-24, RILIR (Robust visual Imitation Learning with Inverse dynamics Representations) is a framework designed to enable robots to learn from expert demonstrations even when their learning environment differs significantly from the expert's. By focusing on action-relevant features, RILIR overcomes the "correspondence problem" where visual distractors typically degrade imitation performance.

The Challenge of Visual Correspondence

Imitation Learning (IL) often assumes that the expert's environment and the agent's environment are identical. In real-world applications, this is rarely the case. An expert might be recorded in a clean simulator, while a physical robot must learn in a lab with varying lighting, moving backgrounds, or sensor noise.

Standard methods like Generative Adversarial Imitation Learning (GAIL) often fail in these scenarios because their reward functions (discriminators) become distracted by visual differences. If a background changes, the discriminator may penalize the agent for pixel-level mismatches, even if the physical movement is correct. RILIR addresses this by learning representations that are invariant to environmental noise.

Methodology

RILIR achieves robustness through a two-pronged approach involving specialized state representation and a hybrid reward system.

1. Inverse Dynamics State Representation

Instead of a standard image encoder, RILIR utilizes an inverse dynamics objective to train its representation function $\phi$. The model is tasked with predicting the action $a_t$ that occurred between two consecutive frames, $\phi(o_t)$ and $\phi(o_{t+1})$. Since environmental noise (like a moving background) does not influence the robot's actions, the encoder learns to ignore these distractors, focusing exclusively on the robot and relevant objects.

2. Dual-Scale Imitative Reward

To provide a stable learning signal, RILIR combines two reward types:

  • Macro-level (Trajectory Matching): Using the Sinkhorn algorithm for Optimal Transport, the agent aligns its entire state sequence with the expert's trajectory, providing a global goal.
  • Micro-level (Discriminator): A GAIL-style discriminator operates on the learned latent space to provide fine-grained feedback on individual state-action pairs.
The RILIR architecture: (a) learning action-centric representations via inverse dynamics, and (b) generating dual-scale imitative rewards.

Experimental Evaluation

The authors evaluated RILIR on the DeepMind Control Suite (DMC) (e.g., CartPole Swingup, Walker Stand) and Meta-World manipulation tasks (Hammer, Drawer Close). To test robustness, they introduced three types of visual shifts:

  • Changing Backgrounds: Using distracting video backgrounds.
  • White Noise: Pixel-level interference.
  • Random Masking: Blacking out random patches of the observation.

Key Results and Insights

RILIR demonstrated superior robustness across all tested perturbations. In the Walker Stand task with changing backgrounds, RILIR maintained near-expert performance (average return ~950), while baselines like ROT and DAC dropped below 400. In Meta-World's Drawer Close task, RILIR achieved a 100% success rate significantly faster than baselines, many of which failed to converge under masking noise.

Performance of RILIR vs. baselines across different noise types. RILIR (red) consistently maintains high performance where others fail.

Why it Works

  • Action-Centricity: By solving the "what action caused this change?" puzzle, the network naturally filters out irrelevant background movement. Saliency maps confirmed that RILIR's attention remains locked on the robot's limbs and tools.
  • Hybrid Reward Stability: Trajectory matching provides a stationary reward that prevents the "moving target" problem common in adversarial learning, where the policy and discriminator can enter unstable cycles.

Limitations and Future Work

While highly effective, RILIR assumes that the underlying physics (dynamics) of the expert and learner environments are consistent. If the learner's robot has different joint friction or mass, the inverse dynamics objective may require further adaptation. Additionally, calculating Optimal Transport can be computationally intensive, and extreme domain gaps (e.g., different camera angles) remain a challenge for future research.

Summary updated

BibTeX
@inproceedings{li2024robust,
  author = {Siyuan Li and Xun Wang and Rongchang Zuo and Kewu Sun and Lingfei Cui and Jishiyu Ding and Peng Liu and Zhe Ma},
  title = {{Robust Visual Imitation Learning with Inverse Dynamics Representations}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2024},
  doi = {10.1609/aaai.v38i12.29265},
}
Figure