R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1 Chapter 3: The Reinforcement Learning Problem pdescribe the RL problem we will.

Slides:



Advertisements
Similar presentations
Reinforcement Learning: Learning from Interaction
Advertisements

Markov Decision Process
brings-uas-sensor-technology-to- smartphones/ brings-uas-sensor-technology-to-
1 Dynamic Programming Week #4. 2 Introduction Dynamic Programming (DP) –refers to a collection of algorithms –has a high computational complexity –assumes.
Computational Modeling Lab Wednesday 18 June 2003 Reinforcement Learning an introduction part 3 Ann Nowé By Sutton.
Decision Theoretic Planning
1 Reinforcement Learning Problem Week #3. Figure reproduced from the figure on page 52 in reference [1] 2 Reinforcement Learning Loop state Agent Environment.
COSC 878 Seminar on Large Scale Statistical Machine Learning 1.
R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1 Chapter 4: Dynamic Programming pOverview of a collection of classical solution.
Lehrstuhl für Informatik 2 Gabriella Kókai: Maschine Learning Reinforcement Learning.
R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1 Chapter 4: Dynamic Programming pOverview of a collection of classical solution.
Chapter 5: Monte Carlo Methods
1 Hybrid Agent-Based Modeling: Architectures,Analyses and Applications (Stage One) Li, Hailin.
Chapter 6: Temporal Difference Learning
R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1 From Sutton & Barto Reinforcement Learning An Introduction.
Chapter 6: Temporal Difference Learning
Markov Decision Processes Value Iteration Pieter Abbeel UC Berkeley EECS TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.:
R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1 Chapter 3: The Reinforcement Learning Problem pdescribe the RL problem we will.
R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1 Chapter 4: Dynamic Programming pOverview of a collection of classical solution.
Reinforcement Learning
Reinforcement Learning (1)
Wednesday 18 June 2003 Computational Modeling Lab Situated Agents Course Karl Tuyls (1.004) Sub-Course on: Reinforcement Learning Multi-Agent Learning.
CS Reinforcement Learning1 Reinforcement Learning Variation on Supervised Learning Exact target outputs are not given Some variation of reward is.
MAKING COMPLEX DEClSlONS
Reinforcement Learning
REINFORCEMENT LEARNING LEARNING TO PERFORM BEST ACTIONS BY REWARDS Tayfun Gürel.
1 ECE-517: Reinforcement Learning in Artificial Intelligence Lecture 6: Optimality Criterion in MDPs Dr. Itamar Arel College of Engineering Department.
Decision Making in Robots and Autonomous Agents Decision Making in Robots and Autonomous Agents The Markov Decision Process (MDP) model Subramanian Ramamoorthy.
1 ECE-517 Reinforcement Learning in Artificial Intelligence Lecture 7: Finite Horizon MDPs, Dynamic Programming Dr. Itamar Arel College of Engineering.
Computational Modeling Lab Wednesday 18 June 2003 Reinforcement Learning an introduction Ann Nowé By Sutton and.
Introduction to Reinforcement Learning
Reinforcement Learning 主講人:虞台文 Content Introduction Main Elements Markov Decision Process (MDP) Value Functions.
Attributions These slides were originally developed by R.S. Sutton and A.G. Barto, Reinforcement Learning: An Introduction. (They have been reformatted.
Reinforcement Learning 主講人:虞台文 大同大學資工所 智慧型多媒體研究室.
Reinforcement Learning with Laser Cats! Marshall Wang Maria Jahja DTR Group Meeting October 5, 2015.
Announcements  Upcoming due dates  Wednesday 11/4, 11:59pm Homework 8  Friday 10/30, 5pm Project 3  Watch out for Daylight Savings and UTC.
CMSC 471 Fall 2009 MDPs and the RL Problem Prof. Marie desJardins Class #23 – Tuesday, 11/17 Thanks to Rich Sutton and Andy Barto for the use of their.
Reinforcement Learning Dynamic Programming I Subramanian Ramamoorthy School of Informatics 31 January, 2012.
MDPs and Reinforcement Learning. Overview MDPs Reinforcement learning.
Reinforcement Learning  Basic idea:  Receive feedback in the form of rewards  Agent’s utility is defined by the reward function  Must learn to act.
Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 3
Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 3
Markov Decision Processes
Timothy Boger and Mike Korostelev
ECE 517: Reinforcement Learning in Artificial Intelligence
Markov Decision Processes
Markov Decision Processes
CMSC 671 – Fall 2010 Class #22 – Wednesday 11/17
Reinforcement learning
Chapter 3: The Reinforcement Learning Problem
CMSC 471 Fall 2009 RL using Dynamic Programming
Chapter 4: Dynamic Programming
Chapter 4: Dynamic Programming
Dr. Unnikrishnan P.C. Professor, EEE
CS 188: Artificial Intelligence Fall 2007
Chapter 3: The Reinforcement Learning Problem
Chapter 3: The Reinforcement Learning Problem
CS 188: Artificial Intelligence Spring 2006
CMSC 471 – Fall 2011 Class #25 – Tuesday, November 29
Chapter 7: Eligibility Traces
Chapter 4: Dynamic Programming
Reinforcement Learning Dealing with Partial Observability
CS 416 Artificial Intelligence
Markov Decision Processes
Markov Decision Processes
Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 3
Presentation transcript:

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 1 Chapter 3: The Reinforcement Learning Problem pdescribe the RL problem we will be studying for the remainder of the course ppresent idealized form of the RL problem for which we have precise theoretical results; pintroduce key components of the mathematics: value functions and Bellman equations; pdescribe trade-offs between applicability and mathematical tractability. Objectives of this chapter:

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 2 The Agent-Environment Interface t... s t a r t +1 s a r t +2 s a r t +3 s... t +3 a

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 3 The Agent Learns a Policy pReinforcement learning methods specify how the agent changes its policy as a result of experience. pRoughly, the agent’s goal is to get as much reward as it can over the long run.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 4 Getting the Degree of Abstraction Right pTime steps need not refer to fixed intervals of real time. pActions can be low level (e.g., voltages to motors), or high level (e.g., accept a job offer), “mental” (e.g., shift in focus of attention), etc. pStates can low-level “sensations”, or they can be abstract, symbolic, based on memory, or subjective (e.g., the state of being “surprised” or “lost”). pAn RL agent is not like a whole animal or robot, which consist of many RL agents as well as other components. pThe environment is not necessarily unknown to the agent, only incompletely controllable. pReward computation is in the agent’s environment because the agent cannot change it arbitrarily.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 5 Goals and Rewards pIs a scalar reward signal an adequate notion of a goal?— maybe not, but it is surprisingly flexible. pA goal should specify what we want to achieve, not how we want to achieve it. pA goal must be outside the agent’s direct control—thus outside the agent. pThe agent must be able to measure success: explicitly; frequently during its lifespan.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 6 Returns Episodic tasks: interaction breaks naturally into episodes, e.g., plays of a game, trips through a maze. where T is a final time step at which a terminal state is reached, ending an episode.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 7 Returns for Continuing Tasks Continuing tasks: interaction does not have natural episodes. Discounted return:

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 8 An Example Avoid failure: the pole falling beyond a critical angle or the cart hitting end of track. As an episodic task where episode ends upon failure: As a continuing task with discounted return: In either case, return is maximized by avoiding failure for as long as possible.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 9 Another Example Get to the top of the hill as quickly as possible. Return is maximized by minimizing number of steps reach the top of the hill.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 10 A Unified Notation pIn episodic tasks, we number the time steps of each episode starting from zero. pWe usually do not have distinguish between episodes, so we write instead of for the state at step t of episode j. pThink of each episode as ending in an absorbing state that always produces reward of zero: pWe can cover all cases by writing

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 11 The Markov Property pBy “the state” at step t, the book means whatever information is available to the agent at step t about its environment. pThe state can include immediate “sensations,” highly processed sensations, and structures built up over time from sequences of sensations. pIdeally, a state should summarize past sensations so as to retain all “essential” information, i.e., it should have the Markov Property:

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 12 Markov Decision Processes pIf a reinforcement learning task has the Markov Property, it is basically a Markov Decision Process (MDP). pIf state and action sets are finite, it is a finite MDP. pTo define a finite MDP, you need to give: state and action sets one-step “dynamics” defined by transition probabilities: reward probabilities:

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 13 Recycling Robot An Example Finite MDP pAt each step, robot has to decide whether it should (1) actively search for a can, (2) wait for someone to bring it a can, or (3) go to home base and recharge. pSearching is better but runs down the battery; if runs out of power while searching, has to be rescued (which is bad).  Decisions made on basis of current energy level: high, low. pReward = number of cans collected

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 14 Recycling Robot MDP

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 15 Value Functions pThe value of a state is the expected return starting from that state; depends on the agent’s policy:  The value of taking an action in a state under policy  is the expected return starting from that state, taking that action, and thereafter following  :

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 16 Bellman Equation for a Policy  The basic idea: So: Or, without the expectation operator:

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 17 More on the Bellman Equation This is a set of equations (in fact, linear), one for each state. The value function for  is its unique solution. Backup diagrams:

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 18 Gridworld  Actions: north, south, east, west ; deterministic. pIf would take agent off the grid: no move but reward = –1 pOther actions produce reward = 0, except actions that move agent out of special states A and B as shown. State-value function for equiprobable random policy;  = 0.9

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 19 Golf pState is ball location pReward of –1 for each stroke until the ball is in the hole pValue of a state? pActions: putt (use putter) driver (use driver)  putt succeeds anywhere on the green

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 20 Optimal Value Functions pFor finite MDPs, policies can be partially ordered:  There is always at least one (and possibly many) policies that is better than or equal to all the others. This is an optimal policy. We denote them all  *. pOptimal policies share the same optimal state-value function: pOptimal policies also share the same optimal action-value function: This is the expected return for taking action a in state s and thereafter following an optimal policy.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 21 Optimal Value Function for Golf  We can hit the ball farther with driver than with putter, but with less accuracy  Q*(s, driver ) gives the value or using driver first, then using whichever actions are best

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 22 Bellman Optimality Equation for V* The value of a state under an optimal policy must equal the expected return for the best action from that state: The relevant backup diagram: is the unique solution of this system of nonlinear equations.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 23 Bellman Optimality Equation for Q* The relevant backup diagram: is the unique solution of this system of nonlinear equations.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 24 Why Optimal State-Value Functions are Useful Any policy that is greedy with respect to is an optimal policy. Therefore, given, one-step-ahead search produces the long-term optimal actions. E.g., back to the gridworld:

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 25 What About Optimal Action-Value Functions? Given, the agent does not even have to do a one-step-ahead search:

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 26 Solving the Bellman Optimality Equation pFinding an optimal policy by solving the Bellman Optimality Equation requires the following: accurate knowledge of environment dynamics; we have enough space an time to do the computation; the Markov Property. pHow much space and time do we need? polynomial in number of states (via dynamic programming methods; Chapter 4), BUT, number of states is often huge (e.g., backgammon has about 10**20 states). pWe usually have to settle for approximations. pMany RL methods can be understood as approximately solving the Bellman Optimality Equation.

R. S. Sutton and A. G. Barto: Reinforcement Learning: An Introduction 27 Summary pAgent-environment interaction States Actions Rewards pPolicy: stochastic rule for selecting actions pReturn: the function of future rewards agent tries to maximize pEpisodic and continuing tasks pMarkov Property pMarkov Decision Process Transition probabilities Expected rewards pValue functions State-value function for a policy Action-value function for a policy Optimal state-value function Optimal action-value function pOptimal value functions pOptimal policies pBellman Equations pThe need for approximation