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

Speeding up tests #190

Merged
merged 2 commits into from
Apr 24, 2023
Merged

Speeding up tests #190

merged 2 commits into from
Apr 24, 2023

Conversation

rosecers
Copy link
Collaborator

@rosecers rosecers commented Apr 24, 2023

I'll go one by one from #174 and leave this on draft til I'm through. Started with pcovcur and reduced the datasize.


📚 Documentation preview 📚: https://scikit-matter--190.org.readthedocs.build/en/190/

@rosecers
Copy link
Collaborator Author

@PicoCentauri There was a patch in KernelPCovR that should speed up a lot of things. Can you re-benchmark and see how we're doing?

@rosecers rosecers requested a review from PicoCentauri April 24, 2023 17:27
@PicoCentauri
Copy link
Collaborator

I ran the tests with

tox -e tests -- --durations=5 tests/test_kernel_pcovr.py tests/test_sample_pcov_cur.py

and got for the main branch

807.39s call     tests/test_sample_pcov_cur.py::TestPCovCUR::test_multiple_k
211.64s call     tests/test_kernel_pcovr.py::KernelPCovRTestSVDSolvers::test_svd_solvers
25.62s call     tests/test_kernel_pcovr.py::KernelPCovRErrorTest::test_kpcovr_error
25.01s call     tests/test_kernel_pcovr.py::KernelTests::test_kernel_types
23.54s call     tests/test_kernel_pcovr.py::KernelPCovRErrorTest::test_reconstruction_errors

and for the speedup_tests branch

7.86s call     tests/test_kernel_pcovr.py::KernelPCovRTestSVDSolvers::test_svd_solvers
5.92s call     tests/test_sample_pcov_cur.py::TestPCovCUR::test_multiple_k
3.09s call     tests/test_kernel_pcovr.py::KernelPCovRErrorTest::test_reconstruction_errors
2.91s call     tests/test_kernel_pcovr.py::KernelPCovRErrorTest::test_kpcovr_error
2.85s call     tests/test_kernel_pcovr.py::KernelPCovRTestSVDSolvers::test_good_n_components

So it is mhuuuuch better. The CI tests now also only take a minute!

@rosecers rosecers marked this pull request as ready for review April 24, 2023 20:46
@rosecers
Copy link
Collaborator Author

Great! With your approval we can merge

Copy link
Collaborator

@PicoCentauri PicoCentauri left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🫶

@rosecers rosecers merged commit abbb3ff into main Apr 24, 2023
@rosecers rosecers deleted the speedup_tests branch April 24, 2023 21:25
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.

2 participants