a and weighted a search
play

A* and Weighted A* Search Maxim Likhachev Carnegie Mellon - PowerPoint PPT Presentation

A* and Weighted A* Search Maxim Likhachev Carnegie Mellon University Planning as Graph Search Problem 1. Construct a graph representing the planning problem 2. Search the graph for a (hopefully, close-to-optimal) path The two steps above are


  1. A* and Weighted A* Search Maxim Likhachev Carnegie Mellon University

  2. Planning as Graph Search Problem 1. Construct a graph representing the planning problem 2. Search the graph for a (hopefully, close-to-optimal) path The two steps above are often interleaved Maxim Likhachev Carnegie Mellon University 2

  3. Planning as Graph Search Problem 1. Construct a graph representing the planning problem (future lectures) 2. Search the graph for a (hopefully, close-to-optimal) path (three next lectures) The two steps above are often interleaved Maxim Likhachev Carnegie Mellon University 3

  4. Examples of Graph Construction • Cell decomposition - X-connected grids - lattice-based graphs replicate action template online • Skeletonization of the environment/C-Space -Visibility graphs - Voronoi diagrams - Probabilistic roadmaps Maxim Likhachev Carnegie Mellon University 4

  5. Examples of Graph Construction • Cell decomposition - X-connected grids - lattice-based graphs replicate action template online Will all be covered later • Skeletonization of the environment/C-Space -Visibility graphs - Voronoi diagrams - Probabilistic roadmaps Maxim Likhachev Carnegie Mellon University 5

  6. Examples of Search-based Planning 1. Construct a graph representing the planning problem 2. Search the graph for a (hopefully, close-to-optimal) path The two steps are often interleaved motion planning for autonomous vehicles in 4D (<x,y,orientation,velocity>) running Anytime Incremental A* (Anytime D*) on multi-resolution lattice [Likhachev & Ferguson, IJRR’09] part of efforts by Tartanracing team from CMU for the Urban Challenge 2007 race Maxim Likhachev Carnegie Mellon University 6

  7. Examples of Search-based Planning 1. Construct a graph representing the planning problem 2. Search the graph for a (hopefully, close-to-optimal) path The two steps are often interleaved 8-dim foothold planning for quadrupeds using R* graph search Maxim Likhachev Carnegie Mellon University 7

  8. Searching Graphs for a Least-cost Path • Once a graph is constructed (from skeletonization or uniform cell decomposition or adaptive cell decomposition or lattice or whatever else), we need to search it for a least-cost path 2 S 2 S 1 1 2 S start 1 S goal 1 3 S 4 S 3 Maxim Likhachev Carnegie Mellon University 8

  9. Searching Graphs for a Least-cost Path • Many searches work by computing optimal g-values for relevant states – g(s) – an estimate of the cost of a least-cost path from s start to s – optimal values satisfy: g(s) = min s’’  pred(s) g(s’’) + c(s’’,s) the cost c(s 1 ,s goal ) of an edge from s 1 to s goal g=1 g=3 2 S 2 S 1 1 2 g=0 g=5 S start 1 S goal 1 3 S 4 S 3 g=2 g=5 Maxim Likhachev Carnegie Mellon University 9

  10. Searching Graphs for a Least-cost Path • Many searches work by computing optimal g-values for relevant states – g(s) – an estimate of the cost of a least-cost path from s start to s – optimal values satisfy: g(s) = min s’’  pred(s) g(s’’) + c(s’’,s) the cost c(s 1 ,s goal ) of why? an edge from s 1 to s goal g=1 g=3 2 S 2 S 1 1 2 g=0 g=5 S start 1 S goal 1 3 S 4 S 3 g=2 g=5 Maxim Likhachev Carnegie Mellon University 10

  11. Searching Graphs for a Least-cost Path • Least-cost path is a greedy path computed by backtracking: – start with s goal and from any state s move to the predecessor state s’ such that   s ' arg min ( g ( s ' ' ) c ( s ' ' , s ))  s ' ' pred ( s ) g=1 g=3 2 S 2 S 1 1 2 g=0 g=5 S start 1 S goal 1 3 S 4 S 3 g=2 g=5 Maxim Likhachev Carnegie Mellon University 11

  12. A* Search • Computes optimal g-values for relevant states at any point of time: an (under) estimate of the cost of a shortest path from s to s goal g(s) the cost of a shortest path h(s) from s start to s found so far S S 1 S start … S goal S 2 Maxim Likhachev Carnegie Mellon University 12

  13. A* Search • Computes optimal g-values for relevant states at any point of time: heuristic function g(s) h(s) S S 1 S start … S goal S 2 one popular heuristic function – Euclidean distance Maxim Likhachev Carnegie Mellon University 13

  14. A* Search minimal cost from s to s goal • Heuristic function must be: – admissible: for every state s, h(s) ≤ c*(s,s goal ) – consistent (satisfy triangle inequality) : h(s goal ,s goal ) = 0 and for every s≠s goal , h(s) ≤ c(s,succ(s)) + h(succ(s)) – admissibility follows from consistency and often consistency follows from admissibility Maxim Likhachev Carnegie Mellon University 14

  15. A* Search • Computes optimal g-values for relevant states Main function g(s start ) = 0; all other g- values are infinite ; OPEN = {s start }; ComputePath(); publish solution; set of candidates for expansion ComputePath function while( s goal is not expanded) remove s with the smallest [f(s) = g(s)+h(s)] from OPEN ; expand s ; g=  g=  h=2 h=1 2 g=0 g=  S 2 S 1 1 2 h=3 h=0 S start for every expanded state 1 S goal g(s) is optimal 1 (if heuristics are consistent) 3 S 4 S 3 g=  g=  h=2 h=1 Maxim Likhachev Carnegie Mellon University 15

  16. A* Search • Computes optimal g-values for relevant states ComputePath function while( s goal is not expanded) remove s with the smallest [f(s) = g(s)+h(s)] from OPEN ; expand s ; g=  g=  h=2 h=1 2 g=0 g=  S 2 S 1 1 2 h=3 h=0 S start 1 S goal 1 3 S 4 S 3 g=  g=  h=2 h=1 Maxim Likhachev Carnegie Mellon University 16

  17. A* Search • Computes optimal g-values for relevant states ComputePath function while( s goal is not expanded) remove s with the smallest [f(s) = g(s)+h(s)] from OPEN ; insert s into CLOSED ; for every successor s’ of s such that s’ not in CLOSED if g(s’) > g(s) + c(s,s’) g(s’) = g(s) + c(s,s’); set of states that have already been expanded insert s’ into OPEN ; g=  g=  h=2 h=1 tries to decrease g(s’) using the 2 g=0 g=  S 2 S 1 found path from s start to s 1 2 h=3 h=0 S start 1 S goal 1 3 S 4 S 3 g=  g=  h=2 h=1 Maxim Likhachev Carnegie Mellon University 17

  18. A* Search • Computes optimal g-values for relevant states ComputePath function while( s goal is not expanded) remove s with the smallest [f(s) = g(s)+h(s)] from OPEN ; insert s into CLOSED ; for every successor s’ of s such that s’ not in CLOSED if g(s’) > g(s) + c(s,s’) g(s’) = g(s) + c(s,s’); insert s’ into OPEN ; g=  g=  h=2 h=1 2 g=0 g=  S 2 S 1 1 2 h=3 h=0 CLOSED = {} S start 1 S goal OPEN = {s start } 1 next state to expand: s start 3 S 4 S 3 g=  g=  h=2 h=1 Maxim Likhachev Carnegie Mellon University 18

  19. A* Search • Computes optimal g-values for relevant states ComputePath function while( s goal is not expanded) remove s with the smallest [f(s) = g(s)+h(s)] from OPEN ; insert s into CLOSED ; for every successor s’ of s such that s’ not in CLOSED if g(s’) > g(s) + c(s,s’) g(s 2 ) > g(s start ) + c(s start ,s 2 ) g(s’) = g(s) + c(s,s’); insert s’ into OPEN ; g=  g=  h=2 h=1 2 g=0 g=  S 2 S 1 1 2 h=3 h=0 CLOSED = {} S start 1 S goal OPEN = {s start } 1 next state to expand: s start 3 S 4 S 3 g=  g=  h=2 h=1 Maxim Likhachev Carnegie Mellon University 19

  20. A* Search • Computes optimal g-values for relevant states ComputePath function while( s goal is not expanded) remove s with the smallest [f(s) = g(s)+h(s)] from OPEN ; insert s into CLOSED ; for every successor s’ of s such that s’ not in CLOSED if g(s’) > g(s) + c(s,s’) g(s’) = g(s) + c(s,s’); insert s’ into OPEN ; g=  g=1 h=2 h=1 2 g=0 g=  S 2 S 1 1 2 h=3 h=0 S start 1 S goal 1 3 S 4 S 3 g=  g=  h=2 h=1 Maxim Likhachev Carnegie Mellon University 20

  21. A* Search • Computes optimal g-values for relevant states ComputePath function while( s goal is not expanded) remove s with the smallest [f(s) = g(s)+h(s)] from OPEN ; insert s into CLOSED ; for every successor s’ of s such that s’ not in CLOSED if g(s’) > g(s) + c(s,s’) g(s’) = g(s) + c(s,s’); insert s’ into OPEN ; g=  g=1 h=2 h=1 2 g=0 g=  S 2 S 1 1 2 h=3 h=0 CLOSED = {s start } S start 1 S goal OPEN = {s 2 } 1 next state to expand: s 2 3 S 4 S 3 g=  g=  h=2 h=1 Maxim Likhachev Carnegie Mellon University 21

  22. A* Search • Computes optimal g-values for relevant states ComputePath function while( s goal is not expanded) remove s with the smallest [f(s) = g(s)+h(s)] from OPEN ; insert s into CLOSED ; for every successor s’ of s such that s’ not in CLOSED if g(s’) > g(s) + c(s,s’) g(s’) = g(s) + c(s,s’); insert s’ into OPEN ; g=1 g= 3 h=2 h=1 2 g=0 g=  S 2 S 1 1 2 h=3 h=0 CLOSED = {s start ,s 2 } S start 1 S goal OPEN = {s 1 ,s 4 } 1 next state to expand: s 1 3 S 4 S 3 g=  g= 2 h=1 h=2 Maxim Likhachev Carnegie Mellon University 22

  23. A* Search • Computes optimal g-values for relevant states ComputePath function while( s goal is not expanded) remove s with the smallest [f(s) = g(s)+h(s)] from OPEN ; insert s into CLOSED ; for every successor s’ of s such that s’ not in CLOSED if g(s’) > g(s) + c(s,s’) g(s’) = g(s) + c(s,s’); insert s’ into OPEN ; g=1 g= 3 h=2 h=1 2 g=0 S 2 g= 5 S 1 1 2 h=3 h=0 CLOSED = {s start ,s 2 ,s 1 } S start 1 S goal OPEN = {s 4 ,s goal } 1 next state to expand: s 4 3 S 4 S 3 g=  g= 2 h=1 h=2 Maxim Likhachev Carnegie Mellon University 23

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend