|
25 | 25 | #include "Common/Core/Zorro.h" |
26 | 26 | #include "Common/Core/ZorroSummary.h" |
27 | 27 | #include "Common/DataModel/Centrality.h" |
| 28 | +#include "Common/DataModel/CollisionAssociationTables.h" |
28 | 29 | #include "Common/DataModel/EventSelection.h" |
29 | 30 | #include "Common/DataModel/Multiplicity.h" |
30 | 31 | #include "Common/DataModel/PIDResponseTOF.h" |
@@ -82,6 +83,8 @@ struct HStrangeCorrelationFilter { |
82 | 83 | Configurable<float> strangedEdxNSigmaTight{"strangedEdxNSigmaTight", 3, "Nsigmas for strange decay daughters"}; |
83 | 84 | Configurable<std::string> zorroMask{"zorroMask", "", "zorro trigger class to select on (empty: none)"}; |
84 | 85 | Configurable<float> nSigmaNearXiMassCenter{"nSigmaNearXiMassCenter", 0, "for Oemga analysis only, to check if candidate mass is around Xi"}; |
| 86 | + Configurable<bool> rejectAmbiguousTracks{"rejectAmbiguousTracks", false, "reject tracks compatible with more than one collision (requires track-to-collision-associator with fillTableOfCollIdsPerTrack)"}; |
| 87 | + Configurable<bool> rejectAmbiguousAssoc{"rejectAmbiguousAssoc", false, "reject V0/cascade candidates having at least one ambiguous daughter track"}; |
85 | 88 |
|
86 | 89 | // used for event selections in Pb-Pb |
87 | 90 | Configurable<int> cfgCutOccupancyHigh{"cfgCutOccupancyHigh", 3000, "High cut on TPC occupancy"}; |
@@ -210,10 +213,10 @@ struct HStrangeCorrelationFilter { |
210 | 213 |
|
211 | 214 | // using V0LinkedTagged = soa::Join<aod::V0sLinked, aod::V0Tags>; |
212 | 215 | // using CascadesLinkedTagged = soa::Join<aod::CascadesLinked, aod::CascTags>; |
213 | | - using FullTracks = soa::Join<aod::Tracks, aod::TracksExtra, aod::TracksDCA>; |
214 | | - using FullTracksMC = soa::Join<aod::Tracks, aod::TracksExtra, aod::TracksDCA, aod::McTrackLabels>; |
215 | | - using DauTracks = soa::Join<aod::Tracks, aod::TracksExtra, aod::pidTPCFullPi, aod::pidTPCFullKa, aod::pidTPCFullPr, aod::TracksDCA>; |
216 | | - using DauTracksMC = soa::Join<aod::Tracks, aod::TracksExtra, aod::pidTPCFullPi, aod::pidTPCFullKa, aod::pidTPCFullPr, aod::TracksDCA, aod::McTrackLabels>; |
| 216 | + using FullTracks = soa::Join<aod::Tracks, aod::TracksExtra, aod::TracksDCA, aod::TrackCompColls>; |
| 217 | + using FullTracksMC = soa::Join<aod::Tracks, aod::TracksExtra, aod::TracksDCA, aod::McTrackLabels, aod::TrackCompColls>; |
| 218 | + using DauTracks = soa::Join<aod::Tracks, aod::TracksExtra, aod::pidTPCFullPi, aod::pidTPCFullKa, aod::pidTPCFullPr, aod::TracksDCA, aod::TrackCompColls>; |
| 219 | + using DauTracksMC = soa::Join<aod::Tracks, aod::TracksExtra, aod::pidTPCFullPi, aod::pidTPCFullKa, aod::pidTPCFullPr, aod::TracksDCA, aod::McTrackLabels, aod::TrackCompColls>; |
217 | 220 | // using IDTracks= soa::Join<aod::Tracks, aod::TracksExtra, aod::pidTPCFullPi, aod::pidTOFFullPi, aod::pidBayesPi, aod::pidBayesKa, aod::pidBayesPr, aod::TOFSignal>; // prepared for Bayesian PID |
218 | 221 | using IDTracks = soa::Join<aod::Tracks, aod::TracksExtra, aod::pidTPCFullPi, aod::pidTOFFullPi, aod::pidTPCFullKa, aod::pidTOFFullKa, aod::pidTPCFullPr, aod::pidTOFFullPr, aod::pidTPCFullEl, aod::pidTOFFullEl, aod::TOFSignal, aod::TracksDCA>; |
219 | 222 | using IDTracksMC = soa::Join<aod::Tracks, aod::TracksExtra, aod::pidTPCFullPi, aod::pidTOFFullPi, aod::pidTPCFullKa, aod::pidTOFFullKa, aod::pidTPCFullPr, aod::pidTOFFullPr, aod::pidTPCFullEl, aod::pidTOFFullEl, aod::TOFSignal, aod::TracksDCA, aod::McTrackLabels>; |
@@ -300,12 +303,21 @@ struct HStrangeCorrelationFilter { |
300 | 303 | histos.add("h3dMassLambda", "h3dMassLambda", kTH3F, {axesConfigurations.axisPtQA, axesConfigurations.axisLambdaMass, axesConfigurations.axisMult}); |
301 | 304 | histos.add("h3dMassAntiLambda", "h3dMassAntiLambda", kTH3F, {axesConfigurations.axisPtQA, axesConfigurations.axisLambdaMass, axesConfigurations.axisMult}); |
302 | 305 | } |
| 306 | + if (rejectAmbiguousAssoc && (doprocessV0s || doprocessV0sMC)) { |
| 307 | + histos.add("hAmbiguousV0Pt", "hAmbiguousV0Pt", kTH1F, {axesConfigurations.axisPtQA}); |
| 308 | + } |
| 309 | + if (rejectAmbiguousTracks && (doprocessTriggers || doprocessTriggersMC)) { |
| 310 | + histos.add("hAmbiguousTriggerPt", "hAmbiguousTriggerPt", kTH1F, {axesConfigurations.axisPtQA}); |
| 311 | + } |
303 | 312 | if (doprocessCascades || doprocessCascadesMC) { |
304 | 313 | histos.add("h3dMassXiMinus", "h3dMassXiMinus", kTH3F, {axesConfigurations.axisPtQA, axesConfigurations.axisXiMass, axesConfigurations.axisMult}); |
305 | 314 | histos.add("h3dMassXiPlus", "h3dMassXiPlus", kTH3F, {axesConfigurations.axisPtQA, axesConfigurations.axisXiMass, axesConfigurations.axisMult}); |
306 | 315 | histos.add("h3dMassOmegaMinus", "h3dMassOmegaMinus", kTH3F, {axesConfigurations.axisPtQA, axesConfigurations.axisOmegaMass, axesConfigurations.axisMult}); |
307 | 316 | histos.add("h3dMassOmegaPlus", "h3dMassOmegaPlus", kTH3F, {axesConfigurations.axisPtQA, axesConfigurations.axisOmegaMass, axesConfigurations.axisMult}); |
308 | 317 | } |
| 318 | + if (rejectAmbiguousAssoc && (doprocessCascades || doprocessCascadesMC)) { |
| 319 | + histos.add("hAmbiguousCascadePt", "hAmbiguousCascadePt", kTH1F, {axesConfigurations.axisPtQA}); |
| 320 | + } |
309 | 321 | } |
310 | 322 |
|
311 | 323 | void initCCDB(aod::BCsWithTimestamps::iterator const& bc) |
@@ -410,6 +422,20 @@ struct HStrangeCorrelationFilter { |
410 | 422 | return true; |
411 | 423 | } |
412 | 424 |
|
| 425 | + // ambiguous track check: the track is compatible with more than one collision, |
| 426 | + // or with a collision different from the one it is assigned to (see PWGCF/TableProducer/dptDptFilter.cxx) |
| 427 | + template <class TTrack> |
| 428 | + bool isAmbiguousTrack(TTrack const& track) |
| 429 | + { |
| 430 | + if (track.compatibleCollIds().size() == 0) { |
| 431 | + return false; // no collision association information: not ambiguous |
| 432 | + } |
| 433 | + if (track.compatibleCollIds().size() == 1) { |
| 434 | + return track.collisionId() != track.compatibleCollIds()[0]; |
| 435 | + } |
| 436 | + return true; // associated to more than one collision |
| 437 | + } |
| 438 | + |
413 | 439 | // reco-level trigger quality checks (N.B.: DCA is filtered, not selected) |
414 | 440 | template <class TTrack> |
415 | 441 | bool isValidTrigger(TTrack const& track) |
@@ -593,6 +619,10 @@ struct HStrangeCorrelationFilter { |
593 | 619 | if (!isValidTrigger(track)) { |
594 | 620 | continue; |
595 | 621 | } |
| 622 | + if (rejectAmbiguousTracks && isAmbiguousTrack(track)) { |
| 623 | + histos.fill(HIST("hAmbiguousTriggerPt"), track.pt()); |
| 624 | + continue; |
| 625 | + } |
596 | 626 | TriggCandidate thisTrigg{}; |
597 | 627 | thisTrigg.pt = track.pt(); |
598 | 628 | thisTrigg.trackId = track.globalIndex(); |
@@ -634,6 +664,10 @@ struct HStrangeCorrelationFilter { |
634 | 664 | if (!isValidTrigger(track)) { |
635 | 665 | continue; |
636 | 666 | } |
| 667 | + if (rejectAmbiguousTracks && isAmbiguousTrack(track)) { |
| 668 | + histos.fill(HIST("hAmbiguousTriggerPt"), track.pt()); |
| 669 | + continue; |
| 670 | + } |
637 | 671 | TriggCandidate thisTrigg{}; |
638 | 672 | thisTrigg.pt = track.pt(); |
639 | 673 | thisTrigg.trackId = track.globalIndex(); |
@@ -812,6 +846,10 @@ struct HStrangeCorrelationFilter { |
812 | 846 | if (trackSelections.requireClusterInITS && (posdau.itsNCls() < trackSelections.minITSClustersForDaughterTracks || negdau.itsNCls() < trackSelections.minITSClustersForDaughterTracks)) { |
813 | 847 | continue; |
814 | 848 | } |
| 849 | + if (rejectAmbiguousAssoc && (isAmbiguousTrack(posdau) || isAmbiguousTrack(negdau))) { |
| 850 | + histos.fill(HIST("hAmbiguousV0Pt"), v0.pt()); |
| 851 | + continue; |
| 852 | + } |
815 | 853 |
|
816 | 854 | float dcaDauCutForK0s = v0Selection.dcaDaugToPVForK0s == 0 ? v0Selection.dcaMesonToPV : v0Selection.dcaDaugToPVForK0s; |
817 | 855 | bool isGoodK0Short = (v0.distovertotmom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassK0Short < v0Selection.lifetimecutK0S && |
@@ -947,6 +985,10 @@ struct HStrangeCorrelationFilter { |
947 | 985 | if (trackSelections.requireClusterInITS && (posdau.itsNCls() < trackSelections.minITSClustersForDaughterTracks || negdau.itsNCls() < trackSelections.minITSClustersForDaughterTracks)) { |
948 | 986 | continue; |
949 | 987 | } |
| 988 | + if (rejectAmbiguousAssoc && (isAmbiguousTrack(posdau) || isAmbiguousTrack(negdau))) { |
| 989 | + histos.fill(HIST("hAmbiguousV0Pt"), v0.pt()); |
| 990 | + continue; |
| 991 | + } |
950 | 992 |
|
951 | 993 | float dcaDauCutForK0s = v0Selection.dcaDaugToPVForK0s == 0 ? v0Selection.dcaMesonToPV : v0Selection.dcaDaugToPVForK0s; |
952 | 994 | bool isGoodK0Short = v0.distovertotmom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassK0Short < v0Selection.lifetimecutK0S && |
@@ -1101,6 +1143,10 @@ struct HStrangeCorrelationFilter { |
1101 | 1143 | if (negTrackCast.tpcNClsCrossedRows() < trackSelections.minTPCNCrossedRows) { |
1102 | 1144 | continue; |
1103 | 1145 | } |
| 1146 | + if (rejectAmbiguousAssoc && (isAmbiguousTrack(bachTrackCast) || isAmbiguousTrack(posTrackCast) || isAmbiguousTrack(negTrackCast))) { |
| 1147 | + histos.fill(HIST("hAmbiguousCascadePt"), casc.pt()); |
| 1148 | + continue; |
| 1149 | + } |
1104 | 1150 | if (!doPPAnalysis && !cascadeSelectedPbPb(casc, collision.posX(), collision.posY(), collision.posZ())) { |
1105 | 1151 | continue; |
1106 | 1152 | } |
@@ -1270,6 +1316,10 @@ struct HStrangeCorrelationFilter { |
1270 | 1316 | if (negTrackCast.tpcNClsCrossedRows() < trackSelections.minTPCNCrossedRows) { |
1271 | 1317 | continue; |
1272 | 1318 | } |
| 1319 | + if (rejectAmbiguousAssoc && (isAmbiguousTrack(bachTrackCast) || isAmbiguousTrack(posTrackCast) || isAmbiguousTrack(negTrackCast))) { |
| 1320 | + histos.fill(HIST("hAmbiguousCascadePt"), casc.pt()); |
| 1321 | + continue; |
| 1322 | + } |
1273 | 1323 | if (!doPPAnalysis && !cascadeSelectedPbPb(casc, collision.posX(), collision.posY(), collision.posZ())) { |
1274 | 1324 | continue; |
1275 | 1325 | } |
|
0 commit comments