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
2 changes: 2 additions & 0 deletions PWGLF/TableProducer/Strangeness/strangenesstofpid.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -373,7 +373,7 @@
float findInterceptLength(o2::track::TrackPar track, float magneticField)
{
float length = 1e+6;
for (int iSeg = 0; iSeg < 18; iSeg++) {

Check failure on line 376 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
// Detector segmentation loop
float segmentAngle = 20.0f / 180.0f * TMath::Pi();
float theta = static_cast<float>(iSeg) * 20.0f / 180.0f * TMath::Pi();
Expand All @@ -387,7 +387,7 @@
length = thisLength;
}
}
if (length > 1e+5)

Check failure on line 390 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
length = -100; // force negative to avoid misunderstandings
return length;
}
Expand Down Expand Up @@ -622,10 +622,10 @@
}

// In case override, don't proceed, please - no CCDB access required
if (propagationConfiguration.d_bz_input > -990) {

Check failure on line 625 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
d_bz = propagationConfiguration.d_bz_input;
o2::parameters::GRPMagField grpmag;
if (std::fabs(d_bz) > 1e-5) {

Check failure on line 628 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
grpmag.setL3Current(30000.f / (d_bz / 5.0f));
}
o2::base::Propagator::initFieldFromGRP(&grpmag);
Expand Down Expand Up @@ -736,6 +736,8 @@
if (!hSigmaPosOmPi || !hSigmaPosOmPr || !hSigmaNegOmPi || !hSigmaNegOmPr || !hSigmaBachOmKa)
LOG(info) << "Problems finding omega sigma histograms!";
}
} else {
LOG(warn) << "Problems finding calibration objects for run " << runNumber << " at " << ccdbConfigurations.nSigmaPath << ". Proceed without it";
}
}
}
Expand Down Expand Up @@ -928,7 +930,7 @@
float velocityPositiveEl, velocityPositivePr, velocityPositivePi, lengthPositive;
velocityPositiveEl = velocityPositivePr = velocityPositivePi = lengthPositive = o2::aod::v0data::kNoTOFValue;

if (pTof.hasTOF && pTof.tofEvTime > -1e+5 && pValidTOF) {

Check failure on line 933 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
// method 0: legacy standalone without use of primary particle TOF
if (calculationMethod.value == 0) {
velocityPositiveEl = velocity(posTrack.getP(), o2::constants::physics::MassElectron);
Expand Down Expand Up @@ -1044,7 +1046,7 @@
}
float velocityNegativeEl, velocityNegativePr, velocityNegativePi, lengthNegative;
velocityNegativeEl = velocityNegativePr = velocityNegativePi = lengthNegative = o2::aod::v0data::kNoTOFValue;
if (nTof.hasTOF && nTof.tofEvTime > -1e+5 && nValidTOF) {

Check failure on line 1049 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
// method 0: legacy standalone without use of primary particle TOF
if (calculationMethod.value == 0) {
velocityNegativeEl = velocity(negTrack.getP(), o2::constants::physics::MassElectron);
Expand Down Expand Up @@ -1279,7 +1281,7 @@

//_____________________________________________________________________________________________
// Actual calculation
if (pTof.hasTOF && pTof.tofEvTime > -1e+5 && pValidTOF) {

Check failure on line 1284 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
float velocityPositivePr, velocityPositivePi, lengthPositive;
velocityPositivePr = velocityPositivePi = lengthPositive = o2::aod::v0data::kNoTOFValue;
if (calculationMethod.value == 0) {
Expand Down Expand Up @@ -1415,7 +1417,7 @@
}
} // end positive

if (nTof.hasTOF && nTof.tofEvTime > -1e+5 && nValidTOF) {

Check failure on line 1420 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
float velocityNegativePr, velocityNegativePi, lengthNegative;
velocityNegativePr = velocityNegativePi = lengthNegative = o2::aod::v0data::kNoTOFValue;
// method 0: legacy standalone without use of primary particle TOF
Expand Down Expand Up @@ -1552,7 +1554,7 @@
}
} // end negative

if (bTof.hasTOF && bTof.tofEvTime > -1e+5 && bValidTOF) {

Check failure on line 1557 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
float velocityBachelorKa, velocityBachelorPi, lengthBachelor;
velocityBachelorKa = velocityBachelorPi = lengthBachelor = o2::aod::v0data::kNoTOFValue;
// method 0: legacy standalone without use of primary particle TOF
Expand Down Expand Up @@ -1994,7 +1996,7 @@
pTof.hasTOF = pTra.hasTOF();
pTof.tpcNSigmaPi = pTra.tpcNSigmaPi();
pTof.tpcNSigmaPr = pTra.tpcNSigmaPr();
if (tofIndices[V0.posTrackExtraId()] >= 0 && collision.eventTime() > -1e+5) {

Check failure on line 1999 in PWGLF/TableProducer/Strangeness/strangenesstofpid.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.
auto pTofExt = dauTrackTOFPIDs.rawIteratorAt(tofIndices[V0.posTrackExtraId()]);
// extract BC for BC time shift
const int64_t deltaBc = pTofExt.globalBC() - collision.globalBC();
Expand Down
Loading