-
Notifications
You must be signed in to change notification settings - Fork 92
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Summary
It is possible in 0.7.0rc1 to correlate shapesys modifiers across channels, and these modifiers behave in strange ways. 0.6.3 raised an error instead.
OS / Environment
n/aSteps to Reproduce
import pyhf
spec = {
"channels": [
{
"name": "SR",
"samples": [
{
"data": [24.0, 25.0],
"modifiers": [
{"data": [0.1, 0.2], "name": "par", "type": "shapesys"},
{"data": None, "name": "mu", "type": "normfactor"},
],
"name": "Signal",
}
],
},
{
"name": "CR",
"samples": [
{
"data": [10.0],
"modifiers": [{"data": [0.1], "name": "par", "type": "shapesys"}],
"name": "Background",
}
],
},
],
"measurements": [
{"config": {"parameters": [], "poi": "mu"}, "name": "minimal_example"}
],
"observations": [
{"data": [24.0, 24.0], "name": "SR"},
{"data": [10.0], "name": "CR"},
],
"version": "1.0.0",
}
model = pyhf.Workspace(spec).model()
print(model.config.par_names()) # model contains mu and par[0]
print(model.expected_actualdata([1.0, 1.1])) # modifier scales both SR binsFile Upload (optional)
No response
Expected Results
Expected behavior is that of v0.6.3
ValueError: Trying to add unshared-paramset but other paramsets exist with the same name.
as this setup does not make a lot of sense.
Actual Results
['mu', 'par[0]']
[10. 26.4 27.5]The two bins in the SR get scaled by a parameter that looks like it should instead scale the first bin of both channels.
pyhf Version
0.7.0rc1Code of Conduct
- I agree to follow the Code of Conduct
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working