omnisolver.pt.testing#

Common testing utilities.

Module Contents#

Functions#

numba_seed(→ None)

Seed numba's random generator.

numba_rand(→ float)

Return random number uniformly chosen from [0, 1) using numba's random number generator.

omnisolver.pt.testing.numba_seed(seed) None#

Seed numba’s random generator.

Note that despite calling numpy’s random.seed, this function actually seeds numba’s internal rng, which DOES NOT share state with numpy’s rng.

omnisolver.pt.testing.numba_rand() float#

Return random number uniformly chosen from [0, 1) using numba’s random number generator.