Skip to content

Commit 1e184be

Browse files
[PWGHF] Added table for Sc reco info (#16006)
Co-authored-by: ALICE Action Bot <alibuild@cern.ch>
1 parent 6aa03d7 commit 1e184be

2 files changed

Lines changed: 37 additions & 5 deletions

File tree

PWGHF/HFC/DataModel/CorrelationTables.h

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,7 @@ DECLARE_SOA_COLUMN(DeltaEta, deltaEta, float); //! D
149149
DECLARE_SOA_COLUMN(DeltaY, deltaY, float); //! DeltaY between Lc and Hadrons
150150
DECLARE_SOA_COLUMN(PtLc, ptLc, float); //! Transverse momentum of Lc
151151
DECLARE_SOA_COLUMN(PtHadron, ptHadron, float); //! Transverse momentum of Hadron
152+
DECLARE_SOA_COLUMN(PtSoftPi, ptSoftPi, float); //! Transverse momentum of Soft Pion
152153
DECLARE_SOA_COLUMN(ChargeCand, chargeCand, int); //! store charge of Lc and Sc
153154
DECLARE_SOA_COLUMN(MLc, mLc, float); //! Invariant mass of Lc
154155
DECLARE_SOA_COLUMN(MlScoreBkg, mlScoreBkg, float); //! ML background score for Lc selection
@@ -157,6 +158,8 @@ DECLARE_SOA_COLUMN(SignalStatus, signalStatus, int); //! T
157158
DECLARE_SOA_COLUMN(PoolBin, poolBin, int); //! Pool Bin for the MixedEvent
158159
DECLARE_SOA_COLUMN(TrackDcaXY, trackDcaXY, float); //! DCA xy of the track
159160
DECLARE_SOA_COLUMN(TrackDcaZ, trackDcaZ, float); //! DCA z of the track
161+
DECLARE_SOA_COLUMN(SoftPiDcaXY, softPiDcaXY, float); //! DCA xy of the soft pion
162+
DECLARE_SOA_COLUMN(SoftPiDcaZ, softPiDcaZ, float); //! DCA z of the soft pion
160163
DECLARE_SOA_COLUMN(TrackTPCNClsCrossedRows, trackTPCNClsCrossedRows, int); //! Number of crossed TPC Rows
161164
DECLARE_SOA_COLUMN(TrackOrigin, trackOrigin, int); //! Number of crossed TPC Rows
162165
DECLARE_SOA_COLUMN(IsSignal, isSignal, bool); //! Used in MC-Rec, Lc Signal
@@ -175,6 +178,18 @@ DECLARE_SOA_COLUMN(PiNsigmTOF, piNsigmTOF, float); //! A
175178
DECLARE_SOA_TABLE(PtLcFromScHPair, "AOD", "PTLCSCHPAIR", //! Sc-->Lc pT for paired Sc-proton
176179
aod::hf_correlation_lc_hadron::PtLc);
177180

181+
DECLARE_SOA_TABLE(ScRecoInfo, "AOD", "SCRECOINFO", //! Sc reco info
182+
aod::hf_correlation_lc_hadron::MLc,
183+
aod::hf_correlation_lc_hadron::PtSoftPi,
184+
aod::hf_correlation_lc_hadron::SoftPiDcaXY,
185+
aod::hf_correlation_lc_hadron::SoftPiDcaZ);
186+
187+
DECLARE_SOA_TABLE(ScHadronRecoInfo, "AOD", "SCHADRECOINFO", //! Sc reco info
188+
aod::hf_correlation_lc_hadron::MLc,
189+
aod::hf_correlation_lc_hadron::PtSoftPi,
190+
aod::hf_correlation_lc_hadron::SoftPiDcaXY,
191+
aod::hf_correlation_lc_hadron::SoftPiDcaZ);
192+
178193
DECLARE_SOA_TABLE(PtLcFromSc, "AOD", "PTLCSC", //! Sc-->Lc pT
179194
aod::hf_correlation_lc_hadron::PtLc);
180195

PWGHF/HFC/TableProducer/correlatorLcScHadrons.cxx

Lines changed: 22 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -317,8 +317,10 @@ struct HfCorrelatorLcScHadrons {
317317
Produces<aod::LcHadronPairY> entryCandHadronPairY;
318318
Produces<aod::LcHadronPairTrkPID> entryCandHadronPairTrkPID;
319319
Produces<aod::LcHadronRecoInfo> entryCandHadronRecoInfo;
320+
Produces<aod::ScHadronRecoInfo> entryScHadronRecoInfoExt;
320321
Produces<aod::LcHadronMlInfo> entryCandHadronMlInfo;
321-
Produces<aod::LcRecoInfo> entryCandCandRecoInfo;
322+
Produces<aod::LcRecoInfo> entryCandRecoInfo;
323+
Produces<aod::ScRecoInfo> entryScRecoInfoExt;
322324
Produces<aod::LcHadronGenInfo> entryCandHadronGenInfo;
323325
Produces<aod::LcGenInfo> entryCandCandGenInfo;
324326
Produces<aod::TrkRecInfoLc> entryTrackRecoInfo;
@@ -812,12 +814,17 @@ struct HfCorrelatorLcScHadrons {
812814
double yCand = -999.0;
813815
double etaCand = -999.0;
814816
double ptScProng0 = -999.0;
817+
double ptSoftPi = -999.0;
818+
double massPKPiLcFromSc = -999.0;
819+
double massPiKPLcFromSc = -999.0;
815820
double ptCand = -999.0;
816821
double phiCand = -999.0;
817822
double massCandPKPi = -999.0;
818823
double massCandPiKP = -999.0;
819824
bool selLcPKPi = false;
820825
bool selLcPiKP = false;
826+
float softPiAbsDcaXY = -999.0;
827+
float softPiAbsDcaZ = -999.0;
821828

822829
yCand = estimateY<IsCandSc>(candidate);
823830
etaCand = candidate.eta();
@@ -847,17 +854,21 @@ struct HfCorrelatorLcScHadrons {
847854
chargeCand = candidate.charge();
848855
const auto& candidateLc = candidate.template prongLc_as<CandsLcData>();
849856
ptScProng0 = candidateLc.pt();
857+
softPiAbsDcaXY = std::abs(candidate.softPiDcaXY());
858+
softPiAbsDcaZ = std::abs(candidate.softPiDcaZ());
850859
selLcPKPi = (candidateLc.isSelLcToPKPi() >= selectionFlagLc) && (candidate.statusSpreadLcMinvPKPiFromPDG());
851860
selLcPiKP = (candidateLc.isSelLcToPiKP() >= selectionFlagLc) && (candidate.statusSpreadLcMinvPiKPFromPDG());
852861
if (selLcPKPi) {
853862
const auto& probs = candidateLc.mlProbLcToPKPi();
854863
fillMlOutput(probs, outputMlPKPi);
855-
massCandPKPi = std::abs(HfHelper::invMassScRecoLcToPKPi(candidate, candidateLc) - HfHelper::invMassLcToPKPi(candidateLc));
864+
massPKPiLcFromSc = HfHelper::invMassLcToPKPi(candidateLc);
865+
massCandPKPi = std::abs(HfHelper::invMassScRecoLcToPKPi(candidate, candidateLc) - massPKPiLcFromSc);
856866
}
857867
if (selLcPiKP) {
858868
const auto& probs = candidateLc.mlProbLcToPiKP();
859869
fillMlOutput(probs, outputMlPiKP);
860-
massCandPiKP = std::abs(HfHelper::invMassScRecoLcToPiKP(candidate, candidateLc) - HfHelper::invMassLcToPiKP(candidateLc));
870+
massPiKPLcFromSc = HfHelper::invMassLcToPiKP(candidateLc);
871+
massCandPiKP = std::abs(HfHelper::invMassScRecoLcToPiKP(candidate, candidateLc) - massPiKPLcFromSc);
861872
}
862873
if constexpr (IsMcRec) {
863874
// isSignal =
@@ -870,12 +881,14 @@ struct HfCorrelatorLcScHadrons {
870881
auto trackPos1 = candidateLc.template prong0_as<aod::TracksWMc>();
871882
auto trackPos2 = candidateLc.template prong2_as<aod::TracksWMc>();
872883
signSoftPion = candidate.template prong1_as<aod::TracksWMc>().sign();
884+
ptSoftPi = candidate.template prong1_as<aod::TracksWMc>().pt();
873885
if (calTrkEff && countCand == 1 && (isSignal || !calEffEventWithCand)) {
874886
calculateTrkEff(trackPos1, trackPos2, *mcParticles);
875887
}
876888
registry.fill(HIST("hPtProng1"), candidate.template prong1_as<aod::TracksWMc>().pt());
877889
} else {
878890
signSoftPion = candidate.template prong1_as<aod::Tracks>().sign();
891+
ptSoftPi = candidate.template prong1_as<aod::Tracks>().pt();
879892
registry.fill(HIST("hPtProng1"), candidate.prong1().pt());
880893
}
881894
registry.fill(HIST("hPtProng0"), ptScProng0);
@@ -931,12 +944,13 @@ struct HfCorrelatorLcScHadrons {
931944
registry.fill(HIST("hPtVsMultiplicityMcRecNonPrompt"), ptCand, multiplicityFT0M);
932945
}
933946

934-
entryCandCandRecoInfo(massCandPKPi, ptCand, outputMlPKPi[0], outputMlPKPi[1], poolBin);
947+
entryCandRecoInfo(massCandPKPi, ptCand, outputMlPKPi[0], outputMlPKPi[1], poolBin);
935948
entryCandCandGenInfo(isPrompt);
936949
if (!skipMixedEventTableFilling) {
937950
entryCand(candidate.phi(), etaCand, ptCand, massCandPKPi, poolBin, gCollisionId, timeStamp);
938951
entryCandCharge(chargeCand);
939952
entryPtLcFromSc(ptScProng0);
953+
entryScRecoInfoExt(massPKPiLcFromSc, ptSoftPi, softPiAbsDcaXY, softPiAbsDcaZ);
940954
}
941955
}
942956

@@ -952,12 +966,13 @@ struct HfCorrelatorLcScHadrons {
952966
registry.fill(HIST("hPtCandSigNonPrompt"), ptCand);
953967
registry.fill(HIST("hPtVsMultiplicityMcRecNonPrompt"), ptCand, multiplicityFT0M);
954968
}
955-
entryCandCandRecoInfo(massCandPiKP, ptCand, outputMlPiKP[0], outputMlPiKP[1], poolBin);
969+
entryCandRecoInfo(massCandPiKP, ptCand, outputMlPiKP[0], outputMlPiKP[1], poolBin);
956970
entryCandCandGenInfo(isPrompt);
957971
if (!skipMixedEventTableFilling) {
958972
entryCand(candidate.phi(), etaCand, ptCand, massCandPiKP, poolBin, gCollisionId, timeStamp);
959973
entryCandCharge(chargeCand);
960974
entryPtLcFromSc(ptScProng0);
975+
entryScRecoInfoExt(massPiKPLcFromSc, ptSoftPi, softPiAbsDcaXY, softPiAbsDcaZ);
961976
}
962977
}
963978

@@ -1016,10 +1031,12 @@ struct HfCorrelatorLcScHadrons {
10161031
if (selLcPKPi) {
10171032
fillCorrelationTable<IsMcRec>(fillTrkPID, track, candidate, outputMlPKPi, poolBin, correlationStatus, yCand, chargeCand, ptScProng0, *mcParticles);
10181033
entryCandHadronRecoInfo(massCandPKPi, false);
1034+
entryScHadronRecoInfoExt(massPKPiLcFromSc, ptSoftPi, softPiAbsDcaXY, softPiAbsDcaZ);
10191035
}
10201036
if (selLcPiKP) {
10211037
fillCorrelationTable<IsMcRec>(fillTrkPID, track, candidate, outputMlPiKP, poolBin, correlationStatus, yCand, chargeCand, ptScProng0, *mcParticles);
10221038
entryCandHadronRecoInfo(massCandPiKP, false);
1039+
entryScHadronRecoInfoExt(massPiKPLcFromSc, ptSoftPi, softPiAbsDcaXY, softPiAbsDcaZ);
10231040
}
10241041

10251042
if (countCand == 1) {

0 commit comments

Comments
 (0)