fprass for dnf counting
play

FPRASs for DNF-Counting Kuldeep S. Meel 1 , Aditya A. Shrotri 2 , - PowerPoint PPT Presentation

Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel 1 , Aditya A. Shrotri 2 , Moshe Y. Vardi 2 1 School of Computing, 2 Department of Computer Science, National University of Singapore Rice


  1. Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel 1 , Aditya A. Shrotri 2 , Moshe Y. Vardi 2 1 School of Computing, 2 Department of Computer Science, National University of Singapore Rice University Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 1

  2. Beyond SAT: #SAT • SAT: Does there exist a satisfying assignment? • #SAT: How many satisfying assignments ? • Complexity: #P-Complete (contains entire polynomial hierarchy) • In Practice: Harder than SAT Measuring Probabilistic Information Inference Leakage #SAT Network Probabilistic Reliability Databases Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 2

  3. The Disjunctive Normal Form • F = ¬𝑌 1 ∧ 𝑌 2 ∨ 𝑌 2 ∧ 𝑌 3 ∧ 𝑌 4 ∨ (𝑌 1 ∧ 𝑌 3 ∧ ¬𝑌 5 ) • Disjunction of Cubes • DNF-SAT is in P • #DNF is #P- Complete [Valiant, ’79] • Need to Approximate! Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 3

  4. Approximate DNF-Counting Input: DNF Formula F Tolerance ε 0 < ε < 1 Confidence δ 0 < δ < 1 Output: Approximate Count C s.t. Pr [# 𝐆 ⋅ (1- ε) < C < # 𝐆 ⋅ (1+ε) ] > 1 - δ Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 4

  5. Fully Polynomial Randomized Approximation Scheme Input: DNF Formula F Tolerance ε 0 < ε < 1 Confidence δ 0 < δ < 1 Output: Approximate Count C s.t. Pr [# 𝐆 ⋅ (1- ε) < C < # 𝐆 ⋅ (1+ε) ] > 1 - δ Challenge: Design a poly(m, n, 1 𝜗 , log( 1 𝜀 ) ) time algorithm where m = #cubes n = #vars Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 5

  6. Paradigms for #DNF FPRAS • Monte Carlo Sampling 𝟐 𝟐 • Best complexity: 𝑷(𝒏 ⋅ 𝒐 ⋅ 𝒎𝒑𝒉( 𝜺 ) ⋅ 𝜻 𝟑 ) • Hashing – based 𝟐 𝟐 • Best complexity: ෩ 𝑷(𝒏 ⋅ 𝒐 ⋅ 𝒎𝒑𝒉( 𝜺 ) ⋅ 𝜻 𝟑 ) Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 6

  7. Motivation Can hashing – based approach have same complexity as Monte 1. Carlo? How do the various algorithms compare empirically? 2. Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 7

  8. Our Contribution Can hashing – based approach have same complexity as Monte 1. Carlo? How do the various algorithms compare empirically? 2. In this work: • Improved complexity of hashing – based algorithm • Improves practical performance • First comprehensive empirical evaluation of FPRASs for #DNF • Much more nuanced than complexity analysis alone Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 8

  9. Method 1: Monte Carlo Sampling U • Draw independent samples from U F Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 9

  10. Method 1: Monte Carlo Sampling U U • Draw independent samples from U F F Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 10

  11. Method 1: Monte Carlo Sampling U U U • Draw independent samples from U • Count samples that satisfy F F F F Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 11

  12. Method 1: Monte Carlo Sampling U U U • Draw independent samples from U • Count samples that satisfy F F F F #• • #F ≈ #•+#• * |U| Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 12

  13. Method 1: Monte Carlo Sampling U U U • Draw independent samples from U • Count samples that satisfy F F F F #• • #F ≈ #•+#• * |U| #𝐺 • Requirement: 𝑉 is large • Solution density plays crucial role Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 13

  14. Monte Carlo FPRAS • KL Counter [Karp, Luby , ‘83] • Insight: Transform solution space 1 1 • KLM Counter [Karp et al., ‘89] 𝑃(𝑛 ⋅ 𝑜 ⋅ 𝑚𝑝𝑕( 𝜀 ) ⋅ 𝜁 2 ) • Insight: Sample using geometric distribution • Vazirani Counter [Vazirani , ’13] • Insight: Low variance ⟹ fewer samples Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 14

  15. Method 2: Hashing-Based • Partition U into small cells U U • Count solutions in a random cell ‘ C cell ’ F F • #F ≈ C cell * no. of cells On Hashing-Based Approaches to Approximate DNF Counting 9/5/2018 15

  16. Method 2: Hashing-Based • Partition U into small cells U U • Count solutions in a random cell ‘ C cell ‘ F F • #F ≈ C cell * no. of cells • Requirements: • Roughly equal solutions in each cell • Right size of cell On Hashing-Based Approaches to Approximate DNF Counting 9/5/2018 16

  17. Method 2: Hashing-Based • Requirement: Roughly Equal Solutions in each cell • Solution: Hash Functions • Conjunction of random XOR formulas • h = 𝐼 1 ∧ 𝐼 2 ∧ … ∧ 𝐼 𝑗 • h: 2 𝑜 → 2 𝑗 Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 17

  18. Method 2: Hashing-Based • Requirement: Right size cell • Solution: Count up to threshold 𝑈 • 𝑈 depends on 𝜁 and 𝜀 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 ⟹ cell too large • • Increase no. of constraints 𝑗 • Find 𝑗 such that 𝐷 𝑑𝑓𝑚𝑚 ≤ 𝑈 Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 18

  19. Forward Search • Requirement: Right size partition • Solution: Count up to threshold 𝑈 • Find 𝑗 such that 𝐷 𝑑𝑓𝑚𝑚 ≤ 𝑈 𝒋 0 𝑫 𝒅𝒇𝒎𝒎 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 Cell size Too large Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 19

  20. Forward Search • Requirement: Right size partition • Solution: Count up to threshold 𝑈 • Find 𝑗 such that 𝐷 𝑑𝑓𝑚𝑚 ≤ 𝑈 𝒋 0 1 𝑫 𝒅𝒇𝒎𝒎 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 Cell size Too large Too large Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 20

  21. Forward Search • Requirement: Right size partition • Solution: Count up to threshold 𝑈 • Find 𝑗 such that 𝐷 𝑑𝑓𝑚𝑚 ≤ 𝑈 𝒋 0 1 2 𝑫 𝒅𝒇𝒎𝒎 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 Cell size Too large Too large Too large Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 21

  22. Forward Search • Requirement: Right size partition • Solution: Count up to threshold 𝑈 • Find 𝑗 such that 𝐷 𝑑𝑓𝑚𝑚 ≤ 𝑈 𝒋 0 1 2 … 𝑚 − 1 𝑚 𝑫 𝒅𝒇𝒎𝒎 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 … 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 𝐷 𝑑𝑓𝑚𝑚 ≤ 𝑈 Cell size Too large Too large Too large … Too large Perfect • #F ≈ C cell * 2 𝑚 Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 22

  23. Hashing-Based FPRAS DNFApproxMC [Chakraborty et al., ‘16] 1. • Insight: Satisfiability of partitioned DNF formulas is polytime 𝜀 ) ⋅ 1 1 SymbolicDNFApproxMC [Meel et al., ‘17] ෨ 𝑃(𝑛 ⋅ 𝑜 ⋅ 𝑚𝑝𝑕( 𝜁 2 ) 2. • Insight: Symbolic hash constraints applied to transformed space Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 23

  24. Forward Search • Requirement: Right size partition • Solution: Count up to threshold 𝑈 • Find 𝑗 such that 𝐷 𝑑𝑓𝑚𝑚 ≤ 𝑈 𝒋 0 1 2 … 𝑚 − 1 𝑚 𝑫 𝒅𝒇𝒎𝒎 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 … 𝐷 𝑑𝑓𝑚𝑚 > 𝑈 𝐷 𝑑𝑓𝑚𝑚 ≤ 𝑈 Cell size Too large Too large Too large … Too large Perfect • #F ≈ C cell * 2 𝑚 Drawback: Re-enumerates solutions multiple times Not All FPRASs are Equal: Demystifying FPRASs for DNF-Counting Kuldeep S. Meel, Aditya A. Shrotri, Moshe Y. Vardi 9/5/2018 24

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