O'Reilly logo

Building Probabilistic Graphical Models with Python by Kiran R Karkera

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using the Variable Elimination algorithm

In this section, we shall learn the Variable Elimination algorithm. In the VarElim_asia.ipynb IPython Notebook, we shall use the Asia network to understand the details of this algorithm.

The Asia network (http://www.bnlearn.com/bnrepository/#asia) is a toy Bayesian network used for patient diagnosis. The network tries to elicit the possibility of lung cancer or tuberculosis based on factors such as travel to Asia, smoking history, and X-ray results. Further details on the Asia network can be found at http://www.norsys.com/tutorials/netica/secA/tut_A1.htm.

The following is the diagram of the Asia network (courtesy of http://www.bnlearn.com/bnrepository/asia/asia.png):

The goal of this code snippet is to compare ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required