# cupy.histogram¶

cupy.histogram(x, bins=10)[source]

Computes the histogram of a set of data.

Parameters: x (cupy.ndarray) – Input array. bins (int or cupy.ndarray) – If bins is an int, it represents the number of bins. If bins is an ndarray, it represents a bin edges. (hist, bin_edges) where hist is a cupy.ndarray storing the values of the histogram, and bin_edges is a cupy.ndarray storing the bin edges. tuple

Warning

This function may synchronize the device.