Skip to content

Commit 252758f

Browse files
Cleanup
1 parent d54a4ee commit 252758f

File tree

2 files changed

+30
-27
lines changed

2 files changed

+30
-27
lines changed

PWGLF/TableProducer/Strangeness/sigma0builder.cxx

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -407,15 +407,17 @@ struct sigma0builder {
407407
histos.fill(HIST("Gen/hPrimaryPi0s"), 0);
408408
if (isPrimary) histos.fill(HIST("Gen/hPrimaryPi0s"), 1);
409409

410-
pi0Gens(ptmc); // optional table to store generated pi0 candidates. Be careful, this is a large table!
411-
pi0GenCollRefs(mccollisionid); // link to stramccollision table
410+
if (fillPi0Tables){
411+
pi0Gens(ptmc); // optional table to store generated pi0 candidates. Be careful, this is a large table!
412+
pi0GenCollRefs(mccollisionid); // link to stramccollision table
413+
}
412414
}
413415

414416
// Sigma0-specific
415417
if (isSigma0 || isAntiSigma0){
416418

417419
// Checking decay mode
418-
auto daughtersIDs = mcParticle.daughtersIds();
420+
//auto daughtersIDs = mcParticle.daughtersIds();
419421
auto const& daughters = mcParticle.template daughters_as<aod::McParticles>();
420422

421423
if (daughters.size() == 2) {

PWGLF/Tasks/Strangeness/sigmaanalysis.cxx

Lines changed: 25 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -486,30 +486,31 @@ struct sigmaanalysis {
486486
histos.add("Gen/hCentralityVsPVzMC", "hCentralityVsPVzMC", kTH2F, {{101, 0.0f, 101.0f}, {100, -20.0f, +20.0f}});
487487

488488
// Sigma0 specific
489-
histos.add("Gen/h2dGenSigma0", "h2dGenSigma0", kTH2D, {axisCentrality, axisPt});
490-
histos.add("Gen/h2dGenAntiSigma0", "h2dGenAntiSigma0", kTH2D, {axisCentrality, axisPt});
491-
histos.add("Gen/h2dGenSigma0VsMultMC_RecoedEvt", "h2dGenSigma0VsMultMC_RecoedEvt", kTH2D, {axisNch, axisPt});
492-
histos.add("Gen/h2dGenAntiSigma0VsMultMC_RecoedEvt", "h2dGenAntiSigma0VsMultMC_RecoedEvt", kTH2D, {axisNch, axisPt});
493-
histos.add("Gen/h2dGenSigma0VsMultMC", "h2dGenSigma0VsMultMC", kTH2D, {axisNch, axisPt});
494-
histos.add("Gen/h2dGenAntiSigma0VsMultMC", "h2dGenAntiSigma0VsMultMC", kTH2D, {axisNch, axisPt});
495-
496-
auto hGenSigma0Type = histos.add<TH1>("Gen/hGenSigma0Type", "hGenSigma0Type", kTH1D, {{4, -0.5f, 3.5f}});
497-
hGenSigma0Type->GetXaxis()->SetBinLabel(1, "All Sigma0s");
498-
hGenSigma0Type->GetXaxis()->SetBinLabel(2, "Sterile");
499-
hGenSigma0Type->GetXaxis()->SetBinLabel(3, "Lambda+Gamma");
500-
hGenSigma0Type->GetXaxis()->SetBinLabel(4, "Others");
501-
502-
auto h2DGenSigma0Type = histos.add<TH2>("Gen/h2DGenSigma0Type", "h2DGenSigma0Type", kTH2D, {{4, -0.5f, 3.5f}, axisGeneratorIds});
503-
h2DGenSigma0Type->GetXaxis()->SetBinLabel(1, "All Sigma0s");
504-
h2DGenSigma0Type->GetXaxis()->SetBinLabel(2, "Sterile");
505-
h2DGenSigma0Type->GetXaxis()->SetBinLabel(3, "Lambda+Gamma");
506-
h2DGenSigma0Type->GetXaxis()->SetBinLabel(4, "Others");
507-
508-
// Pi0 specific
509-
histos.add("Gen/h2dGenPi0VsMultMC_RecoedEvt", "h2dGenPi0VsMultMC_RecoedEvt", kTH2D, {axisNch, axisPt});
510-
histos.add("Gen/h2dGenPi0", "h2dGenPi0", kTH2D, {axisCentrality, axisPt});
511-
histos.add("Gen/h2dGenPi0VsMultMC", "h2dGenPi0VsMultMC", kTH2D, {axisNch, axisPt});
512-
489+
if (doprocessGeneratedRun3){
490+
histos.add("Gen/h2dGenSigma0", "h2dGenSigma0", kTH2D, {axisCentrality, axisPt});
491+
histos.add("Gen/h2dGenAntiSigma0", "h2dGenAntiSigma0", kTH2D, {axisCentrality, axisPt});
492+
histos.add("Gen/h2dGenSigma0VsMultMC_RecoedEvt", "h2dGenSigma0VsMultMC_RecoedEvt", kTH2D, {axisNch, axisPt});
493+
histos.add("Gen/h2dGenAntiSigma0VsMultMC_RecoedEvt", "h2dGenAntiSigma0VsMultMC_RecoedEvt", kTH2D, {axisNch, axisPt});
494+
histos.add("Gen/h2dGenSigma0VsMultMC", "h2dGenSigma0VsMultMC", kTH2D, {axisNch, axisPt});
495+
histos.add("Gen/h2dGenAntiSigma0VsMultMC", "h2dGenAntiSigma0VsMultMC", kTH2D, {axisNch, axisPt});
496+
497+
auto hGenSigma0Type = histos.add<TH1>("Gen/hGenSigma0Type", "hGenSigma0Type", kTH1D, {{4, -0.5f, 3.5f}});
498+
hGenSigma0Type->GetXaxis()->SetBinLabel(1, "All Sigma0s");
499+
hGenSigma0Type->GetXaxis()->SetBinLabel(2, "Sterile");
500+
hGenSigma0Type->GetXaxis()->SetBinLabel(3, "Lambda+Gamma");
501+
hGenSigma0Type->GetXaxis()->SetBinLabel(4, "Others");
502+
503+
auto h2DGenSigma0Type = histos.add<TH2>("Gen/h2DGenSigma0Type", "h2DGenSigma0Type", kTH2D, {{4, -0.5f, 3.5f}, axisGeneratorIds});
504+
h2DGenSigma0Type->GetXaxis()->SetBinLabel(1, "All Sigma0s");
505+
h2DGenSigma0Type->GetXaxis()->SetBinLabel(2, "Sterile");
506+
h2DGenSigma0Type->GetXaxis()->SetBinLabel(3, "Lambda+Gamma");
507+
h2DGenSigma0Type->GetXaxis()->SetBinLabel(4, "Others");
508+
}
509+
else{ // Pi0 specific
510+
histos.add("Gen/h2dGenPi0VsMultMC_RecoedEvt", "h2dGenPi0VsMultMC_RecoedEvt", kTH2D, {axisNch, axisPt});
511+
histos.add("Gen/h2dGenPi0", "h2dGenPi0", kTH2D, {axisCentrality, axisPt});
512+
histos.add("Gen/h2dGenPi0VsMultMC", "h2dGenPi0VsMultMC", kTH2D, {axisNch, axisPt});
513+
}
513514
}
514515
}
515516

0 commit comments

Comments
 (0)