deepmd.tf.utils.random
Alias for backward compatibility. Generates a random sample from a given 1-D array. Return random floats in the half-open interval [0.0, 1.0). Seed the generator. Modify a sequence in-place by shuffling its contents. Generates a random sample from a given 1-D array. If an ndarray, a random sample is generated from its elements. If an int, the random sample is generated as if it were np.arange(a) Output shape. If the given shape is, e.g., (m, n, k), then m * n * k samples are drawn. Default is None, in which case a single value is returned. Whether the sample is with or without replacement. Default is True, meaning that a value of a can be selected multiple times. The probabilities associated with each entry in a. If not given, the sample assumes a uniform distribution over all entries in a. arrays with results and their shapes Return random floats in the half-open interval [0.0, 1.0). Output shape. Arrays with results and their shapes. Seed the generator. Seed. Modify a sequence in-place by shuffling its contents. The array or list to be shuffled.Module Contents
Functions
choice
(a[, size, replace, p])random
([size])seed
([val])shuffle
(x)int
int
or tuple
of
ints
, optional
optional
optional
np.ndarray
np.ndarray
int
np.ndarray