Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf ·...

16
Bayes Nets Representation: joint distribution and conditional independence Yi Zhang 10-701, Machine Learning, Spring 2011 February 9 th , 2011 Parts of the slides are from previous 10-701 lectures 1

Transcript of Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf ·...

Page 1: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Bayes Nets Representation: joint distribution and conditional independence

Yi Zhang10-701, Machine Learning, Spring 2011February 9th, 2011

Parts of the slides are from previous 10-701 lectures

1

Page 2: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Outline

Conditional independence (C. I.) Bayes nets: overview Local Markov assumption of BNs Factored joint distribution of BNs Infer C. I. from factored joint distributions D-separation (motivation)

2

Page 3: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Conditional independence X is conditionally independent of Y given Z

◦ In short:

◦ Equivalent to:

3

Page 4: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Bayes nets Bayes nets: directed acyclic graphs express sets

of conditional independence via graph structure◦ All about the joint distribution of variables !◦ Conditional independence assumptions are useful ◦ Naïve Bayes model is an extreme example

4

Page 5: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Three key questions for BNs Representation: ◦ What joint distribution does a BN represent?

Inference◦ How to answer questions about the joint distribution? Conditional independence Marginal distribution Most likely assignment

Learning◦ How to learn the graph structure and parameters of a

BN from data?

5

Page 6: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Local Markov assumptions of BNs A variable X is independent of its non-

descendants given (only) its parents◦ Intuition: “flu” and “allergy” causes “headache” only

through “sinus”

6

Page 7: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Local Markov assumptions of BNs A variable X is independent of its non-

descendants given (only) its parents

7

Page 8: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Local Markov assumptions of BNs Local Markov assumptions only express a subset

of C.I.s on a BN◦ Is XM conditionally independent of X1 given X2?

But they are sufficient to infer all others

8

Page 9: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Factored joint distribution of a BN

A BN can represent the joint distributions of the following form:

9

Page 10: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Factored joint distribution of a BN

A BN can represent the joint distributions of the following form:

10

Page 11: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Factored joint distribution of a BN

Local Markov assumptions imply the factored joint distribution

11

Page 12: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Factored joint distribution of a BN Naïve Bayes◦ Local Markov assumptions: ◦ Factored joint distribution:

12

Page 13: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Infer C.I. from the factored joint distribution We already see: local Markov assumptions

factored joint distribution Also, factored joint distribution all C.I. in

the BN

13

Page 14: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Infer C.I. from the factored joint distribution Factored Joint distribution

Show that

14

Page 15: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

Infer C.I. from the factored joint distribution Factored Joint distribution

Do we have ? In general, no.

◦ Cannot be written into two separate terms of a and b

15

Page 16: Bayes Nets Representation: joint distribution and ...tom/10701_sp11/recitations/Recitation_4.pdf · Bayes Nets Representation: joint distribution and conditional independence Yi Zhang

D-separation: motivation Is XM conditionally independent of X1 given X2?

◦ Intuitively yes: X1 affects XM only through X2 .◦ Method 1: using factored joint distribution to derive

◦ Method II: D-separation --- not today

16