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

Need to be able to parse and write counting-only cards #18

Closed
ajgilbert opened this issue Jan 28, 2016 · 0 comments
Closed

Need to be able to parse and write counting-only cards #18

ajgilbert opened this issue Jan 28, 2016 · 0 comments
Assignees
Milestone

Comments

@ajgilbert
Copy link
Collaborator

With the added complication that some will use "FAKE" shape entries and some won't.

@ajgilbert ajgilbert self-assigned this Jan 28, 2016
@ajgilbert ajgilbert added this to the moriond16 milestone Jan 28, 2016
ajgilbert added a commit that referenced this issue Feb 7, 2016
Closes #18. CombineHarvester can now parse datacards that do not contain
"shape" directives, or that contain "FAKE" shape directives. When writing a
datacard, a bin will be given the "FAKE" shape directive if none of the
Observation and Process objects in that bin refer to a shape, RooDataHist or
RooAbsPdf.

In detail:

 -  New overload method `WriteDatacard(std::string const& name)` that can be
    used when there is no shape information to write. If an object does
    reference a shape then the method will throw. Also added to the python
    interface.
 -  WriteDatacard would previously throw if the supplied TFile was not open.
    As we now use a dummy TFile for counting-only datacards, this throw is
    only triggered when there is a shape to write and the TFile is not open.
 -  The HistMapping class now has a boolean data member `is_fake`, this is
    checked in the LoadShapes methods to avoid making any attempt to read from
    a non-existent ROOT file.
 -  The LoadShapes methods also check at the beginning if the list of
    HistMappings is empty, and if so return immediately, under the assumption
    that must be a counting-only datacard.
mverzett pushed a commit to mverzett/CombineHarvester that referenced this issue Jul 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant