md.calculators.MDCalculator

class md.calculators.MDCalculator(*args: Any, **kwargs: Any)[source]

Base MDCalculator class for computing and updating the forces of the simulated system, as well as other properties predicted by the model.

Parameters:
  • required_properties (list) – List of the property names which will be passed to the simulator

  • force_key (str) – Name of the property corresponding to the forces.

  • energy_unit (str, float) – Energy units returned by the internal computation model.

  • position_unit (str, float) – Unit conversion for the length used in the model computing all properties. E.g. if the model needs Angstrom, one has to provide the conversion factor converting from the atomic units used internally (Bohr) to Angstrom: 0.529177. Is used together with energy_unit to determine units of force and stress.

  • energy_key (str, optional) – Name of the property corresponding to the energy.

  • stress_key (str, optional) – Name of the property corresponding to the stress.

  • property_conversion (dict(float, str)) – Optional dictionary of conversion factors for other properties predicted by the model. Only changes the units used for logging the various outputs.

  • gradients_required (bool) – If set to true, enable accumulation of computational graph in calculator.