Presentation is loading. Please wait.

Presentation is loading. Please wait.

M. HardojoFriday, February 14, 2003 Directional Consistency Dechter, Chapter 4 1.Section 4.4: Width vs. Local Consistency Width-1 problems: DAC Width-2.

Similar presentations


Presentation on theme: "M. HardojoFriday, February 14, 2003 Directional Consistency Dechter, Chapter 4 1.Section 4.4: Width vs. Local Consistency Width-1 problems: DAC Width-2."— Presentation transcript:

1 M. HardojoFriday, February 14, 2003 Directional Consistency Dechter, Chapter 4 1.Section 4.4: Width vs. Local Consistency Width-1 problems: DAC Width-2 problems: DAC & DPC (strong DPC) Width-i problems: strong DIC (i.e., i+1) 2.Section 4.5: Adaptive Consistency  Bucket Elimination Madeline Hardojo CSCE 990-06 Advanced Constraint Processing

2 M. HardojoFriday, February 14, 2003 4.4 Width vs. Local Consistency Goal: –backtrack-free (BT-free) search Approach: –link level of consistency with the shape of the graph sufficient to guarantee BT-free search Known result: –(width+1)  consistency level  BT-free Caveat: –Shape  width  consistency  adds constraints  changes shape  increases width  higher consistency Solution: –Don’t use width, use induced width

3 M. HardojoFriday, February 14, 2003 4.4.1 Trees: width=1 Fig 4.5  width = 1  Directional AC yields BT-free search Add constraint between x 2 and x 4  width =2  Directional AC no longer yields BT-free search Tree-structured binary CSP  (any) ordering w=1  AC  BT-free search Dechter: AC is an overkill, Directional AC is sufficient DAC achieved with Revise (node, one parent) Tree-structured binary CSP  (any) ordering w=1  DAC  BT-free search. Why?

4 M. HardojoFriday, February 14, 2003 Theorem 4.4.1: width-1 & DAC Given –a constraint tree T –d, an ordering with w=1 If T is directional AC relative to d, Then network is BT-free along d

5 M. HardojoFriday, February 14, 2003 Theorem 4.4.1: width-1 & DAC Proof: x 1,…, x i was instantiated consistently Want to instantiate x i+1 Since w = 1, x i+1 only has at most 1 parent that constrained x i+1, say x j Since x j is relatively arc-consistent to x i+1, x i+1 must have a support for x j. Provides consistent extension  BT-free

6 M. HardojoFriday, February 14, 2003 Algorithm: Tree Solving (Fig 4.11) Input: T = (X, D, C) Output: A BT-free network along an ordering d 1.Generate a width-1 ordering, d = x 1, …, x n 2.Let x p(i) denote the parent of x i, in the rooted ordered tree 3.For i = n to 1 do 4. Revise ((x p(i) ), x i ); 5. if the domain of x p(i) is empty, exit (no solution) 6.endfor

7 M. HardojoFriday, February 14, 2003 Interesting note Complexity of Tree Solving Algorithm is the same as the complexity of DAC (when induced width =1), i.e. O(nk 2 ) Achieving full arc-consistency in O(nk 2 ): –apply DAC relative to a width-1 order d, then –apply DAC relative to the reverse order of d Compare with: –AC-3 : O(nk 3 ) –AC-4 : O(nk 2 ), requires special data structures

8 M. HardojoFriday, February 14, 2003 Theorem 4.4.2: width-2 & DPC Given a network R  d, an ordering with w=2 If R is directional AC  directional PC relative to ordering d, Then network is BT-free along d

9 M. HardojoFriday, February 14, 2003 4.4.2 Solving width-2 problems Enforce directional PC using DPC algorithm (Fig. 4.8) Applying DPC may create an induced graph with a width > original width Even though we start with a graph of width-2, if the resulting graph after using DPC has width > 2, DPC no longer guarantees BT-free search

10 M. HardojoFriday, February 14, 2003 Induced width? How to find that a graph has an ordering with induced width = 2? Use MIW algorithm (Fig 4.3) –Selects node with smallest degree –Puts it last in ordering –Connects its parents  not in MW –Removes it from graph –Repeat… Max degree of node removed gives induced width of ordering

11 M. HardojoFriday, February 14, 2003 Theorem 4.4.3: Complexity of DPC Given: –A binary constraint network R –induced width (w*) = 2 R can be solved by DPC in linear time in the number of variables O(nk 3 )

12 M. HardojoFriday, February 14, 2003 Theorem 4.4.4: width-i & DIC(i+1) Given –a general network R –d, an ordering (necessarily w = i) If R is strong directional i+1-consistent to d, Then network is BT-free along d

13 M. HardojoFriday, February 14, 2003 Consistency as inference DAC, DPC, DIC are not complete inference procedures –Network can be inconsistent without us finding it, in general Dechter introduces: Adaptive Consistency –A general and complete procedure for inferring (network) consistency consistent network  solvable problem, guarantees the existence of a solution

14 M. HardojoFriday, February 14, 2003 4.5 Adaptive consistency: Motivation Goal: –Want to make any problem BT-free relative to a given variable ordering. –A complete inference algorithm Approach: Adaptive-consistency –ADC1 (Fig. 4.13) and –Adaptive-C (Fig. 4.14) ADC1 and Adaptive-C apply strong directional (i+1)-consistency and the resulting graph has is BT-free along the ordering d

15 M. HardojoFriday, February 14, 2003 Proposition 4.5.1 Given an ordering of induced width i 1.Adaptive consistency  strong directional (i+1) consistency 2.Resulting network has width bounded by i

16 M. HardojoFriday, February 14, 2003 Algorithm: Adaptive-Consistency (ADC1) Given a constraint network R and an ordering d Find the width i of the current node Establishes DIC depending on the width of the node at the time of processing Enforce i+1 consistency –May tighten constraints –May impose new constraints –We only need to test the consistency of past and current variables DIC i : adaptive directional AC

17 M. HardojoFriday, February 14, 2003 Algorithm: Adaptive-Consistency (Adaptive-C) Variable-elimination algorithm: –At each step: Revise(parents of x j, x j ) Solve one variable and all its related constraints Inferred constraint on all the rest of the variables in the scope –Solved = generate all partial solutions over the parents that can extend to x j –Bucket elimination: an alternative description of adaptive consistency

18 M. HardojoFriday, February 14, 2003 Bucket Elimination Use data-structure: buckets Bucket-elimination: –One bucket per variable –Given an ordering, put constraint of the variable that appears latest in its scope to the bucket –In the same bucket: all constraints that have the same latest variable in their scope –Process bucket in reverse order and record its solution as a new constraint

19 M. HardojoFriday, February 14, 2003 Processing a bucket Solving a subproblem and recording its solutions as a new constraint –Corresponds to Revise(parents of x j, x j ) Place the new constraint in the bucket of its latest variable

20 M. HardojoFriday, February 14, 2003 Algorithm: Adaptive-C Given an ordering d Generates buckets and fill them with the constraints Process buckets in reverse order of ordering –Generate the join of all the constraints in the bucket –Project in a way to exclude the variable of the bucket

21 M. HardojoFriday, February 14, 2003 Algorithm: Adaptive-C (Example) Figure 4.15 d 1 = (E, B, C, D, A) Step 1 –n = 5 (x 5 = A) – bucket A = R AD, R AB –n = 4 (x 4 = D) – bucket D = R DE –… –n = 1 (x 1 = E) – bucket E = empty

22 M. HardojoFriday, February 14, 2003 Algorithm: Adaptive-Consistency (AC) - Example Step 2 –n = 5 A = {A,B,D}\{A} = {B,D} R BD = {(1,1), (2,2)}  bucket D –n = 4 A = {B,D,E}\{D} = {B,E} R BE = {(1,2),(2,1)}  bucket B –n = 3 A = {B,E,C}\{C}= {B,E} R BE  bucket B

23 M. HardojoFriday, February 14, 2003 Algorithm: Adaptive-Consistency (AC) - Example –n = 2 A = {B,E}\{B} = {E} R E = {1,2}  bucket E Induced graph: Fig 4.17

24 M. HardojoFriday, February 14, 2003 Adaptive-C Constraints are generated in reverse order of of d A solution is generated, backtrack free, in the direction of the ordering d

25 M. HardojoFriday, February 14, 2003 Adaptive-C for w* Ordering with induced width (w*) = 1 (tree), Adaptive-C generates only unary constraints (i.e., updates domains) Ordering with w* = 2, Adaptive-C generates only binary constraints The number of constraints in a bucket is bounded by the number of parents of the corresponding variable (owner of the bucket), i.e., induced width

26 M. HardojoFriday, February 14, 2003 Theorem 4.5.2: Output of Adaptive-C Given: –A network R –An ordering d Adaptive-consistency determines the consistency of R R is consistent  E d (R) is a backtrack-free network along d

27 M. HardojoFriday, February 14, 2003 Theorem 4.5.4: Complexity of Adaptive-C Time complexity of Adaptive-Consistency: O(n. (2k) w*+1 ) Space complexity of Adaptive-Consistency: O(n. (k) w* ) n = number of variables k = domain size w* = induced-width given an ordering

28 M. HardojoFriday, February 14, 2003 Lesson of Chapter 4 A class of tractable problems based on the induced width w*-based tractability Adaptive-consistency transforms a network into an equivalent one from which every solution can be generated BT-free –Technique to generate a solution –Technique of problem compilation –Governed by induced-width, w*


Download ppt "M. HardojoFriday, February 14, 2003 Directional Consistency Dechter, Chapter 4 1.Section 4.4: Width vs. Local Consistency Width-1 problems: DAC Width-2."

Similar presentations


Ads by Google