Bayesian Reasoning and Machine Learning