@@ -87,6 +87,16 @@ struct statPromptPhoton {
8787 Configurable<bool > cfgJETracks{" cfgJETracks" , false , " Enables running on derived JE data" };
8888 Configurable<bool > cfgGenHistograms{" cfgGenHistograms" , false , " Enables Generated histograms" };
8989 Configurable<bool > cfgGenReqRec{" cfgGenReqRec" , false , " Only consider generated events which are successfully reconstructed" };
90+ Configurable<bool > cfgReqRecPS_REC{" cfgReqRecPS_REC" , false , " Only consider reconstructed photons within the EMCAl acceptence" };
91+ Configurable<bool > cfgReqRecPS_GEN{" cfgReqRecPS_GEN" , false , " Only consider generated photons within the EMCAl acceptence" };
92+ Configurable<float > cfgEMClowPSphi{" cfgEMClowPSphi" , 1.42 , " lower limit of the EMC acceptance if Rec PS is required" };
93+ Configurable<float > cfgEMChighPSphi{" cfgEMChighPSphi" , 3.26 , " higher limit of the EMC acceptance if Rec PS is required" };
94+ Configurable<float > cfgEMChighPSeta{" cfgEMChighPSeta" , 0.62 , " symmetric eta cut if Rec PS is required" };
95+ Configurable<float > cfgDClowPSphi{" cfgDClowPSphi" , 4.56 , " lower limit of the DCal acceptance if Rec PS is required" };
96+ Configurable<float > cfgDChighPSphi{" cfgDChighPSphi" , 5.70 , " higher limit of the DCal acceptance if Rec PS is required" };
97+ Configurable<int > cfgMCptNbins{" cfgMCptNbins" , 200 , " number of ptbins in MC QA plots" };
98+ Configurable<double > cfgMCptbinLow{" cfgMCptbinLow" , 5 , " lower limit of ptbins in MC QA plots" };
99+ Configurable<double > cfgMCptbinHigh{" cfgMCptbinHigh" , 200 , " upper limit of ptbins in MC QA plots" };
90100 Configurable<bool > cfgRecHistograms{" cfgRecHistograms" , false , " Enables Reconstructed histograms" };
91101 Configurable<bool > cfgDataHistograms{" cfgDataHistograms" , false , " Enables Data histograms" };
92102 Configurable<std::string> cfgTriggerMasks{" cfgTriggerMasks" , " " , " possible JE Trigger masks: fJetChLowPt,fJetChHighPt,fTrackLowPt,fTrackHighPt,fJetD0ChLowPt,fJetD0ChHighPt,fJetLcChLowPt,fJetLcChHighPt,fEMCALReadout,fJetFullHighPt,fJetFullLowPt,fJetNeutralHighPt,fJetNeutralLowPt,fGammaVeryHighPtEMCAL,fGammaVeryHighPtDCAL,fGammaHighPtEMCAL,fGammaHighPtDCAL,fGammaLowPtEMCAL,fGammaLowPtDCAL,fGammaVeryLowPtEMCAL,fGammaVeryLowPtDCAL" };
@@ -101,6 +111,8 @@ struct statPromptPhoton {
101111 std::vector<double > ptBinning = {0.0 , 0.1 , 0.2 , 0.3 , 0.4 , 0.5 , 0.6 , 0.7 , 0.8 , 0.9 , 1.0 , 1.2 , 1.4 , 1.6 , 1.8 , 2.0 , 2.5 , 3.0 , 4.0 , 5.0 , 6.0 , 8.0 , 12.0 , 16.0 , 20.0 , 25.0 , 30.0 , 40.0 , 50.0 , 75.0 , 100.0 , 150.0 , 200.0 , 300.0 , 500.0 };
102112 AxisSpec pthadAxis = {ptBinning, " #it{p}_{T}^{had sum} [GeV/c]" };
103113
114+ const AxisSpec MCptAxis = {cfgMCptNbins, cfgMCptbinLow, cfgMCptbinHigh};
115+
104116 triggerMaskBits = jetderiveddatautilities::initialiseTriggerMaskBits (cfgTriggerMasks);
105117 if (cfgJETracks) {
106118 trackFilter = jetderiveddatautilities::initialiseTrackSelection (static_cast <std::string>(cfgTrackFilter));
@@ -184,48 +196,48 @@ struct statPromptPhoton {
184196 histos.add (" REC_dR_Stern" , " REC_dR_Stern" , kTH1F , {{628 , 0.0 , 2 * TMath::Pi ()}});
185197 histos.add (" REC_prompt_phiQA" , " REC_prompt_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
186198 histos.add (" REC_prompt_etaQA" , " REC_prompt_etaQA" , kTH1F , {{100 , -1 , 1 }});
187- histos.add (" REC_prompt_ptQA" , " REC_prompt_ptQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
199+ histos.add (" REC_prompt_ptQA" , " REC_prompt_ptQA" , kTH1F , {MCptAxis });
188200 histos.add (" REC_decay_phiQA" , " REC_decay_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
189201 histos.add (" REC_decay_etaQA" , " REC_decay_etaQA" , kTH1F , {{100 , -1 , 1 }});
190- histos.add (" REC_decay_ptQA" , " REC_decay_ptQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
202+ histos.add (" REC_decay_ptQA" , " REC_decay_ptQA" , kTH1F , {MCptAxis });
191203 histos.add (" REC_frag_phiQA" , " REC_frag_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
192204 histos.add (" REC_frag_etaQA" , " REC_frag_etaQA" , kTH1F , {{100 , -1 , 1 }});
193- histos.add (" REC_frag_ptQA" , " REC_frag_ptQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
205+ histos.add (" REC_frag_ptQA" , " REC_frag_ptQA" , kTH1F , {MCptAxis });
194206 histos.add (" REC_direct_phiQA" , " REC_direct_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
195207 histos.add (" REC_direct_etaQA" , " REC_direct_etaQA" , kTH1F , {{100 , -1 , 1 }});
196- histos.add (" REC_direct_ptQA" , " REC_direct_ptQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
208+ histos.add (" REC_direct_ptQA" , " REC_direct_ptQA" , kTH1F , {MCptAxis });
197209 histos.add (" REC_cluster_phiQA" , " REC_cluster_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
198210 histos.add (" REC_cluster_etaQA" , " REC_cluster_etaQA" , kTH1F , {{100 , -1 , 1 }});
199- histos.add (" REC_cluster_energyQA" , " REC_cluster_energyQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
211+ histos.add (" REC_cluster_energyQA" , " REC_cluster_energyQA" , kTH1F , {MCptAxis });
200212 histos.add (" REC_clusteriso_phiQA" , " REC_clusteriso_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
201213 histos.add (" REC_clusteriso_etaQA" , " REC_clusteriso_etaQA" , kTH1F , {{100 , -1 , 1 }});
202- histos.add (" REC_clusteriso_energyQA" , " REC_clusteriso_energyQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
214+ histos.add (" REC_clusteriso_energyQA" , " REC_clusteriso_energyQA" , kTH1F , {MCptAxis });
203215 histos.add (" REC_track_phiQA" , " REC_track_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
204216 histos.add (" REC_track_etaQA" , " REC_track_etaQA" , kTH1F , {{100 , -1 , 1 }});
205- histos.add (" REC_track_ptQA" , " REC_track_ptQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
217+ histos.add (" REC_track_ptQA" , " REC_track_ptQA" , kTH1F , {MCptAxis });
206218 histos.add (" REC_cluster_direct_phiQA" , " REC_cluster_direct_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
207219 histos.add (" REC_cluster_direct_etaQA" , " REC_cluster_direct_etaQA" , kTH1F , {{100 , -1 , 1 }});
208- histos.add (" REC_cluster_direct_energyQA" , " REC_cluster_direct_energyQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
220+ histos.add (" REC_cluster_direct_energyQA" , " REC_cluster_direct_energyQA" , kTH1F , {MCptAxis });
209221 histos.add (" REC_cluster_frag_phiQA" , " REC_cluster_frag_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
210222 histos.add (" REC_cluster_frag_etaQA" , " REC_cluster_frag_etaQA" , kTH1F , {{100 , -1 , 1 }});
211- histos.add (" REC_cluster_frag_energyQA" , " REC_cluster_frag_energyQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
223+ histos.add (" REC_cluster_frag_energyQA" , " REC_cluster_frag_energyQA" , kTH1F , {MCptAxis });
212224 histos.add (" REC_cluster_both_phiQA" , " REC_cluster_both_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
213225 histos.add (" REC_cluster_both_etaQA" , " REC_cluster_both_etaQA" , kTH1F , {{100 , -1 , 1 }});
214- histos.add (" REC_cluster_both_energyQA" , " REC_cluster_both_energyQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
226+ histos.add (" REC_cluster_both_energyQA" , " REC_cluster_both_energyQA" , kTH1F , {MCptAxis });
215227 }
216228 if (cfgGenHistograms) {
217229 histos.add (" GEN_prompt_phiQA" , " GEN_prompt_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
218230 histos.add (" GEN_prompt_etaQA" , " GEN_prompt_etaQA" , kTH1F , {{100 , -1 , 1 }});
219- histos.add (" GEN_prompt_ptQA" , " GEN_prompt_ptQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
231+ histos.add (" GEN_prompt_ptQA" , " GEN_prompt_ptQA" , kTH1F , {MCptAxis });
220232 histos.add (" GEN_decay_phiQA" , " GEN_decay_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
221233 histos.add (" GEN_decay_etaQA" , " GEN_decay_etaQA" , kTH1F , {{100 , -1 , 1 }});
222- histos.add (" GEN_decay_ptQA" , " GEN_decay_ptQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
234+ histos.add (" GEN_decay_ptQA" , " GEN_decay_ptQA" , kTH1F , {MCptAxis });
223235 histos.add (" GEN_frag_phiQA" , " GEN_frag_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
224236 histos.add (" GEN_frag_etaQA" , " GEN_frag_etaQA" , kTH1F , {{100 , -1 , 1 }});
225- histos.add (" GEN_frag_ptQA" , " GEN_frag_ptQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
237+ histos.add (" GEN_frag_ptQA" , " GEN_frag_ptQA" , kTH1F , {MCptAxis });
226238 histos.add (" GEN_direct_phiQA" , " GEN_direct_phiQA" , kTH1F , {{640 * 2 , 0 , 2 * TMath::Pi ()}});
227239 histos.add (" GEN_direct_etaQA" , " GEN_direct_etaQA" , kTH1F , {{100 , -1 , 1 }});
228- histos.add (" GEN_direct_ptQA" , " GEN_direct_ptQA" , kTH1F , {{ 82 , - 1.0 , 40.0 } });
240+ histos.add (" GEN_direct_ptQA" , " GEN_direct_ptQA" , kTH1F , {MCptAxis });
229241 histos.add (" GEN_nEvents" , " GEN_nEvents" , kTH1F , {{4 , 0.0 , 4.0 }});
230242 histos.add (" GEN_nEvents_simple" , " GEN_nEvents" , kTH1F , {{4 , 0.0 , 4.0 }});
231243 histos.add (" GEN_True_Trigger_Energy" , " GEN_True_Trigger_Energy" , kTH1F , {{82 , -1.0 , 40.0 }});
@@ -1513,6 +1525,15 @@ struct statPromptPhoton {
15131525 continue ;
15141526 if (std::fabs (mcParticle.getGenStatusCode ()) >= 81 || !mcParticle.isPhysicalPrimary ())
15151527 continue ;
1528+ if (cfgReqRecPS_GEN) {
1529+ if (std::fabs (mcParticle.eta ()) > cfgEMChighPSeta)
1530+ continue ;
1531+ bool insideCalPhi = false ;
1532+ if ((mcParticle.phi () > cfgEMClowPSphi && mcParticle.phi () < cfgEMChighPSphi) || (mcParticle.phi () > cfgDClowPSphi && mcParticle.phi () < cfgDChighPSphi))
1533+ insideCalPhi = true ;
1534+ if (!insideCalPhi)
1535+ continue ;
1536+ }
15161537
15171538 // Chase this final-state photon upward
15181539 int chaseindex = -1 ;
@@ -1629,6 +1650,15 @@ struct statPromptPhoton {
16291650 continue ;
16301651 if (std::fabs (clusterparticle.getGenStatusCode ()) >= 81 )
16311652 continue ;
1653+ if (cfgReqRecPS_REC) {
1654+ if (std::fabs (clusterparticle.eta ()) > cfgEMChighPSeta)
1655+ continue ;
1656+ bool insideCalPhi = false ;
1657+ if ((clusterparticle.phi () > cfgEMClowPSphi && clusterparticle.phi () < cfgEMChighPSphi) || (clusterparticle.phi () > cfgDClowPSphi && clusterparticle.phi () < cfgDChighPSphi))
1658+ insideCalPhi = true ;
1659+ if (!insideCalPhi)
1660+ continue ;
1661+ }
16321662
16331663 int chaseindex = -1 ;
16341664 for (auto & mom : clusterparticle.mothers_as <aod::JMcParticles>()) {
0 commit comments