From e6f0540f647dea424526dd4a840a16f602d4bcf1 Mon Sep 17 00:00:00 2001 From: ariffero Date: Fri, 7 Feb 2025 10:50:10 +0100 Subject: [PATCH 1/3] Add finer pt binning histo --- PWGUD/Tasks/FwdMuonsUPC.cxx | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/PWGUD/Tasks/FwdMuonsUPC.cxx b/PWGUD/Tasks/FwdMuonsUPC.cxx index b35a2d8167c..e6044242387 100644 --- a/PWGUD/Tasks/FwdMuonsUPC.cxx +++ b/PWGUD/Tasks/FwdMuonsUPC.cxx @@ -237,9 +237,20 @@ struct FwdMuonsUPC { 0.60, 0.70, 0.80, 0.90, 1.00, 1.20, 1.40, 1.60, 1.80, 2.00, 2.50, 3.00, 3.50}; + std::vector ptFitBinningHalfWidth = { + 0.00, 0.005, 0.01, 0.015, 0.02, 0.025, 0.03, 0.035, 0.04, 0.045, 0.05, + 0.055, 0.06, 0.065, 0.07, 0.075, 0.08, 0.085, 0.09, 0.095, 0.10, + 0.105, 0.11, 0.115, 0.12, 0.125, 0.13, 0.135, 0.14, 0.145, 0.15, + 0.1625, 0.175, 0.1875, 0.20, 0.225, 0.25, 0.275, 0.30, 0.35, 0.40, + 0.45, 0.50, 0.55, 0.60, 0.65, 0.70, 0.75, 0.80, 0.85, 0.90, 0.95, 1.00, + 1.10, 1.20, 1.30, 1.40, 1.50, 1.60, 1.70, 1.80, 1.90, 2.00, 2.25, + 2.50, 2.75, 3.00, 3.25, 3.50 + }; + // axis const AxisSpec axisPt{nBinsPt, lowPt, highPt, "#it{p}_{T} GeV/#it{c}"}; const AxisSpec axisPtFit = {ptFitBinning, "#it{p}_{T} (GeV/c)"}; + const AxisSpec axisPtFit2 = {ptFitBinningHalfWidth, "#it{p}_{T} (GeV/c)"}; const AxisSpec axisMass{nBinsMass, lowMass, highMass, "m_{#mu#mu} GeV/#it{c}^{2}"}; const AxisSpec axisEta{nBinsEta, lowEta, highEta, "#eta"}; const AxisSpec axisRapidity{nBinsRapidity, lowRapidity, highRapidity, "Rapidity"}; @@ -256,6 +267,7 @@ struct FwdMuonsUPC { registry.add("hMass", "Invariant mass of muon pairs;;#counts", kTH1D, {axisMass}); registry.add("hPt", "Transverse momentum of muon pairs;;#counts", kTH1D, {axisPt}); registry.add("hPtFit", "Transverse momentum of muon pairs;;#counts", kTH1D, {axisPtFit}); + registry.add("hPtFit2", "Transverse momentum of muon pairs;;#counts", kTH1D, {axisPtFit2}); registry.add("hEta", "Pseudorapidty of muon pairs;;#counts", kTH1D, {axisEta}); registry.add("hRapidity", "Rapidty of muon pairs;;#counts", kTH1D, {axisRapidity}); registry.add("hPhi", "#varphi of muon pairs;;#counts", kTH1D, {axisPhi}); @@ -314,6 +326,7 @@ struct FwdMuonsUPC { mcRecoRegistry.add("hMass", "Invariant mass of muon pairs;;#counts", kTH1D, {axisMass}); mcRecoRegistry.add("hPt", "Transverse momentum of muon pairs;;#counts", kTH1D, {axisPt}); mcRecoRegistry.add("hPtFit", "Transverse momentum of muon pairs;;#counts", kTH1D, {axisPtFit}); + mcRecoRegistry.add("hPtFit2", "Transverse momentum of muon pairs;;#counts", kTH1D, {axisPtFit2}); mcRecoRegistry.add("hEta", "Pseudorapidty of muon pairs;;#counts", kTH1D, {axisEta}); mcRecoRegistry.add("hRapidity", "Rapidty of muon pairs;;#counts", kTH1D, {axisRapidity}); mcRecoRegistry.add("hPhi", "#varphi of muon pairs;;#counts", kTH1D, {axisPhi}); @@ -615,6 +628,7 @@ struct FwdMuonsUPC { registry.fill(HIST("hMass"), p.M()); registry.fill(HIST("hPt"), p.Pt()); registry.fill(HIST("hPtFit"), p.Pt()); + registry.fill(HIST("hPtFit2"), p.Pt()); registry.fill(HIST("hEta"), p.Eta()); registry.fill(HIST("hRapidity"), p.Rapidity()); registry.fill(HIST("hPhi"), p.Phi()); @@ -812,6 +826,7 @@ struct FwdMuonsUPC { mcRecoRegistry.fill(HIST("hMass"), p.M()); mcRecoRegistry.fill(HIST("hPt"), p.Pt()); mcRecoRegistry.fill(HIST("hPtFit"), p.Pt()); + mcRecoRegistry.fill(HIST("hPtFit2"), p.Pt()); mcRecoRegistry.fill(HIST("hEta"), p.Eta()); mcRecoRegistry.fill(HIST("hRapidity"), p.Rapidity()); mcRecoRegistry.fill(HIST("hPhi"), p.Phi()); From 34611b4ba62850b38576b7757ccfce0ace479e42 Mon Sep 17 00:00:00 2001 From: ariffero Date: Thu, 6 Mar 2025 10:40:55 +0100 Subject: [PATCH 2/3] Modify names of saved gen varaibles. The names of the varaibles in the gen tree are now the same as the name of the gen varaibles in the reco tree. --- PWGUD/Tasks/FwdMuonsUPC.cxx | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/PWGUD/Tasks/FwdMuonsUPC.cxx b/PWGUD/Tasks/FwdMuonsUPC.cxx index e6044242387..a61f975cdab 100644 --- a/PWGUD/Tasks/FwdMuonsUPC.cxx +++ b/PWGUD/Tasks/FwdMuonsUPC.cxx @@ -86,28 +86,28 @@ DECLARE_SOA_TABLE(DiMu, "AOD", "DIMU", namespace gendimu { // dimuon -DECLARE_SOA_COLUMN(M, m, float); -DECLARE_SOA_COLUMN(Pt, pt, float); -DECLARE_SOA_COLUMN(Rap, rap, float); -DECLARE_SOA_COLUMN(Phi, phi, float); -DECLARE_SOA_COLUMN(PhiAv, phiAv, float); -DECLARE_SOA_COLUMN(PhiCh, phiCh, float); +DECLARE_SOA_COLUMN(GenM, genM, float); +DECLARE_SOA_COLUMN(GenPt, genPt, float); +DECLARE_SOA_COLUMN(GenRap, genRap, float); +DECLARE_SOA_COLUMN(GenPhi, genPhi, float); +DECLARE_SOA_COLUMN(GenPhiAv, genPhiAv, float); +DECLARE_SOA_COLUMN(GenPhiCh, genPhiCh, float); // tracks positive (p) and negative (n) -DECLARE_SOA_COLUMN(Ptp, ptp, float); -DECLARE_SOA_COLUMN(Etap, etap, float); -DECLARE_SOA_COLUMN(Phip, phip, float); -DECLARE_SOA_COLUMN(Ptn, ptn, float); -DECLARE_SOA_COLUMN(Etan, etan, float); -DECLARE_SOA_COLUMN(Phin, phin, float); +DECLARE_SOA_COLUMN(GenPtp, genPtp, float); +DECLARE_SOA_COLUMN(GenEtap, genEtap, float); +DECLARE_SOA_COLUMN(GenPhip, genPhip, float); +DECLARE_SOA_COLUMN(GenPtn, genPtn, float); +DECLARE_SOA_COLUMN(GenEtan, genEtan, float); +DECLARE_SOA_COLUMN(GenPhin, genPhin, float); } // namespace gendimu namespace o2::aod { DECLARE_SOA_TABLE(GenDimu, "AOD", "GENDIMU", - gendimu::M, gendimu::Pt, gendimu::Rap, gendimu::Phi, - gendimu::PhiAv, gendimu::PhiCh, - gendimu::Ptp, gendimu::Etap, gendimu::Phip, - gendimu::Ptn, gendimu::Etan, gendimu::Phin); + gendimu::GenM, gendimu::GenPt, gendimu::GenRap, gendimu::GenPhi, + gendimu::GenPhiAv, gendimu::GenPhiCh, + gendimu::GenPtp, gendimu::GenEtap, gendimu::GenPhip, + gendimu::GenPtn, gendimu::GenEtan, gendimu::GenPhin); } // namespace o2::aod // for saving tree with info on reco MC From 96b879f82c6260104c9a54f1627b7067b53c7bb6 Mon Sep 17 00:00:00 2001 From: ALICE Action Bot Date: Fri, 28 Mar 2025 13:13:30 +0000 Subject: [PATCH 3/3] Please consider the following formatting changes --- PWGUD/Tasks/FwdMuonsUPC.cxx | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/PWGUD/Tasks/FwdMuonsUPC.cxx b/PWGUD/Tasks/FwdMuonsUPC.cxx index a61f975cdab..ee5e578161c 100644 --- a/PWGUD/Tasks/FwdMuonsUPC.cxx +++ b/PWGUD/Tasks/FwdMuonsUPC.cxx @@ -86,17 +86,17 @@ DECLARE_SOA_TABLE(DiMu, "AOD", "DIMU", namespace gendimu { // dimuon -DECLARE_SOA_COLUMN(GenM, genM, float); -DECLARE_SOA_COLUMN(GenPt, genPt, float); -DECLARE_SOA_COLUMN(GenRap, genRap, float); -DECLARE_SOA_COLUMN(GenPhi, genPhi, float); +DECLARE_SOA_COLUMN(GenM, genM, float); +DECLARE_SOA_COLUMN(GenPt, genPt, float); +DECLARE_SOA_COLUMN(GenRap, genRap, float); +DECLARE_SOA_COLUMN(GenPhi, genPhi, float); DECLARE_SOA_COLUMN(GenPhiAv, genPhiAv, float); DECLARE_SOA_COLUMN(GenPhiCh, genPhiCh, float); // tracks positive (p) and negative (n) -DECLARE_SOA_COLUMN(GenPtp, genPtp, float); +DECLARE_SOA_COLUMN(GenPtp, genPtp, float); DECLARE_SOA_COLUMN(GenEtap, genEtap, float); DECLARE_SOA_COLUMN(GenPhip, genPhip, float); -DECLARE_SOA_COLUMN(GenPtn, genPtn, float); +DECLARE_SOA_COLUMN(GenPtn, genPtn, float); DECLARE_SOA_COLUMN(GenEtan, genEtan, float); DECLARE_SOA_COLUMN(GenPhin, genPhin, float); } // namespace gendimu @@ -104,10 +104,10 @@ DECLARE_SOA_COLUMN(GenPhin, genPhin, float); namespace o2::aod { DECLARE_SOA_TABLE(GenDimu, "AOD", "GENDIMU", - gendimu::GenM, gendimu::GenPt, gendimu::GenRap, gendimu::GenPhi, + gendimu::GenM, gendimu::GenPt, gendimu::GenRap, gendimu::GenPhi, gendimu::GenPhiAv, gendimu::GenPhiCh, - gendimu::GenPtp, gendimu::GenEtap, gendimu::GenPhip, - gendimu::GenPtn, gendimu::GenEtan, gendimu::GenPhin); + gendimu::GenPtp, gendimu::GenEtap, gendimu::GenPhip, + gendimu::GenPtn, gendimu::GenEtan, gendimu::GenPhin); } // namespace o2::aod // for saving tree with info on reco MC @@ -244,8 +244,7 @@ struct FwdMuonsUPC { 0.1625, 0.175, 0.1875, 0.20, 0.225, 0.25, 0.275, 0.30, 0.35, 0.40, 0.45, 0.50, 0.55, 0.60, 0.65, 0.70, 0.75, 0.80, 0.85, 0.90, 0.95, 1.00, 1.10, 1.20, 1.30, 1.40, 1.50, 1.60, 1.70, 1.80, 1.90, 2.00, 2.25, - 2.50, 2.75, 3.00, 3.25, 3.50 - }; + 2.50, 2.75, 3.00, 3.25, 3.50}; // axis const AxisSpec axisPt{nBinsPt, lowPt, highPt, "#it{p}_{T} GeV/#it{c}"};