asimtools.asimmodules.benchmarking package
asimtools.asimmodules.benchmarking.parity module
Generates a parity plot and collects evaluation statistics comparing energy and/or forces and/or stress to existing values in the provided dataset. This asimmodule can work in parallel based on the number of cores specified.
Author: mkphuthi@github.com
- asimtools.asimmodules.benchmarking.parity.calc_parity_data(subset: List, calculator: Dict, properties: Sequence = ('energy', 'forces', 'stress'), force_prob: float = 1.0) Dict[source]
Calculates parity data for each atoms instance in subset
- Parameters:
subset (List) – List of atoms instances
calculator (Dict) – Calculator specification, see
asimtools.calculators.load_calc()properties (List, optional) – Properties to evaluate, choose from “energy”, “forces” and “stress”, defaults to (‘energy’, ‘forces’, ‘stress’)
force_prob (float, optional) – Fraction of forces to consider, may speed up sampling large structures by subsampling forces randomly, defaults to 1.0
- Returns:
Dictionary with reference and predicted values for each property
- Return type:
Dict
- asimtools.asimmodules.benchmarking.parity.parity(images: Dict, calculator: Dict, force_prob: float = 1.0, nprocs: int = 1, unit: str = 'meV', index: str = ':', properties: Sequence = ('energy', 'forces', 'stress')) Dict[source]
Generates a parity plot and collects evaluation statistics comparing energy and/or forces and/or stress to existing values in the provided dataset
- Parameters:
images (Dict) – Images specification, see
asimtools.utils.get_images()calculator (Dict) – Calculator specification, see
asimtools.calculators.load_calc()force_prob (float, optional) – Fraction of forces to consider in force parity, can be used for speeding up large structures by only subsampling randomly, defaults to 1.0
nprocs (int, optional) – Number of process to parallelize over, must be less than number of datapoints, defaults to 1
unit (str, optional) – Unit to plot, choose from meV, eV or kcal/mol, defaults to ‘meV’
index (int, optional) – index of data to use from full dataset, defaults to ‘:’
properties (Sequence, optional) – Properties to evaluate, choose from “energy”, “forces” and “stress”, defaults to (‘energy’, ‘forces’, ‘stress’)
- Returns:
Dictionary of results
- Return type:
Dict