library to simulate master equations in python