2828// david.dobrigkeit.chinellato@cern.ch
2929//
3030
31- #include < Math/Vector4D.h>
32- #include < cmath>
33- #include < array>
34- #include < cstdlib>
35- #include < string>
36- #include < map>
37- #include < algorithm>
38- #include < vector>
39-
40- #include < TFile.h>
41- #include < TH2D.h>
42- #include < TProfile.h>
43- #include < TLorentzVector.h>
44- #include < TPDGCode.h>
45-
46- #include " Framework/runDataProcessing.h"
47- #include " Framework/AnalysisTask.h"
48- #include " Framework/AnalysisDataModel.h"
49- #include " Framework/ASoAHelpers.h"
50- #include " DataFormatsParameters/GRPMagField.h"
51- #include " ReconstructionDataFormats/Track.h"
52- #include " CommonConstants/MathConstants.h"
53- #include " CommonConstants/PhysicsConstants.h"
54- #include " Common/Core/trackUtilities.h"
55- #include " Common/CCDB/ctpRateFetcher.h"
56- #include " Common/DataModel/EventSelection.h"
57- #include " PWGLF/DataModel/LFStrangenessTables.h"
5831#include " PWGLF/DataModel/LFStrangenessMLTables.h"
5932#include " PWGLF/DataModel/LFStrangenessPIDTables.h"
33+ #include " PWGLF/DataModel/LFStrangenessTables.h"
34+ #include " PWGUD/Core/SGSelector.h"
35+
36+ #include " Common/CCDB/ctpRateFetcher.h"
6037#include " Common/Core/TrackSelection.h"
61- #include " Common/DataModel/TrackSelectionTables.h"
38+ #include " Common/Core/trackUtilities.h"
39+ #include " Common/DataModel/Centrality.h"
6240#include " Common/DataModel/EventSelection.h"
6341#include " Common/DataModel/Multiplicity.h"
64- #include " Common/DataModel/Centrality.h"
6542#include " Common/DataModel/PIDResponse.h"
66- #include " PWGUD/Core/SGSelector .h"
43+ #include " Common/DataModel/TrackSelectionTables .h"
6744#include " Tools/ML/MlResponse.h"
6845#include " Tools/ML/model.h"
6946
47+ #include " CommonConstants/MathConstants.h"
48+ #include " CommonConstants/PhysicsConstants.h"
49+ #include " DataFormatsParameters/GRPMagField.h"
50+ #include " Framework/ASoAHelpers.h"
51+ #include " Framework/AnalysisDataModel.h"
52+ #include " Framework/AnalysisTask.h"
53+ #include " Framework/runDataProcessing.h"
54+ #include " ReconstructionDataFormats/Track.h"
55+
56+ #include < Math/Vector4D.h>
57+ #include < TFile.h>
58+ #include < TH2D.h>
59+ #include < TLorentzVector.h>
60+ #include < TPDGCode.h>
61+ #include < TProfile.h>
62+
63+ #include < algorithm>
64+ #include < array>
65+ #include < cmath>
66+ #include < cstdlib>
67+ #include < map>
68+ #include < string>
69+ #include < vector>
70+
7071using namespace o2 ;
7172using namespace o2 ::framework;
7273using namespace o2 ::framework::expressions;
@@ -675,48 +676,48 @@ struct derivedlambdakzeroanalysis {
675676
676677 auto hSelectionV0s = histos.add <TH1>(" GeneralQA/hSelectionV0s" , " hSelectionV0s" , kTH1D , {{static_cast <int >(selPhysPrimAntiLambda) + 3 , -0 .5f , static_cast <double >(selPhysPrimAntiLambda) + 2 .5f }});
677678 hSelectionV0s->GetXaxis ()->SetBinLabel (1 , " All" );
678- hSelectionV0s->GetXaxis ()->SetBinLabel (selCosPA+ 2 , " cosPA" );
679- hSelectionV0s->GetXaxis ()->SetBinLabel (selRadius+ 2 , " Radius min." );
680- hSelectionV0s->GetXaxis ()->SetBinLabel (selRadiusMax+ 2 , " Radius max." );
681- hSelectionV0s->GetXaxis ()->SetBinLabel (selDCANegToPV+ 2 , " DCA neg. to PV" );
682- hSelectionV0s->GetXaxis ()->SetBinLabel (selDCAPosToPV+ 2 , " DCA pos. to PV" );
683- hSelectionV0s->GetXaxis ()->SetBinLabel (selDCAV0Dau+ 2 , " DCA V0 dau." );
684- hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortRapidity+ 2 , " K^{0}_{S} rapidity" );
685- hSelectionV0s->GetXaxis ()->SetBinLabel (selLambdaRapidity+ 2 , " #Lambda rapidity" );
686- hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDPositivePion+ 2 , " TPC PID #pi^{+}" );
687- hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDNegativePion+ 2 , " TPC PID #pi^{-}" );
688- hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDPositiveProton+ 2 , " TPC PID p" );
689- hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDNegativeProton+ 2 , " TPC PID #bar{p}" );
690- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositiveProtonLambda+ 2 , " TOF #Delta t p from #Lambda" );
691- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositivePionLambda+ 2 , " TOF #Delta t #pi^{+} from #Lambda" );
692- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositivePionK0Short+ 2 , " TOF #Delta t #pi^{+} from K^{0}_{S}" );
693- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativeProtonLambda+ 2 , " TOF #Delta t #bar{p} from #Lambda" );
694- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativePionLambda+ 2 , " TOF #Delta t #pi^{-} from #Lambda" );
695- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativePionK0Short+ 2 , " TOF #Delta t #pi^{-} from K^{0}_{S}" );
696- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositiveProtonLambda+ 2 , " TOF PID p from #Lambda" );
697- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositivePionLambda+ 2 , " TOF PID #pi^{+} from #Lambda" );
698- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositivePionK0Short+ 2 , " TOF PID #pi^{+} from K^{0}_{S}" );
699- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativeProtonLambda+ 2 , " TOF PID #bar{p} from #Lambda" );
700- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativePionLambda+ 2 , " TOF PID #pi^{-} from #Lambda" );
701- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativePionK0Short+ 2 , " TOF PID #pi^{-} from K^{0}_{S}" );
702- hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortCTau+ 2 , " K^{0}_{S} lifetime" );
703- hSelectionV0s->GetXaxis ()->SetBinLabel (selLambdaCTau+ 2 , " #Lambda lifetime" );
704- hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortArmenteros+ 2 , " Arm. pod. cut" );
705- hSelectionV0s->GetXaxis ()->SetBinLabel (selPosGoodTPCTrack+ 2 , " Pos. good TPC track" );
706- hSelectionV0s->GetXaxis ()->SetBinLabel (selNegGoodTPCTrack+ 2 , " Neg. good TPC track" );
707- hSelectionV0s->GetXaxis ()->SetBinLabel (selPosGoodITSTrack+ 2 , " Pos. good ITS track" );
708- hSelectionV0s->GetXaxis ()->SetBinLabel (selNegGoodITSTrack+ 2 , " Neg. good ITS track" );
709- hSelectionV0s->GetXaxis ()->SetBinLabel (selPosItsOnly+ 2 , " Pos. ITS-only" );
710- hSelectionV0s->GetXaxis ()->SetBinLabel (selNegItsOnly+ 2 , " Neg. ITS-only" );
711- hSelectionV0s->GetXaxis ()->SetBinLabel (selPosNotTPCOnly+ 2 , " Pos. not TPC-only" );
712- hSelectionV0s->GetXaxis ()->SetBinLabel (selNegNotTPCOnly+ 2 , " Neg. not TPC-only" );
713- hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderK0Short+ 2 , " True K^{0}_{S}" );
714- hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderLambda+ 2 , " True #Lambda" );
715- hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderAntiLambda+ 2 , " True #bar{#Lambda}" );
716- hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimK0Short+ 2 , " Phys. prim. K^{0}_{S}" );
717- hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimLambda+ 2 , " Phys. prim. #Lambda" );
718- hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimAntiLambda+ 2 , " Phys. prim. #bar{#Lambda}" );
719- hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimAntiLambda+ 3 , " Cand. selected" );
679+ hSelectionV0s->GetXaxis ()->SetBinLabel (selCosPA + 2 , " cosPA" );
680+ hSelectionV0s->GetXaxis ()->SetBinLabel (selRadius + 2 , " Radius min." );
681+ hSelectionV0s->GetXaxis ()->SetBinLabel (selRadiusMax + 2 , " Radius max." );
682+ hSelectionV0s->GetXaxis ()->SetBinLabel (selDCANegToPV + 2 , " DCA neg. to PV" );
683+ hSelectionV0s->GetXaxis ()->SetBinLabel (selDCAPosToPV + 2 , " DCA pos. to PV" );
684+ hSelectionV0s->GetXaxis ()->SetBinLabel (selDCAV0Dau + 2 , " DCA V0 dau." );
685+ hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortRapidity + 2 , " K^{0}_{S} rapidity" );
686+ hSelectionV0s->GetXaxis ()->SetBinLabel (selLambdaRapidity + 2 , " #Lambda rapidity" );
687+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDPositivePion + 2 , " TPC PID #pi^{+}" );
688+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDNegativePion + 2 , " TPC PID #pi^{-}" );
689+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDPositiveProton + 2 , " TPC PID p" );
690+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDNegativeProton + 2 , " TPC PID #bar{p}" );
691+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositiveProtonLambda + 2 , " TOF #Delta t p from #Lambda" );
692+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositivePionLambda + 2 , " TOF #Delta t #pi^{+} from #Lambda" );
693+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositivePionK0Short + 2 , " TOF #Delta t #pi^{+} from K^{0}_{S}" );
694+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativeProtonLambda + 2 , " TOF #Delta t #bar{p} from #Lambda" );
695+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativePionLambda + 2 , " TOF #Delta t #pi^{-} from #Lambda" );
696+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativePionK0Short + 2 , " TOF #Delta t #pi^{-} from K^{0}_{S}" );
697+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositiveProtonLambda + 2 , " TOF PID p from #Lambda" );
698+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositivePionLambda + 2 , " TOF PID #pi^{+} from #Lambda" );
699+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositivePionK0Short + 2 , " TOF PID #pi^{+} from K^{0}_{S}" );
700+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativeProtonLambda + 2 , " TOF PID #bar{p} from #Lambda" );
701+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativePionLambda + 2 , " TOF PID #pi^{-} from #Lambda" );
702+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativePionK0Short + 2 , " TOF PID #pi^{-} from K^{0}_{S}" );
703+ hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortCTau + 2 , " K^{0}_{S} lifetime" );
704+ hSelectionV0s->GetXaxis ()->SetBinLabel (selLambdaCTau + 2 , " #Lambda lifetime" );
705+ hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortArmenteros + 2 , " Arm. pod. cut" );
706+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPosGoodTPCTrack + 2 , " Pos. good TPC track" );
707+ hSelectionV0s->GetXaxis ()->SetBinLabel (selNegGoodTPCTrack + 2 , " Neg. good TPC track" );
708+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPosGoodITSTrack + 2 , " Pos. good ITS track" );
709+ hSelectionV0s->GetXaxis ()->SetBinLabel (selNegGoodITSTrack + 2 , " Neg. good ITS track" );
710+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPosItsOnly + 2 , " Pos. ITS-only" );
711+ hSelectionV0s->GetXaxis ()->SetBinLabel (selNegItsOnly + 2 , " Neg. ITS-only" );
712+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPosNotTPCOnly + 2 , " Pos. not TPC-only" );
713+ hSelectionV0s->GetXaxis ()->SetBinLabel (selNegNotTPCOnly + 2 , " Neg. not TPC-only" );
714+ hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderK0Short + 2 , " True K^{0}_{S}" );
715+ hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderLambda + 2 , " True #Lambda" );
716+ hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderAntiLambda + 2 , " True #bar{#Lambda}" );
717+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimK0Short + 2 , " Phys. prim. K^{0}_{S}" );
718+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimLambda + 2 , " Phys. prim. #Lambda" );
719+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimAntiLambda + 2 , " Phys. prim. #bar{#Lambda}" );
720+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimAntiLambda + 3 , " Cand. selected" );
720721
721722 // histograms versus mass
722723 if (analyseK0Short) {
@@ -1129,7 +1130,7 @@ struct derivedlambdakzeroanalysis {
11291130 phi = TMath::TwoPi () - phi;
11301131 if (sign < 0 ) // for negative charge
11311132 phi = TMath::TwoPi () - phi;
1132- if (phi < 0 )
1133+ if (phi < 0 )
11331134 LOGF (warning, " phi < 0: %g" , phi);
11341135
11351136 phi += TMath::Pi () / 18.0 ; // to center gap in the middle
@@ -1144,7 +1145,7 @@ struct derivedlambdakzeroanalysis {
11441145 return true ; // keep track
11451146 if (phiModn < fPhiCutLow ->Eval (trackPt))
11461147 return true ; // keep track
1147- return false ; // reject track
1148+ return false ; // reject track
11481149 }
11491150
11501151 template <typename TV0, typename TCollision>
@@ -1199,12 +1200,12 @@ struct derivedlambdakzeroanalysis {
11991200 posTrackExtra.tpcFractionSharedCls () < v0Selections.maxFractionTPCSharedClusters && // check the maximum fraction of allowed shared TPC clusters
12001201 (!v0Selections.rejectTPCsectorBoundary || isTrackFarFromTPCBoundary (v0.positivept (), v0.positivephi (), 1 ))) // reject track far from TPC sector boundary or not
12011202 BITSET (bitMap, selPosGoodTPCTrack);
1202- if (negTrackExtra.tpcCrossedRows () >= v0Selections.minTPCrows && // check minimum TPC crossed rows
1203- negTrackExtra.tpcChi2NCl () < v0Selections.maxTPCchi2PerNcls && // check maximum TPC chi2 per clusters
1204- negTrackExtra.tpcCrossedRowsOverFindableCls () >= v0Selections.minTPCrowsOverFindableClusters && // check minimum fraction of TPC rows over findable
1205- negTrackExtra.tpcFoundOverFindableCls () >= v0Selections.minTPCfoundOverFindableClusters && // check minimum fraction of found over findable TPC clusters
1206- negTrackExtra.tpcFractionSharedCls () < v0Selections.maxFractionTPCSharedClusters && // check the maximum fraction of allowed shared TPC clusters
1207- (!v0Selections.rejectTPCsectorBoundary || isTrackFarFromTPCBoundary (v0.negativept (), v0.negativephi (), -1 )))// reject track far from TPC sector boundary or not
1203+ if (negTrackExtra.tpcCrossedRows () >= v0Selections.minTPCrows && // check minimum TPC crossed rows
1204+ negTrackExtra.tpcChi2NCl () < v0Selections.maxTPCchi2PerNcls && // check maximum TPC chi2 per clusters
1205+ negTrackExtra.tpcCrossedRowsOverFindableCls () >= v0Selections.minTPCrowsOverFindableClusters && // check minimum fraction of TPC rows over findable
1206+ negTrackExtra.tpcFoundOverFindableCls () >= v0Selections.minTPCfoundOverFindableClusters && // check minimum fraction of found over findable TPC clusters
1207+ negTrackExtra.tpcFractionSharedCls () < v0Selections.maxFractionTPCSharedClusters && // check the maximum fraction of allowed shared TPC clusters
1208+ (!v0Selections.rejectTPCsectorBoundary || isTrackFarFromTPCBoundary (v0.negativept (), v0.negativephi (), -1 ))) // reject track far from TPC sector boundary or not
12081209 BITSET (bitMap, selNegGoodTPCTrack);
12091210
12101211 // TPC PID
@@ -1552,7 +1553,7 @@ struct derivedlambdakzeroanalysis {
15521553 // __________________________________________
15531554 // main analysis
15541555 if (passK0ShortSelections && analyseK0Short) {
1555- histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda+ 2 ); //
1556+ histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda + 2 ); //
15561557 histos.fill (HIST (" GeneralQA/h2dArmenterosSelected" ), v0.alpha (), v0.qtarm ()); // cross-check
15571558 histos.fill (HIST (" h3dMassK0Short" ), centrality, pt, v0.mK0Short ());
15581559 if (gapSide == 0 )
@@ -1636,7 +1637,7 @@ struct derivedlambdakzeroanalysis {
16361637 nK0Shorts++;
16371638 }
16381639 if (passLambdaSelections && analyseLambda) {
1639- histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda+ 2 ); //
1640+ histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda + 2 ); //
16401641 histos.fill (HIST (" h3dMassLambda" ), centrality, pt, v0.mLambda ());
16411642 if (gapSide == 0 )
16421643 histos.fill (HIST (" h3dMassLambdaSGA" ), centrality, pt, v0.mLambda ());
@@ -1719,7 +1720,7 @@ struct derivedlambdakzeroanalysis {
17191720 nLambdas++;
17201721 }
17211722 if (passAntiLambdaSelections && analyseAntiLambda) {
1722- histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda+ 2 ); //
1723+ histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda + 2 ); //
17231724 histos.fill (HIST (" h3dMassAntiLambda" ), centrality, pt, v0.mAntiLambda ());
17241725 if (gapSide == 0 )
17251726 histos.fill (HIST (" h3dMassAntiLambdaSGA" ), centrality, pt, v0.mAntiLambda ());
0 commit comments