-
Notifications
You must be signed in to change notification settings - Fork 11
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
Integration of OpenMM #87
Conversation
a570288
to
75d04e9
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #87 +/- ##
==========================================
+ Coverage 65.10% 68.26% +3.16%
==========================================
Files 50 51 +1
Lines 4662 4847 +185
==========================================
+ Hits 3035 3309 +274
+ Misses 1627 1538 -89
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
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.
The code looks good, thanks! I have only a minor comment regarding triggering a NotImplemented error. If it is too much work to implement, we can merge the code without it.
Dear all, I just have one comment, for now OpenMM only support MACE, correct me if I am wrong. Do we need to ensure that we have MACE before running OpenMM dynamics? |
Hi @Hanwen1018, Indeed, OpenMM-ML currently only supports MACE (and ANI, but that MLP is not part of mlp-train). MACE is installed when running https://github.com/openmm/openmm-ml/blob/main/openmmml/models/macepotential.py#L136-L143 Additionally, if you install the other environments ( https://github.com/JMorado/mlp-train/blob/openmm-features/mlptrain/sampling/md_openmm.py#L210-L220 Could you please clarify what you are suggesting? |
Thank you for clarification. I want to add a checking step before run OpenMM. It is not about whether MACE is installed. I want to check it is the MACE potential used in the _create_openmm_simulation function. As in _create_openmm_simulation, the argument is mlp (belong to mlt.potentials._base.MLPotential), which can also be ACE or GAP, and will make issue. |
I understand your point. In such a scenario, OpenMM-ML might throw an error that isn't very informative. I agree that an additional check would be beneficial. I'll implement that. Thanks! |
This is probably part of the same issue. For example, when I activate the mace environment and specify ACE in AL, it will still train the ACE and the code will fail only after the training is finished - it is a similar issue as with the plumed check when the error was triggered after the training. The environments are quite similar and on my system, the ACE training finished even though I activated a different environment (which is not great tbh). So the MLP type check should be able to resolve also this. |
This PR builds upon previous features introduced in PR #55, implementing the following changes:
md.py
, aiming for uniformity, consistency, and improved readability