@@ -95,7 +95,7 @@ struct JFlucEfficiencyTask {
9595 // (aod::track::eta <= cfgEtaMax);
9696 Filter trackSelectionFilter = (trackSelection.node() == 0 ) || // from tpcSkimsTableCreator
9797 ((trackSelection.node() == 1 ) && requireGlobalTrackInFilter()) ||
98- ((trackSelection.node() == 2 ) && requireGlobalTrackWoPtEtaInFilter ()) ||
98+ ((trackSelection.node() == 2 ) && requirePrimaryTracksInFilter ()) ||
9999 ((trackSelection.node() == 3 ) && requireGlobalTrackWoDCAInFilter()) ||
100100 ((trackSelection.node() == 4 ) && requireQualityTracksInFilter()) ||
101101 ((trackSelection.node() == 5 ) && requireTrackCutInFilter(TrackSelectionFlags::kInAcceptanceTracks ));
@@ -144,26 +144,15 @@ struct JFlucEfficiencyTask {
144144 o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
145145 registry.add (" hPtGenNeg" , " Generated p_{T} (negative);p_{T} (GeV/c);Centrality (%);Counts" ,
146146 o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
147- registry.add (" hPtGenParticle" , " Generated p_{T} (all);p_{T} (GeV/c);Centrality (%);Counts" ,
148- o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
149- registry.add (" hEtaGenParticle" , " Generated #eta (all);#eta;Centrality (%);Counts" ,
150- o2::framework::HistType::kTH2F , {AxisSpec (100 , -1 , 1 ), AxisSpec (axisMultiplicity)});
151- registry.add (" hPtGenParticlePos" , " Generated p_{T} (positive);p_{T} (GeV/c);Centrality (%);Counts" ,
152- o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
153- registry.add (" hPtGenParticleNeg" , " Generated p_{T} (negative);p_{T} (GeV/c);Centrality (%);Counts" ,
154- o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
155- }
156-
157- if (doprocessData || doprocessDerivedData) {
158- registry.add (" hPtRec" , " Reconstructed p_{T} (all);p_{T} (GeV/c);Centrality (%);Counts" ,
159- o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
160- registry.add (" hEtaRec" , " Reconstructed #eta (all);#eta;Centrality (%);Counts" ,
161- o2::framework::HistType::kTH2F , {AxisSpec (100 , -1 , 1 ), AxisSpec (axisMultiplicity)});
162- registry.add (" hPtRecPos" , " Reconstructed p_{T} (positive);p_{T} (GeV/c);Centrality (%);Counts" ,
163- o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
164- registry.add (" hPtRecNeg" , " Reconstructed p_{T} (negative);p_{T} (GeV/c);Centrality (%);Counts" ,
165- o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
166147 }
148+ registry.add (" hPtRec" , " Reconstructed p_{T} (all);p_{T} (GeV/c);Centrality (%);Counts" ,
149+ o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
150+ registry.add (" hEtaRec" , " Reconstructed #eta (all);#eta;Centrality (%);Counts" ,
151+ o2::framework::HistType::kTH2F , {AxisSpec (100 , -1 , 1 ), AxisSpec (axisMultiplicity)});
152+ registry.add (" hPtRecPos" , " Reconstructed p_{T} (positive);p_{T} (GeV/c);Centrality (%);Counts" ,
153+ o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
154+ registry.add (" hPtRecNeg" , " Reconstructed p_{T} (negative);p_{T} (GeV/c);Centrality (%);Counts" ,
155+ o2::framework::HistType::kTH2F , {AxisSpec (axisPt), AxisSpec (axisMultiplicity)});
167156
168157 if (doprocessEfficiency) {
169158 registry.add (" hPtGenData" , " Generated p_{T} from data events (all);p_{T} (GeV/c);Centrality (%);Counts" ,
@@ -266,7 +255,7 @@ struct JFlucEfficiencyTask {
266255 Preslice<TrackCandidates> perCollision = aod::track::collisionId;
267256 void processMC (aod::McCollisions::iterator const & mcCollision,
268257 soa::SmallGroups<MCCollisionCandidates> const & collisions,
269- MCTrackCandidates const & mcTracks,
258+ soa::Filtered< MCTrackCandidates> const & mcTracks,
270259 aod::McParticles const & mcParticles)
271260 {
272261 registry.fill (HIST (" hEventCounterMC" ), 0 );
@@ -300,16 +289,18 @@ struct JFlucEfficiencyTask {
300289 if (particle.pt () < cfgPtMin || particle.pt () > cfgPtMax || particle.eta () < cfgEtaMin || particle.eta () > cfgEtaMax) {
301290 continue ;
302291 }
303- registry.fill (HIST (" hPtGenParticle " ), particle.pt (), centrality);
304- registry.fill (HIST (" hEtaGenParticle " ), particle.eta (), centrality);
292+ registry.fill (HIST (" hPtGen " ), particle.pt (), centrality);
293+ registry.fill (HIST (" hEtaGen " ), particle.eta (), centrality);
305294 if (charge > 0 ) { // Positive particles
306- registry.fill (HIST (" hPtGenParticlePos " ), particle.pt (), centrality);
295+ registry.fill (HIST (" hPtGenPos " ), particle.pt (), centrality);
307296 } else if (charge < 0 ) { // Negative particles
308- registry.fill (HIST (" hPtGenParticleNeg " ), particle.pt (), centrality);
297+ registry.fill (HIST (" hPtGenNeg " ), particle.pt (), centrality);
309298 }
310299 }
311300 // Reconstruct tracks from MC particles
312301 for (const auto & collision : collisions) {
302+ registry.fill (HIST (" hZVertexReco" ), collision.posZ (), centrality);
303+ registry.fill (HIST (" hZVertexCorrelation" ), mcCollision.posZ (), collision.posZ ());
313304 auto tracks = mcTracks.sliceBy (perCollision, collision.globalIndex ());
314305 for (const auto & track : tracks) {
315306 if (!track.has_mcParticle ()) {
@@ -323,18 +314,18 @@ struct JFlucEfficiencyTask {
323314 if (track.pt () < cfgPtMin || track.pt () > cfgPtMax || track.eta () < cfgEtaMin || track.eta () > cfgEtaMax) {
324315 continue ;
325316 }
326- registry.fill (HIST (" hPtGen " ), track.pt (), centrality);
327- registry.fill (HIST (" hEtaGen " ), track.eta (), centrality);
317+ registry.fill (HIST (" hPtRec " ), track.pt (), centrality);
318+ registry.fill (HIST (" hEtaRec " ), track.eta (), centrality);
328319 if (track.sign () > 0 ) { // Positive tracks
329- registry.fill (HIST (" hPtGenPos " ), track.pt (), centrality);
320+ registry.fill (HIST (" hPtRecPos " ), track.pt (), centrality);
330321 } else if (track.sign () < 0 ) { // Negative tracks
331- registry.fill (HIST (" hPtGenNeg " ), track.pt (), centrality);
322+ registry.fill (HIST (" hPtRecNeg " ), track.pt (), centrality);
332323 }
333324 }
334325 }
335326 }
336327
337- void processData (CollisionCandidates::iterator const & collision, TrackCandidates const & tracks)
328+ void processData (CollisionCandidates::iterator const & collision, soa::Filtered< TrackCandidates> const & tracks)
338329 {
339330 if (!colCuts.isSelected (collision)) // Default event selection
340331 return ;
@@ -364,7 +355,7 @@ struct JFlucEfficiencyTask {
364355 void processEfficiency (soa::Filtered<aod::CFMcCollisions>::iterator const & mcCollision,
365356 aod::CFMcParticles const & mcParticles,
366357 soa::SmallGroups<aod::CFCollisionsWithLabel> const & collisions,
367- aod::CFTracksWithLabel const & tracks)
358+ soa::Filtered< aod::CFTracksWithLabel> const & tracks)
368359 {
369360 try {
370361 // Count MC events and fill MC z-vertex with centrality
0 commit comments