TPs in Python for Probabilistic Graphical Models