Lecture 7: Value Function Approximation

Size: px
Start display at page:

Download "Lecture 7: Value Function Approximation"

Transcription

1 Lecture 7: Value Function Approximation Joseph Modayil

2 Outline 1 Introduction 2 3 Batch Methods

3 Introduction Large-Scale Reinforcement Learning Reinforcement learning can be used to solve large problems, e.g. Backgammon: states Computer Go: states Helicopter/Mountain Car: continuous state space Robots: informal state space (physical universe) How can we scale up the model-free methods for prediction and control from the last two lectures?

4 Introduction Value Function Approximation So far we have represented value function by a lookup table Every state s has an entry V (s) Or every state-action pair s, a has an entry Q(s, a) Problem with large MDPs: There are too many states and/or actions to store in memory It is too slow to learn the value of each state individually Solution for large MDPs: Estimate value function with function approximation V θ (s) v π (s) or Q θ (s, a) q π (s, a) Generalise from seen states to unseen states Update parameter θ using MC or TD learning

5 Introduction Which Function Approximator? There are many function approximators, e.g. Artificial neural network Decision tree Nearest neighbour Fourier / wavelet bases Coarse coding In principle, any function approximator can be used. However, the choice may be affected by some properties of RL: Experience is not i.i.d. - successive time-steps are correlated During control, value function v π (s) is non-stationary Agent s actions affect the subsequent data it receives Feedback is delayed, not instantaneous

6 Introduction Classes of Function Approximation Tabular (No FA): a table with an entry for each MDP state State Aggregation: Partition environment states Linear function approximation: fixed features (or fixed kernel) Differentiable (nonlinear) function approximation: neural nets So what should you choose? Depends on your goals. Top: good theory but weak performance. Bottom: excellent performance but weak theory Linear function approximation is a useful middle ground Neural nets now commonly give the highest performance

7 Gradient Descent Gradient Descent Let J(θ) be a differentiable function of parameter vector θ Define the gradient of J(θ) to be θ J(θ) = To find a local minimum of J(θ) J(θ) θ 1. J(θ) θ n Adjust the parameter θ in the direction of -ve gradient θ = 1 2 α θj(θ) where α is a step-size parameter

8 Gradient Descent Value Function Approx. By Stochastic Gradient Descent Goal: find parameter vector θ minimising mean-squared error between approximate value fn V θ (s) and true value fn v π (s) J(θ) = E π [ (v π (S) V θ (S)) 2] Note: The notation E π [] means that the random variable S is drawn from a distribution induced by π. E π [f (S)] = s f (s)d π(s) Gradient descent finds a local minimum θ = 1 2 α θj(θ) = αe π [(v π (S) V θ (S)) θ V θ (S)] Stochastic gradient descent samples the gradient θ = α(v π (s) V θ (s)) θ V θ (s) Expected update is equal to full gradient update

9 Linear Function Approximation Feature Vectors Represent state by a feature vector φ 1 (s) φ(s) =. φ n (s) For example: Distance of robot from landmarks Trends in the stock market Piece and pawn configurations in chess

10 Linear Function Approximation Linear Value Function Approximation Approximate value function by a linear combination of features V θ (s) = φ(s) θ = n φ j (s)θ j j=1 Objective function is quadratic in parameters θ J(θ) = E π [ (v π (S) φ(s) θ) 2] Stochastic gradient descent converges on global optimum Update rule is particularly simple θ V θ (s) = φ(s) θ = α(v π (s) V θ (s))φ(s) Update = step-size prediction error feature vector

11 Linear Function Approximation Table Lookup Features Table lookup can be implemented as a special case of linear value function approximation Let the n states be given by S = {s (1),..., s (n) }. Using table lookup features φ table (s) = 1(s = s (1) ). 1(s = s (n) ) Parameter vector θ gives value of each individual state 1(s = s (1) ) θ 1 V (s) =.. 1(s = s (n) ) θ n

12 Coarse Coding Example Coarse Coding Example of linear value function approximation: Coarse coding provides large feature vector φ(s) Parameter vector θ gives a value to each feature original representation expanded representation, many features t approximation

13 Coarse Coding Example Generalization in Coarse Coding

14 Coarse Coding Example Stochastic Gradient Descent with Coarse Coding

15 Incremental Prediction Algorithms Incremental Prediction Algorithms Have assumed true value function v π (s) given by supervisor But in RL there is no supervisor, only rewards In practice, we substitute a target for v π (s) For MC, the target is the return G t θ = α(g t V θ (s)) θ V θ (s) For TD(0), the target is the TD target r + γv θ (s ) θ = α(r + γv θ (s ) V θ (s)) θ V θ (s) For TD(λ), the target is the λ-return G λ t θ = α(gt λ V θ (s)) θ V θ (s)

16 Incremental Prediction Algorithms Monte-Carlo with Value Function Approximation The return G t is an unbiased, noisy sample of true value v π (s) Can therefore apply supervised learning to training data : S 1, G 1, S 2, G 2,..., S T, G T For example, using linear Monte-Carlo policy evaluation θ = α(g t V θ (s)) θ V θ (s) = α(g t V θ (s))φ(s) Monte-Carlo evaluation converges to a local optimum Even when using non-linear value function approximation

17 Incremental Prediction Algorithms TD Learning with Value Function Approximation The TD-target R t+1 + γv θ (S t+1 ) is a biased sample of true value v π (S t ) Can still apply supervised learning to training data : S 1, R 2 + γv θ (S 2 ), S 2, R 3 + γv θ (S 3 ),..., S T 1, R T For example, using linear TD(0) θ = α(r + γv θ (s ) V θ (s)) θ V θ (s) = αδφ(s) Linear TD(0) converges (close) to global optimum

18 Incremental Prediction Algorithms TD(λ) with Value Function Approximation The λ-return Gt λ is also a biased sample of true value v π (s) Can again apply supervised learning to training data : S 1, G1 λ, S 2, G2 λ,..., S T 1, GT λ 1 Forward view linear TD(λ) Backward view linear TD(λ) θ = α(g λ t V θ (S t )) θ V θ (S t ) = α(g λ t V θ (S t ))φ(s t ) δ t = R t+1 + γv θ (S t+1 ) V θ (S t ) e t = γλe t 1 + φ(s t ) θ = αδ t e t

19 Incremental Control Algorithms Control with Value Function Approximation Q θ Q π Starting θ Q θ Q * π = ε-greedy(q θ ) Policy evaluation Approximate policy evaluation, Q θ q π Policy improvement ɛ-greedy policy improvement

20 Incremental Control Algorithms Action-Value Function Approximation Approximate the action-value function Q θ (s, a) q π (s, a) Minimise mean-squared error between approximate action-value fn Q θ (s, a) and true action-value fn q π (s, a) J(θ) = E π [ (q π (S, A) Q θ (S, A)) 2] Here, E π [] means both S and A are drawn from a distribution induced by π. Use stochastic gradient descent to find a local minimum 1 2 θj(θ) = (q π (s, a) Q θ (s, a)) θ Q θ (s, a) θ = α(q π (s, a) Q θ (s, a)) θ Q θ (s, a)

21 Incremental Control Algorithms Linear Action-Value Function Approximation Represent state and action by a feature vector φ 1 (s, a) φ(s, a) =. φ n (s, a) Represent action-value fn by linear combination of features n Q θ (s, a) = φ(s, a) θ = φ j (s, a)θ j j=1 Stochastic gradient descent update θ Q θ (s, a) = φ(s, a) θ = α(q π (s, a) Q θ (s, a))φ(s)

22 Incremental Control Algorithms Incremental Linear Control Algorithms Like prediction, we must substitute a target for q π (s, a) For MC, the target is the return G t θ = α(g t Q θ (S t, a t ))φ(s t, A t ) For SARSA(0), the target is the TD target R t+1 + γq(s t+1, A t+1 ) θ = α(r t+1 + γq θ (S t+1, A t+1 ) Q θ (S t, A t ))φ(s t, A t ) For forward-view Sarsa(λ), target is the λ-return with action-values θ = α(g λ t Q θ (S t, A t ))φ(s t, A t ) For backward-view Sarsa(λ), equivalent update is δ t = R t+1 + γq θ (S t+1, A t+1 ) Q θ (S t, A t ) e t = γλe t 1 + φ(s t, A t ) θ = αδ t e t

23 Mountain Car Linear Sarsa with Coarse Coding in Mountain Car

24 Mountain Car Linear Sarsa with Radial Basis Functions in Mountain Car

25 Mountain Car Study of λ: Should We Bootstrap?

26 Convergence Convergence Questions The previous results show it is desirable to bootstrap But now we consider convergence issues When do incremental prediction algorithms converge? When using bootstrapping (i.e. TD with λ < 1)? When using linear value function approximation? When using off-policy learning? Ideally, we would like algorithms that converge in all cases

27 Convergence Baird s Counterexample

28 Convergence Parameter Divergence in Baird s Counterexample

29 Convergence Convergence of Prediction Algorithms On/Off-Policy Algorithm Table Lookup Linear Non-Linear MC On-Policy TD(0) TD(λ) MC Off-Policy TD(0) TD(λ)

30 Convergence Gruesome Threesome We have not quite achieved our ideal goal for prediction algorithms.

31 Convergence Gradient Temporal-Difference Learning TD does not follow the gradient of any objective function This is why TD can diverge when off-policy or using non-linear function approximation Gradient TD follows true gradient of projected Bellman error On/Off-Policy Algorithm Table Lookup Linear Non-Linear MC On-Policy TD Gradient TD MC Off-Policy TD Gradient TD

32 Convergence Convergence of Control Algorithms In practice, the tabular control learning algorithms are extended to find a control policy (with linear FA or with neural nets). In theory, many aspects of control are not as simple to specify under function approximation. e.g. The starting state distribution is required before specifying an optimal policy, unlike in the tabular setting. The optimal policy can differ starting from state s (1) and from state s (2), but the state aggregation may not be able to distinguish between them. Such situations commonly arise in large environments (e.g. robotics), and tracking is often preferred to convergence. (continually adapting the policy instead of converging to a fixed policy).

33 Batch Methods Batch Reinforcement Learning Gradient descent is simple and appealing But it is not sample efficient Batch methods seek to find the best fitting value function for a given a set of past experience ( training data )

34 Batch Methods Least Squares Prediction Least Squares Prediction Given value function approximation V θ (s) v π (s) And experience D consisting of state, estimated value pairs D = { S 1, ˆV 1 π, S 2, ˆV 2 π,..., S T, ˆV T π } Which parameters θ give the best fitting value fn V θ (s)? Least squares algorithms find parameter vector θ minimising sum-squared error between V θ (S t ) and target values ˆV π t, LS(θ) = T t=1 ( ˆV π t V θ (S t )) 2 = E D [ ( ˆV π V θ (s)) 2]

35 Batch Methods Least Squares Prediction Stochastic Gradient Descent with Experience Replay Given experience consisting of state, value pairs D = { S 1, ˆV 1 π, S 2, ˆV 2 π,..., S T, ˆV T π } Repeat: 1 Sample state, value from experience s, ˆV π D 2 Apply stochastic gradient descent update θ = α( ˆV π V θ (s)) θ V θ (s) Converges to least squares solution θ π = argmin θ LS(θ)

36 Batch Methods Least Squares Prediction Linear Least Squares Prediction Experience replay finds least squares solution But it may take many iterations Using linear value function approximation V θ (s) = φ(s) θ We can solve the least squares solution directly

37 Batch Methods Least Squares Prediction Linear Least Squares Prediction (2) At minimum of LS(θ), the expected update must be zero α T t=1 E D [ θ] = 0 φ(s t )( ˆV π t φ(s t ) θ) = 0 T t=1 φ(s t ) ˆV π t = T φ(s t )φ(s t ) θ t=1 ( T ) 1 θ = φ(s t )φ(s t ) t=1 For N features, direct solution time is O(N 3 ) T t=1 φ(s t ) ˆV π t Incremental solution time is O(N 2 ) using Shermann-Morrison

38 Batch Methods Least Squares Prediction Linear Least Squares Prediction Algorithms We do not know true values vt π (have estimates ˆV t π ) In practice, our training data must use noisy or biased samples of vt π LSMC Least Squares Monte-Carlo uses return vt π G t LSTD Least Squares Temporal-Difference uses TD target vt π R t+1 + γv θ (S t+1 ) LSTD(λ) Least Squares TD(λ) uses λ-return vt π Vt λ In each case solve directly for fixed point of MC / TD / TD(λ)

39 Batch Methods Least Squares Prediction Linear Least Squares Prediction Algorithms (2) T LSMC 0 = α(g t V θ (S t ))φ(s t ) t=1 ( T ) 1 θ = φ(s t )φ(s t ) t=1 T t=1 φ(s t )G t T LSTD 0 = α(r t+1 + γv θ (S t+1 ) V θ (S t ))φ(s t ) t=1 ( T ) 1 T θ = φ(s t )(φ(s t ) γφ(s t+1 )) φ(s t )R t+1 t=1 T LSTD(λ) 0 = αδ t e t t=1 ( T ) 1 θ = e t (φ(s t ) γφ(s t+1 )) T t=1 t=1 t=1 e t R t+1

40 Batch Methods Least Squares Prediction Convergence of Linear Least Squares Prediction Algorithms On/Off-Policy Algorithm Table Lookup Linear Non-Linear MC On-Policy LSMC - TD LSTD - Off-Policy MC LSMC - TD LSTD -

41 Batch Methods Least Squares Control Least Squares Policy Iteration Q θ Q π Starting θ Q θ Q * π = greedy(q θ ) Policy evaluation Policy evaluation by least squares Q-learning Policy improvement Greedy policy improvement

42 Batch Methods Least Squares Control Least Squares Action-Value Function Approximation Approximate action-value function q π (s, a) using linear combination of features φ(s, a) Q θ (s, a) = φ(s, a) θ q π (s, a) Minimise least squares error between Q θ (s, a) and q π (s, a) from experience generated using policy π consisting of (state, action), value pairs D = { (S 1, A 1 ), ˆV 1 π, (S 2, A 2 ), ˆV 2 π,..., (S T, A T ), ˆV T π }

43 Batch Methods Least Squares Control Least Squares Control For policy evaluation, we want to efficiently use all experience For control, we also want to improve the policy This experience is generated from many policies So to evaluate q π (s, a) we must learn off-policy We use the same idea as Q-learning: Use experience generated by old policy S t, A t, R t+1, S t+1 π old Consider alternative successor action a = π new (S t+1 ) Update Q θ (S t, A t ) towards value of alternative action R t+1 + γq θ (S t+1, a )

44 Batch Methods Least Squares Control Least Squares Q-Learning Consider the following linear Q-learning update δ = R t+1 + γq θ (S t+1, π(s t+1 )) Q θ (S t, A t ) θ = αδφ(s t, A t ) LSTDQ algorithm: solve for total update = zero T 0 = α(r t+1 + γq θ (S t+1, π(s t+1 )) Q θ (S t, A t ))φ(s t, A t ) t=1 ( T ) 1 T θ = φ(s t, A t )(φ(s t, A t ) γφ(s t+1, π(s t+1 ))) φ(s t, A t )R t+1 t=1 t=1

45 Batch Methods Least Squares Control Least Squares Policy Iteration Algorithm The following pseudocode uses LSTDQ for policy evaluation It repeatedly re-evaluates experience D with different policies function LSPI-TD(D, π 0 ) π π 0 repeat π π Q LSTDQ(π, D) for all s S do π (s) argmax Q(s, a) end for until (π π ) return π end function a A

46 Batch Methods Least Squares Control Least-Squares Policy Iteration Chain Walk Example L R R R R L L L r=0 r=1 r=1 r=0 Figure 9: The problematic MDP. Consider the 50 state version of this problem where s is the state number. LSPI was applied on the same problem using thesamebasis functions Reward repeated +1forineach states of the two 10actions and 41, so that 0 each elsewhere action gets its own parameters: 10 Optimal policy: R (1-9), L I(a (10-25), = L) 1 R (26-41), L (42, 50) I(a = L) s φ(s, a) = I(a = L) s 2 I(a = R) 1. Experience: 10,000 steps from random I(a = R) s walk policy I(a = R) s 2 Features: 10 evenly spaced Gaussians (σ = 4) for each action

47 Batch Methods Least Squares Control Least-Squares Policy Iteration LSPI in Chain Walk: Action-Value Function Iteration Iteration Iteration Iteration Iteration Iteration Iteration7 Exact (solid blue) Function Approx. (red dashes)

48 Batch Methods Least Squares Control Questions?

Reinforcement Learning

Reinforcement Learning Reinforcement Learning RL in continuous MDPs March April, 2015 Large/Continuous MDPs Large/Continuous state space Tabular representation cannot be used Large/Continuous action space Maximization over action

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Learning Function approximation Mario Martin CS-UPC May 18, 2018 Mario Martin (CS-UPC) Reinforcement Learning May 18, 2018 / 65 Recap Algorithms: MonteCarlo methods for Policy Evaluation

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Learning Function approximation Daniel Hennes 19.06.2017 University Stuttgart - IPVS - Machine Learning & Robotics 1 Today Eligibility traces n-step TD returns Forward and backward view Function

More information

Lecture 8: Policy Gradient

Lecture 8: Policy Gradient Lecture 8: Policy Gradient Hado van Hasselt Outline 1 Introduction 2 Finite Difference Policy Gradient 3 Monte-Carlo Policy Gradient 4 Actor-Critic Policy Gradient Introduction Vapnik s rule Never solve

More information

Temporal Difference. Learning KENNETH TRAN. Principal Research Engineer, MSR AI

Temporal Difference. Learning KENNETH TRAN. Principal Research Engineer, MSR AI Temporal Difference Learning KENNETH TRAN Principal Research Engineer, MSR AI Temporal Difference Learning Policy Evaluation Intro to model-free learning Monte Carlo Learning Temporal Difference Learning

More information

15-889e Policy Search: Gradient Methods Emma Brunskill. All slides from David Silver (with EB adding minor modificafons), unless otherwise noted

15-889e Policy Search: Gradient Methods Emma Brunskill. All slides from David Silver (with EB adding minor modificafons), unless otherwise noted 15-889e Policy Search: Gradient Methods Emma Brunskill All slides from David Silver (with EB adding minor modificafons), unless otherwise noted Outline 1 Introduction 2 Finite Difference Policy Gradient

More information

CSE 190: Reinforcement Learning: An Introduction. Chapter 8: Generalization and Function Approximation. Pop Quiz: What Function Are We Approximating?

CSE 190: Reinforcement Learning: An Introduction. Chapter 8: Generalization and Function Approximation. Pop Quiz: What Function Are We Approximating? CSE 190: Reinforcement Learning: An Introduction Chapter 8: Generalization and Function Approximation Objectives of this chapter: Look at how experience with a limited part of the state set be used to

More information

CS599 Lecture 2 Function Approximation in RL

CS599 Lecture 2 Function Approximation in RL CS599 Lecture 2 Function Approximation in RL Look at how experience with a limited part of the state set be used to produce good behavior over a much larger part. Overview of function approximation (FA)

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Learning Value Function Approximation Continuous state/action space, mean-square error, gradient temporal difference learning, least-square temporal difference, least squares policy iteration

More information

Temporal difference learning

Temporal difference learning Temporal difference learning AI & Agents for IET Lecturer: S Luz http://www.scss.tcd.ie/~luzs/t/cs7032/ February 4, 2014 Recall background & assumptions Environment is a finite MDP (i.e. A and S are finite).

More information

Reinforcement Learning. Spring 2018 Defining MDPs, Planning

Reinforcement Learning. Spring 2018 Defining MDPs, Planning Reinforcement Learning Spring 2018 Defining MDPs, Planning understandability 0 Slide 10 time You are here Markov Process Where you will go depends only on where you are Markov Process: Information state

More information

CSE 190: Reinforcement Learning: An Introduction. Chapter 8: Generalization and Function Approximation. Pop Quiz: What Function Are We Approximating?

CSE 190: Reinforcement Learning: An Introduction. Chapter 8: Generalization and Function Approximation. Pop Quiz: What Function Are We Approximating? CSE 190: Reinforcement Learning: An Introduction Chapter 8: Generalization and Function Approximation Objectives of this chapter: Look at how experience with a limited part of the state set be used to

More information

Introduction to Reinforcement Learning. CMPT 882 Mar. 18

Introduction to Reinforcement Learning. CMPT 882 Mar. 18 Introduction to Reinforcement Learning CMPT 882 Mar. 18 Outline for the week Basic ideas in RL Value functions and value iteration Policy evaluation and policy improvement Model-free RL Monte-Carlo and

More information

Chapter 8: Generalization and Function Approximation

Chapter 8: Generalization and Function Approximation Chapter 8: Generalization and Function Approximation Objectives of this chapter: Look at how experience with a limited part of the state set be used to produce good behavior over a much larger part. Overview

More information

Reinforcement Learning. George Konidaris

Reinforcement Learning. George Konidaris Reinforcement Learning George Konidaris gdk@cs.brown.edu Fall 2017 Machine Learning Subfield of AI concerned with learning from data. Broadly, using: Experience To Improve Performance On Some Task (Tom

More information

Reinforcement Learning with Function Approximation. Joseph Christian G. Noel

Reinforcement Learning with Function Approximation. Joseph Christian G. Noel Reinforcement Learning with Function Approximation Joseph Christian G. Noel November 2011 Abstract Reinforcement learning (RL) is a key problem in the field of Artificial Intelligence. The main goal is

More information

CS 287: Advanced Robotics Fall Lecture 14: Reinforcement Learning with Function Approximation and TD Gammon case study

CS 287: Advanced Robotics Fall Lecture 14: Reinforcement Learning with Function Approximation and TD Gammon case study CS 287: Advanced Robotics Fall 2009 Lecture 14: Reinforcement Learning with Function Approximation and TD Gammon case study Pieter Abbeel UC Berkeley EECS Assignment #1 Roll-out: nice example paper: X.

More information

Grundlagen der Künstlichen Intelligenz

Grundlagen der Künstlichen Intelligenz Grundlagen der Künstlichen Intelligenz Reinforcement learning II Daniel Hennes 11.12.2017 (WS 2017/18) University Stuttgart - IPVS - Machine Learning & Robotics 1 Today Eligibility traces n-step TD returns

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Learning Function Approximation Continuous state/action space, mean-square error, gradient temporal difference learning, least-square temporal difference, least squares policy iteration Vien

More information

Generalization and Function Approximation

Generalization and Function Approximation Generalization and Function Approximation 0 Generalization and Function Approximation Suggested reading: Chapter 8 in R. S. Sutton, A. G. Barto: Reinforcement Learning: An Introduction MIT Press, 1998.

More information

PART A and ONE question from PART B; or ONE question from PART A and TWO questions from PART B.

PART A and ONE question from PART B; or ONE question from PART A and TWO questions from PART B. Advanced Topics in Machine Learning, GI13, 2010/11 Advanced Topics in Machine Learning, GI13, 2010/11 Answer any THREE questions. Each question is worth 20 marks. Use separate answer books Answer any THREE

More information

Reinforcement Learning. Donglin Zeng, Department of Biostatistics, University of North Carolina

Reinforcement Learning. Donglin Zeng, Department of Biostatistics, University of North Carolina Reinforcement Learning Introduction Introduction Unsupervised learning has no outcome (no feedback). Supervised learning has outcome so we know what to predict. Reinforcement learning is in between it

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Learning Temporal Difference Learning Temporal difference learning, TD prediction, Q-learning, elibigility traces. (many slides from Marc Toussaint) Vien Ngo MLR, University of Stuttgart

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Learning Temporal Difference Learning Temporal difference learning, TD prediction, Q-learning, elibigility traces. (many slides from Marc Toussaint) Vien Ngo Marc Toussaint University of

More information

Approximation Methods in Reinforcement Learning

Approximation Methods in Reinforcement Learning 2018 CS420, Machine Learning, Lecture 12 Approximation Methods in Reinforcement Learning Weinan Zhang Shanghai Jiao Tong University http://wnzhang.net http://wnzhang.net/teaching/cs420/index.html Reinforcement

More information

Machine Learning I Reinforcement Learning

Machine Learning I Reinforcement Learning Machine Learning I Reinforcement Learning Thomas Rückstieß Technische Universität München December 17/18, 2009 Literature Book: Reinforcement Learning: An Introduction Sutton & Barto (free online version:

More information

Reinforcement Learning. Summer 2017 Defining MDPs, Planning

Reinforcement Learning. Summer 2017 Defining MDPs, Planning Reinforcement Learning Summer 2017 Defining MDPs, Planning understandability 0 Slide 10 time You are here Markov Process Where you will go depends only on where you are Markov Process: Information state

More information

Lecture 23: Reinforcement Learning

Lecture 23: Reinforcement Learning Lecture 23: Reinforcement Learning MDPs revisited Model-based learning Monte Carlo value function estimation Temporal-difference (TD) learning Exploration November 23, 2006 1 COMP-424 Lecture 23 Recall:

More information

Notes on Reinforcement Learning

Notes on Reinforcement Learning 1 Introduction Notes on Reinforcement Learning Paulo Eduardo Rauber 2014 Reinforcement learning is the study of agents that act in an environment with the goal of maximizing cumulative reward signals.

More information

CS599 Lecture 1 Introduction To RL

CS599 Lecture 1 Introduction To RL CS599 Lecture 1 Introduction To RL Reinforcement Learning Introduction Learning from rewards Policies Value Functions Rewards Models of the Environment Exploitation vs. Exploration Dynamic Programming

More information

Least squares temporal difference learning

Least squares temporal difference learning Least squares temporal difference learning TD(λ) Good properties of TD Easy to implement, traces achieve the forward view Linear complexity = fast Combines easily with linear function approximation Outperforms

More information

Fast Gradient-Descent Methods for Temporal-Difference Learning with Linear Function Approximation

Fast Gradient-Descent Methods for Temporal-Difference Learning with Linear Function Approximation Fast Gradient-Descent Methods for Temporal-Difference Learning with Linear Function Approximation Rich Sutton, University of Alberta Hamid Maei, University of Alberta Doina Precup, McGill University Shalabh

More information

Actor-critic methods. Dialogue Systems Group, Cambridge University Engineering Department. February 21, 2017

Actor-critic methods. Dialogue Systems Group, Cambridge University Engineering Department. February 21, 2017 Actor-critic methods Milica Gašić Dialogue Systems Group, Cambridge University Engineering Department February 21, 2017 1 / 21 In this lecture... The actor-critic architecture Least-Squares Policy Iteration

More information

Reinforcement Learning: An Introduction. ****Draft****

Reinforcement Learning: An Introduction. ****Draft**** i Reinforcement Learning: An Introduction Second edition, in progress ****Draft**** Richard S. Sutton and Andrew G. Barto c 2014, 2015 A Bradford Book The MIT Press Cambridge, Massachusetts London, England

More information

Reinforcement Learning: An Introduction

Reinforcement Learning: An Introduction Introduction Betreuer: Freek Stulp Hauptseminar Intelligente Autonome Systeme (WiSe 04/05) Forschungs- und Lehreinheit Informatik IX Technische Universität München November 24, 2004 Introduction What is

More information

Approximate Dynamic Programming

Approximate Dynamic Programming Master MVA: Reinforcement Learning Lecture: 5 Approximate Dynamic Programming Lecturer: Alessandro Lazaric http://researchers.lille.inria.fr/ lazaric/webpage/teaching.html Objectives of the lecture 1.

More information

An online kernel-based clustering approach for value function approximation

An online kernel-based clustering approach for value function approximation An online kernel-based clustering approach for value function approximation N. Tziortziotis and K. Blekas Department of Computer Science, University of Ioannina P.O.Box 1186, Ioannina 45110 - Greece {ntziorzi,kblekas}@cs.uoi.gr

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Learning Policy gradients Daniel Hennes 26.06.2017 University Stuttgart - IPVS - Machine Learning & Robotics 1 Policy based reinforcement learning So far we approximated the action value

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Learning Policy Search: Actor-Critic and Gradient Policy search Mario Martin CS-UPC May 28, 2018 Mario Martin (CS-UPC) Reinforcement Learning May 28, 2018 / 63 Goal of this lecture So far

More information

Reinforcement Learning. Introduction

Reinforcement Learning. Introduction Reinforcement Learning Introduction Reinforcement Learning Agent interacts and learns from a stochastic environment Science of sequential decision making Many faces of reinforcement learning Optimal control

More information

PART A and ONE question from PART B; or ONE question from PART A and TWO questions from PART B.

PART A and ONE question from PART B; or ONE question from PART A and TWO questions from PART B. Advanced Topics in Machine Learning, GI13, 2010/11 Advanced Topics in Machine Learning, GI13, 2010/11 Answer any THREE questions. Each question is worth 20 marks. Use separate answer books Answer any THREE

More information

INF 5860 Machine learning for image classification. Lecture 14: Reinforcement learning May 9, 2018

INF 5860 Machine learning for image classification. Lecture 14: Reinforcement learning May 9, 2018 Machine learning for image classification Lecture 14: Reinforcement learning May 9, 2018 Page 3 Outline Motivation Introduction to reinforcement learning (RL) Value function based methods (Q-learning)

More information

Introduction to Reinforcement Learning

Introduction to Reinforcement Learning CSCI-699: Advanced Topics in Deep Learning 01/16/2019 Nitin Kamra Spring 2019 Introduction to Reinforcement Learning 1 What is Reinforcement Learning? So far we have seen unsupervised and supervised learning.

More information

Grundlagen der Künstlichen Intelligenz

Grundlagen der Künstlichen Intelligenz Grundlagen der Künstlichen Intelligenz Reinforcement learning Daniel Hennes 4.12.2017 (WS 2017/18) University Stuttgart - IPVS - Machine Learning & Robotics 1 Today Reinforcement learning Model based and

More information

(Deep) Reinforcement Learning

(Deep) Reinforcement Learning Martin Matyášek Artificial Intelligence Center Czech Technical University in Prague October 27, 2016 Martin Matyášek VPD, 2016 1 / 17 Reinforcement Learning in a picture R. S. Sutton and A. G. Barto 2015

More information

State Space Abstractions for Reinforcement Learning

State Space Abstractions for Reinforcement Learning State Space Abstractions for Reinforcement Learning Rowan McAllister and Thang Bui MLG RCC 6 November 24 / 24 Outline Introduction Markov Decision Process Reinforcement Learning State Abstraction 2 Abstraction

More information

Replacing eligibility trace for action-value learning with function approximation

Replacing eligibility trace for action-value learning with function approximation Replacing eligibility trace for action-value learning with function approximation Kary FRÄMLING Helsinki University of Technology PL 5500, FI-02015 TKK - Finland Abstract. The eligibility trace is one

More information

Approximate Dynamic Programming

Approximate Dynamic Programming Approximate Dynamic Programming A. LAZARIC (SequeL Team @INRIA-Lille) Ecole Centrale - Option DAD SequeL INRIA Lille EC-RL Course Value Iteration: the Idea 1. Let V 0 be any vector in R N A. LAZARIC Reinforcement

More information

Lecture 3: Markov Decision Processes

Lecture 3: Markov Decision Processes Lecture 3: Markov Decision Processes Joseph Modayil 1 Markov Processes 2 Markov Reward Processes 3 Markov Decision Processes 4 Extensions to MDPs Markov Processes Introduction Introduction to MDPs Markov

More information

Reinforcement Learning

Reinforcement Learning 1 Reinforcement Learning Chris Watkins Department of Computer Science Royal Holloway, University of London July 27, 2015 2 Plan 1 Why reinforcement learning? Where does this theory come from? Markov decision

More information

Reinforcement Learning and Deep Reinforcement Learning

Reinforcement Learning and Deep Reinforcement Learning Reinforcement Learning and Deep Reinforcement Learning Ashis Kumer Biswas, Ph.D. ashis.biswas@ucdenver.edu Deep Learning November 5, 2018 1 / 64 Outlines 1 Principles of Reinforcement Learning 2 The Q

More information

ilstd: Eligibility Traces and Convergence Analysis

ilstd: Eligibility Traces and Convergence Analysis ilstd: Eligibility Traces and Convergence Analysis Alborz Geramifard Michael Bowling Martin Zinkevich Richard S. Sutton Department of Computing Science University of Alberta Edmonton, Alberta {alborz,bowling,maz,sutton}@cs.ualberta.ca

More information

arxiv: v1 [cs.ai] 5 Nov 2017

arxiv: v1 [cs.ai] 5 Nov 2017 arxiv:1711.01569v1 [cs.ai] 5 Nov 2017 Markus Dumke Department of Statistics Ludwig-Maximilians-Universität München markus.dumke@campus.lmu.de Abstract Temporal-difference (TD) learning is an important

More information

Machine Learning. Reinforcement learning. Hamid Beigy. Sharif University of Technology. Fall 1396

Machine Learning. Reinforcement learning. Hamid Beigy. Sharif University of Technology. Fall 1396 Machine Learning Reinforcement learning Hamid Beigy Sharif University of Technology Fall 1396 Hamid Beigy (Sharif University of Technology) Machine Learning Fall 1396 1 / 32 Table of contents 1 Introduction

More information

Machine Learning I Continuous Reinforcement Learning

Machine Learning I Continuous Reinforcement Learning Machine Learning I Continuous Reinforcement Learning Thomas Rückstieß Technische Universität München January 7/8, 2010 RL Problem Statement (reminder) state s t+1 ENVIRONMENT reward r t+1 new step r t

More information

Decision Theory: Q-Learning

Decision Theory: Q-Learning Decision Theory: Q-Learning CPSC 322 Decision Theory 5 Textbook 12.5 Decision Theory: Q-Learning CPSC 322 Decision Theory 5, Slide 1 Lecture Overview 1 Recap 2 Asynchronous Value Iteration 3 Q-Learning

More information

Open Theoretical Questions in Reinforcement Learning

Open Theoretical Questions in Reinforcement Learning Open Theoretical Questions in Reinforcement Learning Richard S. Sutton AT&T Labs, Florham Park, NJ 07932, USA, sutton@research.att.com, www.cs.umass.edu/~rich Reinforcement learning (RL) concerns the problem

More information

Reinforcement Learning: the basics

Reinforcement Learning: the basics Reinforcement Learning: the basics Olivier Sigaud Université Pierre et Marie Curie, PARIS 6 http://people.isir.upmc.fr/sigaud August 6, 2012 1 / 46 Introduction Action selection/planning Learning by trial-and-error

More information

https://www.youtube.com/watch?v=ymvi1l746us Eligibility traces Chapter 12, plus some extra stuff! Like n-step methods, but better! Eligibility traces A mechanism that allow TD, Sarsa and Q-learning to

More information

Learning Control for Air Hockey Striking using Deep Reinforcement Learning

Learning Control for Air Hockey Striking using Deep Reinforcement Learning Learning Control for Air Hockey Striking using Deep Reinforcement Learning Ayal Taitler, Nahum Shimkin Faculty of Electrical Engineering Technion - Israel Institute of Technology May 8, 2017 A. Taitler,

More information

Dueling Network Architectures for Deep Reinforcement Learning (ICML 2016)

Dueling Network Architectures for Deep Reinforcement Learning (ICML 2016) Dueling Network Architectures for Deep Reinforcement Learning (ICML 2016) Yoonho Lee Department of Computer Science and Engineering Pohang University of Science and Technology October 11, 2016 Outline

More information

Reinforcement. Function Approximation. Learning with KATJA HOFMANN. Researcher, MSR Cambridge

Reinforcement. Function Approximation. Learning with KATJA HOFMANN. Researcher, MSR Cambridge Reinforcement Learning with Function Approximation KATJA HOFMANN Researcher, MSR Cambridge Representation and Generalization in RL Focus on training stability Learning generalizable value functions Navigating

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Learning Ron Parr CompSci 7 Department of Computer Science Duke University With thanks to Kris Hauser for some content RL Highlights Everybody likes to learn from experience Use ML techniques

More information

Reinforcement Learning as Variational Inference: Two Recent Approaches

Reinforcement Learning as Variational Inference: Two Recent Approaches Reinforcement Learning as Variational Inference: Two Recent Approaches Rohith Kuditipudi Duke University 11 August 2017 Outline 1 Background 2 Stein Variational Policy Gradient 3 Soft Q-Learning 4 Closing

More information

Introduction to Reinforcement Learning. Part 5: Temporal-Difference Learning

Introduction to Reinforcement Learning. Part 5: Temporal-Difference Learning Introduction to Reinforcement Learning Part 5: emporal-difference Learning What everybody should know about emporal-difference (D) learning Used to learn value functions without human input Learns a guess

More information

A Convergent O(n) Algorithm for Off-policy Temporal-difference Learning with Linear Function Approximation

A Convergent O(n) Algorithm for Off-policy Temporal-difference Learning with Linear Function Approximation A Convergent O(n) Algorithm for Off-policy Temporal-difference Learning with Linear Function Approximation Richard S. Sutton, Csaba Szepesvári, Hamid Reza Maei Reinforcement Learning and Artificial Intelligence

More information

Introduction. Reinforcement Learning

Introduction. Reinforcement Learning Introduction Reinforcement Learning Learn Act Sense Scott Sanner NICTA / ANU First.Last@nicta.com.au Lecture Goals 1) To understand formal models for decisionmaking under uncertainty and their properties

More information

Variance Reduction for Policy Gradient Methods. March 13, 2017

Variance Reduction for Policy Gradient Methods. March 13, 2017 Variance Reduction for Policy Gradient Methods March 13, 2017 Reward Shaping Reward Shaping Reward Shaping Reward shaping: r(s, a, s ) = r(s, a, s ) + γφ(s ) Φ(s) for arbitrary potential Φ Theorem: r admits

More information

Lecture 18: Reinforcement Learning Sanjeev Arora Elad Hazan

Lecture 18: Reinforcement Learning Sanjeev Arora Elad Hazan COS 402 Machine Learning and Artificial Intelligence Fall 2016 Lecture 18: Reinforcement Learning Sanjeev Arora Elad Hazan Some slides borrowed from Peter Bodik and David Silver Course progress Learning

More information

Chapter 7: Eligibility Traces. R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1

Chapter 7: Eligibility Traces. R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1 Chapter 7: Eligibility Traces R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1 Midterm Mean = 77.33 Median = 82 R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction

More information

Basics of reinforcement learning

Basics of reinforcement learning Basics of reinforcement learning Lucian Buşoniu TMLSS, 20 July 2018 Main idea of reinforcement learning (RL) Learn a sequential decision policy to optimize the cumulative performance of an unknown system

More information

Reinforcement Learning using Continuous Actions. Hado van Hasselt

Reinforcement Learning using Continuous Actions. Hado van Hasselt Reinforcement Learning using Continuous Actions Hado van Hasselt 2005 Concluding thesis for Cognitive Artificial Intelligence University of Utrecht First supervisor: Dr. Marco A. Wiering, University of

More information

Q-Learning in Continuous State Action Spaces

Q-Learning in Continuous State Action Spaces Q-Learning in Continuous State Action Spaces Alex Irpan alexirpan@berkeley.edu December 5, 2015 Contents 1 Introduction 1 2 Background 1 3 Q-Learning 2 4 Q-Learning In Continuous Spaces 4 5 Experimental

More information

Reinforcement Learning via Policy Optimization

Reinforcement Learning via Policy Optimization Reinforcement Learning via Policy Optimization Hanxiao Liu November 22, 2017 1 / 27 Reinforcement Learning Policy a π(s) 2 / 27 Example - Mario 3 / 27 Example - ChatBot 4 / 27 Applications - Video Games

More information

1944 IEEE TRANSACTIONS ON NEURAL NETWORKS AND LEARNING SYSTEMS, VOL. 24, NO. 12, DECEMBER 2013

1944 IEEE TRANSACTIONS ON NEURAL NETWORKS AND LEARNING SYSTEMS, VOL. 24, NO. 12, DECEMBER 2013 1944 IEEE TRANSACTIONS ON NEURAL NETWORKS AND LEARNING SYSTEMS, VOL. 24, NO. 12, DECEMBER 2013 Online Selective Kernel-Based Temporal Difference Learning Xingguo Chen, Yang Gao, Member, IEEE, andruiliwang

More information

Reinforcement Learning in Continuous Action Spaces

Reinforcement Learning in Continuous Action Spaces Reinforcement Learning in Continuous Action Spaces Hado van Hasselt and Marco A. Wiering Intelligent Systems Group, Department of Information and Computing Sciences, Utrecht University Padualaan 14, 3508

More information

ROB 537: Learning-Based Control. Announcements: Project background due Today. HW 3 Due on 10/30 Midterm Exam on 11/6.

ROB 537: Learning-Based Control. Announcements: Project background due Today. HW 3 Due on 10/30 Midterm Exam on 11/6. ROB 537: Learning-Based Control Week 5, Lecture 1 Policy Gradient, Eligibility Traces, Transfer Learning (MaC Taylor Announcements: Project background due Today HW 3 Due on 10/30 Midterm Exam on 11/6 Reading:

More information

Off-Policy Actor-Critic

Off-Policy Actor-Critic Off-Policy Actor-Critic Ludovic Trottier Laval University July 25 2012 Ludovic Trottier (DAMAS Laboratory) Off-Policy Actor-Critic July 25 2012 1 / 34 Table of Contents 1 Reinforcement Learning Theory

More information

This question has three parts, each of which can be answered concisely, but be prepared to explain and justify your concise answer.

This question has three parts, each of which can be answered concisely, but be prepared to explain and justify your concise answer. This question has three parts, each of which can be answered concisely, but be prepared to explain and justify your concise answer. 1. Suppose you have a policy and its action-value function, q, then you

More information

Marks. bonus points. } Assignment 1: Should be out this weekend. } Mid-term: Before the last lecture. } Mid-term deferred exam:

Marks. bonus points. } Assignment 1: Should be out this weekend. } Mid-term: Before the last lecture. } Mid-term deferred exam: Marks } Assignment 1: Should be out this weekend } All are marked, I m trying to tally them and perhaps add bonus points } Mid-term: Before the last lecture } Mid-term deferred exam: } This Saturday, 9am-10.30am,

More information

An Introduction to Reinforcement Learning

An Introduction to Reinforcement Learning 1 / 58 An Introduction to Reinforcement Learning Lecture 01: Introduction Dr. Johannes A. Stork School of Computer Science and Communication KTH Royal Institute of Technology January 19, 2017 2 / 58 ../fig/reward-00.jpg

More information

Reinforcement Learning Part 2

Reinforcement Learning Part 2 Reinforcement Learning Part 2 Dipendra Misra Cornell University dkm@cs.cornell.edu https://dipendramisra.wordpress.com/ From previous tutorial Reinforcement Learning Exploration No supervision Agent-Reward-Environment

More information

Olivier Sigaud. September 21, 2012

Olivier Sigaud. September 21, 2012 Supervised and Reinforcement Learning Tools for Motor Learning Models Olivier Sigaud Université Pierre et Marie Curie - Paris 6 September 21, 2012 1 / 64 Introduction Who is speaking? 2 / 64 Introduction

More information

Reinforcement Learning II. George Konidaris

Reinforcement Learning II. George Konidaris Reinforcement Learning II George Konidaris gdk@cs.brown.edu Fall 2017 Reinforcement Learning π : S A max R = t=0 t r t MDPs Agent interacts with an environment At each time t: Receives sensor signal Executes

More information

CS230: Lecture 9 Deep Reinforcement Learning

CS230: Lecture 9 Deep Reinforcement Learning CS230: Lecture 9 Deep Reinforcement Learning Kian Katanforoosh Menti code: 21 90 15 Today s outline I. Motivation II. Recycling is good: an introduction to RL III. Deep Q-Learning IV. Application of Deep

More information

Lecture 4: Approximate dynamic programming

Lecture 4: Approximate dynamic programming IEOR 800: Reinforcement learning By Shipra Agrawal Lecture 4: Approximate dynamic programming Deep Q Networks discussed in the last lecture are an instance of approximate dynamic programming. These are

More information

Reinforcement Learning II. George Konidaris

Reinforcement Learning II. George Konidaris Reinforcement Learning II George Konidaris gdk@cs.brown.edu Fall 2018 Reinforcement Learning π : S A max R = t=0 t r t MDPs Agent interacts with an environment At each time t: Receives sensor signal Executes

More information

Reinforcement Learning II

Reinforcement Learning II Reinforcement Learning II Andrea Bonarini Artificial Intelligence and Robotics Lab Department of Electronics and Information Politecnico di Milano E-mail: bonarini@elet.polimi.it URL:http://www.dei.polimi.it/people/bonarini

More information

Least-Squares Temporal Difference Learning based on Extreme Learning Machine

Least-Squares Temporal Difference Learning based on Extreme Learning Machine Least-Squares Temporal Difference Learning based on Extreme Learning Machine Pablo Escandell-Montero, José M. Martínez-Martínez, José D. Martín-Guerrero, Emilio Soria-Olivas, Juan Gómez-Sanchis IDAL, Intelligent

More information

6 Reinforcement Learning

6 Reinforcement Learning 6 Reinforcement Learning As discussed above, a basic form of supervised learning is function approximation, relating input vectors to output vectors, or, more generally, finding density functions p(y,

More information

Approximate Dynamic Programming

Approximate Dynamic Programming Approximate Dynamic Programming A. LAZARIC (SequeL Team @INRIA-Lille) ENS Cachan - Master 2 MVA SequeL INRIA Lille MVA-RL Course Approximate Dynamic Programming (a.k.a. Batch Reinforcement Learning) A.

More information

Prof. Dr. Ann Nowé. Artificial Intelligence Lab ai.vub.ac.be

Prof. Dr. Ann Nowé. Artificial Intelligence Lab ai.vub.ac.be REINFORCEMENT LEARNING AN INTRODUCTION Prof. Dr. Ann Nowé Artificial Intelligence Lab ai.vub.ac.be REINFORCEMENT LEARNING WHAT IS IT? What is it? Learning from interaction Learning about, from, and while

More information

Dyna-Style Planning with Linear Function Approximation and Prioritized Sweeping

Dyna-Style Planning with Linear Function Approximation and Prioritized Sweeping Dyna-Style Planning with Linear Function Approximation and Prioritized Sweeping Richard S Sutton, Csaba Szepesvári, Alborz Geramifard, Michael Bowling Reinforcement Learning and Artificial Intelligence

More information

Lecture 10 - Planning under Uncertainty (III)

Lecture 10 - Planning under Uncertainty (III) Lecture 10 - Planning under Uncertainty (III) Jesse Hoey School of Computer Science University of Waterloo March 27, 2018 Readings: Poole & Mackworth (2nd ed.)chapter 12.1,12.3-12.9 1/ 34 Reinforcement

More information

Elements of Reinforcement Learning

Elements of Reinforcement Learning Elements of Reinforcement Learning Policy: way learning algorithm behaves (mapping from state to action) Reward function: Mapping of state action pair to reward or cost Value function: long term reward,

More information

Reinforcement Learning and Control

Reinforcement Learning and Control CS9 Lecture notes Andrew Ng Part XIII Reinforcement Learning and Control We now begin our study of reinforcement learning and adaptive control. In supervised learning, we saw algorithms that tried to make

More information

Reinforcement learning an introduction

Reinforcement learning an introduction Reinforcement learning an introduction Prof. Dr. Ann Nowé Computational Modeling Group AIlab ai.vub.ac.be November 2013 Reinforcement Learning What is it? Learning from interaction Learning about, from,

More information

Lecture 3: Policy Evaluation Without Knowing How the World Works / Model Free Policy Evaluation

Lecture 3: Policy Evaluation Without Knowing How the World Works / Model Free Policy Evaluation Lecture 3: Policy Evaluation Without Knowing How the World Works / Model Free Policy Evaluation CS234: RL Emma Brunskill Winter 2018 Material builds on structure from David SIlver s Lecture 4: Model-Free

More information

Deep Reinforcement Learning

Deep Reinforcement Learning Martin Matyášek Artificial Intelligence Center Czech Technical University in Prague October 27, 2016 Martin Matyášek VPD, 2016 1 / 50 Reinforcement Learning in a picture R. S. Sutton and A. G. Barto 2015

More information

Monte Carlo is important in practice. CSE 190: Reinforcement Learning: An Introduction. Chapter 6: Temporal Difference Learning.

Monte Carlo is important in practice. CSE 190: Reinforcement Learning: An Introduction. Chapter 6: Temporal Difference Learning. Monte Carlo is important in practice CSE 190: Reinforcement Learning: An Introduction Chapter 6: emporal Difference Learning When there are just a few possibilitieo value, out of a large state space, Monte

More information