don't create a new distribution object every time and also variate_generator doesn't seem to be doing what it is supposed to do... and that it's no different to simply use the dist(engine) here.