Pickling helper function that returns a legacy RandomState-like object Parameters ---------- bit_generator_name : str String containing the core BitGenerator's name bit_generator_ctor : callable, optional Callable function that takes bit_generator_name as its on
(bit_generator_name="MT19937",
bit_generator_ctor=__bit_generator_ctor)
| 59 | |
| 60 | |
| 61 | def __randomstate_ctor(bit_generator_name="MT19937", |
| 62 | bit_generator_ctor=__bit_generator_ctor): |
| 63 | """ |
| 64 | Pickling helper function that returns a legacy RandomState-like object |
| 65 | |
| 66 | Parameters |
| 67 | ---------- |
| 68 | bit_generator_name : str |
| 69 | String containing the core BitGenerator's name |
| 70 | bit_generator_ctor : callable, optional |
| 71 | Callable function that takes bit_generator_name as its only argument |
| 72 | and returns an instantized bit generator. |
| 73 | |
| 74 | Returns |
| 75 | ------- |
| 76 | rs : RandomState |
| 77 | Legacy RandomState using the named core BitGenerator |
| 78 | """ |
| 79 | |
| 80 | return RandomState(bit_generator_ctor(bit_generator_name)) |
nothing calls this directly
no outgoing calls
no test coverage detected