3535namespace hf_mc_gen
3636{
3737
38- using namespace o2 ::hf_corrbkg;
39-
4038template <bool matchCorrBkgs = false , typename T, typename U, typename V>
4139void fillMcMatchGen2Prong (T const & mcParticles, U const & mcParticlesPerMcColl, V& rowMcMatchGen, bool rejectBackground)
4240{
@@ -59,7 +57,7 @@ void fillMcMatchGen2Prong(T const& mcParticles, U const& mcParticlesPerMcColl, V
5957 if (matchCorrBkgs) {
6058 bool matched = false ;
6159
62- for (const auto & [chn, finalState] : o2::hf_corrbkg::hf_chns_2prong ::finalStates2Prongs) {
60+ for (const auto & [chn, finalState] : o2::hf_decay::hf_cand_2prong ::finalStates2Prongs) {
6361 if (finalState.size () == 3 ) { // Partly Reco 3-prong decays
6462 std::array<int , 3 > finalStateParts = std::array{finalState[0 ], finalState[1 ], finalState[2 ]};
6563 if (particle.pdgCode () < 0 ) {
@@ -78,7 +76,7 @@ void fillMcMatchGen2Prong(T const& mcParticles, U const& mcParticlesPerMcColl, V
7876 continue ;
7977 }
8078 if (matched) {
81- flag = sign * chn;
79+ flag = sign * ( 1 << chn) ;
8280
8381 // Flag the resonant decay channel
8482 int resoMaxDepth = 1 ;
@@ -90,7 +88,7 @@ void fillMcMatchGen2Prong(T const& mcParticles, U const& mcParticlesPerMcColl, V
9088 auto daughI = mcParticles.rawIteratorAt (arrResoDaughIndex[iProng]);
9189 arrPDGDaugh[iProng] = daughI.pdgCode ();
9290 }
93- flagResonantDecay (Pdg::kD0 , &channel, arrPDGDaugh);
91+ o2::hf_decay:: flagResonantDecay (Pdg::kD0 , &channel, arrPDGDaugh);
9492 }
9593 break ;
9694 }
@@ -159,7 +157,7 @@ void fillMcMatchGen3Prong(T const& mcParticles, U const& mcParticlesPerMcColl, V
159157 if (std::abs (particle.pdgCode ()) != motherPdgCode) {
160158 continue ; // Skip if the particle PDG code does not match the mother PDG code
161159 }
162- auto finalStates = getDecayChannel3Prong (motherPdgCode);
160+ auto finalStates = o2::hf_decay::hf_cand_3prong:: getDecayChannel3Prong (motherPdgCode);
163161 int maxDepth = 2 ;
164162 bool matched = false ;
165163 if (motherPdgCode == Pdg::kDStar ) {
@@ -224,7 +222,7 @@ void fillMcMatchGen3Prong(T const& mcParticles, U const& mcParticlesPerMcColl, V
224222 auto daughI = mcParticles.rawIteratorAt (arrResoDaughIndex[iProng]);
225223 arrPDGDaugh[iProng] = daughI.pdgCode ();
226224 }
227- flagResonantDecay<true >(motherPdgCode, &channel, arrPDGDaugh);
225+ o2::hf_decay:: flagResonantDecay<true >(motherPdgCode, &channel, arrPDGDaugh);
228226 }
229227 break ; // Exit loop if a match is found
230228 }
0 commit comments