@@ -3324,7 +3324,7 @@ struct HfTrackIndexSkimCreatorLfCascades {
33243324 Configurable<double > massXiPiPiMax{" massXiPiPiMax" , 2.8 , " Invariant mass upper limit for xi pi pi decay channel" };
33253325
33263326 // DCAFitter settings
3327- Configurable<bool > propagateToPCA{" propagateToPCA" , false , " create tracks version propagated to PCA" };
3327+ Configurable<bool > propagateToPCA{" propagateToPCA" , true , " create tracks version propagated to PCA" };
33283328 Configurable<bool > useAbsDCA{" useAbsDCA" , true , " Minimise abs. distance rather than chi2" };
33293329 Configurable<bool > useWeightedFinalPCA{" useWeightedFinalPCA" , true , " Recalculate vertex position using track covariances, effective only if useAbsDCA is true" };
33303330 Configurable<double > maxR{" maxR" , 200 ., " reject PCA's above this radius" };
@@ -3551,6 +3551,7 @@ struct HfTrackIndexSkimCreatorLfCascades {
35513551 template <typename T1, typename T2, typename T3>
35523552 bool isSelectedCandidateXic (const T1& pVecCand, const T2& secVtx, const T3& primVtx)
35533553 {
3554+
35543555 // pT
35553556 if (config.ptMinXicplusLfCasc > 0 .f ) {
35563557 const auto pt = RecoDecay::pt (pVecCand);
@@ -3706,34 +3707,27 @@ struct HfTrackIndexSkimCreatorLfCascades {
37063707 }
37073708
37083709 if (nVtxFrom2ProngFitterXiHyp > 0 ) {
3709-
3710- df2.propagateTracksToVertex ();
3711-
3712- if (df2.isPropagateTracksToVertexDone ()) {
3713- std::array<float , 3 > pVecXi{};
3714- std::array<float , 3 > pVecPion1XiHyp{};
3715- df2.getTrack (0 ).getPxPyPzGlo (pVecXi);
3716- df2.getTrack (1 ).getPxPyPzGlo (pVecPion1XiHyp);
3717- const float ptXic = RecoDecay::pt (pVecXi, pVecPion1XiHyp);
3718-
3719- const std::array arrMomToXi{pVecXi, pVecPion1XiHyp};
3720- const auto mass2ProngXiHyp = RecoDecay::m (arrMomToXi, arrMass2Prong[hf_cand_casc_lf::DecayType2Prong::XiczeroOmegaczeroToXiPi]);
3721-
3722- if ((std::abs (casc.mXi () - MassXiMinus) < config.cascadeMassWindow ) && (mass2ProngXiHyp >= config.massXiPiMin ) && (mass2ProngXiHyp <= config.massXiPiMax )) {
3723- registry.fill (HIST (" hRejpTStatusXicZeroOmegacZeroToXiPi" ), 0 );
3724- if (ptXic >= config.ptMinXicZeroOmegacZeroToXiPiLfCasc ) {
3725- SETBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::XiczeroOmegaczeroToXiPi);
3726- registry.fill (HIST (" hRejpTStatusXicZeroOmegacZeroToXiPi" ), 1 );
3727- }
3710+ std::array<float , 3 > pVecXi{};
3711+ std::array<float , 3 > pVecPion1XiHyp{};
3712+ df2.getTrack (0 ).getPxPyPzGlo (pVecXi);
3713+ df2.getTrack (1 ).getPxPyPzGlo (pVecPion1XiHyp);
3714+ const float ptXic = RecoDecay::pt (pVecXi, pVecPion1XiHyp);
3715+
3716+ const std::array arrMomToXi{pVecXi, pVecPion1XiHyp};
3717+ const auto mass2ProngXiHyp = RecoDecay::m (arrMomToXi, arrMass2Prong[hf_cand_casc_lf::DecayType2Prong::XiczeroOmegaczeroToXiPi]);
3718+
3719+ if ((std::abs (casc.mXi () - MassXiMinus) < config.cascadeMassWindow ) && (mass2ProngXiHyp >= config.massXiPiMin ) && (mass2ProngXiHyp <= config.massXiPiMax )) {
3720+ registry.fill (HIST (" hRejpTStatusXicZeroOmegacZeroToXiPi" ), 0 );
3721+ if (ptXic >= config.ptMinXicZeroOmegacZeroToXiPiLfCasc ) {
3722+ SETBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::XiczeroOmegaczeroToXiPi);
3723+ registry.fill (HIST (" hRejpTStatusXicZeroOmegacZeroToXiPi" ), 1 );
37283724 }
3725+ }
37293726
3730- // fill histograms
3731- if (config.fillHistograms && (TESTBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::XiczeroOmegaczeroToXiPi))) {
3732- registry.fill (HIST (" hMassXicZeroOmegacZeroToXiPi" ), mass2ProngXiHyp);
3733- registry.fill (HIST (" hPtCutsXicZeroOmegacZeroToXiPi" ), ptXic);
3734- }
3735- } else if (df2.isPropagationFailure ()) {
3736- LOGF (info, " Exception caught: failed to propagate tracks (2prong - xi) to charm baryon decay vtx" );
3727+ // fill histograms
3728+ if (config.fillHistograms && (TESTBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::XiczeroOmegaczeroToXiPi))) {
3729+ registry.fill (HIST (" hMassXicZeroOmegacZeroToXiPi" ), mass2ProngXiHyp);
3730+ registry.fill (HIST (" hPtCutsXicZeroOmegacZeroToXiPi" ), ptXic);
37373731 }
37383732 }
37393733
@@ -3753,50 +3747,43 @@ struct HfTrackIndexSkimCreatorLfCascades {
37533747
37543748 if (nVtxFrom2ProngFitterOmegaHyp > 0 ) {
37553749
3756- df2.propagateTracksToVertex ();
3757-
3758- if (df2.isPropagateTracksToVertexDone ()) {
3759-
3760- std::array<float , 3 > pVecOmega{};
3761- std::array<float , 3 > pVecCharmBachelor1OmegaHyp{};
3762- df2.getTrack (0 ).getPxPyPzGlo (pVecOmega);
3763- df2.getTrack (1 ).getPxPyPzGlo (pVecCharmBachelor1OmegaHyp);
3764- const float ptOmegac = RecoDecay::pt (pVecOmega, pVecCharmBachelor1OmegaHyp);
3765-
3766- const std::array arrMomToOmega{pVecOmega, pVecCharmBachelor1OmegaHyp};
3767- const auto mass2ProngOmegaPiHyp = RecoDecay::m (arrMomToOmega, arrMass2Prong[hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaPi]);
3768- const auto mass2ProngOmegaKHyp = RecoDecay::m (arrMomToOmega, arrMass2Prong[hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaK]);
3769-
3770- if (std::abs (casc.mOmega () - MassOmegaMinus) < config.cascadeMassWindow ) {
3771- if ((mass2ProngOmegaPiHyp >= config.massOmegaCharmBachelorMin ) && (mass2ProngOmegaPiHyp <= config.massOmegaCharmBachelorMax )) {
3772- registry.fill (HIST (" hRejpTStatusOmegacZeroToOmegaPi" ), 0 );
3773- if (ptOmegac >= config.ptMinOmegacZeroToOmegaPiLfCasc ) {
3774- SETBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaPi);
3775- registry.fill (HIST (" hRejpTStatusOmegacZeroToOmegaPi" ), 1 );
3776- }
3750+ std::array<float , 3 > pVecOmega{};
3751+ std::array<float , 3 > pVecCharmBachelor1OmegaHyp{};
3752+ df2.getTrack (0 ).getPxPyPzGlo (pVecOmega);
3753+ df2.getTrack (1 ).getPxPyPzGlo (pVecCharmBachelor1OmegaHyp);
3754+ const float ptOmegac = RecoDecay::pt (pVecOmega, pVecCharmBachelor1OmegaHyp);
3755+
3756+ const std::array arrMomToOmega{pVecOmega, pVecCharmBachelor1OmegaHyp};
3757+ const auto mass2ProngOmegaPiHyp = RecoDecay::m (arrMomToOmega, arrMass2Prong[hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaPi]);
3758+ const auto mass2ProngOmegaKHyp = RecoDecay::m (arrMomToOmega, arrMass2Prong[hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaK]);
3759+
3760+ if (std::abs (casc.mOmega () - MassOmegaMinus) < config.cascadeMassWindow ) {
3761+ if ((mass2ProngOmegaPiHyp >= config.massOmegaCharmBachelorMin ) && (mass2ProngOmegaPiHyp <= config.massOmegaCharmBachelorMax )) {
3762+ registry.fill (HIST (" hRejpTStatusOmegacZeroToOmegaPi" ), 0 );
3763+ if (ptOmegac >= config.ptMinOmegacZeroToOmegaPiLfCasc ) {
3764+ SETBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaPi);
3765+ registry.fill (HIST (" hRejpTStatusOmegacZeroToOmegaPi" ), 1 );
37773766 }
3778- if ((mass2ProngOmegaKHyp >= config. massOmegaCharmBachelorMin ) && (mass2ProngOmegaKHyp <= config. massOmegaCharmBachelorMax )) {
3779- registry. fill ( HIST ( " hRejpTStatusOmegacZeroToOmegaKa " ), 0 );
3780- if (ptOmegac >= config. ptMinOmegaczeroToOmegaKaLfCasc ) {
3781- SETBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaK);
3782- registry. fill ( HIST ( " hRejpTStatusOmegacZeroToOmegaKa " ), 1 );
3783- }
3767+ }
3768+ if ((mass2ProngOmegaKHyp >= config. massOmegaCharmBachelorMin ) && (mass2ProngOmegaKHyp <= config. massOmegaCharmBachelorMax )) {
3769+ registry. fill ( HIST ( " hRejpTStatusOmegacZeroToOmegaKa " ), 0 );
3770+ if (ptOmegac >= config. ptMinOmegaczeroToOmegaKaLfCasc ) {
3771+ SETBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaK );
3772+ registry. fill ( HIST ( " hRejpTStatusOmegacZeroToOmegaKa " ), 1 );
37843773 }
37853774 }
3775+ }
37863776
3787- // fill histograms
3788- if (config.fillHistograms ) {
3789- if (TESTBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaPi)) {
3790- registry.fill (HIST (" hMassOmegacZeroToOmegaPi" ), mass2ProngOmegaPiHyp);
3791- registry.fill (HIST (" hPtCutsOmegacZeroToOmegaPi" ), ptOmegac);
3792- }
3793- if (TESTBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaK)) {
3794- registry.fill (HIST (" hMassOmegacZeroToOmegaK" ), mass2ProngOmegaKHyp);
3795- registry.fill (HIST (" hPtCutsOmegacZeroToOmegaKa" ), ptOmegac);
3796- }
3777+ // fill histograms
3778+ if (config.fillHistograms ) {
3779+ if (TESTBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaPi)) {
3780+ registry.fill (HIST (" hMassOmegacZeroToOmegaPi" ), mass2ProngOmegaPiHyp);
3781+ registry.fill (HIST (" hPtCutsOmegacZeroToOmegaPi" ), ptOmegac);
3782+ }
3783+ if (TESTBIT (hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaK)) {
3784+ registry.fill (HIST (" hMassOmegacZeroToOmegaK" ), mass2ProngOmegaKHyp);
3785+ registry.fill (HIST (" hPtCutsOmegacZeroToOmegaKa" ), ptOmegac);
37973786 }
3798- } else if (df2.isPropagationFailure ()) {
3799- LOGF (info, " Exception caught: failed to propagate tracks (2prong - omega) to charm baryon decay vtx" );
38003787 }
38013788 }
38023789
@@ -3859,43 +3846,45 @@ struct HfTrackIndexSkimCreatorLfCascades {
38593846 }
38603847
38613848 if (nVtxFrom3ProngFitterXiHyp > 0 ) {
3862- df2.propagateTracksToVertex ();
3863- if (df2.isPropagateTracksToVertexDone ()) {
3864- std::array<float , 3 > pVecPi1{};
3865- std::array<float , 3 > pVecPi2{};
3866- // get bachelor momenta at the Xic vertex
3867- df2.getTrack (0 ).getPxPyPzGlo (pVecPi1);
3868- df2.getTrack (1 ).getPxPyPzGlo (pVecPi2);
3869- const auto pVecCand = RecoDecay::pVec (pVecCasc, pVecPi1, pVecPi2);
3870- const auto ptCand = RecoDecay::pt (pVecCand);
3871- const std::array primaryVertex{collision.posX (), collision.posY (), collision.posZ ()}; // primary vertex
3872- const auto & secondaryVertex = df2.getPCACandidate (); // secondary vertex
3873-
3874- registry.fill (HIST (" hRejpTStatusXicPlusToXiPiPi" ), 0 );
3875- if (ptCand >= config.ptMinXicplusLfCasc ) {
3876- registry.fill (HIST (" hRejpTStatusXicPlusToXiPiPi" ), 1 );
3877- }
3878-
3879- if (!isSelectedCandidateXic (pVecCand, secondaryVertex, primaryVertex)) {
3880- continue ;
3881- }
3849+ std::array<float , 3 > pVecPi1{};
3850+ std::array<float , 3 > pVecPi2{};
3851+ // get bachelor momenta at the Xic vertex
3852+ df2.getTrack (0 ).getPxPyPzGlo (pVecPi1);
3853+ df2.getTrack (1 ).getPxPyPzGlo (pVecPi2);
3854+ // we propagate the cascade to the pipi vertex
3855+ trackParCovCascXi.setPID (o2::track::PID::XiMinus);
3856+ trackParCovCascXi.setAbsCharge (1 ); // to be sure
3857+ std::array<float , 2 > dcaInfoXi;
3858+ o2::base::Propagator::Instance ()->propagateToDCABxByBz ({collision.posX (), collision.posY (), collision.posZ ()}, trackParCovCascXi, 2 .f , matCorr, &dcaInfoXi);
3859+ std::array<float , 3 > pVecXiProp{};
3860+ getPxPyPz (trackParCovCascXi, pVecXiProp);
3861+ const auto pVecCand = RecoDecay::pVec (pVecCasc, pVecPi1, pVecPi2);
3862+ const auto ptCand = RecoDecay::pt (pVecCand);
3863+ const std::array primaryVertex{collision.posX (), collision.posY (), collision.posZ ()}; // primary vertex
3864+ const auto & secondaryVertex = df2.getPCACandidate (); // secondary vertex
3865+
3866+ registry.fill (HIST (" hRejpTStatusXicPlusToXiPiPi" ), 0 );
3867+ if (ptCand >= config.ptMinXicplusLfCasc ) {
3868+ registry.fill (HIST (" hRejpTStatusXicPlusToXiPiPi" ), 1 );
3869+ }
38823870
3883- // fill histograms
3884- if (config.fillHistograms ) {
3885- const std::array arr3Mom{pVecCasc, pVecPi1, pVecPi2};
3886- const auto mass3Prong = RecoDecay::m (arr3Mom, arrMass3Prong[hf_cand_casc_lf::DecayType3Prong::XicplusToXiPiPi]);
3887- registry.fill (HIST (" hMassXicPlusToXiPiPi" ), mass3Prong);
3888- registry.fill (HIST (" hPtCutsXicPlusToXiPiPi" ), ptCand);
3889- }
3871+ if (!isSelectedCandidateXic (pVecCand, secondaryVertex, primaryVertex)) {
3872+ continue ;
3873+ }
38903874
3891- // fill table row if a vertex was found
3892- rowTrackIndexCasc3Prong (thisCollId,
3893- casc.cascadeId (),
3894- trackCharmBachelor1.globalIndex (),
3895- trackCharmBachelor2.globalIndex ());
3896- } else if (df2.isPropagationFailure ()) {
3897- LOGF (info, " Exception caught: failed to propagate tracks (3prong) to charm baryon decay vtx" );
3875+ // fill histograms
3876+ if (config.fillHistograms ) {
3877+ const std::array arr3Mom{pVecCasc, pVecPi1, pVecPi2};
3878+ const auto mass3Prong = RecoDecay::m (arr3Mom, arrMass3Prong[hf_cand_casc_lf::DecayType3Prong::XicplusToXiPiPi]);
3879+ registry.fill (HIST (" hMassXicPlusToXiPiPi" ), mass3Prong);
3880+ registry.fill (HIST (" hPtCutsXicPlusToXiPiPi" ), ptCand);
38983881 }
3882+
3883+ // fill table row if a vertex was found
3884+ rowTrackIndexCasc3Prong (thisCollId,
3885+ casc.cascadeId (),
3886+ trackCharmBachelor1.globalIndex (),
3887+ trackCharmBachelor2.globalIndex ());
38993888 }
39003889 } // end 3prong loop
39013890 } // end 3prong condition
0 commit comments