BAYESIAN BELIEF NETWORKS

Submitted by
KODAM SAI KUMAR, 213CS2157, M.Tech – IS,
Department of Computer Science and Engineering
NATIONAL INSTITUTE OF TECHNOLOGY, ROURKELA
Contents:
•
•
•
•
•
•

Why BAYESIAN BELIEF NETWORKS
Definition
Incremental Network Construction
Conditional Independence
Example
Advantages and Disadvantages
Why BAYESIAN BELIEF NETWORKS ?
To represent the probabilistic relationships
between different classes.
To avoid dependences between value of
attributes by joint conditional probability
distribution.
In Naive Bayes Classifier,
conditionally independent

attributes are
Bayesian Belief Network (BN) Definition:
BN are also known as Bayesian Networks, Belief Networks,
and Probabilistic Networks.
A BN is defined is defined by two parts, a directed acyclic
graph (DAG) and a set of conditional probability tables (CPT).
Nodes
Links

Variables
Dependency
A Formal Definition
A BN is a graph with the following properties
Nodes: Set of random variables.
Directed Links: The real meaning of a link from
node X to node Y is that X has a direct influence
on Y.
Each node has a CPT that quantifies the effects
that the parent have on the node.
The Graph has no directed cycles.
If an arc drawn from Y to Z, then Y is a parent
or immediate predecessor of Z, and Z is a
descendant of Y.

Y
Z

Fig: 1

Each variable is conditionally independent of
its nondescendants in the graph, given its
parents.
Incremental Network Construction:
1. Choose the set of relevant variables Xi that
describes the domain
2. Choose an ordering for the variables (very
important step)
3. While there are variable left
a) Pick a variable X and add a node for it
b) Set parent (X) to some minimal set of existing nodes
such that the conditional independence property is
satisfied.
c) Define the CPT for X
Conditional Independence:
P(X1,X2,…..Xn) = P(Xn/X n-1,X n-2,...,X1)P(Xn-1,X n-2,...,X1)
=P(Xn/Xn-1,Xn-2,...,X1)P(Xn-1/Xn-2,..,X1)….P(X2/X1)P(X1)
=
A BN represents Conditional Independence
P(Xn/X n-1,X n-2,...,X1) = P(Xn/Parents(X n))
Example:
Burglar Alarm at home
• Fairy reliable at detecting a Burglary.
• Responds at times of Earthquakes.

Two neighbors on hearing Alarm, calls police
• John always calls when he hears the alarm, but
sometimes confuses the telephone ringing with the
alarm and calls then too.
Mary likes loud music and sometimes misses the
alarm altogether.
P(B)=0.001

A simple BN:

P(E)=0.002

Barglary

Earthquake

B

A
T

0.95

F

0.95

F

T

0.29

F

F

0.001

0.90

F

T

T

P(J)

P(A)

T

Alarm

E

0.05
A
T

John Calls

P(M)
0.90

F
Fig: 2

0.05

Mary Calls
How to find P(Burglary / JohnCalls)...?
P(B / J) = P(J B) / P(J) -----------------------------------------------------------Eqn (1)
1. How to find P(J B) ?
P(J B) = P(J A B) + P(J A’ B)
= P(J / A B) P(A B) + P(J / A’ B) P(A’ B)

= P(J / A) P(A B) + P(J / A’) P(A’ B)
=(0.9)*P(A B) + (0.05)*P(A’ B) --------------------------------Eqn (2)
P(A B) = P(A B E) + P(A B E’)
=P(A / B E) P(B E) + P(A / B E’) P(B E’)
=P(A / B) P(B) P(E) + P(A / B) P(B) P(E’)
=(0.95) (0.001) (0.002) + (0.95) (0.001) (0.998)
=0.00095
P(A’ B) = P(A’ B E) + P(A’ B E’)
=P(A’ / B E) P(B E) + P(A’ / B E’) P(B E’)
=P(A’ / B) P(B) P(E) + P(A’ / B) P(B) P(E’)
=(0.05) (0.001) (0.002) + (0.05) (0.001) (0.998)
=0.00005
Substitute P(A B) & P(A’ B) values in Eqn (2)
P(J B)=(0.9)*(0.00095) + (0.05)*(0.00005)
P(J B)= 0.00086
2. How to find P(J) ?
P(J) = P(J A) + P(J A’)
= P(J / A) P(A) + P(J / A’) P(A’)
=(0.9) P(A) + P(0.05) P(A’) --------------------------------Eqn (3)
P(A)= P(A B E) + P(A B E’) + P(A B’ E) + P(A B’ E’)
= 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.95) P(B) P(E) + (0.95) P(B) P(E’) + (0.29) P(B’) P(E) + (0.001) P(B’) P(E’)
=(0.95)(0.001)(0.002)+(0.95)(0.001)(0.998)+(0.29)(0.999)(0.002)+(0.001)(0.998) (0.999)
= 0.0025

P(A) = 0.0025 P(A’) = 0.9975 Substitute these values in Eqn (3)
P(J) = (0.9) P(A) + P(0.05) P(A’)
= (0.9) (0.0025) + (0.05) (0.9975)
= 0.052125
P(J)= 0.052125

Substitute P(J B) and P(J) values in Eqn (1)
P(B / J) = P(J B) / P(J)
= (0.00086) / (0.052125)
P(B / J) = 0.016
Advantages and Disadvantages:
• It can readily handle incomplete data sets.
• It allow one to learn about causal relationships.
• It readily facilitate use of prior knowledge.
• It is more complex to construct the graph
CONCLUSION:
Bayesian networks provide a natural
representation for conditional independence.
QUERIES…???
THANK YOU…!!!

Bayes Belief Networks

  • 1.
    BAYESIAN BELIEF NETWORKS Submittedby KODAM SAI KUMAR, 213CS2157, M.Tech – IS, Department of Computer Science and Engineering NATIONAL INSTITUTE OF TECHNOLOGY, ROURKELA
  • 2.
    Contents: • • • • • • Why BAYESIAN BELIEFNETWORKS Definition Incremental Network Construction Conditional Independence Example Advantages and Disadvantages
  • 3.
    Why BAYESIAN BELIEFNETWORKS ? To represent the probabilistic relationships between different classes. To avoid dependences between value of attributes by joint conditional probability distribution. In Naive Bayes Classifier, conditionally independent attributes are
  • 4.
    Bayesian Belief Network(BN) Definition: BN are also known as Bayesian Networks, Belief Networks, and Probabilistic Networks. A BN is defined is defined by two parts, a directed acyclic graph (DAG) and a set of conditional probability tables (CPT). Nodes Links Variables Dependency
  • 5.
    A Formal Definition ABN is a graph with the following properties Nodes: Set of random variables. Directed Links: The real meaning of a link from node X to node Y is that X has a direct influence on Y. Each node has a CPT that quantifies the effects that the parent have on the node. The Graph has no directed cycles.
  • 6.
    If an arcdrawn from Y to Z, then Y is a parent or immediate predecessor of Z, and Z is a descendant of Y. Y Z Fig: 1 Each variable is conditionally independent of its nondescendants in the graph, given its parents.
  • 7.
    Incremental Network Construction: 1.Choose the set of relevant variables Xi that describes the domain 2. Choose an ordering for the variables (very important step) 3. While there are variable left a) Pick a variable X and add a node for it b) Set parent (X) to some minimal set of existing nodes such that the conditional independence property is satisfied. c) Define the CPT for X
  • 8.
    Conditional Independence: P(X1,X2,…..Xn) =P(Xn/X n-1,X n-2,...,X1)P(Xn-1,X n-2,...,X1) =P(Xn/Xn-1,Xn-2,...,X1)P(Xn-1/Xn-2,..,X1)….P(X2/X1)P(X1) = A BN represents Conditional Independence P(Xn/X n-1,X n-2,...,X1) = P(Xn/Parents(X n))
  • 9.
    Example: Burglar Alarm athome • Fairy reliable at detecting a Burglary. • Responds at times of Earthquakes. Two neighbors on hearing Alarm, calls police • John always calls when he hears the alarm, but sometimes confuses the telephone ringing with the alarm and calls then too. Mary likes loud music and sometimes misses the alarm altogether.
  • 10.
  • 11.
    How to findP(Burglary / JohnCalls)...? P(B / J) = P(J B) / P(J) -----------------------------------------------------------Eqn (1) 1. How to find P(J B) ? P(J B) = P(J A B) + P(J A’ B) = P(J / A B) P(A B) + P(J / A’ B) P(A’ B) = P(J / A) P(A B) + P(J / A’) P(A’ B) =(0.9)*P(A B) + (0.05)*P(A’ B) --------------------------------Eqn (2) P(A B) = P(A B E) + P(A B E’) =P(A / B E) P(B E) + P(A / B E’) P(B E’) =P(A / B) P(B) P(E) + P(A / B) P(B) P(E’) =(0.95) (0.001) (0.002) + (0.95) (0.001) (0.998) =0.00095 P(A’ B) = P(A’ B E) + P(A’ B E’) =P(A’ / B E) P(B E) + P(A’ / B E’) P(B E’) =P(A’ / B) P(B) P(E) + P(A’ / B) P(B) P(E’) =(0.05) (0.001) (0.002) + (0.05) (0.001) (0.998) =0.00005 Substitute P(A B) & P(A’ B) values in Eqn (2) P(J B)=(0.9)*(0.00095) + (0.05)*(0.00005) P(J B)= 0.00086
  • 12.
    2. How tofind P(J) ? P(J) = P(J A) + P(J A’) = P(J / A) P(A) + P(J / A’) P(A’) =(0.9) P(A) + P(0.05) P(A’) --------------------------------Eqn (3) P(A)= P(A B E) + P(A B E’) + P(A B’ E) + P(A B’ E’) = 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.95) P(B) P(E) + (0.95) P(B) P(E’) + (0.29) P(B’) P(E) + (0.001) P(B’) P(E’) =(0.95)(0.001)(0.002)+(0.95)(0.001)(0.998)+(0.29)(0.999)(0.002)+(0.001)(0.998) (0.999) = 0.0025 P(A) = 0.0025 P(A’) = 0.9975 Substitute these values in Eqn (3) P(J) = (0.9) P(A) + P(0.05) P(A’) = (0.9) (0.0025) + (0.05) (0.9975) = 0.052125 P(J)= 0.052125 Substitute P(J B) and P(J) values in Eqn (1) P(B / J) = P(J B) / P(J) = (0.00086) / (0.052125) P(B / J) = 0.016
  • 13.
    Advantages and Disadvantages: •It can readily handle incomplete data sets. • It allow one to learn about causal relationships. • It readily facilitate use of prior knowledge. • It is more complex to construct the graph
  • 14.
    CONCLUSION: Bayesian networks providea natural representation for conditional independence.
  • 15.
  • 16.