From 11462d36b4bad517b05ef67c1dbc1949f18e485a Mon Sep 17 00:00:00 2001 From: Fabrizio Grosa Date: Wed, 13 Jul 2022 15:12:00 +0200 Subject: [PATCH] Fix match of decays including resonant channels --- EventFiltering/PWGHF/HFFilter.cxx | 6 +++--- EventFiltering/PWGHF/HFFilterQC.cxx | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/EventFiltering/PWGHF/HFFilter.cxx b/EventFiltering/PWGHF/HFFilter.cxx index 41efb4b7184..5cd1ee1b5ea 100644 --- a/EventFiltering/PWGHF/HFFilter.cxx +++ b/EventFiltering/PWGHF/HFFilter.cxx @@ -1010,13 +1010,13 @@ struct HfFilter { // Main struct for HF triggers int8_t origin = 0; // D± → π± K∓ π± - auto indexRec = RecoDecay::getMatchedMCRec(particlesMC, arrayDaughters, pdg::Code::kDPlus, array{+kPiPlus, -kKPlus, +kPiPlus}, true, &sign); + auto indexRec = RecoDecay::getMatchedMCRec(particlesMC, arrayDaughters, pdg::Code::kDPlus, array{+kPiPlus, -kKPlus, +kPiPlus}, true, &sign, 2); if (indexRec >= 0) { channel = kDplus; } if (indexRec < 0) { // Ds± → K± K∓ π± - indexRec = RecoDecay::getMatchedMCRec(particlesMC, arrayDaughters, 431, array{+kKPlus, -kKPlus, +kPiPlus}, true, &sign); // TODO: replace hard coded pdg code + indexRec = RecoDecay::getMatchedMCRec(particlesMC, arrayDaughters, 431, array{+kKPlus, -kKPlus, +kPiPlus}, true, &sign, 2); // TODO: replace hard coded pdg code if (indexRec >= 0) { channel = kDs; } @@ -1030,7 +1030,7 @@ struct HfFilter { // Main struct for HF triggers } if (indexRec < 0) { // Ξc± → p± K∓ π± - indexRec = RecoDecay::getMatchedMCRec(particlesMC, arrayDaughters, pdg::Code::kXiCPlus, array{+kProton, -kKPlus, +kPiPlus}, true, &sign); + indexRec = RecoDecay::getMatchedMCRec(particlesMC, arrayDaughters, pdg::Code::kXiCPlus, array{+kProton, -kKPlus, +kPiPlus}, true, &sign, 2); if (indexRec >= 0) { channel = kXic; } diff --git a/EventFiltering/PWGHF/HFFilterQC.cxx b/EventFiltering/PWGHF/HFFilterQC.cxx index 9a8d68bc6eb..2c34cc9708d 100644 --- a/EventFiltering/PWGHF/HFFilterQC.cxx +++ b/EventFiltering/PWGHF/HFFilterQC.cxx @@ -110,7 +110,7 @@ struct HfFilterQc { // Main struct for HF trigger QC return; } else { int8_t sign = 0; - if (RecoDecay::isMatchedMCGen(particlesMC, particle, pdgCodes[I], std::get(pdgDau), true, &sign)) { + if (RecoDecay::isMatchedMCGen(particlesMC, particle, pdgCodes[I], std::get(pdgDau), true, &sign, 2)) { nParticles[I]++; hPtDistr[0]->Fill(static_cast(I), static_cast(particle.pt())); for (auto iTrig = 0; iTrig < kNtriggersHF; ++iTrig) {