Skip to content

ENH: short-circuit config lookup when exact key given GH5147 #5565

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
1 commit merged into from Nov 21, 2013
Merged

ENH: short-circuit config lookup when exact key given GH5147 #5565

1 commit merged into from Nov 21, 2013

Conversation

ghost
Copy link

@ghost ghost commented Nov 21, 2013

Related #5147, #5457

before

In [4]: %timeit -r 10 pd.get_option("display.max_rows")
10000 loops, best of 10: 53.3 us per loop

after

In [1]: %timeit -r 10 pd.get_option("display.max_rows")
100000 loops, best of 10: 5.5 us per loop

jeff's version with no error checking or rerouting deprecated keys

In [1]: %timeit -r 10 pd.core.config._get_option_fast("display.max_rows")
1000000 loops, best of 10: 792 ns per loop

Probably makes no practical difference.

ghost pushed a commit that referenced this pull request Nov 21, 2013
ENH: short-circuit config lookup when exact key given GH5147
@ghost ghost merged commit eb6ef91 into pandas-dev:master Nov 21, 2013
@ghost ghost deleted the PR_GH5147_fast_config_lookup branch November 21, 2013 13:22
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants