Skip to content

Commit 9f9c33d

Browse files
authored
[PWGHF] Fix the unit mismatch in QA histogram filling (#18577)
1 parent b0eedb8 commit 9f9c33d

2 files changed

Lines changed: 15 additions & 13 deletions

File tree

‎PWGHF/TableProducer/candidateCreatorXicToXiPiPi.cxx‎

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,8 @@ struct HfCandidateCreatorXicToXiPiPi {
151151
HistogramRegistry registry{"registry"};
152152
OutputObj<ZorroSummary> zorroSummary{"zorroSummary"};
153153

154+
static constexpr float cmToMicrometer{10000.};
155+
154156
void init(InitContext const&)
155157
{
156158
if ((doprocessNoCentXicplusWithDcaFitter + doprocessCentFT0CXicplusWithDcaFitter + doprocessCentFT0MXicplusWithDcaFitter + doprocessNoCentXicplusWithKFParticle + doprocessCentFT0CXicplusWithKFParticle + doprocessCentFT0MXicplusWithKFParticle) != 1) {
@@ -541,12 +543,12 @@ struct HfCandidateCreatorXicToXiPiPi {
541543
registry.fill(HIST("hCovSVXZ"), covMatrixSV[3]);
542544
registry.fill(HIST("hCovSVZZ"), covMatrixSV[5]);
543545
// DCAs of prongs
544-
registry.fill(HIST("hDcaXYProngs"), trackCasc.getPt(), impactParameterCasc.getY());
545-
registry.fill(HIST("hDcaXYProngs"), trackCharmBachelor0.pt(), impactParameter0.getY());
546-
registry.fill(HIST("hDcaXYProngs"), trackCharmBachelor1.pt(), impactParameter1.getY());
547-
registry.fill(HIST("hDcaZProngs"), trackCasc.getPt(), impactParameterCasc.getZ());
548-
registry.fill(HIST("hDcaZProngs"), trackCharmBachelor0.pt(), impactParameter0.getZ());
549-
registry.fill(HIST("hDcaZProngs"), trackCharmBachelor1.pt(), impactParameter1.getZ());
546+
registry.fill(HIST("hDcaXYProngs"), trackCasc.getPt(), impactParameterCasc.getY() * cmToMicrometer);
547+
registry.fill(HIST("hDcaXYProngs"), trackCharmBachelor0.pt(), impactParameter0.getY() * cmToMicrometer);
548+
registry.fill(HIST("hDcaXYProngs"), trackCharmBachelor1.pt(), impactParameter1.getY() * cmToMicrometer);
549+
registry.fill(HIST("hDcaZProngs"), trackCasc.getPt(), impactParameterCasc.getZ() * cmToMicrometer);
550+
registry.fill(HIST("hDcaZProngs"), trackCharmBachelor0.pt(), impactParameter0.getZ() * cmToMicrometer);
551+
registry.fill(HIST("hDcaZProngs"), trackCharmBachelor1.pt(), impactParameter1.getZ() * cmToMicrometer);
550552
}
551553

552554
//---------------------------------fill candidate table rows-------------------------------------------------------------------------------------------
@@ -873,9 +875,9 @@ struct HfCandidateCreatorXicToXiPiPi {
873875
registry.fill(HIST("hCovSVXZ"), covMatrixXicPlus[3]);
874876
registry.fill(HIST("hCovSVZZ"), covMatrixXicPlus[5]);
875877
// DCAs of prongs
876-
registry.fill(HIST("hDcaXYProngs"), kfXi.GetPt(), impactParameterXiXY);
877-
registry.fill(HIST("hDcaXYProngs"), kfCharmBachelor0.GetPt(), impactParameterPi0XY);
878-
registry.fill(HIST("hDcaXYProngs"), kfCharmBachelor1.GetPt(), impactParameterPi1XY);
878+
registry.fill(HIST("hDcaXYProngs"), kfXi.GetPt(), impactParameterXiXY * cmToMicrometer);
879+
registry.fill(HIST("hDcaXYProngs"), kfCharmBachelor0.GetPt(), impactParameterPi0XY * cmToMicrometer);
880+
registry.fill(HIST("hDcaXYProngs"), kfCharmBachelor1.GetPt(), impactParameterPi1XY * cmToMicrometer);
879881
}
880882

881883
//------------------------------fill candidate table rows--------------------------------------
@@ -1093,7 +1095,7 @@ struct HfCandidateCreatorXicToXiPiPiExpressions {
10931095
registry.add("hDecayedPions", "hDecayedPions", {HistType::kTH1F, {{5, -0.5, 4.5}}});
10941096
registry.add("hInteractionsWithMaterial", "hInteractionsWithMaterial", {HistType::kTH1F, {{6, -0.5, 5.5}}});
10951097
registry.add("hDebugRec", "hDebugRec", {HistType::kTH1F, {{4, -0.5, 3.5}}});
1096-
registry.add("hy_pt_gen", "Generated MC", {HistType::kTH2F, {{20, -1.0, 1.0}, {200, 0, 20}}});
1098+
registry.add("hYPtGen", "Generated MC", {HistType::kTH2F, {{20, -1.0, 1.0}, {200, 0, 20}}});
10971099
registry.get<TH1>(HIST("hDebugRec"))->GetXaxis()->SetBinLabel(1 + TotalRec, "total");
10981100
registry.get<TH1>(HIST("hDebugRec"))->GetXaxis()->SetBinLabel(1 + XicToFinalState, "#Xi^{+}_{c} #rightarrow #pi^{#plus} #pi^{#plus} #pi^{#minus} p #pi^{#minus}");
10991101
registry.get<TH1>(HIST("hDebugRec"))->GetXaxis()->SetBinLabel(1 + XiToPiPPi, "#Xi^{#minus} #rightarrow #pi^{#minus} p #pi^{#minus}");
@@ -1348,7 +1350,7 @@ struct HfCandidateCreatorXicToXiPiPiExpressions {
13481350
// Check whether the charm baryon is non-prompt (from a b quark).
13491351
if (flag != 0) {
13501352
// fill inclusive generated Xic+
1351-
registry.fill(HIST("hy_pt_gen"), particle.y(), particle.pt());
1353+
registry.fill(HIST("hYPtGen"), particle.y(), particle.pt());
13521354

13531355
origin = RecoDecay::getCharmHadronOrigin(mcParticles, particle, false, &idxBhadMothers);
13541356
// Calculate the decay length of the generated particle

‎PWGHF/TableProducer/candidateSelectorXicToXiPiPi.cxx‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ struct HfCandidateSelectorXicToXiPiPi {
251251
registry.add("hNCrossedRowsTpcV0PosDauRecBkg", "Reconstructed background;#it{N}_{rows}^{TPC} (V0 pos. dau.);entries", {HistType::kTH1F, {{103, 49.5, 152.5}}});
252252
registry.add("hNCrossedRowsTpcV0NegDauRecBkg", "Reconstructed background;#it{N}_{rows}^{TPC} (V0 neg. dau.);entries", {HistType::kTH1F, {{103, 49.5, 152.5}}});
253253
/// reconstructed MC
254-
registry.add("hmass_pt_reco_truth", "Reconstructed truth matching MC;inv.mass(#Xi#pi#pi) [GeV/c^{2}];p_{T} [GeV/c]", {HistType::kTH2F, {{40, 2.3, 2.7}, {200, 0, 20}}});
254+
registry.add("hMassPtRecSig", "Reconstructed truth matching MC;inv.mass(#Xi#pi#pi) [GeV/c^{2}];p_{T} [GeV/c]", {HistType::kTH2F, {{40, 2.3, 2.7}, {200, 0, 20}}});
255255
}
256256
}
257257

@@ -655,7 +655,7 @@ struct HfCandidateSelectorXicToXiPiPi {
655655
if constexpr (IsMc) {
656656
if (isMatchedSignal) {
657657
registry.fill(HIST("hSelCandidatesRecSig"), PidSelected);
658-
registry.fill(HIST("hmass_pt_reco_truth"), hfCandXic.invMassXicPlus(), hfCandXic.pt());
658+
registry.fill(HIST("hMassPtRecSig"), hfCandXic.invMassXicPlus(), hfCandXic.pt());
659659
} else {
660660
registry.fill(HIST("hSelCandidatesRecBkg"), PidSelected);
661661
}

0 commit comments

Comments
 (0)