@@ -75,6 +75,8 @@ struct FemtoUniversePairTaskTrackV0Extended {
7575
7676 Configurable<float > confmom{" confmom" , 0.5 , " momentum threshold for particle identification using TOF" };
7777 Configurable<float > confNsigmaTPCParticle{" confNsigmaTPCParticle" , 3.0 , " TPC Sigma for particle momentum < confmom" };
78+ Configurable<float > confNsigmaTPCDaughter{" confNsigmaTPCDaughter" , 3.0 , " TPC Sigma for daughter" };
79+
7880 Configurable<float > confNsigmaTOFParticle{" confNsigmaTOFParticle" , 3.0 , " TOF Sigma for particle (daugh & bach) momentum > Confmom" };
7981 Configurable<float > confNsigmaCombinedParticle{" confNsigmaCombinedParticle" , 3.0 , " TPC and TOF Sigma (combined) for particle momentum > confmom" };
8082
@@ -146,6 +148,7 @@ struct FemtoUniversePairTaskTrackV0Extended {
146148 // / Correlation part
147149 // Configurable<int> confTrackChoicePartTwo{"confTrackChoicePartTwo", 1, "0:Proton, 1:Pion, 2:Kaon"}; //not used
148150 Configurable<bool > confIsMC{" confIsMC" , false , " Enable additional Histograms in the case of a MonteCarlo Run" };
151+ Configurable<bool > confIsDebug{" confIsDebug" , false , " Enable additional histograms (e.g. three-momentum)" };
149152 Configurable<bool > confUse3D{" confUse3D" , false , " Enable three dimensional histogramms (to be used only for analysis with high statistics): k* vs mT vs multiplicity" };
150153 Configurable<bool > confUseCent{" confUseCent" , false , " Use centrality in place of multiplicity" };
151154 ConfigurableAxis confMultBins{" confMultBins" , {VARIABLE_WIDTH, 0 .0f , 20 .0f , 40 .0f , 60 .0f , 80 .0f , 100 .0f , 200 .0f , 99999 .f }, " Mixing bins - multiplicity" };
@@ -154,19 +157,22 @@ struct FemtoUniversePairTaskTrackV0Extended {
154157 ConfigurableAxis confkstarBins{" confkstarBins" , {1500 , 0 ., 6 .}, " binning kstar" };
155158 ConfigurableAxis confkTBins{" confkTBins" , {150 , 0 ., 9 .}, " binning kT" };
156159 ConfigurableAxis confmTBins{" confmTBins" , {225 , 0 ., 7.5 }, " binning mT" };
157- Configurable<bool > confIsCPR{" confIsCPR" , true , " Close Pair Rejection" };
158- Configurable<bool > confRectV0V0CPR{" confRectV0V0CPR" , true , " Enable rectangular CPR cut for V0-V0 pairs" };
159- Configurable<bool > confCPRPlotPerRadii{" confCPRPlotPerRadii" , false , " Plot CPR per radii" };
160- Configurable<float > confCPRdeltaPhiCutMax{" confCPRdeltaPhiCutMax" , 0.0 , " Delta Phi max cut for Close Pair Rejection" };
161- Configurable<float > confCPRdeltaPhiCutMin{" confCPRdeltaPhiCutMin" , 0.0 , " Delta Phi min cut for Close Pair Rejection" };
162- Configurable<float > confCPRdeltaEtaCutMax{" confCPRdeltaEtaCutMax" , 0.0 , " Delta Eta max cut for Close Pair Rejection" };
163- Configurable<float > confCPRdeltaEtaCutMin{" confCPRdeltaEtaCutMin" , 0.0 , " Delta Eta min cut for Close Pair Rejection" };
164- Configurable<float > confCPRChosenRadii{" confCPRChosenRadii" , 0.80 , " Delta Eta cut for Close Pair Rejection" };
165160 Configurable<int > confPhiBins{" confPhiBins" , 29 , " Number of phi bins in deta dphi" };
166161 Configurable<int > confEtaBins{" confEtaBins" , 29 , " Number of eta bins in deta dphi" };
167162 ConfigurableAxis confmTBins3D{" confmTBins3D" , {VARIABLE_WIDTH, 1 .02f , 1 .14f , 1 .20f , 1 .26f , 1 .38f , 1 .56f , 1 .86f , 4 .50f }, " mT Binning for the 3Dimensional plot: k* vs multiplicity vs mT (set <<confUse3D>> to true in order to use)" };
168163 ConfigurableAxis confMultBins3D{" confMultBins3D" , {VARIABLE_WIDTH, 0 .0f , 20 .0f , 30 .0f , 40 .0f , 99999 .0f }, " multiplicity Binning for the 3Dimensional plot: k* vs multiplicity vs mT (set <<confUse3D>> to true in order to use)" };
169164
165+ struct : o2::framework::ConfigurableGroup {
166+ Configurable<bool > confIsCPR{" confIsCPR" , true , " Close Pair Rejection" };
167+ Configurable<bool > confRectV0V0CPR{" confRectV0V0CPR" , true , " Enable rectangular CPR cut for V0-V0 pairs" };
168+ Configurable<bool > confCPRPlotPerRadii{" confCPRPlotPerRadii" , false , " Plot CPR per radii" };
169+ Configurable<float > confCPRdeltaPhiCutMax{" confCPRdeltaPhiCutMax" , 0.0 , " Delta Phi max cut for Close Pair Rejection" };
170+ Configurable<float > confCPRdeltaPhiCutMin{" confCPRdeltaPhiCutMin" , 0.0 , " Delta Phi min cut for Close Pair Rejection" };
171+ Configurable<float > confCPRdeltaEtaCutMax{" confCPRdeltaEtaCutMax" , 0.0 , " Delta Eta max cut for Close Pair Rejection" };
172+ Configurable<float > confCPRdeltaEtaCutMin{" confCPRdeltaEtaCutMin" , 0.0 , " Delta Eta min cut for Close Pair Rejection" };
173+ Configurable<float > confCPRChosenRadii{" confCPRChosenRadii" , 0.80 , " Delta Eta cut for Close Pair Rejection" };
174+ } ConfCPR;
175+
170176 // Efficiency
171177 Configurable<std::string> confLocalEfficiency{" confLocalEfficiency" , " " , " Local path to efficiency .root file" };
172178
@@ -214,7 +220,7 @@ struct FemtoUniversePairTaskTrackV0Extended {
214220
215221 bool isNSigmaTPC (float nsigmaTPCParticle)
216222 {
217- if (std::abs (nsigmaTPCParticle) < confNsigmaTPCParticle ) {
223+ if (std::abs (nsigmaTPCParticle) < confNsigmaTPCDaughter ) {
218224 return true ;
219225 } else {
220226 return false ;
@@ -280,6 +286,13 @@ struct FemtoUniversePairTaskTrackV0Extended {
280286 qaRegistry.add (" V0Type1/hInvMassAntiLambdaVsCent" , " ; Centrality; M_{#Lambda}; Entries" , kTH2F , {confMultBins, {2000 , 1 .f , 3 .f }});
281287 qaRegistry.add (" V0Type2/hInvMassAntiLambdaVsCent" , " ; Centrality; M_{#Lambda}; Entries" , kTH2F , {confMultBins, {2000 , 1 .f , 3 .f }});
282288
289+ if (confIsDebug) {
290+ qaRegistry.add (" SameEvent/hPtPosDaugh" , " ; #it{p}_{T}^{1} (GeV/c); #it{p}_{T}^{2} (GeV/c)" , kTH2F , {{500 , 0 , 5 }, {500 , 0 , 5 }});
291+ qaRegistry.add (" SameEvent/hPtNegDaugh" , " ; #it{p}_{T}^{1} (GeV/c); #it{p}_{T}^{2} (GeV/c)" , kTH2F , {{500 , 0 , 5 }, {500 , 0 , 5 }});
292+ qaRegistry.add (" SameEvent/hDaughMomPart1" , " ; #it{p}_{T}^{+} (GeV/c); #it{p}_{T}^{-} (GeV/c)" , kTH2F , {{500 , 0 , 5 }, {500 , 0 , 5 }});
293+ qaRegistry.add (" SameEvent/hDaughMomPart2" , " ; #it{p}_{T}^{+} (GeV/c); #it{p}_{T}^{-} (GeV/c)" , kTH2F , {{500 , 0 , 5 }, {500 , 0 , 5 }});
294+ }
295+
283296 trackHistoV0Type1.init (&qaRegistry, ConfV0Selection.confV0TempFitVarpTBins , ConfV0Selection.confV0TempFitVarBins , confIsMC, ConfV0Selection.confV0PDGCodePartTwo , true , " V0Type1" );
284297 posChildV0Type1.init (&qaRegistry, ConfV0Selection.confChildTempFitVarpTBins , ConfV0Selection.confChildTempFitVarBins , false , 0 , true , " posChildV0Type1" );
285298 negChildV0Type1.init (&qaRegistry, ConfV0Selection.confChildTempFitVarpTBins , ConfV0Selection.confChildTempFitVarBins , false , 0 , true , " negChildV0Type1" );
@@ -344,9 +357,9 @@ struct FemtoUniversePairTaskTrackV0Extended {
344357
345358 pairCleaner.init (&qaRegistry);
346359 pairCleanerV0.init (&qaRegistry);
347- if (confIsCPR.value ) {
348- pairCloseRejection.init (&resultRegistry, &qaRegistry, confCPRdeltaPhiCutMin.value , confCPRdeltaPhiCutMax.value , confCPRdeltaEtaCutMin.value , confCPRdeltaEtaCutMax.value , confCPRChosenRadii.value , confCPRPlotPerRadii.value );
349- pairCloseRejectionV0.init (&resultRegistry, &qaRegistry, confCPRdeltaPhiCutMin.value , confCPRdeltaPhiCutMax.value , confCPRdeltaEtaCutMin.value , confCPRdeltaEtaCutMax.value , confCPRChosenRadii.value , confCPRPlotPerRadii.value );
360+ if (ConfCPR. confIsCPR .value ) {
361+ pairCloseRejection.init (&resultRegistry, &qaRegistry, ConfCPR. confCPRdeltaPhiCutMin .value , ConfCPR. confCPRdeltaPhiCutMax .value , ConfCPR. confCPRdeltaEtaCutMin .value , ConfCPR. confCPRdeltaEtaCutMax .value , ConfCPR. confCPRChosenRadii .value , ConfCPR. confCPRPlotPerRadii .value );
362+ pairCloseRejectionV0.init (&resultRegistry, &qaRegistry, ConfCPR. confCPRdeltaPhiCutMin .value , ConfCPR. confCPRdeltaPhiCutMax .value , ConfCPR. confCPRdeltaEtaCutMin .value , ConfCPR. confCPRdeltaEtaCutMax .value , ConfCPR. confCPRChosenRadii .value , ConfCPR. confCPRPlotPerRadii .value );
350363 }
351364
352365 if (!confLocalEfficiency.value .empty ()) {
@@ -528,7 +541,7 @@ struct FemtoUniversePairTaskTrackV0Extended {
528541 }
529542 }
530543
531- if (confIsCPR.value ) {
544+ if (ConfCPR. confIsCPR .value ) {
532545 if (pairCloseRejection.isClosePair (p1, p2, parts, magFieldTesla, femto_universe_container::EventType::same)) {
533546 continue ;
534547 }
@@ -543,7 +556,6 @@ struct FemtoUniversePairTaskTrackV0Extended {
543556 sameEventCont.setPair <false >(p1, p2, multCol, confUse3D, weight);
544557 }
545558 }
546-
547559 // / This function processes the same event for V0 - V0
548560 template <bool isMC, typename PartType, typename PartitionType, typename MCParticles = std::nullptr_t >
549561 void doSameEventV0 (FilteredFDCollision const & col, PartType const & parts, PartitionType& groupPartsTwo, [[maybe_unused]] MCParticles mcParts = nullptr )
@@ -752,10 +764,10 @@ struct FemtoUniversePairTaskTrackV0Extended {
752764 }
753765 }
754766
755- if (confIsCPR.value ) {
756- if (confRectV0V0CPR && pairCloseRejectionV0.isClosePair <true >(p1, p2, parts, magFieldTesla, femto_universe_container::EventType::same)) {
767+ if (ConfCPR. confIsCPR .value ) {
768+ if (ConfCPR. confRectV0V0CPR && pairCloseRejectionV0.isClosePair <true >(p1, p2, parts, magFieldTesla, femto_universe_container::EventType::same)) {
757769 return false ;
758- } else if (!confRectV0V0CPR && pairCloseRejectionV0.isClosePair <false >(p1, p2, parts, magFieldTesla, femto_universe_container::EventType::same)) {
770+ } else if (!ConfCPR. confRectV0V0CPR && pairCloseRejectionV0.isClosePair <false >(p1, p2, parts, magFieldTesla, femto_universe_container::EventType::same)) {
759771 return false ;
760772 }
761773 }
@@ -773,8 +785,27 @@ struct FemtoUniversePairTaskTrackV0Extended {
773785 }
774786 // / Now build the combinations for V0s
775787 for (const auto & [p1, p2] : combinations (CombinationsStrictlyUpperIndexPolicy (groupPartsTwo, groupPartsTwo))) {
776- if (!pairProcessFunc (p1, p2))
777- pairProcessFunc (p2, p1);
788+ if (!pairProcessFunc (p1, p2)) {
789+ if (pairProcessFunc (p2, p1) && confIsDebug) {
790+ const auto & posChild1 = parts.iteratorAt (p2.globalIndex () - 2 - parts.begin ().globalIndex ());
791+ const auto & negChild1 = parts.iteratorAt (p2.globalIndex () - 1 - parts.begin ().globalIndex ());
792+ const auto & posChild2 = parts.iteratorAt (p1.globalIndex () - 2 - parts.begin ().globalIndex ());
793+ const auto & negChild2 = parts.iteratorAt (p1.globalIndex () - 1 - parts.begin ().globalIndex ());
794+ qaRegistry.fill (HIST (" SameEvent/hPtPosDaugh" ), posChild1.pt (), posChild2.pt ());
795+ qaRegistry.fill (HIST (" SameEvent/hPtNegDaugh" ), negChild1.pt (), negChild2.pt ());
796+ qaRegistry.fill (HIST (" SameEvent/hDaughMomPart1" ), posChild1.pt (), negChild1.pt ());
797+ qaRegistry.fill (HIST (" SameEvent/hDaughMomPart2" ), posChild2.pt (), negChild2.pt ());
798+ }
799+ } else if (confIsDebug) {
800+ const auto & posChild1 = parts.iteratorAt (p1.globalIndex () - 2 - parts.begin ().globalIndex ());
801+ const auto & negChild1 = parts.iteratorAt (p1.globalIndex () - 1 - parts.begin ().globalIndex ());
802+ const auto & posChild2 = parts.iteratorAt (p2.globalIndex () - 2 - parts.begin ().globalIndex ());
803+ const auto & negChild2 = parts.iteratorAt (p2.globalIndex () - 1 - parts.begin ().globalIndex ());
804+ qaRegistry.fill (HIST (" SameEvent/hPtPosDaugh" ), posChild1.pt (), posChild2.pt ());
805+ qaRegistry.fill (HIST (" SameEvent/hPtNegDaugh" ), negChild1.pt (), negChild2.pt ());
806+ qaRegistry.fill (HIST (" SameEvent/hDaughMomPart1" ), posChild1.pt (), negChild1.pt ());
807+ qaRegistry.fill (HIST (" SameEvent/hDaughMomPart2" ), posChild2.pt (), negChild2.pt ());
808+ }
778809 }
779810 }
780811
@@ -861,7 +892,7 @@ struct FemtoUniversePairTaskTrackV0Extended {
861892 if ((ConfV0Selection.confV0Type1 == 0 && pdgCode2 != kLambda0 ) || (ConfV0Selection.confV0Type1 == 1 && pdgCode2 != kLambda0Bar ))
862893 continue ;
863894 // track cleaning
864- if (confIsCPR.value ) {
895+ if (ConfCPR. confIsCPR .value ) {
865896 if (pairCloseRejection.isClosePair (p1, p2, parts, magFieldTesla, femto_universe_container::EventType::same)) {
866897 continue ;
867898 }
@@ -999,7 +1030,7 @@ struct FemtoUniversePairTaskTrackV0Extended {
9991030 if (!pairCleaner.isCleanPair (p1, p2, parts)) {
10001031 continue ;
10011032 }
1002- if (confIsCPR.value ) {
1033+ if (ConfCPR. confIsCPR .value ) {
10031034 if (pairCloseRejection.isClosePair (p1, p2, parts, magFieldTesla1, femto_universe_container::EventType::mixed)) {
10041035 continue ;
10051036 }
@@ -1122,10 +1153,10 @@ struct FemtoUniversePairTaskTrackV0Extended {
11221153 if (!pairCleanerV0.isCleanPair (p1, p2, parts)) {
11231154 continue ;
11241155 }
1125- if (confIsCPR.value ) {
1126- if (confRectV0V0CPR && pairCloseRejectionV0.isClosePair <true >(p1, p2, parts, magFieldTesla1, femto_universe_container::EventType::mixed)) {
1156+ if (ConfCPR. confIsCPR .value ) {
1157+ if (ConfCPR. confRectV0V0CPR && pairCloseRejectionV0.isClosePair <true >(p1, p2, parts, magFieldTesla1, femto_universe_container::EventType::mixed)) {
11271158 continue ;
1128- } else if (!confRectV0V0CPR && pairCloseRejectionV0.isClosePair <false >(p1, p2, parts, magFieldTesla1, femto_universe_container::EventType::mixed)) {
1159+ } else if (!ConfCPR. confRectV0V0CPR && pairCloseRejectionV0.isClosePair <false >(p1, p2, parts, magFieldTesla1, femto_universe_container::EventType::mixed)) {
11291160 continue ;
11301161 }
11311162 }
@@ -1210,7 +1241,7 @@ struct FemtoUniversePairTaskTrackV0Extended {
12101241 int pdgCode2 = static_cast <int >(p2.pidCut ());
12111242 if ((ConfV0Selection.confV0Type1 == 0 && pdgCode2 != kLambda0 ) || (ConfV0Selection.confV0Type1 == 1 && pdgCode2 != kLambda0Bar ))
12121243 continue ;
1213- if (confIsCPR.value ) {
1244+ if (ConfCPR. confIsCPR .value ) {
12141245 if (pairCloseRejection.isClosePair (p1, p2, parts, magFieldTesla1, femto_universe_container::EventType::mixed)) {
12151246 continue ;
12161247 }
@@ -1373,7 +1404,7 @@ struct FemtoUniversePairTaskTrackV0Extended {
13731404 if (!pairCleaner.isCleanPair (p1, p2, parts)) {
13741405 continue ;
13751406 }
1376- if (confIsCPR.value ) {
1407+ if (ConfCPR. confIsCPR .value ) {
13771408 if (pairCloseRejection.isClosePair (p1, p2, parts, magFieldTesla1, femto_universe_container::EventType::mixed)) {
13781409 continue ;
13791410 }
@@ -1465,7 +1496,7 @@ struct FemtoUniversePairTaskTrackV0Extended {
14651496 if (!pairCleanerV0.isCleanPair (p1, p2, parts)) {
14661497 continue ;
14671498 }
1468- if (confIsCPR.value ) {
1499+ if (ConfCPR. confIsCPR .value ) {
14691500 if (pairCloseRejectionV0.isClosePair (p1, p2, parts, magFieldTesla1, femto_universe_container::EventType::mixed)) {
14701501 continue ;
14711502 }
0 commit comments