Bayesian Network Code In Python