Converting model to stochastic