File tree Expand file tree Collapse file tree 2 files changed +1
-21
lines changed Expand file tree Collapse file tree 2 files changed +1
-21
lines changed Original file line number Diff line number Diff line change @@ -1141,11 +1141,6 @@ def group_nth(
1141
1141
1142
1142
if uses_mask:
1143
1143
isna_entry = mask[i, j]
1144
- if isna_entry:
1145
- # set out[i, j] to 0 to be deterministic, as
1146
- # it was initialized with np.empty. Also ensures
1147
- # we can downcast out if appropriate.
1148
- out[i, j] = 0
1149
1144
else :
1150
1145
isna_entry = checknull(val)
1151
1146
@@ -1176,12 +1171,6 @@ def group_nth(
1176
1171
1177
1172
if uses_mask:
1178
1173
isna_entry = mask[i, j]
1179
- if isna_entry:
1180
- # set out[i, j] to 0 to be deterministic, as
1181
- # it was initialized with np.empty. Also ensures
1182
- # we can downcast out if appropriate.
1183
- out[i, j] = 0
1184
-
1185
1174
else :
1186
1175
isna_entry = _treat_as_na(val, True )
1187
1176
# TODO: Sure we always want is_datetimelike=True?
Original file line number Diff line number Diff line change @@ -434,10 +434,9 @@ def _masked_ea_wrap_cython_operation(
434
434
)
435
435
436
436
dtype = self ._get_result_dtype (orig_values .dtype )
437
- assert res_values .dtype == dtype .type , (res_values .dtype , dtype )
438
437
# TODO: avoid cast as res_values *should* already have the right
439
438
# dtype; last attempt ran into trouble on 32bit linux build
440
- # res_values = res_values.astype(dtype.type, copy=False)
439
+ res_values = res_values .astype (dtype .type , copy = False )
441
440
442
441
if self .kind != "aggregate" :
443
442
out_mask = mask
@@ -607,14 +606,6 @@ def _call_cython_op(
607
606
# "rank" is the only member of cast_blocklist we get here
608
607
res_dtype = self ._get_result_dtype (orig_values .dtype )
609
608
op_result = maybe_downcast_to_dtype (result , res_dtype )
610
- if self .how == "first" and result_mask is not None and self .uses_mask ():
611
- # troubleshooting 32bit linux build
612
- assert res_dtype == orig_values .dtype , (res_dtype , orig_values .dtype )
613
- assert op_result .dtype == res_dtype , (
614
- op_result .dtype ,
615
- res_dtype ,
616
- result ,
617
- )
618
609
else :
619
610
op_result = result
620
611
You can’t perform that action at this time.
0 commit comments