Sorting, Searching, and CountingΒΆ

cupy.sort Returns a sorted copy of an array with a stable sorting algorithm.
cupy.lexsort Perform an indirect sort using an array of keys.
cupy.argsort Returns the indices that would sort an array with a stable sorting.
cupy.argmax Returns the indices of the maximum along an axis.
cupy.argmin Returns the indices of the minimum along an axis.
cupy.partition Returns a partially sorted copy of an array.
cupy.count_nonzero Counts the number of non-zero values in the array.
cupy.nonzero Return the indices of the elements that are non-zero.
cupy.flatnonzero Return indices that are non-zero in the flattened version of a.
cupy.where Return elements, either from x or y, depending on condition.