Implement Bayesian Networks In Python Class