From 3907a54dad4a4bd281c77166b5f2bbebbde0e8ab Mon Sep 17 00:00:00 2001 From: shazj99 Date: Tue, 26 Oct 2021 08:20:29 +0800 Subject: [PATCH] remove jr.json to allow rerun in autotest make (#579) Change-Id: I26e8f7120703f131ffb005e4c0c927c108821ae0 Co-authored-by: Zhengju Sha --- dpgen/auto_test/common_equi.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dpgen/auto_test/common_equi.py b/dpgen/auto_test/common_equi.py index d5dba8227..ce5df94e8 100644 --- a/dpgen/auto_test/common_equi.py +++ b/dpgen/auto_test/common_equi.py @@ -79,6 +79,9 @@ def make_equi(confs, poscar = os.path.abspath(os.path.join(ii, 'POSCAR')) if not os.path.exists(poscar): raise FileNotFoundError('no configuration for autotest') + if os.path.exists(os.path.join(ii, 'relaxation', 'jr.json')): + os.remove(os.path.join(ii, 'relaxation', 'jr.json')) + relax_dirs = os.path.abspath(os.path.join(ii, 'relaxation', 'relax_task')) # to be consistent with property in make dispatcher create_path(relax_dirs) task_dirs.append(relax_dirs)