From 4de01ef34ff5cefd0034be0bf402bfb27d51599f Mon Sep 17 00:00:00 2001 From: Mike Henry <11765982+mikemhenry@users.noreply.github.com> Date: Tue, 8 Oct 2024 12:20:43 -0700 Subject: [PATCH 1/3] Don't warn if using HIP --- openfe/protocols/openmm_rfe/_rfe_utils/compute.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openfe/protocols/openmm_rfe/_rfe_utils/compute.py b/openfe/protocols/openmm_rfe/_rfe_utils/compute.py index b3bee28f6..987ecdedc 100644 --- a/openfe/protocols/openmm_rfe/_rfe_utils/compute.py +++ b/openfe/protocols/openmm_rfe/_rfe_utils/compute.py @@ -50,7 +50,7 @@ def get_openmm_platform(platform_name=None): platform.setPropertyDefaultValue( 'DeterministicForces', 'true') - if name != 'CUDA': + if name not in ['CUDA', 'HIP']: wmsg = (f"Non-GPU platform selected: {name}, this may significantly " "impact simulation performance") warnings.warn(wmsg) From e806bc323c3fbe2e1c7f35712076ec485b70568e Mon Sep 17 00:00:00 2001 From: Mike Henry <11765982+mikemhenry@users.noreply.github.com> Date: Tue, 8 Oct 2024 12:22:12 -0700 Subject: [PATCH 2/3] add news item --- news/support_hip.rst | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 news/support_hip.rst diff --git a/news/support_hip.rst b/news/support_hip.rst new file mode 100644 index 000000000..74fb4f69f --- /dev/null +++ b/news/support_hip.rst @@ -0,0 +1,23 @@ +**Added:** + +* HIP Platform Support + +**Changed:** + +* + +**Deprecated:** + +* + +**Removed:** + +* + +**Fixed:** + +* + +**Security:** + +* From 5b5953b61d15bf2844c6aa5a0df07379fc216f76 Mon Sep 17 00:00:00 2001 From: Mike Henry <11765982+mikemhenry@users.noreply.github.com> Date: Tue, 29 Oct 2024 10:51:50 -0700 Subject: [PATCH 3/3] set percision and DeterministicForces for hip --- openfe/protocols/openmm_rfe/_rfe_utils/compute.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/openfe/protocols/openmm_rfe/_rfe_utils/compute.py b/openfe/protocols/openmm_rfe/_rfe_utils/compute.py index 987ecdedc..d325b070c 100644 --- a/openfe/protocols/openmm_rfe/_rfe_utils/compute.py +++ b/openfe/protocols/openmm_rfe/_rfe_utils/compute.py @@ -35,6 +35,7 @@ def get_openmm_platform(platform_name=None): 'cpu': 'CPU', 'opencl': 'OpenCL', 'cuda': 'CUDA', + 'hip': 'HIP', }[str(platform_name).lower()] except KeyError: pass @@ -43,10 +44,10 @@ def get_openmm_platform(platform_name=None): platform = Platform.getPlatformByName(platform_name) # Set precision and properties name = platform.getName() - if name in ['CUDA', 'OpenCL']: + if name in ['CUDA', 'OpenCL', 'HIP']: platform.setPropertyDefaultValue( 'Precision', 'mixed') - if name == 'CUDA': + if name in ['CUDA', 'HIP']: platform.setPropertyDefaultValue( 'DeterministicForces', 'true')