File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -434,6 +434,17 @@ struct CorrelationTask {
434434 bool checkObject (TTrack& track)
435435 {
436436 if constexpr (step <= CorrelationContainer::kCFStepAnaTopology ) {
437+ // If using MC trigger PDGs, allow ONLY those PDGs to bypass isPhysicalPrimary
438+ if (!cfgMcTriggerPDGs->empty ()) {
439+ // track has pdgCode in this compilation branch (you only call checkObject where that is true)
440+ const bool isWantedTrigger =
441+ std::find (cfgMcTriggerPDGs->begin (), cfgMcTriggerPDGs->end (), track.pdgCode ()) != cfgMcTriggerPDGs->end ();
442+ if (isWantedTrigger) {
443+ return true ; // allow phi, K*, etc. even if not physical primary
444+ }
445+ // For everything else keep original definition
446+ return track.isPhysicalPrimary ();
447+ }
437448 return track.isPhysicalPrimary ();
438449 } else if constexpr (step == CorrelationContainer::kCFStepTrackedOnlyPrim ) {
439450 return track.isPhysicalPrimary () && (track.flags () & aod::cfmcparticle::kReconstructed );
You can’t perform that action at this time.
0 commit comments