bctpy icon indicating copy to clipboard operation
bctpy copied to clipboard

Update `get_rng` to return Generator instances

Open clbarnes opened this issue 2 years ago • 0 comments

Following on from #67 :

As of somewhat-recent numpy versions, the RandomState RNG interface has been deprecated in favour of the Generator interface, and bctpy should be updated to match.

It's worth noting that the RandomState class will produce stable results across numpy versions (other than bugfixes), where the now-preferred Generator class will benefit from algorithmic improvements which may change the random numbers returned from the same seed.

clbarnes avatar Aug 28 '22 13:08 clbarnes