1 / 34

Introduction

Introduction. Combining two frameworks AND/OR Search Spaces Multi-valued Decision Diagrams ( MDDs ) Both are more compact ways to represent problems. Their combination yields an even more compact representation. Decision Diagrams are known to allow online speed queries. OFFLINE. A. F. B.

adila
Download Presentation

Introduction

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introduction • Combining two frameworks • AND/OR Search Spaces • Multi-valued Decision Diagrams (MDDs) • Both are more compact ways to represent problems. • Their combination yields an even more compact representation. • Decision Diagrams are known to allow online speed queries.

  2. OFFLINE A F B C E D ONLINE Evaluate answer Polytime? Constant time? Introduction Query Compiled structure ONCE MANY

  3. A A A A A A A B B B B B B B B B B B B C C C C C C C C C C C C C C C C C 0 0 0 0 0 0 0 1 0 1 1 1 1 1 0 1 0 0 0 1 0 1 0 1 Decision tree OBDD [Bryant86] Ordered Binary Decision Diagram B = {0,1} f : B3→ B Table 1) Merge nodes with identical children Merge terminal nodes Simplify 2) Remove redundant nodes Ordering enables efficient operations

  4. A B B A C C A C C C C B D D B B B D D D D D D D D D D G G E E E G G E E E E E E E E E H F H F F F F F 0 0 0 0 1 1 1 1 G G H 0 1 AND Decision Diagrams f = (A ∨ E) ∧ (B ∨ F) ? f ∧ g = OBDD g = (C ∨G) ∧ (D ∨ H) f ∧ g = OBDD

  5. A 0 1 A B B 0 1 0 1 0 1 B B C 1 0 1 0 1 C 0 1 1 Minimal AND/OR graph Decision Diagram AOMDDs A Point dead-ends to terminal node “0” Point goods to terminal node “1” B C

  6. A A redundant A A 0 1 0 1 0 0 1 1 B B B B B B 0 1 0 1 0 1 0 0 1 1 0 1 C C C C 0 1 0 1 0 0 1 1 0 1 0 1 0 1 0 1 OBDD (pseudo tree is a chain) Removing Redundancy A Group OR node together with its AND children into a meta-node B C

  7. A D B B D D D A B 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 A 0 1 B B 0 0 1 1 C C 0 0 1 1 0 1 0 1 0 1 AOBDD A A A B B B C D D C = *

  8. B D D A B A 0 0 0 0 0 0 1 1 1 1 1 1 A 0 1 B B 0 0 1 1 A C B 0 1 D C Apply Operator A1B1 A1 B1 A1B1 = * A2B2 A4B6 A2B2 A2 B2 B6 A4B4 A4 B4 B7 0 1 0 1 A3B3 0 A3 A5 B3 B5

  9. B D D A B A 0 0 0 0 0 0 1 1 1 1 1 1 A 0 1 B B 0 0 1 1 A C B 0 1 D C Apply Operator A1 B1 A1B1 = * A4B6 A2B2 A2 B2 B6 A4 A4B4 B4 A4 B4 B7 0 1 0 1 0 A3 A5 B3 B5

  10. A B D D B A D 0 0 0 0 0 0 0 1 1 1 1 1 1 1 A 0 1 B B 0 0 1 1 A C C B 0 0 1 1 D C Apply Operator A1 B1 A1B1 = * A4B6 A2B2 A2 B2 B6 A4 B4 A4 B4 A4 B4 B7 0 1 0 1 0 1 A3 A5 B3 B5

  11. D B D D B A B A 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 A 0 1 B B 0 0 1 1 A C C B 0 0 1 1 D C Apply Operator A1 B1 A1B1 = * A4B6 A2B2 A4B6 A2 B2 B6 A4B4 A4B7 A4 B4 A4 B4 B7 0 1 0 1 0 1 A3 A5 B3 B5

  12. B B D D D B A D A 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 A 0 1 B B 0 0 1 1 A C C B 0 0 1 1 D C Apply Operator A1 B1 A1B1 = * A2B2 A4B6 A2 B2 B6 A4B7 A4 B4 A4 B4 B7 B7 0 1 0 1 0 1 A3 A5 B3 B5

  13. And/Or Multi-Valued Decision Diagrams • AOMDDs are: • AND/OR search graphs • canonical representations, given a pseudo tree • Defined by two rules: • All isomorphic subgraphs are merged • There are no redundant (meta) nodes

  14. A A D G B C B F C F A m7 E A H D E G H B primal graph pseudo tree B C F 0 1 m6 m6 m3 0 1 m3 D E G H A A B F 0 1 0 1 B C F C9 C5 0 1 0 1 0 1 m2 C m4 m1 m5 0 1 m1 m5 m4 G H m2 D E A A A C C B A B C C D D C B C F H E A C B C F F E C H B B F A H D G G G A D B G F H F B A D D A B C E F E H A A F B G H C G F B G F 0 1 0 1 0 1 0 1 0 1 0 1 F E H D 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 C8 E G D C1 C4 C6 C7 C2 F C3 0 1 H G (f ∨ h) ∧ (a∨!h) ∧ (a#b#g) ∧ (f ∨ g) ∧ (b ∨ f) ∧ (a ∨ e) ∧ (c ∨ e) ∧ (c#d) ∧ (b ∨ c) Example: m7

  15. A m7 B C F 0 1 m6 A 0 1 m3 D E G H 0 1 m7 B G B C C C H A F C B F F G H B A F B D C F C C D E F B A H B D F F E D C H G G 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 Example (continued)

  16. D G C B F A E A H B primal graph C F D E G H 0 1 C G F F C B G F H A B D C E H F D C 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 AOBDD vs. OBDD A B B C C C C D D D D D D E E E F F F F G G G G G A H H B C 1 0 D AOBDD 18 nonterminals 47 arcs OBDD 27 nonterminals 54 arcs E F G H

  17. [ ] A A f1(ABC) [A] B f2(ABD) B D f3(BDE) [AB] [AB] C D [BD] C E E A 0 1 B B 0 1 0 1 C D C D C D C D 8 8 2 2 2 5 2 5 8 1 8 0 8 6 8 6 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 E E E E E E E E 3 4 3 4 3 4 3 4 8 8 8 8 8 8 8 8 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 Constraint Optimization - AND/OR Tree

  18. [ ] A A f1(ABC) [A] B f2(ABD) B D f3(BDE) [AB] [AB] C D [BD] C E E A 0 1 B B 0 1 0 1 C D C D C D C D 8 8 2 2 2 5 2 5 8 1 8 0 8 6 8 6 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 E E E E 3 4 3 4 8 8 8 8 0 1 0 1 0 1 0 1 AND/OR Context Minimal Graph

  19. A 0 1 B 0 1 C C D 8 2 2 8 8 0 0 1 0 1 0 1 E E 3 4 8 8 0 1 0 1 AOMDD – Compilation by Search A A 0 1 B B B 0 1 0 1 C D C D C D C D C D 2 2 2 5 2 5 8 8 8 8 1 8 0 6 8 6 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 E E E E E 3 4 3 4 8 8 8 8 0 1 0 1 0 1 0 1 redundant 0 1

  20. A 0 1 B B 0 1 0 1 C D C D 2 2 2 5 8 0 8 6 0 1 0 1 0 1 0 1 E E E E 3 3 4 4 8 8 8 8 0 0 1 1 0 0 1 1 AOMDD – Compilation by Search A A 0 1 B B B 0 1 0 1 C D C D C D C D C D 2 2 2 5 2 5 8 8 8 8 1 8 0 6 8 6 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 E E E E E 3 4 3 4 8 8 8 8 0 1 0 1 0 1 0 1 isomorphic isomorphic isomorphic 0 1

  21. A 0 1 B B 0 1 0 1 C D D C D 2 2 5 2 5 8 0 6 8 6 0 1 0 1 0 1 0 1 0 1 E E 3 4 8 8 0 1 0 1 AOMDD – Compilation by Search A A 0 1 B B B 0 1 0 1 C D C D C D C D C D 2 2 2 5 2 5 8 8 8 8 1 8 0 6 8 6 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 E E E E E 3 4 3 4 8 8 8 8 0 1 0 1 0 1 0 1 isomorphic isomorphic 0 1

  22. A 0 1 B B 0 1 0 1 C D 2 2 8 0 0 1 0 1 E E 3 4 8 8 0 1 0 1 D 5 6 0 1 AOMDD – Compilation by Search A A 0 1 B B B 0 1 0 1 C D C D C D C D C D 2 2 2 5 2 5 8 8 8 8 1 8 0 6 8 6 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 E E E E E 3 4 3 4 8 8 8 8 0 1 0 1 0 1 0 1 redundant 0 1

  23. A A 0 0 1 1 B B 0 0 1 1 C C D D 2 2 2 2 8 8 0 0 0 0 1 1 0 0 1 1 E E E E 3 3 4 4 8 8 8 8 0 0 1 1 0 0 1 1 0 1 0 1 AOMDD for two best solutions D A=0 A=0 A=1 A=1 A=1 A=1 5 6 0 1 B=1 B=1 B=0 B=1 B=0 B=1 2 2 2 2 6 2 6 2 5 2 5 C=1 D=1 C=1 D=0 C=1 D=0 C=1 D=0 C=1 D=1 C=1 D=1 3 4 3 3 4 4 E=1 E=1 E=1 E=1 E=1 E=1 AOMDD for Constraint Optimization AOMDD for all solutions cost = 11 cost = 5 cost = 8 cost = 11 cost = 11 cost = 11

  24. Complexity of Compilation • The size of the AOMDD is O(n kw*) • The compilation time is also bounded by O(n kw*) • k = domain size • n = number of variables • w*= treewidth

  25. Semantic Treewidth • Given a network, there may exist a sparser equivalent network. • Challenges the idea of using induced width to measure the difficulty of the problem • AOMDD sizes are much smaller than the bound

  26. Semantic Treewidth • With respect to a pseudo tree, this is the smallest treewidth over all equivalent networks that can have that pseudo tree • With respect to the network, this is the smallest semantic treewidth over all pseudo trees that can express the set of solutions • Instead of the induced width bounding AOMDD size, we can use semantic treewidth.

  27. Semantic Treewidth Equality constraint network results

  28. Constraint Propagation • We can also prune the search space during compilation without removing possible solutions. • In Bayesian networks, prune a subtree if the weight of the assignment is 0.

  29. Experiments • What about the pseudo-tree height parameter? • Problems: WCSP instances • ISCAS 89 Circuits • SPOT5 Satellites • Mastermind • CELAR6 Radio Frequencies • Time bound for compilation: 3 hours

  30. Experiments • Compilation was for finding the optimal solution • Used AOBB with static mini-bucket heuristics (i-bound = 10) • Tried different implementations of MinFill • Existing implementation in the compiler • daoopt(gets lower h because it considers it too) • CVO

  31. Experiments • BnBpruning makes the size unpredictable as a function of the parameters • Need to modify the routine for solution counting so the entire AOMDD is actually compiled

  32. Experiments (BN) • Reproduce and extend BN results in JAIR 2008 paper • UAI 2006 Bayesian network benchmarks • Domain sizes of 2 • Evidence on 30 random variables (to simplify the networks slightly) • Many elements with “0” support • Compile with constraint propagation

  33. To do • Perform experiments to compare optimization vs. full compilation • Need to extend code for WCSPs • Another way to deal with unpredictability of w/h vs. size in optimization? • Compute many orderings with equal w/h and average the search space/AOMDD sizes.

  34. Future Work? • Try regressing curves that depend on w, h, or both • Evaluation of bottom-up version of compilation (Robert’s algorithm in CP 2006)

More Related