Bayesian Networks: Review Representation, independence, and inference (+ a few problems for your enjoyment) Stanislav Funiak 10-701 Recitation, 3/30/2006 3/30/2006 Bayesian Networks: Review.

Download Report

Transcript Bayesian Networks: Review Representation, independence, and inference (+ a few problems for your enjoyment) Stanislav Funiak 10-701 Recitation, 3/30/2006 3/30/2006 Bayesian Networks: Review.

Bayesian Networks: Review
Representation, independence, and inference
(+ a few problems for your enjoyment)
Stanislav Funiak
10-701 Recitation, 3/30/2006
3/30/2006
Bayesian Networks: Review
1
Conference Submission Network
Beer
Done
in Time
Sleep1
Quality
Comments1
Sleep2
Comments2
Recommended
Accepted
3/30/2006
Bayesian Networks: Review
2
Bayesian Network



DAG, each node is a variable
For each var. X, CPD p(X | Pa X)
represents the distribution as
B
D
T
S1
C1
A,B,D,T,Q,S1,S2,C1,C2,R
S2
Q
C2
R
A
3/30/2006
Bayesian Networks: Review
3
Smaller Network
S1
S1
Q
C1
p(S1)
Q
p(Q1)
t
0.4
t
0.8
f
0.6
f
0.2
t
f
t
0.5
0.3
f
0.5
0.7
C2
R
C1| S1
Q=t
t
f
A
Q=f
t
f
0.9
0.5
C1|0.1
C2 0.5
t
C2=t
R | C1
t
f
t
1
0.5
f
f
C2=f
t
0.6
0.1
f
0.4
0.9
p(S1=f, Q=t, C1=f, C2=t, R=t, A=t)
=
3/30/2006
C2 | Q
Bayesian Networks: Review
01
R\C
0.5
t
f
t
0.5
0
f
0.5
1
t
f
t
0.8
0.1
f
0.2
0.9
A|R
4
Independence Relations
… where the force lies
 example independencies

S1
Q
C1
C2
R
A
3/30/2006
Bayesian Networks: Review
5
Factorization => Independence relations

We have seen:


starting from: p factorizes according to G
show: p satisfies some independence relations
p factorizes
according to G

3/30/2006
p satisfies
indep. relations
in G
Which independence assumptions in G?
Bayesian Networks: Review
6
Independence relations encoded in G
1. Local Markov Assumptions:

B
D
X indep. NonDescendants(X) | Pa X
T
S1
S2
Q
C1
C2
R
A
3/30/2006
Bayesian Networks: Review
7
Independence relations encoded in G
2. absence of active trails

Variables X indep of variables Y
given Z if no active trail between
X and Y given Z
B
D
T
S1
S2
Q
C1
C2
R
A
3/30/2006
Bayesian Networks: Review
8
Active trail: Review

3/30/2006
A path X1 – X2 – · · · –Xk is an active trail when
variables Oµ{X1,…,Xn} are observed if for each
consecutive triplet in the trail:

Xi-1XiXi+1, and Xi is not observed (XiO)

Xi-1XiXi+1, and Xi is not observed (XiO)

Xi-1XiXi+1, and Xi is not observed (XiO)

Xi-1XiXi+1, and Xi is observed (Xi2O), or one of its
descendents
Bayesian Networks: Review
9
Independence relations encoded in G
2. absence of active trails

Variables X indep of variables Y
given Z if no active trail between
X and Y given Z
B
D
T
S1
S2
Q
C1
C2
R
A
3/30/2006
Bayesian Networks: Review
10
Independence relations encoded in G
1. Local Markov Assumptions
2. absence of active trails (d-separation)
3/30/2006
Bayesian Networks: Review
11
Independence relations => Factorization

Before:
p factorizes
according to G

How about:
p factorizes
according to G
3/30/2006
p satisfies
indep. relations
in G
p satisfies
indep. relations
in G
Bayesian Networks: Review
12
Independence relations => Factorization

Suppose
S1
Q
C1
C2
R

3/30/2006
Prove that p factorizes according to G
Bayesian Networks: Review
A
13
Queries

Marginal probability
Variable elimination

Most probable explanation (MPE)

Active data collection
3/30/2006
Bayesian Networks: Review
14
Conditioning on evidence
S1
S1
Q
C1
p(S1)
Q
p(Q1)
t
0.4
t
0.8
C2 | Q
Q
t
f
0.6
f
0.2
f
t
t
0.5
0.5
0.5
C2
R
C1| S1
Q=t
t
f
A
Q=f
t
f
0.9
0.5
C1|0.1
C2 0.5
t
C2=t
R | C1
t
f
t
1
0.5
f
f
C2=f
t
0.6
0.1
f
0.4
0.9
01
R\C
0.5
t
f
t
0.5
0
f
0.5
1
A|R
R
t
3/30/2006
f
f
0.3
0.7
0.7
Bayesian Networks: Review
f
t
t
0.8
0.8
0.2
f
f
0.1
0.1
0.9
15
Marginal probability query

S1
Let’s compute
Q
C1
C2
R
A
3/30/2006
Bayesian Networks: Review
16
Most probable explanation

S1
Now, let’s compute
Q
C1
C2
R
A
3/30/2006
Bayesian Networks: Review
17
Do we need this algorithm?

Couldn’t we just take argmax of marginals?
Take
A\B
3/30/2006
t
f
t
0.3
0.4
f
0.3
0
Bayesian Networks: Review
18
What you need to know

Representation
 Independence relations




Variable elimination


3/30/2006
local Markov assumption
active trails / d-separation
independence relations => factorization
marginal queries
argmax queries
Bayesian Networks: Review
19