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
3 changes: 1 addition & 2 deletions PWGLF/Tasks/Strangeness/sigmaminustask.cxx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.

Check failure on line 1 in PWGLF/Tasks/Strangeness/sigmaminustask.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/workflow-file]

Name of a workflow file must match the name of the main struct in it (without the PWG prefix). (Class implementation files should be in "Core" directories.)
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
// All rights not expressly granted are reserved.
//
Expand Down Expand Up @@ -30,7 +30,7 @@
using CollisionsFull = soa::Join<aod::Collisions, aod::EvSel>;
using CollisionsFullMC = soa::Join<aod::Collisions, aod::McCollisionLabels, aod::EvSels>;

struct sigmaminustask {

Check failure on line 33 in PWGLF/Tasks/Strangeness/sigmaminustask.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/struct]

Use UpperCamelCase for names of structs.
// Histograms are defined with HistogramRegistry
HistogramRegistry rEventSelection{"eventSelection", {}, OutputObjHandlingPolicy::AnalysisObject, true, true};
HistogramRegistry rSigmaMinus{"sigmaminus", {}, OutputObjHandlingPolicy::AnalysisObject, true, true};
Expand Down Expand Up @@ -70,11 +70,11 @@
rEventSelection.fill(HIST("hVertexZRec"), collision.posZ());
for (const auto& kinkCand : KinkCands) {
auto dauTrack = kinkCand.trackDaug_as<TracksFull>();
if (abs(dauTrack.tpcNSigmaPi()) > cutNSigmaPi) {

Check failure on line 73 in PWGLF/Tasks/Strangeness/sigmaminustask.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[std-prefix]

Use std:: prefix for names from the std namespace.
continue;
}
rSigmaMinus.fill(HIST("h2MassSigmaMinusPt"), kinkCand.mothSign() * kinkCand.ptMoth(), kinkCand.mSigmaMinus());
rSigmaMinus.fill(HIST("h2SigmaMassVsXiMass"), kinkCand.mXiMinus(), kinkCand.mSigmaMinus());
rSigmaMinus.fill(HIST("h2SigmaMassVsXiMass"), kinkCand.mXiMinus(), kinkCand.mSigmaMinus());
rSigmaMinus.fill(HIST("h2NSigmaPiPt"), kinkCand.mothSign() * kinkCand.ptMoth(), dauTrack.tpcNSigmaPi());
}
}
Expand All @@ -93,7 +93,7 @@
LOG(info) << "Skipping kink candidate with opposite sign daughter and mother: " << kinkCand.globalIndex();
continue; // Skip if the daughter has the opposite sign as the mother
}
if (abs(dauTrack.tpcNSigmaPi()) > cutNSigmaPi) {

Check failure on line 96 in PWGLF/Tasks/Strangeness/sigmaminustask.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[std-prefix]

Use std:: prefix for names from the std namespace.
continue;
}

Expand All @@ -109,15 +109,14 @@
if (!mcTrackPiDau.has_mothers()) {
continue;
}
for (auto& piMother : mcTrackPiDau.mothers_as<aod::McParticles>()) {

Check failure on line 112 in PWGLF/Tasks/Strangeness/sigmaminustask.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 (piMother.globalIndex() != mcTrackSigma.globalIndex()) {
continue;
}
if (std::abs(mcTrackSigma.pdgCode()) != 3112 || std::abs(mcTrackPiDau.pdgCode()) != 211) {

Check failure on line 116 in PWGLF/Tasks/Strangeness/sigmaminustask.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.

Check failure on line 116 in PWGLF/Tasks/Strangeness/sigmaminustask.cxx

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.
continue;
}
rSigmaMinus.fill(HIST("h2MassSigmaMinusPtMC"), kinkCand.mothSign() * kinkCand.ptMoth(), kinkCand.mSigmaMinus());

}
}
}
Expand Down
Loading