pestifer.tasks.mdtask module¶
Definition of the MDTask class for handling molecular dynamics (MD) simulations using NAMD.
This class is a descendant of the BaseTask class and is used to run NAMD simulations,
manage the state of the simulation, and handle various aspects of the MD task such as ensembles, constraints, and colvars.
It manages the setup and execution of NAMD runs, including reading and writing necessary files,
updating artifacts, and handling the results of the simulation.
- class pestifer.tasks.mdtask.MDTask(specs: dict = None, **kwargs)[source]¶
Bases:
VMDTaskA class for handling all NAMD runs
- namdrun(baselabel='', extras={}, script_only=False, **kwargs)[source]¶
Run a NAMD simulation based on the specifications provided in the task. This method prepares the necessary parameters, writes the NAMD script, and executes it. It handles different ensembles (NPT, NVT, minimize), sets up constraints and colvars, and manages the simulation state. If script_only is True, it only writes the script without executing it.
- Parameters:
baselabel (str, optional) – The base label for the NAMD run. If not provided, it will be generated based on the ensemble type.
extras (dict, optional) – Additional parameters to be included in the NAMD script.
script_only (bool, optional) – If True, only the script will be written without executing it.
**kwargs (dict, optional) – Additional keyword arguments that may include execution options such as single_gpu_only.
- provision(packet: dict)[source]¶
Provision the MDTask with the provided packet of data. This method updates the task’s provisions with the necessary configuration for NAMD runs. It sets up the global NAMD configuration and prepares the task for execution.
- Parameters:
packet (dict) – A dictionary containing the necessary configuration data for the MDTask.