Would that be to get the exact same variates as the serial execution would create?
2015-02-26 15:04 GMT-05:00 Steve Kay <[email protected]>: > Thanks for the comments. - nice to know it's not my usual programming > inadequacies. I like the > > for p in workers() > @spawnat p srand(seed + p) > end > > idea. It would be even better if instead of resetting the seed it did a > (imaginary) @spawnat p jumpahead(seed,(p*X)) where X was larger than the > number of bootstrap reps for each worker. Here jumpahead(seed,b) took > the state of the random number generator when seed=seed and then moves it > on b steps. Very easy for me to come up with imaginary commands - way past > my ability to actually program them! > > On Thursday, February 26, 2015 at 3:37:19 PM UTC, Steve Kay wrote: >> >> There is a really nice example of using pmap for parallel bootstrapping >> purposes on http://juliaeconomics.com/2014/06/18/parallel- >> processing-in-julia-bootstrapping-the-mle/ . >> If you rerun the code however, it's clear that the pmap function does not >> respect the set seed command srand. I've tried various small changes but >> nothing is working (although a lot of nuances around parallel computing are >> a bit above my level). Is it possible to get pmap to respect the seed >> setting? I hope there is as pmap is superb otherwise. >> >> Any help much appreciated. >> >> Best, >> >> Steve >> >
