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
Make the TPR parser a bit faster #2804
Conversation
A function in the TPR parser calls list.pop thousands of times, which is slow. This commit avoids that exansive call. Taking the TPR from https://github.com/bioexcel/covid_modelling_simulation_data/tree/master/spike_protein/full_spike/trimer the parsing time on my computer goes from 25.6s to 9.39s. On a more pathological TPR file, it goes from 3 minutes to about 6s.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jbarnoud looks solid, thanks!
Codecov Report
@@ Coverage Diff @@
## develop #2804 +/- ##
===========================================
- Coverage 92.22% 92.08% -0.14%
===========================================
Files 184 183 -1
Lines 24141 23670 -471
Branches 3123 3083 -40
===========================================
- Hits 22263 21797 -466
+ Misses 1813 1808 -5
Partials 65 65
Continue to review full report at Codecov.
|
Could be backported to 1.0.1 via PR #2798. |
* Make the TPR parser a bit faster A function in the TPR parser calls list.pop thousands of times, which is slow. This commit avoids that exansive call. Taking the TPR from https://github.com/bioexcel/covid_modelling_simulation_data/tree/master/spike_protein/full_spike/trimer the parsing time on my computer goes from 25.6s to 9.39s. On a more pathological TPR file, it goes from 3 minutes to about 6s. * Update changelog for #2804 Co-authored-by: Richard Gowers <richardjgowers@gmail.com>
* Make the TPR parser a bit faster A function in the TPR parser calls list.pop thousands of times, which is slow. This commit avoids that exansive call. Taking the TPR from https://github.com/bioexcel/covid_modelling_simulation_data/tree/master/spike_protein/full_spike/trimer the parsing time on my computer goes from 25.6s to 9.39s. On a more pathological TPR file, it goes from 3 minutes to about 6s. * Update changelog for #2804 Co-authored-by: Richard Gowers <richardjgowers@gmail.com>
* Make the TPR parser a bit faster A function in the TPR parser calls list.pop thousands of times, which is slow. This commit avoids that exansive call. Taking the TPR from https://github.com/bioexcel/covid_modelling_simulation_data/tree/master/spike_protein/full_spike/trimer the parsing time on my computer goes from 25.6s to 9.39s. On a more pathological TPR file, it goes from 3 minutes to about 6s. * Update changelog for MDAnalysis#2804 Co-authored-by: Richard Gowers <richardjgowers@gmail.com>
A function in the TPR parser calls list.pop thousands of times, which is
slow. This commit avoids that exansive call.
Taking the TPR from
https://github.com/bioexcel/covid_modelling_simulation_data/tree/master/spike_protein/full_spike/trimer
the parsing time on my computer goes from 25.6s to 9.39s. On a more
pathological TPR file, it goes from 3 minutes to about 6s.
Changes made in this Pull Request:
PR Checklist
- [ ] Tests?- [ ] Docs?