SlideShare a Scribd company logo
1 of 20
Bayesian Belief
Networks(BBN)
Dr L.Srinivasan
Associate Professor/CSE
Dr N.G.P IT
CS3491 –AI & ML
UNIT-2
01
BAYESIAN BELIEF NETWORKS
 Bayesian networks (BN) are probabilistic graphical models that are based
on directed acyclic graphs.
 They provide a tool to deal with two problems: uncertainty and
complexity.
 Hence, they provide a compact representation of joint probability
distributions using a combination of graph theory and probability theory.
 The graph structure specifies statistical dependencies among the
variables and the local probabilistic models specify how these variables
are combined.
2
BAYESIAN BELIEF NETWORKS
 The naive Bayes classifier makes significant use of the assumption that
the values of the attributes a1 . . .an are conditionally independent given
the target value v.
 This assumption dramatically reduces the complexity of learning the
target function
 A Bayesian belief network describes the probability distribution governing
a set of variables by specifying a set of conditional independence
assumptions along with a set of conditional probabilities
 Bayesian belief networks allow stating conditional independence
assumptions that apply to subsets of the variables
3
BAYESIAN BELIEF NETWORKS
 Consider an arbitrary set of random variables Y1 . . .Yn, where each variable Yi
can take on the set of possible values V(Yi).
 The joint space of the set of variables Y to be the cross product V(Y1) x V(Y2)
x. . . V(Yn).
 In other words, each item in the joint space corresponds to one of the possible
assignments of values to the tuple of variables (Y1 . . .Yn). The probability
distribution over this joint' space is called the joint probability distribution.
 The joint probability distribution specifies the probability for each of the
possible variable bindings for the tuple (Y1 . . .Yn).
 A Bayesian belief network describes the joint probability distribution for a
set of variables.
4
BAYESIAN BELIEF NETWORKS
 Let X, Y, and Z be three discrete-valued random variables.
 We say that X is conditionally independent of Y given Z if the probability
distribution governing X is independent of the value of Y given a value for Z;
that is , if
We say that the set of variables X1 . . . Xi is conditionally independent of the set of
variables Y1. . .Ym given the set of variables Z1 . . . Zn, if
5
BAYESIAN BELIEF NETWORKS
 The joint probability for any desired assignment of values(y1,. . . ,yn) to the
tuple of network variables(Y1. . .Yn) can be computed by the formula
 Where Parents(Yi) denotes the set of immediate predecessors of Yi in the
network.
 Note the values of P(yi | Parents(Yi)) are precisely the values stored in the
conditional probability table associated with node Yi.
6
BAYESIAN BELIEF NETWORKS
7
BAYESIAN BELIEF NETWORKS-Example
 You have a new burglar alarm installed at home.
 It is fairly reliable at detecting burglary, but also sometimes responds to minor
earthquakes.
 You have two neighbors, John and Merry , who promised to call you at work
when they hear the alarm.
 John always calls when he hears the alarm, but sometimes confuses
telephone ringing with the alarm and calls too.
 Merry likes loud music and sometimes misses the alarm.
 Given the evidence of who has or has not called, we would like to estimate the
probability of a burglary.
8
BAYESIAN BELIEF NETWORKS-Example
9
BAYESIAN BELIEF NETWORKS-Example
 In this case, probability of Alarm depends on Burglary, Earthquake
 If there is Burglary the alarm starts ringing
 If there is minor earthquake the alarm starts ringing
 john calls if there is an alarm
 marry calls if there is an alarm
10
BAYESIAN BELIEF NETWORKS-Example
Probability of individual events
 Having Burglary :P(B)=.001 Not Having Burglary : P(¬B) =1 - .001=.999
 Having Earthquake : P(E)=.001 Not Having Earthquake: P(¬E) =1 - .002=.998
 Probability of Alarm depends on Burglary, Earthquake
so formula is P(A|B,E)
11
B E P(A|B,E) P (¬A|B,E)
T T P(A|B,E) =0.95 P(¬A|B,E) 1 - 0.95 =0.05
T F P(A|B, ¬E) =0.94 P(¬A|B, ¬E) 1 - 0.94 =0.06
F T P(A|¬B, E) =0.29 P(¬A|¬B, E) 1 - 0.29 =0.71
F F P(A|¬B, ¬E) =0.001 P(¬A|¬B, ¬E) 1 - 0.001=0.999
BAYESIAN BELIEF NETWORKS-Example
Probability of individual events
12
A P(J|A) P(¬J|A)
T P(J|A) =0.90 P(¬J|A) 1 - 0.90 = 0.1
F P(J|¬A) =0.05 P(¬J|¬A) 1 - 0.05 = 0.95
A P (M|A) P(¬M|A)
T P(M|A) =0.70 P(¬M|A) 1 - 0.70 = 0.3
F P(M|¬A) =0.01 P(¬M|¬A) 1 - 0.01 = 0.99
BAYESIAN BELIEF NETWORKS-Example
What is the probability that the
alarm has sounded but neither
a burglary nor an earthquake
Has occurred, and both John and Merry call?
Ans:
Here we are given with all events
Solution:
P(J ^ M ^ A ^ ¬B ^ ¬E)= P(J |A) P(M |A) P(A |¬B, ¬E) P(¬B) P(¬E)
= 0.90× 0.70× 0.001× 0.999× 0.998
= 0.00062 (Joint Probability distribution when all events given to us)
13
BAYESIAN BELIEF NETWORKS-Example
What is the probability that John call?
Here we are given with only 1 event
Solution:
P(J)= P(J |A) P(A) + P(J |¬A) P(¬A)
Here P(J|A),P(J | ¬ A) are known
To calculate P(A) ->Depends on Burglary and
Earthquake, but no info abt Burg and alarm
So calculate all 4 possibilities
B-TRUE E-TRUE , B-TRUE E- FALSE
B-FALSE E-TRUE , B-FALSE E- FALSE
14
BAYESIAN BELIEF NETWORKS-Example
What is the probability that John call?
Here we are given with only 1 event
Solution:
P(J)= P(J |A) P(A) + P(J |¬A) P(¬A)
=P(J | A) {P(A | B, E)*P(B , E)+P( A |¬ B, E)*P(¬B , E)+
P(A | B, ¬E)*P( B, ¬ E)+P(A |¬ B , ¬ E)*P(¬B, ¬E)}
+P(J | ¬ A) {P(¬ A | B, E)*P(B , E)+P(¬ A |¬ B, E)
*P(¬B , E)+P(¬ A | B, ¬E)*P(B, ¬ E)+
P(¬ A |¬ B , ¬ E)*P(¬B, ¬E)}
=0.90 * { (.95* (.001*.002)) + (.29 *(.999 *.002)) +(.94*(.001*.998)) +(.001*(.999*.998))} +
0.05 *{(0.05 * (.001*.002)) + (.71*(.999 *.002)) +(.06 *(.001*.998)) +(.999 *(.999*.998))}
={0.90* 0.00252}+ {0.05* 0.9974} => 0.0521
15
BAYESIAN BELIEF NETWORKS-Example
 Suppose, we are given for the evidence variables E1,…,Em, their values
e1,…,em, and we want to predict whether the query variable X has the value x
or not.
 For this we compute and compare the following
Here P(x,e1,…..em) ->Specifies probability of all events
16
BAYESIAN BELIEF NETWORKS-Example
What is the probability that there is a burglary given that John and Merry calls(Some Evidence is
there)?
P(B | J, M) =∝ P(B) 𝐴 P (J | A) P (M | A)
𝐸 P (A | B, E) P(E)
Why 𝑨 -may/maynot be alarm
Why 𝐸 - may/maynot be earthquake
Why P(B) moved front instead of last-Bcoz we had to find
Whether burglary happened or not
Whenever writing Join probability distribution start from bottom
and whatever the value known keep it to the left
17
BAYESIAN BELIEF NETWORKS-Example
What is the probability that there is a burglary given that John and Merry calls(Some Evidence is
there)?
P(B | J, M) =∝ P(B) 𝐴 P (J | A) P (M | A) 𝐸 P (A | B, E) P(E)
= ∝ P(B) 𝐴 P (J | A) P (M | A) {P (A | B, E) P(E) + P (A | B, ¬ E) P(¬E) }
= ∝ P(B) [P (J | A) P (M | A) { P (A | B, E) P(E) + P (A | B, ¬ E) P(¬E) }
+ P (J | ¬ A) P (M | ¬ A) { P (¬ A | B, E) P(E) + P (¬ A | B, ¬ E) P(¬E) }]
= ∝ * .001 * (.9 * .7 *(.95 * .002 + .94 * .998) + 0.5 * .01 * (.05 * .002 +.71 *.998))
= ∝ * .00059
18
BAYESIAN BELIEF NETWORKS-Example
What is the probability that there is a burglary given that John and Merry calls(Some Evidence is
there)?
P(¬B | J, M) =∝ P(¬B) 𝐴 P (J | A) P (M | A) 𝐸 P (A | ¬B, E) P(E)
= ∝ P(¬B) 𝐴 P (J | A) P (M | A) {P (A | ¬B, E) P(E) + P (A | ¬B, ¬ E) P(¬E) }
= ∝ P(¬B) [P (J | A) P (M | A) { P (A | ¬B, E) P(E) + P (A | ¬B, ¬ E) P(¬E) }
+ P (J | ¬ A) P (M | ¬ A) { P (¬ A | ¬B, E) P(E) + P (¬ A | ¬B, ¬ E) P(¬E) }]
= ∝ * .999 * (.9 * .7 *(.29 * .002 + .001 * .998) + 0.5 * .01 * (.71 * .002 +.999 *.998))
= ∝ * .0015
19
BAYESIAN BELIEF NETWORKS-Example
What is the probability that there is a burglary given that John and Merry calls?
α = 1 = 1 =478.5
(P(B,J,M) + P(¬B,J,M) ) (.00059) + (.0015)
P(B|J,M) = α * P(B|J,M)
=478.5 * .00059
= 0.28
P(¬B|J,M) = α * P(¬B|J,M)
=478.5 * .0015
= 0.72 Here 0.72>0.28 Hence, we conclude no burglary 20

More Related Content

What's hot (20)

Naive bayes
Naive bayesNaive bayes
Naive bayes
 
Directed Acyclic Graph
Directed Acyclic Graph Directed Acyclic Graph
Directed Acyclic Graph
 
Multilayer perceptron
Multilayer perceptronMultilayer perceptron
Multilayer perceptron
 
The pseudocode
The pseudocodeThe pseudocode
The pseudocode
 
DIGITAL ELECTRONICS- Logic Gates
DIGITAL ELECTRONICS- Logic GatesDIGITAL ELECTRONICS- Logic Gates
DIGITAL ELECTRONICS- Logic Gates
 
Introdution and designing a learning system
Introdution and designing a learning systemIntrodution and designing a learning system
Introdution and designing a learning system
 
Ch08
Ch08Ch08
Ch08
 
Gradient descent method
Gradient descent methodGradient descent method
Gradient descent method
 
Python as a calculator
Python as a calculatorPython as a calculator
Python as a calculator
 
13 Boolean Algebra
13 Boolean Algebra13 Boolean Algebra
13 Boolean Algebra
 
Artificial Neural Network
Artificial Neural NetworkArtificial Neural Network
Artificial Neural Network
 
Introduction to java programming part 1
Introduction to java programming part 1Introduction to java programming part 1
Introduction to java programming part 1
 
Perceptron & Neural Networks
Perceptron & Neural NetworksPerceptron & Neural Networks
Perceptron & Neural Networks
 
Goal stack planning.ppt
Goal stack planning.pptGoal stack planning.ppt
Goal stack planning.ppt
 
Shift Registers
Shift RegistersShift Registers
Shift Registers
 
Strings in python
Strings in pythonStrings in python
Strings in python
 
Complexity theory
Complexity theory Complexity theory
Complexity theory
 
Looping (Computer programming and utilization)
Looping (Computer programming and utilization)Looping (Computer programming and utilization)
Looping (Computer programming and utilization)
 
Divide and conquer
Divide and conquerDivide and conquer
Divide and conquer
 
Method overloading
Method overloadingMethod overloading
Method overloading
 

Similar to CS3491-Unit-2 BBN.pptx

Basics of Probability Theory ; set definitions about the concepts
Basics of Probability Theory ; set definitions about the conceptsBasics of Probability Theory ; set definitions about the concepts
Basics of Probability Theory ; set definitions about the conceptsps6005tec
 
Unit IV UNCERTAINITY AND STATISTICAL REASONING in AI K.Sundar,AP/CSE,VEC
Unit IV UNCERTAINITY AND STATISTICAL REASONING in AI K.Sundar,AP/CSE,VECUnit IV UNCERTAINITY AND STATISTICAL REASONING in AI K.Sundar,AP/CSE,VEC
Unit IV UNCERTAINITY AND STATISTICAL REASONING in AI K.Sundar,AP/CSE,VECsundarKanagaraj1
 
Probability theory lecture about theory 1a.ppt
Probability theory lecture about theory 1a.pptProbability theory lecture about theory 1a.ppt
Probability theory lecture about theory 1a.pptsadafshahbaz7777
 
MATHS PRESENTATION OF STATISTICS AND PROBABILITY.pptx
MATHS PRESENTATION OF STATISTICS AND PROBABILITY.pptxMATHS PRESENTATION OF STATISTICS AND PROBABILITY.pptx
MATHS PRESENTATION OF STATISTICS AND PROBABILITY.pptxpavantech57
 
CISEA 2019: ABC consistency and convergence
CISEA 2019: ABC consistency and convergenceCISEA 2019: ABC consistency and convergence
CISEA 2019: ABC consistency and convergenceChristian Robert
 
Data mining assignment 2
Data mining assignment 2Data mining assignment 2
Data mining assignment 2BarryK88
 
Introduction to Discrete Probabilities with Scilab - Michaël Baudin, Consort...
Introduction to Discrete Probabilities with Scilab - Michaël Baudin, Consort...Introduction to Discrete Probabilities with Scilab - Michaël Baudin, Consort...
Introduction to Discrete Probabilities with Scilab - Michaël Baudin, Consort...Scilab
 
Monte Carlo in Montréal 2017
Monte Carlo in Montréal 2017Monte Carlo in Montréal 2017
Monte Carlo in Montréal 2017Christian Robert
 
STAB52 Lecture Notes (Week 2)
STAB52 Lecture Notes (Week 2)STAB52 Lecture Notes (Week 2)
STAB52 Lecture Notes (Week 2)Danny Cao
 
Tutorial on Belief Propagation in Bayesian Networks
Tutorial on Belief Propagation in Bayesian NetworksTutorial on Belief Propagation in Bayesian Networks
Tutorial on Belief Propagation in Bayesian NetworksAnmol Dwivedi
 
Jarrar.lecture notes.aai.2011s.ch9.fol.inference
Jarrar.lecture notes.aai.2011s.ch9.fol.inferenceJarrar.lecture notes.aai.2011s.ch9.fol.inference
Jarrar.lecture notes.aai.2011s.ch9.fol.inferencePalGov
 

Similar to CS3491-Unit-2 BBN.pptx (20)

Basics of Probability Theory ; set definitions about the concepts
Basics of Probability Theory ; set definitions about the conceptsBasics of Probability Theory ; set definitions about the concepts
Basics of Probability Theory ; set definitions about the concepts
 
Bayesnetwork
BayesnetworkBayesnetwork
Bayesnetwork
 
Unit IV UNCERTAINITY AND STATISTICAL REASONING in AI K.Sundar,AP/CSE,VEC
Unit IV UNCERTAINITY AND STATISTICAL REASONING in AI K.Sundar,AP/CSE,VECUnit IV UNCERTAINITY AND STATISTICAL REASONING in AI K.Sundar,AP/CSE,VEC
Unit IV UNCERTAINITY AND STATISTICAL REASONING in AI K.Sundar,AP/CSE,VEC
 
Probability theory lecture about theory 1a.ppt
Probability theory lecture about theory 1a.pptProbability theory lecture about theory 1a.ppt
Probability theory lecture about theory 1a.ppt
 
Bayesian statistics
Bayesian statisticsBayesian statistics
Bayesian statistics
 
MATHS PRESENTATION OF STATISTICS AND PROBABILITY.pptx
MATHS PRESENTATION OF STATISTICS AND PROBABILITY.pptxMATHS PRESENTATION OF STATISTICS AND PROBABILITY.pptx
MATHS PRESENTATION OF STATISTICS AND PROBABILITY.pptx
 
CISEA 2019: ABC consistency and convergence
CISEA 2019: ABC consistency and convergenceCISEA 2019: ABC consistency and convergence
CISEA 2019: ABC consistency and convergence
 
Data mining assignment 2
Data mining assignment 2Data mining assignment 2
Data mining assignment 2
 
Lemh1a1
Lemh1a1Lemh1a1
Lemh1a1
 
Lemh1a1
Lemh1a1Lemh1a1
Lemh1a1
 
Introduction to Discrete Probabilities with Scilab - Michaël Baudin, Consort...
Introduction to Discrete Probabilities with Scilab - Michaël Baudin, Consort...Introduction to Discrete Probabilities with Scilab - Michaël Baudin, Consort...
Introduction to Discrete Probabilities with Scilab - Michaël Baudin, Consort...
 
Bayes Belief Networks
Bayes Belief NetworksBayes Belief Networks
Bayes Belief Networks
 
Probability Homework Help
Probability Homework HelpProbability Homework Help
Probability Homework Help
 
Mcs 013 solve assignment
Mcs 013 solve assignmentMcs 013 solve assignment
Mcs 013 solve assignment
 
Monte Carlo in Montréal 2017
Monte Carlo in Montréal 2017Monte Carlo in Montréal 2017
Monte Carlo in Montréal 2017
 
STAB52 Lecture Notes (Week 2)
STAB52 Lecture Notes (Week 2)STAB52 Lecture Notes (Week 2)
STAB52 Lecture Notes (Week 2)
 
Dempster shafer theory
Dempster shafer theoryDempster shafer theory
Dempster shafer theory
 
Bayes network
Bayes networkBayes network
Bayes network
 
Tutorial on Belief Propagation in Bayesian Networks
Tutorial on Belief Propagation in Bayesian NetworksTutorial on Belief Propagation in Bayesian Networks
Tutorial on Belief Propagation in Bayesian Networks
 
Jarrar.lecture notes.aai.2011s.ch9.fol.inference
Jarrar.lecture notes.aai.2011s.ch9.fol.inferenceJarrar.lecture notes.aai.2011s.ch9.fol.inference
Jarrar.lecture notes.aai.2011s.ch9.fol.inference
 

Recently uploaded

Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur EscortsRussian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escortsranjana rawat
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performancesivaprakash250
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Dr.Costas Sachpazis
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...ranjana rawat
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...Call Girls in Nagpur High Profile
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college projectTonystark477637
 
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service NashikCall Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesPrabhanshu Chaturvedi
 
Online banking management system project.pdf
Online banking management system project.pdfOnline banking management system project.pdf
Online banking management system project.pdfKamal Acharya
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlysanyuktamishra911
 
Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxupamatechverse
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxAsutosh Ranjan
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduitsrknatarajan
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Call Girls in Nagpur High Profile
 

Recently uploaded (20)

Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur EscortsRussian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performance
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college project
 
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service NashikCall Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and Properties
 
Online banking management system project.pdf
Online banking management system project.pdfOnline banking management system project.pdf
Online banking management system project.pdf
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghly
 
Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptx
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptx
 
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and RoutesRoadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduits
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
 

CS3491-Unit-2 BBN.pptx

  • 1. Bayesian Belief Networks(BBN) Dr L.Srinivasan Associate Professor/CSE Dr N.G.P IT CS3491 –AI & ML UNIT-2 01
  • 2. BAYESIAN BELIEF NETWORKS  Bayesian networks (BN) are probabilistic graphical models that are based on directed acyclic graphs.  They provide a tool to deal with two problems: uncertainty and complexity.  Hence, they provide a compact representation of joint probability distributions using a combination of graph theory and probability theory.  The graph structure specifies statistical dependencies among the variables and the local probabilistic models specify how these variables are combined. 2
  • 3. BAYESIAN BELIEF NETWORKS  The naive Bayes classifier makes significant use of the assumption that the values of the attributes a1 . . .an are conditionally independent given the target value v.  This assumption dramatically reduces the complexity of learning the target function  A Bayesian belief network describes the probability distribution governing a set of variables by specifying a set of conditional independence assumptions along with a set of conditional probabilities  Bayesian belief networks allow stating conditional independence assumptions that apply to subsets of the variables 3
  • 4. BAYESIAN BELIEF NETWORKS  Consider an arbitrary set of random variables Y1 . . .Yn, where each variable Yi can take on the set of possible values V(Yi).  The joint space of the set of variables Y to be the cross product V(Y1) x V(Y2) x. . . V(Yn).  In other words, each item in the joint space corresponds to one of the possible assignments of values to the tuple of variables (Y1 . . .Yn). The probability distribution over this joint' space is called the joint probability distribution.  The joint probability distribution specifies the probability for each of the possible variable bindings for the tuple (Y1 . . .Yn).  A Bayesian belief network describes the joint probability distribution for a set of variables. 4
  • 5. BAYESIAN BELIEF NETWORKS  Let X, Y, and Z be three discrete-valued random variables.  We say that X is conditionally independent of Y given Z if the probability distribution governing X is independent of the value of Y given a value for Z; that is , if We say that the set of variables X1 . . . Xi is conditionally independent of the set of variables Y1. . .Ym given the set of variables Z1 . . . Zn, if 5
  • 6. BAYESIAN BELIEF NETWORKS  The joint probability for any desired assignment of values(y1,. . . ,yn) to the tuple of network variables(Y1. . .Yn) can be computed by the formula  Where Parents(Yi) denotes the set of immediate predecessors of Yi in the network.  Note the values of P(yi | Parents(Yi)) are precisely the values stored in the conditional probability table associated with node Yi. 6
  • 8. BAYESIAN BELIEF NETWORKS-Example  You have a new burglar alarm installed at home.  It is fairly reliable at detecting burglary, but also sometimes responds to minor earthquakes.  You have two neighbors, John and Merry , who promised to call you at work when they hear the alarm.  John always calls when he hears the alarm, but sometimes confuses telephone ringing with the alarm and calls too.  Merry likes loud music and sometimes misses the alarm.  Given the evidence of who has or has not called, we would like to estimate the probability of a burglary. 8
  • 10. BAYESIAN BELIEF NETWORKS-Example  In this case, probability of Alarm depends on Burglary, Earthquake  If there is Burglary the alarm starts ringing  If there is minor earthquake the alarm starts ringing  john calls if there is an alarm  marry calls if there is an alarm 10
  • 11. BAYESIAN BELIEF NETWORKS-Example Probability of individual events  Having Burglary :P(B)=.001 Not Having Burglary : P(¬B) =1 - .001=.999  Having Earthquake : P(E)=.001 Not Having Earthquake: P(¬E) =1 - .002=.998  Probability of Alarm depends on Burglary, Earthquake so formula is P(A|B,E) 11 B E P(A|B,E) P (¬A|B,E) T T P(A|B,E) =0.95 P(¬A|B,E) 1 - 0.95 =0.05 T F P(A|B, ¬E) =0.94 P(¬A|B, ¬E) 1 - 0.94 =0.06 F T P(A|¬B, E) =0.29 P(¬A|¬B, E) 1 - 0.29 =0.71 F F P(A|¬B, ¬E) =0.001 P(¬A|¬B, ¬E) 1 - 0.001=0.999
  • 12. BAYESIAN BELIEF NETWORKS-Example Probability of individual events 12 A P(J|A) P(¬J|A) T P(J|A) =0.90 P(¬J|A) 1 - 0.90 = 0.1 F P(J|¬A) =0.05 P(¬J|¬A) 1 - 0.05 = 0.95 A P (M|A) P(¬M|A) T P(M|A) =0.70 P(¬M|A) 1 - 0.70 = 0.3 F P(M|¬A) =0.01 P(¬M|¬A) 1 - 0.01 = 0.99
  • 13. BAYESIAN BELIEF NETWORKS-Example What is the probability that the alarm has sounded but neither a burglary nor an earthquake Has occurred, and both John and Merry call? Ans: Here we are given with all events Solution: P(J ^ M ^ A ^ ¬B ^ ¬E)= P(J |A) P(M |A) P(A |¬B, ¬E) P(¬B) P(¬E) = 0.90× 0.70× 0.001× 0.999× 0.998 = 0.00062 (Joint Probability distribution when all events given to us) 13
  • 14. BAYESIAN BELIEF NETWORKS-Example What is the probability that John call? Here we are given with only 1 event Solution: P(J)= P(J |A) P(A) + P(J |¬A) P(¬A) Here P(J|A),P(J | ¬ A) are known To calculate P(A) ->Depends on Burglary and Earthquake, but no info abt Burg and alarm So calculate all 4 possibilities B-TRUE E-TRUE , B-TRUE E- FALSE B-FALSE E-TRUE , B-FALSE E- FALSE 14
  • 15. BAYESIAN BELIEF NETWORKS-Example What is the probability that John call? Here we are given with only 1 event Solution: P(J)= P(J |A) P(A) + P(J |¬A) P(¬A) =P(J | A) {P(A | B, E)*P(B , E)+P( A |¬ B, E)*P(¬B , E)+ P(A | B, ¬E)*P( B, ¬ E)+P(A |¬ B , ¬ E)*P(¬B, ¬E)} +P(J | ¬ A) {P(¬ A | B, E)*P(B , E)+P(¬ A |¬ B, E) *P(¬B , E)+P(¬ A | B, ¬E)*P(B, ¬ E)+ P(¬ A |¬ B , ¬ E)*P(¬B, ¬E)} =0.90 * { (.95* (.001*.002)) + (.29 *(.999 *.002)) +(.94*(.001*.998)) +(.001*(.999*.998))} + 0.05 *{(0.05 * (.001*.002)) + (.71*(.999 *.002)) +(.06 *(.001*.998)) +(.999 *(.999*.998))} ={0.90* 0.00252}+ {0.05* 0.9974} => 0.0521 15
  • 16. BAYESIAN BELIEF NETWORKS-Example  Suppose, we are given for the evidence variables E1,…,Em, their values e1,…,em, and we want to predict whether the query variable X has the value x or not.  For this we compute and compare the following Here P(x,e1,…..em) ->Specifies probability of all events 16
  • 17. BAYESIAN BELIEF NETWORKS-Example What is the probability that there is a burglary given that John and Merry calls(Some Evidence is there)? P(B | J, M) =∝ P(B) 𝐴 P (J | A) P (M | A) 𝐸 P (A | B, E) P(E) Why 𝑨 -may/maynot be alarm Why 𝐸 - may/maynot be earthquake Why P(B) moved front instead of last-Bcoz we had to find Whether burglary happened or not Whenever writing Join probability distribution start from bottom and whatever the value known keep it to the left 17
  • 18. BAYESIAN BELIEF NETWORKS-Example What is the probability that there is a burglary given that John and Merry calls(Some Evidence is there)? P(B | J, M) =∝ P(B) 𝐴 P (J | A) P (M | A) 𝐸 P (A | B, E) P(E) = ∝ P(B) 𝐴 P (J | A) P (M | A) {P (A | B, E) P(E) + P (A | B, ¬ E) P(¬E) } = ∝ P(B) [P (J | A) P (M | A) { P (A | B, E) P(E) + P (A | B, ¬ E) P(¬E) } + P (J | ¬ A) P (M | ¬ A) { P (¬ A | B, E) P(E) + P (¬ A | B, ¬ E) P(¬E) }] = ∝ * .001 * (.9 * .7 *(.95 * .002 + .94 * .998) + 0.5 * .01 * (.05 * .002 +.71 *.998)) = ∝ * .00059 18
  • 19. BAYESIAN BELIEF NETWORKS-Example What is the probability that there is a burglary given that John and Merry calls(Some Evidence is there)? P(¬B | J, M) =∝ P(¬B) 𝐴 P (J | A) P (M | A) 𝐸 P (A | ¬B, E) P(E) = ∝ P(¬B) 𝐴 P (J | A) P (M | A) {P (A | ¬B, E) P(E) + P (A | ¬B, ¬ E) P(¬E) } = ∝ P(¬B) [P (J | A) P (M | A) { P (A | ¬B, E) P(E) + P (A | ¬B, ¬ E) P(¬E) } + P (J | ¬ A) P (M | ¬ A) { P (¬ A | ¬B, E) P(E) + P (¬ A | ¬B, ¬ E) P(¬E) }] = ∝ * .999 * (.9 * .7 *(.29 * .002 + .001 * .998) + 0.5 * .01 * (.71 * .002 +.999 *.998)) = ∝ * .0015 19
  • 20. BAYESIAN BELIEF NETWORKS-Example What is the probability that there is a burglary given that John and Merry calls? α = 1 = 1 =478.5 (P(B,J,M) + P(¬B,J,M) ) (.00059) + (.0015) P(B|J,M) = α * P(B|J,M) =478.5 * .00059 = 0.28 P(¬B|J,M) = α * P(¬B|J,M) =478.5 * .0015 = 0.72 Here 0.72>0.28 Hence, we conclude no burglary 20