beyond np revolution
play

Beyond NP Revolution Kuldeep S. Meel National University of - PowerPoint PPT Presentation

Beyond NP Revolution Kuldeep S. Meel National University of Singapore @Telekom ParisTech May 2019 1/47 Artificial Intelligence and Logic Turing, 1950: Opinions may vary as to the complexity which is suitable in the child machine. One


  1. Reliability of Critical Infrastructure Networks • G = ( V , E ); source node: s and terminal node t • failure probability g : E → [0 , 1] • Compute Pr[ s and t are disconnected]? • π : Configuration (of network) denoted by a 0 / 1 vector of size | E | • W ( π ) = Pr( π ) • π s , t : configuration where s and t are Figure: Plantersville, disconnected SC – Represented as a solution to set of constraints over edge variables 13/47

  2. Reliability of Critical Infrastructure Networks • G = ( V , E ); source node: s and terminal node t • failure probability g : E → [0 , 1] • Compute Pr[ s and t are disconnected]? • π : Configuration (of network) denoted by a 0 / 1 vector of size | E | • W ( π ) = Pr( π ) • π s , t : configuration where s and t are Figure: Plantersville, disconnected SC – Represented as a solution to set of constraints over edge variables • Pr[s and t are disconnected] = � π s , t W ( π s , t ) 13/47

  3. Reliability of Critical Infrastructure Networks • G = ( V , E ); source node: s and terminal node t • failure probability g : E → [0 , 1] • Compute Pr[ s and t are disconnected]? • π : Configuration (of network) denoted by a 0 / 1 vector of size | E | • W ( π ) = Pr( π ) • π s , t : configuration where s and t are Figure: Plantersville, disconnected SC – Represented as a solution to set of constraints over edge variables • Pr[s and t are disconnected] = � π s , t W ( π s , t ) Constrained Counting ( DMPV, AAAI 17, ICASP13 2019) 13/47

  4. Probabilistic Models Patient Cough Smoker Asthma Alice 1 0 0 Bob 0 0 1 Smoker ( S ) Asthma ( A ) Randee 1 0 0 Tova 1 1 1 Azucena 1 0 0 Georgine 1 1 0 Cough ( C ) Shoshana 1 0 1 Lina 0 0 1 Hermine 1 1 1 14/47

  5. Probabilistic Models Patient Cough Smoker Asthma Alice 1 0 0 Bob 0 0 1 Smoker ( S ) Asthma ( A ) Randee 1 0 0 Tova 1 1 1 Azucena 1 0 0 Georgine 1 1 0 Cough ( C ) Shoshana 1 0 1 Lina 0 0 1 Hermine 1 1 1 14/47

  6. Probabilistic Models Patient Cough Smoker Asthma Alice 1 0 0 Bob 0 0 1 Smoker ( S ) Asthma ( A ) Randee 1 0 0 Tova 1 1 1 Azucena 1 0 0 Georgine 1 1 0 Cough ( C ) Shoshana 1 0 1 Lina 0 0 1 Hermine 1 1 1 Pr[Asthma( A ) | Cough( C )] = Pr[ A ∩ C ] Pr[ C ] 14/47

  7. Probabilistic Models Patient Cough Smoker Asthma Alice 1 0 0 Bob 0 0 1 Smoker ( S ) Asthma ( A ) Randee 1 0 0 Tova 1 1 1 Azucena 1 0 0 Georgine 1 1 0 Cough ( C ) Shoshana 1 0 1 Lina 0 0 1 Hermine 1 1 1 Pr[Asthma( A ) | Cough( C )] = Pr[ A ∩ C ] Pr[ C ] F = A ∧ C 14/47

  8. Probabilistic Models Patient Cough Smoker Asthma Alice 1 0 0 Bob 0 0 1 Smoker ( S ) Asthma ( A ) Randee 1 0 0 Tova 1 1 1 Azucena 1 0 0 Georgine 1 1 0 Cough ( C ) Shoshana 1 0 1 Lina 0 0 1 Hermine 1 1 1 Pr[Asthma( A ) | Cough( C )] = Pr[ A ∩ C ] Pr[ C ] F = A ∧ C Sol( F ) = { ( A , C , S ) , ( A , C , ¯ S ) } 14/47

  9. Probabilistic Models Patient Cough Smoker Asthma Alice 1 0 0 Bob 0 0 1 Smoker ( S ) Asthma ( A ) Randee 1 0 0 Tova 1 1 1 Azucena 1 0 0 Georgine 1 1 0 Cough ( C ) Shoshana 1 0 1 Lina 0 0 1 Hermine 1 1 1 Pr[Asthma( A ) | Cough( C )] = Pr[ A ∩ C ] Pr[ C ] F = A ∧ C Sol( F ) = { ( A , C , S ) , ( A , C , ¯ S ) } Pr[ A ∩ C ] = Σ y ∈ Sol( F ) W ( y ) = W ( F ) Constrained Counting (Roth, 1996) 14/47

  10. Prior Work Strong guarantees but poor scalability • Exact counters (Birnbaum and Lozinskii 1999, Jr. and Schrag 1997, Sang et al. 2004, Thurley 2006, Lagniez and Marquis 2014-18) • Hashing-based approach (Stockmeyer 1983, Jerrum Valiant and Vazirani 1986) Weak guarantees but impressive scalability • Bounding counters (Gomes et al. 2007,Kroc, Sabharwal, and Selman 2008, Gomes, Sabharwal, and Selman 2006, Kroc, Sabharwal, and Selman 2008) • Sampling-based techniques (Wei and Selman 2005, Rubinstein 2012, Gogate and Dechter 2011) 15/47

  11. Prior Work Strong guarantees but poor scalability • Exact counters (Birnbaum and Lozinskii 1999, Jr. and Schrag 1997, Sang et al. 2004, Thurley 2006, Lagniez and Marquis 2014-18) • Hashing-based approach (Stockmeyer 1983, Jerrum Valiant and Vazirani 1986) Weak guarantees but impressive scalability • Bounding counters (Gomes et al. 2007,Kroc, Sabharwal, and Selman 2008, Gomes, Sabharwal, and Selman 2006, Kroc, Sabharwal, and Selman 2008) • Sampling-based techniques (Wei and Selman 2005, Rubinstein 2012, Gogate and Dechter 2011) How to bridge this gap between theory and practice? 15/47

  12. Constrained Counting • Given – Boolean variables X 1 , X 2 , · · · X n – Formula F over X 1 , X 2 , · · · X n – Weight Function W : { 0 , 1 } n �→ [0 , 1] • ExactCount( F , W ): Compute W ( F )? – #P-complete (Valiant 1979) 16/47

  13. Constrained Counting • Given – Boolean variables X 1 , X 2 , · · · X n – Formula F over X 1 , X 2 , · · · X n – Weight Function W : { 0 , 1 } n �→ [0 , 1] • ExactCount( F , W ): Compute W ( F )? – #P-complete (Valiant 1979) • ApproxCount( F , W , ε, δ ): Compute C such that Pr[ W ( F ) 1 + ε ≤ C ≤ W ( F )(1 + ε )] ≥ 1 − δ 16/47

  14. From Weighted to Unweighted Counting Boolean Formula F ′ Boolean Formula F and weight function W : { 0 , 1 } n → Q ≥ 0 W ( F ) = c ( W ) × | Sol( F ′ ) | • Key Idea: Encode weight function as a set of constraints 17/47

  15. From Weighted to Unweighted Counting Boolean Formula F ′ Boolean Formula F and weight function W : { 0 , 1 } n → Q ≥ 0 W ( F ) = c ( W ) × | Sol( F ′ ) | • Key Idea: Encode weight function as a set of constraints • Caveat: | F ′ | = O ( | F | + | W | ) ( CFMV, IJCAI15) 17/47

  16. From Weighted to Unweighted Counting Boolean Formula F ′ Boolean Formula F and weight function W : { 0 , 1 } n → Q ≥ 0 W ( F ) = c ( W ) × | Sol( F ′ ) | • Key Idea: Encode weight function as a set of constraints • Caveat: | F ′ | = O ( | F | + | W | ) ( CFMV, IJCAI15) How do we estimate | Sol( F ′ ) | ? 17/47

  17. Counting in Paris How many people in Paris like coffee? • Population of Paris = 2.1M • Assign every person a unique ( n =) 21 bit identifier (2 n = 2.1M) 18/47

  18. Counting in Paris How many people in Paris like coffee? • Population of Paris = 2.1M • Assign every person a unique ( n =) 21 bit identifier (2 n = 2.1M) • Attempt #1: Pick 50 people and count how many of them like coffee and multiple by 2.1M/50 18/47

  19. Counting in Paris How many people in Paris like coffee? • Population of Paris = 2.1M • Assign every person a unique ( n =) 21 bit identifier (2 n = 2.1M) • Attempt #1: Pick 50 people and count how many of them like coffee and multiple by 2.1M/50 – If only 5 people like coffee, it is unlikely that we will find anyone who likes coffee in our sample of 50 18/47

  20. Counting in Paris How many people in Paris like coffee? • Population of Paris = 2.1M • Assign every person a unique ( n =) 21 bit identifier (2 n = 2.1M) • Attempt #1: Pick 50 people and count how many of them like coffee and multiple by 2.1M/50 – If only 5 people like coffee, it is unlikely that we will find anyone who likes coffee in our sample of 50 • SAT Query: Find a person who likes coffee 18/47

  21. Counting in Paris How many people in Paris like coffee? • Population of Paris = 2.1M • Assign every person a unique ( n =) 21 bit identifier (2 n = 2.1M) • Attempt #1: Pick 50 people and count how many of them like coffee and multiple by 2.1M/50 – If only 5 people like coffee, it is unlikely that we will find anyone who likes coffee in our sample of 50 • SAT Query: Find a person who likes coffee • A SAT solver can answer queries like: – Q1: Find a person who likes coffee – Q2: Find a person who likes coffee and is not person y 18/47

  22. Counting in Paris How many people in Paris like coffee? • Population of Paris = 2.1M • Assign every person a unique ( n =) 21 bit identifier (2 n = 2.1M) • Attempt #1: Pick 50 people and count how many of them like coffee and multiple by 2.1M/50 – If only 5 people like coffee, it is unlikely that we will find anyone who likes coffee in our sample of 50 • SAT Query: Find a person who likes coffee • A SAT solver can answer queries like: – Q1: Find a person who likes coffee – Q2: Find a person who likes coffee and is not person y • Attempt #2: Enumerate every person who likes coffee 18/47

  23. Counting in Paris How many people in Paris like coffee? • Population of Paris = 2.1M • Assign every person a unique ( n =) 21 bit identifier (2 n = 2.1M) • Attempt #1: Pick 50 people and count how many of them like coffee and multiple by 2.1M/50 – If only 5 people like coffee, it is unlikely that we will find anyone who likes coffee in our sample of 50 • SAT Query: Find a person who likes coffee • A SAT solver can answer queries like: – Q1: Find a person who likes coffee – Q2: Find a person who likes coffee and is not person y • Attempt #2: Enumerate every person who likes coffee – Potentially 2 n queries Can we do with lesser # of SAT queries – O ( n ) or O (log n )? 18/47

  24. As Simple as Counting Dots 19/47

  25. As Simple as Counting Dots 19/47

  26. As Simple as Counting Dots Pick a random cell Estimate = Number of solutions in a cell × Number of cells 19/47

  27. Challenges Challenge 1 How to partition into roughly equal small cells of solutions without knowing the distribution of solutions? 20/47

  28. Challenges Challenge 1 How to partition into roughly equal small cells of solutions without knowing the distribution of solutions? Challenge 2 How many cells? 20/47

  29. Challenges Challenge 1 How to partition into roughly equal small cells of solutions without knowing the distribution of solutions? • Designing function h : assignments → cells (hashing) • Solutions in a cell α : Sol( F ) ∩ { y | h ( y ) = α } 20/47

  30. Challenges Challenge 1 How to partition into roughly equal small cells of solutions without knowing the distribution of solutions? • Designing function h : assignments → cells (hashing) • Solutions in a cell α : Sol( F ) ∩ { y | h ( y ) = α } • Deterministic h unlikely to work 20/47

  31. Challenges Challenge 1 How to partition into roughly equal small cells of solutions without knowing the distribution of solutions? • Designing function h : assignments → cells (hashing) • Solutions in a cell α : Sol( F ) ∩ { y | h ( y ) = α } • Deterministic h unlikely to work • Choose h randomly from a large family H of hash functions Universal Hashing (Carter and Wegman 1977) 20/47

  32. 2-Universal Hashing • Let H be family of 2-universal hash functions mapping { 0 , 1 } n to { 0 , 1 } m R ∀ y 1 , y 2 ∈ { 0 , 1 } n , α 1 , α 2 ∈ { 0 , 1 } m , h ← − H � 1 � Pr[ h ( y 1 ) = α 1 ] = Pr[ h ( y 2 ) = α 2 ] = 2 m � 1 � 2 Pr[ h ( y 1 ) = α 1 ∧ h ( y 2 ) = α 2 ] = 2 m 21/47

  33. 2-Universal Hashing • Let H be family of 2-universal hash functions mapping { 0 , 1 } n to { 0 , 1 } m R ∀ y 1 , y 2 ∈ { 0 , 1 } n , α 1 , α 2 ∈ { 0 , 1 } m , h ← − H � 1 � Pr[ h ( y 1 ) = α 1 ] = Pr[ h ( y 2 ) = α 2 ] = 2 m � 1 � 2 Pr[ h ( y 1 ) = α 1 ∧ h ( y 2 ) = α 2 ] = 2 m • The power of 2-universality – Z be the number of solutions in a randomly chosen cell – E[ Z ] = | Sol( F ) | 2 m – σ 2 [ Z ] ≤ E[ Z ] 21/47

  34. 2-Universal Hash Functions • Variables: X 1 , X 2 , · · · X n • To construct h : { 0 , 1 } n → { 0 , 1 } m , choose m random XORs • Pick every X i with prob. 1 2 and XOR them – X 1 ⊕ X 3 ⊕ X 6 · · · ⊕ X n − 2 – Expected size of each XOR: n 2 22/47

  35. 2-Universal Hash Functions • Variables: X 1 , X 2 , · · · X n • To construct h : { 0 , 1 } n → { 0 , 1 } m , choose m random XORs • Pick every X i with prob. 1 2 and XOR them – X 1 ⊕ X 3 ⊕ X 6 · · · ⊕ X n − 2 – Expected size of each XOR: n 2 • To choose α ∈ { 0 , 1 } m , set every XOR equation to 0 or 1 randomly X 1 ⊕ X 3 ⊕ X 6 · · · ⊕ X n − 2 = 0 ( Q 1 ) X 2 ⊕ X 5 ⊕ X 6 · · · ⊕ X n − 1 = 1 ( Q 2 ) ( · · · ) · · · X 1 ⊕ X 2 ⊕ X 5 · · · ⊕ X n − 2 = 1 ( Q m ) • Solutions in a cell: F ∧ Q 1 · · · ∧ Q m 22/47

  36. 2-Universal Hash Functions • Variables: X 1 , X 2 , · · · X n • To construct h : { 0 , 1 } n → { 0 , 1 } m , choose m random XORs • Pick every X i with prob. 1 2 and XOR them – X 1 ⊕ X 3 ⊕ X 6 · · · ⊕ X n − 2 – Expected size of each XOR: n 2 • To choose α ∈ { 0 , 1 } m , set every XOR equation to 0 or 1 randomly X 1 ⊕ X 3 ⊕ X 6 · · · ⊕ X n − 2 = 0 ( Q 1 ) X 2 ⊕ X 5 ⊕ X 6 · · · ⊕ X n − 1 = 1 ( Q 2 ) ( · · · ) · · · X 1 ⊕ X 2 ⊕ X 5 · · · ⊕ X n − 2 = 1 ( Q m ) • Solutions in a cell: F ∧ Q 1 · · · ∧ Q m • Performance of state of the art SAT solvers degrade with increase in the size of XORs (SAT Solvers != SAT oracles) 22/47

  37. Improved Universal Hash Functions • Not all variables are required to specify solution space of F – F := X 3 ⇐ ⇒ ( X 1 ∨ X 2 ) – X 1 and X 2 uniquely determines rest of the variables (i.e., X 3 ) • Formally: if I is independent support, then ∀ σ 1 , σ 2 ∈ Sol( F ), if σ 1 and σ 2 agree on I then σ 1 = σ 2 – { X 1 , X 2 } is independent support but { X 1 , X 3 } is not 23/47

  38. Improved Universal Hash Functions • Not all variables are required to specify solution space of F – F := X 3 ⇐ ⇒ ( X 1 ∨ X 2 ) – X 1 and X 2 uniquely determines rest of the variables (i.e., X 3 ) • Formally: if I is independent support, then ∀ σ 1 , σ 2 ∈ Sol( F ), if σ 1 and σ 2 agree on I then σ 1 = σ 2 – { X 1 , X 2 } is independent support but { X 1 , X 3 } is not • Random XORs need to be constructed only over I ( CMV DAC14) 23/47

  39. Improved Universal Hash Functions • Not all variables are required to specify solution space of F – F := X 3 ⇐ ⇒ ( X 1 ∨ X 2 ) – X 1 and X 2 uniquely determines rest of the variables (i.e., X 3 ) • Formally: if I is independent support, then ∀ σ 1 , σ 2 ∈ Sol( F ), if σ 1 and σ 2 agree on I then σ 1 = σ 2 – { X 1 , X 2 } is independent support but { X 1 , X 3 } is not • Random XORs need to be constructed only over I ( CMV DAC14) • Typically I is 1-2 orders of magnitude smaller than X • Auxiliary variables introduced during encoding phase are dependent (Tseitin 1968) 23/47

  40. Improved Universal Hash Functions • Not all variables are required to specify solution space of F – F := X 3 ⇐ ⇒ ( X 1 ∨ X 2 ) – X 1 and X 2 uniquely determines rest of the variables (i.e., X 3 ) • Formally: if I is independent support, then ∀ σ 1 , σ 2 ∈ Sol( F ), if σ 1 and σ 2 agree on I then σ 1 = σ 2 – { X 1 , X 2 } is independent support but { X 1 , X 3 } is not • Random XORs need to be constructed only over I ( CMV DAC14) • Typically I is 1-2 orders of magnitude smaller than X • Auxiliary variables introduced during encoding phase are dependent (Tseitin 1968) Algorithmic procedure to determine I ? 23/47

  41. Improved Universal Hash Functions • Not all variables are required to specify solution space of F – F := X 3 ⇐ ⇒ ( X 1 ∨ X 2 ) – X 1 and X 2 uniquely determines rest of the variables (i.e., X 3 ) • Formally: if I is independent support, then ∀ σ 1 , σ 2 ∈ Sol( F ), if σ 1 and σ 2 agree on I then σ 1 = σ 2 – { X 1 , X 2 } is independent support but { X 1 , X 3 } is not • Random XORs need to be constructed only over I ( CMV DAC14) • Typically I is 1-2 orders of magnitude smaller than X • Auxiliary variables introduced during encoding phase are dependent (Tseitin 1968) Algorithmic procedure to determine I ? • FP NP procedure via reduction to Minimal Unsatisfiable Subset 23/47

  42. Improved Universal Hash Functions • Not all variables are required to specify solution space of F – F := X 3 ⇐ ⇒ ( X 1 ∨ X 2 ) – X 1 and X 2 uniquely determines rest of the variables (i.e., X 3 ) • Formally: if I is independent support, then ∀ σ 1 , σ 2 ∈ Sol( F ), if σ 1 and σ 2 agree on I then σ 1 = σ 2 – { X 1 , X 2 } is independent support but { X 1 , X 3 } is not • Random XORs need to be constructed only over I ( CMV DAC14) • Typically I is 1-2 orders of magnitude smaller than X • Auxiliary variables introduced during encoding phase are dependent (Tseitin 1968) Algorithmic procedure to determine I ? • FP NP procedure via reduction to Minimal Unsatisfiable Subset • Two orders of magnitude runtime improvement ( IMMV CP15, Best Student Paper) ( IMMV Constraints16, Invited Paper) 23/47

  43. Challenges Challenge 1 How to partition into roughly equal small cells of solutions without knowing the distribution of solutions? • Independent Support-based 2-Universal Hash Functions Challenge 2 How many cells? 24/47

  44. Question 2: How many cells? ε ) 2 solutions • A cell is small if it has ≈ thresh = 5(1 + 1 25/47

  45. Question 2: How many cells? ε ) 2 solutions • A cell is small if it has ≈ thresh = 5(1 + 1 • We want to partition into 2 m ∗ cells such that 2 m ∗ = | Sol( F ) | thresh 25/47

  46. Question 2: How many cells? ε ) 2 solutions • A cell is small if it has ≈ thresh = 5(1 + 1 • We want to partition into 2 m ∗ cells such that 2 m ∗ = | Sol( F ) | thresh – Check for every m = 0 , 1 , · · · n if the number of solutions ≤ thresh 25/47

  47. ApproxMC( F , ε, δ ) # of sols ≤ thresh ? 26/47

  48. ApproxMC( F , ε, δ ) No # of sols # of sols ≤ thresh ? ≤ thresh ? 26/47

  49. ApproxMC( F , ε, δ ) No No # of sols # of sols ≤ thresh ? ≤ thresh ? 26/47

  50. ApproxMC( F , ε, δ ) No No # of sols # of sols ≤ thresh ? ≤ thresh ? # of sols ≤ thresh ? No · · · # of sols ≤ thresh ? 26/47

  51. ApproxMC( F , ε, δ ) No No # of sols # of sols ≤ thresh ? ≤ thresh ? # of sols ≤ thresh ? No Estimate = Yes # of sols × · · · # of cells # of sols ≤ thresh ? 26/47

  52. ApproxMC( F , ε, δ ) • We want to partition into 2 m ∗ cells such that 2 m ∗ = | Sol( F ) | thresh – Query 1: Is #( F ∧ Q 1 ) ≤ thresh – Query 2: Is #( F ∧ Q 1 ∧ Q 2 ) ≤ thresh – · · · – Query n : Is #( F ∧ Q 1 ∧ Q 2 · · · ∧ Q n ) ≤ thresh • Stop at the first m where Query m returns YES and return estimate as #( F ∧ Q 1 ∧ Q 2 · · · ∧ Q m ) × 2 m • Observation: #( F ∧ Q 1 · · · ∧ Q i ∧ Q i +1 ) ≤ #( F ∧ Q 1 · · · ∧ Q i ) – If Query i returns YES, then Query i + 1 must return YES 27/47

  53. ApproxMC( F , ε, δ ) • We want to partition into 2 m ∗ cells such that 2 m ∗ = | Sol( F ) | thresh – Query 1: Is #( F ∧ Q 1 ) ≤ thresh – Query 2: Is #( F ∧ Q 1 ∧ Q 2 ) ≤ thresh – · · · – Query n : Is #( F ∧ Q 1 ∧ Q 2 · · · ∧ Q n ) ≤ thresh • Stop at the first m where Query m returns YES and return estimate as #( F ∧ Q 1 ∧ Q 2 · · · ∧ Q m ) × 2 m • Observation: #( F ∧ Q 1 · · · ∧ Q i ∧ Q i +1 ) ≤ #( F ∧ Q 1 · · · ∧ Q i ) – If Query i returns YES, then Query i + 1 must return YES – Logarithmic search (# of SAT calls: O (log n )) 27/47

  54. ApproxMC( F , ε, δ ) • We want to partition into 2 m ∗ cells such that 2 m ∗ = | Sol( F ) | thresh – Query 1: Is #( F ∧ Q 1 ) ≤ thresh – Query 2: Is #( F ∧ Q 1 ∧ Q 2 ) ≤ thresh – · · · – Query n : Is #( F ∧ Q 1 ∧ Q 2 · · · ∧ Q n ) ≤ thresh • Stop at the first m where Query m returns YES and return estimate as #( F ∧ Q 1 ∧ Q 2 · · · ∧ Q m ) × 2 m • Observation: #( F ∧ Q 1 · · · ∧ Q i ∧ Q i +1 ) ≤ #( F ∧ Q 1 · · · ∧ Q i ) – If Query i returns YES, then Query i + 1 must return YES – Logarithmic search (# of SAT calls: O (log n )) ( CMV, IJCAI16) 27/47

  55. ApproxMC( F , ε, δ ) Theorem (Correctness) � � | Sol( F ) | Pr ≤ ApproxMC ( F , ε, δ ) ≤ | Sol( F ) | (1 + ε ) ≥ 1 − δ 1+ ε Theorem (Complexity) log n log( 1 δ ) ApproxMC ( F , ε, δ ) makes O ( ) calls to SAT oracle. ε 2 n log n log( 1 δ ) • Prior work required O ( ) calls to SAT oracle (Stockmeyer ε 1983) 28/47

  56. ApproxMC( F , ε, δ ) Theorem (Correctness) � � | Sol( F ) | Pr ≤ ApproxMC ( F , ε, δ ) ≤ | Sol( F ) | (1 + ε ) ≥ 1 − δ 1+ ε Theorem (Complexity) log n log( 1 δ ) ApproxMC ( F , ε, δ ) makes O ( ) calls to SAT oracle. ε 2 n log n log( 1 δ ) • Prior work required O ( ) calls to SAT oracle (Stockmeyer ε 1983) Theorem (FPRAS for DNF; (MSV, FSTTCS-17; CP-18, IJCAI-29( Invited Paper))) If F is a DNF formula, then ApproxMC is FPRAS – fundamentally different from the only other known FPRAS for DNF (Karp, Luby 1983) 28/47

  57. Reliability of Critical Infrastructure Networks 1 , 000 800 Time(seconds) 600 Figure: Plantersville, 400 SC 200 • G = ( V , E ); source node: s • Compute Pr[ t is 10 20 30 40 50 60 disconnected]? Terminal Timeout = 1000 seconds ( DMPV, AAAI17) 29/47

  58. Reliability of Critical Infrastructure Networks 1 , 000 RDA 800 Time(seconds) 600 Figure: Plantersville, 400 SC 200 • G = ( V , E ); source node: s • Compute Pr[ t is 10 20 30 40 50 60 disconnected]? Terminal Timeout = 1000 seconds ( DMPV, AAAI17) 29/47

  59. Reliability of Critical Infrastructure Networks 1 , 000 RDA ApproxMC 800 Time(seconds) 600 Figure: Plantersville, 400 SC 200 • G = ( V , E ); source node: s • Compute Pr[ t is 10 20 30 40 50 60 disconnected]? Terminal Timeout = 1000 seconds ( DMPV, AAAI17) 29/47

  60. Beyond Network Reliability (CFMSV, AAAI14), (IMMV, Probabilistic CP15), (CFMV, IJCAI15), (CMMV, Inference AAAI16), (CMV, IJCAI16) Quantified Information Flow Fremont, Rabe and Seshia 2017, BEHLM Q-18, Bang-2018 Network (DMPV, ApproxMC AAAI17) Reliability Deep Learning BMS 2019 Verification 30/47

  61. Network Reliability Constrained Counting Probabilistic Inference 31/47

  62. Hardware Validation • Design is simulated with test vectors (values of a and b ) • Results from simulation compared to intended results 32/47

  63. Hardware Validation • Design is simulated with test vectors (values of a and b ) • Results from simulation compared to intended results • Challenge: How do we generate test vectors? – 2 128 combinations for a toy circuit 32/47

  64. Hardware Validation • Design is simulated with test vectors (values of a and b ) • Results from simulation compared to intended results • Challenge: How do we generate test vectors? – 2 128 combinations for a toy circuit • Use constraints to represent interesting verification scenarios 32/47

  65. Constrained-Random Simulation Constraints • Designers: – a + 64 11 ∗ 32 b = 12 – a < 64 ( b >> 4) • Past Experience: – 40 < 64 34 + a < 64 5050 – 120 < 64 b < 64 230 • Users: – 232 ∗ 32 a + 64 b ! = 1100 – 1020 < 64 ( b / 64 2)+ 64 a < 64 2200 Test vectors : random solutions of con- straints 33/47

  66. Constrained Sampling • Given: – Set of Constraints F over variables X 1 , X 2 , · · · X n • Uniform Sampler 1 ∀ y ∈ Sol( F ) , Pr[y is output] = | Sol( F ) | • Almost-Uniform Sampler (1 + ε ) | Sol( F ) | ≤ Pr[y is output] ≤ (1 + ε ) 1 ∀ y ∈ Sol( F ) , | Sol( F ) | 34/47

  67. Prior Work Strong guarantees but poor scalability • Polynomial calls to NP oracle (Bellare, Goldreich and Petrank,2000) • BDD-based techniques (Yuan et al 1999, Yuan et al 2004, Kukula and Shiple 2000) • Reduction to approximate counting (Jerrum, Valiant and Vazirani 1986) Weak guarantees but impressive scalability • Randomization in SAT solvers (Moskewicz 2001, Nadel 2011) • MCMC-based approaches (Sinclair 1993, Jerrum and Sinclair 1996, Kitchen and Kuehlmann 2007,...) • Belief Networks (Dechter 2002, Gogate and Dechter 2006) 35/47

  68. Prior Work Strong guarantees but poor scalability • Polynomial calls to NP oracle (Bellare, Goldreich and Petrank,2000) • BDD-based techniques (Yuan et al 1999, Yuan et al 2004, Kukula and Shiple 2000) • Reduction to approximate counting (Jerrum, Valiant and Vazirani 1986) Weak guarantees but impressive scalability • Randomization in SAT solvers (Moskewicz 2001, Nadel 2011) • MCMC-based approaches (Sinclair 1993, Jerrum and Sinclair 1996, Kitchen and Kuehlmann 2007,...) • Belief Networks (Dechter 2002, Gogate and Dechter 2006) How to bridge this gap between theory and practice? 35/47

  69. Close Cousins: Counting and Sampling • Approximate counting and almost-uniform sampling are inter-reducible (Jerrum, Valiant and Vazirani, 1986) 36/47

  70. Close Cousins: Counting and Sampling • Approximate counting and almost-uniform sampling are inter-reducible (Jerrum, Valiant and Vazirani, 1986) • Is the reduction efficient? – Almost-uniform sampler (JVV) require linear number of approximate counting calls 36/47

  71. Key Ideas • Check if a randomly picked cell is small – If yes, pick a solution randomly from randomly picked cell 37/47

  72. Key Ideas • Check if a randomly picked cell is small – If yes, pick a solution randomly from randomly picked cell Challenge: How many cells? 37/47

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend