Skip to content

Commit b154c3a

Browse files
authored
[DPG] Fix multiple initialisations in histogram registry (#8924)
1 parent a2fd229 commit b154c3a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

DPG/Tasks/AOTTrack/qaEfficiency.cxx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,6 @@ struct QaEfficiency {
338338
phiMin, phiMax,
339339
yMin, yMax);
340340
const int histogramIndex = id + pdgSign * nSpecies;
341-
hPtmotherGenerated = histos.add<TH1>("MC/mother/pt/generated", "Generated pT of mother Lambda or Xi", kTH1D, {axisPt});
342341

343342
// Pt
344343
hPtIts[histogramIndex] = histos.add<TH1>(Form("MC/pdg%i/pt/its", PDGs[histogramIndex]), "ITS tracks " + tagPt, kTH1D, {axisPt});
@@ -664,6 +663,9 @@ struct QaEfficiency {
664663
histos.add("MC/occ_cent/reco/neg/its", "ITS Negative ", kTH3D, {axisOcc, axisCent, axisPt});
665664
}
666665

666+
AxisSpec axisPtMother{ptBins, "#it{p}_{T} (GeV/#it{c})"};
667+
hPtmotherGenerated = histos.add<TH1>("MC/mother/pt/generated", "Generated pT of mother Lambda or Xi", kTH1D, {axisPtMother});
668+
667669
static_for<0, 1>([&](auto pdgSign) {
668670
makeMCHistograms<pdgSign, o2::track::PID::Electron>(doEl);
669671
makeMCHistograms<pdgSign, o2::track::PID::Muon>(doMu);

0 commit comments

Comments
 (0)