Abstract
Inverse Reinforcement Learning (IRL) aims to recover the underlying reward function optimized by an expert from observed demonstrations. Traditional IRL methods often require solving a complete reinforcement learning problem in an inner loop for every reward candidate, leading to significant computational overhead. This paper introduces GIRL (Gradient Inverse Reinforcement Learning), a novel approach that bypasses the forward RL bottleneck. By minimizing the norm of the policy gradient with respect to the reward parameters, GIRL identifies the reward function for which the expert's policy is stationary. We provide an analytical solution for linear reward settings (PGIRL) and demonstrate the method's efficiency and robustness on various control benchmarks.
Introduction
In standard Reinforcement Learning (RL), an agent learns an optimal policy given a reward function. Inverse Reinforcement Learning (IRL) reverses this process: given an expert's behavior, we seek to infer the reward function they were optimizing. This is a critical task for apprenticeship learning and understanding complex human or biological behaviors.
The primary challenge in existing IRL frameworks, such as Maximum Entropy IRL or Apprenticeship Learning, is their nested structure. These algorithms iteratively guess a reward and then solve the entire "forward" RL problem to evaluate that guess. This process is computationally prohibitive for high-dimensional or complex environments. GIRL addresses this by asking: Can we recover the reward function directly from data without ever solving the forward RL problem?
Methods
The core insight of GIRL is derived from the Policy Gradient Theorem. If an expert's policy $\pi^E$ is optimal with respect to a reward function $R^E$, then the gradient of the expected return $J$ with respect to the policy parameters $\theta$ must be zero: $\nabla_\theta J = 0$.
GIRL Objective
GIRL frames IRL as an optimization problem where we search for reward parameters $\omega$ that minimize the norm of the policy gradient: $$\min_\omega \|\nabla_\theta J(\pi^E, R_\omega)\|^2$$ This objective essentially finds the reward that makes the expert look like they have already converged to an optimal solution.
Linear Reward and PGIRL
When the reward is a linear combination of features, the problem simplifies significantly. The authors demonstrate that this is equivalent to a Multi-Objective Optimization (MOO) problem where the expert lies on the "Pareto frontier" of different reward components.
For the linear case, the authors propose PGIRL (Plane GIRL), an analytical solution that utilizes the null space of the Jacobian matrix of feature expectations. This allows for identifying reward weights that best explain the expert's behavior without iterative optimization.
Results
The authors evaluated GIRL and PGIRL on two primary domains: the Linear-Quadratic Regulator (LQR) and the Mountain Car benchmark.
Performance on LQR Tasks
The LQR domain served as a proof of concept across various dimensions (2D, 5D, 10D, and 20D). As shown in the figure below, the error in recovered reward weights decreases consistently as the number of expert episodes increases.
Key findings include:
- Computational Efficiency: In the 5D LQR task, PGIRL was approximately two orders of magnitude faster than the iterative GIRL approach while maintaining comparable accuracy.
- Sample Efficiency: On the Mountain Car domain, PGIRL outperformed state-of-the-art baselines like SCIRL and CSI, particularly when provided with very few expert demonstrations (10-30 samples).
- Robustness: The method successfully recovered rewards even when the expert's internal policy parameters were unknown and had to be estimated via Maximum Likelihood Estimation (MLE) from raw trajectories.
Conclusion
GIRL provides a computationally efficient, model-free alternative to traditional IRL methods. By leveraging the stationarity of the optimal policy gradient, it avoids the expensive forward RL loop. While the method requires differentiable policies and assumes near-optimality of the expert, its speed and sample efficiency make it a promising tool for real-world IRL applications.
Summary updated