Summary. Agenda. Search. Search is a common technique in problem solving. Search Formulation Tree Search Uniform cost search A* Search.

Similar documents
1/19/2010. Usually for static, deterministic environment

Uninformed Search. Models To Be Studied in CS 540. Chapter Search Example: Route Finding

Lecture overview. Knowledge-based systems in Bioinformatics, 1MB602, Goal based agents. Search terminology. Specifying a search problem

Lecture 14: March 9, 2015

mywbut.com Uninformed Search

Problem solving by search

Reminders. Problem solving and search. Problem-solving agents. Outline. Assignment 0 due 5pm today

Problem solving and search

Problem solving and search

Problem solving and search

Problem solving Basic search. Example: Romania. Example: Romania. Problem types. Intelligent Systems and HCI D7023E. Single-state problem formulation

Problem-solving agents. Problem solving and search. Example: Romania. Reminders. Example: Romania. Outline. Chapter 3

Outline. Problem solving and search. Problem-solving agents. Example: Romania. Example: Romania. Problem types. Problem-solving agents.

Problem Solving and Search. Chapter 3

Solving problems by searching

Outline. Solving problems by searching. Prologue. Example: Romania. Uninformed search

COMP 8620 Advanced Topics in AI

Problem-solving agents. Solving Problems by Searching. Outline. Example: Romania. Chapter 3

SOLVING PROBLEMS BY SEARCHING

Problem Solving as State Space Search. Assignments

CS 331: Artificial Intelligence Uninformed Search. Leftovers from last time

Artificial Intelligence, CS, Nanjing University Spring, 2018, Yang Yu. Lecture 2: Search 1.

A2 Uninformed Search

Example: The 8-puzzle. A2 Uninformed Search. It can be generalized to 15-puzzle, 24-puzzle, or. (n 2 1)-puzzle for n 6. Department of Computer Science

CS 331: Artificial Intelligence Uninformed Search. Real World Search Problems

CS 331: Artificial Intelligence Uninformed Search. Real World Search Problems

Outline. Informed Search. Recall: Uninformed Search. An Idea. Heuristics Informed search techniques More on heuristics Iterative improvement

Solving Problem by Searching. Chapter 3

Uninformed Search. Reading: Chapter 4 (Tuesday, 2/5) HW#1 due next Tuesday

Logic Programming: Search Strategies

6.01: Introduction to EECS 1 Week 13 December 1, 2009

Search. Intelligent agents. Problem-solving. Problem-solving agents. Road map of Romania. The components of a problem. that will take me to the goal!

Outline. Solving Problems by Searching. Introduction. Problem-solving agents

Uninformed Search B. Navigating through a search tree. Navigating through a search tree. Navigating through a search tree

Today More about Trees. Introduction to Computers and Programming. Spanning trees. Generic search algorithm. Prim s algorithm Kruskal s algorithm

Problem solving and search: Chapter 3, Sections 1 5

State Transition Graph of 8-Puzzle E W W E W W 3 2 E

Problem solving and search: Chapter 3, Sections 1 5

Minimum Spanning Trees and Shortest Paths

What is Search? Intro to Search. Search problems. Finding goals in trees. Why is goal search not trivial? Blind Search Methods

MASSACHUSETTS INSTITUTE OF TECHNOLOGY Department of Electrical Engineering and Computer Science Artificial Intelligence Fall, 2010

CS 8520: Artificial Intelligence

Problem Solving and Searching

6.01: Introduction to EECS I Lecture 13 May 3, 2011

Algorithms for Data Structures: Uninformed Search. Phillip Smith 19/11/2013

Logic Programming: Search Strategies

CS:4420 Artificial Intelligence

EE562 ARTIFICIAL INTELLIGENCE FOR ENGINEERS

Minimum Spanning Trees and Shortest Paths

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

An Early Problem in Graph Theory. Clicker Question 1. Konigsberg and the River Pregel

Incremental Path Planning

ITCS 6150 Intelligent Systems. Lecture 3 Uninformed Searches

Uninformed Search B. Navigating through a search tree. Navigating through a search tree. Navigating through a search tree

CS1800: Graph Algorithms (2nd Part) Professor Kevin Gold

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

Solving problems by searching

Planning and search. Lecture 1: Introduction and Revision of Search. Lecture 1: Introduction and Revision of Search 1

CSC 2114: Artificial Intelligence Search

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

Problem solving and search

CS 771 Artificial Intelligence. Problem Solving by Searching Uninformed search

Artificial Intelligence: Search Part 1: Uninformed graph search

Solving problems by searching

Note. Out of town Thursday afternoon. Willing to meet before 1pm, me if you want to meet then so I know to be in my office

Problem Solving and Search

Uninformed Search. CPSC 322 Lecture 5. September 14, 2007 Textbook 2.4. Graph Search Searching Depth-First Search

CS 380: Artificial Intelligence Lecture #3

Introduction to Graphs. common/notes/ppt/

CS-171, Intro to A.I. Final Exam Winter Quarter, 2012

Chapter 3. A problem-solving agent is a kind of goal-based agent. It decide what to do by finding sequences of actions that lead to desirable states.

Outline. Solving problems by searching. Problem-solving agents. Example: Romania

Solving problems by searching

Search Methods 9/21/11 MOTIVATION. Artificial Intelligence. Where are we? Outline. Problem Solving as Search

Bayesian Networks and Decision Graphs

Uninformed Search. CPSC 322 Lecture 5. January 17, 2007 Textbook 2.4. Uninformed Search CPSC 322 Lecture 5, Slide 1

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

An Early Problem in Graph Theory

Downloded from: CSITauthority.blogspot.com

Announcements. Project 0: Python Tutorial Due last night

Solving Problems by Searching

Uninformed Search Strategies

Problem: Large Graphs

Uninformed Search Complexity. Informed Search. Search Revisited. Day 2/3 of Search

Pengju XJTU 2016

Solving problems by searching

Chapter 2. Blind Search 8/19/2017

Solving Problems by Searching

Chapter 3: Solving Problems by Searching

Luke. Leia 2. Han Leia

Solving Problems by Searching

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

Why Search. Things to consider. Example, a holiday in Jamaica. CSE 3401: Intro to Artificial Intelligence Uninformed Search

Uniformed Search (cont.)

Data Structure Chapter 6

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

Search : Lecture 2. September 9, 2003

Intelligent Agents. Foundations of Artificial Intelligence. Problem-Solving as Search. A Simple Reflex Agent. Agent with Model and Internal State

Search Algorithms. Uninformed Blind search. Informed Heuristic search. Important concepts:

Problem Solving as Search. CMPSCI 383 September 15, 2011

Transcription:

ummary rtificial Intelligence and its applications ecture earch earch onstraint atisfaction Problems rom start state to goal state onsider constraints Professor aniel Yeung danyeung@ieee.org r. Patrick han patrickchan@ieee.org outh hina University of Technology, hina ifficulty ame Playing Markov ecision Processes onsider an adversary onsider an uncertainty einforcement earning No information is given rtificial Intelligence and its applications - ecture : ame Playing genda earch earch ormulation Tree earch Uniform cost search * earch earch is a common technique in problem solving Maze Magic ube 8 puzzle oute-finding rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch

earch n agent finds the action sequence which leads to a goal state nvironment: a set of states gent: User, player, etc who can take actions to change states earch Procedure ormulation How to convert a real problem into a problem can be solved by our algorithm earch earching algorithm xecution ealize it rtificial Intelligence and its applications - ecture : earch 6 rtificial Intelligence and its applications - ecture : earch ormulation implification kashi Too simple: ridge not enough information waji Too complicate: increase complexity and difficulty ppropriate level of abstraction? kashi waji uma uma Harbor and Harbor and Meriken Park Port Kobe irport Meriken Park Port Kobe irport ormulation ssumptions Observable: can be converted into states tatic: no change in execution iscrete: states, actions eterministic: can be predicted kashi waji uma Harbor and Meriken Park Port Kobe irport 7 rtificial Intelligence and its applications - ecture : earch 8 rtificial Intelligence and its applications - ecture : earch

tate s Information of earch tart (Initial) tate nd (oal) tate = {kashi, uma, Harbor and } ction(kashi) = ction(s) : Possible action (a) in s {go to uma, go to waji } ost(s, a) : ction cost ost(uma, go to kashi) = ost(uma, go to Harborand) = ucc(s, a) = s : successor ucc(kashi, go to ) = uma ormulation xample vacuum robot cleans up two rooms automatically How to formulate this problem? kashi waji uma Harbor and Meriken Park Port Kobe irport Two rooms vacuum robot dirt 9 rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch ormulation xample ormulation xample actor of a room: or each room, possible states With / without irt With / without obot or two rooms ctions: ight eft uck ction cost: ach action costs one Initial tate: ny state oal tate: ll rooms are clean Therefore, 8 states rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch

ormulation earch raph ormulation earch raph Nodes are states ach state occurs only once rcs represent successors i.e. action results The goal test is a set of goal nodes rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch ormulation earch Tree arelybuild the full graph in memory raph is usually too big Not necessary to build the whole graph to obtain the solution rtificial Intelligence and its applications - ecture : earch ormulation earch Tree earch Tree will build until the solution is found 6 oot : start state hildren : correspond to successors ometimes the size of a tree is infinite epeat is unavoidable (e.g. move left and right) i.e. yclic graph a graph with a cycle H P J V M rtificial Intelligence and its applications - ecture : earch N Q

ormulation earch Tree ormulation earch Tree yclic graph cyclic graph Infinite Tree inite Tree 7 rtificial Intelligence and its applications - ecture : earch 8 rtificial Intelligence and its applications - ecture : earch earch valuation earch lgorithm ompleteness Is the algorithm guaranteed to find a solution when there is one? Optimality oes the strategy find the optimal solution? Time complexity How long does it take to find a solution? pace complexity How much memory is needed to perform the search? ost-insensitive earch ame cost for all actions Method: Tree earch ost-sensitive earch ctions with different costs Method: Uniform ost earch 7 9 rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch

Tree earch: epth-irst earch xpand deepest nodes first Not optimal (Only leftmost solution) May be infinite Need to control the depth Time complexity: O(b ) pace complexity: O() where b is branch factor is max. depth of the tree rtificial Intelligence and its applications - ecture : earch annot find the optimal one Tree earch: epth V readth-irst earch Tree earch: readth-irst earch xpand shallowest nodes first Optimal for uniform cost Time complexity: O(b s ) pace complexity: O(b s ) where b is branch factor s is the depth of the shallow solution rtificial Intelligence and its applications - ecture : earch Tree earch: Iterative eepening earch When or is better? pace : : Time : : the tree contains the shallow solution a path aster for hallow olution aster for eep olution (?) Need to determine the depth limit to avoid the infinite depth Take the advantages from and : ess time complexity for shallow solution : ess space complexity lgorithm et i =, run with depth limit (i x n) If no solution, do it again with i = i + n n n... rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch

Tree earch: Iterative eepening earch dvantage: educe the space complexity (only one path) No need to consider the infinite tree isadvantage: edundancy: hallow part of tree is considered several times n n n... Tree earch: idirectional earch Two trees from opposite directions uild two trees rooted at Initial and oal state top when the two trees meet each other Time complexity: b s/ + b s/ < b d pace complexity: O(b s ) where b is branch factor s is the depth of the shallow solution rtificial Intelligence and its applications - ecture : earch 6 rtificial Intelligence and its applications - ecture : earch Tree earch: idirectional earch Uniform ost earch ost-sensitive search onsider the cost of actions ind the shortest path from the start state to a state in each iteration until the end state is considered ll weight values are non-negative imilar to ijkstra s algorithm ble to handle a weighted cyclic graph 7 rtificial Intelligence and its applications - ecture : earch 8 rtificial Intelligence and its applications - ecture : earch

Uniform ost earch Uniform ost earch xpand explored region to cover the end state xplored: already found the optimal path rontier: still figuring out the optimal path Unexplored: states have not been seen xplore states according to the order of value of Pastost() Pastost(): the minimum cost from the start state to s utureost(): the minimum cost from to an end state tart xplored nd Pastost() utureost() rontier Unexplored 9 rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch Uniform ost earch Uniform ost earch dd start state to frontier (priority queue) epeat until frontier is empty: emove s with smallest priority p from frontier If s = end state: return solution ddsto explored or each action ain ctions(s): et successor s <- ucc(s, a) If s already in explored: continue dd s to frontier with priority p + ost(s, a) 87 9 xplored rontier Unexplored rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch

Uniform ost earch * earch 8 7 7 9 7 9 Uniform cost search explores many states which are far away from the end state * improves uniform cost search by biasing the states which are closer to the end state Wasted effort at this side? tart xplored rontier Unexplored nd rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch * earch * earch xample Pastost() utureost() lgorithm: * search (proposed by Hart/ Nilsson/ aphael, 968) Total cost of to = Pastost() + utureost() Uniform ost earch xplore states in order of Pastost() * earch xplore states in order of Pastost() + h() h() is a heuristic function which estimates utureost() ost (, ) = ost(, ) + h() where h() = d() - d() d(s) = rtificial Intelligence and its applications - ecture : earch 6 rtificial Intelligence and its applications - ecture : earch

Not consider here * earch d(s) = Uniform ost earch : ost (, ) = ost(, ) * earch d(s) = * : ost (, ) = ost(, ) + (d() -d()) ost h Total: ost - h - - d()-d() d()-d() d()-d() Total 7 rtificial Intelligence and its applications - ecture : earch 8 rtificial Intelligence and its applications - ecture : earch * earch * earch: Heuristic unction Uniform ost earch * h(s) determination is important If h(s) is incorrect, then * performs much worse than U If h(s) =, then * is same as U If h(s) = utureost(s), then * only explores nodes on a minimum cost path (optimal) esign of heuristics is domain dependence 9 rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch

* earch: Heuristic unction xample * earch: Heuristic unction xample Maze ame Maze ame How to find out a suitable heuristic function? onsidering obstacles causes Heuristic function very complicated et rid of constraints to make the problem easier rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : earch * earch: Heuristic unction xample ummary Maze ame earch rom start state to goal state onstraint atisfaction Problems onsider constraints h(s) = Manhattanistance(s, ndtate) where Manhattanistance((r, c ), (r, c )) = r - r + c - c e.g. h((, )) = 6 ifficulty ame Playing Markov ecision Processes onsider an adversary onsider an uncertainty einforcement earning No information is given rtificial Intelligence and its applications - ecture : earch rtificial Intelligence and its applications - ecture : ame Playing