強化學習教父 Richard Sutton 的經典教材《Reinforcement Learning:An Introduction》第二版公布啦。本書分為三大部分,共十七章,機器之心對其簡介和框架做了扼要介紹,並附上了全書目錄、課程代碼與資料。下載《強化學習》PDF 請點擊文末「閱讀原文」。
書籍百度網盤:https://pan.baidu.com/s/1miP38tM
原書籍地址:http://incompleteideas.net/sutton/book/bookdraft2017nov5.pdf
課程代碼地址:https://github.com/ShangtongZhang/reinforcement-learning-an-introduction
課程資料地址:http://incompleteideas.net/sutton/book/the-book-2nd.html
簡介
當我們思考學習的本質時,首先映入腦海的想法很可能是通過與環境的交互進行學習。當一個嬰兒玩耍時,揮舞手臂,左顧右盼,旁邊沒有老師指導他,他與環境卻有著一種直接的感知連接。通過這種連接,他懂得了因果關係,行動帶來的結果,以及為了達成目標所需做的一切。人的一生中,這樣的交互成了我們關於環境和自身知識的主要來源。不管學習駕駛汽車,還是進行一場交談,實際上我們自始至終觀察著環境如何回應我們的所為,並通過自身行為影響當下情景。交互式學習幾乎是所有學習與智能理論的基石。
本書中我們提出了一種通過計算實現交互式學習的方法。我們沒有直接理論化人類或動物的學習方式,而是探索理想的學習環境,評估不同學習方法的有效性。即,我們站在人工智慧研究者或工程師的角度來解決問題。我們探討了在解決科學或經濟問題方面表現突出的機器的設計,通過數學分析或計算實驗評估其設計。我們提出的這一方法稱之為強化學習。相較於其他機器學習方法,它更專注於交互之中的目標導向性學習。
第一部分:列表(Tabular)解決法
本書第一部分我們以最簡單形式描述了強化學習算法幾乎所有的核心的概念,即狀態和動作空間要足夠小,保證近似值函數被表徵為數組或表格。本案例中,這些方法經常能夠發現正確方案,即找到最優值函數和最優策略。這與本書第二部分描述的、只能找到近似方案的近似法(但反過來它可有效用於解決更大的問題)形成了鮮明對比。
本書第一部分的第一章描述了強化學習問題具體案例的解決方案,其中只有一個稱為土匪問題(bandit problem)的單一狀態。第二章描述了貫穿全書的一般問題制定——有限馬爾科夫決策過程,其主要思想包括貝爾曼方程(Bellman equation)和價值函數。
第三、四、五章介紹了解決有限馬爾科夫決策問題的三類基本方法:動態編程,蒙特卡洛方法、時序差分學習。三者各有其優缺點。動態編程偏向數學,但是需要完整和精確的環境模型。蒙特卡洛無需模型,概念也很簡單,但是不適用於一步一步的增量計算。時序差分方法也不需要模型,並且是完全增量的,但是分析異常困難。三者在效率和收斂速度方面也各有其不同。
第六、七章介紹了上述三類方法如何結合在一起進而達到最佳效果。第六章中我們介紹了可使用適合度軌跡(eligibility traces)把蒙特卡洛方法和時序差分學習的優勢整合起來。第七章中我們表明時序差分學習可與模型學習和規劃方法(比如動態編程)結合起來,獲得一個解決列表強化學習(tabular reinforcement learning)問題的完整而統一的方案。
第二部分:近似求解法
本書第二部分將擴展第一部分中介紹的列表法以應用於任意大的狀態空間。我們希望應用強化學習的諸多任務中的狀態空間都是組合性的和龐大的;例如,可能存在的圖像的數量遠遠大於宇宙中的原子的總數。在這樣的案例中我們甚至不能在無限的時間和數據極限內找到最優策略或最優值函數,因此我們的目標需要換成使用有限的計算資源尋找足夠好的近似解。在本書的這一部分我們將探索多種近似解法。
大型狀態空間的問題不僅僅在於需要為大型的列表分配的內存,還有使其達到足夠的準確率需要的時間和數據量。我們很多的目標任務中幾乎每一個遇到的狀態都是前所未見的。為了在這樣的狀態中做出合理的決策,從先前遇到的和當前狀態在某種程度上相似的多種狀態進行泛化是很有必要的。換一種說法,問題的關鍵就是泛化能力。狀態空間的有限子集的經驗如何有效地泛化以對相對大得多的子集生成足夠好的近似解呢?
幸運的是,從樣本中泛化的問題已經被廣泛地研究過,我們並不需要在強化學習中發明全新的方法;從某種程度上講只需要將強化學習方法和已有的泛化方法結合起來。我們需要的泛化方法通常稱為函數逼近,這是因為這種方法從所需的函數(例如,價值函數)中採樣,然後從中泛化以構建完整函數的近似。函數逼近是監督學習的一個實例,也是機器學習、人工神經網絡、模式識別和統計曲線擬合中最重要的研究課題。從理論上看,在這些領域中研究過的任何方法都可以用作強化學習算法中的函數逼近器,雖然實際上有些方法比起其它更加適用於強化學習。
在強化學習中使用函數逼近涉及一些在傳統的監督學習中不常出現的新問題,比如非穩定性(nonstationarity)、引導(bootstrapping)和目標延遲(delayed targets)。我們將在這部分的五章中先後介紹這些以及其它問題。我們首先集中討論在線(on-policy)訓練,而在第九章中的預測案例其策略是給定的,只有其價值函數是近似的,在第十章中的控制案例中最優策略的一個近似已經找到。函數逼近的離線(off-policy)學習的困難將在第十一章討論。在這三章的每一章中我們都必須從基本原理開始,並複查函數逼近的學習目標。第十二章將介紹和分析適合度軌跡(eligibility traces)的算法機制,它能在多個案例中顯著優化多步強化學習方法的計算特性。這一部分的最後一章將探索一種不同的控制、策略梯度的方法,它能直接逼近最優策略且完全不需要設定近似值函數(雖然如果使用了一個逼近價值函數,效率會高得多)。
第三部分:更進一步
在本書的最後一部分我們將把眼光放到第一、二部分中介紹標準的強化學習思想之外,簡單地概述它們和心理學以及神經科學的關係,討論一個強化學習應用的採樣過程,和一些未來的強化學習研究的活躍前沿。
以下是該書籍的目錄:
1 Introduction
1.1 Reinforcement Learning
1.2 Examples
1.3 Elements of Reinforcement Learning
1.4 Limitations and Scope
1.5 An Extended Example: Tic-Tac-Toe
1.6 Summary
1.7 Early History of Reinforcement Learning
I Tabular Solution Methods
2 Multi-armed Bandits
2.1 A k-armed Bandit Problem
2.2 Action-value Methods
2.3 The 10-armed Testbed
2.4 Incremental Implementation
2.5 Tracking a Nonstationary Problem
2.6 Optimistic Initial Values
2.7 Upper-Condence-Bound Action Selection
2.8 Gradient Bandit Algorithms
2.9 Associative Search (Contextual Bandits)
2.10 Summary
3 Finite Markov Decision Processes
3.1 The Agent{Environment Interface
3.2 Goals and Rewards
3.3 Returns and Episodes
3.4 Unied Notation for Episodic and Continuing Tasks
3.5 Policies and Value Functions
3.6 Optimal Policies and Optimal Value Functions
3.7 Optimality and Approximation
3.8 Summary
4 Dynamic Programming
4.1 Policy Evaluation (Prediction)
4.2 Policy Improvement
4.3 Policy Iteration
4.4 Value Iteration
4.5 Asynchronous Dynamic Programming
4.6 Generalized Policy Iteration
4.7 Eciency of Dynamic Programming
4.8 Summary
5 Monte Carlo Methods
5.1 Monte Carlo Prediction
5.2 Monte Carlo Estimation of Action Values
5.3 Monte Carlo Control
5.4 Monte Carlo Control without Exploring Starts
5.5 O-policy Prediction via Importance Sampling
5.6 Incremental Implementation
5.7 O-policy Monte Carlo Control
5.8 *Discounting-aware Importance Sampling
5.9 *Per-reward Importance Sampling
5.10 Summary
6 Temporal-Dierence Learning
6.1 TD Prediction
6.2 Advantages of TD Prediction Methods
6.3 Optimality of TD(0)
6.4 Sarsa: On-policy TD Control
6.5 Q-learning: O-policy TD Control
6.6 Expected Sarsa
6.7 Maximization Bias and Double Learning
6.8 Games, Afterstates, and Other Special Cases
6.9 Summary
7 n -step Bootstrapping
7.1 n-step TD Prediction
7.2 n-step Sarsa
7.3 n-step O-policy Learning by Importance Sampling
7.4 *Per-reward O-policy Methods
7.5 O-policy Learning Without Importance Sampling:
The n-step Tree Backup Algorithm
7.6 *A Unifying Algorithm: n-step Q()
7.7 Summary
8 Planning and Learning with Tabular Methods
8.1 Models and Planning
8.2 Dyna: Integrating Planning, Acting, and Learning
8.3 When the Model Is Wrong
8.4 Prioritized Sweeping
8.5 Expected vs. Sample Updates
8.6 Trajectory Sampling
8.7 Real-time Dynamic Programming
8.8 Planning at Decision Time
8.9 Heuristic Search
8.10 Rollout Algorithms
8.11 Monte Carlo Tree Search
8.12 Summary of the Chapter
8.13 Summary of Part I: Dimensions
II Approximate Solution Methods
9 On-policy Prediction with Approximation
9.1 Value-function Approximation
9.2 The Prediction Objective (VE)
9.3 Stochastic-gradient and Semi-gradient Methods
9.4 Linear Methods
9.5 Feature Construction for Linear Methods
9.5.1 Polynomials
9.5.2 Fourier Basis
9.5.3 Coarse Coding
9.5.4 Tile Coding
9.5.5 Radial Basis Functions
9.6 Nonlinear Function Approximation: Articial Neural Networks
9.7 Least-Squares TD
9.8 Memory-based Function Approximation
9.9 Kernel-based Function Approximation
9.10 Looking Deeper at On-policy Learning: Interest and Emphasis
9.11 Summary
10 On-policy Control with Approximation
10.1 Episodic Semi-gradient Control
10.2 n-step Semi-gradient Sarsa
10.3 Average Reward: A New Problem Setting for Continuing Tasks
10.4 Deprecating the Discounted Setting
10.5 n-step Dierential Semi-gradient Sarsa
10.6 Summary
11 O-policy Methods with Approximation
11.1 Semi-gradient Methods
11.2 Examples of O-policy Divergence
11.3 The Deadly Triad
11.4 Linear Value-function Geometry
11.5 Stochastic Gradient Descent in the Bellman Error
11.6 The Bellman Error is Not Learnable
11.7 Gradient-TD Methods
11.8 Emphatic-TD Methods
11.9 Reducing Variance
11.10 Summary
12 Eligibility Traces
12.1 The -return
12.2 TD()
12.3 n-step Truncated -return Methods
12.4 Redoing Updates: The Online -return Algorithm
12.5 True Online TD()
12.6 Dutch Traces in Monte Carlo Learning
12.7 Sarsa()
12.8 Variable and
12.9 O-policy Eligibility Traces
12.10 Watkins's Q() to Tree-Backup()
12.11 Stable O-policy Methods with Traces
12.12 Implementation Issues
12.13 Conclusions
13 Policy Gradient Methods
13.1 Policy Approximation and its Advantages
13.2 The Policy Gradient Theorem
13.3 REINFORCE: Monte Carlo Policy Gradient
13.4 REINFORCE with Baseline
13.5 Actor{Critic Methods
13.6 Policy Gradient for Continuing Problems
13.7 Policy Parameterization for Continuous Actions
13.8 Summary
III Looking Deeper
14 Psychology
14.1 Prediction and Control
14.2 Classical Conditioning
14.2.1 Blocking and Higher-order Conditioning
14.2.2 The Rescorla{Wagner Model
14.2.3 The TD Model
14.2.4 TD Model Simulations
14.3 Instrumental Conditioning
14.4 Delayed Reinforcement
14.5 Cognitive Maps
14.6 Habitual and Goal-directed Behavior
14.7 Summary
15 Neuroscience
15.1 Neuroscience Basics
15.2 Reward Signals, Reinforcement Signals, Values, and Prediction Errors
15.3 The Reward Prediction Error Hypothesis
15.4 Dopamine
15.5 Experimental Support for the Reward Prediction Error Hypothesis
15.6 TD Error/Dopamine Correspondence
15.7 Neural Actor Critic
15.8 Actor and Critic Learning Rules
15.9 Hedonistic Neurons
15.10 Collective Reinforcement Learning
15.11 Model-based Methods in the Brain
15.12 Addiction
15.13 Summary
16 Applications and Case Studies
16.1 TD-Gammon
16.2 Samuel's Checkers Player
16.3 Watson's Daily-Double Wagering
16.4 Optimizing Memory Control
16.5 Human-level Video Game Play
16.6 Mastering the Game of Go
16.6.1 AlphaGo
16.6.2 AlphaGo Zero
16.7 Personalized Web Services
16.8 Thermal Soaring
17 Frontiers
17.1 General Value Functions and Auxiliary Tasks
17.2 Temporal Abstraction via Options
17.3 Observations and State
17.4 Designing Reward Signals
17.5 Remaining Issues
17.6 Reinforcement Learning and the Future of Articial Intelligence
本文為機器之心編譯,轉載請聯繫本公眾號獲得授權。
✄---
加入機器之心(全職記者/實習生):hr@jiqizhixin.com
投稿或尋求報導:content@jiqizhixin.com
廣告&商務合作:bd@jiqizhixin.com