1 / 30

Finish Search Jim Little UBC CS 322 – Search 7 September 24, 2014 Textbook §3.6

Finish Search Jim Little UBC CS 322 – Search 7 September 24, 2014 Textbook §3.6. Lecture Overview. Finish MBA* Pruning Cycles and Repeated states Examples Dynamic Programming Search Recap. H euristic value by look ahead. Memory-bounded A *.

enoch
Download Presentation

Finish Search Jim Little UBC CS 322 – Search 7 September 24, 2014 Textbook §3.6

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Finish Search • Jim Little • UBC CS 322 – Search 7 September 24, 2014 Textbook §3.6

  2. Lecture Overview • Finish MBA* • Pruning Cycles and Repeated states Examples • Dynamic Programming • Search Recap

  3. Heuristic value by look ahead

  4. Memory-bounded A* • Iterative deepening A* and B & B use a tiny amount of memory • what if we've got more memory to use? • keep as much of the fringe in memory as we can • if we have to delete something: • delete the worst paths ( ) • ``back them up'' to a common ancestor highest f p p1 pn

  5. MBA*: Compute New h(p)

  6. Lecture Overview • Finish MBA* • Interlude: State Space/Search Graphs • Pruning Cycles and Repeated states Examples • Dynamic Programming • Search Recap

  7. Clarification: state space graph vs search tree k a d kb kc kch b kbz z 4 5 k c h kchfy 6 7 8 f kbza kbzd State space graph. If there are no cycles, the two look the same Search tree. Nodes in this tree correspond to paths in the state space graph

  8. Clarification: state space graph vs search tree k a d The numbers in the search tree’s nodes mean? kb kc kch b kbz z 4 5 k c h kchf 6 7 8 f kbza kbzd State space graph. Search tree. Order in which a search algo. (here: BFS) expands nodes Node’s name 8

  9. Clarification: state space graph vs search tree k a d • If there are cycles, the two look very different kb kc kch b kbk kbz kck z k c h kchf kbkb kbkc f kbza kbzd kckb kckc State space graph. Search tree. (only first 3 levels, of BFS)

  10. Clarification: state space graph vs search tree k a d kb kc kch b kbk kbz kck z k c h kchf kbkb kbkc f kbza kbzd kckb kckc State space graph. Search tree. (only first 3 levels, of BFS)

  11. Clarification: state space graph vs search tree k a d kb kc kch b kbk kbz kck z k c h kchf kbkb kbkc f kbza kbzd kckb kckc State space graph. Search tree. (only first 3 levels, of BFS)

  12. Clarification: state space graph vs search tree k a d kb kc kch b kbk kbz kck z k c h kchz kbkb kbkc z kbza kbzd kckb kckc State space graph. May contain cycles! Search tree. Nodes in this tree correspond to paths in the state space graph (if multiple start nodes: forest) Cannot contain cycles!

  13. Clarification: state space graph vs search tree k a d kb kc kch b kbk kbz kck z k c h kchz kbkb kbkc z State space graph. Why don’t we just eliminate cycles? Sometimes (but not always) we want multiple solution paths kbza kbzd kckb kckc Search tree. Nodes in this tree correspond to paths in the state space graph

  14. Lecture Overview • Finish MBA* • Pruning Cycles and Repeated states Examples • Dynamic Programming • Search Recap

  15. Multiple-Path Pruning & Optimal Solutions • Problem: what if a subsequent path to n is shorter than the first path to n ? • You can remove all paths from the frontier that use the longer path. (as these can’t be optimal)

  16. Multiple-Path Pruning & Optimal Solutions • Problem: what if a subsequent path to n is shorter than the first path to n ? • You can change the initial segment of the paths on the frontier to use the shorter path.

  17. Example Pruning Cycles Repeated States

  18. Lecture Overview • Finish MBA* • Pruning Cycles and Repeated states Examples • Dynamic Programming • Search Recap

  19. Dynamic Programming • Idea: for statically stored graphs, build a table of dist(n): • The actual distance of the shortest path from node n to a goal g • This is the perfect • dist(g) = 0 • dist(z) = 1 • dist(c) = 3 • dist(b) = 4 • dist(k) = ? • dist(h) = ? • How could we implement that? cost f function heuristic 2 b h 2 1 3 k c g 4 6 7  1 z 6 7 

  20. Dynamic Programming • This can be built backwards from the goal: m 0 g b c a 2 d 2 2 b g 1 1 a c 3 3

  21. Dynamic Programming This can be used locally to determine what to do. From each nodengo to its neighbor which minimizes • But there are at least two main problems: • You need enough space to store the graph. • The dist function needs to be recomputed for each goal 4 d 2 2 b 2 2 g 1 3 1 a c 3 3 3

  22. Lecture Overview • Finish MBA* • Pruning Cycles and Repeated states Examples • Dynamic Programming • Search Recap

  23. Recap Search

  24. Recap Search (some qualifications) C>0 h admiss. no inf path

  25. Search in Practice

  26. approve robuddies-seminars.admin \ subscribe robuddies-seminars \Justin Hart <justin.hart@mech.ubc.ca> Search in Practice (cont’) approve robuddies-seminars.admin \ subscribe robuddies-seminars \Justin Hart <justin.hart@mech.ubc.ca> F IDS B&B Informed? T T IDA* Many paths to solution, no ∞paths? T F Large branching factor? F MBA*

  27. (Adversarial) Search: Chess • Deep Blue’s Results in the second tournament: • second tournament: won 3 games, lost 2, tied 1 • 30 CPUs + 480 chess processors • Searched 126.000.000 nodes per sec • Generated 30 billion positions per move reaching depth 14 routinely • Iterative Deepening with evaluation function (similar to a heuristic) based on 8000 features (e.g., sum of worth of pieces: pawn 1, rook 5, queen 10)

  28. Modules we'll cover in this course: R&Rsys Stochastic Deterministic • Environment Problem Arc Consistency Constraint Satisfaction Vars + Constraints Search Static Belief Nets Logics Query Var. Elimination Search Sequential Decision Nets STRIPS Var. Elimination Planning Search Markov Processes Representation Value Iteration Reasoning Technique

  29. Standard Search vs. Specific R&R systems • Constraint Satisfaction (Problems): • State • Successor function • Goal test • Solution • Heuristic function • Planning : • State • Successor function • Goal test • Solution • Heuristic function • Inference • State • Successor function • Goal test • Solution • Heuristic function

  30. Next class Start Constraint Satisfaction Problems (CSPs) Textbook 4.1-4.3

More Related