Skip to content

Commit 0751934

Browse files
Configurable to optionally skip not built V0s
1 parent 99f6ce5 commit 0751934

1 file changed

Lines changed: 10 additions & 4 deletions

File tree

PWGLF/Tasks/QC/v0assoqa.cxx

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,9 @@ struct v0assoqa {
8484
// ML for deduplication
8585
Configurable<bool> fillDuplicatesTable{"fillDuplicatesTable", false, "if true, fill table with duplicated v0s"};
8686

87+
// Select only built v0s
88+
Configurable<bool> selectBuiltOnly{"selectBuiltOnly", true, "if true, select only built v0s"};
89+
8790
// CCDB options
8891
struct : ConfigurableGroup {
8992
std::string prefix = "ccdb";
@@ -437,9 +440,6 @@ struct v0assoqa {
437440

438441
// START OF MAIN DUPLICATE LOOP IS HERE
439442
for (size_t ic = 0; ic < v0tableGrouped[iV0].collisionIds.size(); ic++) {
440-
// simple duplicate accounting
441-
histos.fill(HIST("hPhotonPt_Duplicates"), mcV0.pt());
442-
443443
// check if candidate is correctly associated
444444
bool correctlyAssociated = false;
445445
for (size_t imcc = 0; imcc < mcCollToColl[correctMcCollision].size(); imcc++) {
@@ -479,10 +479,16 @@ struct v0assoqa {
479479
}
480480
} // end TPC drift treatment
481481

482-
483482
// process candidate with helper
484483
bool buildOK = straHelper.buildV0Candidate<false>(v0tableGrouped[iV0].collisionIds[ic], collision.posX(), collision.posY(), collision.posZ(), pTrack, nTrack, posTrackPar, negTrackPar, true, false, true);
485484

485+
if (!buildOK && selectBuiltOnly) {
486+
continue; // skip not built V0s
487+
}
488+
489+
// simple duplicate accounting
490+
histos.fill(HIST("hPhotonPt_Duplicates"), mcV0.pt());
491+
486492
float daughterDCA3D = std::hypot(
487493
straHelper.v0.positivePosition[0] - straHelper.v0.negativePosition[0],
488494
straHelper.v0.positivePosition[1] - straHelper.v0.negativePosition[1],

0 commit comments

Comments
 (0)