Closed ywan2 closed 4 months ago
Attention: Patch coverage is 85.71429%
with 4 lines
in your changes are missing coverage. Please review.
Project coverage is 27.44%. Comparing base (
8095829
) to head (e96fedb
).:exclamation: Current head e96fedb differs from pull request most recent head 36b68d4
Please upload reports for the commit 36b68d4 to get more accurate results.
Files | Patch % | Lines |
---|---|---|
topeft/modules/datacard_tools.py | 80.95% | 4 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Thank you @bryates for your comments! I made the changes you suggested, except for the last one of "checking non-zero nominal for zero FFUp / FFDown ". There are some channels that have these values during this step but don't raise errors in Combine. Also, I think that keeping "print()" statement might be better than "raise Warning", in case people want to still have the rest of the datacards made to test some things. What do you think?
Thank you @bryates for your comments! I made the changes you suggested, except for the last one of "checking non-zero nominal for zero FFUp / FFDown ". There are some channels that have these values during this step but don't raise errors in Combine. Also, I think that keeping "print()" statement might be better than "raise Warning", in case people want to still have the rest of the datacards made to test some things. What do you think?
@ywan2 Raising a warning should still just print a message and continue. Raising an exception will for sure terminate the script. Are you seeing otherwise?
Thank you @bryates for your comments! I made the changes you suggested, except for the last one of "checking non-zero nominal for zero FFUp / FFDown ". There are some channels that have these values during this step but don't raise errors in Combine. Also, I think that keeping "print()" statement might be better than "raise Warning", in case people want to still have the rest of the datacards made to test some things. What do you think?
@ywan2 Raising a warning should still just print a message and continue. Raising an exception will for sure terminate the script. Are you seeing otherwise?
Ah maybe I was thinking of this (https://stackoverflow.com/questions/3891804/raise-warning-in-python-without-interrupting-program). You can switch back to print statements instead of warnings.
@bryates, yes I tested the the raise Warning
statement, it does terminate the code. So I switched back to print statement.
Merging this PR now. I've created issues for the remaining items so we can address them later.
Two features are added in the datacard making step using
python make_cards.py pkl _np.pkl.gz
:--unblind
option), by including--wc-vals wc1={number1}, wc2={number2} ...
An example code to run is:FFUp
andFFDown
are supposed to be zero. If any non-zero value occurs, the systematics is invalid thus an error would be raised. If this error shows up, it would be very likely that the datacards made won't pass text2workspace.py later in combine.