-
Notifications
You must be signed in to change notification settings - Fork 90
Open
Labels
Description
Summary
Fairly easy histosys + normfactor model, but our minuit settings aren't great.. any tips @alexander-held ? (I saw it first in cabinetry but realized it's the minuit backend)
def make_model(s,b,bup,bdn):
m = {
'channels': [{'name': 'singlechannel',
'samples': [{'name': 'signal',
'data': [s],
'modifiers': [{'name': 'mu', 'type': 'normfactor', 'data': None}]},
{'name': 'background',
'data': [b],
'modifiers': [
{'name': 'bkguncrt',
'type': 'histosys',
'data': {'hi_data': [bup], 'lo_data': [bdn]}
}]}]}]
}
return pyhf.Model(m)
m = make_model(7,50,40,60)
d = [50] + m.config.auxdata
pyhf.set_backend('jax',pyhf.optimize.minuit_optimizer())
print(pyhf.infer.mle.fit(d,m))
pyhf.set_backend('jax',pyhf.optimize.scipy_optimizer())
print(pyhf.infer.mle.fit(d,m))[0.74700387 0.38452911]
[3.07345898e-19 6.20569308e-06]
OS / Environment
n/aSteps to Reproduce
see above
File Upload (optional)
No response
Expected Results
this should work trivially :-/
Actual Results
not working :)pyhf Version
0.6.1Code of Conduct
- I agree to follow the Code of Conduct
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
To do