Team Ai
Datasetpublic

codekingpro/portable-devtools

sourceHugging Faceupdated 5mo agoView on Hugging Face
1likes14kdownloads
_mt19937.pyi28 linesDownload Raw Back to random
1from typing import TypedDict, type_check_only
2
3from numpy import uint32
4from numpy._typing import _ArrayLikeInt_co
5from numpy.random.bit_generator import BitGenerator, SeedSequence
6from numpy.typing import NDArray
7
8__all__ = ["MT19937"]
9
10@type_check_only
11class _MT19937Internal(TypedDict):
12    key: NDArray[uint32]
13    pos: int
14
15@type_check_only
16class _MT19937State(TypedDict):
17    bit_generator: str
18    state: _MT19937Internal
19
20class MT19937(BitGenerator):
21    def __init__(self, seed: _ArrayLikeInt_co | SeedSequence | None = ...) -> None: ...
22    def _legacy_seeding(self, seed: _ArrayLikeInt_co) -> None: ...
23    def jumped(self, jumps: int = 1) -> MT19937: ...
24    @property  # type: ignore[override]
25    def state(self) -> _MT19937State: ...
26    @state.setter
27    def state(self, value: _MT19937State) -> None: ...
28 
codekingpro/portable-devtools · Team Ai