Skip to content

PERF: Use ccalendar.get_days_in_month over tslib.monthrange #21451

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 1 commit into from
Jun 13, 2018

Conversation

jbrockmendel
Copy link
Member

asv looks like a wash, probably to be expected since these calls make up such a small part of the methods they are used in.

tslibs.resolution uses the stdlib calendar.monthrange instead of tslib.monthrange, so the perf bump should be bigger there.

@codecov
Copy link

codecov bot commented Jun 13, 2018

Codecov Report

Merging #21451 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master   #21451   +/-   ##
=======================================
  Coverage   91.89%   91.89%           
=======================================
  Files         153      153           
  Lines       49600    49600           
=======================================
  Hits        45580    45580           
  Misses       4020     4020
Flag Coverage Δ
#multiple 90.29% <100%> (ø) ⬆️
#single 41.86% <0%> (ø) ⬆️
Impacted Files Coverage Δ
pandas/tseries/offsets.py 97% <100%> (ø) ⬆️
pandas/core/indexes/datetimes.py 95.8% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ab668b0...aecbee8. Read the comment docs.

@gfyoung gfyoung changed the title use ccalendar.get_days_in_month, deprecate tslib.monthrange PERF: Use ccalendar.get_days_in_month over tslib.monthrange Jun 13, 2018
@gfyoung gfyoung added Datetime Datetime data dtype Performance Memory or execution speed performance labels Jun 13, 2018
@gfyoung
Copy link
Member

gfyoung commented Jun 13, 2018

@jbrockmendel : Any asv-related information + whatsnew in 0.24.0 would be good here.

@jreback jreback added this to the 0.24.0 milestone Jun 13, 2018
@jreback jreback merged commit 8eb4937 into pandas-dev:master Jun 13, 2018
@jreback
Copy link
Contributor

jreback commented Jun 13, 2018

this is fine, no whatsnew needed if just internal refactoring generally (unless its 'big') or has an api impact.

@jbrockmendel jbrockmendel deleted the usecal branch June 13, 2018 14:43
david-liu-brattle-1 pushed a commit to david-liu-brattle-1/pandas that referenced this pull request Jun 18, 2018
Sup3rGeo pushed a commit to Sup3rGeo/pandas that referenced this pull request Oct 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Datetime Datetime data dtype Performance Memory or execution speed performance
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants