Skip to content

An implementation of loopy belief propagation on a Bayesian Network (BN)

Notifications You must be signed in to change notification settings

nanchenchen/belief-propagation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 

Repository files navigation

Belief Propagation on Bayesian Network

This is a program that runs loopy belief propagation on a Bayesian Network (BN), and generate the marginalized probability for each node on the network. The details of the algorithm refers to Kschischang et al. (2001), with the variation of using bethe cluster graph instead a pure factor graph of BN. The input format should be in Bayesian Network Interchange Format (BIF)

Usage

$ python bp <.bif file path> [-o output file] [-t threshold]
Options:
   -o, --output          output file name, default to 'result.txt'
   -t, --threshold       threshold for convergence default to 1e-10

Acknowledgment

The BIF parser is provided by Antoine Bosselut. The codes in the project is for the assignment 3 in CSE 515 - Statistical Methods in Computer Science, University of Washington.

About

An implementation of loopy belief propagation on a Bayesian Network (BN)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages