Abstraction Transformation & Heuristics

Slides:



Advertisements
Similar presentations
BEST FIRST SEARCH - BeFS
Advertisements

Informed search algorithms
Informed Search Algorithms
Informed search algorithms
An Introduction to Artificial Intelligence
A* Search. 2 Tree search algorithms Basic idea: Exploration of state space by generating successors of already-explored states (a.k.a.~expanding states).
Problem Solving: Informed Search Algorithms Edmondo Trentin, DIISM.
Greedy best-first search Use the heuristic function to rank the nodes Search strategy –Expand node with lowest h-value Greedily trying to find the least-cost.
Solving Problem by Searching
CS344: Introduction to Artificial Intelligence Pushpak Bhattacharyya CSE Dept., IIT Bombay Lecture– 4, 5, 6: A* properties 9 th,10 th and 12 th January,
1 Heuristic Search Chapter 4. 2 Outline Heuristic function Greedy Best-first search Admissible heuristic and A* Properties of A* Algorithm IDA*
Informed Search (no corresponding text chapter). Recall: Wanted " An algorithm and associated data structure(s) that can: 1) Solve an arbitrary 8-puzzle.
Artificial Intelligence
Cooperating Intelligent Systems Informed search Chapter 4, AIMA.
Research Related to Real-Time Strategy Games Robert Holte November 8, 2002.
Properties of Heuristics that Guarantee A* Finds Optimal Paths Robert Holte this talk:
State-Space Searches.
Using Abstraction to Speed Up Search Robert Holte University of Ottawa.
Heuristic Search In addition to depth-first search, breadth-first search, bound depth-first search, and iterative deepening, we can also use informed or.
Computer Science CPSC 322 Lecture 9 (Ch , 3.7.6) Slide 1.
State-Space Searches. 2 State spaces A state space consists of A (possibly infinite) set of states The start state represents the initial problem Each.
CP Summer School Modelling for Constraint Programming Barbara Smith 2. Implied Constraints, Optimization, Dominance Rules.
Informed search algorithms Chapter 4. Best-first search Idea: use an evaluation function f(n) for each node –estimate of "desirability"  Expand most.
Informed search strategies Idea: give the algorithm “hints” about the desirability of different states – Use an evaluation function to rank nodes and select.
Review: Tree search Initialize the frontier using the starting state While the frontier is not empty – Choose a frontier node to expand according to search.
Heuristic Search Andrea Danyluk September 16, 2013.
Artificial Intelligence Problem solving by searching.
CS621: Artificial Intelligence Pushpak Bhattacharyya CSE Dept., IIT Bombay Lecture 3 - Search.
Informed Search and Heuristics Chapter 3.5~7. Outline Best-first search Greedy best-first search A * search Heuristics.
Best-first search Idea: use an evaluation function f(n) for each node –estimate of "desirability"  Expand most desirable unexpanded node Implementation:
Informed Search II CIS 391 Fall CIS Intro to AI 2 Outline PART I  Informed = use problem-specific knowledge  Best-first search and its variants.
A* optimality proof, cycle checking CPSC 322 – Search 5 Textbook § 3.6 and January 21, 2011 Taught by Mike Chiang.
Chapter 3.5 and 3.6 Heuristic Search Continued. Review:Learning Objectives Heuristic search strategies –Best-first search –A* algorithm Heuristic functions.
Heuristic Functions.
CPSC 420 – Artificial Intelligence Texas A & M University Lecture 5 Lecturer: Laurie webster II, M.S.S.E., M.S.E.e., M.S.BME, Ph.D., P.E.
Chapter 3 Solving problems by searching. Search We will consider the problem of designing goal-based agents in observable, deterministic, discrete, known.
Review: Tree search Initialize the frontier using the starting state
Heuristic Functions.
Heuristic Search A heuristic is a rule for choosing a branch in a state space search that will most likely lead to a problem solution Heuristics are used.
Heuristic Search Introduction to Artificial Intelligence
Artificial Intelligence Problem solving by searching CSC 361
Finding Heuristics Using Abstraction
The A* Algorithm Héctor Muñoz-Avila.
Discussion on Greedy Search and A*
Discussion on Greedy Search and A*
Crowd Simulation (INFOMCRWS) - A* Search
CS 4100 Artificial Intelligence
Informed search algorithms
Heuristic Search Thank you Michael L. Littman, Princeton University for sharing these slides.
Informed search algorithms
Artificial Intelligence
CS621: Artificial Intelligence
CSE 473 University of Washington
Workshop: A* Search.
HW 1: Warmup Missionaries and Cannibals
Informed Search Idea: be smart about what paths to try.
State-Space Searches.
Heuristic Search Generate and Test Hill Climbing Best First Search
State-Space Searches.
HW 1: Warmup Missionaries and Cannibals
CS621: Artificial Intelligence
Artificial Intelligence
CS 416 Artificial Intelligence
Midterm Review.
A Guaranteed Bidirectional Search
Reading: Chapter 4.5 HW#2 out today, due Oct 5th
State-Space Searches.
Informed Search Idea: be smart about what paths to try.
Informed Search.
Presentation transcript:

Abstraction Transformation & Heuristics Md Modasshir Sharmin Rahman

What we will cover Abstraction Transformation Valtorta's Theorem Hierarchical A*

Review Admissibility Consistency Solution Preserving Relaxed Problem Embedding Homomorphism

Admissibility A heuristic function is said to be admissible if it never overestimates the cost of reaching the goal. n is a node h is a heuristic h(n) is the cost indicated by h to reach a goal from n h*(n) is the actual cost to reach a goal from n h(n) is admissible if ∀𝑛, ℎ 𝑛 ≤ℎ∗(𝑛)

Consistency A consistent (or monotone) heuristic function is a function that estimates the distance of a given state to a goal state, and that is always at most equal to the estimated distance from any neighboring vertex plus the step cost of reaching that neighbor. ℎ is the consistent heuristic function 𝑁 is any node in the graph 𝑃 is any descendant of N 𝐺 is any goal node 𝑐(𝑁,𝑃) is the cost of reaching node P from N ℎ 𝑛 ≤𝑐 𝑁,𝑃 +ℎ 𝑝 𝑎𝑛𝑑 ℎ 𝐺 =0

Solution Preserving While transforming, keeping the existing solution path in the concrete problem is solution preserving

Relaxed problem A problem where constraints are dropped (e.g. removing constraints on puzzle problem) It means we can add new edges or merge existing nodes or both.

Embedding Embedding: Drop some preconditions from the operators (creates “supergraph”) – Preserves nodes, but creates extra edges

Homomorphism Homomorphism: Drop distinctions between objects – Reduces set of nodes, preserves edges

Abstraction Transformation

Definition: Abstraction Transformation An abstraction transformation ∅ :𝑆 →𝑆′ maps states u in the concrete problem space to abstract states ∅ 𝑢 and concrete actions a to abstract actions ∅ 𝑎 .

Heuristics Defined By Abstraction An abstraction of state space S is any state space such that : for every state 𝑠 ∈𝑆 there is a corresponding state ∅ 𝑠 ∈ ∅ 𝑆 . distance (∅ 𝑠 1 , ∅ 𝑠 2 ≤ distance 𝑠 1 , 𝑠 2 . Exact distances in ∅ 𝑆 are admissible and consistent heuristics for searching in S.

Definition: Embedding and Homomorphism An abstraction transformation ∅ is an embedding transformation if it adds edges to S such that the concrete and abstract state sets are the same; That is, ∅ 𝑢 =𝑢 for all 𝑢 ∈𝑆. Homomorphism requires that for all edges 𝑢,𝑣 in S, there must also be an edge ∅ 𝑢 , ∅ 𝑣 in S’.

Use of Abstract Spaces The solution in the abstract space can be used in 2 ways: The length of the abstract solution as a heuristic function ℎ 𝑛 The actual abstract plan as constraints for the concrete plan

Spurious Paths Introduces new path which does not exist in the concrete problem.

Theorem: Admissibility and Consistency of Abstraction Heuristics Let S be a state space and 𝑆′= ∅ 𝑆 be any homomorphic abstraction transformation of S. Let heuristic function ℎ ∅ 𝑢 for state u and goal t be defined as the length of the shortest path from ∅ 𝑢 and ∅ 𝑡 in S’. Then ℎ ∅ is an admissible consistent heuristic function.

Proof If 𝑝= 𝑢= 𝑢 1 ,…….., 𝑢 𝑡 =𝑡 is the shortest solution in S, ∅ 𝑢 1 ,………,∅ 𝑡 is a solution in S’, which cannot obviously be shorter than the optimal solution in S’. Heuristics h is consistent if for all u and u’ in S, ℎ 𝑢 ≤ 𝛿 𝑢, 𝑢 ′ +ℎ 𝑢 ′ If 𝛿 ∅ 𝑢,𝑡 is the shortest path between ∅ 𝑢 and ∅ 𝑡 , for all u and u’ 𝛿 ∅ 𝑢,𝑡 ≤ 𝛿 ∅ 𝑢, 𝑢 ′ + 𝛿 ∅ ( 𝑢 ′ ,𝑡) ⇒ ℎ ∅ 𝑢 ≤𝛿 𝑢, 𝑢 ′ + ℎ ∅ 𝑢 ′ 𝑆𝑖𝑛𝑐𝑒 𝛿 ∅ 𝑢, 𝑢 ′ ≤𝛿 𝑢, 𝑢 ′

Types of Abstraction based on State Representation Star Abstraction Domain Abstraction

Star Abstraction A method of grouping states together The state u with the largest degree is grouped together with its neighbors within a certain distance (the “abstraction radius”) to form a single abstract state. The range of an abstract state consists of all states reachable from u within the abstract radius.

Domain Abstraction Mapping of labels ∅:𝐿→𝐿′ Relabels all constants in both concrete states and actions Abstract space consists of all states reachable from ∅ 𝑠 by applying sequence of abstract action.

Example of Domain Abstraction First Abstraction ∅1: Tiles 1, 2 and 7 are replace by don’t care symbol x ∅1 𝑣 ={0, 3, 4, 5, 6, 8} Second Abstraction ∅2: Tiles 3 and 4 are mapped to y and 6 and 8 to z Allows refinements of Granularity of relaxation: how many constants in the concrete domain are mapped to each constant in the abstract domain Granularity of ∅2 is: 𝑥, 𝑦, 𝑧,0, 5 ={3, 2, 2, 1, 1}

Valtorta’s Theorem

Theorem Let u be any state necessarily expanded, when the problem 𝑠,𝑡 is solved in S with BFS: ∅ :𝑆 →𝑆′ be any abstraction mapping; and the heuristic estimate h 𝑢 be computed by blindly searching from ∅ 𝑢 to ∅ 𝑡 . If the problem is solved by the A* algorithm using h then either u itself will be expanded or ∅ 𝑢 will be expanded.

Proof If u is closed, it has already been expanded. If u is open, then ℎ ∅ 𝑢 is computed by searching in S’ starting at ∅ 𝑢 ; if ∅ 𝑢 ≠∅ 𝑡 , the first step in this auxiliary search is to expand ∅ 𝑢 ; otherwise, if ∅ 𝑢 =∅ 𝑡 , then ℎ ∅ 𝑢 =0, and u itself is necessarily expanded. if u is unvisited, on every path from s to u, there must be a state that was added to open during search but never expanded.

Proof (continued) Let v be any such state on the shortest path from s to u. be cause v was opened, ℎ ∅ 𝑣 must have been computed. We know that u is necessarily expanded by blind search, therefore, 𝛿 𝑠,𝑢 <𝛿 𝑠,𝑡 For v is in the shortest path, 𝛿 𝑠,𝑣 +𝛿 𝑣,𝑢 = 𝛿 𝑠,𝑢 < 𝛿(𝑠,𝑡) Since v was never expanded by A*, we get, 𝛿 𝑠,𝑣 + ℎ ∅ 𝑣 ≥ 𝛿(𝑠,𝑡) Combining the inequalities we get, 𝛿 𝑣,𝑢 < ℎ ∅ 𝑣 = 𝛿 (𝑣,𝑡) Since ∅ is an abstraction mapping, we know, 𝛿 ∅ 𝑣,𝑢 ≤ 𝛿 𝑣,𝑢 ⇒ 𝛿 ∅ 𝑣,𝑢 < 𝛿 ∅ (v,t) This proves that ∅(𝑢) is necessarily expanded.

Example of Valtorta’s Theorem

Hierarchical A*

Same Method, but applied differently Creates different level of abstraction transformation layers ∅ 1 , ∅ 2 , ……. Whenever a heuristic value for a node u in the base level problem is requested, the abstract problem to find a shortest path between ∅ 1 𝑢 and ∅ 1 𝑡 is solved on demand. The search at level 2 uses a heuristic computed on a third level as the shortest path between ∅ 2 ( ∅ 1 𝑢 ) and ∅ 2 ( ∅ 1 𝑡 ) and so on.

Layered abstraction in hierarchical A Layered abstraction in hierarchical A* with regard to current state u and goal state t

Pitfalls and Remedy There are overheads for repeatedly solving the same instances in the higher levels. Immediate solution is to cache the heuristic values of all the nodes in a shortest path computed at an abstract level.

Pitfalls and Remedy (Continued) The resulting heuristic will no longer be monotone. This leads to reopening nodes, they can be closed even if no shortest path is found. However, a node u can only be prematurely closed if every shortest path passes through same node v for which a shortest path is known. All nodes on the shortest path from v to t have already cached the exact estimate and hence will only be expanded once.

References Edelkamp, Stefan, and Stefan Schroedl. Heuristic search: theory and applications. Holte, Robert C., et al. "Hierarchical A*: Searching abstraction hierarchies efficiently." AAAI/IAAI, Vol. 1. 1996. Yang, Fan, et al. "A general theory of additive state space abstractions."Journal of Artificial Intelligence Research (2008): 631- 662.