-
Notifications
You must be signed in to change notification settings - Fork 744
ENH: support tpx 134 (GMX 2024.4) #4866
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
ENH: support tpx 134 (GMX 2024.4) #4866
Conversation
* Fixes MDAnalysisgh-4855. * Add support for reading topology data from `.tpr` files produced by GROMACS 2024.4, corresponding to tpx version `134`. * My approach was similar to the one I used in MDAnalysisgh-4523, except for two things: 1) I retrieved the current generation (`28`) from a `print` in our own binary parser rather than rebuilding GMX from source with added `printf`, and more importantly 2) I had to add some shims because the `.tpr` format has changed. * With regard to the additional field data now stored in the `.tpr` format, I was involved in reviewing it upstream at: https://gitlab.com/gromacs/gromacs/-/merge_requests/4544. You can see that the changes related to the MARTINI functional form made it into the `v2024.4` tag i.e., here: https://gitlab.com/gromacs/gromacs/-/blob/v2024.4/src/gromacs/gmxpreprocess/convparm.cpp?ref_type=tags#L372
|
Hello @tylerjereddy! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:
Comment last updated at 2024-12-27 17:25:12 UTC |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #4866 +/- ##
===========================================
- Coverage 93.65% 93.63% -0.03%
===========================================
Files 177 189 +12
Lines 21779 22853 +1074
Branches 3064 3067 +3
===========================================
+ Hits 20398 21399 +1001
- Misses 929 1002 +73
Partials 452 452 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
hmacdope
left a comment
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.
Tiny typo but thanks for doing this!
RMeli
left a comment
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.
LGTM besides the comment from @hmacdope.
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.
I was going through this PR and I am not able to understand why u added an elif for fver>=134. I am a bit new to this repo.
* Remove the periods (`.`) from Tyler's identifier in the `CHANGELOG` to satisfy reviewer comments.
* Add support for GROMACS `2025.0` `.tpr` version 137, which mostly involves accounting for the new PyTorch neural network potential field, `F_ENNPOT`. Most of the other changes are similar to the approach I previously used for bumping `.tpr` version support in MDAnalysisgh-4866. * Some other `.tpr` additions are noted at MDAnalysis#4888, but we don't appear to need to use those within the context of our current `.tpr` parsing tests. It may be sensible to occasionally generate `.tpr` test files that use those extra bells and whistles to see how we fare, though as a first pass here the full testsuite passes for us if we simply do the usual `gmx convert-tpr` at the latest stable GROMACS release tag `v2025.0` and propagate our current TPR testing to additionally use the converted files.
* ENH: support tpx 134 (GMX 2024.4) * Fixes MDAnalysisgh-4855. * Add support for reading topology data from `.tpr` files produced by GROMACS 2024.4, corresponding to tpx version `134`. * My approach was similar to the one I used in MDAnalysisgh-4523, except for two things: 1) I retrieved the current generation (`28`) from a `print` in our own binary parser rather than rebuilding GMX from source with added `printf`, and more importantly 2) I had to add some shims because the `.tpr` format has changed. * With regard to the additional field data now stored in the `.tpr` format, I was involved in reviewing it upstream at: https://gitlab.com/gromacs/gromacs/-/merge_requests/4544. You can see that the changes related to the MARTINI functional form made it into the `v2024.4` tag i.e., here: https://gitlab.com/gromacs/gromacs/-/blob/v2024.4/src/gromacs/gmxpreprocess/convparm.cpp?ref_type=tags#L372 * DOC: PR 4866 revisions * Remove the periods (`.`) from Tyler's identifier in the `CHANGELOG` to satisfy reviewer comments.
* Add support for GROMACS `2025.0` `.tpr` version 137, which mostly involves accounting for the new PyTorch neural network potential field, `F_ENNPOT`. Most of the other changes are similar to the approach I previously used for bumping `.tpr` version support in MDAnalysisgh-4866. * Some other `.tpr` additions are noted at MDAnalysis#4888, but we don't appear to need to use those within the context of our current `.tpr` parsing tests. It may be sensible to occasionally generate `.tpr` test files that use those extra bells and whistles to see how we fare, though as a first pass here the full testsuite passes for us if we simply do the usual `gmx convert-tpr` at the latest stable GROMACS release tag `v2025.0` and propagate our current TPR testing to additionally use the converted files.
* ENH: tpx 137 support * Add support for GROMACS `2025.0` `.tpr` version 137, which mostly involves accounting for the new PyTorch neural network potential field, `F_ENNPOT`. Most of the other changes are similar to the approach I previously used for bumping `.tpr` version support in gh-4866. * Some other `.tpr` additions are noted at #4888, but we don't appear to need to use those within the context of our current `.tpr` parsing tests. It may be sensible to occasionally generate `.tpr` test files that use those extra bells and whistles to see how we fare, though as a first pass here the full testsuite passes for us if we simply do the usual `gmx convert-tpr` at the latest stable GROMACS release tag `v2025.0` and propagate our current TPR testing to additionally use the converted files. * TST: Add GROMACS 2025.0 TPR with NNpot * Generated input file with random set of features enabled Using inputs from gromacs/src/testutils/simulationdatabase/ `gmx grompp -f tt6710474.mdp -c ala.gro -n ala.ndx -p ala.top -o ala_nnpot_gmx_2025_0.tpr` * Add Andrey to `CHANGELOG` * Apply suggestions from code review --------- Co-authored-by: Andrey Alekseenko <al42and@gmail.com>
* ENH: tpx 137 support * Add support for GROMACS `2025.0` `.tpr` version 137, which mostly involves accounting for the new PyTorch neural network potential field, `F_ENNPOT`. Most of the other changes are similar to the approach I previously used for bumping `.tpr` version support in MDAnalysisgh-4866. * Some other `.tpr` additions are noted at MDAnalysis#4888, but we don't appear to need to use those within the context of our current `.tpr` parsing tests. It may be sensible to occasionally generate `.tpr` test files that use those extra bells and whistles to see how we fare, though as a first pass here the full testsuite passes for us if we simply do the usual `gmx convert-tpr` at the latest stable GROMACS release tag `v2025.0` and propagate our current TPR testing to additionally use the converted files. * TST: Add GROMACS 2025.0 TPR with NNpot * Generated input file with random set of features enabled Using inputs from gromacs/src/testutils/simulationdatabase/ `gmx grompp -f tt6710474.mdp -c ala.gro -n ala.ndx -p ala.top -o ala_nnpot_gmx_2025_0.tpr` * Add Andrey to `CHANGELOG` * Apply suggestions from code review --------- Co-authored-by: Andrey Alekseenko <al42and@gmail.com>
Fixes Error: Your tpx version is 134, which this parser does not support, yet #4855.
Add support for reading topology data from
.tprfiles produced by GROMACS 2024.4, corresponding to tpx version134.My approach was similar to the one I used in ENH: support tpx 133 (GMX 2024.1) #4523, except for two things: 1) I retrieved the current generation (
28) from aprintin our own binary parser rather than rebuilding GMX from source with addedprintf, and more importantly 2) I had to add some shims because the.tprformat has changed.With regard to the additional field data now stored in the
.tprformat, I was involved in reviewing it upstream at: https://gitlab.com/gromacs/gromacs/-/merge_requests/4544. You can see that the changes related to the MARTINI functional form made it into thev2024.4tag i.e., here:https://gitlab.com/gromacs/gromacs/-/blob/v2024.4/src/gromacs/gmxpreprocess/convparm.cpp?ref_type=tags#L372
The new
.tprbinary assets added here were produced usinggmx convert-tpras I did for previous adjustments of this type, and I did confirm that the tests failed before adding the source code shims inutils.py.PR Checklist
Developers certificate of origin
📚 Documentation preview 📚: https://mdanalysis--4866.org.readthedocs.build/en/4866/