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;
@@ -684,48 +685,48 @@ struct derivedlambdakzeroanalysis {
684685
685686 auto hSelectionV0s = histos.add <TH1>(" GeneralQA/hSelectionV0s" , " hSelectionV0s" , kTH1D , {{static_cast <int >(selPhysPrimAntiLambda) + 3 , -0 .5f , static_cast <double >(selPhysPrimAntiLambda) + 2 .5f }});
686687 hSelectionV0s->GetXaxis ()->SetBinLabel (1 , " All" );
687- hSelectionV0s->GetXaxis ()->SetBinLabel (selCosPA+ 2 , " cosPA" );
688- hSelectionV0s->GetXaxis ()->SetBinLabel (selRadius+ 2 , " Radius min." );
689- hSelectionV0s->GetXaxis ()->SetBinLabel (selRadiusMax+ 2 , " Radius max." );
690- hSelectionV0s->GetXaxis ()->SetBinLabel (selDCANegToPV+ 2 , " DCA neg. to PV" );
691- hSelectionV0s->GetXaxis ()->SetBinLabel (selDCAPosToPV+ 2 , " DCA pos. to PV" );
692- hSelectionV0s->GetXaxis ()->SetBinLabel (selDCAV0Dau+ 2 , " DCA V0 dau." );
693- hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortRapidity+ 2 , " K^{0}_{S} rapidity" );
694- hSelectionV0s->GetXaxis ()->SetBinLabel (selLambdaRapidity+ 2 , " #Lambda rapidity" );
695- hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDPositivePion+ 2 , " TPC PID #pi^{+}" );
696- hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDNegativePion+ 2 , " TPC PID #pi^{-}" );
697- hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDPositiveProton+ 2 , " TPC PID p" );
698- hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDNegativeProton+ 2 , " TPC PID #bar{p}" );
699- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositiveProtonLambda+ 2 , " TOF #Delta t p from #Lambda" );
700- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositivePionLambda+ 2 , " TOF #Delta t #pi^{+} from #Lambda" );
701- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositivePionK0Short+ 2 , " TOF #Delta t #pi^{+} from K^{0}_{S}" );
702- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativeProtonLambda+ 2 , " TOF #Delta t #bar{p} from #Lambda" );
703- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativePionLambda+ 2 , " TOF #Delta t #pi^{-} from #Lambda" );
704- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativePionK0Short+ 2 , " TOF #Delta t #pi^{-} from K^{0}_{S}" );
705- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositiveProtonLambda+ 2 , " TOF PID p from #Lambda" );
706- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositivePionLambda+ 2 , " TOF PID #pi^{+} from #Lambda" );
707- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositivePionK0Short+ 2 , " TOF PID #pi^{+} from K^{0}_{S}" );
708- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativeProtonLambda+ 2 , " TOF PID #bar{p} from #Lambda" );
709- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativePionLambda+ 2 , " TOF PID #pi^{-} from #Lambda" );
710- hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativePionK0Short+ 2 , " TOF PID #pi^{-} from K^{0}_{S}" );
711- hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortCTau+ 2 , " K^{0}_{S} lifetime" );
712- hSelectionV0s->GetXaxis ()->SetBinLabel (selLambdaCTau+ 2 , " #Lambda lifetime" );
713- hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortArmenteros+ 2 , " Arm. pod. cut" );
714- hSelectionV0s->GetXaxis ()->SetBinLabel (selPosGoodTPCTrack+ 2 , " Pos. good TPC track" );
715- hSelectionV0s->GetXaxis ()->SetBinLabel (selNegGoodTPCTrack+ 2 , " Neg. good TPC track" );
716- hSelectionV0s->GetXaxis ()->SetBinLabel (selPosGoodITSTrack+ 2 , " Pos. good ITS track" );
717- hSelectionV0s->GetXaxis ()->SetBinLabel (selNegGoodITSTrack+ 2 , " Neg. good ITS track" );
718- hSelectionV0s->GetXaxis ()->SetBinLabel (selPosItsOnly+ 2 , " Pos. ITS-only" );
719- hSelectionV0s->GetXaxis ()->SetBinLabel (selNegItsOnly+ 2 , " Neg. ITS-only" );
720- hSelectionV0s->GetXaxis ()->SetBinLabel (selPosNotTPCOnly+ 2 , " Pos. not TPC-only" );
721- hSelectionV0s->GetXaxis ()->SetBinLabel (selNegNotTPCOnly+ 2 , " Neg. not TPC-only" );
722- hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderK0Short+ 2 , " True K^{0}_{S}" );
723- hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderLambda+ 2 , " True #Lambda" );
724- hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderAntiLambda+ 2 , " True #bar{#Lambda}" );
725- hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimK0Short+ 2 , " Phys. prim. K^{0}_{S}" );
726- hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimLambda+ 2 , " Phys. prim. #Lambda" );
727- hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimAntiLambda+ 2 , " Phys. prim. #bar{#Lambda}" );
728- hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimAntiLambda+ 3 , " Cand. selected" );
688+ hSelectionV0s->GetXaxis ()->SetBinLabel (selCosPA + 2 , " cosPA" );
689+ hSelectionV0s->GetXaxis ()->SetBinLabel (selRadius + 2 , " Radius min." );
690+ hSelectionV0s->GetXaxis ()->SetBinLabel (selRadiusMax + 2 , " Radius max." );
691+ hSelectionV0s->GetXaxis ()->SetBinLabel (selDCANegToPV + 2 , " DCA neg. to PV" );
692+ hSelectionV0s->GetXaxis ()->SetBinLabel (selDCAPosToPV + 2 , " DCA pos. to PV" );
693+ hSelectionV0s->GetXaxis ()->SetBinLabel (selDCAV0Dau + 2 , " DCA V0 dau." );
694+ hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortRapidity + 2 , " K^{0}_{S} rapidity" );
695+ hSelectionV0s->GetXaxis ()->SetBinLabel (selLambdaRapidity + 2 , " #Lambda rapidity" );
696+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDPositivePion + 2 , " TPC PID #pi^{+}" );
697+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDNegativePion + 2 , " TPC PID #pi^{-}" );
698+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDPositiveProton + 2 , " TPC PID p" );
699+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTPCPIDNegativeProton + 2 , " TPC PID #bar{p}" );
700+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositiveProtonLambda + 2 , " TOF #Delta t p from #Lambda" );
701+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositivePionLambda + 2 , " TOF #Delta t #pi^{+} from #Lambda" );
702+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTPositivePionK0Short + 2 , " TOF #Delta t #pi^{+} from K^{0}_{S}" );
703+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativeProtonLambda + 2 , " TOF #Delta t #bar{p} from #Lambda" );
704+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativePionLambda + 2 , " TOF #Delta t #pi^{-} from #Lambda" );
705+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFDeltaTNegativePionK0Short + 2 , " TOF #Delta t #pi^{-} from K^{0}_{S}" );
706+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositiveProtonLambda + 2 , " TOF PID p from #Lambda" );
707+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositivePionLambda + 2 , " TOF PID #pi^{+} from #Lambda" );
708+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaPositivePionK0Short + 2 , " TOF PID #pi^{+} from K^{0}_{S}" );
709+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativeProtonLambda + 2 , " TOF PID #bar{p} from #Lambda" );
710+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativePionLambda + 2 , " TOF PID #pi^{-} from #Lambda" );
711+ hSelectionV0s->GetXaxis ()->SetBinLabel (selTOFNSigmaNegativePionK0Short + 2 , " TOF PID #pi^{-} from K^{0}_{S}" );
712+ hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortCTau + 2 , " K^{0}_{S} lifetime" );
713+ hSelectionV0s->GetXaxis ()->SetBinLabel (selLambdaCTau + 2 , " #Lambda lifetime" );
714+ hSelectionV0s->GetXaxis ()->SetBinLabel (selK0ShortArmenteros + 2 , " Arm. pod. cut" );
715+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPosGoodTPCTrack + 2 , " Pos. good TPC track" );
716+ hSelectionV0s->GetXaxis ()->SetBinLabel (selNegGoodTPCTrack + 2 , " Neg. good TPC track" );
717+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPosGoodITSTrack + 2 , " Pos. good ITS track" );
718+ hSelectionV0s->GetXaxis ()->SetBinLabel (selNegGoodITSTrack + 2 , " Neg. good ITS track" );
719+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPosItsOnly + 2 , " Pos. ITS-only" );
720+ hSelectionV0s->GetXaxis ()->SetBinLabel (selNegItsOnly + 2 , " Neg. ITS-only" );
721+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPosNotTPCOnly + 2 , " Pos. not TPC-only" );
722+ hSelectionV0s->GetXaxis ()->SetBinLabel (selNegNotTPCOnly + 2 , " Neg. not TPC-only" );
723+ hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderK0Short + 2 , " True K^{0}_{S}" );
724+ hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderLambda + 2 , " True #Lambda" );
725+ hSelectionV0s->GetXaxis ()->SetBinLabel (selConsiderAntiLambda + 2 , " True #bar{#Lambda}" );
726+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimK0Short + 2 , " Phys. prim. K^{0}_{S}" );
727+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimLambda + 2 , " Phys. prim. #Lambda" );
728+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimAntiLambda + 2 , " Phys. prim. #bar{#Lambda}" );
729+ hSelectionV0s->GetXaxis ()->SetBinLabel (selPhysPrimAntiLambda + 3 , " Cand. selected" );
729730
730731 // histograms versus mass
731732 if (analyseK0Short) {
@@ -1172,7 +1173,7 @@ struct derivedlambdakzeroanalysis {
11721173 phi = TMath::TwoPi () - phi;
11731174 if (sign < 0 ) // for negative charge
11741175 phi = TMath::TwoPi () - phi;
1175- if (phi < 0 )
1176+ if (phi < 0 )
11761177 LOGF (warning, " phi < 0: %g" , phi);
11771178
11781179 phi += TMath::Pi () / 18.0 ; // to center gap in the middle
@@ -1187,7 +1188,7 @@ struct derivedlambdakzeroanalysis {
11871188 return true ; // keep track
11881189 if (phiModn < fPhiCutLow ->Eval (trackPt))
11891190 return true ; // keep track
1190- return false ; // reject track
1191+ return false ; // reject track
11911192 }
11921193
11931194 template <typename TV0, typename TCollision>
@@ -1242,12 +1243,12 @@ struct derivedlambdakzeroanalysis {
12421243 posTrackExtra.tpcFractionSharedCls () < v0Selections.maxFractionTPCSharedClusters && // check the maximum fraction of allowed shared TPC clusters
12431244 (!v0Selections.rejectTPCsectorBoundary || isTrackFarFromTPCBoundary (v0.positivept (), v0.positivephi (), 1 ))) // reject track far from TPC sector boundary or not
12441245 BITSET (bitMap, selPosGoodTPCTrack);
1245- if (negTrackExtra.tpcCrossedRows () >= v0Selections.minTPCrows && // check minimum TPC crossed rows
1246- negTrackExtra.tpcChi2NCl () < v0Selections.maxTPCchi2PerNcls && // check maximum TPC chi2 per clusters
1247- negTrackExtra.tpcCrossedRowsOverFindableCls () >= v0Selections.minTPCrowsOverFindableClusters && // check minimum fraction of TPC rows over findable
1248- negTrackExtra.tpcFoundOverFindableCls () >= v0Selections.minTPCfoundOverFindableClusters && // check minimum fraction of found over findable TPC clusters
1249- negTrackExtra.tpcFractionSharedCls () < v0Selections.maxFractionTPCSharedClusters && // check the maximum fraction of allowed shared TPC clusters
1250- (!v0Selections.rejectTPCsectorBoundary || isTrackFarFromTPCBoundary (v0.negativept (), v0.negativephi (), -1 )))// reject track far from TPC sector boundary or not
1246+ if (negTrackExtra.tpcCrossedRows () >= v0Selections.minTPCrows && // check minimum TPC crossed rows
1247+ negTrackExtra.tpcChi2NCl () < v0Selections.maxTPCchi2PerNcls && // check maximum TPC chi2 per clusters
1248+ negTrackExtra.tpcCrossedRowsOverFindableCls () >= v0Selections.minTPCrowsOverFindableClusters && // check minimum fraction of TPC rows over findable
1249+ negTrackExtra.tpcFoundOverFindableCls () >= v0Selections.minTPCfoundOverFindableClusters && // check minimum fraction of found over findable TPC clusters
1250+ negTrackExtra.tpcFractionSharedCls () < v0Selections.maxFractionTPCSharedClusters && // check the maximum fraction of allowed shared TPC clusters
1251+ (!v0Selections.rejectTPCsectorBoundary || isTrackFarFromTPCBoundary (v0.negativept (), v0.negativephi (), -1 ))) // reject track far from TPC sector boundary or not
12511252 BITSET (bitMap, selNegGoodTPCTrack);
12521253
12531254 // TPC PID
@@ -1595,7 +1596,7 @@ struct derivedlambdakzeroanalysis {
15951596 // __________________________________________
15961597 // main analysis
15971598 if (passK0ShortSelections && analyseK0Short) {
1598- histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda+ 2 ); //
1599+ histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda + 2 ); //
15991600 histos.fill (HIST (" GeneralQA/h2dArmenterosSelected" ), v0.alpha (), v0.qtarm ()); // cross-check
16001601 histos.fill (HIST (" h3dMassK0Short" ), centrality, pt, v0.mK0Short ());
16011602 if (gapSide == 0 )
@@ -1679,7 +1680,7 @@ struct derivedlambdakzeroanalysis {
16791680 nK0Shorts++;
16801681 }
16811682 if (passLambdaSelections && analyseLambda) {
1682- histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda+ 2 ); //
1683+ histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda + 2 ); //
16831684 histos.fill (HIST (" h3dMassLambda" ), centrality, pt, v0.mLambda ());
16841685 if (gapSide == 0 )
16851686 histos.fill (HIST (" h3dMassLambdaSGA" ), centrality, pt, v0.mLambda ());
@@ -1762,7 +1763,7 @@ struct derivedlambdakzeroanalysis {
17621763 nLambdas++;
17631764 }
17641765 if (passAntiLambdaSelections && analyseAntiLambda) {
1765- histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda+ 2 ); //
1766+ histos.fill (HIST (" GeneralQA/hSelectionV0s" ), selPhysPrimAntiLambda + 2 ); //
17661767 histos.fill (HIST (" h3dMassAntiLambda" ), centrality, pt, v0.mAntiLambda ());
17671768 if (gapSide == 0 )
17681769 histos.fill (HIST (" h3dMassAntiLambdaSGA" ), centrality, pt, v0.mAntiLambda ());
0 commit comments