random – Low-level random numbers#

Low-level random numbers#

The pytensor.tensor.random module provides random-number drawing functionality that closely resembles the numpy.random module.

pytensor.tensor.random.basic.permutation(x, **kwargs)[source]#

Randomly permute a sequence or a range of values.

Signature#

(x) -> (x)

param x:

If x is an integer, randomly permute np.arange(x). If x is a sequence, shuffle its elements randomly.