Skip to content

Commit 08ecab8

Browse files
committed
fix canary tests
1 parent 83a2120 commit 08ecab8

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

canary/scripts/test_hmr.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,10 @@ def hmr_driver(mol, ff_name):
5858
collision_rate = 1.0 / unit.picoseconds
5959
timestep = 4.0 * unit.femtoseconds
6060

61-
integrator = openmm.LangevinIntegrator(temperature, collision_rate, timestep)
61+
integrator = openmm.LangevinMiddleIntegrator(temperature, collision_rate, timestep)
6262
context = openmm.Context(system, integrator)
6363
mol.generate_conformers(n_conformers=1)
64-
context.setPositions(mol.conformers[0])
64+
context.setPositions(mol.conformers[0].to_openmm())
6565

6666
# Run for 10 ps
6767
integrator.step(2500)
@@ -99,6 +99,7 @@ def hmr_driver(mol, ff_name):
9999
hmr_driver(mol, ff_name)
100100
except NANEnergyError:
101101
failed_runs.append([mol.to_smiles(), ff_name, "NaN energy"])
102+
102103
except Exception:
103104
# OpenMM's OpenMMException cannot be caught as it does not
104105
# inherit from BaseException; therefore this clause may

0 commit comments

Comments
 (0)