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: 0 additions & 2 deletions PWGLF/TableProducer/Strangeness/cascqaanalysis.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -179,12 +179,10 @@
registry.add("hFT0MsignalPVContr", "hFT0MsignalPVContr", {HistType::kTH3D, {signalFT0MAxis, multNTracksAxis, eventTypeAxis}});
}


rctChecker.init(cfgEvtRCTFlagCheckerLabel, cfgEvtRCTFlagCheckerZDCCheck, cfgEvtRCTFlagCheckerLimitAcceptAsBad);
if (cfgEvtRCTFlagCheckerFV0Check) {
rctChecker.set(o2::aod::rctsel::kFV0Bad);
}

}

Filter preFilter =
Expand All @@ -195,7 +193,7 @@
aod::cascdata::dcacascdaughters < dcacascdau);

Partition<DauTracks> pvContribTracksIUEta1 = (nabs(aod::track::eta) < 1.0f) && ((aod::track::flags & static_cast<uint32_t>(o2::aod::track::PVContributor)) == static_cast<uint32_t>(o2::aod::track::PVContributor));
Partition<DauTracks> globalTracksIUEta05 = (nabs(aod::track::eta) < 0.5f) && (requireGlobalTrackInFilter());

Check failure on line 196 in PWGLF/TableProducer/Strangeness/cascqaanalysis.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.

template <class TCascTracksTo, typename TCascade>
bool acceptCascCandidate(TCascade const& cascCand, float const& pvx, float const& pvy, float const& pvz)
Expand Down Expand Up @@ -235,7 +233,7 @@
if (pdgInfo->Charge() == 0) {
continue;
}
if (mcParticle.eta() < -3.3 || mcParticle.eta() > 4.9 || (mcParticle.eta() > -2.1 && mcParticle.eta() < 3.5)) {

Check failure on line 236 in PWGLF/TableProducer/Strangeness/cascqaanalysis.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; // select on T0M Nch region
}
nchFT0++; // increment
Expand All @@ -259,7 +257,7 @@
if (pdgInfo->Charge() == 0) {
continue;
}
if (mcParticle.eta() < 2.2 || mcParticle.eta() > 5.1) {

Check failure on line 260 in PWGLF/TableProducer/Strangeness/cascqaanalysis.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; // select on V0A Nch region
}
nchFV0A++; // increment
Expand Down Expand Up @@ -422,7 +420,7 @@

// ITS N hits
int posITSNhits = 0, negITSNhits = 0, bachITSNhits = 0;
for (unsigned int i = 0; i < 7; i++) {

Check failure on line 423 in PWGLF/TableProducer/Strangeness/cascqaanalysis.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.
if (posdau.itsClusterMap() & (1 << i)) {
posITSNhits++;
}
Expand Down Expand Up @@ -567,7 +565,7 @@

// ITS N hits
int posITSNhits = 0, negITSNhits = 0, bachITSNhits = 0;
for (unsigned int i = 0; i < 7; i++) {

Check failure on line 568 in PWGLF/TableProducer/Strangeness/cascqaanalysis.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.
if (posdau.itsClusterMap() & (1 << i)) {
posITSNhits++;
}
Expand Down Expand Up @@ -688,7 +686,7 @@

registry.fill(HIST("hNchFT0MNAssocMCCollisions"), nchFT0, nAssocColl, evType);

if (numberOfContributors.size() == 2) {

Check failure on line 689 in PWGLF/TableProducer/Strangeness/cascqaanalysis.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.
std::sort(numberOfContributors.begin(), numberOfContributors.end());
registry.fill(HIST("hNContributorsCorrelation"), numberOfContributors[0], numberOfContributors[1]);
}
Expand Down
21 changes: 12 additions & 9 deletions PWGLF/Tasks/Strangeness/derivedupcanalysis.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@
template <int partID>
void addTopoHistograms(HistogramRegistry& histos)
{
const bool isCascade = (partID > 2.5) ? true : false;

Check failure on line 308 in PWGLF/Tasks/Strangeness/derivedupcanalysis.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.
if (isCascade) {
histos.add(Form("%s/hCascCosPA", kParticlenames[partID].data()), "hCascCosPA", kTH2F, {axisPtCoarse, {100, 0.9f, 1.0f}});
histos.add(Form("%s/hDCACascDaughters", kParticlenames[partID].data()), "hDCACascDaughters", kTH2F, {axisPtCoarse, {44, 0.0f, 2.2f}});
Expand Down Expand Up @@ -339,7 +339,7 @@
template <int partID>
void addTPCQAHistograms(HistogramRegistry& histos)
{
const bool isCascade = (partID > 2.5) ? true : false;

Check failure on line 342 in PWGLF/Tasks/Strangeness/derivedupcanalysis.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.
histos.add(Form("%s/h3dPosNsigmaTPC", kParticlenames[partID].data()), "h3dPosNsigmaTPC", kTH3F, {axisDetectors.axisFT0ampl, axisPtCoarse, axisNsigmaTPC});
histos.add(Form("%s/h3dNegNsigmaTPC", kParticlenames[partID].data()), "h3dNegNsigmaTPC", kTH3F, {axisDetectors.axisFT0ampl, axisPtCoarse, axisNsigmaTPC});
histos.add(Form("%s/h3dPosTPCsignal", kParticlenames[partID].data()), "h3dPosTPCsignal", kTH3F, {axisDetectors.axisFT0ampl, axisPtCoarse, axisTPCsignal});
Expand Down Expand Up @@ -370,7 +370,7 @@
template <int partID>
void addTOFQAHistograms(HistogramRegistry& histos)
{
const bool isCascade = (partID > 2.5) ? true : false;

Check failure on line 373 in PWGLF/Tasks/Strangeness/derivedupcanalysis.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.
histos.add(Form("%s/h3dPosTOFdeltaT", kParticlenames[partID].data()), "h3dPosTOFdeltaT", kTH3F, {axisDetectors.axisFT0ampl, axisPtCoarse, axisTOFdeltaT});
histos.add(Form("%s/h3dNegTOFdeltaT", kParticlenames[partID].data()), "h3dNegTOFdeltaT", kTH3F, {axisDetectors.axisFT0ampl, axisPtCoarse, axisTOFdeltaT});
histos.add(Form("%s/h3dPosTOFdeltaTvsTrackPtot", kParticlenames[partID].data()), "h3dPosTOFdeltaTvsTrackPtot", kTH3F, {axisDetectors.axisFT0ampl, axisPtCoarse, axisTOFdeltaT});
Expand All @@ -387,7 +387,7 @@
template <int partID>
void addKinematicQAHistograms(HistogramRegistry& histos)
{
const bool isCascade = (partID > 2.5) ? true : false;

Check failure on line 390 in PWGLF/Tasks/Strangeness/derivedupcanalysis.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.
histos.add(Form("%s/h3dPosEtaPt", kParticlenames[partID].data()), "h3dPosEtaPt", kTH3F, {axisPtCoarse, axisEta, axisSelGap});
histos.add(Form("%s/h3dNegEtaPt", kParticlenames[partID].data()), "h3dNegEtaPt", kTH3F, {axisPtCoarse, axisEta, axisSelGap});
histos.add(Form("%s/h3dRapPt", kParticlenames[partID].data()), "h3dRapPt", kTH3F, {axisPtCoarse, axisRap, axisSelGap});
Expand Down Expand Up @@ -1088,11 +1088,14 @@
auto znc = collision.energyCommonZNC();
constexpr float inf_f = std::numeric_limits<float>::infinity();

if (zna == -inf_f) histos.fill(HIST("eventQA/hZN"), -1, znc, gap);
else if (znc == -inf_f) histos.fill(HIST("eventQA/hZN"), zna, -1, gap);
else if (zna == -999 && znc == -999) histos.fill(HIST("eventQA/hZN"), -2, -2, gap);
else if (zna == -999 || znc == -999) LOG(warning) << "Only one ZDC signal is -999";

if (zna == -inf_f)
histos.fill(HIST("eventQA/hZN"), -1, znc, gap);
else if (znc == -inf_f)
histos.fill(HIST("eventQA/hZN"), zna, -1, gap);
else if (zna == -999 && znc == -999)
histos.fill(HIST("eventQA/hZN"), -2, -2, gap);
else if (zna == -999 || znc == -999)
LOG(warning) << "Only one ZDC signal is -999";
}

template <typename TCollision>
Expand Down Expand Up @@ -1950,7 +1953,7 @@

std::size_t nV0sThisColl = v0sGrouped[collision.globalIndex()].size();

for (std::size_t i = 0 ; i < nV0sThisColl ; i++) {
for (std::size_t i = 0; i < nV0sThisColl; i++) {
auto v0 = fullV0s.rawIteratorAt(v0sGrouped[collision.globalIndex()][i]);
if ((v0.v0Type() != v0cuts.v0TypeSelection) && (v0cuts.v0TypeSelection > 0))
continue; // skip V0s that are not standard
Expand Down Expand Up @@ -2040,7 +2043,7 @@

std::size_t nV0sThisColl = v0sGrouped[collision.globalIndex()].size();

for (std::size_t i = 0 ; i < nV0sThisColl ; i++) {
for (std::size_t i = 0; i < nV0sThisColl; i++) {
auto v0 = fullV0s.rawIteratorAt(v0sGrouped[collision.globalIndex()][i]);
if ((v0.v0Type() != v0cuts.v0TypeSelection) && (v0cuts.v0TypeSelection > 0))
continue; // skip V0s that are not standard
Expand Down Expand Up @@ -2091,7 +2094,7 @@

std::size_t nCascadesThisColl = cascadesGrouped[collision.globalIndex()].size();

for (std::size_t i = 0 ; i < nCascadesThisColl ; i++) {
for (std::size_t i = 0; i < nCascadesThisColl; i++) {
auto casc = fullCascades.rawIteratorAt(cascadesGrouped[collision.globalIndex()][i]);
std::bitset<kSelNum> selMap = computeBitmapCascade(casc, collision);
// the candidate may belong to any particle species
Expand Down Expand Up @@ -2177,7 +2180,7 @@

std::size_t nCascadesThisColl = cascadesGrouped[collision.globalIndex()].size();

for (std::size_t i = 0 ; i < nCascadesThisColl ; i++) {
for (std::size_t i = 0; i < nCascadesThisColl; i++) {
auto casc = fullCascades.rawIteratorAt(cascadesGrouped[collision.globalIndex()][i]);
std::bitset<kSelNum> selMap = computeBitmapCascade(casc, collision);

Expand Down
Loading