ObservableArray
- class openff.evaluator.utils.observables.ObservableArray(value: Optional[Quantity] = None, gradients: Optional[List[ParameterGradient]] = None)[source]
A class which stores the value(s) of an observable obtained via molecule simulation (or simulation data) as well as optionally the derivatives of the value with respect to certain force field parameters.
- __init__(value: Optional[Quantity] = None, gradients: Optional[List[ParameterGradient]] = None)[source]
Methods
__init__
([value, gradients])Clears all gradient information.
join
(*observables)Concatenates multiple observables together in the order that they appear in the args list.
subset
(indices)Extracts the subset of the values stored for this observable at the specified indices.
Attributes
gradients
The value(s) of the observable.
- property value: Quantity
The value(s) of the observable.
- subset(indices: Iterable[int]) ObservableArray [source]
Extracts the subset of the values stored for this observable at the specified indices.
- Parameters
indices – The indices of the entries to extract.
- Return type
The subset of the observable values.
- classmethod join(*observables: ObservableArray) ObservableArray [source]
Concatenates multiple observables together in the order that they appear in the args list.
- Parameters
observables – The observables to join.
- Return type
The concatenated observable object.