Skip to content

Commit

Permalink
PWGCF: DptDpt, Addressing extra event selection checks separately (#7552
Browse files Browse the repository at this point in the history
)

* PWGCF: DptDpt, Addressing extra event selection checks separately

* Please consider the following formatting changes

---------

Co-authored-by: Victor <[email protected]>
Co-authored-by: ALICE Action Bot <[email protected]>
  • Loading branch information
3 people authored Sep 3, 2024
1 parent e792e4c commit 96f2e76
Showing 1 changed file with 41 additions and 8 deletions.
49 changes: 41 additions & 8 deletions PWGCF/TableProducer/dptdptfilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,16 @@ enum CentMultEstimatorType {
/// \enum TriggerSelectionType
/// \brief The type of trigger to apply for event selection
enum TriggerSelectionType {
kNONE = 0, ///< do not use trigger selection
kMB, ///< Minimum bias trigger
kVTXTOFMATCHED, ///< at least one vertex contributor is matched to TOF
kVTXTRDMATCHED, ///< at least one vertex contributor is matched to TRD
kVTXTRDTOFMATCHED, ///< at least one vertex contributor is matched to TRD and TOF
knEventSelection ///< number of triggers for event selection
kNONE = 0, ///< do not use trigger selection
kMB, ///< Minimum bias trigger
kMBEXTRA, ///< Additional Run3 event quality
kVTXTOFMATCHED, ///< at least one vertex contributor is matched to TOF
kVTXTRDMATCHED, ///< at least one vertex contributor is matched to TRD
kVTXTRDTOFMATCHED, ///< at least one vertex contributor is matched to TRD and TOF
kEXTRAVTXTOFMATCHED, ///< Additional Run3 event quality and at least one vertex contributor is matched to TOF
kEXTRAVTXTRDMATCHED, ///< Additional Run3 event quality and at least one vertex contributor is matched to TRD
kEXTRAVTXTRDTOFMATCHED, ///< Additional Run3 event quality and at least one vertex contributor is matched to TRD and TOF
knEventSelection ///< number of triggers for event selection
};

/// \enum StrongDebugging
Expand Down Expand Up @@ -312,12 +316,20 @@ inline TriggerSelectionType getTriggerSelection(std::string const& triggstr)
{
if (triggstr.empty() || triggstr == "MB") {
return kMB;
} else if (triggstr == "MBEXTRA") {
return kMBEXTRA;
} else if (triggstr == "VTXTOFMATCHED") {
return kVTXTOFMATCHED;
} else if (triggstr == "VTXTRDMATCHED") {
return kVTXTRDMATCHED;
} else if (triggstr == "VTXTRDTOFMATCHED") {
return kVTXTRDTOFMATCHED;
} else if (triggstr == "EXTRAVTXTOFMATCHED") {
return kEXTRAVTXTOFMATCHED;
} else if (triggstr == "EXTRAVTXTRDMATCHED") {
return kEXTRAVTXTRDMATCHED;
} else if (triggstr == "EXTRAVTXTRDTOFMATCHED") {
return kEXTRAVTXTRDTOFMATCHED;
} else if (triggstr == "None") {
return kNONE;
} else {
Expand Down Expand Up @@ -481,9 +493,10 @@ inline bool triggerSelectionReco(CollisionObject const& collision)
case kppRun3:
case kPbPbRun3: {
auto run3Accepted = [](auto const& coll) {
return coll.sel8();
};
auto run3ExtraAccepted = [](auto const& coll) {
return coll.sel8() &&
coll.selection_bit(aod::evsel::kNoITSROFrameBorder) &&
coll.selection_bit(aod::evsel::kNoTimeFrameBorder) &&
coll.selection_bit(aod::evsel::kNoSameBunchPileup) &&
coll.selection_bit(aod::evsel::kIsGoodZvtxFT0vsPV) &&
coll.selection_bit(aod::evsel::kIsVertexITSTPC);
Expand All @@ -494,6 +507,11 @@ inline bool triggerSelectionReco(CollisionObject const& collision)
trigsel = true;
}
break;
case kMBEXTRA:
if (run3ExtraAccepted(collision)) {
trigsel = true;
}
break;
case kVTXTOFMATCHED:
if (run3Accepted(collision) && collision.selection_bit(aod::evsel::kIsVertexTOFmatched)) {
trigsel = true;
Expand All @@ -509,6 +527,21 @@ inline bool triggerSelectionReco(CollisionObject const& collision)
trigsel = true;
}
break;
case kEXTRAVTXTOFMATCHED:
if (run3ExtraAccepted(collision) && collision.selection_bit(aod::evsel::kIsVertexTOFmatched)) {
trigsel = true;
}
break;
case kEXTRAVTXTRDMATCHED:
if (run3ExtraAccepted(collision) && collision.selection_bit(aod::evsel::kIsVertexTRDmatched)) {
trigsel = true;
}
break;
case kEXTRAVTXTRDTOFMATCHED:
if (run3ExtraAccepted(collision) && collision.selection_bit(aod::evsel::kIsVertexTRDmatched) && collision.selection_bit(aod::evsel::kIsVertexTOFmatched)) {
trigsel = true;
}
break;
case kNONE:
trigsel = true;
break;
Expand Down

0 comments on commit 96f2e76

Please sign in to comment.