Skip to content

Commit 854cb6f

Browse files
author
Lucia Anna Tarasovicova
committed
fix the O2 linter for OTFStrangeness
1 parent c8e4f7c commit 854cb6f

File tree

2 files changed

+39
-39
lines changed

2 files changed

+39
-39
lines changed

ALICE3/DataModel/OTFStrangeness.h

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ DECLARE_SOA_INDEX_COLUMN_FULL(NegTrack, negTrack, int, Tracks, "_Neg");
3535
DECLARE_SOA_INDEX_COLUMN_FULL(BachTrack, bachTrack, int, Tracks, "_Bach"); //!
3636

3737
// topo vars
38-
DECLARE_SOA_COLUMN(DCAV0Daughters, dcaV0Daughters, float);
39-
DECLARE_SOA_COLUMN(DCACascadeDaughters, dcaCascadeDaughters, float);
38+
DECLARE_SOA_COLUMN(DcaV0Daughters, dcaV0Daughters, float);
39+
DECLARE_SOA_COLUMN(DcaCascadeDaughters, dcaCascadeDaughters, float);
4040
DECLARE_SOA_COLUMN(V0Radius, v0Radius, float);
4141
DECLARE_SOA_COLUMN(CascRadius, cascRadius, float);
4242
DECLARE_SOA_COLUMN(CascRadiusMC, cascRadiusMC, float);
@@ -55,8 +55,8 @@ DECLARE_SOA_TABLE(UpgradeCascades, "AOD", "UPGRADECASCADES",
5555
otfcascade::PosTrackId,
5656
otfcascade::NegTrackId,
5757
otfcascade::BachTrackId,
58-
otfcascade::DCAV0Daughters,
59-
otfcascade::DCACascadeDaughters,
58+
otfcascade::DcaV0Daughters,
59+
otfcascade::DcaCascadeDaughters,
6060
otfcascade::V0Radius,
6161
otfcascade::CascRadius,
6262
otfcascade::CascRadiusMC,
@@ -75,7 +75,7 @@ DECLARE_SOA_INDEX_COLUMN_FULL(NegTrack, negTrack, int, Tracks, "_Neg"); //!
7575
DECLARE_SOA_INDEX_COLUMN(V0, v0); //! index of the mc particle corresponding to the V0
7676

7777
// topo vars
78-
DECLARE_SOA_COLUMN(DCAV0Daughters, dcaV0Daughters, float);
78+
DECLARE_SOA_COLUMN(DcaV0Daughters, dcaV0Daughters, float);
7979
DECLARE_SOA_COLUMN(V0Radius, v0Radius, float);
8080
DECLARE_SOA_COLUMN(MLambda, mLambda, float);
8181
DECLARE_SOA_COLUMN(MAntiLambda, mAntiLambda, float);
@@ -91,7 +91,7 @@ DECLARE_SOA_TABLE(UpgradeV0s, "AOD", "UPGRADEV0S",
9191
otfv0::V0Id,
9292
otfv0::PosTrackId,
9393
otfv0::NegTrackId,
94-
otfv0::DCAV0Daughters,
94+
otfv0::DcaV0Daughters,
9595
otfv0::V0Radius,
9696
otfv0::MLambda,
9797
otfv0::MAntiLambda,
@@ -108,27 +108,27 @@ DECLARE_SOA_INDEX_COLUMN_FULL(NegTrack, negTrack, int, Tracks, "_Neg"); //!
108108
DECLARE_SOA_INDEX_COLUMN(V0, v0); //!
109109

110110
// Label to MC particle
111-
DECLARE_SOA_INDEX_COLUMN_FULL(MCParticle, mcParticle, int, McParticles, ""); //! label to the MC particle corresponding to the V0
111+
DECLARE_SOA_INDEX_COLUMN_FULL(McParticle, mcParticle, int, McParticles, ""); //! label to the MC particle corresponding to the V0
112112

113113
// General V0 properties: position, momentum
114114
DECLARE_SOA_COLUMN(PosX, posX, float); //! positive track X at min
115115
DECLARE_SOA_COLUMN(NegX, negX, float); //! negative track X at min
116-
DECLARE_SOA_COLUMN(PxPos, pxpos, float); //! positive track px at min
117-
DECLARE_SOA_COLUMN(PyPos, pypos, float); //! positive track py at min
118-
DECLARE_SOA_COLUMN(PzPos, pzpos, float); //! positive track pz at min
119-
DECLARE_SOA_COLUMN(PxNeg, pxneg, float); //! negative track px at min
120-
DECLARE_SOA_COLUMN(PyNeg, pyneg, float); //! negative track py at min
121-
DECLARE_SOA_COLUMN(PzNeg, pzneg, float); //! negative track pz at min
116+
DECLARE_SOA_COLUMN(PxPos, pxPos, float); //! positive track px at min
117+
DECLARE_SOA_COLUMN(PyPos, pyPos, float); //! positive track py at min
118+
DECLARE_SOA_COLUMN(PzPos, pzPos, float); //! positive track pz at min
119+
DECLARE_SOA_COLUMN(PxNeg, pxNeg, float); //! negative track px at min
120+
DECLARE_SOA_COLUMN(PyNeg, pyNeg, float); //! negative track py at min
121+
DECLARE_SOA_COLUMN(PzNeg, pzNeg, float); //! negative track pz at min
122122
DECLARE_SOA_COLUMN(X, x, float); //! decay position X
123123
DECLARE_SOA_COLUMN(Y, y, float); //! decay position Y
124124
DECLARE_SOA_COLUMN(Z, z, float); //! decay position Z
125125

126126
// topo vars
127-
DECLARE_SOA_COLUMN(DCAV0Daughters, dcaV0Daughters, float);
127+
DECLARE_SOA_COLUMN(DcaV0Daughters, dcaV0Daughters, float);
128128
DECLARE_SOA_COLUMN(CosPA, cosPA, float);
129-
DECLARE_SOA_COLUMN(DCAPosToPV, dcaPosToPV, float);
130-
DECLARE_SOA_COLUMN(DCANegToPV, dcaNegToPV, float);
131-
DECLARE_SOA_COLUMN(DCAV0ToPV, dcaV0ToPV, float);
129+
DECLARE_SOA_COLUMN(DcaPosToPV, dcaPosToPV, float);
130+
DECLARE_SOA_COLUMN(DcaNegToPV, dcaNegToPV, float);
131+
DECLARE_SOA_COLUMN(DcaV0ToPV, dcaV0ToPV, float);
132132

133133
//______________________________________________________
134134
// DYNAMIC COLUMNS
@@ -154,14 +154,14 @@ DECLARE_SOA_DYNAMIC_COLUMN(Eta, eta, //! Pseudorapidity, conditionally defined t
154154
return RecoDecay::eta(std::array{pxPos + pxNeg, pyPos + pyNeg, pzPos + pzNeg});
155155
});
156156
// Length quantities
157-
DECLARE_SOA_DYNAMIC_COLUMN(V0Radius, v0radius, //! V0 decay radius (2D, centered at zero)
157+
DECLARE_SOA_DYNAMIC_COLUMN(V0radius, v0radius, //! V0 decay radius (2D, centered at zero)
158158
[](float x, float y) -> float { return RecoDecay::sqrtSumOfSquares(x, y); });
159159

160160
// Distance Over To Mom
161-
DECLARE_SOA_DYNAMIC_COLUMN(DistOverTotMom, distovertotmom, //! PV to V0decay distance over total momentum
161+
DECLARE_SOA_DYNAMIC_COLUMN(DistOverTotMom, distOverTotMom, //! PV to V0decay distance over total momentum
162162
[](float X, float Y, float Z, float pxPos, float pyPos, float pzPos, float pxNeg, float pyNeg, float pzNeg, float pvX, float pvY, float pvZ) {
163-
float P = RecoDecay::sqrtSumOfSquares(pxPos + pxNeg, pyPos + pyNeg, pzPos + pzNeg);
164-
return std::sqrt(std::pow(X - pvX, 2) + std::pow(Y - pvY, 2) + std::pow(Z - pvZ, 2)) / (P + 1E-10);
163+
float p = RecoDecay::sqrtSumOfSquares(pxPos + pxNeg, pyPos + pyNeg, pzPos + pzNeg);
164+
return std::sqrt(std::pow(X - pvX, 2) + std::pow(Y - pvY, 2) + std::pow(Z - pvZ, 2)) / (p + 1E-10);
165165
});
166166

167167
// Armenteros-Podolanski variables
@@ -173,7 +173,7 @@ DECLARE_SOA_DYNAMIC_COLUMN(Alpha, alpha, //! Armenteros Alpha
173173
return (lQlPos - lQlNeg) / (lQlPos + lQlNeg); // alphav0
174174
});
175175

176-
DECLARE_SOA_DYNAMIC_COLUMN(QtArm, qtarm, //! Armenteros Qt
176+
DECLARE_SOA_DYNAMIC_COLUMN(QtArm, qtArm, //! Armenteros Qt
177177
[](float pxpos, float pypos, float pzpos, float pxneg, float pyneg, float pzneg) {
178178
float momTot = RecoDecay::p2(pxpos + pxneg, pypos + pyneg, pzpos + pzneg);
179179
float dp = RecoDecay::dotProd(std::array{pxneg, pyneg, pzneg}, std::array{pxpos + pxneg, pypos + pyneg, pzpos + pzneg});
@@ -202,37 +202,37 @@ DECLARE_SOA_DYNAMIC_COLUMN(YLambda, yLambda, //! V0 y with lambda or antilambda
202202
return RecoDecay::y(std::array{pxpos + pxneg, pypos + pyneg, pzpos + pzneg}, o2::constants::physics::MassLambda);
203203
});
204204
// Daughter track momenta
205-
DECLARE_SOA_DYNAMIC_COLUMN(NegativePt, negativept, //! negative daughter pT
205+
DECLARE_SOA_DYNAMIC_COLUMN(NegativePt, negativePt, //! negative daughter pT
206206
[](float pxneg, float pyneg) -> float { return RecoDecay::sqrtSumOfSquares(pxneg, pyneg); });
207-
DECLARE_SOA_DYNAMIC_COLUMN(PositivePt, positivept, //! positive daughter pT
207+
DECLARE_SOA_DYNAMIC_COLUMN(PositivePt, positivePt, //! positive daughter pT
208208
[](float pxpos, float pypos) -> float { return RecoDecay::sqrtSumOfSquares(pxpos, pypos); });
209-
DECLARE_SOA_DYNAMIC_COLUMN(NegativeEta, negativeeta, //! negative daughter eta
209+
DECLARE_SOA_DYNAMIC_COLUMN(NegativeEta, negativeEta, //! negative daughter eta
210210
[](float PxNeg, float PyNeg, float PzNeg) -> float { return RecoDecay::eta(std::array{PxNeg, PyNeg, PzNeg}); });
211-
DECLARE_SOA_DYNAMIC_COLUMN(NegativePhi, negativephi, //! negative daughter phi
211+
DECLARE_SOA_DYNAMIC_COLUMN(NegativePhi, negativePhi, //! negative daughter phi
212212
[](float PxNeg, float PyNeg) -> float { return RecoDecay::phi(PxNeg, PyNeg); });
213-
DECLARE_SOA_DYNAMIC_COLUMN(PositiveEta, positiveeta, //! positive daughter eta
213+
DECLARE_SOA_DYNAMIC_COLUMN(PositiveEta, positiveEta, //! positive daughter eta
214214
[](float PxPos, float PyPos, float PzPos) -> float { return RecoDecay::eta(std::array{PxPos, PyPos, PzPos}); });
215-
DECLARE_SOA_DYNAMIC_COLUMN(PositivePhi, positivephi, //! positive daughter phi
215+
DECLARE_SOA_DYNAMIC_COLUMN(PositivePhi, positivePhi, //! positive daughter phi
216216
[](float PxPos, float PyPos) -> float { return RecoDecay::phi(PxPos, PyPos); });
217217
} // namespace candidatev0
218218
DECLARE_SOA_TABLE(V0CandidateIndices, "AOD", "V0CANDIDATEINDEX", //! index table
219-
o2::soa::Index<>, candidatev0::CollisionId, candidatev0::PosTrackId, candidatev0::NegTrackId, candidatev0::MCParticleId);
219+
o2::soa::Index<>, candidatev0::CollisionId, candidatev0::PosTrackId, candidatev0::NegTrackId, candidatev0::McParticleId);
220220

221221
DECLARE_SOA_TABLE(V0CandidateCores, "AOD", "V0CANDIDATECORE",
222222
o2::soa::Index<>,
223223
candidatev0::X, candidatev0::Y, candidatev0::Z,
224224
candidatev0::PxPos, candidatev0::PyPos, candidatev0::PzPos,
225225
candidatev0::PxNeg, candidatev0::PyNeg, candidatev0::PzNeg,
226-
candidatev0::DCAV0Daughters, candidatev0::DCAPosToPV, candidatev0::DCANegToPV,
227-
candidatev0::CosPA, candidatev0::DCAV0ToPV,
226+
candidatev0::DcaV0Daughters, candidatev0::DcaPosToPV, candidatev0::DcaNegToPV,
227+
candidatev0::CosPA, candidatev0::DcaV0ToPV,
228228
candidatev0::Px<candidatev0::PxPos, candidatev0::PxNeg>,
229229
candidatev0::Py<candidatev0::PyPos, candidatev0::PyNeg>,
230230
candidatev0::Pz<candidatev0::PzPos, candidatev0::PzNeg>,
231231
candidatev0::Pt<candidatev0::PxPos, candidatev0::PyPos, candidatev0::PxNeg, candidatev0::PyNeg>,
232232
candidatev0::P<candidatev0::PxPos, candidatev0::PyPos, candidatev0::PzPos, candidatev0::PxNeg, candidatev0::PyNeg, candidatev0::PzNeg>,
233233
candidatev0::Phi<candidatev0::PxPos, candidatev0::PyPos, candidatev0::PxNeg, candidatev0::PyNeg>,
234234
candidatev0::Eta<candidatev0::PxPos, candidatev0::PyPos, candidatev0::PzPos, candidatev0::PxNeg, candidatev0::PyNeg, candidatev0::PzNeg>,
235-
candidatev0::V0Radius<candidatev0::X, candidatev0::Y>,
235+
candidatev0::V0radius<candidatev0::X, candidatev0::Y>,
236236
candidatev0::DistOverTotMom<candidatev0::X, candidatev0::Y, candidatev0::Z, candidatev0::PxPos, candidatev0::PyPos, candidatev0::PzPos, candidatev0::PxNeg, candidatev0::PyNeg, candidatev0::PzNeg>,
237237
candidatev0::Alpha<candidatev0::PxPos, candidatev0::PyPos, candidatev0::PzPos, candidatev0::PxNeg, candidatev0::PyNeg, candidatev0::PzNeg>,
238238
candidatev0::QtArm<candidatev0::PxPos, candidatev0::PyPos, candidatev0::PzPos, candidatev0::PxNeg, candidatev0::PyNeg, candidatev0::PzNeg>,

ALICE3/Tasks/alice3Strangeness.cxx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ struct Alice3Strangeness {
222222
bool isLambda = (v0.mLambda() - o2::constants::physics::MassLambda0) < selectionValues.acceptedLambdaMassWindow;
223223
bool isAntiLambda = (v0.mAntiLambda() - o2::constants::physics::MassLambda0) < selectionValues.acceptedLambdaMassWindow;
224224

225-
histos.fill(HIST("reconstructedCandidates/hArmeterosBeforeAllSelections"), v0.alpha(), v0.qtarm());
225+
histos.fill(HIST("reconstructedCandidates/hArmeterosBeforeAllSelections"), v0.alpha(), v0.qtArm());
226226
histos.fill(HIST("hV0CandidateCounter"), 0.5);
227227
if (selectionFlags.applyRapiditySelection) {
228228
if (isK0 && std::abs(v0.yK0Short()) > selectionValues.yK0Selection)
@@ -263,7 +263,7 @@ struct Alice3Strangeness {
263263
histos.fill(HIST("hV0CandidateCounter"), 5.5);
264264
if (isK0) {
265265
if (selectionFlags.applyArmenterosSelection) {
266-
if (v0.qtarm() < selectionValues.armenterosSelection * std::abs(v0.alpha()))
266+
if (v0.qtArm() < selectionValues.armenterosSelection * std::abs(v0.alpha()))
267267
continue;
268268
}
269269
}
@@ -280,15 +280,15 @@ struct Alice3Strangeness {
280280
}
281281
histos.fill(HIST("hV0CandidateCounter"), 7.5);
282282
if (selectionFlags.applyLifetimeSelection) {
283-
if (isK0 && v0.distovertotmom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassK0Short > selectionValues.lifetimecutak0)
283+
if (isK0 && v0.distOverTotMom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassK0Short > selectionValues.lifetimecutak0)
284284
continue;
285-
if ((isLambda || isAntiLambda) && v0.distovertotmom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassLambda0 > selectionValues.lifetimecutambda)
285+
if ((isLambda || isAntiLambda) && v0.distOverTotMom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassLambda0 > selectionValues.lifetimecutambda)
286286
continue;
287287
} else {
288288
if (isK0)
289-
selectionCheck = v0.distovertotmom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassK0Short;
289+
selectionCheck = v0.distOverTotMom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassK0Short;
290290
else
291-
selectionCheck = v0.distovertotmom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassLambda0;
291+
selectionCheck = v0.distOverTotMom(collision.posX(), collision.posY(), collision.posZ()) * o2::constants::physics::MassLambda0;
292292
}
293293
histos.fill(HIST("hV0CandidateCounter"), 8.5);
294294
auto posTrack = v0.template posTrack_as<Alice3tracks>();
@@ -301,7 +301,7 @@ struct Alice3Strangeness {
301301
histos.fill(HIST("reconstructedCandidates/hEtaDaughters"), negTrack.eta());
302302
histos.fill(HIST("hV0CandidateCounter"), 9.5);
303303

304-
histos.fill(HIST("reconstructedCandidates/hArmeterosAfterAllSelections"), v0.alpha(), v0.qtarm());
304+
histos.fill(HIST("reconstructedCandidates/hArmeterosAfterAllSelections"), v0.alpha(), v0.qtArm());
305305
if (selectionFlags.doQAforSelectionVariables) {
306306
static_for<0, 5>([&](auto i) {
307307
constexpr int In = i.value;

0 commit comments

Comments
 (0)