You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CategoricalBlock.array_dtype returns np.object_, but the docstring describes array_dtype as "the dtype to return if I want to construct this block as an array". Shouldn't the array constructed now be Categorical? In which case, shouldn't the dtype here be self.dtype? (which matches the base class, and in fact makes the attribute unnecessary)
The text was updated successfully, but these errors were encountered:
where in any case it is required to be a numpy dtype (and not extension dtype). So apparently this path is not hit with ExtensionBlock (where array_dtype is an EAdtype, otherwise it would fail). So from that, I think Categorical is actually more correct, apart from that it doesn't seem used anyway.
It would be good to investigate which path hits it, and see if it is possible to get there with an extension array.
CategoricalBlock.array_dtype
returnsnp.object_
, but the docstring describesarray_dtype
as "the dtype to return if I want to construct this block as an array". Shouldn't the array constructed now beCategorical
? In which case, shouldn't the dtype here beself.dtype
? (which matches the base class, and in fact makes the attribute unnecessary)The text was updated successfully, but these errors were encountered: