Presentation is loading. Please wait.

Presentation is loading. Please wait.

A. Darwiche Inference in Bayesian Networks. A. Darwiche Query Types Pr: –Evidence: Pr(e) –Posterior marginals: Pr(x|e) for every X MPE: Most probable.

Similar presentations


Presentation on theme: "A. Darwiche Inference in Bayesian Networks. A. Darwiche Query Types Pr: –Evidence: Pr(e) –Posterior marginals: Pr(x|e) for every X MPE: Most probable."— Presentation transcript:

1 A. Darwiche Inference in Bayesian Networks

2 A. Darwiche Query Types Pr: –Evidence: Pr(e) –Posterior marginals: Pr(x|e) for every X MPE: Most probable instantiation: –Instantiation y such that Pr(y|e) is maximal (Y = E) MAP: Maximum a posteriori hypothesis: –Intantiation y such that Pr(y|e) is maximal (Y is subset of E)

3 A. Darwiche Pr: Posterior Marginals Battery Age Alternator Fan Belt Battery Charge Delivered Battery Power Starter Radio LightsEngine Turn Over Gas Gauge Gas Fuel Pump Fuel Line Distributor Spark Plugs Engine Start

4 A. Darwiche Diagnosis Scenario Battery Age Alternator Fan Belt Battery Charge Delivered Battery Power Starter Radio LightsEngine Turn Over Gas Gauge Gas Fuel Pump Fuel Line Distributor Spark Plugs Engine Start okonyesno.001 okoffyesno.090

5 A. Darwiche Battery Age Alternator Fan Belt Battery Charge Delivered Battery Power Starter Radio LightsEngine Turn Over Gas Gauge Gas Fuel Pump Fuel Line Distributor Spark Plugs Engine Start MPE: Most Probable Explanation

6 A. Darwiche Battery Age Alternator Fan Belt Battery Charge Delivered Battery Power Starter Radio LightsEngine Turn Over Gas Gauge Gas Fuel Pump Fuel Line Distributor Spark Plugs Engine Start MPE: Most Probable Explanation

7 A. Darwiche MAP: Maximum a Posteriori Hypothesis Battery Age Alternator Fan Belt Battery Charge Delivered Battery Power Starter Radio LightsEngine Turn Over Gas Gauge Gas Fuel Pump Fuel Line Distributor Spark Plugs Engine Start

8 A. Darwiche MAP: Maximum a Posteriori Hypothesis Battery Age Alternator Fan Belt Battery Charge Delivered Battery Power Starter Radio LightsEngine Turn Over Gas Gauge Gas Fuel Pump Fuel Line Distributor Spark Plugs Engine Start

9 A. Darwiche Battery Age Alternator Fan Belt Battery Charge Delivered Battery Power Starter Radio LightsEngine Turn Over Gas Gauge Gas Fuel Pump Fuel Line Distributor Spark Plugs Engine Start MAP: Maximum a Posteriori Hypothesis

10 A. Darwiche Probability of Evidence

11 A. Darwiche false A B true false A.3.7 ØAØA BA.1true.9truefalse ØBØB.2false.8falsetrue ** ** λ ~b λ ~a λbλb λaλa + ++ ** * *.3.1.9.8.2.7 Factoring

12 A. Darwiche Notation A binary variable X: –is variable with two values (true, false) –x is short notation for X=true –~x is short notation for X=false If X is a variable with parents Y and Z, then: represents the probability Pr(X=x | Y=y, Z=y) If X is a binary variable with parents Y and Z (also binary), then: represents the probability Pr(X=true | Y=false, Z=true)

13 A. Darwiche Notation An instantiation is a set of variables with their values: –X=true,Y=false, Z=true is an instantiation –A=a, B=b, C=c is an instantiation x, ~y, z is short notation for the instantiation X=true, Y=false, Z=true a,b,c is short notation for the instantiation A=a, B=b, C=c Two instantiations are inconsistent iff they assign different values to the same variable: –x,~y,z and x,y,z are inconsistent –x,~y,z and a,b,c are consistent

14 A. Darwiche Pr(a) =.03+.27 =.3 Joint Probability Distribution false B.03.27 A.56.14 true false Pr false true

15 A. Darwiche Pr(~b) =.27+.14 =.41 false B.03.27 A.56.14 true false Pr false true Joint Probability Distribution

16 A. Darwiche F =.03λ a λ b +.27λ a λ ~b +.56λ ~a λ b +.14λ ~a λ ~b false B.03 A true false Pr false true.27.14.56 λ a λ b.03 λ a λ ~ b.27 λ ~ a λ b.56 λ ~ a λ ~ b.14 λ a λ b …are called evidence indicators F is called the polynomial of the given probability distribution Evidence Indicators

17 A. Darwiche Computing Probabilities To compute the probability of instantiation e: Evaluate polynomial F while replacing each indicator -by 1 if the instantiation is consistent with the indicator; -by 0 if the instantiation is inconsistent with the indicator Examples: –Indicator λ a is consistent with instantiation a,~b,c –Indicator λ b is inconsistent with instantiation a,~b,c –Indicator λ d is consistent with instantiation a,~b,c –Indicator λ ~d is consistent with instantiation a,~b,c

18 A. Darwiche F =.03λ a λ b +.27λ a λ ~b +.56λ ~a λ b +.14λ ~a λ ~b Computing Probabilities To compute the probability of instantiation a, ~b: F(a,~b) =.03*1*0 +.27*1*1 +.56*0*0 +.14*0*1 =.27 To compute the probability of instantiation ~a: F(~a) =.03*0*1 +.27*0*1 +.56*1*1 +.14*1*1 =.70

19 A. Darwiche A B true false A.3.7 ØAØA BA.1true.9truefalse ØBØB.2false.8falsetrue false BA true false Pr false true.03=.3*.1.27=.3*.9 56=.7*.8.14=.7*.2

20 A. Darwiche A B true false AØAØA BA true false ØBØB true θaθa θ ~a θ b|a θ ~b|a θ b|~a θ ~b|~a false BA true false Pr false true θ a θ b|a θ a θ ~b|a θ ~a θ b|~a θ ~a θ ~b|~a

21 A. Darwiche A B true false AØAØA BA true false ØBØB true θaθa θ ~a θ b|a θ ~b|a θ b|~a θ ~b|~a false BA true false Pr false true λ a λ b θ a θ b|a λ a λ ~ b θ a θ ~b|a λ ~ a λ b θ ~a θ b|~a λ ~ a λ ~ b θ ~a θ ~b|~a

22 A. Darwiche AB true false AØAØA BA true false ØBØB true θaθa θ ~a θ b|a θ ~b|a θ b|~a θ ~b|~a false BA true false Pr false true λ a λ b θ a θ b|a λ a λ ~ b θ a θ ~b|a λ ~ a λ b θ ~a θ b|~a λ ~ a λ ~ b θ ~a θ ~b|~a λ a λ b θ a θ b|a + λ a λ ~b θ a θ ~b|a + λ ~a λ b θ ~a θ b|~a + λ ~a λ ~b θ ~a θ ~b|~a

23 A. Darwiche A B true false A θaθa θ ~a ØAØA false B θ b|a θ ~b|a A θ b|~a θ ~b|~a true false ØBØB true λ a λ b θ a θ b|a + λ a λ ~b θ a θ ~b|a + λ ~a λ b θ ~a θ b|~a + λ ~a λ ~b θ ~a θ ~b|~a The Polynomial of a Bayesian Network

24 A. Darwiche F = λ a λ b λ c λ d θ a θ b|a θ c|a θ d|bc + λ a λ b λ c λ ~d θ a θ b|a θ c|a θ ~d|bc + …. A B C D The Polynomial of a Bayesian Network

25 A. Darwiche Arithmetic Circuit λ a λ b θ a θ b|a + λ a λ ~b θ a θ ~b|a + λ ~a λ b θ ~a θ b|~a + λ ~a λ ~b θ ~a θ ~b|~a + ** ** λ ~b λ ~a λbλb λaλa ++ ** * * θaθa θ ab θ a~b θ ~ab θ ~a~b θ ~a Factoring

26 A. Darwiche ** ** λ ~b λ ~a λbλb λaλa + ++ ** * * θaθa θ ab θ a~b θ ~ab θ ~a~b θ ~a 1 1 1 0.3.3.1.9.8.2 0.3 0 1 1 Arithmetic Circuit.3.1.9.8.2.7 Pr(a)

27 A. Darwiche false A B true false A.3.7 ØAØA BA.1true.9truefalse ØBØB.2false.8falsetrue ** ** λ ~b λ ~a λbλb λaλa + ++ ** * * θaθa θ b|a θ ~b|a θ b|~a θ ~b|~a θ ~a Factoring

28 A. Darwiche Factoring the Polynomial of a Bayesian Network S1S1 T S2S2 S3S3 SnSn …

29 A. Darwiche Primitive Platforms (embedded) Embedding Probabilistic Reasoning Systems Sophisticated Platform (desktop) compiler Eval A. Circuit

30 A. Darwiche TreeWidth (Measures connectivity of Networks) Higher treewidth

31 A. Darwiche TreeWidth (Measures connectivity of Networks) Singly-connected network (polytree) Multiply-connected networks

32 A. Darwiche Treewidth The treewidth of a polytree is m, where m is the maximum number of parents that any node If each node has at most one parent, the polytree is called a tree The treewidth of a tree is 1

33 A. Darwiche Treewidth NGiven a Bayesian network N with: –Number of nodes: n –Treewith: w NWe can generate an arithmetic circuit for N: –In O(n 2 w ) time –In O(n 2 w ) space It is easy to do inference on polytrees


Download ppt "A. Darwiche Inference in Bayesian Networks. A. Darwiche Query Types Pr: –Evidence: Pr(e) –Posterior marginals: Pr(x|e) for every X MPE: Most probable."

Similar presentations


Ads by Google