bundles / numpy 2.5.0.dev0+git20251130.2de293a / numpy / random / _mt19937 / MT19937 / _legacy_seeding
cython_function_or_method
numpy.random._mt19937:MT19937._legacy_seeding
Signature
def _legacy_seeding ( seed ) Summary
Seed the generator in a backward compatible way. For modern applications, creating a new instance is preferable. Calling this overrides self._seed_seq
Parameters
seed: {None, int, array_like}Random seed initializing the pseudo-random number generator. Can be an integer in [0, 2**32-1], array of integers in [0, 2**32-1], a
SeedSequence, or ''None'. IfseedisNone, then fresh, unpredictable entropy will be pulled from the OS.
Raises
: ValueErrorIf seed values are out of range for the PRNG.
Aliases
-
numpy.random.MT19937._legacy_seeding