Skip to content
Closed
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
4 changes: 2 additions & 2 deletions PWGDQ/Tasks/dqEfficiency.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
//
// Analysis task for processing O2::DQ MC skimmed AODs
//
#include <iostream>

Check failure on line 16 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[include-iostream]

Do not include iostream. Use O2 logging instead.
#include <vector>
#include <TMath.h>
#include <TH1F.h>
Expand Down Expand Up @@ -207,14 +207,14 @@
// Configure histogram classes for each track cut;
// Add histogram classes for each track cut and for each requested MC signal (reconstructed tracks with MC truth)
TString histClasses = "TrackBarrel_BeforeCuts;";
for (auto& cut : fTrackCuts) {

Check failure on line 210 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[const-ref-in-for-loop]

Use constant references for non-modified iterators in range-based for loops.
TString nameStr = Form("TrackBarrel_%s", cut.GetName());
fHistNamesReco.push_back(nameStr);
histClasses += Form("%s;", nameStr.Data());
std::vector<TString> mcnames;
for (auto& sig : fMCSignals) {
TString nameStr2 = Form("TrackBarrel_%s_%s", cut.GetName(), sig.GetName());
printf("Adding my histogram class %s\n", nameStr2.Data());

Check failure on line 217 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[logging]

Use O2 logging (LOG, LOGF, LOGP).
mcnames.push_back(nameStr2);
histClasses += Form("%s;", nameStr2.Data());
}
Expand Down Expand Up @@ -383,7 +383,7 @@
std::vector<TString> mcnames;
for (auto& sig : fMCSignals) {
TString nameStr2 = Form("TrackMuon_%s_%s", cut.GetName(), sig.GetName());
printf("Adding my histogram class %s\n", nameStr2.Data());

Check failure on line 386 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[logging]

Use O2 logging (LOG, LOGF, LOGP).
mcnames.push_back(nameStr2);
histClasses += Form("%s;", nameStr2.Data());
}
Expand Down Expand Up @@ -1048,7 +1048,7 @@
Configurable<bool> fNoCorr{"cfgNoCorrFwdProp", false, "Do not correct for MCS effects in track propagation"};
Configurable<std::string> lutPath{"lutPath", "GLO/Param/MatLUT", "Path of the Lut parametrization"};
Configurable<std::string> geoPath{"geoPath", "GLO/Config/GeometryAligned", "Path of the geometry file"};

Filter eventFilter = aod::dqanalysisflags::isEventSelected == 1;
// Filter dileptonFilter = aod::reducedpair::mass > 2.92f && aod::reducedpair::mass < 3.16f && aod::reducedpair::sign == 0;
// Filter dileptonFilter = aod::reducedpair::mass > 2.6f && aod::reducedpair::mass < 3.5f && aod::reducedpair::sign == 0;
Expand Down Expand Up @@ -1095,7 +1095,7 @@
lut = o2::base::MatLayerCylSet::rectifyPtrFromFile(ccdb->get<o2::base::MatLayerCylSet>(lutPath));
VarManager::SetupMatLUTFwdDCAFitter(lut);
}

TString sigNamesStr = fConfigMCRecSignals.value;
std::unique_ptr<TObjArray> objRecSigArray(sigNamesStr.Tokenize(","));
TString histNames;
Expand Down Expand Up @@ -1395,7 +1395,7 @@
// dilepton-track-track cuts
TString configQuadruletCutNamesStr = fConfigQuadrupletCuts.value;
std::unique_ptr<TObjArray> objArray(configQuadruletCutNamesStr.Tokenize(","));
for (Int_t icut = 0; icut < objArray->GetEntries(); ++icut) {

Check failure on line 1398 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
TString cutName = objArray->At(icut)->GetName();
fQuadrupletCutNames.push_back(cutName);
fQuadrupletCuts.push_back(*dqcuts::GetCompositeCut(cutName.Data()));
Expand Down Expand Up @@ -1661,7 +1661,7 @@
// The histogram classes and their components histograms are defined below depending on the name of the histogram class
//
std::unique_ptr<TObjArray> objArray(histClasses.Tokenize(";"));
for (Int_t iclass = 0; iclass < objArray->GetEntries(); ++iclass) {

Check failure on line 1664 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
TString classStr = objArray->At(iclass)->GetName();
histMan->AddHistClass(classStr.Data());

Expand Down Expand Up @@ -1693,7 +1693,7 @@
histMan->AddHistogram(objArray->At(iclass)->GetName(), "Pt_Rapidity", "MC generator p_{T}, y distribution", false, 120, 0.0, 30.0, VarManager::kMCPt, 150, 2.5, 4.0, VarManager::kMCY);
histMan->AddHistogram(objArray->At(iclass)->GetName(), "Eta", "MC generator #eta distribution", false, 200, 2.5, 4.0, VarManager::kMCEta);
// histMan->AddHistogram(objArray->At(iclass)->GetName(), "Rapidity", "MC generator y distribution", false, 150, 2.5, 4.0, VarManager::kMCY);
histMan->AddHistogram(objArray->At(iclass)->GetName(), "Phi", "MC generator #varphi distribution", false, 50, 0.0, 2. * TMath::Pi(), VarManager::kMCPhi);

Check failure on line 1696 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[pi-multiple-fraction]

Use multiples/fractions of PI defined in o2::constants::math.

Check failure on line 1696 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[external-pi]

Use the PI constant (and its multiples and fractions) defined in o2::constants::math.
}
if (classStr.Contains("MCTruthGenQuad")) {
dqhistograms::DefineHistograms(histMan, objArray->At(iclass)->GetName(), "mctruth_quad");
Expand All @@ -1703,7 +1703,7 @@
histMan->AddHistogram(objArray->At(iclass)->GetName(), "Pt_Rapidity", "MC generator p_{T}, y distribution", false, 120, 0.0, 30.0, VarManager::kMCPt, 150, 2.5, 4.0, VarManager::kMCY);
histMan->AddHistogram(objArray->At(iclass)->GetName(), "Eta", "MC generator #eta distribution", false, 200, 2.5, 4.0, VarManager::kMCEta);
// histMan->AddHistogram(objArray->At(iclass)->GetName(), "Rapidity", "MC generator y distribution", false, 150, 2.5, 4.0, VarManager::kMCY);
histMan->AddHistogram(objArray->At(iclass)->GetName(), "Phi", "MC generator #varphi distribution", false, 50, 0.0, 2. * TMath::Pi(), VarManager::kMCPhi);

Check failure on line 1706 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[pi-multiple-fraction]

Use multiples/fractions of PI defined in o2::constants::math.

Check failure on line 1706 in PWGDQ/Tasks/dqEfficiency.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[external-pi]

Use the PI constant (and its multiples and fractions) defined in o2::constants::math.
}
if (classStr.Contains("DileptonsSelected")) {
dqhistograms::DefineHistograms(histMan, objArray->At(iclass)->GetName(), "pair", "barrel,dimuon");
Expand Down
Loading