Hello:
I encountered the following error when I try to prepare training data from the CP2K MD calculation with the dpdata plugin. I have the following output files in my working directory: energy.out (main output file), qmworks-cp2k-1.ener, qmworks-cp2k-1.cell, qmworks-cp2k-frc-1.xyz, qmworks-cp2k-pos-1.xyz, qmworks-cp2k-1.stress
CP2K VERSION: 6.1
Can you please provide some suggestions to resolve this error.
import dpdata
cp2kmd_dir = "./test"
cp2kmd_output_name = "energy.out"
dp = dpdata.LabeledSystem(cp2kmd_dir, cp2k_output_name=cp2kmd_output_name, fmt="cp2kdata/md")
--- You are parsing data using package Cp2kData ---
Traceback (most recent call last):
File "", line 1, in
File "/afs/enea.it/por/user/irpannee/miniconda3/envs/deepmd/lib/python3.10/site-packages/dpdata/system.py", line 281, in init
self.from_fmt(
File "/afs/enea.it/por/user/irpannee/miniconda3/envs/deepmd/lib/python3.10/site-packages/dpdata/system.py", line 318, in from_fmt
return self.from_fmt_obj(load_format(fmt), file_name, kwargs)
File "/afs/enea.it/por/user/irpannee/miniconda3/envs/deepmd/lib/python3.10/site-packages/dpdata/system.py", line 1162, in from_fmt_obj
data = fmtobj.from_labeled_system(file_name, kwargs)
File "/afs/enea.it/por/user/irpannee/miniconda3/envs/deepmd/lib/python3.10/site-packages/cp2kdata/dpdata_plugin.py", line 71, in from_labeled_system
cp2kmd = Cp2kOutput(output_file=cp2k_output_name, run_type="MD", path_prefix=path_prefix)
File "/afs/enea.it/por/user/irpannee/miniconda3/envs/deepmd/lib/python3.10/site-packages/cp2kdata/output.py", line 100, in init
Parse_Run_Type[self.GlobalInfo.run_type]()
File "/afs/enea.it/por/user/irpannee/miniconda3/envs/deepmd/lib/python3.10/site-packages/cp2kdata/output.py", line 390, in parse_md
self.num_frames = len(self.energies_list)
AttributeError: 'Cp2kOutput' object has no attribute 'energies_list'. Did you mean: 'get_energies_list'?
Hello, I think it should work. Your code looks well. But it seems the code didn't find the "ener" file. Can you send me the files or have you manage to convert it?
Hello: I encountered the following error when I try to prepare training data from the CP2K MD calculation with the dpdata plugin. I have the following output files in my working directory: energy.out (main output file), qmworks-cp2k-1.ener, qmworks-cp2k-1.cell, qmworks-cp2k-frc-1.xyz, qmworks-cp2k-pos-1.xyz, qmworks-cp2k-1.stress
CP2K VERSION: 6.1
Can you please provide some suggestions to resolve this error.