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 PWGLF/Tasks/Strangeness/derivedcascadeanalysis.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@
#include <TFile.h>
#include <TH2F.h>
#include <TProfile.h>
#include <TLorentzVector.h>

Check failure on line 52 in PWGLF/Tasks/Strangeness/derivedcascadeanalysis.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/lorentz-vector]

Do not use the TLorentzVector legacy class. Use std::array with RecoDecay methods or the ROOT::Math::LorentzVector template instead.
#include <TPDGCode.h>

// constants
const float ctauxiPDG = 4.91; // from PDG

Check failure on line 56 in PWGLF/Tasks/Strangeness/derivedcascadeanalysis.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.
const float ctauomegaPDG = 2.461; // from PDG

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

using namespace o2;
using namespace o2::framework;
Expand Down Expand Up @@ -560,9 +560,9 @@
ptdepCut = candidateSelectionValues.cosPApar0 + candidateSelectionValues.cosPApar1 * casc.pt();
else
ptdepCut = candidateSelectionValues.cosPApar0 + candidateSelectionValues.cosPApar1 * casc.pt();
if (ptdepCut > 0.3 && casc.pt() < 0.5)

Check failure on line 563 in PWGLF/Tasks/Strangeness/derivedcascadeanalysis.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.
ptdepCut = 0.3;
if (ptdepCut < 0.012)

Check failure on line 565 in PWGLF/Tasks/Strangeness/derivedcascadeanalysis.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.
ptdepCut = 0.012;
if (isCascPa)
histos.fill(HIST("hCutValue"), 15, std::cos(ptdepCut));
Expand Down Expand Up @@ -873,9 +873,9 @@
if (candidateSelectionFlags.doDCACascadeDauCut) {
if (candidateSelectionFlags.doPtDepDCAcascDauCut) {
float ptDepCut = candidateSelectionValues.dcaCacsDauPar0;
if (casc.pt() > 1 && casc.pt() < 4)

Check failure on line 876 in PWGLF/Tasks/Strangeness/derivedcascadeanalysis.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.
ptDepCut = candidateSelectionValues.dcaCacsDauPar1;
else if (casc.pt() > 4)

Check failure on line 878 in PWGLF/Tasks/Strangeness/derivedcascadeanalysis.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.
ptDepCut = candidateSelectionValues.dcaCacsDauPar2;
histos.fill(HIST("hCutValue"), 3, ptDepCut);
if (casc.dcacascdaughters() > ptDepCut)
Expand Down Expand Up @@ -1296,7 +1296,7 @@
if (!kHasTOF && !kHasITS)
continue;
histos.fill(HIST("hCandidate"), ++counter);
} else if (candidateSelectionFlags.dooobrej == 2) {

Check failure on line 1299 in PWGLF/Tasks/Strangeness/derivedcascadeanalysis.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 (!kHasTOF && (casc.pt() > candidateSelectionValues.ptthrtof))
continue;
histos.fill(HIST("hCandidate"), ++counter);
Expand All @@ -1315,7 +1315,7 @@

if (candidateSelectionFlags.doNTOFSigmaProtonCut && casc.sign() < 0) {
histos.fill(HIST("hNsigmaTOFProton"), casc.tofNSigmaXiLaPr(), fullMomentumPosDaugh, centrality);
if (std::abs(casc.tofNSigmaXiLaPr()) > candidateSelectionValues.nsigmatofPr && fullMomentumPosDaugh > 0.6)

Check failure on line 1318 in PWGLF/Tasks/Strangeness/derivedcascadeanalysis.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 (candidateSelectionFlags.doNTOFSigmaV0PionCut && casc.sign() > 0) {
Expand All @@ -1329,7 +1329,7 @@

if (candidateSelectionFlags.doNTOFSigmaProtonCut && casc.sign() > 0) {
histos.fill(HIST("hNsigmaTOFProton"), casc.tofNSigmaXiLaPr(), fullmomentumNegDaugh, centrality);
if (std::abs(casc.tofNSigmaXiLaPr()) > candidateSelectionValues.nsigmatofPr && fullmomentumNegDaugh > 0.6)

Check failure on line 1332 in PWGLF/Tasks/Strangeness/derivedcascadeanalysis.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 (candidateSelectionFlags.doNTOFSigmaV0PionCut && casc.sign() < 0) {
Expand Down Expand Up @@ -1515,7 +1515,7 @@
histos.fill(HIST("h2dGenXiMinusVsCentIR"), ptmc, centrality, intRate);
histos.fill(HIST("h2dGenXiMinusVsNchVsOccupancy"), ptmc, nChEta1, occupancy);
}
if (cascMC.pdgCode() == PDG_t::kXiPlusBar && isXi) {
if (cascMC.pdgCode() == PDG_t::kXiPlusBar && isXi) {
histos.fill(HIST("h2dGenXiPlus"), centrality, ptmc);
histos.fill(HIST("h2dGenXiPlusVsNch"), nChEta1, ptmc);
histos.fill(HIST("h2dGenXiPlusVsMultMCVsCentrality"), mcCollision.multMCNParticlesEta05(), centrality, ptmc);
Expand Down
Loading