Is there a way to serialize a CURAND RNG?

With Base, I can take the RNG returned by Random.default_rng(), write it to file with eg JLD2, then later reload it and reproduce my random number sequence from that point.

Is something like this possible with CURAND? I know I can do e.g. CURAND.seed!(0) and always get same random sequence after that, but I can’t figure out how to just save the current random state.

The CURAND API doesn’t seem to offer a way to get the current seed and offset, so no,

1 Like