-
Notifications
You must be signed in to change notification settings - Fork 78
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
Update DL3 cuts and some clean-up #1105
Conversation
…ain_api index doc for high_level module
…o update en-dep cuts for bins with fewer events than minimum, with nearest evaluated cut values
…narios for it. Fix other corresponding tests
…-lstchain into ctapipe_0.17_update_dl3_cuts
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## ctapipe_0.17 #1105 +/- ##
================================================
+ Coverage 74.57% 74.64% +0.06%
================================================
Files 124 124
Lines 12321 12352 +31
================================================
+ Hits 9189 9220 +31
Misses 3132 3132
☔ View full report in Codecov by Sentry. |
…-lstchain into ctapipe_0.17_update_dl3_cuts
…-lstchain into ctapipe_0.17_update_dl3_cuts
…-lstchain into ctapipe_0.17_update_dl3_cuts
It is a bit weird though that the gammaness cut decreases after 8 TeV. Hard to be sure on a color scale, but it does not seem like the gammaness distributions shift down as energy increases... What efficiency is that? Do the cuts seem right (e.g. for the first bin above 10 TeV) if the vertical slices of the histogram are plotted? |
…d update the function to handle case of low event bin in between of high event bins
…-lstchain into ctapipe_0.17_update_dl3_cuts
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The computed alpha cuts look as expected, so this PR looks fine for me (source-dep analysis). I just added a small comment.
@moralejo changes were made, anything else missing? |
Instead of aEvaluating the maximum energy-dependent theta cuts should be analysis dependent and therefore up to the analyzer to change the values in the config and not let the code arrange it using a fixed method (no standard has been defined).max_theta_cut
for energy-dependent theta (source-independent) cuts,RAD_MAX
, evaluate the maximumRAD_MAX
as per the wobble offset angle and the number of OFF regions to be used in ON/OFF normalization, in post DL3 analysis, when using Wobble OFF regions to evaluate the background counts. This replacesmax_theta_cut
andfill_theta_cut
withn_off_wobbles
in this case.update_fill_cuts
to replace the cut values for the energy-dependent cuts evaluated with pyirf, for the energy bins with fewer events thanmin_event_p_en_bin
(default = 100), with the cut value of the nearest energy bin, evaluated properly. This is usually relevant for lower and higher energy bins, where there are fewer or no MC events, and will select a cut evaluated for the first or last energy bin with a statistically significant number of events, instead of a constantfill_value
. This is applied for all such parameters -gammaness
,theta
andalpha
(source-dependent).lstchain/high_level/hdu_table
and updated docstrings.Note: These changes will make the IRF/DL3 files incompatible with older versions