import dpdata
[docs]
class DPDataInterface:
"""This is a rough interface to the dpdata library, aimed at containerizing the hdf5 data format used by
deepmd-kit. It is not a complete interface and should be used with caution.
See Also
--------
dpdata.Multisystems : The dpdata library for loading and saving systems in the hdf5 format.
"""
def __init__(self):
"""Initialize the DeepIO class."""
return
[docs]
def read(self, hdf5_file):
return dpdata.MultiSystems().load_systems_from_file(hdf5_file, fmt="deepmd/hdf5")
[docs]
def write(self):
raise NotImplementedError("The write method is not implemented in the DPDataInterface class.")