You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Random Number Generation (RNG) is a bit messy in ScopeSim. See for example #295 and #97.
The idea behind this issue is to collect what we need from the RNG.
I'll go first.
The default should perhaps be to seed the RNG with something supposedly unique, like the MJDOBS of the simulated observation. This can be done once we can simulate full templates / observing blocks.
If that's not possible, the default should be a 'random random number seed' I believe, unlike the current fixed seed.
Whatever seed is used, it should be stored in the headers of the FITS file, so it is possible to uniquely recreate the exact same simulation (which also requires other keywords, e.g. for versioning).
The RNG should be setup such that each effect 'splits of' its own generator from the main one, instead of reusing the seed. This should be easy to do in Python/numpy/scipy.
Perhaps it should be possible to seed only specific effects, and not others. For example the generation of hot/cold pixels should perhaps be the same over many simulations, but the noise should not.
The text was updated successfully, but these errors were encountered:
I recently noticed that numpy recommends using np.random.Generator for new development. AFAIK, we're using the legacy random functions most everywhere. While I didn't consider it a priority at the time I found out about this, I think if (when) we're already touching the random stuff, it might be worth migrating to the new style, which numpy claim has performance benefits, as well as quality of the "randomness" and handling. Maybe some of the changes we want to implement anyway will become easier to manage with this.
The Random Number Generation (RNG) is a bit messy in ScopeSim. See for example #295 and #97.
The idea behind this issue is to collect what we need from the RNG.
I'll go first.
The text was updated successfully, but these errors were encountered: