Generator
and RandomState
were removed in 1.23.0.
Use numpy.random.Generator
if possible, or numpy.random.RandomState
if you face legacy constraints.
Generator
and RandomState
have been officially deprecated, and will warn with a FutureWarning
about their removal. They will also receive virtually no maintenance. It is now time to move to NumPy’s numpy.random.Generator
which has features not in Generator
and is maintained more actively.
A few distributions that are not present in Generator
have been moved to ExtendedGenerator
:
multivariate_normal()
: which supports broadcasting
uintegers()
: fast 32 and 64-bit uniform integers
complex_normal()
: scalar complex normals
There are no plans to remove any of the bit generators, e.g., AESCounter
, ThreeFry
, or PCG64
.
There are many changes between v1.16.x and v1.18.x. These reflect API decision taken in conjunction with NumPy in preparation of the core of randomgen
being used as the preferred random number generator in NumPy. These all issue DeprecationWarning
except for BitGenerator.generator
which raises NotImplementedError
. The C-API has also changed to reflect the preferred naming the underlying Pseudo-RNGs, which are now known as bit generators (or BitGenerator
).
The main changes are
Rename RandomGenerator
to Generator
.
Rename randint
to integers
.
Rename random_integers
to integers
.
Rename random_sample
to random
.
Change jump
which operated in-place to jumped
which returns a new BitGenerator
.
Rename Basic RNG to bit generator, which impacts the API in multiple places where names like brng
and basic_rng
have been replaced by bitgen
or bit_generator
.
Support for randomgen.seed_sequence.SeedSequence
(also support NumPy SeedSequence
instances)
Removed support for Python 2.7
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4