Skip to content

Commit a012c2b

Browse files
cnkosteralibuild
andauthored
[PWGCF] Add QA plots and clean up task (#11784)
Co-authored-by: ALICE Action Bot <alibuild@cern.ch>
1 parent 5d40191 commit a012c2b

File tree

2 files changed

+56
-16
lines changed

2 files changed

+56
-16
lines changed

PWGCF/Flow/TableProducer/zdcQVectors.cxx

Lines changed: 56 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@ struct ZdcQVectors {
144144
using BCsRun3 = soa::Join<aod::BCs, aod::Timestamps, aod::BcSels, aod::Run3MatchedToBCSparse>;
145145

146146
enum SelectionCriteria {
147+
evSel_FilteredEvent,
147148
evSel_Zvtx,
148149
evSel_sel8,
149150
evSel_occupancy,
@@ -228,8 +229,8 @@ struct ZdcQVectors {
228229
} // end of capCOORDS
229230
} // end of sides
230231

231-
registry.add<TH1>("QA/centrality_before", "centrality_before", kTH1D, {{200, 0, 100}});
232-
registry.add<TH1>("QA/centrality_after", "centrality_after", kTH1D, {{200, 0, 100}});
232+
registry.add<TH1>("QA/centrality_before", "centrality_before", kTH1D, {{100, 0, 100}});
233+
registry.add<TH1>("QA/centrality_after", "centrality_after", kTH1D, {{100, 0, 100}});
233234

234235
registry.add<TProfile>("QA/ZNA_Energy", "ZNA_Energy", kTProfile, {{8, 0, 8}});
235236
registry.add<TProfile>("QA/ZNC_Energy", "ZNC_Energy", kTProfile, {{8, 0, 8}});
@@ -251,12 +252,29 @@ struct ZdcQVectors {
251252
registry.add<TProfile>("QA/before/ZNC_Qx", "ZNC_Qx", kTProfile, {{1, 0, 1.}});
252253
registry.add<TProfile>("QA/before/ZNC_Qy", "ZNC_Qy", kTProfile, {{1, 0, 1.}});
253254

255+
registry.add<TH2>("QA/before/ZNA_Qx_vs_Centrality", "ZNA_Qx_vs_Centrality", kTH2D, {{100, 0, 100}, {200, -2, 2}});
256+
registry.add<TH2>("QA/before/ZNA_Qy_vs_Centrality", "ZNA_Qy_vs_Centrality", kTH2D, {{100, 0, 100}, {200, -2, 2}});
257+
registry.add<TH2>("QA/before/ZNC_Qx_vs_Centrality", "ZNC_Qx_vs_Centrality", kTH2D, {{100, 0, 100}, {200, -2, 2}});
258+
registry.add<TH2>("QA/before/ZNC_Qy_vs_Centrality", "ZNC_Qy_vs_Centrality", kTH2D, {{100, 0, 100}, {200, -2, 2}});
259+
260+
registry.add<TH2>("QA/before/ZNA_pmC_vs_Centrality", "ZNA_pmC_vs_Centrality", kTH2D, {{100, 0, 100}, {300, 0, 300}});
261+
registry.add<TH2>("QA/before/ZNA_pm1_vs_Centrality", "ZNA_pm1_vs_Centrality", kTH2D, {{100, 0, 100}, {150, 0, 150}});
262+
registry.add<TH2>("QA/before/ZNA_pm2_vs_Centrality", "ZNA_pm2_vs_Centrality", kTH2D, {{100, 0, 100}, {150, 0, 150}});
263+
registry.add<TH2>("QA/before/ZNA_pm3_vs_Centrality", "ZNA_pm3_vs_Centrality", kTH2D, {{100, 0, 100}, {150, 0, 150}});
264+
registry.add<TH2>("QA/before/ZNA_pm4_vs_Centrality", "ZNA_pm4_vs_Centrality", kTH2D, {{100, 0, 100}, {150, 0, 150}});
265+
266+
registry.add<TH2>("QA/before/ZNC_pmC_vs_Centrality", "ZNC_pmC_vs_Centrality", kTH2D, {{100, 0, 100}, {300, 0, 300}});
267+
registry.add<TH2>("QA/before/ZNC_pm1_vs_Centrality", "ZNC_pm1_vs_Centrality", kTH2D, {{100, 0, 100}, {150, 0, 150}});
268+
registry.add<TH2>("QA/before/ZNC_pm2_vs_Centrality", "ZNC_pm2_vs_Centrality", kTH2D, {{100, 0, 100}, {150, 0, 150}});
269+
registry.add<TH2>("QA/before/ZNC_pm3_vs_Centrality", "ZNC_pm3_vs_Centrality", kTH2D, {{100, 0, 100}, {150, 0, 150}});
270+
registry.add<TH2>("QA/before/ZNC_pm4_vs_Centrality", "ZNC_pm4_vs_Centrality", kTH2D, {{100, 0, 100}, {150, 0, 150}});
271+
272+
registry.addClone("QA/before/", "QA/after/");
273+
254274
registry.add<TProfile>("QA/before/ZNA_Qx_noEq", "ZNA_Qx_noEq", kTProfile, {{1, 0, 1.}});
255275
registry.add<TProfile>("QA/before/ZNA_Qy_noEq", "ZNA_Qy_noEq", kTProfile, {{1, 0, 1.}});
256276
registry.add<TProfile>("QA/before/ZNC_Qx_noEq", "ZNC_Qx_noEq", kTProfile, {{1, 0, 1.}});
257277
registry.add<TProfile>("QA/before/ZNC_Qy_noEq", "ZNC_Qy_noEq", kTProfile, {{1, 0, 1.}});
258-
259-
registry.addClone("QA/before/", "QA/after/");
260278
}
261279

262280
// Tower mean energies vs. centrality used for tower gain equalisation
@@ -273,6 +291,7 @@ struct ZdcQVectors {
273291
registry.add<TProfile>("vmean/hvertex_vz", "hvertex_vz", kTProfile, {{1, 0., 1.}});
274292

275293
registry.add("hEventCount", "Number of Event; Cut; #Events Passed Cut", {HistType::kTH1D, {{nEventSelections, 0, nEventSelections}}});
294+
registry.get<TH1>(HIST("hEventCount"))->GetXaxis()->SetBinLabel(evSel_FilteredEvent + 1, "Filtered events");
276295
registry.get<TH1>(HIST("hEventCount"))->GetXaxis()->SetBinLabel(evSel_Zvtx + 1, "Z vertex cut event");
277296
registry.get<TH1>(HIST("hEventCount"))->GetXaxis()->SetBinLabel(evSel_sel8 + 1, "Sel8");
278297
registry.get<TH1>(HIST("hEventCount"))->GetXaxis()->SetBinLabel(evSel_occupancy + 1, "kOccupancy");
@@ -290,7 +309,7 @@ struct ZdcQVectors {
290309
{
291310
if (std::fabs(collision.posZ()) > cfgVtxZ)
292311
return 0;
293-
registry.fill(HIST("hEventCount"), evSel_sel8);
312+
registry.fill(HIST("hEventCount"), evSel_Zvtx);
294313

295314
if (!collision.sel8())
296315
return 0;
@@ -403,6 +422,11 @@ struct ZdcQVectors {
403422
registry.fill(HIST("QA/") + HIST(Time[ft]) + HIST("/hQYA_QXC_vs_vz"), v[2], qya * qxc);
404423
registry.fill(HIST("QA/") + HIST(Time[ft]) + HIST("/hQXA_QYC_vs_vz"), v[2], qxa * qyc);
405424

425+
registry.fill(HIST("QA/") + HIST(Time[ft]) + HIST("/ZNA_Qx_vs_Centrality"), centrality, qxa);
426+
registry.fill(HIST("QA/") + HIST(Time[ft]) + HIST("/ZNA_Qy_vs_Centrality"), centrality, qya);
427+
registry.fill(HIST("QA/") + HIST(Time[ft]) + HIST("/ZNC_Qx_vs_Centrality"), centrality, qxc);
428+
registry.fill(HIST("QA/") + HIST(Time[ft]) + HIST("/ZNC_Qy_vs_Centrality"), centrality, qyc);
429+
406430
// add psi!!
407431
double psiA = 1.0 * std::atan2(qxc, qxa);
408432
registry.fill(HIST("QA/") + HIST(Time[ft]) + HIST("/hSPplaneA"), psiA, centrality, 1);
@@ -536,6 +560,8 @@ struct ZdcQVectors {
536560
if (cfgFillCommonRegistry)
537561
registry.fill(HIST("QA/centrality_before"), cent);
538562

563+
registry.fill(HIST("hEventCount"), evSel_FilteredEvent);
564+
539565
if (!eventSelected(collision, cent)) {
540566
// event not selected
541567
isSelected = false;
@@ -678,13 +704,38 @@ struct ZdcQVectors {
678704
registry.get<TProfile>(HIST("QA/before/ZNC_pm3"))->Fill(Form("%d", runnumber), eZN[6]);
679705
registry.get<TProfile>(HIST("QA/before/ZNC_pm4"))->Fill(Form("%d", runnumber), eZN[7]);
680706

707+
registry.get<TProfile>(HIST("QA/after/ZNA_pm1"))->Fill(Form("%d", runnumber), e[0]);
681708
registry.get<TProfile>(HIST("QA/after/ZNA_pm2"))->Fill(Form("%d", runnumber), e[1]);
682709
registry.get<TProfile>(HIST("QA/after/ZNA_pm3"))->Fill(Form("%d", runnumber), e[2]);
683710
registry.get<TProfile>(HIST("QA/after/ZNA_pm4"))->Fill(Form("%d", runnumber), e[3]);
684711
registry.get<TProfile>(HIST("QA/after/ZNC_pm1"))->Fill(Form("%d", runnumber), e[4]);
685712
registry.get<TProfile>(HIST("QA/after/ZNC_pm2"))->Fill(Form("%d", runnumber), e[5]);
686713
registry.get<TProfile>(HIST("QA/after/ZNC_pm3"))->Fill(Form("%d", runnumber), e[6]);
687714
registry.get<TProfile>(HIST("QA/after/ZNC_pm4"))->Fill(Form("%d", runnumber), e[7]);
715+
716+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNA_pmC_vs_Centrality"), centrality, zdcCol.energyCommonZNA());
717+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNA_pm1_vs_Centrality"), centrality, eZN[0]);
718+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNA_pm2_vs_Centrality"), centrality, eZN[1]);
719+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNA_pm3_vs_Centrality"), centrality, eZN[2]);
720+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNA_pm4_vs_Centrality"), centrality, eZN[3]);
721+
722+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNC_pmC_vs_Centrality"), centrality, zdcCol.energyCommonZNC());
723+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNC_pm1_vs_Centrality"), centrality, eZN[4]);
724+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNC_pm2_vs_Centrality"), centrality, eZN[5]);
725+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNC_pm3_vs_Centrality"), centrality, eZN[6]);
726+
registry.fill(HIST("QA/") + HIST("before") + HIST("/ZNC_pm4_vs_Centrality"), centrality, eZN[7]);
727+
728+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNA_pmC_vs_Centrality"), centrality, zdcCol.energyCommonZNA());
729+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNA_pm1_vs_Centrality"), centrality, e[0]);
730+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNA_pm2_vs_Centrality"), centrality, e[1]);
731+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNA_pm3_vs_Centrality"), centrality, e[2]);
732+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNA_pm4_vs_Centrality"), centrality, e[3]);
733+
734+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNC_pmC_vs_Centrality"), centrality, zdcCol.energyCommonZNC());
735+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNC_pm1_vs_Centrality"), centrality, e[4]);
736+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNC_pm2_vs_Centrality"), centrality, e[5]);
737+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNC_pm3_vs_Centrality"), centrality, e[6]);
738+
registry.fill(HIST("QA/") + HIST("after") + HIST("/ZNC_pm4_vs_Centrality"), centrality, e[7]);
688739
}
689740

690741
// Now calculate Q-vector

PWGCF/Flow/Tasks/flowSP.cxx

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -311,9 +311,7 @@ struct FlowSP {
311311
registry.add("QA/after/hCentFV0A", "; Cent FV0A (%); ", {HistType::kTH1D, {axisCent}});
312312
registry.add("QA/after/hCentNGlobal", "; Cent NGlobal (%); ", {HistType::kTH1D, {axisCent}});
313313
registry.add("QA/after/globalTracks_centT0C", "", {HistType::kTH2D, {axisCent, axisNch}});
314-
// registry.add("QA/after/globalTracks_centNGlobal", "", {HistType::kTH2D, {axisCent, axisNch}});
315314
registry.add("QA/after/PVTracks_centT0C", "", {HistType::kTH2D, {axisCent, axisMultpv}});
316-
// registry.add("QA/after/PVTracks_centNGlobal", "", {HistType::kTH2D, {axisCent, axisMultpv}});
317315
registry.add("QA/after/globalTracks_PVTracks", "", {HistType::kTH2D, {axisMultpv, axisNch}});
318316
registry.add("QA/after/globalTracks_multT0A", "", {HistType::kTH2D, {axisT0a, axisNch}});
319317
registry.add("QA/after/globalTracks_multV0A", "", {HistType::kTH2D, {axisV0a, axisNch}});
@@ -607,12 +605,10 @@ struct FlowSP {
607605
}
608606

609607
if (nIdentified == 0) {
610-
// LOGF(warning, "No PID match found for |nSigma| < %.2f", cfgTrackSelsPIDNsigma);
611608
return kUnidentified; // No PID match found
612609
} else if (nIdentified == 1) {
613610
return valPID;
614611
} else {
615-
// LOGF(warning, "Track identified as %i particles for |nSigma| < %.2f", nIdentified, cfgTrackSelsPIDNsigma);
616612
return kUnidentified; // Multiple PID matches found
617613
}
618614

@@ -622,10 +618,8 @@ struct FlowSP {
622618
int getMagneticField(uint64_t timestamp)
623619
{
624620
// TODO done only once (and not per run). Will be replaced by CCDBConfigurable
625-
// static o2::parameters::GRPObject* grpo = nullptr;
626621
static o2::parameters::GRPMagField* grpo = nullptr;
627622
if (grpo == nullptr) {
628-
// grpo = ccdb->getForTimeStamp<o2::parameters::GRPObject>("GLO/GRP/GRP", timestamp);
629623
grpo = ccdb->getForTimeStamp<o2::parameters::GRPMagField>("GLO/Config/GRPMagField", timestamp);
630624
if (grpo == nullptr) {
631625
LOGF(fatal, "GRP object not found for timestamp %llu", timestamp);
@@ -816,8 +810,6 @@ struct FlowSP {
816810

817811
registry.fill(HIST("hTrackCount"), trackSel_DCAz);
818812

819-
// registry.fill(HIST("hTrackCount"), trackSel_GlobalTracks);
820-
821813
if (track.tpcNClsFound() < cfgTrackSelsNcls)
822814
return false;
823815
registry.fill(HIST("hTrackCount"), trackSel_NCls);
@@ -1363,7 +1355,6 @@ struct FlowSP {
13631355

13641356
fillEventQA<kAfter>(collision, tracks);
13651357

1366-
// LOGF(info, "Size of tracks: %i", tracks.size());
13671358
registry.fill(HIST("trackMCReco/hTrackSize_unFiltered"), tracks.size());
13681359
registry.fill(HIST("trackMCReco/hTrackSize_Filtered"), filteredTracks.size());
13691360

@@ -1388,10 +1379,8 @@ struct FlowSP {
13881379
}
13891380
PROCESS_SWITCH(FlowSP, processMCReco, "Process analysis for MC reconstructed events", false);
13901381

1391-
// Filter mcCollFilter = nabs(aod::mccollision::posZ) < cfgEvSelsVtxZ;
13921382
void processMCGen(aod::McCollisions const& mcCollisions, CCs const& collisions, TCs const& tracks, FilteredTCs const& filteredTracks, MCs const& McParts)
13931383
{
1394-
// LOGF(info, "Size of mccollisions: %i", mcCollisions.size());
13951384

13961385
for (const auto& mcCollision : mcCollisions) {
13971386
float centrality = -1;

0 commit comments

Comments
 (0)