Skip to content

Commit

Permalink
[PWGDQ] add TPCnCRoverFindCls as variable and add cut setting to do a…
Browse files Browse the repository at this point in the history
… comparison between DQ and EM framework
  • Loading branch information
feisenhu committed Oct 29, 2024
1 parent d1642fb commit 2f087af
Show file tree
Hide file tree
Showing 4 changed files with 57 additions and 3 deletions.
48 changes: 48 additions & 0 deletions PWGDQ/Core/CutsLibrary.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -2512,6 +2512,22 @@ AnalysisCompositeCut* o2::aod::dqcuts::GetCompositeCut(const char* cutName)
return cut;
}

if (!nameStr.compare("trackCut_compareDQEMframework")) { // cut setting to check least common factor between reduced data sets of PWGEM and PWGDQ
cut->AddCut(GetAnalysisCut("lmeeStandardKine"));
cut->AddCut(GetAnalysisCut("trackQuality_compareDQEMframework"));
cut->AddCut(GetAnalysisCut("trackDCA1cm"));
AnalysisCompositeCut* cut_tpc_nSigma = new AnalysisCompositeCut("pid_TPCnSigma", "pid_TPCnSigma", kTRUE);
cut_tpc_nSigma->AddCut(GetAnalysisCut("lmee_commonDQEM_PID_TPC"));

AnalysisCompositeCut* cut_tof_nSigma = new AnalysisCompositeCut("pid_TOFnSigma", "pid_TOFnSigma", kTRUE);
cut_tof_nSigma->AddCut(GetAnalysisCut("lmee_commonDQEM_PID_TOF"));

AnalysisCompositeCut* cut_pid_OR = new AnalysisCompositeCut("e_NSigma", "e_NSigma", kFALSE);
cut_pid_OR->AddCut(cut_tpc_nSigma);
cut_pid_OR->AddCut(cut_tof_nSigma);
return cut;
}

// -------------------------------------------------------------------------------------------------
// lmee pair cuts

Expand Down Expand Up @@ -3801,6 +3817,17 @@ AnalysisCut* o2::aod::dqcuts::GetAnalysisCut(const char* cutName)
return cut;
}

if (!nameStr.compare("trackQuality_compareDQEMframework")) { // cut setting to check least common factor between reduced data sets of PWGEM and PWGDQ
cut->AddCut(VarManager::kIsSPDfirst, 0.5, 1.5);
cut->AddCut(VarManager::kITSchi2, 0.0, 5.0);
cut->AddCut(VarManager::kITSncls, 4.5, 7.5);
cut->AddCut(VarManager::kTPCchi2, 0.0, 4.0);
cut->AddCut(VarManager::kTPCnclsCR, 80.0, 161.);
cut->AddCut(VarManager::kTPCnCRoverFindCls, 0.8, 1e+10);
cut->AddCut(VarManager::kTPCncls, 90.0, 170.);
return cut;
}

if ((!nameStr.compare("TightGlobalTrackRun3")) || (!nameStr.compare("lmeeQCTrackCuts"))) {
cut->AddCut(VarManager::kIsSPDfirst, 0.5, 1.5);
cut->AddCut(VarManager::kTPCchi2, 0.0, 4.0);
Expand Down Expand Up @@ -4049,6 +4076,12 @@ AnalysisCut* o2::aod::dqcuts::GetAnalysisCut(const char* cutName)
return cut;
}

if (!nameStr.compare("trackDCA1cm")) { // cut setting to check least common factor between reduced data sets of PWGEM and PWGDQ
cut->AddCut(VarManager::kTrackDCAxy, -1.0, 1.0);
cut->AddCut(VarManager::kTrackDCAz, -1.0, 1.0);
return cut;
}

if (!nameStr.compare("dcaCut1_ionut")) {
cut->AddCut(VarManager::kTrackDCAxy, -0.5, 0.5);
cut->AddCut(VarManager::kTrackDCAz, -0.5, 0.5);
Expand Down Expand Up @@ -4409,6 +4442,21 @@ AnalysisCut* o2::aod::dqcuts::GetAnalysisCut(const char* cutName)
return cut;
}

if (!nameStr.compare("lmee_commonDQEM_PID_TPC")) { // cut setting to check least common factor between reduced data sets of PWGEM and PWGDQ
cut->AddCut(VarManager::kTPCnSigmaEl, -2.5, 3., false, VarManager::kPin, 0.0, 1e+10, false);
cut->AddCut(VarManager::kTPCnSigmaPi, -1e12, 3.5, true, VarManager::kPin, 0.0, 1e+10, false);
cut->AddCut(VarManager::kTPCnSigmaKa, -3., 3., true, VarManager::kPin, 0.0, 1e+10, false);
cut->AddCut(VarManager::kTPCnSigmaPr, -3., 3., true, VarManager::kPin, 0.0, 1e+10, false);
return cut;
}

if (!nameStr.compare("lmee_commonDQEM_PID_TOF")) { // cut setting to check least common factor between reduced data sets of PWGEM and PWGDQ
cut->AddCut(VarManager::kTPCnSigmaEl, -2.5, 3., false, VarManager::kPin, 0.0, 1e+10, false);
cut->AddCut(VarManager::kTPCnSigmaPi, -3., 3.5, true, VarManager::kPin, 0.0, 1e+10, false);
cut->AddCut(VarManager::kTOFnSigmaEl, -3., 3., false, VarManager::kPin, 0.3, 1e+10, false);
return cut;
}

std::vector<TString> vecPIDcase;
vecPIDcase.emplace_back(""); // without post calibration
vecPIDcase.emplace_back("_Corr"); // case of using post calibrated PID spectra
Expand Down
2 changes: 2 additions & 0 deletions PWGDQ/Core/VarManager.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -435,6 +435,8 @@ void VarManager::SetDefaultVarNames()
fgVariableUnits[kTPCncls] = "";
fgVariableNames[kTPCnclsCR] = "TPC #cls crossed rows";
fgVariableUnits[kTPCnclsCR] = "";
fgVariableNames[kTPCnCRoverFindCls] = "TPC crossed rows over findable cls";
fgVariableUnits[kTPCnCRoverFindCls] = "";
fgVariableNames[kTPCchi2] = "TPC chi2";
fgVariableUnits[kTPCchi2] = "";
fgVariableNames[kTPCsignal] = "TPC dE/dx";
Expand Down
4 changes: 4 additions & 0 deletions PWGDQ/Core/VarManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -445,6 +445,7 @@ class VarManager : public TObject
kTPCncls,
kITSClusterMap,
kTPCnclsCR,
kTPCnCRoverFindCls,
kTPCchi2,
kTPCsignal,
kTPCsignalRandomized,
Expand Down Expand Up @@ -2045,6 +2046,9 @@ void VarManager::FillTrack(T const& track, float* values)
values[kHasTPC] = track.hasTPC();

if constexpr ((fillMap & TrackExtra) > 0) {
if (fgUsedVars[kTPCnCRoverFindCls]) {
values[kTPCnCRoverFindCls] = track.tpcCrossedRowsOverFindableCls();
}
if (fgUsedVars[kITSncls]) {
values[kITSncls] = track.itsNCls(); // dynamic column
}
Expand Down
6 changes: 3 additions & 3 deletions PWGEM/Dilepton/Tasks/MCtemplates.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -333,9 +333,9 @@ struct AnalysisTrackSelection {
fHistMan->FillHistClass(fHistNamesMCMatched[j][i].Data(), VarManager::fgValues);
}
} // end loop over cuts
} // end loop over MC signals
} // end loop over tracks
}
} // end loop over MC signals
} // end loop over tracks
} // end runTrackSelection

template <typename TTracksMC>
void runMCGenTrack(TTracksMC const& groupedMCTracks)
Expand Down

0 comments on commit 2f087af

Please sign in to comment.