Skip to content
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

fix: faster picking when no slices are made #645

Merged
merged 2 commits into from
Sep 15, 2021
Merged

Conversation

henryiii
Copy link
Member

Helps with #644. Ideally, I think the order of picking and slicing should be flipped, which would probably be faster. Empty reduce should still be swapped for a copy, though, so this code code is still needed even in that case.

@github-actions github-actions bot added the needs changelog Might need a changelog entry label Sep 15, 2021
@henryiii henryiii force-pushed the henryiii/fix/slowslice branch from 3c97cdd to 4c7e151 Compare September 15, 2021 04:48
@github-actions github-actions bot removed the needs changelog Might need a changelog entry label Sep 15, 2021
@henryiii
Copy link
Member Author

henryiii commented Sep 15, 2021

Current benchmark info:

PYTHONPATH=build pytest tests/test_benchmark_category_axis.py --benchmark-enable
---------------------------------------------------------------------------------------------- benchmark 'Pick': 2 tests ----------------------------------------------------------------------------------------------
Name (time in us)               Min                     Max                    Mean                 StdDev                  Median                    IQR            Outliers         OPS            Rounds  Iterations
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
test_pick_only             469.6110 (1.0)       10,963.2400 (1.0)          548.6303 (1.0)         335.7542 (1.0)          496.3605 (1.0)          58.5930 (1.0)         7;153  1,822.7210 (1.0)        1054           1
test_pick_and_slice    752,036.0140 (>1000.0)  794,440.9860 (72.46)    768,945.9046 (>1000.0)  15,980.4104 (47.60)    764,982.2400 (>1000.0)  18,759.4093 (320.16)        2;0      1.3005 (0.00)          5           1
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

@henryiii henryiii force-pushed the henryiii/fix/slowslice branch from b07caa0 to 2e2b435 Compare September 15, 2021 14:03
@henryiii henryiii force-pushed the henryiii/fix/slowslice branch from 2e2b435 to 83520f1 Compare September 15, 2021 14:29
@henryiii henryiii merged commit 2d1ea1e into develop Sep 15, 2021
@henryiii henryiii deleted the henryiii/fix/slowslice branch September 15, 2021 14:47
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.

1 participant