cupy.random.beta

cupy.random.beta(a, b, size=None, dtype=<class 'float'>)[source]

Beta distribution.

Returns an array of samples drawn from the beta distribution. Its probability density function is defined as

\[f(x) = \frac{x^{\alpha-1}(1-x)^{\beta-1}}{B(\alpha,\beta)}.\]
Parameters:
  • a (float) – Parameter of the beta distribution \(\alpha\).
  • b (float) – Parameter of the beta distribution \(\beta\).
  • size (int or tuple of ints) – The shape of the array. If None, a zero-dimensional array is generated.
  • dtype – Data type specifier. Only numpy.float32 and numpy.float64 types are allowed.
Returns:

Samples drawn from the beta distribution.

Return type:

cupy.ndarray

See also

numpy.random.beta()