(function from pyomo.contrib.parmest.utils.model_utils)
pyomo.contrib.parmest.utils.model_utils
Overwrite each variable/parameter referenced by suffix_obj with the corresponding value in values. The provided values are expected to be in the same order as the components in the suffix from when it was created.
suffix_obj
values
suffix_obj (pyomo.core.base.suffix.Suffix) – The suffix whose keys are the components you want to update. Call like update_from_suffix(model.unknown_parameters, vals).
update_from_suffix(model.unknown_parameters, vals)
values (iterable of numbers) – New numerical values for the components referenced by the suffix. Must be the same length as suffix_obj.
Notes
The measurement_error suffix is a special case: instead of updating the value of the keys (variables/parameters), it updates the value stored in the suffix itself.