Skip to content

Hessian of POI around its maximum #1862

Discussion options

You must be logged in to vote

You should be able to get it through minuit.

>>> import pyhf
>>> model = pyhf.simplemodels.uncorrelated_background([5.0], [10.0], [2.5])
>>> data = [12.5] + model.config.auxdata
>>> pyhf.set_backend(pyhf.tensorlib, 'minuit')
>>> pyhf.infer.mle.fit(data, model, return_correlations=True)
(array([0.5015113 , 0.99947511]), array([[ 1.        , -0.57697422],
       [-0.57697422,  1.        ]]))

Keyword arguments for most/all fit functions are listed in the Optimizer API (https://scikit-hep.org/pyhf/_generated/pyhf.optimize.mixins.OptimizerMixin.html#pyhf.optimize.mixins.OptimizerMixin.minimize)

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@kratsg
Comment options

Answer selected by kratsg
Comment options

You must be logged in to vote
0 replies
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