Skip to content

Commit 403d200

Browse files
authored
[PWGLF] Correction on histogram filling (#15544)
1 parent 94d8270 commit 403d200

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

PWGLF/Tasks/GlobalEventProperties/studyPnch.cxx

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,6 @@ struct StudyPnch {
256256
if (!isGenTrackSelected(track)) {
257257
continue;
258258
}
259-
// Verify that the track belongs to the given MC collision
260259
if (track.mcCollisionId() != McCol.globalIndex()) {
261260
continue;
262261
}
@@ -276,7 +275,6 @@ struct StudyPnch {
276275
if (!isTrackSelected(track)) {
277276
continue;
278277
}
279-
// Verify that the track belongs to the given MC collision
280278
if (track.has_mcParticle()) {
281279
auto particle = track.mcParticle();
282280
if (particle.mcCollisionId() != McCol.mcCollisionId()) {
@@ -287,7 +285,7 @@ struct StudyPnch {
287285
}
288286
histos.fill(HIST("PhiVsEtaHist"), track.phi(), track.eta());
289287
}
290-
// Once all the frequencies have been counted, a loop can be made to fill the histogram
288+
// Loop to fill the histogram without cloned tracks
291289
for (const auto& [globalIndex, frequency] : recoFrequencies) {
292290
histos.fill(HIST("hCountNTracks"), frequency);
293291
// Fill histogram with not cloned tracks
@@ -355,18 +353,19 @@ struct StudyPnch {
355353
if (!isEventSelected(RecCol)) {
356354
continue;
357355
}
356+
// Evaluation of reconstructed collisions with more than 1 contributor
358357
if (RecCol.globalIndex() != mcCollision.bestCollisionIndex()) {
359358
continue;
360359
}
361360
auto recTracksPart = RecTracks.sliceBy(perCollision, RecCol.globalIndex());
362361
auto multrec = countNTracksMcCol(recTracksPart, RecCol);
363362
if (multrec > 0) {
364-
histos.fill(HIST("hMultiplicityMCrec"), multrec);
363+
histos.fill(HIST("hMultiplicityMCrecMod"), multrec);
365364
}
366365
auto multgen = countGenTracks(GenParticles, mcCollision);
367366
if (multgen > 0 && multrec > 0) {
368-
histos.fill(HIST("hMultiplicityMCgen"), multgen);
369-
histos.fill(HIST("hResponseMatrix"), multrec, multgen);
367+
histos.fill(HIST("hMultiplicityMCgenMod"), multgen);
368+
histos.fill(HIST("hResponseMatrixMod"), multrec, multgen);
370369
}
371370
}
372371
}

0 commit comments

Comments
 (0)