Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modify the post_fp_cp2k function to generate multisystem data. Allows to run different system at one single iteration model_devi step. #1513

Merged
merged 7 commits into from
Apr 12, 2024
11 changes: 6 additions & 5 deletions dpgen/generator/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -4437,14 +4437,15 @@ def post_fp_cp2k(iter_index, jdata, rfailed=None):
sys_output = glob.glob(os.path.join(work_path, "task.%s.*/output" % ss))
sys_output.sort()
tcount += len(sys_output)
all_sys = None
all_sys = dpdata.MultiSystems(type_map=jdata["type_map"])
for oo in sys_output:
_sys = dpdata.LabeledSystem(oo, fmt="cp2k/output")
# _sys.check_type_map(type_map = jdata['type_map'])
if all_sys is None:
all_sys = _sys
else:
all_sys.append(_sys)
# if all_sys is None:
# all_sys = _sys
# else:
# all_sys.append(_sys)
all_sys.append(_sys)

icount += len(all_sys)
if (all_sys is not None) and (len(all_sys) > 0):
Expand Down
Loading