From 358cea5ff0a5eef602ed14cb6fb36bb2edc8ccf7 Mon Sep 17 00:00:00 2001 From: svdenhau Date: Tue, 24 Oct 2023 17:09:37 +0200 Subject: [PATCH] scale slack in walltime with length of trajectory --- .github/workflows/run_pytest.yaml | 2 ++ psiflow/walkers/dynamic.py | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/run_pytest.yaml b/.github/workflows/run_pytest.yaml index 634d535..e548a3e 100644 --- a/.github/workflows/run_pytest.yaml +++ b/.github/workflows/run_pytest.yaml @@ -20,6 +20,7 @@ jobs: openmm-plumed py-plumed cp2k + spglib=2.0.* nwchem pip pytorch=1.13.1 @@ -42,5 +43,6 @@ jobs: cd ${{ runner.temp }} && git clone https://github.com/molmod/psiflow cd psiflow which cp2k.psmp + export WANDB_API_KEY=${{ secrets.WANDB_API_KEY }} pytest --skip-gpu --psiflow-config=.github/workflows/threadpool.py shell: micromamba-shell {0} diff --git a/psiflow/walkers/dynamic.py b/psiflow/walkers/dynamic.py index e32dc64..6aeaecf 100644 --- a/psiflow/walkers/dynamic.py +++ b/psiflow/walkers/dynamic.py @@ -54,7 +54,7 @@ def molecular_dynamics_yaff( command_unbuffer, command_printenv, command_write, - "timeout -s 15 {}s".format(walltime - 2), + "timeout -s 15 {}s".format(int(walltime - 5 - 0.01 * walltime)), "psiflow-md-yaff", "--device {}".format(device), "--ncores {}".format(ncores), @@ -137,7 +137,7 @@ def molecular_dynamics_openmm( command_unbuffer, command_printenv, command_write, - "timeout -s 15 {}s".format(walltime - 2), + "timeout -s 15 {}s".format(int(walltime - 5 - 0.01 * walltime)), "psiflow-md-openmm", "--device {}".format(device), "--ncores {}".format(ncores),