Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 19 additions & 21 deletions PWGUD/Tasks/upcTauRl.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -533,7 +533,7 @@
histos.add("EventTwoTracks/ElectronMuPi/PID/hTOFnSigmaVsPPofO", ";Not-electron #it{p} (GeV/c);n#sigma^{#pi}_{TOF} (arb. units)", HistType::kTH2D, {confAxis.zzAxisMom, confAxis.zzAxisNsigma});
histos.add("EventTwoTracks/ElectronMuPi/PID/hTOFnSigmaEvsnSigmaPofO", ";Not-electron n#sigma^{e}_{TOF} (arb. units);Not-electron n#sigma^{#pi}_{TOF} (arb. units)", HistType::kTH2D, {confAxis.zzAxisNsigma, confAxis.zzAxisNsigma});

if (doMixedEventsHistos){
if (doMixedEventsHistos) {
histos.add("EventTwoTracks/MixedEvents/TwoElectrons/hInvariantMass", "Mixed events;Invariant mass (GeV/c^{2});Number of events (-)", HistType::kTH1D, {confAxis.zzAxisInvMass});
histos.add("EventTwoTracks/MixedEvents/TwoElectrons/hInvariantMassWide", "Mixed events;Invariant mass (GeV/c^{2});Number of events (-)", HistType::kTH1D, {confAxis.zzAxisInvMassWide});
histos.add("EventTwoTracks/MixedEvents/TwoElectrons/hAcoplanarity", "Mixed events;#Delta#phi (rad);Number of events (-)", HistType::kTH1D, {confAxis.zzAxisAcoplanarity});
Expand Down Expand Up @@ -592,7 +592,6 @@
histos.add("EventTwoTracks/MixedEvents/ElectronMuPi/hElectronPhiVsOtherPhi", "Mixed events;Electron #phi (rad); #mu/#pi #phi (rad)", HistType::kTH2D, {confAxis.zzAxisPhi, confAxis.zzAxisPhi});
histos.add("EventTwoTracks/MixedEvents/ElectronMuPi/hElectronRapVsOtherRap", "Mixed events;Electron #it{y} (-); #mu/#pi #it{y} (-)", HistType::kTH2D, {confAxis.zzAxisRap, confAxis.zzAxisRap});
}

}

if (doTruthHistos) {
Expand Down Expand Up @@ -1191,15 +1190,15 @@
}
}
if (isElMuPion) {
if (cutTauEvent.useThresholdsPID){
if (isElectronCandidate(trkDaug1)){
vecMixElMupion.push_back(std::make_pair(vecPVnewPIDidx[0], vecPVnewPIDidx[1]));// storing electron first
if (cutTauEvent.useThresholdsPID) {
if (isElectronCandidate(trkDaug1)) {
vecMixElMupion.push_back(std::make_pair(vecPVnewPIDidx[0], vecPVnewPIDidx[1])); // storing electron first
} else {
vecMixElMupion.push_back(std::make_pair(vecPVnewPIDidx[1], vecPVnewPIDidx[0]));
}
} else {
if (enumMyParticle(trackPDG(trkDaug1, cutPID.cutSiTPC, cutPID.cutSiTOF, cutPID.usePIDwTOF, cutPID.useScutTOFinTPC)) == P_ELECTRON){
vecMixElMupion.push_back(std::make_pair(vecPVidx[0], vecPVidx[1]));// storing electron first
if (enumMyParticle(trackPDG(trkDaug1, cutPID.cutSiTPC, cutPID.cutSiTOF, cutPID.usePIDwTOF, cutPID.useScutTOFinTPC)) == P_ELECTRON) {
vecMixElMupion.push_back(std::make_pair(vecPVidx[0], vecPVidx[1])); // storing electron first
} else {
vecMixElMupion.push_back(std::make_pair(vecPVidx[1], vecPVidx[0]));
}
Expand Down Expand Up @@ -2013,9 +2012,9 @@
void fillMixedEventHistograms(Ts const& reconstructedBarrelTracks)
{
TLorentzVector mother, daug[2];
for (int idx = 0; idx < static_cast<int>(vecMixElEl.size()); idx++){
for (int cnt = 0; cnt < 5; cnt++){
for (int idx = 0; idx < static_cast<int>(vecMixElEl.size()); idx++) {
for (int cnt = 0; cnt < 5; cnt++) {
std::random_device rand_dev;

Check warning on line 2017 in PWGUD/Tasks/upcTauRl.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
std::mt19937 generator(rand_dev());
std::uniform_int_distribution<int> distr(0, static_cast<int>(vecMixElEl.size()));
int idx2 = distr(generator);
Expand Down Expand Up @@ -2055,12 +2054,12 @@
histos.get<TH2>(HIST("EventTwoTracks/MixedEvents/TwoElectrons/hLeadingPtVsOtherPt"))->Fill(((daug[0].P() > daug[1].P()) ? daug[0].Pt() : daug[1].Pt()), ((daug[0].P() > daug[1].P()) ? daug[1].Pt() : daug[0].Pt()));
histos.get<TH2>(HIST("EventTwoTracks/MixedEvents/TwoElectrons/hLeadingPhiVsOtherPhi"))->Fill(((daug[0].P() > daug[1].P()) ? daug[0].Phi() : daug[1].Phi()), ((daug[0].P() > daug[1].P()) ? daug[1].Phi() : daug[0].Phi()));
histos.get<TH2>(HIST("EventTwoTracks/MixedEvents/TwoElectrons/hLeadingRapVsOtherRap"))->Fill(((daug[0].P() > daug[1].P()) ? daug[0].Rapidity() : daug[1].Rapidity()), ((daug[0].P() > daug[1].P()) ? daug[1].Rapidity() : daug[0].Rapidity()));
}//cnt
}//idx
} // cnt
} // idx

for (int idx = 0; idx < static_cast<int>(vecMixElMupion.size()); idx++){
for (int cnt = 0; cnt < 5; cnt++){
for (int idx = 0; idx < static_cast<int>(vecMixElMupion.size()); idx++) {
for (int cnt = 0; cnt < 5; cnt++) {
std::random_device rand_dev;

Check warning on line 2062 in PWGUD/Tasks/upcTauRl.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
std::mt19937 generator(rand_dev());
std::uniform_int_distribution<int> distr(0, static_cast<int>(vecMixElMupion.size()));
int idx2 = distr(generator);
Expand All @@ -2076,7 +2075,7 @@
const auto& electronPt = daug[0].Pt();
const auto& electronP = daug[0].P();
const auto& electronE = daug[0].E();
const auto& mupionPt = daug[1].Pt();
const auto& mupionPt = daug[1].Pt();
const auto& mupionP = daug[1].P();
const auto& mupionE = daug[1].E();
histos.get<TH1>(HIST("EventTwoTracks/MixedEvents/ElectronMuPi/hInvariantMass"))->Fill(mother.M());
Expand Down Expand Up @@ -2109,15 +2108,15 @@
histos.get<TH2>(HIST("EventTwoTracks/MixedEvents/ElectronMuPi/hElectronPtVsOtherPt"))->Fill(electronPt, mupionPt);
histos.get<TH2>(HIST("EventTwoTracks/MixedEvents/ElectronMuPi/hElectronPhiVsOtherPhi"))->Fill(isElectronCandidate(trkDaug1) ? daug[0].Phi() : daug[1].Phi(), isElectronCandidate(trkDaug1) ? daug[1].Phi() : daug[0].Phi());
histos.get<TH2>(HIST("EventTwoTracks/MixedEvents/ElectronMuPi/hElectronRapVsOtherRap"))->Fill(isElectronCandidate(trkDaug1) ? daug[0].Rapidity() : daug[1].Rapidity(), isElectronCandidate(trkDaug1) ? daug[1].Rapidity() : daug[0].Rapidity());
}//cnt
}//idx
} // cnt
} // idx
} // end fillMixedEventHistograms

void processDataDG(FullUDCollisions const& reconstructedCollisions,
FullUDTracks const& reconstructedBarrelTracks)
{

for (const auto& reconstructedCollision : reconstructedCollisions){
for (const auto& reconstructedCollision : reconstructedCollisions) {
if (!isGoodROFtime(reconstructedCollision))
return;

Expand Down Expand Up @@ -2146,7 +2145,7 @@
void processDataSG(FullSGUDCollisions const& reconstructedCollisions,
FullUDTracks const& reconstructedBarrelTracks)
{
for (const auto& reconstructedCollision : reconstructedCollisions){
for (const auto& reconstructedCollision : reconstructedCollisions) {

int gapSide = reconstructedCollision.gapSide();
int trueGapSide = sgSelector.trueGap(reconstructedCollision, cutSample.cutTrueGapSideFV0, cutSample.cutTrueGapSideFT0A, cutSample.cutTrueGapSideFT0C, cutSample.cutTrueGapSideZDC);
Expand Down Expand Up @@ -2188,7 +2187,7 @@
aod::UDMcParticles const&)
{
isMC = true;
for (const auto& reconstructedCollision : reconstructedCollisions){
for (const auto& reconstructedCollision : reconstructedCollisions) {

if (!isGoodROFtime(reconstructedCollision))
return;
Expand Down Expand Up @@ -2231,7 +2230,7 @@
aod::UDMcParticles const&)
{
isMC = true;
for (const auto& reconstructedCollision : reconstructedCollisions){
for (const auto& reconstructedCollision : reconstructedCollisions) {

int gapSide = reconstructedCollision.gapSide();
histos.fill(HIST("Events/UDtableGapSide"), gapSide);
Expand Down Expand Up @@ -2271,7 +2270,6 @@
fillPIDhistograms(reconstructedCollision, reconstructedBarrelTracks);
fillMCPIDhistograms(reconstructedBarrelTracks);
}

}

} // end processMCrecDG
Expand Down
Loading