Skip to content

Commit 889ebab

Browse files
authored
[PWGLF] added control histogram for evt rejection (#10606)
1 parent 71fed8a commit 889ebab

File tree

1 file changed

+22
-4
lines changed

1 file changed

+22
-4
lines changed

PWGLF/Tasks/Nuspex/antinucleiInJets.cxx

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,7 @@ struct AntinucleiInJets {
173173

174174
// event counter data
175175
registryData.add("number_of_events_data", "number of events in data", HistType::kTH1F, {{10, 0, 10, "counter"}});
176+
registryData.add("number_of_rejected_events", "check on number of events rejected", HistType::kTH1F, {{10, 0, 10, "counter"}});
176177

177178
// antiprotons
178179
registryData.add("antiproton_jet_tpc", "antiproton_jet_tpc", HistType::kTH2F, {{nbins, min, max, "#it{p}_{T} (GeV/#it{c})"}, {400, -20.0, 20.0, "n#sigma_{TPC}"}});
@@ -257,6 +258,7 @@ struct AntinucleiInJets {
257258

258259
// systematic uncertainties
259260
if (doprocessSystematicsData) {
261+
registryData.add("number_of_rejected_events_syst", "check on number of events rejected", HistType::kTH1F, {{10, 0, 10, "counter"}});
260262
registryData.add("antiproton_tpc_syst", "antiproton_tpc_syst", HistType::kTHnSparseF, {{nbins, min, max, "#it{p}_{T} (GeV/#it{c})"}, {400, -20.0, 20.0, "n#sigma_{TPC}"}, {10, 0, 10, "systematic uncertainty"}});
261263
registryData.add("antiproton_tof_syst", "antiproton_tof_syst", HistType::kTHnSparseF, {{nbins, min, max, "#it{p}_{T} (GeV/#it{c})"}, {400, -20.0, 20.0, "n#sigma_{TOF}"}, {10, 0, 10, "systematic uncertainty"}});
262264
registryData.add("antideuteron_tpc_syst", "antideuteron_tpc_syst", HistType::kTHnSparseF, {{nbins, min * 2, max * 2, "#it{p}_{T} (GeV/#it{c})"}, {400, -20.0, 20.0, "n#sigma_{TPC}"}, {10, 0, 10, "systematic uncertainty"}});
@@ -458,8 +460,16 @@ struct AntinucleiInJets {
458460
// Process Data
459461
void processData(SelectedCollisions::iterator const& collision, FullNucleiTracks const& tracks)
460462
{
461-
if (rejectEvents && shouldRejectEvent())
462-
return;
463+
if (rejectEvents) {
464+
// event counter: before event rejection
465+
registryData.fill(HIST("number_of_rejected_events"), 0.5);
466+
467+
if (shouldRejectEvent())
468+
return;
469+
470+
// event counter: after event rejection
471+
registryData.fill(HIST("number_of_rejected_events"), 1.5);
472+
}
463473

464474
// event counter: before event selection
465475
registryData.fill(HIST("number_of_events_data"), 0.5);
@@ -1216,8 +1226,16 @@ struct AntinucleiInJets {
12161226
// Process Systematics
12171227
void processSystematicsData(SelectedCollisions::iterator const& collision, FullNucleiTracks const& tracks)
12181228
{
1219-
if (rejectEvents && shouldRejectEvent())
1220-
return;
1229+
if (rejectEvents) {
1230+
// event counter: before event rejection
1231+
registryData.fill(HIST("number_of_rejected_events_syst"), 0.5);
1232+
1233+
if (shouldRejectEvent())
1234+
return;
1235+
1236+
// event counter: after event rejection
1237+
registryData.fill(HIST("number_of_rejected_events_syst"), 1.5);
1238+
}
12211239

12221240
const int nSystematics = 10;
12231241
int itsNclustersSyst[nSystematics] = {5, 6, 5, 4, 5, 3, 5, 6, 3, 4};

0 commit comments

Comments
 (0)