Skip to content

Commit edfdf66

Browse files
committed
Fill QA histogram for trigger events
1 parent a9fcaa7 commit edfdf66

File tree

1 file changed

+17
-15
lines changed

1 file changed

+17
-15
lines changed

PWGLF/TableProducer/Resonances/f1protonreducedtable.cxx

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ struct f1protonreducedtable {
8484
Configurable<int> trackSphMin{"trackSphMin", 10, "Number of tracks for Spherocity Calculation"};
8585

8686
// Configs for track PID
87+
Configurable<bool> Confglobaltrackcheck{"Confglobaltrackcheck", true, "Global track check"};
8788
Configurable<bool> cfgSkimmedProcessing{"cfgSkimmedProcessing", true, "Analysed skimmed events"};
8889
Configurable<bool> ConfUseManualPIDproton{"ConfUseManualPIDproton", true, "True: use home-made PID solution for proton "};
8990
Configurable<bool> ConfUseManualPIDkaon{"ConfUseManualPIDkaon", true, "True: use home-made PID solution for kaon "};
@@ -265,8 +266,8 @@ struct f1protonreducedtable {
265266
template <typename T>
266267
bool selectionGlobalTrack(const T& candidate)
267268
{
268-
if (!(candidate.isGlobalTrack() && candidate.isPVContributor())) {
269-
// return false;
269+
if (Confglobaltrackcheck && !(candidate.isGlobalTrack() && candidate.isPVContributor())) {
270+
return false;
270271
}
271272
return true;
272273
}
@@ -984,22 +985,23 @@ struct f1protonreducedtable {
984985
}
985986
}
986987
qaRegistry.fill(HIST("hEventstat"), 0.5);
987-
988-
for (auto iproton = protons.begin(); iproton != protons.end(); ++iproton) {
989-
auto i6 = std::distance(protons.begin(), iproton);
990-
ProtonVectorDummy2 = protons.at(i6);
991-
if (std::abs(ProtonDcaxy.at(i6)) < 0.05 && std::abs(ProtonDcaz.at(i6)) < 0.05) {
992-
if (ProtonTOFHit.at(i6) && ProtonVectorDummy2.P() > 0.7) {
993-
qaRegistry.fill(HIST("hNsigmaPtprotonTPC"),ProtonTPCNsigma.at(i6), ProtonTOFNsigma.at(i6), ProtonVectorDummy2.Pt());
988+
if (keepEventF1Proton) {
989+
for (auto iproton = protons.begin(); iproton != protons.end(); ++iproton) {
990+
auto i6 = std::distance(protons.begin(), iproton);
991+
ProtonVectorDummy2 = protons.at(i6);
992+
if (std::abs(ProtonDcaxy.at(i6)) < 0.05 && std::abs(ProtonDcaz.at(i6)) < 0.05) {
993+
if (ProtonTOFHit.at(i6) && ProtonVectorDummy2.P() > 0.7) {
994+
qaRegistry.fill(HIST("hNsigmaPtprotonTPC"),ProtonTPCNsigma.at(i6), ProtonTOFNsigma.at(i6), ProtonVectorDummy2.Pt());
995+
}
996+
if (ProtonVectorDummy2.P() < 0.7) {
997+
qaRegistry.fill(HIST("hNsigmaPtprotonTPC"),ProtonTPCNsigma.at(i6), 4.999, ProtonVectorDummy2.Pt());
998+
}
994999
}
995-
if (ProtonVectorDummy2.P() < 0.7) {
996-
qaRegistry.fill(HIST("hNsigmaPtprotonTPC"),ProtonTPCNsigma.at(i6), 4.999, ProtonVectorDummy2.Pt());
1000+
if (passProtonPID(ProtonTPCNsigma.at(i6), ProtonTOFNsigma.at(i6), ProtonTOFHit.at(i6), ProtonVectorDummy2)) {
1001+
qaRegistry.fill(HIST("hDCAxy"), ProtonDcaxy.at(i6), ProtonCharge.at(i6), ProtonVectorDummy2.Pt());
1002+
qaRegistry.fill(HIST("hDCAz"), ProtonDcaz.at(i6), ProtonCharge.at(i6), ProtonVectorDummy2.Pt());
9971003
}
9981004
}
999-
if (passProtonPID(ProtonTPCNsigma.at(i6), ProtonTOFNsigma.at(i6), ProtonTOFHit.at(i6), ProtonVectorDummy2)) {
1000-
qaRegistry.fill(HIST("hDCAxy"), ProtonDcaxy.at(i6), ProtonCharge.at(i6), ProtonVectorDummy2.Pt());
1001-
qaRegistry.fill(HIST("hDCAz"), ProtonDcaz.at(i6), ProtonCharge.at(i6), ProtonVectorDummy2.Pt());
1002-
}
10031005
}
10041006

10051007
if (numberF1 > 0 && (f1resonance.size() == f1signal.size()) && (f1resonance.size() == f1kaonkshortmass.size()) && (f1resonance.size() == f1resonanced1.size()) && (f1resonance.size() == f1resonanced2.size()) && (f1resonance.size() == f1resonanced3.size())) {

0 commit comments

Comments
 (0)