class matlantis_features.features.md.md.MDFeatureResult(traj_path: Optional[str] = None, checkpoint_path: Optional[str] = None, temp_dir: Optional[TemporaryDirectory] = None)#

Bases: object

A dataclass for result of MDFeature.

Methods

__init__([traj_path, checkpoint_path, temp_dir])

from_traj_obj(traj_file_name)

Get MDFeatureResult from trajectory file.

get_traj_obj(ctxt_save_dir)

Get ASE’s trajectory reader object of the MD result.

save([traj_file_name, checkpoint_file_name])

Save the MD trajectory and checkpoint files to a different location.

__init__(traj_path: Optional[str] = None, checkpoint_path: Optional[str] = None, temp_dir: Optional[TemporaryDirectory] = None) None#
classmethod from_traj_obj(traj_file_name: str) MDFeatureResult#

Get MDFeatureResult from trajectory file.

Parameters

traj_file_name (str) – Path to the trajectory file.

Returns

MDFeatureResult.

Return type

MDFeatureResult

get_traj_obj(ctxt_save_dir: Path) TrajectoryReader#

Get ASE’s trajectory reader object of the MD result.

Parameters

ctxt_save_dir (Path) – Context’s temporary directory location.
Ignored if this obj contains trajectory path in absolute path.

Returns

TrajectoryReader object for this MD result.

Return type

TrajectoryReader

save(traj_file_name: Optional[str] = None, checkpoint_file_name: Optional[str] = None) None#

Save the MD trajectory and checkpoint files to a different location.

Parameters
  • traj_file_name (str or None, optional) – The new location of MD trajectory file. Defaults to None.

  • checkpoint_file_name (str or None, optional) – The new location of MD checkpoint file. Defaults to None.

Attributes

checkpoint_path: Optional[str] = None#
temp_dir: Optional[TemporaryDirectory] = None#
traj_path: Optional[str] = None#