Workflow Layers¶

The WorkflowCalculationLayer and WorkflowCalculationSchema offer an abstract base implementation for any calculation layers (and their associated schemas) which will perform their calculations using the built-in workflow engine.

The WorkflowCalculationLayer takes as input from its calculation schema one WorkflowSchema object for each type of property to be estimated by this layer. These schemas must at a minimum provide both the schemas of the protocols in the workflow, and have the final_value_source attribute set to the value of the calculated observable. In addition, the layer fully supports schemas which provide gradient information (see the gradients_sources attribute), as well as storing any generated dataclasses (see the outputs_to_store attribute) to the available storage backend.

This layer implements three key methods which are available to be overridden by any subclass implementations:

The workflow layer will by default tag each property estimated using it (or one of its derivatives) with a CalculationSource with the fidelity attribute set to the name of the layer, and the provenance attribute set to the schema of the workflow used to generate the property.

The metadata provided to the workflows generated by this layer is generated on a per property to estimate basis mainly using the generate_default_metadata() function. It includes:

Key
Type
Description
thermodynamic_state
The state at which the to perform any calculations .
substance
The substance to use in any calculations.
components
The components present in the main substance.
target_uncertainty
The target uncertainty of any calculations defined by the calculation schema.
per_component_uncertainty
The target_uncertainty divided by sqrt(substance.n_components + 1)
force_field_path
A file path to the force field parameters to use.
parameter_gradient_keys
The parameters to differentiate any observables with respect to (if any).