Search in sources :

Example 1 with LsqVarianceGradientProcedure

use of uk.ac.sussex.gdsc.smlm.fitting.nonlinear.gradient.LsqVarianceGradientProcedure in project GDSC-SMLM by aherbert.

the class LseLvmSteppingFunctionSolver method computeDeviationsAndValues.

@Override
protected void computeDeviationsAndValues(double[] parametersVariance, double[] fx) {
    Gradient1Function f1 = (Gradient1Function) this.function;
    // Capture the y-values if necessary
    if (fx != null && fx.length == f1.size()) {
        f1 = new Gradient2FunctionValueStore(f1, fx);
    }
    final LsqVarianceGradientProcedure p = createVarianceProcedure(f1);
    if (p.variance(null) == LsqVarianceGradientProcedure.STATUS_OK) {
        setDeviations(parametersVariance, p.variance);
    }
}
Also used : LsqVarianceGradientProcedure(uk.ac.sussex.gdsc.smlm.fitting.nonlinear.gradient.LsqVarianceGradientProcedure) Gradient1Function(uk.ac.sussex.gdsc.smlm.function.Gradient1Function) Gradient2FunctionValueStore(uk.ac.sussex.gdsc.smlm.function.Gradient2FunctionValueStore)

Aggregations

LsqVarianceGradientProcedure (uk.ac.sussex.gdsc.smlm.fitting.nonlinear.gradient.LsqVarianceGradientProcedure)1 Gradient1Function (uk.ac.sussex.gdsc.smlm.function.Gradient1Function)1 Gradient2FunctionValueStore (uk.ac.sussex.gdsc.smlm.function.Gradient2FunctionValueStore)1