Reinforcement Learning:An introduction读书笔记-Chapter 2
来源:互联网 发布:上瘾网络剧拍摄花絮5 编辑:程序博客网 时间:2024/06/01 07:54
- Chapter 2 Multi-arm Bandits
- 1 A k-Armed Bandit Problem
- k-armed bandit problem 是什么
- 问题表示
- 2 Action-Value Methods
- sample-average
- varepsilon-greedy methods
- Example
- 3 Incremental Implementation
- 4 Tracking a Nonstationary Problem
- 5 Optimistic Initial Values
- 6 Upper-Confidence Bound Action Selection
- 7 Gradient Bandit Algorithms
- 8 Associative SearchContextual Bandits
- 1 A k-Armed Bandit Problem
Chapter 2 Multi-arm Bandits
评价性反馈(evaluative feedback):知道这个action有多好,但不知道是不是最好的。
指导性反馈(instructive feedback):已知正确的action是什么,和现在采取的action无关。
本章主要内容是增强学习简化的evaluate,即只在一个状态下的学习,也就是没有连接性的(nonassociative)。
2.1 A k-Armed Bandit Problem
k-armed bandit problem 是什么?
可以类比成一个自动售货机,这个售货机有k个拉杆,也就是有k种选择,每种选择都有一定的回报,且这些回报都是满足一个稳定的概率分布的。问题的目的就是要尽可能最大化总的回报(比如1000次选择后的回报)
问题表示
如果value是知道的,那么我们只要选择大value的action就可以了。如果我们不知道确切的value,那么就要让
这时候就涉及到了exploration和exploitation矛盾的问题,尽管在每次预估的时候都会有一个value最大的action,这个action是greedy action,选择这个action (exploitation)满足了我们最大化回报的目的,但是我们并不知道其他的action会不会有更大的回报,选择其他的action(exploration)可能会造成短期的回报减少,但当找到回报更大的action时,我们的长期回报就会增加。
2.2 Action-Value Methods
sample-average
value
ε -greedy methods
在做选择时最简单的方法就是选value最大的action
但是因为想做一定的exploration,就可以在大部分时间选取greedy-action,但是有很小的几率
这种做法的优势在于,随着时间的延长
Example
该节举了一个10-armed bandit的例子,假设10个action value是从高斯分布(0,1)中选出的,真正的回报又是满足高斯分布(
最后的结果是greedy method虽然在开始增长较快,但最后表现最差;
但随着学习时间及策略的变化,k-armed bandit的任务情况也在不断变化,所以哪怕reward的方差很小,也不能保证在变化中其他action的value会不会超过已知的最优action,所以exploration都是需要的。
2.3 Incremental Implementation
如何使得样本平均值可以更有效的计算出来(常数的内存,每步一次计算)
范式:
这里的
2.4 Tracking a Nonstationary Problem
在不稳定的情况下,让近期的reward占更大比重是有道理的。比较好的解决方法是将步长(
由于系数和
从式子中我们可以看出由于
我们还可以在每一步时都改变参数
这是为了让步长足够大避开一开始的一些波动与干扰,同时还要满足
这是为了让步长足够小以便于收敛。
当
2.5 Optimistic Initial Values
之前讨论的所有方法都是与最开始的action-value有关(
初始的action-value值还可以鼓励agent进行exploration。比如将10-armed bandit问题的初始值设为5,则无论选择哪个action,reward都少于初始值,也就是
2.6 Upper-Confidence Bound Action Selection
如果选择的时候更偏向于有潜力成为最优的non-greedy actions会更好,将它们的估值与最大值的差距以及它们估值的不确定性都考虑进来。
其中
其中平方根项为a value的不确定性或者说是方差。这整个项便是action a可能最大值的上限,c决定了可信度。每次某个action被选择了,那么其不确定性就会降低。相反,当t增加,但是
2.7 Gradient Bandit Algorithms
学会对于每个action a的偏好(preference)。只有相对偏好有用。下述式子中
在每次选择了action
其中
Gradient Bandit Algorithm事实上就是Stochastic Gradient Ascent,证明如下。
Stochastic Gradient Ascent:
根据Stochastic Gradient Ascent的几条性质可以进行推导
接着证明
正因为如此,我们可以保证这个算法和stochastic gradient ascent一样是收敛的,至于baseline,选择什么数都不影响其收敛,但是会影响其收敛速度,选择
2.8 Associative Search(Contextual Bandits)
本节主要讨论结合不同的action到不同的场景中去的做法。
Example:如果有几个不同的k-armed bandit task,在每一步都是随机的碰到其中的一个。在每次action value变化时你会得到变化的提示,比如在第一个机器上做选择时其显示为红色,第二个显示为绿色。这样你就可以选择在红色出现时选择最优的选择arm 1,而在绿色出现时改变策略。
这个问题介于k-armed bandit tasks和完全增强学习问题之间,如果其选择会影响到下一步那么就变成了一个完全增强学习问题。
- Reinforcement Learning:An introduction读书笔记-Chapter 2
- Reinforcement Learning:An Introduction 读书笔记- Chapter 1
- Reinforcement Learning:An introduction读书笔记-Chapter 3
- 《reinforcement learning:an introduction》第一章《The Reinforcement Learning Problem》总结
- 强化学习导论(Reinforcement Learning: An Introduction)读书笔记(一):强化学习介绍
- 强化学习导论(Reinforcement Learning: An Introduction)读书笔记(二):多臂赌博机(Multi-arm Bandits)
- 《reinforcement learning:an introduction》第六章《Temporal-Difference Learning》总结
- 《reinforcement learning:an introduction》第二章《Multi-arm Bandits》总结
- 《reinforcement learning:an introduction》第四章《Dynamic Programming》总结
- 《reinforcement learning:an introduction》第五章《Monte Carlo Methods》总结
- 《reinforcement learning:an introduction》第七章《Multi-step Bootstrapping》总结
- 《reinforcement learning:an introduction》第十三章《Policy Gradient Methods》总结
- 《reinforcement learning:an introduction》第八章《Planning and Learning with Tabular Methods》总结
- introduction-to-reinforcement-learning-implementation
- 《reinforcement learning:an introduction》第三章《Finite Markov Decision Processes》总结
- 《reinforcement learning:an introduction》第九章《On-policy Prediction with Approximation》总结
- 《reinforcement learning:an introduction》第十章《On-policy Control with Approximation》总结
- 《reinforcement learning:an introduction》第十一章《Off-policy Methods with Approximation》总结
- http协议以及几种常见的状态码
- STL学习笔记——2.stack
- Numpy学习笔记
- Django-restframework25 Pagination(分页)
- loongson2f_灵珑9S2A一体机原共创系统下备份设备驱动模块
- Reinforcement Learning:An introduction读书笔记-Chapter 2
- md5加密C语言实现
- 我的第一篇博客
- 开始android 之路(废话篇)
- Django-restframework26 Versioning(版本控制)
- C++笔试题(单向链表)
- Your MATLAB license will expire in 05 days
- A
- 发稿排行>更多