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

[WIP] Atomate2 support in OpenMM #717

Closed
wants to merge 12 commits into from

Conversation

orionarcher
Copy link
Contributor

@orionarcher orionarcher commented Feb 13, 2024

Summary

This PR ports over functionality from atomate2-openmm developed by @xperrylinn and myself. It includes:

  • Support for setting up OpenMM InputSets using pymatgen.io.openmm
  • Standard classical MD workflows operating on OpenMM inputsets
  • Optionally recording trajectory and simulation state information to AWS
  • Rich metadata on simulation setup for downstream analysis with Emmett

Additional dependencies introduced

  • openmm
  • openff-toolkit
  • mdanalysis
  • pymatgen.io.openmm
  • packmol
  • openbabel

These are all necessary for the classical MD setup and execution workflow.

TODO (if any)

  • Tests are not fully passing yet in atomate2
  • OpenMM input sets, which are used as the input and output of jobs, can be very large and a more compact solution is needed

Checklist

Before a pull request can be merged, the following items must be checked:

  • Code is in the standard Python style.
    The easiest way to handle this is to run the following in the correct sequence on
    your local machine. Start with running ruff and ruff format on your new code. This will
    automatically reformat your code to PEP8 conventions and fix many linting issues.
  • Doc strings have been added in the Numpy docstring format.
    Run ruff on your code.
  • Type annotations are highly encouraged. Run mypy to
    type check your code.
  • Tests have been added for any new functionality or bug fixes.
  • All linting and tests pass.

Note that the CI system will run all the above checks. But it will be much more
efficient if you already fix most errors prior to submitting the PR. It is highly
recommended that you use the pre-commit hook provided in the repository. Simply run
pre-commit install and a check will be run prior to allowing commits.

Questions:

Best way to deal with new requirements?

@utf
Copy link
Member

utf commented Feb 14, 2024

Hi @orionarcher and @xperrylinn, this looks great. Thanks for contributing this back to atomate2.

On first glance, the code looks very nice. I'll try and get some proper comments back to you in the next few days.

@orionarcher
Copy link
Contributor Author

orionarcher commented Feb 20, 2024

Thanks @utf!

Head's up that we are working to reorganize the code around the OpenFF Interchange object, which is a much closer analog to Molecule or Structure than an OpenMMInputSet, which is what we are currently using. This should let us better delineate what is being simulated vs the details of the simulation. Much of the OpenMM code will remain the same but the basic input and output of jobs will change. I'm hoping to add that to the PR in the next week or so. May be best to hold off on a close review until then.

@utf
Copy link
Member

utf commented Feb 22, 2024

Ok, thanks for the heads up. I'll hold off reviewing for now. Let me know when you want me to take a look.

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