Skip to content

PERF: Using _Period for optimization #32973

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
Mar 30, 2020
1 change: 0 additions & 1 deletion pandas/_libs/index.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,6 @@ cdef class PeriodEngine(Int64Engine):
return scalar.value
if isinstance(scalar, Period):
# NB: we assume that we have the correct freq here.
# TODO: potential optimize by checking for _Period?
return scalar.ordinal
raise TypeError(scalar)

Expand Down