Skip to content
Draft
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
23 changes: 23 additions & 0 deletions PWGHF/DataModel/DerivedTables.h
Original file line number Diff line number Diff line change
Expand Up @@ -610,9 +610,14 @@ DECLARE_SOA_TABLE_STAGED(HfBplusPars, "HFBPPAR", //! Table with candidate proper

DECLARE_SOA_TABLE_STAGED(HfBplusParD0s, "HFBPPARD0", //! Table with D0 candidate properties used for selection of B+
hf_cand_par_charm::CpaCharm,
hf_cand_par_charm::DecayLengthXYCharm,
hf_cand_par_charm::DecayLengthNormalisedCharm,
hf_cand_par_charm::DecayLengthXYNormalisedCharm,
hf_cand_par_charm::DecayLengthCharm,
hf_cand_par_charm::ImpactParameter0Charm,
hf_cand_par_charm::ImpactParameter1Charm,
hf_cand_par_charm::ImpactParameterNormalised0Charm,
hf_cand_par_charm::ImpactParameterNormalised1Charm,
hf_cand_par_charm::ImpactParameterProductCharm,
hf_cand_par_charm::NSigTpcPiExpPiCharm,
hf_cand_par_charm::NSigTofPiExpPiCharm,
Expand All @@ -627,6 +632,20 @@ DECLARE_SOA_TABLE_STAGED(HfBplusParD0s, "HFBPPARD0", //! Table with D0 candidate
hf_cand_par_charm::NSigTofKaExpKaCharm,
hf_cand_par_charm::NSigTpcTofKaExpKaCharm);

DECLARE_SOA_TABLE_STAGED(HfBplusParD0Es, "HFBPPARD0E", //! Table with additional D0 candidate properties used for selection of B+
hf_cand_par_charm::Chi2PCACharm,
hf_cand_par_charm::NProngsContributorsPVCharm,
hf_cand_par_charm::InvMassCharm,
hf_cand_par_charm::MaxNormalisedDeltaIPCharm,
hf_cand_par_charm::PxProng0Charm,
hf_cand_par_charm::PyProng0Charm,
hf_cand_par_charm::PzProng0Charm,
hf_cand_par_charm::PxProng1Charm,
hf_cand_par_charm::PyProng1Charm,
hf_cand_par_charm::PzProng1Charm,
hf_cand_par_charm::PtProng0Charm,
hf_cand_par_charm::PtProng1Charm);

DECLARE_SOA_TABLE_STAGED(HfBplusParEs, "HFBPPARE", //! Table with additional candidate properties used for selection
hf_cand::XSecondaryVertex,
hf_cand::YSecondaryVertex,
Expand All @@ -638,6 +657,10 @@ DECLARE_SOA_TABLE_STAGED(HfBplusParEs, "HFBPPARE", //! Table with additional can
hf_cand::PxProng1,
hf_cand::PyProng1,
hf_cand::PzProng1,
hf_cand_par::PProng0,
hf_cand::PxProng0,
hf_cand::PyProng0,
hf_cand::PzProng0,
hf_cand::ErrorImpactParameter1,
hf_cand_par::CosThetaStar,
hf_cand_par::Ct,
Expand Down
33 changes: 33 additions & 0 deletions PWGHF/TableProducer/derivedDataCreatorBplusToD0Pi.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ struct HfDerivedDataCreatorBplusToD0Pi {
// Candidates
Produces<o2::aod::HfBplusPars> rowCandidatePar;
Produces<o2::aod::HfBplusParD0s> rowCandidateParD0;
Produces<o2::aod::HfBplusParD0Es> rowCandidateParD0E;
Produces<o2::aod::HfBplusParEs> rowCandidateParE;
Produces<o2::aod::HfBplusSels> rowCandidateSel;
Produces<o2::aod::HfBplusMls> rowCandidateMl;
Expand All @@ -83,6 +84,7 @@ struct HfDerivedDataCreatorBplusToD0Pi {
HfConfigurableDerivedData confDerData;
Configurable<bool> fillCandidatePar{"fillCandidatePar", true, "Fill candidate parameters"};
Configurable<bool> fillCandidateParD0{"fillCandidateParD0", true, "Fill D0 candidate parameters"};
Configurable<bool> fillCandidateParD0E{"fillCandidateParD0E", true, "Fill additional D0 candidate parameters"};
Configurable<bool> fillCandidateParE{"fillCandidateParE", true, "Fill candidate extended parameters"};
Configurable<bool> fillCandidateSel{"fillCandidateSel", true, "Fill candidate selection flags"};
Configurable<bool> fillCandidateMl{"fillCandidateMl", true, "Fill candidate selection ML scores"};
Expand Down Expand Up @@ -181,8 +183,13 @@ struct HfDerivedDataCreatorBplusToD0Pi {
rowCandidateParD0(
prongCharm.cpa(),
prongCharm.decayLength(),
prongCharm.decayLengthXY(),
prongCharm.decayLengthNormalised(),
prongCharm.decayLengthXYNormalised(),
prongCharm.impactParameter0(),
prongCharm.impactParameter1(),
prongCharm.impactParameterNormalised0(),
prongCharm.impactParameterNormalised1(),
prongCharm.impactParameterProduct(),
sigmas[HfProngSpecies::Pion][HfProngSpecies::Pion][0],
sigmas[HfProngSpecies::Pion][HfProngSpecies::Pion][1],
Expand All @@ -197,6 +204,27 @@ struct HfDerivedDataCreatorBplusToD0Pi {
sigmas[HfProngSpecies::Kaon][HfProngSpecies::Kaon][1],
sigmas[HfProngSpecies::Kaon][HfProngSpecies::Kaon][2]);
}
if (fillCandidateParD0E) {
float invMassD0;
if (candFlag == 0) {
invMassD0 = HfHelper::invMassD0ToPiK(prongCharm);
} else if (candFlag == 1) {
invMassD0 = HfHelper::invMassD0barToKPi(prongCharm);
}
rowCandidateParD0E(
prongCharm.chi2PCA(),
prongCharm.nProngsContributorsPV(),
invMassD0,
prongCharm.maxNormalisedDeltaIP(),
prongCharm.pxProng0(),
prongCharm.pyProng0(),
prongCharm.pzProng0(),
prongCharm.pxProng1(),
prongCharm.pyProng1(),
prongCharm.pzProng1(),
prongCharm.ptProng0(),
prongCharm.ptProng1());
}
if (fillCandidateParE) {
rowCandidateParE(
candidate.xSecondaryVertex(),
Expand All @@ -209,6 +237,10 @@ struct HfDerivedDataCreatorBplusToD0Pi {
candidate.pxProng1(),
candidate.pyProng1(),
candidate.pzProng1(),
RecoDecay::p(candidate.pxProng0(), candidate.pyProng0(), candidate.pzProng0()),
candidate.pxProng0(),
candidate.pyProng0(),
candidate.pzProng0(),
candidate.errorImpactParameter1(),
HfHelper::cosThetaStarBplus(candidate),
ct);
Expand Down Expand Up @@ -277,6 +309,7 @@ struct HfDerivedDataCreatorBplusToD0Pi {
reserveTable(rowCandidatePar, fillCandidatePar, sizeTableCand);
reserveTable(rowCandidateParD0, fillCandidateParD0, sizeTableCand);
reserveTable(rowCandidateParE, fillCandidateParE, sizeTableCand);
reserveTable(rowCandidateParD0E, fillCandidateParD0E, sizeTableCand);
reserveTable(rowCandidateSel, fillCandidateSel, sizeTableCand);
reserveTable(rowCandidateMl, fillCandidateMl, sizeTableCand);
reserveTable(rowCandidateMlD0, fillCandidateMlD0, sizeTableCand);
Expand Down
Loading