latest (dev)
Copy
Latest development documentation · Updated 2026-10-08
tensorplay.accelerator.random
Device-agnostic random-number helpers for the current accelerator.
Seeds and generator states are read and written through the active
accelerator backend (the GPU backend in this build). device
accepts a device object, a spelling such as "cuda:1", an integer
index, or None for the current device.
Functions
|
Generator state of the given accelerator device. |
|
Generator states of every accelerator device. |
|
Initial seed of the generator for the given accelerator device. |
|
Seed the generator of the current accelerator device. |
|
Seed the generators of every accelerator device. |
|
Reseed the generator of the current accelerator device. |
|
Reseed the generators of every accelerator device. |
|
Set the generator state of the given accelerator device. |
|
Set the generator states of every accelerator device. |
Help improve this page
Found an error, an unclear step, or a missing example?

