SlideShare a Scribd company logo
1 of 6
Download to read offline
Note to other teachers and users of these slides.
                                                         Andrew would be delighted if you found this source
                                                         material useful in giving your own lectures. Feel free
                                                         to use these slides verbatim, or to modify them to fit
                                                         your own needs. PowerPoint originals are available. If
                                                         you make use of a significant portion of these slides in
                                                         your own lecture, please include this message, or the
                                                         following link to the source repository of Andrew’s
                                                         tutorials: http://www.cs.cmu.edu/~awm/tutorials .
                                                         Comments and corrections gratefully received.


               Bayes Net Structure
                    Learning
                                   Andrew W. Moore
                                  Associate Professor
                              School of Computer Science
                              Carnegie Mellon University
                                       www.cs.cmu.edu/~awm
                                         awm@cs.cmu.edu
                                           412-268-7599


         Copyright © 2001, Andrew W. Moore                                  Oct 29th, 2001




                 Reminder: A Bayes Net




Copyright © 2001, Andrew W. Moore                                          Bayes Net Structure: Slide 2




                                                                                                                    1
Estimating
Probability
  Tables




Copyright © 2001, Andrew W. Moore   Bayes Net Structure: Slide 3




Estimating
Probability
  Tables




Copyright © 2001, Andrew W. Moore   Bayes Net Structure: Slide 4




                                                                   2
Scoring a
   structure

                                                                  (Which of these fits
                                                                  the data best?)

                                             N. Friedman and Z. Yakhini, On the sample
Score =                                      complexity of learning Bayesian networks,
                                             Proceedings of the 12th conference on
  N
− params log R                               Uncertainty in Artificial Intelligence, Morgan
                                             Kaufmann, 1996
    2
          num combinations 
                           
                      ues  (arityof X j )
       m  of parent val    
+ R∑                ∑                 ∑ P(V ) P( X            = v | Vk ) log P ( X j = v | Vk )
                                                k         j
       j =1         k =1              v =1


 Copyright © 2001, Andrew W. Moore                                         Bayes Net Structure: Slide 5




  Scoring a
   structure
Number of non-
redundant
parameters defining
the net                         Sums over all the
                                rows in the prob-
        #Attributes             ability table for X j

                   #Records
Score =                                      The parent values
                                             in the k’th row of
  N
− params log R                               X j ’s probability
                                             table
    2
          num combinations 
                           
                      ues  (arityof X j )
       m  of parent val    
+ R∑                ∑                 ∑ P(V ) P( X            = v | Vk ) log P ( X j = v | Vk )
                                                k         j
       j =1         k =1              v =1
                                              All these values estimated from data
 Copyright © 2001, Andrew W. Moore                                         Bayes Net Structure: Slide 6




                                                                                                          3
Scoring a                          This is called a BIC (Bayes Information
  structure                          Criterion) estimate
                                     This part is a penalty for too many
                                     parameters
                                     This part is the training set log-
                                     likelihood
                                     BIC asymptotically tries to get the
Score =                              structure right. (There’s a lot of heavy emotional debate
  N                                  about whether this is the best scoring criterion)
− params log R
    2
         num combinations 
                          
                     ues  (arityof X j )
      m  of parent val    
+ R∑               ∑                ∑ P(V ) P( X               = v | Vk ) log P ( X j = v | Vk )
                                               k           j
      j =1         k =1             v =1
                                             All these values estimated from data
Copyright © 2001, Andrew W. Moore                                                Bayes Net Structure: Slide 7




 Searching
for structure
  with best
    score




Copyright © 2001, Andrew W. Moore                                                Bayes Net Structure: Slide 8




                                                                                                                4
Learning Methods until today



                                          Dec Tree, Sigmoid Perceptron, Sigmoid N.Net,
                                Predict Gauss/Joint BC, Gauss Naïve BC, N.Neigh
 Inputs




                  Classifier   category

                                          Joint DE, Naïve DE, Gauss/Joint DE, Gauss Naïve
                                Prob-
 Inputs Inputs




                   Density
                                          DE
                                ability
                  Estimator

                                          Linear Regression, Quadratic Regression,
                                Predict
                  Regressor               Perceptron, Neural Net, N.Neigh, Kernel, LWR
                               real no.



Copyright © 2001, Andrew W. Moore                                       Bayes Net Structure: Slide 9




            Learning Methods added today



                                          Dec Tree, Sigmoid Perceptron, Sigmoid N.Net,
                                Predict Gauss/Joint BC, Gauss Naïve BC, N.Neigh
 Inputs




                  Classifier   category

                                          Joint DE, Naïve DE, Gauss/Joint DE, Gauss Naïve
                                Prob-
 Inputs Inputs




                   Density
                                          DE, Bayes Net Structure Learning (Note, can be
                                ability
                  Estimator
                                          extended to permit mixed categorical/real values)
                                          Linear Regression, Quadratic Regression,
                                Predict
                  Regressor               Perceptron, Neural Net, N.Neigh, Kernel, LWR
                               real no.



Copyright © 2001, Andrew W. Moore                                      Bayes Net Structure: Slide 10




                                                                                                       5
But also, for free…



                                         Dec Tree, Sigmoid Perceptron, Sigmoid N.Net,
                               Predict Gauss/Joint BC, Gauss Naïve BC, N.Neigh, Bayes
 Inputs




                 Classifier   category Net Based BC

                                         Joint DE, Naïve DE, Gauss/Joint DE, Gauss Naïve
                               Prob-
 Inputs Inputs




                  Density
                                         DE, Bayes Net Structure Learning
                               ability
                 Estimator

                                         Linear Regression, Quadratic Regression,
                               Predict
                 Regressor               Perceptron, Neural Net, N.Neigh, Kernel, LWR
                              real no.



Copyright © 2001, Andrew W. Moore                                    Bayes Net Structure: Slide 11




                      And a new operation…
 Inputs




                  Inference
                              P(E1|E2) Joint DE, Bayes Net Structure Learning
                 Engine Learn

                                         Dec Tree, Sigmoid Perceptron, Sigmoid N.Net,
                               Predict Gauss/Joint BC, Gauss Naïve BC, N.Neigh, Bayes
 Inputs




                 Classifier   category Net Based BC

                                         Joint DE, Naïve DE, Gauss/Joint DE, Gauss Naïve
                               Prob-
 Inputs Inputs




                  Density
                                         DE, Bayes Net Structure Learning
                               ability
                 Estimator

                                         Linear Regression, Quadratic Regression,
                               Predict
                 Regressor               Perceptron, Neural Net, N.Neigh, Kernel, LWR
                              real no.



Copyright © 2001, Andrew W. Moore                                    Bayes Net Structure: Slide 12




                                                                                                     6

More Related Content

Viewers also liked

Inference in Bayesian Networks
Inference in Bayesian NetworksInference in Bayesian Networks
Inference in Bayesian Networksguestfee8698
 
Training pendidikan 2012
Training pendidikan 2012Training pendidikan 2012
Training pendidikan 2012Azure Linger
 
FY2009 Sex Ed Abstinence Fact Sheet
FY2009 Sex Ed Abstinence Fact SheetFY2009 Sex Ed Abstinence Fact Sheet
FY2009 Sex Ed Abstinence Fact SheetMarcus Peterson
 
Hidden Markov Models
Hidden Markov ModelsHidden Markov Models
Hidden Markov Modelsguestfee8698
 
Gaussian Mixture Models
Gaussian Mixture ModelsGaussian Mixture Models
Gaussian Mixture Modelsguestfee8698
 
Maximum Likelihood Estimation
Maximum Likelihood EstimationMaximum Likelihood Estimation
Maximum Likelihood Estimationguestfee8698
 
K-means and Hierarchical Clustering
K-means and Hierarchical ClusteringK-means and Hierarchical Clustering
K-means and Hierarchical Clusteringguestfee8698
 

Viewers also liked (10)

Inference in Bayesian Networks
Inference in Bayesian NetworksInference in Bayesian Networks
Inference in Bayesian Networks
 
Training pendidikan 2012
Training pendidikan 2012Training pendidikan 2012
Training pendidikan 2012
 
FY2009 Sex Ed Abstinence Fact Sheet
FY2009 Sex Ed Abstinence Fact SheetFY2009 Sex Ed Abstinence Fact Sheet
FY2009 Sex Ed Abstinence Fact Sheet
 
Hidden Markov Models
Hidden Markov ModelsHidden Markov Models
Hidden Markov Models
 
VC dimensio
VC dimensioVC dimensio
VC dimensio
 
PAC Learning
PAC LearningPAC Learning
PAC Learning
 
Cross-Validation
Cross-ValidationCross-Validation
Cross-Validation
 
Gaussian Mixture Models
Gaussian Mixture ModelsGaussian Mixture Models
Gaussian Mixture Models
 
Maximum Likelihood Estimation
Maximum Likelihood EstimationMaximum Likelihood Estimation
Maximum Likelihood Estimation
 
K-means and Hierarchical Clustering
K-means and Hierarchical ClusteringK-means and Hierarchical Clustering
K-means and Hierarchical Clustering
 

Similar to Learning Bayesian Networks (6)

07 approximate inference in bn
07 approximate inference in bn07 approximate inference in bn
07 approximate inference in bn
 
Project3.ppt
Project3.pptProject3.ppt
Project3.ppt
 
Bayesian probabilistic interference
Bayesian probabilistic interferenceBayesian probabilistic interference
Bayesian probabilistic interference
 
Bayesian probabilistic interference
Bayesian probabilistic interferenceBayesian probabilistic interference
Bayesian probabilistic interference
 
06 exact inference in bn
06 exact inference in bn06 exact inference in bn
06 exact inference in bn
 
Predicting Real-valued Outputs: An introduction to regression
Predicting Real-valued Outputs: An introduction to regressionPredicting Real-valued Outputs: An introduction to regression
Predicting Real-valued Outputs: An introduction to regression
 

Recently uploaded

Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfjimielynbastida
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Bluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfBluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfngoud9212
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Neo4j
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentationphoebematthew05
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 

Recently uploaded (20)

Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdf
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Bluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfBluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdf
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentation
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 

Learning Bayesian Networks

  • 1. Note to other teachers and users of these slides. Andrew would be delighted if you found this source material useful in giving your own lectures. Feel free to use these slides verbatim, or to modify them to fit your own needs. PowerPoint originals are available. If you make use of a significant portion of these slides in your own lecture, please include this message, or the following link to the source repository of Andrew’s tutorials: http://www.cs.cmu.edu/~awm/tutorials . Comments and corrections gratefully received. Bayes Net Structure Learning Andrew W. Moore Associate Professor School of Computer Science Carnegie Mellon University www.cs.cmu.edu/~awm awm@cs.cmu.edu 412-268-7599 Copyright © 2001, Andrew W. Moore Oct 29th, 2001 Reminder: A Bayes Net Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 2 1
  • 2. Estimating Probability Tables Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 3 Estimating Probability Tables Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 4 2
  • 3. Scoring a structure (Which of these fits the data best?) N. Friedman and Z. Yakhini, On the sample Score = complexity of learning Bayesian networks, Proceedings of the 12th conference on N − params log R Uncertainty in Artificial Intelligence, Morgan Kaufmann, 1996 2  num combinations     ues  (arityof X j ) m  of parent val  + R∑ ∑ ∑ P(V ) P( X = v | Vk ) log P ( X j = v | Vk ) k j j =1 k =1 v =1 Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 5 Scoring a structure Number of non- redundant parameters defining the net Sums over all the rows in the prob- #Attributes ability table for X j #Records Score = The parent values in the k’th row of N − params log R X j ’s probability table 2  num combinations     ues  (arityof X j ) m  of parent val  + R∑ ∑ ∑ P(V ) P( X = v | Vk ) log P ( X j = v | Vk ) k j j =1 k =1 v =1 All these values estimated from data Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 6 3
  • 4. Scoring a This is called a BIC (Bayes Information structure Criterion) estimate This part is a penalty for too many parameters This part is the training set log- likelihood BIC asymptotically tries to get the Score = structure right. (There’s a lot of heavy emotional debate N about whether this is the best scoring criterion) − params log R 2  num combinations     ues  (arityof X j ) m  of parent val  + R∑ ∑ ∑ P(V ) P( X = v | Vk ) log P ( X j = v | Vk ) k j j =1 k =1 v =1 All these values estimated from data Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 7 Searching for structure with best score Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 8 4
  • 5. Learning Methods until today Dec Tree, Sigmoid Perceptron, Sigmoid N.Net, Predict Gauss/Joint BC, Gauss Naïve BC, N.Neigh Inputs Classifier category Joint DE, Naïve DE, Gauss/Joint DE, Gauss Naïve Prob- Inputs Inputs Density DE ability Estimator Linear Regression, Quadratic Regression, Predict Regressor Perceptron, Neural Net, N.Neigh, Kernel, LWR real no. Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 9 Learning Methods added today Dec Tree, Sigmoid Perceptron, Sigmoid N.Net, Predict Gauss/Joint BC, Gauss Naïve BC, N.Neigh Inputs Classifier category Joint DE, Naïve DE, Gauss/Joint DE, Gauss Naïve Prob- Inputs Inputs Density DE, Bayes Net Structure Learning (Note, can be ability Estimator extended to permit mixed categorical/real values) Linear Regression, Quadratic Regression, Predict Regressor Perceptron, Neural Net, N.Neigh, Kernel, LWR real no. Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 10 5
  • 6. But also, for free… Dec Tree, Sigmoid Perceptron, Sigmoid N.Net, Predict Gauss/Joint BC, Gauss Naïve BC, N.Neigh, Bayes Inputs Classifier category Net Based BC Joint DE, Naïve DE, Gauss/Joint DE, Gauss Naïve Prob- Inputs Inputs Density DE, Bayes Net Structure Learning ability Estimator Linear Regression, Quadratic Regression, Predict Regressor Perceptron, Neural Net, N.Neigh, Kernel, LWR real no. Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 11 And a new operation… Inputs Inference P(E1|E2) Joint DE, Bayes Net Structure Learning Engine Learn Dec Tree, Sigmoid Perceptron, Sigmoid N.Net, Predict Gauss/Joint BC, Gauss Naïve BC, N.Neigh, Bayes Inputs Classifier category Net Based BC Joint DE, Naïve DE, Gauss/Joint DE, Gauss Naïve Prob- Inputs Inputs Density DE, Bayes Net Structure Learning ability Estimator Linear Regression, Quadratic Regression, Predict Regressor Perceptron, Neural Net, N.Neigh, Kernel, LWR real no. Copyright © 2001, Andrew W. Moore Bayes Net Structure: Slide 12 6