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

CI/TST #34131 fixed test_floordiv_axis0_numexpr_path #34537

Conversation

OlivierLuG
Copy link
Contributor

@OlivierLuG OlivierLuG commented Jun 2, 2020

xref #34131

  • [ x ] passes black pandas
  • [ x ] passes git diff upstream/master -u -- "*.py" | flake8 --diff

Test /pandas/tests/frame/test_floordiv_axis0_numexpr_path is slow. It builds a df with 10^6 elements to tests functions floordiv and pow. The number of elements can be reduced with keeping the same min/max values inside the dataframe.

Before/after timeit comparison:

26.6 s ± 1.04 s per loop (mean ± std. dev. of 7 runs, 1 loop each)
37.6 ms ± 3.45 ms per loop (mean ± std. dev. of 7 runs, 10 loops each)

@OlivierLuG OlivierLuG requested a review from jbrockmendel June 7, 2020 08:58
@OlivierLuG
Copy link
Contributor Author

I did it : green light :-D I had hard time with it !!!

Summary:
The tests are skipped if numexpr is not installed. Otherwise, the entry dataframe is built to construct the minimum of element to reduce the duration of the test.

@jreback jreback added the Testing pandas testing functions or related to the test suite label Jun 14, 2020
@jreback jreback added this to the 1.1 milestone Jun 14, 2020
@jreback
Copy link
Contributor

jreback commented Jun 14, 2020

this is ok, ping on green.

@jreback jreback merged commit a97bddd into pandas-dev:master Jun 14, 2020
@jreback
Copy link
Contributor

jreback commented Jun 14, 2020

thanks @OlivierLuG

@OlivierLuG OlivierLuG deleted the CI_#34131_slow_test_floordiv_axis0_numexpr_path branch January 2, 2021 08:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Testing pandas testing functions or related to the test suite
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants