RTDP
Also known as Real-Time Dynamic Programming
search stochastic-search
RTDP (real-time dynamic programming) plans when actions have costs and random outcomes, and a goal must be reached at the lowest expected cost (a stochastic shortest path problem). It runs trials: from the start state, it sets the state's value to the cheapest expected cost over its actions (a Bellman backup), takes the cheapest action and samples a successor. With an admissible heuristic (one that never overestimates the cost), the values on the states that trials keep visiting converge to the optimum. The crate's rtdp stops when every state that the greedy policy reaches has a residual (the change that one more backup would make) of at most ε. It is a baseline for comparisons; use lrtdp for real problems.
Pseudocode
algorithm RTDP(s₀, goal, h, ε)input: initial state s₀, goal test goal, heuristic h, tolerance εoutput: values V and a greedy policy πV[s] ← h(s) for each state s when it is first reachedrepeats ← s₀while not goal(s) doback-up(s) ▷ V[s] ← min over a of Q(s, a), π[s] ← its argminif π[s] = nil then ▷ a dead end ends the trialbreaks ← sample(successors(s, π[s]))until envelope-consistent(s₀, ε) ▷ checked only now and thenreturn V, πfunction envelope-consistent(s₀, ε)▷ the solved check of LRTDP; a failed check backs up nothingfor each state t reachable from s₀ under π doif |V[t] − min over a of Q(t, a)| > ε thenreturn falsereturn trueIn the crates
stochastic-searchPlain real-time dynamic programming with LRTDP's solved check as its stopping rule; the classic baseline.
Lineage
Papers
- Learning to act using real-time dynamic programming Andrew G. Barto, Steven J. Bradtke, Satinder P. Singh · 1995· Artificial Intelligence