Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix in SL interface #93

Merged
merged 2 commits into from
Jun 20, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions doc/releases/changelog-dev.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,20 +51,29 @@
## Bug fixes
* Zero division error fixed in the simplified likelihoods workflow.
([#4](https://github.com/MadAnalysis/madanalysis5/pull/4))

* Bug fix in the Pyhf wrapper.
([#10](https://github.com/MadAnalysis/madanalysis5/pull/10))

* The ability to flush previous executions has been added to the PADForSFS.
([#17](https://github.com/MadAnalysis/madanalysis5/pull/17))

* The `RecParticleFormat` dataformat now has an `ntracks()` accessor (as
required by the NormalMode).
([#56](https://github.com/MadAnalysis/madanalysis5/pull/56))

* Negative value can now be used for SFS bounds.
([#52](https://github.com/MadAnalysis/madanalysis5/pull/52))

* Bugfix for covariance matrix construction when global likelihood switch is off.
([#88](https://github.com/MadAnalysis/madanalysis5/pull/88))

* Update the version check message for the cases that local version is greater
than stable version. ([#91](https://github.com/MadAnalysis/madanalysis5/pull/91))

* SL interface break has been fixed in cases of HL extrapolation.
([#93](https://github.com/MadAnalysis/madanalysis5/pull/93))

## Contributors

This release contains contributions from (in alphabetical order):
Expand Down
10 changes: 5 additions & 5 deletions madanalysis/misc/run_recast.py
Original file line number Diff line number Diff line change
Expand Up @@ -1727,9 +1727,9 @@ def write_cls_output(self, analysis, regions, regiondata, errordata, summary, xs
# Adding the global CLs from simplified likelihood
for cov_subset in self.cov_config.keys():
if not xsflag:
myxsexp = regiondata["cov_subset"][cov_subset]["s95exp"]
myxsobs = regiondata["cov_subset"][cov_subset]["s95obs"]
best = str(regiondata["cov_subset"][cov_subset].get("best",0))
myxsexp = regiondata["cov_subset"][cov_subset].get("s95exp", "-1")
myxsobs = regiondata["cov_subset"][cov_subset].get("s95obs", "-1")
best = str(regiondata["cov_subset"][cov_subset].get("best", 0))
myglobalcls = "%.4f" % regiondata["cov_subset"][cov_subset]["CLs"]
description = "[SL]-"+cov_subset
summary.write(analysis.ljust(30,' ') + description.ljust(60,' ') + best.ljust(10, ' ') +
Expand Down Expand Up @@ -1769,8 +1769,8 @@ def write_cls_output(self, analysis, regions, regiondata, errordata, summary, xs
for likelihood_profile in list(self.pyhf_config.keys()):
if likelihood_profile not in list(pyhf_data.keys()):
continue
myxsexp = pyhf_data.get(likelihood_profile,{}).get('s95exp',"-1")
myxsobs = pyhf_data.get(likelihood_profile,{}).get('s95obs',"-1")
myxsexp = pyhf_data.get(likelihood_profile, {}).get('s95exp', "-1")
myxsobs = pyhf_data.get(likelihood_profile, {}).get('s95obs', "-1")
if not xsflag:
self.logger.debug(str(pyhf_data))
mycls = '{:.4f}'.format(pyhf_data.get(likelihood_profile,{}).get('CLs', 0.))
Expand Down