最大熵强化学习:SAC和Soft Q-learning
介绍最大熵强化学习基础理论和两个主要算法soft actor-critic和soft Q-learning
最大熵强化学习:SAC和Soft Q-learning
1. 最大熵强化学习
- Soft Actor-Critic:Off-Policy Maximum Entropy Deep Reinforcement Learning with a Stochastic Actor
- 离线策略算法
- SAC:基于Soft Q-learning改进而来,使用显示的actor函数
- Soft Q-learning
- 不学习显示的策略函数,而是使用一个Q函数的玻尔兹曼分布
- learning expressive energy-based policies for continuous states and actions
- 增强探索能力
对于一个随机变量X,它的概率密度函数为p,它的熵H定义为: \(H(X) = \mathbb{E}_{x\sim p}[-\log{p(x)}]\) 强化学习中可以使用$H(\pi(*|s))$表示策略$\pi$在状态$s$下的探索能力(随机程度)。
标准强化学习
考虑以下infinite-horizon Markov Decision Process$(S, A, p_s, r)$,状态空间$S$和动作空间$A$是连续的:
- 状态转移方程$p_s: S \times S \times A \rightarrow [0, \infty]$
- 奖励函数$r: S\times A\rightarrow [r_{min}, r_{max}]$
- $\rho_{\pi}(s_t)$和$\rho_{\pi}(s_t, a_t)$分别表示state and state-action marginals of the trajectory distribution induced by a policy $\pi(a_t|s_t)$ 标准强化学习目标是学习以下最优策略: \(\pi_{std}^{*} = \arg\max_{\pi}\sum_{t}\mathbb{E}_{(s_t,a_t)\sim \rho_{\pi}}[r(s_t,a_t)]\)
最大熵强化学习
\(\begin{align} \pi_{maxEnt}^{*} &= \arg\max_{\pi}\sum_{t}\mathbb{E}_{(s_t,a_t)\sim \rho_{\pi}}[r(s_t,a_t)+\alpha H(\pi(*|s_t))]\\ &= \arg\max_{\pi}\sum_{t}\mathbb{E}_{(s_t)\sim \rho_{\pi}}[\sum r(s_t,a_t)+\alpha H(\pi(*|s_t))]\\ \end{align}\) 通过最大化每个状态$s_t$的熵从而增加每个状态$s_t$下的策略探索能力。
This post is licensed under CC BY 4.0 by the author.