Skip to content
Merged
Show file tree
Hide file tree
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 PWGJE/Core/JetTaggingUtilities.h
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@

int motherStatusCode = std::abs(mother.getGenStatusCode());

if (motherStatusCode == 23 || motherStatusCode == 33 || motherStatusCode == 43 || motherStatusCode == 63) {

Check failure on line 158 in PWGJE/Core/JetTaggingUtilities.h

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.
return mother.globalIndex();
}
}
Expand Down Expand Up @@ -183,7 +183,7 @@

int motherStatusCode = std::abs(mother.getGenStatusCode());

if (motherStatusCode == 23 || motherStatusCode == 33 || motherStatusCode == 43 || motherStatusCode == 63 || (motherStatusCode == 51 && mother.template mothers_first_as<T>().pdgCode() == 21)) {

Check failure on line 186 in PWGJE/Core/JetTaggingUtilities.h

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.

Check failure on line 186 in PWGJE/Core/JetTaggingUtilities.h

View workflow job for this annotation

GitHub Actions / O2 linter

[pdg/explicit-code]

Avoid hard-coded PDG codes. Use named values from PDG_t or o2::constants::physics::Pdg instead.
return mother.globalIndex();
}
}
Expand Down Expand Up @@ -350,7 +350,7 @@
typename U::iterator parton1;
typename U::iterator parton2;
for (auto const& particle : particles) {
if (std::abs(particle.getGenStatusCode() == 23)) {
if (std::abs(particle.getGenStatusCode()) == 23) {

Check failure on line 353 in PWGJE/Core/JetTaggingUtilities.h

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.
if (!firstPartonFound) {
parton1 = particle;
firstPartonFound = true;
Expand Down Expand Up @@ -387,13 +387,13 @@
bool charmQuark = false;
for (auto const& mcpart : mcparticles) {
int pdgcode = mcpart.pdgCode();
if (std::abs(pdgcode) == 21 || (std::abs(pdgcode) >= 1 && std::abs(pdgcode) <= 5)) {

Check failure on line 390 in PWGJE/Core/JetTaggingUtilities.h

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.

Check failure on line 390 in PWGJE/Core/JetTaggingUtilities.h

View workflow job for this annotation

GitHub Actions / O2 linter

[pdg/explicit-code]

Avoid hard-coded PDG codes. Use named values from PDG_t or o2::constants::physics::Pdg instead.
double dR = jetutilities::deltaR(jet, mcpart);

if (dR < jet.r() / 100.f) {
if (std::abs(pdgcode) == 5) {

Check failure on line 394 in PWGJE/Core/JetTaggingUtilities.h

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.

Check failure on line 394 in PWGJE/Core/JetTaggingUtilities.h

View workflow job for this annotation

GitHub Actions / O2 linter

[pdg/explicit-code]

Avoid hard-coded PDG codes. Use named values from PDG_t or o2::constants::physics::Pdg instead.
return JetTaggingSpecies::beauty; // Beauty jet
} else if (std::abs(pdgcode) == 4) {

Check failure on line 396 in PWGJE/Core/JetTaggingUtilities.h

View workflow job for this annotation

GitHub Actions / O2 linter

[pdg/explicit-code]

Avoid hard-coded PDG codes. Use named values from PDG_t or o2::constants::physics::Pdg instead.
charmQuark = true;
}
}
Expand Down Expand Up @@ -916,7 +916,7 @@

trkLabels["trkVtxIndex"] = std::vector<int>(nTrks, -1);
if (count.size() != 0) { // If there is any SV cluster not only PV cluster
for (auto& [idx, avgDistance] : avgDistances) // o2-linter: disable=const-ref-in-for-loop

Check failure on line 919 in PWGJE/Core/JetTaggingUtilities.h

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.
avgDistance /= count[idx];

nVertices += avgDistances.size();
Expand Down
2 changes: 1 addition & 1 deletion PWGJE/Tasks/trackJetQA.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ struct TrackJetQa {
histos.fill(HIST("TrackPar/signed1Pt"), track.pt(), track.sigma1Pt() * track.pt(), track.signed1Pt(), collision.centFT0A(), collision.centFT0C());
histos.fill(HIST("TrackPar/snp"), track.pt(), track.sigma1Pt() * track.pt(), track.snp(), collision.centFT0A(), collision.centFT0C());
histos.fill(HIST("TrackPar/tgl"), track.pt(), track.sigma1Pt() * track.pt(), track.tgl(), collision.centFT0A(), collision.centFT0C());
for (unsigned int i = 0; i < 64; i++) {
for (unsigned int i = 0; i < 32; i++) {
if (track.flags() & (1 << i)) {
histos.fill(HIST("TrackPar/flags"), track.pt(), track.sigma1Pt() * track.pt(), i);
}
Expand Down
Loading