• Keine Ergebnisse gefunden

Planning and Optimization C4. Delete Relaxation: Relaxed Task Graphs Gabriele R¨oger and Thomas Keller

N/A
N/A
Protected

Academic year: 2022

Aktie "Planning and Optimization C4. Delete Relaxation: Relaxed Task Graphs Gabriele R¨oger and Thomas Keller"

Copied!
68
0
0

Wird geladen.... (Jetzt Volltext ansehen)

Volltext

(1)

Planning and Optimization

C4. Delete Relaxation: Relaxed Task Graphs

Gabriele R¨oger and Thomas Keller

Universit¨at Basel

October 22, 2018

(2)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Content of this Course: Heuristics

Heuristics

Delete Relaxation Relaxed Tasks Relaxed Task Graphs

Relaxation Heuristics Abstraction

Landmarks Potential Heuristics

(3)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Relaxed Task Graphs

(4)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Relaxed Task Graphs

Let Π+ be a relaxed planning task.

Therelaxed task graph of Π+, in symbolsRTG(Π+), is an AND/OR graph that encodes

which state variablescan become true in an applicable operator sequence for Π+, which operators of Π+ can be included in an applicable operator sequence for Π+, if the goalof Π+ can be reached,

andhow these things can be achieved.

(5)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Running Example

As a running example, consider the relaxed planning task hV,I,{o1,o2,o3,o4}, γiwith

V ={a,b,c,d,e,f,g,h}

I ={a7→T,b7→T,c 7→F,d 7→T, e 7→F,f 7→F,g 7→F,h7→F}

o1 =hc ∨(a∧b),c ∧((c∧d)Be),1i o2 =h>,f,2i

o3 =hf,g,1i o4 =hf,h,1i

γ =e∧(g∧h)

(6)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Construction

(7)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Components of Relaxed Task Graphs

A relaxed task graph has four kinds of components:

Variable node represent the state variables.

The initial noderepresent the initial state.

Operator subgraphs represent the preconditions and effects of operators.

The goal subgraphrepresents the goal.

The idea is to construct the graph in such a way that all nodes representingreachable aspects of the task areforced true.

(8)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Variable Nodes

Let Π+=hV,I,O+, γi be a relaxed planning task.

For eachv ∈V,RTG(Π+) contains an OR node nv. These nodes are called variable nodes.

(9)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Variable Nodes: Example

V ={a,b,c,d,e,f,g,h}

a b c d e f g h

I o1,> o1,cd

o2,>

o3,> o4,>

γ

(10)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Initial Node

Let Π+=hV,I,O+, γi be a relaxed planning task.

RTG(Π+) contains an AND node nI. This node is called the initial node.

For all v ∈V with I(v) =T,RTG(Π+) has an arc fromnv to nI. These arcs are called initial state arcs.

(11)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Initial Node and Initial State Arcs: Example

V ={a,b,c,d,e,f,g,h}

a b c d e f g h

I o1,> o1,cd

o2,>

o3,> o4,>

γ

(12)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Initial Node and Initial State Arcs: Example

I ={a7→T,b 7→T,c 7→F,d 7→T,e 7→F,f 7→F,g 7→F,h7→F}

o1,> o1,cd

o2,>

o3,> o4,>

γ

(13)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Operator Subgraphs

Let Π+=hV,I,O+, γi be a relaxed planning task.

For each operatoro+∈O+,RTG(Π+) contains anoperator subgraph with the following parts:

for each formulaϕthat occurs as a subformula of the precondition or of some effect condition of o+, a formula nodenϕ (details follow)

for each conditional effect (χBv) that occurs

in the effect of o+, an effect nodenχo+ (details follow);

unconditional effects are treated as (>Bv)

(14)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Formula Nodes

Formula nodesnϕ are defined as follows:

Ifϕ=v for some state variablev,nϕ is the variable nodenv (so no new node is introduced).

Ifϕ=>,nϕ is an AND node without outgoing arcs.

Ifϕ=⊥,nϕ is an OR node without outgoing arcs.

Ifϕ= (ϕ1∧ϕ2),nϕ is an AND node with outgoing arcs to nϕ1 andnϕ2. Ifϕ= (ϕ1∨ϕ2),nϕ is an OR node with outgoing arcs to nϕ1 andnϕ2.

(15)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Effect Nodes

Effect nodesnχo+ are defined as follows:

nχo+ is an AND node

It has an outgoing arc to the formula nodes npre(o+) (precondition arcs) andnχ (effect condition arcs).

Exception: if χ=>, there is no effect condition arc.

(This makes our pictures cleaner.)

For every conditional effect (χBv) in the operator, there is an arc from variable nodenv to nχo+ (effect arcs).

Note: identically named nodes are identical,

so if the same effect condition occurs multiple times in the same operator, this only inducesone node.

(16)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Operator Subgraphs: Example

o1,> o1,cd

o2,>

o3,> o4,>

γ

(17)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Operator Subgraphs: Example

o1 =hc ∨(a∧b),c ∧((c∧d)Be),1i

a b c d e f g h

I o1,> o1,cd

o2,>

o3,> o4,>

γ

(18)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Operator Subgraphs: Example

o2 =h>,f,2i

o1,> o1,cd

o2,>

o3,> o4,>

γ

(19)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Operator Subgraphs: Example

o3=hf,g,1i

a b c d e f g h

I o1,> o1,cd

o2,>

o3,>

o4,>

γ

(20)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Operator Subgraphs: Example

o4 =hf,h,1i

o1,> o1,cd

o2,>

o3,> o4,>

γ

(21)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Goal Subgraph

Let Π+=hV,I,O+, γi be a relaxed planning task.

RTG(Π+) contains a goal subgraph, consisting of formula nodes for the goalγ and its subformulas, constructed in the same way as formula nodes for preconditions and effect conditions.

(22)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Goal Subgraph and Final Relaxed Task Graph: Example

o1,> o1,cd

o2,>

o3,> o4,>

γ

(23)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Goal Subgraph and Final Relaxed Task Graph: Example

γ =e∧(g∧h)

a b c d e f g h

I o1,> o1,cd

o2,>

o3,> o4,>

γ

(24)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis

(25)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

How Can We Use Relaxed Task Graphs?

We are now done with the definition of relaxed task graphs.

Now we want to usethem to derive information about planning tasks.

In the following chapter, we will use them

to compute heuristics for delete-relaxed planning tasks.

Here, we start with something simpler: reachability analysis.

(26)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Forced True Nodes and Reachability

Theorem (Forced True Nodes vs. Reachability) LetΠ+=hV,I,O+, γi be a relaxed planning task, and let NT be the forced true nodes of RTG(Π+).

For allformulas over state variablesϕ that occur in the definition ofΠ+:

(27)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Forced True Nodes and Reachability: Consequences

Corollary

LetΠ+=hV,I,O+, γi be a relaxed planning task, and let NT be the forced true nodes of RTG(Π+). Then:

A state variablev ∈V is true in at least one reachable state iff nv ∈NT.

An operator o+∈O+ is part of at least one applicable operator sequence iff npre(o+)∈NT. The relaxed task is solvable iff nγ ∈NT.

(28)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T

f

T

g

T

h

T

T T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

T

(29)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T

f

T

g

T

h

T

I

T

T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

γ

T

(30)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T b

T

c

T

d

T

e

T

f

T

g

T

h

T

I T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

T

(31)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T c

T

d

T

e

T

f

T

g

T

h

T

I

T

T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

γ

T

(32)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T c

T d

T e

T

f

T

g

T

h

T

I T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

T

(33)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T c

T d

T e

T

f

T

g

T

h

T

I

T T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

γ

T

(34)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T c

T d

T e

T

f

T

g

T

h

T

I

T

T

T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

T

(35)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T c

T d

T e

T

f

T

g

T

h

T

I

T T

T

T o1,>

T o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

γ

T

(36)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T e

T

f

T

g

T

h

T

I

T

T

T o1,>

T o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

T

(37)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T e

T

f

T

g

T

h

T

I

T T

T T

o1,>

T o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

γ

T

(38)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T e

T

f

T

g

T

h

T

I

T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

T

(39)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T f

T

g

T

h

T

I

T T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

γ

T

(40)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T f

T

g

T

h

T

I

T

T T

o1,>

T

o1,cd

T

T o2,>

T

o3,>

T

o4,>

T

T

T

(41)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T f

T

g

T

h

T

I

T T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

γ

T

(42)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T

f

T g

T

h

T

I

T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

T

(43)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T

f

T g

T

h

T

I

T T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T o4,>

T

T

γ

T

(44)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T

f

T

g

T h

T

I

T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T o4,>

T

T

T

(45)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T

f

T

g

T h

T

I

T T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

γ

T

(46)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T

f

T

g

T

h

T

I

T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

T

(47)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T

f

T

g

T

h

T

I

T T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

T

γ

T

(48)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example

a

T

b

T

c

T

d

T

e

T

f

T

g

T

h

T

I

T

T T

o1,>

T

o1,cd

T

T

o2,>

T

o3,>

T

o4,>

T

γ

(49)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T

d e f

T

g

T

h

T

I

T T

T

o1,>

T

o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

γ

(50)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T

d e f

T

g

T

h

T

I T

T

o1,>

T

o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

(51)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T b

T

c

T

d e f

T

g

T

h

T

I

T

T

T

o1,>

T

o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

γ

(52)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T c

T

d e f

T

g

T

h

T

I T

T

o1,>

T

o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

(53)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T c

T

d e f

T

g

T

h

T

I

T T

T

o1,>

T

o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

γ

(54)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T c

T

d e f

T

g

T

h

T

I

T

T o1,>

T

o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

(55)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T c

T

d e f

T

g

T

h

T

I

T T

T

o1,>

T o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

γ

(56)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T d e f

T

g

T

h

T

I

T

T

o1,>

T o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

(57)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T d e f

T

g

T

h

T

I

T T

T

o1,>

T o1,cd

T o2,>

T

o3,>

T

o4,>

T

T

γ

(58)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T d e f

T

g

T

h

T

I

T

T

o1,>

T o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

(59)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T d e

f

T g

T

h

T

I

T T

T

o1,>

T o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

γ

(60)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T d e

f

T g

T

h

T

I

T

T

o1,>

T o1,cd

T

o2,>

T

o3,>

T o4,>

T

T

(61)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T d e

f

T

g

T h

T

I

T T

T

o1,>

T o1,cd

T

o2,>

T

o3,>

T o4,>

T

T

γ

(62)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T d e

f

T

g

T h

T

I

T

T

o1,>

T o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

(63)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T d e

f

T

g

T

h

T

I

T T

T

o1,>

T o1,cd

T

o2,>

T

o3,>

T

o4,>

T

T

γ

(64)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Reachability Analysis: Example with Different Initial State

a

T

b

T

c

T d e

f

T

g

T

h

T

I

T

T

o1,>

T o1,cd

T

o2,>

T

o3,>

T

o4,>

T

(65)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Remarks

(66)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Relaxed Task Graphs in the Literature

Some remarks on the planning literature:

Usually, only the STRIPScase is studied.

definitions simpler: only variable nodes andoperator nodes, no formula nodes or effect nodes

Usually, so-called relaxed planning graphs (RPGs) are studied instead of RTGs.

These are temporally unrolled versions of RTGs,

i.e., they have multiple layers (“time steps”) and are acyclic.

(67)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Summary

(68)

Relaxed Task Graphs Construction Reachability Analysis Remarks Summary

Summary

Relaxed task graphs(RTGs) represent (most of) the

information of a relaxed planning task as an AND/OR graph.

They consist of:

variable nodes an initial node

operator subgraphsincludingformula nodesandeffect nodes agoal subgraphincludingformula nodes

Referenzen

ÄHNLICHE DOKUMENTE

PDDL: Planning Domain Definition Language PDDL is the standard language used in practice to describe planning tasks. descriptions in (restricted) predicate logic instead

intuition: the closer h is to true cost to goal, the more efficient the search using h.. Heuristics A ∗ Search

Delete relaxation is a simplification in the sense that it is never harder to solve a relaxed task than the original one. Delete-relaxed tasks have a

C3.1 Optimal Relaxed Plans C3.2 AND/OR Graphs C3.3 Forced Nodes?. C3.4 Most/Least Conservative Valuations

If n is a node in an AND/OR graph that is forced true, then this can be derived by a sequence of applications of Rule T-(∧) and Rule

Coming up with good abstractions automatically is the main research challenge when applying abstraction heuristics

Formally, pattern database heuristics are abstraction heuristics induced by a particular class of abstractions called projections.

The objective value of an integer program that minimizes this cost subject to the flow constraints is a lower bound on the plan cost (i.e., an admissible heuristic estimate)..