Minimizers#

zfit supplies wrappers for different minimizers from multiple libraries. Most of the are local minimizers (such as Minuit, Ipyopt or ScipyLBFGSB are) while there are also a few global ones such as the NLoptISRES or NLoptStoGO.

While the former are usually faster and preferred, they depend more on the initial values than the latter. Especially in higher dimensions, a global search of the parameters can increase the minimization time drastically and is often infeasible. It is also possible to couple the minimizers by first doing an approximate global minimization and then polish the minimum found with a local minimizer.

All minimizers support similar arguments, most notably tol which denotes the termination value. This is reached if the value of the convergence criterion, which defaults to EDM, the same that is also used in Minuit.

Other than that, there are a also a few minimizer specific arguments that differ from each minimizer.

They all have the exact same minimization method minimize() which takes a loss, parameters and (optionally) a FitResult from which it can take information to have a better start into the minimization.

Minuit#

zfit.minimize.Minuit([tol, mode, gradient, ...])

Minuit is a longstanding and well proven algorithm of the L-BFGS-B class implemented in iminuit.

Levenberg-Marquardt#

zfit.minimize.LevenbergMarquardt([tol, ...])

Levenberg-Marquardt minimizer for general non-linear minimization by interpolating between Gauss-Newton and Gradient descent optimization.

Ipyopt#

zfit.minimize.Ipyopt([tol, maxcor, ...])

Ipopt is a gradient-based minimizer that performs large scale nonlinear optimization of continuous systems.

Scipy#

zfit.minimize.ScipyBFGS([tol, c1, c2, ...])

Local, gradient based quasi-Newton algorithm using the BFGS algorithm.

zfit.minimize.ScipyLBFGSB([tol, maxcor, ...])

Local, gradient based quasi-Newton algorithm using the limited-memory BFGS approximation.

zfit.minimize.ScipyTrustConstr([tol, ...])

Trust-region based local minimizer.

zfit.minimize.ScipyPowell([tol, verbosity, ...])

Local minimizer using the modified Powell algorithm.

zfit.minimize.ScipySLSQP([tol, gradient, ...])

Local, gradient-based minimizer using tho Sequential Least Squares Programming algorithm.name.

zfit.minimize.ScipyTruncNC([tol, maxcg, ...])

Local, gradient based minimization algorithm using a truncated Newton method.

zfit.minimize.ScipyCOBYLA([tol, verbosity, ...])

UNSTABLE! Local gradient-free dowhhill simplex-like method with an implicit linear approximation.

zfit.minimize.ScipyTrustNCG([tol, ...])

PERFORMS POORLY! Local Newton conjugate gradient trust-region algorithm.

zfit.minimize.ScipyDogleg([tol, ...])

This minimizer requires the hessian and gradient to be provided by the loss itself.

zfit.minimize.ScipyTrustKrylov([tol, ...])

PERFORMS POORLY! Local, gradient based (nearly) exact trust-region algorithm using matrix vector products with the hessian.

NLopt#

zfit.minimize.NLoptLBFGSV1

alias of NLoptLBFGS

zfit.minimize.NLoptTruncNewtonV1

alias of NLoptTruncNewton

zfit.minimize.NLoptSLSQPV1

alias of NLoptSLSQP

zfit.minimize.NLoptMMAV1

alias of NLoptMMA

zfit.minimize.NLoptCCSAQV1

alias of NLoptCCSAQ

zfit.minimize.NLoptSubplexV1

alias of NLoptSubplex

zfit.minimize.NLoptCOBYLAV1

alias of NLoptCOBYLA

zfit.minimize.NLoptMLSLV1

alias of NLoptMLSL

zfit.minimize.NLoptStoGOV1

alias of NLoptStoGO

zfit.minimize.NLoptBOBYQAV1

alias of NLoptBOBYQA

zfit.minimize.NLoptISRESV1

alias of NLoptISRES

zfit.minimize.NLoptESCHV1

alias of NLoptESCH

zfit.minimize.NLoptShiftVarV1

alias of NLoptShiftVar