Skip to content

Commit 49812cf

Browse files
WillAydjreback
authored andcommitted
Explicitly set dtype of np.lexsort in group_rank (#19679)
1 parent 8cace88 commit 49812cf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pandas/_libs/groupby_helper.pxi.in

+1-1
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@ def group_rank_{{name}}(ndarray[float64_t, ndim=2] out,
531531
# each label corresponds to a different group value,
532532
# the mask helps you differentiate missing values before
533533
# performing sort on the actual values
534-
_as = np.lexsort(order)
534+
_as = np.lexsort(order).view(dtype=np.int64)
535535

536536
if not ascending:
537537
_as = _as[::-1]

0 commit comments

Comments
 (0)