Python code for inference in ODE models