Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Replace ParmEd with Interchange in Amber/GROMACS example #1113

Merged
merged 29 commits into from
Nov 16, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
3cbe2f3
Add Interchange + GROMACS to existing GROMACS example
mattwthompson Oct 7, 2021
325a35b
Overhaul Amber + GROMACS example
mattwthompson Oct 27, 2021
a964ae6
Update conda env used by binder
mattwthompson Oct 27, 2021
f594cd4
Refactor protein-ligand examples to not use ParmEd
mattwthompson Oct 27, 2021
dd28d08
Add back ParmEd-based example
mattwthompson Oct 27, 2021
72d8352
Fix other files
mattwthompson Oct 27, 2021
fdf19b9
Rename notebooks
mattwthompson Oct 28, 2021
7b353f9
Add header notes to each notebook
mattwthompson Oct 28, 2021
6df34eb
add new example deps to example yaml
j-wags Nov 1, 2021
70cd142
Skip Interchange example when AmberTools is not installed
mattwthompson Nov 2, 2021
9b126ea
Merge remote-tracking branch 'upstream/drop-parmed-examples' into dro…
mattwthompson Nov 2, 2021
cc4b1e0
Do not assume LAMMPS and GROMACS are installed
mattwthompson Nov 2, 2021
9b9d823
Fix how GROMACS/Amber notebook is detected
mattwthompson Nov 8, 2021
109641d
Merge remote-tracking branch 'upstream/master' into drop-parmed-examples
mattwthompson Nov 8, 2021
23d674f
Debug files
mattwthompson Nov 9, 2021
5b26465
Move debug so it might get printed
mattwthompson Nov 9, 2021
eca429d
Split out Amber/GROMACS example into earlier step
mattwthompson Nov 9, 2021
511a445
Run examples with Python 3.9
mattwthompson Nov 9, 2021
618bc7b
try not using mamba in case its causing trouble with ambertools
j-wags Nov 10, 2021
db9f186
re enable mamba, force ambertools downgrade
j-wags Nov 10, 2021
637eae9
Try running it as a test script
mattwthompson Nov 10, 2021
2283dfe
Merge remote-tracking branch 'upstream/drop-parmed-examples' into dro…
mattwthompson Nov 10, 2021
f7e2d3b
Unpin AmberTools
mattwthompson Nov 10, 2021
64c4af2
Revert some debugging in workflow
mattwthompson Nov 10, 2021
7219b0b
Remove script used for debugging
mattwthompson Nov 10, 2021
5363f56
Pin to interchange v0.1.3+
mattwthompson Nov 13, 2021
e7466a4
Merge branch 'master' into drop-parmed-examples
mattwthompson Nov 16, 2021
f41cee6
Update CHANGELOG
mattwthompson Nov 16, 2021
8d62b9f
Merge remote-tracking branch 'upstream/drop-parmed-examples' into dro…
mattwthompson Nov 16, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,8 @@ jobs:
- name: Install package
shell: bash -l {0}
run: |
pip install git+https://github.com/openforcefield/openff-interchange.git@skip-drivers

Comment on lines +104 to +105
Copy link
Member Author

Choose a reason for hiding this comment

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

To be explicit: I will include this branch into a release before aiming to have this PR merged

Copy link
Member Author

Choose a reason for hiding this comment

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

This is now included in v0.1.3; CI will need to be restarted next week to get it to pass (the package will not be online until after hours)

# Remove the packaged openff-toolkit, installed as a dependency of openmmforcefields
conda remove --force openff-toolkit-base
python setup.py develop --no-deps
Expand All @@ -127,6 +129,7 @@ jobs:
NB_ARGS+=" --ignore=examples/QCArchive_interface"
NB_ARGS+=" --ignore=examples/check_dataset_parameter_coverage"
NB_ARGS+=" --ignore=examples/conformer_energies"
NB_ARGS+=" --ignore=examples/using_smirnoff_in_amber_or_gromacs"
fi
pytest $NB_ARGS examples

Expand Down
6 changes: 6 additions & 0 deletions docs/releasehistory.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ Releases follow the `major.minor.micro` scheme recommended by [PEP440](https://w
[`Molecule.to_hill_formula`](openff.toolkit.topology.Molecule.to_hill_formula) is now a class method
and no longer accepts input of NetworkX graphs.

### Examples added

- [PR #1113](https://github.com/openforcefield/openff-toolkit/pull/1113): Updates the Amber/GROMACS
example to use Interchange.


## 0.10.1 Minor feature and bugfix release

### Behaviors changed and bugfixes
Expand Down
4 changes: 4 additions & 0 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ name: binder-env
channels:
- conda-forge
- defaults
- bioconda
dependencies:
# Let conda pull in the toolkit and its deps
- openff-toolkit
Expand All @@ -13,3 +14,6 @@ dependencies:
- qcportal
- qcengine
- openmmforcefields
- openff-interchange >=0.1.2
- gromacs
- lammps
4 changes: 4 additions & 0 deletions examples/environment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,7 @@ dependencies:
- numpy
- openmm
- openff-forcefields >=2.0.0
- openff-interchange >=0.1.3
- gromacs
- lammps
- ambertools
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,17 @@
{
"cell_type": "markdown",
"metadata": {},
"source": [
" <div class=\"alert alert-block alert-info\">\n",
" <b>Note:</b> \n",
" Please take a look at the other notebook in the folder (<code>export_with_interchange.ipynb</code>), showcasing how to use OpenFF Interchange. Interchange is well-validated for small molecule interoperability with several formats and is in the process of replacing ParmEd in OpenFF workflows.</div>"
]
},
{
"cell_type": "markdown",
"metadata": {
"tags": []
},
"source": [
"## Convert Open Forcefield System to AMBER and GROMACS input files\n",
"\n",
Expand Down Expand Up @@ -40,7 +51,8 @@
" from simtk.openmm.app import PDBFile\n",
"\n",
"from openff.toolkit.topology import Molecule, Topology\n",
"from openff.toolkit.typing.engines.smirnoff import ForceField"
"from openff.toolkit.typing.engines.smirnoff import ForceField\n",
"from openff.toolkit.utils import get_data_file_path"
]
},
{
Expand All @@ -53,7 +65,9 @@
"cyclohexane = Molecule.from_smiles(\"C1CCCCC1\")\n",
"\n",
"# Obtain the OpenMM Topology object from the PDB file.\n",
"pdbfile = PDBFile(\"1_cyclohexane_1_ethanol.pdb\")\n",
"pdbfile = PDBFile(\n",
" get_data_file_path(\"systems/test_systems/1_cyclohexane_1_ethanol.pdb\")\n",
")\n",
"omm_topology = pdbfile.topology\n",
"\n",
"# Create the Open Forcefield Topology.\n",
Expand Down Expand Up @@ -82,7 +96,10 @@
},
{
"cell_type": "markdown",
"metadata": {},
"metadata": {
"jp-MarkdownHeadingCollapsed": true,
"tags": []
},
"source": [
"### Convert OpenMM System to AMBER and GROMACS files\n",
"\n",
Expand Down Expand Up @@ -263,7 +280,7 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
Expand All @@ -277,7 +294,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.6"
"version": "3.8.12"
}
},
"nbformat": 4,
Expand Down
Loading