Merge branch 'main' into maint/remove_element_change_warning

This commit is contained in:
Irfan Alibay
2026-05-21 19:57:57 +01:00
committed by GitHub
26 changed files with 119 additions and 309 deletions

View File

@@ -3,16 +3,16 @@ Checklist for releasing a new version of openfe.
-->
Make the PR:
* [ ] Create a new release-prep branch corresponding to the version name, e.g. `release-prep-v1.2.0`. Note: please follow [semantic versioning](https://semver.org/).
* [ ] Create a new release prep branch corresponding to the version name, e.g. `release/v1.2.0`. Note: please follow [semantic versioning](https://semver.org/).
* [ ] Check that all user-relevant updates are included in the `news/` rever `.rst` files. You can backfill any additional items by making a new .rst, e.g. `backfill.rst`
* [ ] Run [rever](https://regro.github.io/rever-docs/index.html#), e.g. `rever 1.2.0`. This will auto-commit `docs/CHANGELOG.md` and remove the `.rst` files from `news/`.
* [ ] Verify that`docs/CHANGELOG.rst` looks correct.
* [ ] Verify that`docs/CHANGELOG.rst` looks correct and that it renders as expected in the docs preview.
* [ ] If needed, create a release of the [example notebooks repository](https://github.com/OpenFreeEnergy/ExampleNotebooks) and update the pinned release version in the `openfe/docs/conf.py`.
* [ ] Make the PR and verify that CI/CD passes.
* [ ] (feedstock packaging tests)[https://github.com/OpenFreeEnergy/openfe/actions/workflows/release-prep-feedstock.yaml]
* [ ] (example notebooks)[https://github.com/OpenFreeEnergy/openfe/actions/workflows/release-prep-examplenotebooks.yaml]
* [ ] (GPU tests)[https://github.com/OpenFreeEnergy/openfe/actions/workflows/aws-gpu-integration-tests.yaml]
* [ ] [feedstock packaging tests](https://github.com/OpenFreeEnergy/openfe/actions/workflows/release-prep-feedstock.yaml)
* [ ] [example notebooks](https://github.com/OpenFreeEnergy/openfe/actions/workflows/release-prep-examplenotebooks.yaml)
* [ ] [GPU tests](https://github.com/OpenFreeEnergy/openfe/actions/workflows/aws-gpu-integration-tests.yaml)
* [ ] Merge the PR into `main`.
* [ ] Make a PR into the [example notebooks repository](https://github.com/OpenFreeEnergy/ExampleNotebooks) to update the version used in `showcase/openfe_showcase.ipynb` and `.binder/environment.yml`
After Merging the PR [follow this guide](https://github.com/OpenFreeEnergy/openfe/wiki/How-to-create-a-new-release)

View File

@@ -4,6 +4,58 @@ Changelog
.. current developments
v1.11.1
====================
**Fixed:**
* Fixed slow response time of CLI commands (`PR #1972 <https://github.com/OpenFreeEnergy/openfe/pull/1972>`_).
v1.11.0
====================
* **openfe v1.11.0** introduces support for protein-membrane systems both with the Python API and the CLI. See our tutorial `RBFE calculations of a Protein-Membrane System <https://docs.openfree.energy/en/latest/tutorials/rbfe_membrane_protein.html>`_ for details.
The `ability to resume execution of incomplete transformations <https://docs.openfree.energy/en/v1.10.0/guide/execution/quickrun_execution.html>`_ that was introduced in ``openfe v1.10.0`` is now available for the plain MD and SepTop protocols.
See below for the full changelog for this release:
**Added:**
* Added support for systems with membranes to the following protocols:
PlainMDProtocol, RelativeHybridTopologyProtocol, SepTopProtocol, and AbsoluteBindingProtocol (`PR #1561 <https://github.com/OpenFreeEnergy/openfe/pull/1561>`_).
* Added support for membrane systems to ``openfe plan-rbfe-network``.
Use ``--protein-membrane`` instead of the ``--protein`` argument, and see the tutorial on preparing membrane systems (`PR #1896 <https://github.com/OpenFreeEnergy/openfe/pull/1896>`_).
* Added API support for resuming the PlainMDProtocol (`PR #1884 <https://github.com/OpenFreeEnergy/openfe/pull/1884>`_).
* Added API support for resuming the SepTopProtocol. (`PR #1949 <https://github.com/OpenFreeEnergy/openfe/pull/1949>`_).
* The ``validate`` method for the SepTopProtocol has been implemented.
This means that settings and system validation can mostly be done prior to Protocol execuation by calling ``SepTopProtocol.validate(stateA, stateB, mapping=None)`` (`PR #1946 <https://github.com/OpenFreeEnergy/openfe/pull/1946>`_).
**Changed:**
* The SepTopProtocol now has a dedicated Analysis unit.
At the top level API, this does not change behavior, but if you are directly interfacing with th ProtocolUnits, you will have to account for this change.
The SepTopProtocolResult now solely uses the Analysis units (`PR #1937 <https://github.com/OpenFreeEnergy/openfe/pull/1937>`_).
* Updated the chemical systems user guide and the defining protocols user guide to reflect recent protocol updates, including adding membrane support (`PR #1933 <https://github.com/OpenFreeEnergy/openfe/pull/1933>`_).
* The default value for the Hybrid TopologyProtocol setting ``turn_off_core_unique_exceptions`` has been changed to ``True``.
This means 1-4 interactions involving the unique alchemical atoms and core regions will now be interpolated on/off accordingly by default (`PR #1856 <https://github.com/OpenFreeEnergy/openfe/pull/1856>`_).
**Deprecated:**
* Perses atom mapper and scorer functionality is deprecated, now slated to be removed in ``openfe v1.12``.
This includes ``PersesAtomMapper`` and ``default_perses_scorer`` (`PR #1857 <https://github.com/OpenFreeEnergy/openfe/pull/1857>`_).
**Fixed:**
* Fix erroneous logging information message which would mention setting up the alchemical system when running simulation or analysis units with the hybrid topology, AHFE or ABFE Protocols (`PR #1915 <https://github.com/OpenFreeEnergy/openfe/pull/1915>`_).
* System equality checks on resuming no longer expect complete equality in the force parameters.
This fixes a scenario where small changes in precision due to running on different machines would prevent users from restarting their simulations (`PR #1914 <https://github.com/OpenFreeEnergy/openfe/pull/1914>`_).
v1.10.0
====================
@@ -19,7 +71,7 @@ See the `quickrun documentation <https://docs.openfree.energy/en/v1.10.0/guide/e
**Deprecated:**
* Perses atom mapper and scorer functionality is deprecated, slated to be removed in ``openfe v2.0``.
* Perses atom mapper and scorer functionality is deprecated, slated to be removed in ``openfe v2.0``.
This includes ``PersesAtomMapper`` and ``default_perses_scorer`` (`PR #1857 <https://github.com/OpenFreeEnergy/openfe/pull/1857>`_).
**Fixed:**
@@ -90,7 +142,7 @@ v1.8.0
**Added:**
* The ``HybridTopologyFactory`` supports building hybrid OpenMM systems which contain ``CMAPTorsionForces`` on non-alchemical atoms.
* The ``HybridTopologyFactory`` supports building hybrid OpenMM systems which contain ``CMAPTorsionForces`` on non-alchemical atoms.
This should allow for simulations using Amber ff19SB (`PR #1695 <https://github.com/OpenFreeEnergy/openfe/pull/1695>`_).
* Added experimental features ``openfe gather-septop`` and ``openfe gather-abfe``, which are analogous to ``openfe gather`` and allow for gathering results generated by the Separated Topologies and Absolute Binding Free Energy protocols, respectively. These commands are experimental and are liable to be changed in a future release.
* Emit a clarifying log message when a user gets a warning from JAX (`PR #1585 <https://github.com/OpenFreeEnergy/openfe/pull/1585>`_, fixes `Issue #1499 <https://github.com/OpenFreeEnergy/openfe/issues/1499>`_).

View File

@@ -193,7 +193,7 @@ try:
else:
repo = git.Repo.clone_from(
"https://github.com/OpenFreeEnergy/ExampleNotebooks.git",
branch="main", # TODO: update this after making ExampleNotebooks release
branch="2026.04.28",
to_path=example_notebooks_path,
)
except Exception as e:

View File

@@ -6,8 +6,7 @@ See `Supported Hardware`_ for more details.
We try to follow `SPEC0 <https://scientific-python.org/specs/spec-0000/>`_ as far as minimum supported dependencies, with the following caveats:
- OpenMM 8.0, 8.1.2, 8.2.0 - **we do not yet support OpenMM v8.3.0**
- ``OpenEye Toolkits`` is not yet compatible with Python 3.13, so **openfe** cannot use openeye functionality with Python 3.13.
- OpenMM 8.0, 8.1.2, 8.2, and 8.4 - **OpenMM v8.3.0 is not supported**
When you install **openfe** through any of the methods described below, you will install both the core library and the command line interface (CLI).
@@ -417,7 +416,7 @@ functionality. This is called a "developer" or "editable" installation.
Getting a developer installation for **openfe** first installing the
requirements, and then creating the editable installation. We recommend
doing that with ``mamba`` using the following procedure:
doing that with ``micromamba`` using the following procedure:
First, clone the **openfe** repository, and switch into its root directory::
@@ -427,11 +426,11 @@ First, clone the **openfe** repository, and switch into its root directory::
Next create a ``conda`` environment containing the requirements from the
specification in that directory::
$ mamba create -f environment.yml
$ micromamba create -f environment.yml
Then activate the **openfe** environment with::
Then activate the openfe environment with::
$ mamba activate openfe
$ micromamba activate openfe_env
Finally, create the editable installation::

View File

@@ -19,7 +19,7 @@ dependencies:
- openff-toolkit-base >=0.16.2
- openff-units==0.3.1 # https://github.com/OpenFreeEnergy/openfe/pull/1374
- openmm ~=8.4.0 # omit 8.3.0 and 8.3.1 due to https://github.com/openmm/openmm/pull/5069
- openmmforcefields >=0.15.1 # min needed for https://github.com/OpenFreeEnergy/openfe/pull/414
- openmmforcefields >=0.15.1 # min needed for https://github.com/openmm/openmmforcefields/pull/414
- openmmtools >=0.26 # fix to support membrane barostat: https://github.com/choderalab/openmmtools/pull/798
- packaging
- pandas

25
news/afe-uuid.rst Normal file
View File

@@ -0,0 +1,25 @@
**Added:**
* <news item>
**Changed:**
* AFE Protocols (AbsoluteBindingProtocol and AbsoluteSolvationProtocol)
now assign a single uuid for all ProtocolUnits in a repeat rather than
separating the uuid by legs of the transformation. PR #1948
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -1,27 +0,0 @@
**Added:**
* <news item>
**Changed:**
* The SepTopProtocol now has a dedicated Analysis unit.
At the top level API, this does not change behaviour, but
if you are directly interfacing with the ProtocolUnits, you
will have to account for this change. The SepTopProtocolResult now
solely uses the Analysis units. PR #1937
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -1,24 +0,0 @@
**Added:**
* <news item>
**Changed:**
* <news item>
**Deprecated:**
* Perses atom mapper and scorer functionality is deprecated, now slated to be removed in ``openfe v1.12``.
This includes ``PersesAtomMapper`` and ``default_perses_scorer`` (`PR #1857 <https://github.com/OpenFreeEnergy/openfe/pull/1857>`_).
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -1,25 +0,0 @@
**Added:**
* <news item>
**Changed:**
* <news item>
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* Fix erroneous logging information message which would mention
setting up the alchemical system when running simulation or
analysis units with the hybrid topology, AHFE or ABFE Protocols (PR #1915).
**Security:**
* <news item>

View File

@@ -1,23 +0,0 @@
**Added:**
* <news item>
**Changed:**
* The default value for the Hybrid TopologyProtocol setting ``turn_off_core_unique_exceptions`` has been changed to ``True`. This means 1-4 interactions involving the unique alchemical atoms and core regions will now be interpolated on/off accordingly by default PR #1856.
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -1,26 +0,0 @@
**Added:**
* <news item>
**Changed:**
* <news item>
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* System equality checks on resuming no longer expect complete equality
in the force parameters. This fixes a scenario where small changes
in precision due to running on different machines would prevent users from
restarting their simulations (Issue #1913, PR #1914).
**Security:**
* <news item>

View File

@@ -1,24 +0,0 @@
**Added:**
* Added support for systems with membranes to the following protocols:
PlainMDProtocol, RelativeHybridTopologyProtocol, SepTopProtocol, and AbsoluteBindingProtocol.
**Changed:**
* <news item>
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -1,24 +0,0 @@
**Added:**
* Added support for membrane systems to ``openfe plan-rbfe-network``.
Use ``--protein-membrane`` instead of the ``--protein`` argument, and see the tutorial on preparing membrane systems (`PR #1896 <https://github.com/OpenFreeEnergy/openfe/pull/1896>`_).
**Changed:**
* <news item>
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -1,24 +0,0 @@
**Added:**
* * Added API support for resuming the PlainMDProtocol.
PR #1884.
**Changed:**
* <news item>
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -1,24 +0,0 @@
**Added:**
* Added API support for resuming the SepTopProtocol.
PR #1949.
**Changed:**
* <news item>
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -1,23 +0,0 @@
**Added:**
* <news item>
**Changed:**
* Updated the chemical systems user guide and the defining protocols user guide to reflect recent protocol updates, including adding membrane support.
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -1,26 +0,0 @@
**Added:**
* The `validate` method for the SepTopProtocol has been implemented.
This means that settings and system validation can mostly be done prior
to Protocol execuation by calling
`SepTopProtocol.validate(stateA, stateB, mapping=None)`.
**Changed:**
* <news item>
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View File

@@ -502,10 +502,9 @@ class AbsoluteBindingProtocol(gufe.Protocol):
protocol_units: dict[str, list[gufe.ProtocolUnit]] = {"solvent": [], "complex": []}
for phase in ["solvent", "complex"]:
for i in range(self.settings.protocol_repeats):
repeat_id = int(uuid.uuid4())
for i in range(self.settings.protocol_repeats):
repeat_id = int(uuid.uuid4())
for phase in ["solvent", "complex"]:
setup = unit_classes[phase]["setup"](
protocol=self,
stateA=stateA,

View File

@@ -466,10 +466,9 @@ class AbsoluteSolvationProtocol(gufe.Protocol):
protocol_units: dict[str, list[gufe.ProtocolUnit]] = {"solvent": [], "vacuum": []}
for phase in ["solvent", "vacuum"]:
for i in range(self.settings.protocol_repeats):
repeat_id = int(uuid.uuid4())
for i in range(self.settings.protocol_repeats):
repeat_id = int(uuid.uuid4())
for phase in ["solvent", "vacuum"]:
setup = unit_classes[phase]["setup"](
protocol=self,
stateA=stateA,

View File

@@ -158,8 +158,8 @@ def test_create_independent_repeat_ids(benzene_modifications, T4_protein_compone
for u in dag.protocol_units:
repeat_ids.add(u.inputs["repeat_id"])
# squashed by repeat_id, that's 2 sets of 6
assert len(repeat_ids) == 12
# squashed by repeat_id, that's 1 uuid per repeat
assert len(repeat_ids) == 6
def test_mda_universe_error():

View File

@@ -142,8 +142,8 @@ def test_create_independent_repeat_ids(benzene_system):
for u in dag.protocol_units:
repeat_ids.add(u.inputs["repeat_id"])
# squashed by repeat_id, that's 2 sets of 6
assert len(repeat_ids) == 12
# squashed by repeat_id, that's 1 uuid by repeat
assert len(repeat_ids) == 6
def _assert_num_forces(system, forcetype, number):

View File

@@ -6,7 +6,6 @@ from typing import List, Literal
import click
import numpy as np
import pandas as pd
from openff.units import unit
from openfecli import OFECommandPlugin
from openfecli.clicktypes import HyphenAwareChoice
@@ -108,6 +107,8 @@ def _get_legs_from_result_jsons(
"""
from collections import defaultdict
from openff.units import unit
dgs = defaultdict(lambda: defaultdict(list))
for result_fn in result_fns:

View File

@@ -6,8 +6,6 @@ from typing import List, Literal
import click
import numpy as np
import pandas as pd
from cinnabar import FEMap, Measurement
from openff.units import unit
from openfecli import OFECommandPlugin
from openfecli.clicktypes import HyphenAwareChoice
@@ -84,6 +82,8 @@ def _get_legs_from_result_jsons(
"""
from collections import defaultdict
from openff.units import unit
ddgs = defaultdict(lambda: defaultdict(list))
for result_fn in result_fns:
@@ -253,6 +253,8 @@ def _generate_dg_mle(
pd.DataFrame
A pandas DataFrame with the dG results for each ligand pair.
"""
from cinnabar import FEMap, Measurement
from openff.units import unit
DDGs = _get_ddgs(results_dict)

View File

@@ -4,11 +4,7 @@ import sys
import click
import pytest
from openfe.data import _downloader
from openfe.data._registry import zenodo_data_registry as api_test_data_registry
from openfecli import OFECommandPlugin
from openfecli.data._registry import POOCH_CACHE
from openfecli.data._registry import zenodo_data_registry as cli_test_data_registry
from openfecli.utils import write
@@ -34,7 +30,13 @@ def test(long, download_only):
"""
if download_only:
from openfe.data import _downloader
from openfe.data._registry import zenodo_data_registry as api_test_data_registry
from openfecli.data._registry import POOCH_CACHE
from openfecli.data._registry import zenodo_data_registry as cli_test_data_registry
click.echo(f"Checking for test data in cache location:\n{POOCH_CACHE}")
_downloader.retrieve_registry_data(
cli_test_data_registry + api_test_data_registry, POOCH_CACHE
)

View File

@@ -6,8 +6,6 @@ from typing import Iterable
import click
from plugcli.params import Option
from openfe import ProteinComponent, ProteinMembraneComponent
_PDB_EXT = [".pdb"]
_PDBX_EXT = [".cif", ".pdbx"]
@@ -16,7 +14,7 @@ def _contains_any_substring(input: str, substrings: Iterable[str]) -> bool:
return any([substring in input for substring in substrings])
def _load_protein_from_file(input_file, protein_class: ProteinComponent | ProteinMembraneComponent):
def _load_protein_from_file(input_file, protein_class):
valid_ext = _PDB_EXT + _PDBX_EXT
info_str = (
f"Unable to load a {protein_class.__name__} from {click.format_filename(input_file)}: "
@@ -34,10 +32,14 @@ def _load_protein_from_file(input_file, protein_class: ProteinComponent | Protei
# TODO: these functions are shims to work with plugcli. We should consider migrating to just click.
def _get_protein(user_input, context):
from openfe import ProteinComponent
return _load_protein_from_file(user_input, ProteinComponent)
def _get_protein_membrane(user_input, context):
from openfe import ProteinMembraneComponent
return _load_protein_from_file(user_input, ProteinMembraneComponent)

View File

@@ -2,7 +2,6 @@
# For details, see https://github.com/OpenFreeEnergy/openfe
from __future__ import annotations
import json
import pathlib
from openfe import AlchemicalNetwork, LigandNetwork