In traditional imitation learning, the simplest approach is Behavioral Cloning: treating the problem as supervised learning where an agent learns to map states to the exact actions taken by an expert. However, this approach famously suffers from "compounding errors." If the agent makes a tiny mistake and drifts into a state the expert never visited, it has no data on how to recover, leading to a catastrophic spiral away from the target behavior.
A more robust perspective has emerged that treats imitation not as action-copying, but as distribution alignment. In this framework, the goal is to minimize the statistical divergence between the states and actions visited by the agent and those visited by the expert.
The Occupancy Measure
The core mathematical object in this research direction is the occupancy measure (or stationary distribution). Instead of looking at a single trajectory as a sequence of steps, researchers like Jonathan Ho and Stefano Ermon in Generative Adversarial Imitation Learning (GAIL) view behavior as a global distribution over state-action pairs.
If an agent can match the expert's occupancy measure, it is guaranteed to achieve the same long-term results. This works because the occupancy measure inherently contains "recovery" information. If the agent's distribution matches the expert's, the agent "knows" it should be in the expert's state space; if it drifts out, the objective of matching the distribution naturally pulls it back toward the expert's path.
Learning from Observation Alone
One of the most powerful implications of this perspective is that we don't actually need to see the expert's actions to imitate them. In Generative Adversarial Imitation from Observation (GAIfO), Faraz Torabi and colleagues demonstrated that matching the distribution of state transitions ($s, s'$) is often sufficient.
By focusing on the "what" (the states reached) rather than the "how" (the specific motor torques), agents can learn from visual demonstrations like YouTube videos where internal control signals are invisible. This is possible because the environment's physics constrain which actions can cause specific state transitions. As Quang Anh Pham shows in IOSTOM, matching state-to-state transitions captures the expert's underlying intent while allowing the agent to discover its own optimal controls to achieve those transitions.
Divergence Minimization and Optimal Transport
If imitation is distribution matching, the choice of how to measure the distance between distributions becomes critical. Seyed Kamyar Seyed Ghasemipour and Richard S. Zemel argue in A Divergence Minimization Perspective on Imitation Learning Methods that the success of modern imitation learning stems from this explicit objective of matching state-marginals, regardless of the specific mathematical divergence used.
However, standard divergences (like those used in GANs) can be brittle when demonstrations are sparse or timing is inconsistent. To solve this, researchers have turned to Optimal Transport. Algorithms like ZILOT, developed by Thomas Rupf and Jonas Frey, use Wasserstein distances to match distributions.
The intuition here is "geometry-aware" matching: instead of penalizing an agent for not being at the exact coordinate at the exact millisecond the expert was, Optimal Transport looks at the overall "cost" of moving the agent's state distribution to overlap with the expert's. This makes imitation robust to differences in execution speed and temporal offsets, as noted by Kun Ho Kim in the context of Cross Domain Imitation Learning.
Bridging the Reality Gap
This framework also provides a solution to the "reality gap" in robotics. In Mutual Alignment Transfer Learning, Ingmar Posner and Markus Wulfmeier use adversarial distribution alignment to make a simulator and a real-world robot "look" the same to an agent. Similarly, Ishan Durugkar and Josiah Hanna show that grounding a simulator is mathematically equivalent to imitation from observation. By aligning the state transition distributions of the two environments, a policy trained in simulation can transfer seamlessly to the real world because the underlying "physics" (the state distributions) have been synchronized.
Stability through Duality
While early adversarial methods (like GAIL) were often unstable, recent work has moved toward more stable, non-adversarial optimization. Yecheng Jason Ma introduced SMODICE, which uses Fenchel duality to transform the distribution matching problem into a stable regression-like objective. This allows for offline imitation learning, where an agent can learn to match an expert's occupancy measure using only a static dataset of its own past experiences, bypassing the need for expensive and potentially dangerous trial-and-error in the real world.