Skip to content

Commit c8b97f0

Browse files
authored
Merge pull request #38 from alibuild/alibot-cleanup-8316
Please consider the following formatting changes to AliceO2Group#8316
2 parents 138d01c + c8595d4 commit c8b97f0

File tree

4 files changed

+119
-120
lines changed

4 files changed

+119
-120
lines changed

PWGHF/D2H/DataModel/ReducedDataModel.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -802,7 +802,7 @@ namespace hf_reso_cand_reduced
802802
DECLARE_SOA_COLUMN(InvMass, invMass, float); //! Invariant mass in GeV/c2
803803
DECLARE_SOA_COLUMN(InvMassProng0, invMassProng0, float); //! Invariant Mass of D daughter in GeV/c
804804
DECLARE_SOA_COLUMN(InvMassProng1, invMassProng1, float); //! Invariant Mass of V0 daughter in GeV/c
805-
DECLARE_SOA_COLUMN(InvMassD0, invMassD0, float); //! Invariant Mass of potential D0 daughter
805+
DECLARE_SOA_COLUMN(InvMassD0, invMassD0, float); //! Invariant Mass of potential D0 daughter
806806

807807
DECLARE_SOA_COLUMN(MlScoreBkgProng0, mlScoreBkgProng0, float); //! Bkg ML score of the D daughter
808808
DECLARE_SOA_COLUMN(MlScorePromptProng0, mlScorePromptProng0, float); //! Prompt ML score of the D daughter

PWGHF/D2H/TableProducer/candidateCreatorCharmResoReduced.cxx

Lines changed: 31 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -94,13 +94,13 @@ struct HfCandidateCreatorCharmResoReduced {
9494
Configurable<std::vector<double>> binsPtD{"binsPtD", std::vector<double>{hf_cuts_d_daughter::vecBinsPt}, "pT bin limits for D daughter cuts"};
9595
Configurable<LabeledArray<double>> cutsV0{"cutsV0daughter", {hf_cuts_v0_daughter::cuts[0], hf_cuts_v0_daughter::nBinsPt, hf_cuts_v0_daughter::nCutVars, hf_cuts_v0_daughter::labelsPt, hf_cuts_v0_daughter::labelsCutVar}, "V0 daughter selections"};
9696
Configurable<std::vector<double>> binsPtV0{"binsPtV0", std::vector<double>{hf_cuts_v0_daughter::vecBinsPt}, "pT bin limits for V0 daughter cuts"};
97-
97+
9898
// Configurables for ME
9999
Configurable<int> numberEventsMixed{"numberEventsMixed", 5, "Number of events mixed in ME process"};
100100
Configurable<int> numberEventsToSkip{"numberEventsToSkip", -1, "Number of events to Skip in ME process"};
101101
ConfigurableAxis multPoolBins{"multPoolBins", {VARIABLE_WIDTH, 0., 45., 60., 75., 95, 250}, "event multiplicity pools (PV contributors for now)"};
102102
ConfigurableAxis zPoolBins{"zPoolBins", {VARIABLE_WIDTH, -10.0, -4, -1, 1, 4, 10.0}, "z vertex position pools"};
103-
103+
104104
using reducedDWithMl = soa::Join<aod::HfRed3PrNoTrks, aod::HfRed3ProngsMl>;
105105

106106
// Partition of V0 candidates based on v0Type
@@ -266,11 +266,11 @@ struct HfCandidateCreatorCharmResoReduced {
266266
float invMassD0{0.};
267267
if (std::abs(candD.dType()) == 1)
268268
invMassD = candD.invMassDplus();
269-
if (candD.dType() == 2){
269+
if (candD.dType() == 2) {
270270
invMassD = candD.invMassDstar();
271271
invMassD0 = candD.invMassD0();
272-
}
273-
if (candD.dType() == -2){
272+
}
273+
if (candD.dType() == -2) {
274274
invMassD = candD.invMassAntiDstar();
275275
invMassD0 = candD.invMassD0Bar();
276276
}
@@ -382,12 +382,12 @@ struct HfCandidateCreatorCharmResoReduced {
382382
{
383383
using BinningType = ColumnBinningPolicy<aod::collision::PosZ, aod::collision::NumContrib>;
384384
BinningType corrBinning{{zPoolBins, multPoolBins}, true};
385-
auto bachTuple = std::make_tuple(candsD,candsV0Tr);
385+
auto bachTuple = std::make_tuple(candsD, candsV0Tr);
386386
Pair<Coll, DRedTable, V0TrRedTable, BinningType> pairs{corrBinning, numberEventsMixed, numberEventsToSkip, collisions, bachTuple, &cache};
387-
for (const auto& [collision1, bachDs, collision2, bachV0Trs] : pairs){
387+
for (const auto& [collision1, bachDs, collision2, bachV0Trs] : pairs) {
388388
registry.fill(HIST("hNPvContCorr"), collision1.numContrib(), collision2.numContrib());
389389
registry.fill(HIST("hZvertCorr"), collision1.posZ(), collision2.posZ());
390-
for (const auto& [bachD, bachV0Tr] : o2::soa::combinations(o2::soa::CombinationsFullIndexPolicy(bachDs, bachV0Trs))){
390+
for (const auto& [bachD, bachV0Tr] : o2::soa::combinations(o2::soa::CombinationsFullIndexPolicy(bachDs, bachV0Trs))) {
391391
// Apply analysis selections on D and V0 bachelors
392392
if (!isDSelected<channel>(bachD) || !isV0Selected<channel>(bachV0Tr, bachD)) {
393393
continue;
@@ -397,11 +397,11 @@ struct HfCandidateCreatorCharmResoReduced {
397397
float invMassD0{0.};
398398
if (std::abs(bachD.dType()) == 1)
399399
invMassD = bachD.invMassDplus();
400-
if (bachD.dType() == 2){
400+
if (bachD.dType() == 2) {
401401
invMassD = bachD.invMassDstar();
402402
invMassD0 = bachD.invMassD0();
403-
}
404-
if (bachD.dType() == -2){
403+
}
404+
if (bachD.dType() == -2) {
405405
invMassD = bachD.invMassAntiDstar();
406406
invMassD0 = bachD.invMassD0Bar();
407407
}
@@ -443,15 +443,15 @@ struct HfCandidateCreatorCharmResoReduced {
443443
break;
444444
}
445445
// Fill output table
446-
rowCandidateReso( pVecD[0], pVecD[1], pVecD[2],
447-
pVecV0Tr[0], pVecV0Tr[1], pVecV0Tr[2],
448-
invMassReso,
449-
invMassD,
450-
invMassV0,
451-
bachV0Tr.cpa(),
452-
bachV0Tr.dca(),
453-
bachV0Tr.v0Radius(),
454-
invMassD0);
446+
rowCandidateReso(pVecD[0], pVecD[1], pVecD[2],
447+
pVecV0Tr[0], pVecV0Tr[1], pVecV0Tr[2],
448+
invMassReso,
449+
invMassD,
450+
invMassV0,
451+
bachV0Tr.cpa(),
452+
bachV0Tr.dca(),
453+
bachV0Tr.v0Radius(),
454+
invMassD0);
455455
rowCandidateResoIndices(collision1.globalIndex(),
456456
bachD.globalIndex(),
457457
bachV0Tr.globalIndex());
@@ -490,16 +490,16 @@ struct HfCandidateCreatorCharmResoReduced {
490490
PROCESS_SWITCH(HfCandidateCreatorCharmResoReduced, processDs2StarToDplusK0sWithMl, "Process Ds2* candidates with Ml info", false);
491491

492492
void processDs2StarToDplusK0sMixedEvent(aod::HfRedCollisions const& collisions,
493-
aod::HfRed3PrNoTrks const& candsD,
494-
aod::HfRedVzeros const& candsV0)
493+
aod::HfRed3PrNoTrks const& candsD,
494+
aod::HfRedVzeros const& candsV0)
495495
{
496496
runCandidateCreationMixedEvent<false, DecayChannel::Ds2StarToDplusK0s>(collisions, candsD, candsV0);
497497
}
498498
PROCESS_SWITCH(HfCandidateCreatorCharmResoReduced, processDs2StarToDplusK0sMixedEvent, "Process Ds2Star mixed Event without ML", false);
499499

500500
void processDs2StarToDplusK0sMixedEventWithMl(aod::HfRedCollisions const& collisions,
501-
reducedDWithMl const& candsD,
502-
aod::HfRedVzeros const& candsV0)
501+
reducedDWithMl const& candsD,
502+
aod::HfRedVzeros const& candsV0)
503503
{
504504
runCandidateCreationMixedEvent<true, DecayChannel::Ds2StarToDplusK0s>(collisions, candsD, candsV0);
505505
}
@@ -540,8 +540,8 @@ struct HfCandidateCreatorCharmResoReduced {
540540
PROCESS_SWITCH(HfCandidateCreatorCharmResoReduced, processDs1ToDstarK0sMixedEvent, "Process Ds1 mixed Event without ML", false);
541541

542542
void processDs1ToDstarK0sMixedEventWithMl(aod::HfRedCollisions const& collisions,
543-
reducedDWithMl const& candsD,
544-
aod::HfRedVzeros const& candsV0)
543+
reducedDWithMl const& candsD,
544+
aod::HfRedVzeros const& candsV0)
545545
{
546546
runCandidateCreationMixedEvent<true, DecayChannel::Ds1ToDstarK0s>(collisions, candsD, candsV0);
547547
}
@@ -637,7 +637,7 @@ struct HfCandidateCreatorCharmResoReducedExpressions {
637637
ConfigurableAxis axisInvMassReso{"axisInvMassReso", {200, 2.5, 2.7}, "inv. mass (DV_{0}) (GeV/#it{c}^{2})"};
638638
ConfigurableAxis axisInvMassProng0{"axisInvMassProng0", {200, 0.14, 0.17}, "inv. mass (D) (GeV/#it{c}^{2})"};
639639
ConfigurableAxis axisInvMassProng1{"axisInvMassProng1", {200, 0.47, 0.53}, "inv. mass ({V}_{0}) (GeV/#it{c}^{2})"};
640-
ConfigurableAxis axisInvMassD0{"axisInvMassD0", {200, 1.65, 2.05}, "inv. mass ({V}_{0}) (GeV/#it{c}^{2})"};
640+
ConfigurableAxis axisInvMassD0{"axisInvMassD0", {200, 1.65, 2.05}, "inv. mass ({V}_{0}) (GeV/#it{c}^{2})"};
641641
ConfigurableAxis axisDebug{"axisDebug", {16, -0.5, 15.5}, "MC debug flag"};
642642
ConfigurableAxis axisOrigin{"axisOrigin", {3, -0.5, 2.5}, "MC origin flag"};
643643
HistogramRegistry registry{"registry"};
@@ -655,7 +655,7 @@ struct HfCandidateCreatorCharmResoReducedExpressions {
655655
registry.add("hMassMcMatchedVsD0Mass", "Reso MC candidates NOT Matched with generate particle;m (GeV/#it{c}^{2}); m (GeV/#it{c}^{2})", {HistType::kTH2F, {axisInvMassReso, axisInvMassD0}});
656656
registry.add("hMassMcUnmatchedVsD0Mass", "Reso MC candidates Matched with generate particle w. Invcomplete decay;m (GeV/#it{c}^{2}); m (GeV/#it{c}^{2})", {HistType::kTH2F, {axisInvMassReso, axisInvMassD0}});
657657
registry.add("hMassMcUnmatchedVsDebug", "Reso MC candidates NOT Matched with generate particle;m (GeV/#it{c}^{2});debug flag", {HistType::kTH2F, {axisInvMassReso, axisDebug}});
658-
registry.add("hSparseUnmatchedDebug","THn for debug of MC matching and Correlated BKG study", HistType::kTHnSparseF, {axisInvMassReso, axisPt, axisInvMassProng0, axisInvMassProng1, axisInvMassD0, axisDebug, axisOrigin});
658+
registry.add("hSparseUnmatchedDebug", "THn for debug of MC matching and Correlated BKG study", HistType::kTHnSparseF, {axisInvMassReso, axisPt, axisInvMassProng0, axisInvMassProng1, axisInvMassD0, axisDebug, axisOrigin});
659659
}
660660

661661
/// Fill candidate information at MC reconstruction level
@@ -674,19 +674,19 @@ struct HfCandidateCreatorCharmResoReducedExpressions {
674674
filledMcInfo = true;
675675
if (TESTBIT(rowDV0McRec.flagMcMatchRec(), DecayTypeMc::Ds1ToDStarK0ToD0PiK0s) || TESTBIT(rowDV0McRec.flagMcMatchRec(), DecayTypeMc::Ds2StarToDplusK0sToPiKaPiPiPi)) {
676676
registry.fill(HIST("hMassMcMatched"), candReso.invMass(), candReso.pt());
677-
registry.fill(HIST("hMassMcMatchedVsBach0Mass"), candReso.invMass(), candReso.invMassProng0()-candReso.invMassD0());
677+
registry.fill(HIST("hMassMcMatchedVsBach0Mass"), candReso.invMass(), candReso.invMassProng0() - candReso.invMassD0());
678678
registry.fill(HIST("hMassMcMatchedVsBach1Mass"), candReso.invMass(), candReso.invMassProng1());
679679
registry.fill(HIST("hMassMcMatchedVsD0Mass"), candReso.invMass(), candReso.invMassD0());
680680

681681
} else if (TESTBIT(rowDV0McRec.flagMcMatchRec(), DecayTypeMc::Ds1ToDStarK0ToDPlusGammaK0s) || TESTBIT(rowDV0McRec.flagMcMatchRec(), DecayTypeMc::Ds1ToDStarK0ToDPlusPi0K0s)) {
682682
registry.fill(HIST("hMassMcMatchedIncomplete"), candReso.invMass(), candReso.pt());
683683
} else {
684684
registry.fill(HIST("hMassMcUnmatched"), candReso.invMass(), candReso.pt());
685-
registry.fill(HIST("hMassMcUnmatchedVsBach0Mass"), candReso.invMass(), candReso.invMassProng0()-candReso.invMassD0());
685+
registry.fill(HIST("hMassMcUnmatchedVsBach0Mass"), candReso.invMass(), candReso.invMassProng0() - candReso.invMassD0());
686686
registry.fill(HIST("hMassMcUnmatchedVsBach1Mass"), candReso.invMass(), candReso.invMassProng1());
687687
registry.fill(HIST("hMassMcUnmatchedVsD0Mass"), candReso.invMass(), candReso.invMassD0());
688688
registry.fill(HIST("hMassMcUnmatchedVsDebug"), candReso.invMass(), rowDV0McRec.debugMcRec());
689-
registry.fill(HIST("hSparseUnmatchedDebug"), candReso.invMass(), candReso.pt(), candReso.invMassProng0()-candReso.invMassD0(), candReso.invMassProng1(), candReso.invMassD0(), rowDV0McRec.debugMcRec(), rowDV0McRec.origin());
689+
registry.fill(HIST("hSparseUnmatchedDebug"), candReso.invMass(), candReso.pt(), candReso.invMassProng0() - candReso.invMassD0(), candReso.invMassProng1(), candReso.invMassD0(), rowDV0McRec.debugMcRec(), rowDV0McRec.origin());
690690
}
691691

692692
break;

PWGHF/D2H/TableProducer/dataCreatorCharmResoReduced.cxx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -949,8 +949,8 @@ struct HfDataCreatorCharmResoReduced {
949949
if (RecoDecay::isMatchedMCGen(particlesMc, candDStarMC, Pdg::kDStar, std::array{-kKPlus, +kPiPlus, +kPiPlus}, true, &signDStar, 2)) {
950950
flag = signDStar * BIT(DecayTypeMc::Ds1ToDStarK0ToD0PiK0s);
951951
if (RecoDecay::isMatchedMCGen<false, true>(particlesMc, candV0MC, kK0, std::array{+kPiPlus, -kMuonPlus, +kNuMu}, true, &signV0, 3) ||
952-
RecoDecay::isMatchedMCGen<false, true>(particlesMc, candDStarMC, Pdg::kDStar, std::array{-kKPlus, +kPiPlus, +kMuonPlus, -kNuMu}, true, &signDStar, 3)){
953-
flag = signDStar * BIT(DecayTypeMc::Ds1ToDStarK0ToD0PiK0sOneMu);
952+
RecoDecay::isMatchedMCGen<false, true>(particlesMc, candDStarMC, Pdg::kDStar, std::array{-kKPlus, +kPiPlus, +kMuonPlus, -kNuMu}, true, &signDStar, 3)) {
953+
flag = signDStar * BIT(DecayTypeMc::Ds1ToDStarK0ToD0PiK0sOneMu);
954954
}
955955
} else if (RecoDecay::isMatchedMCGen(particlesMc, candD0MC, Pdg::kD0, std::array{-kKPlus, +kPiPlus, +kPiPlus, +kPi0}, true, &signDStar, 2) ||
956956
RecoDecay::isMatchedMCGen(particlesMc, candD0MC, Pdg::kD0, std::array{-kKPlus, +kPiPlus, +kPiPlus, -kPi0}, true, &signDStar, 2)) {

0 commit comments

Comments
 (0)