deepmd/comp format

deepmd/npy format

Class: DeePMDCompFormat

Conversions

Convert from this format to System

dpdata.System(file_name, type_map=None, fmt: Literal['deepmd/comp'] = None) dpdata.system.System
dpdata.System(file_name, type_map=None, fmt: Literal['deepmd/npy'] = None) dpdata.system.System
dpdata.System.from_deepmd_comp(file_name, type_map=None) dpdata.system.System
dpdata.System.from_deepmd_npy(file_name, type_map=None) dpdata.system.System

Convert this format to System.

Returns:
System

converted system

Convert from System to this format

dpdata.System.to(fmt: Literal['deepmd/comp'], file_name, set_size=5000, prec=<class 'numpy.float64'>)
dpdata.System.to(fmt: Literal['deepmd/comp'], file_name, set_size=5000, prec=<class 'numpy.float64'>)
dpdata.System.to_deepmd_comp(file_name, set_size=5000, prec=<class 'numpy.float64'>)
dpdata.System.to_deepmd_npy(file_name, set_size=5000, prec=<class 'numpy.float64'>)

Dump the system in deepmd compressed format (numpy binary) to folder.

The frames are firstly split to sets, then dumped to seperated subfolders named as folder/set.000, folder/set.001, ….

Each set contains set_size frames. The last set may have less frames than set_size.

Parameters:
file_namestr

The output folder

set_sizeint

The size of each set.

prec{numpy.float32, numpy.float64}

The floating point precision of the compressed data

Convert from LabeledSystem to this format

dpdata.LabeledSystem.to(fmt: Literal['deepmd/comp'], file_name, set_size=5000, prec=<class 'numpy.float64'>)
dpdata.LabeledSystem.to(fmt: Literal['deepmd/comp'], file_name, set_size=5000, prec=<class 'numpy.float64'>)
dpdata.LabeledSystem.to_deepmd_comp(file_name, set_size=5000, prec=<class 'numpy.float64'>)
dpdata.LabeledSystem.to_deepmd_npy(file_name, set_size=5000, prec=<class 'numpy.float64'>)

Dump the system in deepmd compressed format (numpy binary) to folder.

The frames are firstly split to sets, then dumped to seperated subfolders named as folder/set.000, folder/set.001, ….

Each set contains set_size frames. The last set may have less frames than set_size.

Parameters:
file_namestr

The output folder

set_sizeint

The size of each set.

prec{numpy.float32, numpy.float64}

The floating point precision of the compressed data

Convert from this format to LabeledSystem

dpdata.LabeledSystem(file_name, type_map=None, fmt: Literal['deepmd/comp'] = None) dpdata.system.LabeledSystem
dpdata.LabeledSystem(file_name, type_map=None, fmt: Literal['deepmd/npy'] = None) dpdata.system.LabeledSystem
dpdata.LabeledSystem.from_deepmd_comp(file_name, type_map=None) dpdata.system.LabeledSystem
dpdata.LabeledSystem.from_deepmd_npy(file_name, type_map=None) dpdata.system.LabeledSystem

Convert this format to LabeledSystem.

Returns:
LabeledSystem

converted system

Convert from this format to MultiSystems

dpdata.MultiSystems.from_deepmd_comp(directory) dpdata.system.MultiSystems
dpdata.MultiSystems.from_deepmd_npy(directory) dpdata.system.MultiSystems

Convert this format to MultiSystems.

Parameters:
directorystr

directory of systems

Returns:
MultiSystems

converted system

Convert from MultiSystems to this format

dpdata.MultiSystems.to(fmt: Literal['deepmd/comp'], directory) dpdata.system.MultiSystems
dpdata.MultiSystems.to(fmt: Literal['deepmd/comp'], directory) dpdata.system.MultiSystems
dpdata.MultiSystems.to_deepmd_comp(directory) dpdata.system.MultiSystems
dpdata.MultiSystems.to_deepmd_npy(directory) dpdata.system.MultiSystems

Convert MultiSystems to this format.

Parameters:
directorystr

directory to save systems

Returns:
MultiSystems

this system