dpnp.sort
- dpnp.sort(x1, **kwargs)[source]
Return a sorted copy of an array.
For full documentation refer to
numpy.sort.Limitations
Input array is supported as
dpnp.ndarray. Keyword argumentskwargsare currently unsupported. Dimension of input array is supported to be equal to1. Otherwise the function will be executed sequentially on CPU. Input array data types are limited by supported DPNP Data types.See also
dpnp.argsortIndirect sort.
dpnp.lexsortIndirect stable sort on multiple keys.
dpnp.searchsortedFind elements in a sorted array.
dpnp.partitionPartial sort.
Examples
>>> import dpnp as np >>> a = np.array([1, 4, 3, 1]) >>> out = np.sort(a) >>> [i for i in out] [1, 1, 3, 4]