convert_lmfit_result¶
- convert_lmfit_result(result, models, xdata, ydata, residuals)[source]¶
 A helper function to convert LMFIT
MinimizerResultintoCurveFitResult.CurveFitResultis a dataclass that can be serialized with the experiment JSON decoder. In addition, this class converts LMFITParameterobjects into ufloats so that extra parameter computation in the analysis post-processing can perform accurate error propagation with parameter correlation.- Parameters:
 result (MinimizerResult) – Output from LMFIT
minimize.models (List[Model]) – Model used for the fitting. Function description is extracted.
xdata (ndarray) – X values used for the fitting.
ydata (ndarray) – Y values used for the fitting.
residuals (ndarray) – The residuals of the ydata from the model.
- Returns:
 QiskitExperiments
CurveFitResultobject.- Return type: