Skip to content

Errordef value when using iMinuit as minimiser #2517

Discussion options

You must be logged in to vote

Hi, this relates back to #1006. Currently pyhf uses 2*NLL as objective function to minimize:

pyhf/src/pyhf/infer/mle.py

Lines 132 to 134 in e8789a2

return opt.minimize(
twice_nll, data, pdf, init_pars, par_bounds, fixed_vals, **kwargs
)

With this definition, errordef=1 is the correct thing to use, which is what pyhf does internally as well:

self.errordef = kwargs.pop('errordef', 1)

There is no need to manually change errordef. If pyhf changes to the NLL as objective, the errordef would have to also be changed at the same time. If you run the fit externally, the right value depends on what…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by reallyblaised
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants