Skip to content

Commit 0801b1a

Browse files
authored
Merge branch 'AliceO2Group:master' into Update
2 parents 5692048 + ee1ae43 commit 0801b1a

File tree

7 files changed

+69
-14
lines changed

7 files changed

+69
-14
lines changed

DPG/Tasks/AOTEvent/eventSelectionQa.cxx

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -356,6 +356,8 @@ struct EventSelectionQaTask {
356356
histos.add("occupancyQA/hITSTracks_ev1_vs_ev2_2coll_in_ROF", ";nITStracks event #1;nITStracks event #2", kTH2D, {{200, 0., 6000}, {200, 0., 6000}});
357357
histos.add("occupancyQA/hITSTracks_ev1_vs_ev2_2coll_in_ROF_UPC", ";nITStracks event #1;nITStracks event #2", kTH2D, {{41, -0.5, 40.5}, {41, -0.5, 40.5}});
358358
histos.add("occupancyQA/hITSTracks_ev1_vs_ev2_2coll_in_ROF_nonUPC", ";nITStracks event #1;nITStracks event #2", kTH2D, {{200, 0., 6000}, {200, 0., 6000}});
359+
360+
histos.add("occupancyQA/dEdx_vs_centr_vs_occup_narrow_p_win", "dE/dx", kTH3F, {{20, 0, 4000, "n PV tracks"}, {60, 0, 15000, "occupancy"}, {800, 0.0, 800.0, "dE/dx (a. u.)"}});
359361
}
360362
}
361363

@@ -1152,6 +1154,19 @@ struct EventSelectionQaTask {
11521154
histos.fill(HIST("occupancyQA/hOccupancyByFT0CvsByTracks"), occupancyByTracks, occupancyByFT0C);
11531155
histos.fill(HIST("occupancyQA/hNumTracksPV_vs_V0A_vs_occupancy"), multV0A, nPV, occupancyByTracks);
11541156
histos.fill(HIST("occupancyQA/hNumTracksPVTPC_vs_V0A_vs_occupancy"), multV0A, nContributorsAfterEtaTPCCuts, occupancyByTracks);
1157+
1158+
// dE/dx QA for a narrow pT bin
1159+
for (const auto& track : tracksGrouped) {
1160+
if (!track.isPVContributor())
1161+
continue;
1162+
if (std::fabs(track.eta()) < 0.8 && track.pt() > 0.2 && track.itsNCls() >= 5) {
1163+
float signedP = track.sign() * track.tpcInnerParam();
1164+
if (std::fabs(signedP) > 0.38 && std::fabs(signedP) < 0.4 && track.tpcNClsFound() > 70 && track.tpcNClsCrossedRows() > 80 && track.itsChi2NCl() < 36 && track.tpcChi2NCl() < 4) {
1165+
float dEdx = track.tpcSignal();
1166+
histos.fill(HIST("occupancyQA/dEdx_vs_centr_vs_occup_narrow_p_win"), nPV, occupancyByTracks, dEdx);
1167+
}
1168+
}
1169+
}
11551170
}
11561171
}
11571172

PWGDQ/Core/MCProng.cxx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ std::map<TString, int> MCProng::fgSourceNames = {
2222
{"kProducedInTransport", MCProng::kProducedInTransport},
2323
{"kProducedByGenerator", MCProng::kProducedByGenerator},
2424
{"kFromBackgroundEvent", MCProng::kFromBackgroundEvent},
25-
{"kHEPMCFinalState", MCProng::kHEPMCFinalState}};
25+
{"kHEPMCFinalState", MCProng::kHEPMCFinalState},
26+
{"kIsPowhegDYMuon", MCProng::kIsPowhegDYMuon}};
2627

2728
//________________________________________________________________________________________________________________
2829
MCProng::MCProng() : fNGenerations(0),

PWGDQ/Core/MCProng.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ class MCProng
7373
kProducedByGenerator, // Produced by generator (if not, then produced by GEANT)
7474
kFromBackgroundEvent, // Produced in the underlying event
7575
kHEPMCFinalState, // HEPMC code 11
76+
kIsPowhegDYMuon, // POWHEG muons based on Pythia Status Code (=23) -> Drell-Yan signal
7677
kNSources
7778
};
7879

PWGDQ/Core/MCSignal.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -253,6 +253,12 @@ bool MCSignal::CheckProng(int i, bool checkSources, const T& track)
253253
sourcesDecision |= (static_cast<uint64_t>(1) << MCProng::kHEPMCFinalState);
254254
}
255255
}
256+
// Check kIsPowhegDYMuon
257+
if (fProngs[i].fSourceBits[j] & (static_cast<uint64_t>(1) << MCProng::kIsPowhegDYMuon)) {
258+
if ((fProngs[i].fExcludeSource[j] & (static_cast<uint64_t>(1) << MCProng::kIsPowhegDYMuon)) != (currentMCParticle.getGenStatusCode() == 23)) {
259+
sourcesDecision |= (static_cast<uint64_t>(1) << MCProng::kIsPowhegDYMuon);
260+
}
261+
}
256262
} // end if(hasSources)
257263
// no source bit is fulfilled
258264
if (hasSources && !sourcesDecision) {

PWGDQ/Core/MCSignalLibrary.cxx

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,9 +125,16 @@ MCSignal* o2::aod::dqmcsignals::GetMCSignal(const char* name)
125125
signal = new MCSignal(name, "Inclusive jpsi", {prong}, {-1});
126126
return signal;
127127
}
128-
if (!nameStr.compare("Helium3")) {
128+
if (!nameStr.compare("Helium3Primary")) {
129129
MCProng prong(1, {1000020030}, {true}, {false}, {0}, {0}, {false});
130-
signal = new MCSignal(name, "Helium3", {prong}, {-1});
130+
prong.SetSourceBit(0, MCProng::kPhysicalPrimary);
131+
signal = new MCSignal(name, "Helium3Primary", {prong}, {-1});
132+
return signal;
133+
}
134+
if (!nameStr.compare("Helium3FromTransport")) {
135+
MCProng prong(1, {1000020030}, {true}, {false}, {0}, {0}, {false});
136+
prong.SetSourceBit(0, MCProng::kProducedInTransport);
137+
signal = new MCSignal(name, "Helium3FromTransport", {prong}, {-1});
131138
return signal;
132139
}
133140
if (!nameStr.compare("nonPromptJpsi")) {
@@ -348,6 +355,12 @@ MCSignal* o2::aod::dqmcsignals::GetMCSignal(const char* name)
348355
signal = new MCSignal(name, "electron from a photon conversion", {prong}, {-1});
349356
return signal;
350357
}
358+
if (!nameStr.compare("PowhegDYMuon1")) {
359+
MCProng prong(1, {13}, {true}, {false}, {0}, {0}, {false}); // selecting muons
360+
prong.SetSourceBit(0, MCProng::kIsPowhegDYMuon); // set source to be Muon from POWHEG
361+
signal = new MCSignal(name, "POWHEG Muon singles", {prong}, {-1}); // define a signal with 1-prong
362+
return signal;
363+
}
351364

352365
// 2-prong signals
353366
if (!nameStr.compare("dielectron")) {
@@ -381,6 +394,12 @@ MCSignal* o2::aod::dqmcsignals::GetMCSignal(const char* name)
381394
signal = new MCSignal(name, "dielectron from a photon conversion from a pi0", {prong, prong}, {1, 1});
382395
return signal;
383396
}
397+
if (!nameStr.compare("PowhegDYMuon2")) {
398+
MCProng prong(1, {13}, {true}, {false}, {0}, {0}, {false}); // selecting muons
399+
prong.SetSourceBit(0, MCProng::kIsPowhegDYMuon); // set source to be Muon from POWHEG
400+
signal = new MCSignal(name, "POWHEG Muon pair", {prong, prong}, {-1, -1}); // define a signal with 2-prong
401+
return signal;
402+
}
384403

385404
// LMEE single signals
386405
// electron signals with mother X: e from mother X

PWGDQ/TableProducer/tableMakerMC.cxx

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -762,7 +762,6 @@ struct TableMakerMC {
762762
for (auto& cut : fMuonCuts) {
763763
if (cut.IsSelected(VarManager::fgValues)) {
764764
trackTempFilterMap |= (uint8_t(1) << i);
765-
(reinterpret_cast<TH1I*>(fStatsList->At(2)))->Fill(static_cast<float>(i));
766765
}
767766
i++;
768767
}
@@ -811,7 +810,6 @@ struct TableMakerMC {
811810
for (auto& cut : fMuonCuts) {
812811
if (cut.IsSelected(VarManager::fgValues)) {
813812
trackTempFilterMap |= (uint8_t(1) << i);
814-
fHistMan->FillHistClass(Form("Muons_%s", cut.GetName()), VarManager::fgValues);
815813
if (fIsAmbiguous && isAmbiguous == 1) {
816814
fHistMan->FillHistClass(Form("Ambiguous_Muons_%s", cut.GetName()), VarManager::fgValues);
817815
}
@@ -1322,10 +1320,6 @@ struct TableMakerMC {
13221320
for (auto& cut : fMuonCuts) {
13231321
if (cut.IsSelected(VarManager::fgValues)) {
13241322
trackTempFilterMap |= (uint8_t(1) << i);
1325-
if (fConfigQA) {
1326-
fHistMan->FillHistClass(Form("Muons_%s", cut.GetName()), VarManager::fgValues);
1327-
}
1328-
(reinterpret_cast<TH1I*>(fStatsList->At(2)))->Fill(static_cast<float>(i));
13291323
}
13301324
i++;
13311325
}

PWGMM/Lumi/Tasks/lumiStability.cxx

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ struct LumiStabilityTask {
8787
const AxisSpec axisTimeFDD{1000, -20, 100};
8888
const AxisSpec axisCountsTime{2, -0.5, 1.5};
8989
const AxisSpec axisOrbits{static_cast<int>(nOrbits / nOrbitsPerTF), 0., static_cast<double>(nOrbits), ""};
90-
const AxisSpec axisTimeRate{1440, 0., 86400, ""}; // t in seconds. Histo for 24 hrs. Each bin contain 1 min.
90+
const AxisSpec axisTimeRate{int(double(43200) / (nOrbitsPerTF * 89e-6)), 0., 43200, ""}; // t in seconds. Histo for 12 hrs. Each bin contain one time frame (128/32 orbits for Run2/3).
9191

9292
histos.add("hBcA", "BC pattern A; BC ; It is present", kTH1F, {axisTrigger});
9393
histos.add("hBcC", "BC pattern C; BC ; It is present", kTH1F, {axisTrigger});
@@ -162,6 +162,7 @@ struct LumiStabilityTask {
162162
histos.add("FDD/hValidTimevsBC", "Valid Time vs BC id;BC in FT0;valid time counts", kTH1F, {axisTrigger});
163163
histos.add("FDD/hInvTimevsBC", "Invalid Time vs BC id;BC in FT0;invalid time counts", kTH1F, {axisTrigger});
164164
histos.add("FDD/hTimeForRate", "Counts by time in FDD;t (in seconds) in FDD; counts", kTH1F, {axisTimeRate});
165+
histos.add("FDD/hTimeForRateLeadingBC", "Counts by time in FDD;t (in seconds) in FDD; counts", kTH1F, {axisTimeRate});
165166

166167
histos.add("FT0/hCounts", "0 FT0Count - 1 FT0VertexCount - 2 FT0PPVertexCount - 3 FT0PPBothSidesCount; Number; counts", kTH1F, {axisCounts});
167168
histos.add("FT0/bcVertexTrigger", "vertex trigger per BC (FT0);BC in FT0; counts", kTH1F, {axisTrigger});
@@ -191,7 +192,8 @@ struct LumiStabilityTask {
191192
histos.add("FT0/hInvTimeCvsBC", "Invalid Time C vs BC id;BC in FT0;invalid time counts", kTH1F, {axisTrigger});
192193
histos.add("FT0/hValidTimevsBC", "Valid Time vs BC id;BC in FT0;valid time counts", kTH1F, {axisTrigger});
193194
histos.add("FT0/hInvTimevsBC", "Invalid Time vs BC id;BC in FT0;invalid time counts", kTH1F, {axisTrigger});
194-
histos.add("FT0/hTimeForRate", "Counts by time in FT0;t (in seconds) in FDD; counts", kTH1F, {axisTimeRate});
195+
histos.add("FT0/hTimeForRate", "Counts by time in FT0;t (in seconds) in FT0; counts", kTH1F, {axisTimeRate});
196+
histos.add("FT0/hTimeForRateLeadingBC", "Counts by time in FT0;t (in seconds) in FT0; counts", kTH1F, {axisTimeRate});
195197

196198
histos.add("FV0/hCounts", "0 CountCentralFV0 - 1 CountPFPCentralFV0 - 2 CountPFPOutInFV0 - 3 CountPPCentralFV0 - 4 CountPPOutInFV0; Number; counts", kTH1F, {axisV0Counts});
197199
histos.add("FV0/bcOutTrigger", "Out trigger per BC (FV0);BC in V0; counts", kTH1F, {axisTrigger});
@@ -363,7 +365,22 @@ struct LumiStabilityTask {
363365
histos.fill(HIST("FDD/bcVertexTrigger"), localBC);
364366
histos.fill(HIST("FDD/hCounts"), 1);
365367
histos.fill(HIST("hOrbitFDDVertex"), orbit - minOrbit);
366-
histos.fill(HIST("FDD/hTimeForRate"), (bc.timestamp() - tsSOR) * 1.e-3); // Converting ms into seconds
368+
369+
if (bcPatternB[localBC]) {
370+
histos.fill(HIST("FDD/hTimeForRate"), (bc.timestamp() - tsSOR) * 1.e-3); // Converting ms into seconds
371+
bool isLeadBC = true;
372+
for (int jbit = localBC - minEmpty; jbit < localBC; jbit++) {
373+
int kbit = jbit;
374+
if (kbit < 0)
375+
kbit += nbin;
376+
if (bcPatternB[kbit]) {
377+
isLeadBC = false;
378+
break;
379+
}
380+
}
381+
if (isLeadBC)
382+
histos.fill(HIST("FDD/hTimeForRateLeadingBC"), (bc.timestamp() - tsSOR) * 1.e-3);
383+
}
367384

368385
int deltaIndex = 0; // backward move counts
369386
int deltaBC = 0; // current difference wrt globalBC
@@ -610,7 +627,6 @@ struct LumiStabilityTask {
610627
if (vertex) {
611628
histos.fill(HIST("FT0/bcVertexTrigger"), localBC);
612629
histos.fill(HIST("hOrbitFT0vertex"), orbit - minOrbit);
613-
histos.fill(HIST("FT0/hTimeForRate"), (bc.timestamp() - tsSOR) * 1.e-3); // Converting ms into seconds
614630

615631
if (bcPatternA[localBC]) {
616632
histos.fill(HIST("FT0/timeACbcA"), ft0.timeA(), ft0.timeC());
@@ -623,6 +639,7 @@ struct LumiStabilityTask {
623639
if (bcPatternB[localBC]) {
624640
histos.fill(HIST("FT0/timeACbcB"), ft0.timeA(), ft0.timeC());
625641
histos.fill(HIST("FT0/hBcB"), localBC);
642+
histos.fill(HIST("FT0/hTimeForRate"), (bc.timestamp() - tsSOR) * 1.e-3); // Converting ms into seconds
626643
bool isLeadBC = true;
627644
for (int jbit = localBC - minEmpty; jbit < localBC; jbit++) {
628645
int kbit = jbit;
@@ -633,8 +650,10 @@ struct LumiStabilityTask {
633650
break;
634651
}
635652
}
636-
if (isLeadBC)
653+
if (isLeadBC) {
654+
histos.fill(HIST("FT0/hTimeForRateLeadingBC"), (bc.timestamp() - tsSOR) * 1.e-3); // Converting ms into seconds
637655
histos.fill(HIST("FT0/hBcBL"), localBC);
656+
}
638657
histos.fill(HIST("FT0/hTimeA"), ft0.timeA());
639658
histos.fill(HIST("FT0/hTimeC"), ft0.timeC());
640659

0 commit comments

Comments
 (0)