Unverified Commit 9fc5eed6 authored by Minjie Wang's avatar Minjie Wang Committed by GitHub
Browse files

[Doc] Fix docstring of aten::Sort (#2579)

A small patch to #2391.
parent 2576647c
...@@ -314,16 +314,12 @@ IdArray NonZero(NDArray array); ...@@ -314,16 +314,12 @@ IdArray NonZero(NDArray array);
* is always in int64. * is always in int64.
* *
* \param array Input array. * \param array Input array.
* \param num_bits The number of bits used by the range of values in the array, * \param num_bits The number of bits used in key comparison. For example, if the data type
* or 0 to use all bits of the type. This is currently only used when sort * of the input array is int32_t and `num_bits = 8`, it only uses bits in index
* arrays on the GPU. * range [0, 8) for sorting. Setting it to a small value could
* \param num_bits The number of bits used in key comparison. The bits are * speed up the sorting if the underlying sorting algorithm is radix sort (e.g., on GPU).
* right aligned. For example, setting `num_bits` to 8 means using bits from * Setting it to zero (default value) means using all the bits for comparison.
* `sizeof(IdType) * 8 - num_bits` (inclusive) to `sizeof(IdType) * 8` * On CPU, it currently has no effect.
* (exclusive). Setting it to a small value could speed up the sorting if the
* underlying sorting algorithm is radix sort (e.g., on GPU). Setting it to
* value of zero, uses full number of bits of the type (sizeof(IdType)*8).
* On CPU, it currently has no effect.
* \return A pair of arrays: sorted values and sorted index to the original position. * \return A pair of arrays: sorted values and sorted index to the original position.
*/ */
std::pair<IdArray, IdArray> Sort(IdArray array, int num_bits = 0); std::pair<IdArray, IdArray> Sort(IdArray array, int num_bits = 0);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment