Skip to main content
QUICK REVIEW

[论文解读] Hyperparameters in Reinforcement Learning and How To Tune Them

Theresa Eimer, Marius Lindauer|arXiv (Cornell University)|Jun 2, 2023
Machine Learning and Data ClassificationComputer Science被引用 9
一句话总结

本文认为 RL 超参数对性能和可重复性具有强烈影响,并显示自动超参数优化(HPO)常常在降低计算量的情况下胜过手工调优;它提供 RL 的最佳实践指南和开源调参工具。

ABSTRACT

In order to improve reproducibility, deep reinforcement learning (RL) has been adopting better scientific practices such as standardized evaluation metrics and reporting. However, the process of hyperparameter optimization still varies widely across papers, which makes it challenging to compare RL algorithms fairly. In this paper, we show that hyperparameter choices in RL can significantly affect the agent's final performance and sample efficiency, and that the hyperparameter landscape can strongly depend on the tuning seed which may lead to overfitting. We therefore propose adopting established best practices from AutoML, such as the separation of tuning and testing seeds, as well as principled hyperparameter optimization (HPO) across a broad search space. We support this by comparing multiple state-of-the-art HPO tools on a range of RL algorithms and environments to their hand-tuned counterparts, demonstrating that HPO approaches often have higher performance and lower compute overhead. As a result of our findings, we recommend a set of best practices for the RL community, which should result in stronger empirical results with fewer computational costs, better reproducibility, and thus faster progress. In order to encourage the adoption of these practices, we provide plug-and-play implementations of the tuning algorithms used in this paper at https://github.com/facebookresearch/how-to-autorl.

研究动机与目标

  • 在不同环境中展示 RL 超参数对最终性能和样本效率的影响。
  • 在最前沿的 RL 算法上,将多种 HPO 方法与手工调优基线进行对比评估。
  • 提供开源、即插即用的调参工具以及面向 RL 社区的实用最佳实践建议。
  • 强调分离调优种子与测试种子以避免过拟合并提高可重复性的重要性。

提出的方法

  • 在 RL 中将超参数优化正式定义为 Algorithm Configuration (AC) 和 Dynamic Algorithm Configuration (DAC)。
  • 通过多种种子,在多样的 Gym-like 与 Brax/Procgen 环境中对 PPO、DQN 与 SAC 的超参数空间进行实证研究。
  • 将 RS(随机搜索)、多保真度方法(DEHB)和基于群体的调参(PB2、BGT)与手工调优基线进行比较。
  • 评估调优种子与测试种子在可重复性和性能估计上的影响。
  • 提供开源、基于 Hydra 的调参实现,兼容任何 RL 算法或环境。
Figure 1: Comparison of Hyperparameter Tuning Approaches: state-of-the-art hyperparameter optimization packages match or outperform hand tuning via grid search, while using less than 1/12 of the budget.
Figure 1: Comparison of Hyperparameter Tuning Approaches: state-of-the-art hyperparameter optimization packages match or outperform hand tuning via grid search, while using less than 1/12 of the budget.

实验结果

研究问题

  • RQ1RL 的超参数在不同环境和算法下对最终性能和稳定性有多大影响?
  • RQ2在 RL 中,传统的手工调参相比自动超参数优化是否效率更低?
  • RQ3在预算有限的 RL 设置中,不同的 HPO范式(RS、多保真度、PBT)表现如何?
  • RQ4哪些最佳实践(种子分离、报告、集成到管道中)能够提升 RL 实验的可重复性和可比较性?

主要发现

  • 超参数在不同环境和算法上的影响很大;即使是很少被调的参数也可能决定成败。
  • RL 的超参数空间通常较为平滑,在适度预算下可用简单方法实现有效优化。
  • 随机搜索在某些任务上可以与更复杂的设置相匹配甚至超越,但多保真度和 PBT 方法通常在不同预算下提高稳定性和最终性能。
  • 分离调优种子和测试种子对于避免过拟合、获得对泛化性能的可靠估计至关重要。
  • 自动化 HPO 方法通常比穷举手工调优或网格搜索需要更少的计算,并提供更稳健、可比的基线。
Figure 5: Tuning Results for PPO on Brax. Shown is the mean evaluation reward across $10$ episodes for $3$ tuning runs as well as the $98\%$ confidence interval across tuning runs.
Figure 5: Tuning Results for PPO on Brax. Shown is the mean evaluation reward across $10$ episodes for $3$ tuning runs as well as the $98\%$ confidence interval across tuning runs.

阅读本论文

在 Nubint 阅读器中打开原文,边读边就任意段落提问。

在 Nubint 中阅读本论文

本解读由 AI 根据论文原文生成,引用前请核对原文。