- cupyx.scipy.ndimage.maximum(input, labels=None, index=None)¶
Calculate the maximum of the values of an array over labeled regions.
input (cupy.ndarray) – Array of values. For each region specified by labels, the maximal values of input over the region is computed.
labels (cupy.ndarray, optional) – An array of integers marking different regions over which the maximum value of input is to be computed. labels must have the same shape as input. If labels is not specified, the maximum over the whole array is returned.
index (array_like, optional) – A list of region labels that are taken into account for computing the maxima. If index is None, the maximum over all elements where labels is non-zero is returned.
Array of maxima of input over the regions determaxed by labels and whose index is in index. If index or labels are not specified, a 0-dimensional cupy.ndarray is returned: the maximal value of input if labels is None, and the maximal value of elements where labels is greater than zero if index is None.
- Return type