johnabel / gillespy

A Python package for stochastic model building and simulation. Published as Abel et al., IEEE Life Sci Lett 2017.
https://dx.doi.org/10.1109/LLS.2017.2652448
GNU General Public License v3.0
6 stars 17 forks source link

Setting the seed #6

Closed johnabel closed 9 years ago

johnabel commented 9 years ago

We should discuss this.

ahellander commented 9 years ago

What is it that you want to do?

johnabel commented 9 years ago

The question is one of best practices: if unspecified, should gillespy run a specific seed every time, or should the seed be dynamically generated. I talked to Brian about this but I don't recall the conclusion.

ahellander commented 9 years ago

Not obvious, but I think it might be safer to try to pick a dynamically generated one. I think then the risk of modeling errors is slightly smaller. I think user's would expect a different seed? On the other hand, it can be tricky.

A compromise might be to use a fixed one the first time a solver or model.run is called, and then generate new ones for each consecutive call to it.

briandrawert commented 9 years ago

To stay consistent with StochSS and other stochastic software packages, if a seed is not given, a randomly generated int is used as the see (done in this commit: fac5f5c077e2966849c1afd3af7b0a6c8dfe498c)