Discrete planning (an introduction)

Similar documents
ME/CS 132: Advanced Robotics: Navigation and Vision

Path Planning. Marcello Restelli. Dipartimento di Elettronica e Informazione Politecnico di Milano tel:

Outline. Best-first search

CMU-Q Lecture 2: Search problems Uninformed search. Teacher: Gianni A. Di Caro

Search: Advanced Topics and Conclusion

CS261: Problem Set #1

Heuristic Search and Advanced Methods

Uninformed Search Methods

Branch & Bound (B&B) and Constraint Satisfaction Problems (CSPs)

Search. CS 3793/5233 Artificial Intelligence Search 1

Informed Search Methods

Artificial Intelligence

Search. (Textbook Chpt ) Computer Science cpsc322, Lecture 2. May, 10, CPSC 322, Lecture 2 Slide 1

Uniformed Search (cont.)

Class Overview. Introduction to Artificial Intelligence COMP 3501 / COMP Lecture 2: Search. Problem Solving Agents

Outline. Best-first search

Uninformed Search. Day 1 & 2 of Search. Russel & Norvig Chap. 3. Material in part from

Single Source Shortest Path (SSSP) Problem

HW#1 due today. HW#2 due Monday, 9/09/13, in class Continue reading Chapter 3

Strongly connected: A directed graph is strongly connected if every pair of vertices are reachable from each other.

Search: Advanced Topics and Conclusion

Assignment 1 is out! Due: 9 Sep 23:59! Can work in a group of 2-3 students.! NO cheating!!!! Submit in turnitin! Code + report!

Recap A Search Optimality of A. Search: A. CPSC 322 Search 5. Textbook 3.6. Search: A CPSC 322 Search 5, Slide 1

CPS 170: Artificial Intelligence Search

Algorithms for Data Science

Analysis of Algorithms, I

Informed State Space Search B4B36ZUI, LS 2018

Set 2: State-spaces and Uninformed Search. ICS 271 Fall 2015 Kalev Kask

Route planning / Search Movement Group behavior Decision making

Last time: Problem-Solving

Probabilistic Belief. Adversarial Search. Heuristic Search. Planning. Probabilistic Reasoning. CSPs. Learning CS121

Class Overview. Introduction to Artificial Intelligence COMP 3501 / COMP Lecture 2. Problem Solving Agents. Problem Solving Agents: Assumptions

ITCS 6150 Intelligent Systems. Lecture 5 Informed Searches

CS 161 Lecture 11 BFS, Dijkstra s algorithm Jessica Su (some parts copied from CLRS) 1 Review

CS521 \ Notes for the Final Exam

Name: UW CSE 473 Midterm, Fall 2014

Uninformed Search. (Textbook Chpt 3.5) Computer Science cpsc322, Lecture 5. May 18, CPSC 322, Lecture 5 Slide 1

Network Design and Optimization course

A.I.: Informed Search Algorithms. Chapter III: Part Deux

General Methods and Search Algorithms

CSC 373 Lecture # 3 Instructor: Milad Eftekhar

Informed search strategies (Section ) Source: Fotolia

Lecture 11: Analysis of Algorithms (CS ) 1

Shortest Path Problem

Discrete search algorithms

3 SOLVING PROBLEMS BY SEARCHING

Shortest path problems

Informed search methods

Structures and Strategies For Space State Search

Today s s lecture. Lecture 3: Search - 2. Problem Solving by Search. Agent vs. Conventional AI View. Victor R. Lesser. CMPSCI 683 Fall 2004

CS510 \ Lecture Ariel Stolerman

Chapter S:IV. IV. Informed Search

Introduction to Algorithms / Algorithms I Lecturer: Michael Dinitz Topic: Shortest Paths Date: 10/13/15

CS 512: Comments on Graph Search 16:198:512 Instructor: Wes Cowan

CIS 192: Artificial Intelligence. Search and Constraint Satisfaction Alex Frias Nov. 30 th

DIT411/TIN175, Artificial Intelligence. Peter Ljunglöf. 23 January, 2018

Lecture 4: Search 3. Victor R. Lesser. CMPSCI 683 Fall 2010

Lecture 3 - States and Searching

Algorithms for Minimum Spanning Trees

Heuristic (Informed) Search

Artificial Intelligence p.1/49. n-queens. Artificial Intelligence p.2/49. Initial state: the empty board or a board with n random

Discrete Motion Planning

Week 3: Path Search. COMP9414/ 9814/ 3411: Artificial Intelligence. Motivation. Example: Romania. Romania Street Map. Russell & Norvig, Chapter 3.

Dijkstra s algorithm for shortest paths when no edges have negative weight.

Search : Lecture 2. September 9, 2003

Lecture 3 of 42. Lecture 3 of 42

Search Algorithms for Discrete Optimization Problems

Review of course COMP-251B winter 2010

CS 343: Artificial Intelligence

Lecture Summary CSC 263H. August 5, 2016

Distributed Algorithms 6.046J, Spring, Nancy Lynch

CS 4100 // artificial intelligence

Exam Topics. Search in Discrete State Spaces. What is intelligence? Adversarial Search. Which Algorithm? 6/1/2012

search, DFS & BrFS; cycle checking & MPC arc costs; heuristics; LCFS, BeFS, A* misc: iterative deepening, etc.

ARTIFICIAL INTELLIGENCE. Pathfinding and search

Other course stuff. CSCI 599: Coordinated Mobile Robotics Prof. Nora Ayanian

Heuristic Search INTRODUCTION TO ARTIFICIAL INTELLIGENCE BIL 472 SADI EVREN SEKER

Graph Representation DFS BFS Dijkstra A* Search Bellman-Ford Floyd-Warshall Iterative? Non-iterative? MST Flow Edmond-Karp

Solving Problems by Searching

A and Branch-and-Bound Search

Informed Search Lecture 5

Informed (heuristic) search (cont). Constraint-satisfaction search.

CS:4420 Artificial Intelligence

Introduction to Optimization

Künstliche Intelligenz

Artificial Intelligence

Notes. Video Game AI: Lecture 5 Planning for Pathfinding. Lecture Overview. Knowledge vs Search. Jonathan Schaeffer this Friday

SRI VIDYA COLLEGE OF ENGINEERING & TECHNOLOGY REPRESENTATION OF KNOWLEDGE PART A

Algorithms for Data Science

Cpt S 223 Course Overview. Cpt S 223, Fall 2007 Copyright: Washington State University

Chapter 9. Greedy Technique. Copyright 2007 Pearson Addison-Wesley. All rights reserved.

4 INFORMED SEARCH AND EXPLORATION. 4.1 Heuristic Search Strategies

Introduction to Parallel & Distributed Computing Parallel Graph Algorithms

Planning and Control: Markov Decision Processes

CSE 100 Minimum Spanning Trees Prim s and Kruskal

Problem 1 Zero: 11% (~20 students), Partial: 66% (~120 students), Perfect: 23% (~43 students)

Chapter 11 Search Algorithms for Discrete Optimization Problems

Solving Problems by Searching

CS 561, Lecture 10. Jared Saia University of New Mexico

Searching with Partial Information

Transcription:

Sistemi Intelligenti Corso di Laurea in Informatica, A.A. 2017-2018 Università degli Studi di Milano Discrete planning (an introduction) Nicola Basilico Dipartimento di Informatica Via Comelico 39/41-20135 Milano (MI) Ufficio S242 nicola.basilico@unimi.it +39 02.503.16294 Sito per queste lezioni

Dijkstra Recall: when x is selected, it becomes dead Thesis: when x is selected (and closed), we know its optimal cost-to-come Proof sketch: induction argument over the number of dead nodes (call it d) obtained after selection of x from Q Base case: d=1 then x is the initial state for which the optimal cost-to-come is known to be 0 (d=0 cannot happen from the definition of forward search) Inductive step: d=n (thesis holds for the previously selected N-1 dead nodes) 1. to reach x, we must visit a node currently in Q: impossible, their cost-to-come is higher than that of x and x would not have been selected 2. to reach x we visit only dead nodes: possible, from inductive assumption we know that we got the optimal plan to each of those nodes then C(x) is actually C*(x)

Dijkstra Why we need shortest paths to solve planning for feasibility? Because by solving for minimum cost plans we also solve for feasibility: if the algorithm computed a cost for a node x then we have a plan to reach it, otherwise the state cannot be reached Dijkstra runs in O( V ln V + E ) with clever implementation of Q (Fibonacci heap) It s systematic

A* It s a generalization of Dijkstra where the queue is sorted according to this function cost-to-come estimate of the minimum cost-to-go cost-to-go: the cost for going from x to the goal It guarantees to find the minimum cost plan (like Dijkstra) provided that we do not overestimate the cost-to-go (see previous proof sketch) If we set we obtain Dijsktra The better our estimates, the fewer nodes are visited w.r.t. Dijkstra It s systematic

A* Not overestimating the cost-to-go (admissible heuristic)

Best first Q is sorted using only the estimate of the cost-to-go Does not guarantee minimum cost plans so it doesn t matter if costs are overestimated! Way faster and efficient If something looks good, even very early, it will take it: too greedy! Not systematic

Iterative deepening and IDA* Idea: try to make depth-first search systematic Straightforward approach: use DFS to find all plans with length <=i if goal was not found, i++ and repeat Usually more efficient than BFS (especially with large branching factors): if the nearest goal is i hops away from the initial state, in the worst case BFS could try all nodes at i+1 hops first IDA* naturally follows when applying this idea to A* by introducing allowed total costs

Backward search Symmetric template of forward search: goal start We can just use forward search on the state transition graph where we reversed the arcs Useful when branching is very high when starting from x I

Backward search (example?)

Bidirectional search Template combining forward and backward search: what s happening here? We need to grow the two trees so that they tend to meet quickly. It can be difficult.

Planning for optimality Let us extend the formulation we presented for the feasibility version Call K the length of a plan, and x k+1 the state reached when action u k from the plan is applied This plan of K actions causes the following sequence of states which we might relabel for convenience This plan has a cost: X F is not a goal state X F is a goal state We want to minimize the cost of a plan With this definition of plan cost we enforce feasibility through optimization: seeking for optimal plans entails seeking also for feasible ones

Fixed length plans Problem: find the optimal (minimum cost) plan which has length upper bounded by K Idea: let s make a list of all the <=K length plans and evaluate their cost, then choose the best We don t have to do this thanks to Bellman s principle of optimality

Principle of optimality For some problems optimality admits a recursive definition start goal optimal plan start goal optimal sub-plan + optimal sub-plan Optimal substructure: construct an optimal solution for P exploiting optimal solutions of sub-problems of P This principle leads to a resolution method called value iteration

Backward value iteration Idea: compute cost-to-go backwards Cost from x k to x F along the optimal plan

Backward value iteration

Backward value iteration optimal cost-to-go for any state if final or optimal cost for the empty plan

Backward value iteration optimal cost-to-go for any state when being right before the final one or.. optimal cost of the plan with length 1 We can recursively propagate this reasoning scheme obtaining

Backward value iteration optimal sub-plan from x k+1 If we unroll the execution of this recursive procedure we obtain: in O(K X U ), G* 1 gives the cost of the optimal plan, the actual plan can be obtained by backward annotation of argmins

Plans of arbitrary length Remove the length limit and add a termination action a t If applied it does not change the current state, does not cause any cost and must be applied forever from there on We stop our backward value iteration when it converges, i.e., G does not change anymore Ok only if costs are non-negative

Planning under uncertainty Action selection is often affected by uncertainty Example:

Planning under uncertainty Action selection is often affected by uncertainty Example:

Planning under uncertainty Action selection is often affected by uncertainty Example: Fast forward for 2 seconds

Planning under uncertainty Action selection is often affected by uncertainty Example:? Fast forward for 2 seconds

Planning under uncertainty Are the effects of my actions perfectly predictable? Am I always sure about what s going on? Deterministic vs Stochastic transitions Fully observable vs Partially observable states

Examples Deterministic transitions, fully observable states Only actuation is needed, no sensing! A move B B

Examples Stochastic transitions, fully observable states Surveillance robot Pos A move B Pos B Pos C Broken

Examples? Pos A move Pos B? Pos D move Pos C Deterministic transitions, partially observable states

Examples? Pos A move 0.99 Pos B? Pos D move 0.99 Pos C Broken Stochastic transitions, partially observable states

Nicola Basilico Dipartimento di Informatica Via Comelico 39/41-20135 Milano (MI) Ufficio S242 nicola.basilico@unimi.it +39 02.503.16294 Sistemi Intelligenti Corso di Laurea in Informatica, A.A. 2017-2018 Università degli Studi di Milano