atomica.optimization.Adjustable¶
- class atomica.optimization.Adjustable(name, limit_type='abs', lower_bound=-inf, upper_bound=inf, initial_value=None)[source]¶
Bases:
objectClass to store single optimizable parameter
An
Adjustablerepresents a single entry in the ASD matrix. AnAdjustmentuses one or moreAdjustablesto make changes to the program instructions.- Parameters:
name – The name of the adjustable
limit_type – If bounds are provided, are they relative or absolute (
'abs'or'rel')lower_bound – Optionally specify minimum value
upper_bound – Optionally specify maximum value
initial_value – Optionally specify initial value. Most commonly, the initial value would be set by the
Adjustmentcontaining theAdjustable
Methods
Return hard bounds for the adjustable
- get_hard_bounds(x0=None)[source]¶
Return hard bounds for the adjustable
The hard bounds could be relative or absolute. If they are relative, then they are treated as being relative to the initial value for this adjustable. This is because not all adjustables can be directly drawn from the program instructions (e.g. parametric overwrites) in which case it would not be possible to extract initial values from the instructions alone. For consistency, all adjustables behave the same way with constraints relative to their initialization.