Inverse Reinforcement Learning via Convex Optimization

Hao Zhu, Yuan Zhang, Joschka Boedecker

Abstract

We consider the inverse reinforcement learning (IRL) problem, where an unknown reward function of some Markov decision process is estimated based on observed expert demonstrations. In most existing approaches, IRL is formulated and solved as a nonconvex optimization problem, posing challenges in scenarios where robustness and reproducibility are critical. We discuss a convex formulation of the IRL problem (CIRL) initially proposed by Ng and Russel, and reformulate the problem such that the domain-specific language CVXPY can be applied directly to specify and solve the convex problem. We also extend the CIRL problem to scenarios where the expert policy is not given analytically but by trajectory as state-action pairs, which can be strongly inconsistent with optimality, by augmenting some of the constraints. Theoretical analysis and practical implementation for hyperparameter auto-selection are introduced. This note helps the users to easily apply CIRL for their problems, without background knowledge on convex optimization.

Empirical ResultsBrowse all benchmarks →

BenchmarkMethodMetricScoreProtocol / Evidence
The greedy snake environmentCIRL with augmented constraints for trajectory segmentsfraction of the matched action through the whole trajectory0.94resolution=48x48
Source quote
L262: This leads to a 0.94 fraction of the matched action through the whole trajectory between the observed expert action and the predicted optimal action under the estimated reward.
The greedy snake environmentCIRL with augmented constraints for trajectory segmentstotal computing time432 msresolution=48x48
Source quote
L267: The average computing time for the individual trajectory segments are 9.01 ± 1.10 ms (mean ± standard error), which corresponds to a total computing time of 432 ms.
BibTeX
@misc{zhu2025inverse,
  author = {Hao Zhu and Yuan Zhang and Joschka Boedecker},
  title = {{Inverse Reinforcement Learning via Convex Optimization}},
  year = {2025},
  eprint = {2501.15957},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2501.15957},
}

Loading related content...

Figure