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
2 changes: 1 addition & 1 deletion PWGDQ/Tasks/v0selector.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@
Configurable<float> cutAPL1{"cutAPL1", 0.107, "cutAPL1"};
Configurable<float> cutAPL2{"cutAPL2", -0.69, "cutAPL2"};
Configurable<float> cutAPL3{"cutAPL3", 0.5, "cutAPL3"};
Configurable<bool> produceV0ID{"produceV0ID",false,"Produce additional V0ID table"};
Configurable<bool> produceV0ID{"produceV0ID", false, "Produce additional V0ID table"};

enum { // Reconstructed V0
kUndef = -1,
Expand Down Expand Up @@ -195,7 +195,7 @@
registry.add("hDCAV0Dau", "hDCAV0Dau", HistType::kTH1F, {{1000, 0.0f, 10.0f}});
registry.add("hV0APplot", "hV0APplot", HistType::kTH2F, {{200, -1.0f, +1.0f}, {250, 0.0f, 0.25f}});
registry.add("hV0APplotSelected", "hV0APplotSelected", HistType::kTH2F, {{200, -1.0f, +1.0f}, {250, 0.0f, 0.25f}});
registry.add("hV0Psi", "hV0Psi", HistType::kTH2F, {{100, 0, TMath::PiOver2()}, {100, 0, 0.1}});

Check warning on line 198 in PWGDQ/Tasks/v0selector.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.
}
}

Expand All @@ -210,7 +210,7 @@
if (produceV0ID.value) {
v0pidmap.resize(V0s.size(), -1);
}
for (auto& V0 : V0s) {

Check warning on line 213 in PWGDQ/Tasks/v0selector.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.
// if (!(V0.posTrack_as<FullTracksExt>().trackType() & o2::aod::track::TPCrefit)) {
// continue;
// }
Expand All @@ -222,10 +222,10 @@
if (fillhisto) {
registry.fill(HIST("hV0Candidate"), 1);
}
if (std::fabs(V0.posTrack_as<FullTracksExt>().eta()) > 0.9) {

Check warning on line 225 in PWGDQ/Tasks/v0selector.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[magic-number]

Avoid magic numbers in expressions. Assign the value to a clearly named variable or constant.
continue;
}
if (std::fabs(V0.negTrack_as<FullTracksExt>().eta()) > 0.9) {

Check warning on line 228 in PWGDQ/Tasks/v0selector.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[magic-number]

Avoid magic numbers in expressions. Assign the value to a clearly named variable or constant.
continue;
}

Expand Down Expand Up @@ -343,7 +343,7 @@
registry.fill(HIST("hMassK0SEta"), V0.eta(), mK0S);
registry.fill(HIST("hMassK0SPhi"), V0.phi(), mK0S);
}
if ((0.48 < mK0S && mK0S < 0.51) && std::abs(V0.posTrack_as<FullTracksExt>().tpcNSigmaPi()) < cutNsigmaPiTPC && std::abs(V0.negTrack_as<FullTracksExt>().tpcNSigmaPi()) < cutNsigmaPiTPC) {

Check warning on line 346 in PWGDQ/Tasks/v0selector.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[magic-number]

Avoid magic numbers in expressions. Assign the value to a clearly named variable or constant.
pidmap[V0.posTrackId()] |= (uint8_t(1) << kK0S);
pidmap[V0.negTrackId()] |= (uint8_t(1) << kK0S);
storeV0AddID(V0.globalIndex(), kK0S);
Expand Down Expand Up @@ -372,11 +372,11 @@

} // end of V0 loop
if (produceV0ID.value) {
for (auto& V0 : V0s) {

Check warning on line 375 in PWGDQ/Tasks/v0selector.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.
v0mapID(v0pidmap[V0.globalIndex()]);
}
}
for (auto& track : tracks) {

Check warning on line 379 in PWGDQ/Tasks/v0selector.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.
// printf("setting pidmap[%lld] = %d\n",track.globalIndex(),pidmap[track.globalIndex()]);
v0bits(pidmap[track.globalIndex()]);
} // end of track loop
Expand Down Expand Up @@ -462,12 +462,12 @@
}
registry.fill(HIST("hEventCounter"), 3.0); // Ncontrib > 0

if (abs(collision.posZ()) > 10.0) {

Check warning on line 465 in PWGDQ/Tasks/v0selector.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[std-prefix]

Use std:: prefix for names from the std namespace.
return;
}
registry.fill(HIST("hEventCounter"), 4.0); //|Zvtx| < 10 cm

for (auto& track : tracks) {

Check warning on line 470 in PWGDQ/Tasks/v0selector.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.
if (!track.has_collision()) {
continue;
}
Expand Down Expand Up @@ -579,7 +579,7 @@
void DefineHistograms(TString histClasses)
{
std::unique_ptr<TObjArray> objArray(histClasses.Tokenize(";"));
for (Int_t iclass = 0; iclass < objArray->GetEntries(); ++iclass) {

Check warning on line 582 in PWGDQ/Tasks/v0selector.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();
fHistMan->AddHistClass(classStr.Data());

Expand Down
Loading