Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PWGHF] Add the possibility to run MC Gen only for HF derived data #9357

Merged
merged 7 commits into from
Jan 22, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions PWGHF/TableProducer/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2019-2020 CERN and copyright holders of ALICE O2.

Check warning on line 1 in PWGHF/TableProducer/CMakeLists.txt

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-workflow]

Use kebab-case for names of workflows and match the name of the workflow file.
# See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
# All rights not expressly granted are reserved.
#
Expand Down Expand Up @@ -100,6 +100,11 @@
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore O2::DCAFitter
COMPONENT_NAME Analysis)

o2physics_add_dpl_workflow(candidate-creator-mc-gen
SOURCES candidateCreatorMcGen.cxx
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore
COMPONENT_NAME Analysis)

# Candidate selectors

o2physics_add_dpl_workflow(candidate-selector-b0-to-d-pi
Expand Down Expand Up @@ -244,12 +249,12 @@
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore O2::DCAFitter O2Physics::EventFilteringUtils
COMPONENT_NAME Analysis)

o2physics_add_dpl_workflow(tree-creator-omegac0-to-omega-ka

Check warning on line 252 in PWGHF/TableProducer/CMakeLists.txt

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-workflow]

Workflow name tree-creator-omegac0-to-omega-ka does not match its file name treeCreatorOmegacToOmegaKa.cxx. (Matches treeCreatorOmegac0ToOmegaKa.cxx.)
SOURCES treeCreatorOmegacToOmegaKa.cxx
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore
COMPONENT_NAME Analysis)

o2physics_add_dpl_workflow(tree-creator-omegac0-to-omega-pi

Check warning on line 257 in PWGHF/TableProducer/CMakeLists.txt

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-workflow]

Workflow name tree-creator-omegac0-to-omega-pi does not match its file name treeCreatorOmegacToOmegaPi.cxx. (Matches treeCreatorOmegac0ToOmegaPi.cxx.)
SOURCES treeCreatorOmegacToOmegaPi.cxx
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore
COMPONENT_NAME Analysis)
Expand Down
43 changes: 2 additions & 41 deletions PWGHF/TableProducer/candidateCreator2Prong.cxx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.

Check warning on line 1 in PWGHF/TableProducer/candidateCreator2Prong.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-task]

Specify task name only when it cannot be derived from the struct name. Only append to the default name.
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
// All rights not expressly granted are reserved.
//
Expand All @@ -17,7 +17,7 @@
/// \author Pengzhong Lu <pengzhong.lu@cern.ch>, GSI Darmstadt, USTC

#ifndef HomogeneousField
#define HomogeneousField

Check warning on line 20 in PWGHF/TableProducer/candidateCreator2Prong.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/macro]

Use SCREAMING_SNAKE_CASE for names of macros. Leading and double underscores are not allowed.
#endif

#include <memory>
Expand Down Expand Up @@ -49,6 +49,7 @@
#include "PWGHF/Utils/utilsEvSelHf.h"
#include "PWGHF/Utils/utilsPid.h"
#include "PWGHF/Utils/utilsTrkCandHf.h"
#include "PWGHF/Utils/utilsMcGen.h"

using namespace o2;
using namespace o2::analysis;
Expand Down Expand Up @@ -371,7 +372,7 @@
kfpVertex.SetCovarianceMatrix(rowTrackIndexProng2.pvRefitSigmaX2(), rowTrackIndexProng2.pvRefitSigmaXY(), rowTrackIndexProng2.pvRefitSigmaY2(), rowTrackIndexProng2.pvRefitSigmaXZ(), rowTrackIndexProng2.pvRefitSigmaYZ(), rowTrackIndexProng2.pvRefitSigmaZ2());
}
kfpVertex.GetCovarianceMatrix(covMatrixPV);
KFParticle KFPV(kfpVertex);

Check warning on line 375 in PWGHF/TableProducer/candidateCreator2Prong.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
registry.fill(HIST("hCovPVXX"), covMatrixPV[0]);
registry.fill(HIST("hCovPVYY"), covMatrixPV[2]);
registry.fill(HIST("hCovPVXZ"), covMatrixPV[3]);
Expand Down Expand Up @@ -692,10 +693,10 @@
using McCollisionsFT0Cs = soa::Join<aod::Collisions, aod::EvSels, aod::McCollisionLabels, aod::CentFT0Cs>;
using McCollisionsFT0Ms = soa::Join<aod::Collisions, aod::EvSels, aod::McCollisionLabels, aod::CentFT0Ms>;
using McCollisionsCentFT0Ms = soa::Join<aod::McCollisions, aod::McCentFT0Ms>;
PresliceUnsorted<McCollisionsNoCents> colPerMcCollision = aod::mccollisionlabel::mcCollisionId;

Check warning on line 696 in PWGHF/TableProducer/candidateCreator2Prong.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[pwghf/struct-member-order]

HfCandidateCreator2ProngExpressions: PresliceUnsorted< appears too early (before end of Preslice<).
PresliceUnsorted<McCollisionsFT0Cs> colPerMcCollisionFT0C = aod::mccollisionlabel::mcCollisionId;
PresliceUnsorted<McCollisionsFT0Ms> colPerMcCollisionFT0M = aod::mccollisionlabel::mcCollisionId;
Preslice<aod::McParticles> mcParticlesPerMcCollision = aod::mcparticle::mcCollisionId;

Check warning on line 699 in PWGHF/TableProducer/candidateCreator2Prong.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[pwghf/struct-member-order]

HfCandidateCreator2ProngExpressions: Preslice< appears too early (before end of using).

using BCsInfo = soa::Join<aod::BCs, aod::Timestamps, aod::BcSels>;
HistogramRegistry registry{"registry"};
Expand Down Expand Up @@ -839,47 +840,7 @@
}
continue;
}

// Match generated particles.
for (const auto& particle : mcParticlesPerMcColl) {
flag = 0;
origin = 0;
std::vector<int> idxBhadMothers{};
// Reject particles from background events
if (particle.fromBackgroundEvent() && rejectBackground) {
rowMcMatchGen(flag, origin, -1);
continue;
}

// D0(bar) → π± K∓
if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kD0, std::array{+kPiPlus, -kKPlus}, true, &sign)) {
flag = sign * (1 << DecayType::D0ToPiK);
}

// J/ψ → e+ e−
if (flag == 0) {
if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kJPsi, std::array{+kElectron, -kElectron}, true)) {
flag = 1 << DecayType::JpsiToEE;
}
}

// J/ψ → μ+ μ−
if (flag == 0) {
if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kJPsi, std::array{+kMuonPlus, -kMuonPlus}, true)) {
flag = 1 << DecayType::JpsiToMuMu;
}
}

// Check whether the particle is non-prompt (from a b quark).
if (flag != 0) {
origin = RecoDecay::getCharmHadronOrigin(mcParticles, particle, false, &idxBhadMothers);
}
if (origin == RecoDecay::OriginType::NonPrompt) {
rowMcMatchGen(flag, origin, idxBhadMothers[0]);
} else {
rowMcMatchGen(flag, origin, -1);
}
}
hf_mc_gen::fillMcMatchGen2Prong(mcParticlesPerMcColl, rowMcMatchGen, rejectBackground);
}
}

Expand Down Expand Up @@ -917,6 +878,6 @@
WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
{
return WorkflowSpec{
adaptAnalysisTask<HfCandidateCreator2Prong>(cfgc, TaskName{"hf-candidate-creator-2prong"}),

Check warning on line 881 in PWGHF/TableProducer/candidateCreator2Prong.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-task]

Device names hf-candidate-creator-2prong and hf-candidate-creator2-prong generated from the specified task name hf-candidate-creator-2prong and from the struct name HfCandidateCreator2Prong, respectively, differ in hyphenation. Consider fixing capitalisation of the struct name to HfCandidateCreator2Prong and removing TaskName.
adaptAnalysisTask<HfCandidateCreator2ProngExpressions>(cfgc, TaskName{"hf-candidate-creator-2prong-expressions"})};

Check warning on line 882 in PWGHF/TableProducer/candidateCreator2Prong.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-task]

Device names hf-candidate-creator-2prong-expressions and hf-candidate-creator2-prong-expressions generated from the specified task name hf-candidate-creator-2prong-expressions and from the struct name HfCandidateCreator2ProngExpressions, respectively, differ in hyphenation. Consider fixing capitalisation of the struct name to HfCandidateCreator2ProngExpressions and removing TaskName.
}
92 changes: 2 additions & 90 deletions PWGHF/TableProducer/candidateCreator3Prong.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
#include "PWGHF/Utils/utilsBfieldCCDB.h"
#include "PWGHF/Utils/utilsEvSelHf.h"
#include "PWGHF/Utils/utilsTrkCandHf.h"
#include "PWGHF/Utils/utilsMcGen.h"

using namespace o2;
using namespace o2::analysis;
Expand Down Expand Up @@ -1048,96 +1049,7 @@ struct HfCandidateCreator3ProngExpressions {
}
continue;
}

// Match generated particles.
for (const auto& particle : mcParticlesPerMcColl) {
flag = 0;
origin = 0;
channel = 0;
arrDaughIndex.clear();
std::vector<int> idxBhadMothers{};
// Reject particles from background events
if (particle.fromBackgroundEvent() && rejectBackground) {
rowMcMatchGen(flag, origin, channel, -1);
continue;
}

// D± → π± K∓ π±
if (createDplus) {
if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kDPlus, std::array{+kPiPlus, -kKPlus, +kPiPlus}, true, &sign, 2)) {
flag = sign * (1 << DecayType::DplusToPiKPi);
}
}

// Ds± → K± K∓ π± and D± → K± K∓ π±
if (flag == 0 && createDs) {
bool isDplus = false;
if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kDS, std::array{+kKPlus, -kKPlus, +kPiPlus}, true, &sign, 2)) {
// DecayType::DsToKKPi is used to flag both Ds± → K± K∓ π± and D± → K± K∓ π±
// TODO: move to different and explicit flags
flag = sign * (1 << DecayType::DsToKKPi);
} else if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kDPlus, std::array{+kKPlus, -kKPlus, +kPiPlus}, true, &sign, 2)) {
// DecayType::DsToKKPi is used to flag both Ds± → K± K∓ π± and D± → K± K∓ π±
// TODO: move to different and explicit flags
flag = sign * (1 << DecayType::DsToKKPi);
isDplus = true;
}
if (flag != 0) {
RecoDecay::getDaughters(particle, &arrDaughIndex, std::array{0}, 1);
if (arrDaughIndex.size() == 2) {
for (auto jProng = 0u; jProng < arrDaughIndex.size(); ++jProng) {
auto daughJ = mcParticles.rawIteratorAt(arrDaughIndex[jProng]);
arrPDGDaugh[jProng] = std::abs(daughJ.pdgCode());
}
if ((arrPDGDaugh[0] == arrPDGResonantDPhiPi[0] && arrPDGDaugh[1] == arrPDGResonantDPhiPi[1]) || (arrPDGDaugh[0] == arrPDGResonantDPhiPi[1] && arrPDGDaugh[1] == arrPDGResonantDPhiPi[0])) {
channel = isDplus ? DecayChannelDToKKPi::DplusToPhiPi : DecayChannelDToKKPi::DsToPhiPi;
} else if ((arrPDGDaugh[0] == arrPDGResonantDKstarK[0] && arrPDGDaugh[1] == arrPDGResonantDKstarK[1]) || (arrPDGDaugh[0] == arrPDGResonantDKstarK[1] && arrPDGDaugh[1] == arrPDGResonantDKstarK[0])) {
channel = isDplus ? DecayChannelDToKKPi::DplusToK0starK : DecayChannelDToKKPi::DsToK0starK;
}
}
}
}

// Λc± → p± K∓ π±
if (flag == 0 && createLc) {
if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kLambdaCPlus, std::array{+kProton, -kKPlus, +kPiPlus}, true, &sign, 2)) {
flag = sign * (1 << DecayType::LcToPKPi);

// Flagging the different Λc± → p± K∓ π± decay channels
RecoDecay::getDaughters(particle, &arrDaughIndex, std::array{0}, 1);
if (arrDaughIndex.size() == 2) {
for (auto jProng = 0u; jProng < arrDaughIndex.size(); ++jProng) {
auto daughJ = mcParticles.rawIteratorAt(arrDaughIndex[jProng]);
arrPDGDaugh[jProng] = std::abs(daughJ.pdgCode());
}
if ((arrPDGDaugh[0] == arrPDGResonant1[0] && arrPDGDaugh[1] == arrPDGResonant1[1]) || (arrPDGDaugh[0] == arrPDGResonant1[1] && arrPDGDaugh[1] == arrPDGResonant1[0])) {
channel = 1;
} else if ((arrPDGDaugh[0] == arrPDGResonant2[0] && arrPDGDaugh[1] == arrPDGResonant2[1]) || (arrPDGDaugh[0] == arrPDGResonant2[1] && arrPDGDaugh[1] == arrPDGResonant2[0])) {
channel = 2;
} else if ((arrPDGDaugh[0] == arrPDGResonant3[0] && arrPDGDaugh[1] == arrPDGResonant3[1]) || (arrPDGDaugh[0] == arrPDGResonant3[1] && arrPDGDaugh[1] == arrPDGResonant3[0])) {
channel = 3;
}
}
}
}

// Ξc± → p± K∓ π±
if (flag == 0 && createXic) {
if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kXiCPlus, std::array{+kProton, -kKPlus, +kPiPlus}, true, &sign, 2)) {
flag = sign * (1 << DecayType::XicToPKPi);
}
}

// Check whether the particle is non-prompt (from a b quark).
if (flag != 0) {
origin = RecoDecay::getCharmHadronOrigin(mcParticles, particle, false, &idxBhadMothers);
}
if (origin == RecoDecay::OriginType::NonPrompt) {
rowMcMatchGen(flag, origin, channel, idxBhadMothers[0]);
} else {
rowMcMatchGen(flag, origin, channel, -1);
}
}
hf_mc_gen::fillMcMatchGen3Prong(mcParticlesPerMcColl, rowMcMatchGen, rejectBackground, createDplus, createDs, createLc, createXic);
}
}

Expand Down
20 changes: 6 additions & 14 deletions PWGHF/TableProducer/candidateCreatorB0.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@
///
/// \author Alexandre Bigot <alexandre.bigot@cern.ch>, IPHC Strasbourg

#include <vector>
#include <string>
#include <memory>

#include "CommonConstants/PhysicsConstants.h"
#include "DCAFitter/DCAFitterN.h"
#include "Framework/AnalysisTask.h"
Expand All @@ -30,6 +34,7 @@
#include "PWGHF/DataModel/CandidateSelectionTables.h"
#include "PWGHF/Utils/utilsBfieldCCDB.h"
#include "PWGHF/Utils/utilsTrkCandHf.h"
#include "PWGHF/Utils/utilsMcGen.h"

using namespace o2;
using namespace o2::analysis;
Expand Down Expand Up @@ -448,20 +453,7 @@ struct HfCandidateCreatorB0Expressions {
rowMcMatchRec(flag, origin, debug);
} // rec

// Match generated particles.
for (const auto& particle : mcParticles) {
flag = 0;
origin = 0;
// B0 → D- π+
if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kB0, std::array{-static_cast<int>(Pdg::kDPlus), +kPiPlus}, true)) {
// D- → π- K+ π-
auto candDMC = mcParticles.rawIteratorAt(particle.daughtersIds().front());
if (RecoDecay::isMatchedMCGen(mcParticles, candDMC, -static_cast<int>(Pdg::kDPlus), std::array{-kPiPlus, +kKPlus, -kPiPlus}, true, &sign)) {
flag = sign * BIT(hf_cand_b0::DecayType::B0ToDPi);
}
}
rowMcMatchGen(flag, origin);
} // gen
hf_mc_gen::fillMcMatchGenB0(mcParticles, rowMcMatchGen); // gen
} // processMc
PROCESS_SWITCH(HfCandidateCreatorB0Expressions, processMc, "Process MC", false);
}; // struct
Expand Down
28 changes: 2 additions & 26 deletions PWGHF/TableProducer/candidateCreatorBplus.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
#include "PWGHF/DataModel/CandidateSelectionTables.h"
#include "PWGHF/Utils/utilsBfieldCCDB.h"
#include "PWGHF/Utils/utilsTrkCandHf.h"
#include "PWGHF/Utils/utilsMcGen.h"

using namespace o2;
using namespace o2::analysis;
Expand Down Expand Up @@ -365,7 +366,6 @@ struct HfCandidateCreatorBplusExpressions {
int8_t signB = 0, signD0 = 0;
int8_t flag = 0;
int8_t origin = 0;
int kD0pdg = Pdg::kD0;

// Match reconstructed candidates.
// Spawned table can be used directly
Expand All @@ -386,31 +386,7 @@ struct HfCandidateCreatorBplusExpressions {
}
rowMcMatchRec(flag, origin);
}

// Match generated particles.
for (const auto& particle : mcParticles) {
flag = 0;
origin = 0;
signB = 0;
signD0 = 0;
int indexGenD0 = -1;

// B± → D0bar(D0) π± → (K± π∓) π±
std::vector<int> arrayDaughterB;
if (RecoDecay::isMatchedMCGen(mcParticles, particle, Pdg::kBPlus, std::array{-kD0pdg, +kPiPlus}, true, &signB, 1, &arrayDaughterB)) {
// D0(bar) → π± K∓
for (auto iD : arrayDaughterB) {
auto candDaughterMC = mcParticles.rawIteratorAt(iD);
if (std::abs(candDaughterMC.pdgCode()) == kD0pdg) {
indexGenD0 = RecoDecay::isMatchedMCGen(mcParticles, candDaughterMC, Pdg::kD0, std::array{-kKPlus, +kPiPlus}, true, &signD0, 1);
}
}
if (indexGenD0 > -1) {
flag = signB * (1 << hf_cand_bplus::DecayType::BplusToD0Pi);
}
}
rowMcMatchGen(flag, origin);
} // B candidate
hf_mc_gen::fillMcMatchGenBplus(mcParticles, rowMcMatchGen); // gen
} // process
PROCESS_SWITCH(HfCandidateCreatorBplusExpressions, processMc, "Process MC", false);
}; // struct
Expand Down
76 changes: 76 additions & 0 deletions PWGHF/TableProducer/candidateCreatorMcGen.cxx
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
// All rights not expressly granted are reserved.
//
// This software is distributed under the terms of the GNU General Public
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
//
// In applying this license CERN does not waive the privileges and immunities
// granted to it by virtue of its status as an Intergovernmental Organization
// or submit itself to any jurisdiction.

/// \file candidateCreatorMcGen.cxx
/// \brief McGen only selection of heavy-flavour particles
///
/// \author Nima Zardoshti, nima.zardoshti@cern.ch, CERN

#include <memory>
#include <string>
#include <vector>

#include <TPDGCode.h>

#include "CommonConstants/PhysicsConstants.h"
#include "Framework/AnalysisTask.h"
#include "Framework/HistogramRegistry.h"
#include "Framework/runDataProcessing.h"
#include "Framework/RunningWorkflowInfo.h"

#include "PWGHF/DataModel/CandidateReconstructionTables.h"
#include "PWGHF/Utils/utilsMcGen.h"

using namespace o2;
using namespace o2::analysis;
using namespace o2::framework;

/// Reconstruction of heavy-flavour 2-prong decay candidates
struct HfCandidateCreatorMcGen {

Produces<aod::HfCand2ProngMcGen> rowMcMatchGen2Prong;
Produces<aod::HfCand3ProngMcGen> rowMcMatchGen3Prong;
Produces<aod::HfCandBplusMcGen> rowMcMatchGenBplus;
Produces<aod::HfCandB0McGen> rowMcMatchGenB0;
Configurable<bool> fill2Prong{"fill2Prong", false, "fill table for 2 prong candidates"};
Configurable<bool> fill3Prong{"fill3Prong", false, "fill table for 3 prong candidates"};
Configurable<bool> fillBplus{"fillBplus", false, "fill table for for B+ candidates"};
Configurable<bool> fillB0{"fillB0", false, "fill table for B0 candidates"};
Configurable<bool> rejectBackground2Prong{"rejectBackground2Prong", false, "Reject particles from PbPb background for 2 prong candidates"};
Configurable<bool> rejectBackground3Prong{"rejectBackground3Prong", false, "Reject particles from PbPb background for 3 prong candidates"};
Configurable<bool> createDplus{"createDplus", false, "Create D+ in 3 prong"};
Configurable<bool> createDs{"createDs", false, "Create Ds in 3 prong"};
Configurable<bool> createLc{"createLc", false, "Create Lc in 3 prong"};
Configurable<bool> createXic{"createXic", false, "Create Xic in 3 prong"};

void process(aod::McCollision const&,
aod::McParticles const& mcParticles)
{
if (fill2Prong) {
hf_mc_gen::fillMcMatchGen2Prong(mcParticles, rowMcMatchGen2Prong, rejectBackground2Prong);
}
if (fill3Prong) {
hf_mc_gen::fillMcMatchGen3Prong(mcParticles, rowMcMatchGen3Prong, rejectBackground3Prong, createDplus, createDs, createLc, createXic);
}
if (fillBplus) {
hf_mc_gen::fillMcMatchGenBplus(mcParticles, rowMcMatchGenBplus);
}
if (fillB0) {
hf_mc_gen::fillMcMatchGenB0(mcParticles, rowMcMatchGenB0);
}
}
};

WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
{
return WorkflowSpec{
adaptAnalysisTask<HfCandidateCreatorMcGen>(cfgc)};
vkucera marked this conversation as resolved.
Show resolved Hide resolved
}
7 changes: 7 additions & 0 deletions PWGHF/TableProducer/derivedDataCreatorBplusToD0Pi.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -419,6 +419,13 @@ struct HfDerivedDataCreatorBplusToD0Pi {
rowsCommon.processMcParticles(mcCollisions, mcParticlesPerMcCollision, mcParticles, mass);
}
PROCESS_SWITCH(HfDerivedDataCreatorBplusToD0Pi, processMcMlAll, "Process MC with ML", false);

void processMcGenOnly(TypeMcCollisions const& mcCollisions,
MatchedGenCandidatesMc const& mcParticles)
{
rowsCommon.processMcParticles(mcCollisions, mcParticlesPerMcCollision, mcParticles, mass);
}
PROCESS_SWITCH(HfDerivedDataCreatorBplusToD0Pi, processMcGenOnly, "Process MC gen. only", false);
};

WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
Expand Down
7 changes: 7 additions & 0 deletions PWGHF/TableProducer/derivedDataCreatorD0ToKPi.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -516,6 +516,13 @@ struct HfDerivedDataCreatorD0ToKPi {
rowsCommon.processMcParticles(mcCollisions, mcParticlesPerMcCollision, mcParticles, mass);
}
PROCESS_SWITCH(HfDerivedDataCreatorD0ToKPi, processMcWithKFParticleMlAll, "Process MC with KFParticle and ML", false);

void processMcGenOnly(TypeMcCollisions const& mcCollisions,
MatchedGenCandidatesMc const& mcParticles)
{
rowsCommon.processMcParticles(mcCollisions, mcParticlesPerMcCollision, mcParticles, mass);
}
PROCESS_SWITCH(HfDerivedDataCreatorD0ToKPi, processMcGenOnly, "Process MC gen. only", false);
};

WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
Expand Down
7 changes: 7 additions & 0 deletions PWGHF/TableProducer/derivedDataCreatorLcToPKPi.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,13 @@ struct HfDerivedDataCreatorLcToPKPi {
rowsCommon.processMcParticles(mcCollisions, mcParticlesPerMcCollision, mcParticles, mass);
}
PROCESS_SWITCH(HfDerivedDataCreatorLcToPKPi, processMcMlAll, "Process MC with ML", false);

void processMcGenOnly(TypeMcCollisions const& mcCollisions,
MatchedGenCandidatesMc const& mcParticles)
{
rowsCommon.processMcParticles(mcCollisions, mcParticlesPerMcCollision, mcParticles, mass);
}
PROCESS_SWITCH(HfDerivedDataCreatorLcToPKPi, processMcGenOnly, "Process MC gen. only", false);
};

WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
Expand Down
Loading
Loading