Skip to content

Commit a9fed51

Browse files
Refactor string parameter types in functions
1 parent 359fdf1 commit a9fed51

1 file changed

Lines changed: 34 additions & 38 deletions

File tree

PWGCF/EbyEFluctuations/Tasks/kaonIsospinFluctuations.cxx

Lines changed: 34 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
#include <algorithm>
5151
#include <chrono>
5252
#include <cstdint>
53+
#include <string>
5354
#include <string_view>
5455
#include <typeindex>
5556
#include <vector>
@@ -194,12 +195,12 @@ double calculateTime(T Start)
194195
return timeInSeconds;
195196
}
196197
template <typename T>
197-
void printTime(T Start, std::string String)
198+
void printTime(T Start, const std::string String)
198199
{
199200
LOG(info) << String << calculateTime(Start) << " seconds";
200201
}
201202

202-
void printHistInfo(std::string String, const auto& hist)
203+
void printHistInfo(const std::string String, const auto& hist)
203204
{
204205
int64_t iEntries = hist->GetEntries();
205206
double mean = hist->GetMean();
@@ -1388,9 +1389,6 @@ struct KaonIsospinFluctuations {
13881389
prefixLabel = "effWeightSum";
13891390
}
13901391
for (int i = 0; i < (kRejectedDe + 1); i++) {
1391-
if (i == kNonePid) {
1392-
continue;
1393-
}
13941392
for (int j = kPos; j <= kNeg; j++) {
13951393
signLabel = SignDire[j].data();
13961394
if (kDe < i && i < kRejectedPi) {
@@ -1560,8 +1558,6 @@ struct KaonIsospinFluctuations {
15601558
addAllV0Histos(recoK0s, "recoK0s/PreSel/", "Pi/", "Pi/", fillMotherQA, fillDauTrackQA);
15611559
if (fillDauTrackQA) {
15621560
recoK0s.addClone("recoK0s/PreSel/Pi/Pos/tpcId/", "recoK0s/PreSel/Pi/Pos/NoId/");
1563-
} // for unidentified
1564-
if (fillDauTrackQA) {
15651561
recoK0s.addClone("recoK0s/PreSel/Pi/Pos/NoId/", "recoK0s/PreSel/Pi/Neg/NoId/");
15661562
} // for unidentified
15671563

@@ -2591,7 +2587,7 @@ struct KaonIsospinFluctuations {
25912587
}
25922588

25932589
template <typename T, typename H>
2594-
void findRepeatedEntries(std::vector<H> ParticleList, T hist)
2590+
void findRepeatedEntries(const std::vector<H> ParticleList, T hist)
25952591
{
25962592
for (uint ii = 0; ii < ParticleList.size(); ii++) {
25972593
int nCommonCount = 0; // checking the repeat number of track
@@ -3067,7 +3063,7 @@ struct KaonIsospinFluctuations {
30673063
negDauMass = MassElectron;
30683064
} else {
30693065
static_assert(Mode == v0TableFull || Mode == v0TablePostK0sCheck || Mode == v0TablePostK0sMassCut ||
3070-
Mode == v0TablePostK0sSelectionCut || Mode == v0TablePostLambdaCheck || Mode == v0TablePostLambdaCheck ||
3066+
Mode == v0TablePostK0sSelectionCut || Mode == v0TablePostLambdaCheck ||
30713067
Mode == v0TablePostGammaCheck || Mode == recoK0sPreSel || Mode == recoK0sPostSel ||
30723068
Mode == recoLambdaPostSel || Mode == recoAntiLambdaPostSel || Mode == recoGammaPostSel,
30733069
"Unsupported particleMode");
@@ -3178,7 +3174,7 @@ struct KaonIsospinFluctuations {
31783174
void executeV0loop(const T& posDaughterTrack, const T& negDaughterTrack, const U& v0,
31793175
auto& idMethodPi, auto& idMethodPr, auto& idMethodEl,
31803176
int& v0Tag, int& trueV0TagValue,
3181-
int& v0DauCollisionIndexTag, int& v0DauBCTag, auto& v0CndtDauList,
3177+
int& v0DauCollisionIndexTag, int& v0DauBCTag, auto& v0CandtDauList,
31823178
int& v0PtEtaBin, int& posDauPtEtaBin, int& negDauPtEtaBin,
31833179
float& v0K0sEffWeight, float& v0LambdaEffWeight, float& v0AntiLambdaEffWeight, float& v0GammaEffWeight,
31843180
const auto& v0DecayTrueMcTag)
@@ -3226,8 +3222,8 @@ struct KaonIsospinFluctuations {
32263222
// Final K0s Selection.
32273223
if (selK0s(v0)) {
32283224
BITSET(trueV0TagValue, BIT_IS_K0S);
3229-
v0CndtDauList[kV0TrkK0s][kPos].emplace_back(posDaughterTrack.globalIndex(), std::abs((v0.mK0Short() - MV0DecayCndt[kV0TrkK0s]) / WV0DecayCndt[kV0TrkK0s]));
3230-
v0CndtDauList[kV0TrkK0s][kNeg].emplace_back(negDaughterTrack.globalIndex(), std::abs((v0.mK0Short() - MV0DecayCndt[kV0TrkK0s]) / WV0DecayCndt[kV0TrkK0s]));
3225+
v0CandtDauList[kV0TrkK0s][kPos].emplace_back(posDaughterTrack.globalIndex(), std::abs((v0.mK0Short() - MV0DecayCndt[kV0TrkK0s]) / WV0DecayCndt[kV0TrkK0s]));
3226+
v0CandtDauList[kV0TrkK0s][kNeg].emplace_back(negDaughterTrack.globalIndex(), std::abs((v0.mK0Short() - MV0DecayCndt[kV0TrkK0s]) / WV0DecayCndt[kV0TrkK0s]));
32313227
k0sTagIndexList.push_back(v0.globalIndex());
32323228
if (cfgFill.cfgFill04V0TablePostK0sSelectionCut) {
32333229
fillV0QA<v0TablePostK0sSelectionCut, kFillSimple, kPi, kPi>(recoV0sPostK0sSelectionCut, v0, posDaughterTrack, negDaughterTrack, posDauPtEtaBin, negDauPtEtaBin, v0Tag, v0DauCollisionIndexTag, v0DauBCTag, idMethodPi[kPos], idMethodPi[kNeg], v0K0sEffWeight, fillMotherQA, fillDauTrackQA);
@@ -3241,8 +3237,8 @@ struct KaonIsospinFluctuations {
32413237
BITSET(trueV0TagValue, BIT_IS_LAMBDA);
32423238
v0LambdaEffWeight = hPtEtaForEffCorrection[kV0Lambda][kPos]->GetBinContent(v0PtEtaBin);
32433239

3244-
v0CndtDauList[kV0TrkLambda][kPos].emplace_back(posDaughterTrack.globalIndex(), std::abs((v0.mLambda() - MV0DecayCndt[kV0TrkLambda]) / WV0DecayCndt[kV0TrkLambda]));
3245-
v0CndtDauList[kV0TrkLambda][kNeg].emplace_back(negDaughterTrack.globalIndex(), std::abs((v0.mLambda() - MV0DecayCndt[kV0TrkLambda]) / WV0DecayCndt[kV0TrkLambda]));
3240+
v0CandtDauList[kV0TrkLambda][kPos].emplace_back(posDaughterTrack.globalIndex(), std::abs((v0.mLambda() - MV0DecayCndt[kV0TrkLambda]) / WV0DecayCndt[kV0TrkLambda]));
3241+
v0CandtDauList[kV0TrkLambda][kNeg].emplace_back(negDaughterTrack.globalIndex(), std::abs((v0.mLambda() - MV0DecayCndt[kV0TrkLambda]) / WV0DecayCndt[kV0TrkLambda]));
32463242
if (cfgFill.cfgFill05V0TablePostLambdaCheck) {
32473243
fillV0QA<v0TablePostLambdaCheck, kFillSimple, kPr, kPi>(recoV0sPostLambdaCheck, v0, posDaughterTrack, negDaughterTrack, posDauPtEtaBin, negDauPtEtaBin, v0Tag, v0DauCollisionIndexTag, v0DauBCTag, idMethodPr[kPos], idMethodPi[kNeg], v0LambdaEffWeight, fillMotherQA, fillDauTrackQA);
32483244
}
@@ -3255,8 +3251,8 @@ struct KaonIsospinFluctuations {
32553251
BITSET(trueV0TagValue, BIT_IS_ANTILAMBDA);
32563252
v0AntiLambdaEffWeight = hPtEtaForEffCorrection[kV0AntiLambda][kPos]->GetBinContent(v0PtEtaBin);
32573253

3258-
v0CndtDauList[kV0TrkAntiLambda][kPos].emplace_back(posDaughterTrack.globalIndex(), std::abs((v0.mAntiLambda() - MV0DecayCndt[kV0TrkAntiLambda]) / WV0DecayCndt[kV0TrkAntiLambda]));
3259-
v0CndtDauList[kV0TrkAntiLambda][kNeg].emplace_back(negDaughterTrack.globalIndex(), std::abs((v0.mAntiLambda() - MV0DecayCndt[kV0TrkAntiLambda]) / WV0DecayCndt[kV0TrkAntiLambda]));
3254+
v0CandtDauList[kV0TrkAntiLambda][kPos].emplace_back(posDaughterTrack.globalIndex(), std::abs((v0.mAntiLambda() - MV0DecayCndt[kV0TrkAntiLambda]) / WV0DecayCndt[kV0TrkAntiLambda]));
3255+
v0CandtDauList[kV0TrkAntiLambda][kNeg].emplace_back(negDaughterTrack.globalIndex(), std::abs((v0.mAntiLambda() - MV0DecayCndt[kV0TrkAntiLambda]) / WV0DecayCndt[kV0TrkAntiLambda]));
32603256
if (cfgFill.cfgFill06V0TablePostAntiLambdaCheck) {
32613257
fillV0QA<v0TablePostAntiLambdaCheck, kFillSimple, kPi, kPr>(recoV0sPostAntiLambdaCheck, v0, posDaughterTrack, negDaughterTrack, posDauPtEtaBin, negDauPtEtaBin, v0Tag, v0DauCollisionIndexTag, v0DauBCTag, idMethodPi[kPos], idMethodPr[kNeg], v0AntiLambdaEffWeight, fillMotherQA, fillDauTrackQA);
32623258
}
@@ -3269,8 +3265,8 @@ struct KaonIsospinFluctuations {
32693265
BITSET(trueV0TagValue, BIT_IS_GAMMA);
32703266
v0GammaEffWeight = hPtEtaForEffCorrection[kV0Gamma][kPos]->GetBinContent(v0PtEtaBin);
32713267

3272-
v0CndtDauList[kV0TrkGamma][kPos].emplace_back(posDaughterTrack.globalIndex(), std::abs((v0.mGamma() - MV0DecayCndt[kV0TrkGamma]) / WV0DecayCndt[kV0TrkGamma]));
3273-
v0CndtDauList[kV0TrkGamma][kNeg].emplace_back(negDaughterTrack.globalIndex(), std::abs((v0.mGamma() - MV0DecayCndt[kV0TrkGamma]) / WV0DecayCndt[kV0TrkGamma]));
3268+
v0CandtDauList[kV0TrkGamma][kPos].emplace_back(posDaughterTrack.globalIndex(), std::abs((v0.mGamma() - MV0DecayCndt[kV0TrkGamma]) / WV0DecayCndt[kV0TrkGamma]));
3269+
v0CandtDauList[kV0TrkGamma][kNeg].emplace_back(negDaughterTrack.globalIndex(), std::abs((v0.mGamma() - MV0DecayCndt[kV0TrkGamma]) / WV0DecayCndt[kV0TrkGamma]));
32743270
if (cfgFill.cfgFill07V0TablePostGammaCheck) {
32753271
fillV0QA<v0TablePostGammaCheck, kFillSimple, kEl, kEl>(recoV0sPostGammaCheck, v0, posDaughterTrack, negDaughterTrack, posDauPtEtaBin, negDauPtEtaBin, v0Tag, v0DauCollisionIndexTag, v0DauBCTag, idMethodEl[kPos], idMethodEl[kNeg], v0GammaEffWeight, fillMotherQA, fillDauTrackQA);
32763272
}
@@ -3648,7 +3644,7 @@ struct KaonIsospinFluctuations {
36483644

36493645
template <int analysisType, int fillMode, typename P, typename T, typename D, typename B, typename C, typename L>
36503646
void executePrimVtxCndtInCollisionloop(const P& mother, const T& posTrack, const T& negTrack,
3651-
const int& ptEtaBinPosTrk, const int& ptEtaBinNegTrk, int& primVtxCndtTag, L& primVtxCndtDauList, D& idMethodSignTrk,
3647+
const int& ptEtaBinPosTrk, const int& ptEtaBinNegTrk, int& primVtxCndtTag, L& primVtxCandtDauList, D& idMethodSignTrk,
36523648
C& checkTrackId, B& posDauIs, B& negDauIs,
36533649
auto& iNTrkPrim, auto& fNTrkPrim, auto& effWeightSum,
36543650
const auto posTrackPrimVtxMotherFlag, const auto negTrackPrimVtxMotherFlag, const auto posTrackV0MotherFlag, const auto negTrackV0MotherFlag, const int requiredBit, const auto mpBit,
@@ -3697,7 +3693,7 @@ struct KaonIsospinFluctuations {
36973693
// phi(1020) -> K+ + K-
36983694
if (doPhi1020 && posDauIs[kKa] && negDauIs[kKa] && isTrueMcMatch<analysisType>(primVtxCndtMcTag, kPrimPhi1020)) {
36993695
checkPrimVtxParticle<Phi1020, kKa, kKa, fillMode, kPrimTrkPhi1020>(recoPhi1020,
3700-
mother, posTrack, negTrack, primVtxCndtDauList[kPrimTrkPhi1020][kPos], primVtxCndtDauList[kPrimTrkPhi1020][kNeg], primVtxCndtTag,
3696+
mother, posTrack, negTrack, primVtxCandtDauList[kPrimTrkPhi1020][kPos], primVtxCandtDauList[kPrimTrkPhi1020][kNeg], primVtxCndtTag,
37013697
ptEtaBinPosTrk, ptEtaBinNegTrk,
37023698
idMethodSignTrk[kKa][kPos], idMethodSignTrk[kKa][kNeg],
37033699
iNTrkPrim[kPrimPhi1020], fNTrkPrim[kPrimPhi1020], effWeightSum[kPrimPhi1020],
@@ -3708,7 +3704,7 @@ struct KaonIsospinFluctuations {
37083704
// J/ψ -> e+/e-
37093705
if (doJPsiToEE && posDauIs[kEl] && negDauIs[kEl] && isTrueMcMatch<analysisType>(primVtxCndtMcTag, kPrimJPsiToEE)) {
37103706
checkPrimVtxParticle<JPsiToEE, kEl, kEl, fillMode, kPrimTrkJPsiToEE>(recoJPsiToEE,
3711-
mother, posTrack, negTrack, primVtxCndtDauList[kPrimTrkJPsiToEE][kPos], primVtxCndtDauList[kPrimTrkJPsiToEE][kNeg], primVtxCndtTag,
3707+
mother, posTrack, negTrack, primVtxCandtDauList[kPrimTrkJPsiToEE][kPos], primVtxCandtDauList[kPrimTrkJPsiToEE][kNeg], primVtxCndtTag,
37123708
ptEtaBinPosTrk, ptEtaBinNegTrk,
37133709
idMethodSignTrk[kEl][kPos], idMethodSignTrk[kEl][kNeg],
37143710
iNTrkPrim[kPrimJPsiToEE], fNTrkPrim[kPrimJPsiToEE], effWeightSum[kPrimJPsiToEE],
@@ -3719,7 +3715,7 @@ struct KaonIsospinFluctuations {
37193715
// J/ψ -> mu+/mu-
37203716
if (doJPsiToMuMu && posDauIs[kMu] && negDauIs[kMu] && isTrueMcMatch<analysisType>(primVtxCndtMcTag, kPrimJPsiToMuMu)) {
37213717
checkPrimVtxParticle<JPsiToMuMu, kMu, kMu, fillMode, kPrimTrkJPsiToMuMu>(recoJPsiToMuMu,
3722-
mother, posTrack, negTrack, primVtxCndtDauList[kPrimTrkJPsiToMuMu][kPos], primVtxCndtDauList[kPrimTrkJPsiToMuMu][kNeg], primVtxCndtTag,
3718+
mother, posTrack, negTrack, primVtxCandtDauList[kPrimTrkJPsiToMuMu][kPos], primVtxCandtDauList[kPrimTrkJPsiToMuMu][kNeg], primVtxCndtTag,
37233719
ptEtaBinPosTrk, ptEtaBinNegTrk,
37243720
idMethodSignTrk[kMu][kPos], idMethodSignTrk[kMu][kNeg],
37253721
iNTrkPrim[kPrimJPsiToMuMu], fNTrkPrim[kPrimJPsiToMuMu], effWeightSum[kPrimJPsiToMuMu],
@@ -3730,7 +3726,7 @@ struct KaonIsospinFluctuations {
37303726
// K*(892)^0 → K⁺ + π⁻
37313727
if (doKStar892 && posDauIs[kKa] && negDauIs[kPi] && isTrueMcMatch<analysisType>(primVtxCndtMcTag, kPrimKStar892)) {
37323728
checkPrimVtxParticle<KStar892, kKa, kPi, fillMode, kPrimTrkKStar892>(recoKStar892,
3733-
mother, posTrack, negTrack, primVtxCndtDauList[kPrimTrkKStar892][kPos], primVtxCndtDauList[kPrimTrkKStar892][kNeg], primVtxCndtTag,
3729+
mother, posTrack, negTrack, primVtxCandtDauList[kPrimTrkKStar892][kPos], primVtxCandtDauList[kPrimTrkKStar892][kNeg], primVtxCndtTag,
37343730
ptEtaBinPosTrk, ptEtaBinNegTrk,
37353731
idMethodSignTrk[kKa][kPos], idMethodSignTrk[kPi][kNeg],
37363732
iNTrkPrim[kPrimKStar892], fNTrkPrim[kPrimKStar892], effWeightSum[kPrimKStar892],
@@ -3741,7 +3737,7 @@ struct KaonIsospinFluctuations {
37413737
// K*(892)^0-bar → K⁻ + π⁺
37423738
if (doKStar892Bar && posDauIs[kPi] && negDauIs[kKa] && isTrueMcMatch<analysisType>(primVtxCndtMcTag, kPrimKStar892Bar)) {
37433739
checkPrimVtxParticle<KStar892Bar, kPi, kKa, fillMode, kPrimTrkKStar892Bar>(recoKStar892Bar,
3744-
mother, posTrack, negTrack, primVtxCndtDauList[kPrimTrkKStar892Bar][kPos], primVtxCndtDauList[kPrimTrkKStar892Bar][kNeg], primVtxCndtTag,
3740+
mother, posTrack, negTrack, primVtxCandtDauList[kPrimTrkKStar892Bar][kPos], primVtxCandtDauList[kPrimTrkKStar892Bar][kNeg], primVtxCndtTag,
37453741
ptEtaBinPosTrk, ptEtaBinNegTrk,
37463742
idMethodSignTrk[kPi][kPos], idMethodSignTrk[kKa][kNeg],
37473743
iNTrkPrim[kPrimKStar892Bar], fNTrkPrim[kPrimKStar892Bar], effWeightSum[kPrimKStar892Bar],
@@ -3752,7 +3748,7 @@ struct KaonIsospinFluctuations {
37523748
// ρ(770) -> pi+ + pi-
37533749
if (doRho770 && posDauIs[kPi] && negDauIs[kPi] && isTrueMcMatch<analysisType>(primVtxCndtMcTag, kPrimRho770)) {
37543750
checkPrimVtxParticle<Rho770, kPi, kPi, fillMode, kPrimTrkRho770>(recoRho770,
3755-
mother, posTrack, negTrack, primVtxCndtDauList[kPrimTrkRho770][kPos], primVtxCndtDauList[kPrimTrkRho770][kNeg], primVtxCndtTag,
3751+
mother, posTrack, negTrack, primVtxCandtDauList[kPrimTrkRho770][kPos], primVtxCandtDauList[kPrimTrkRho770][kNeg], primVtxCndtTag,
37563752
ptEtaBinPosTrk, ptEtaBinNegTrk,
37573753
idMethodSignTrk[kPi][kPos], idMethodSignTrk[kPi][kNeg],
37583754
iNTrkPrim[kPrimRho770], fNTrkPrim[kPrimRho770], effWeightSum[kPrimRho770],
@@ -3761,7 +3757,7 @@ struct KaonIsospinFluctuations {
37613757
}
37623758
}
37633759

3764-
void getTrackDecayInfoBit(const auto& track, auto& decayDauTagBit, const auto& v0CndtDauList, const auto& primVtxCndtDauList,
3760+
void getTrackDecayInfoBit(const auto& track, auto& decayDauTagBit, const auto& v0CandtDauList, const auto& primVtxCandtDauList,
37653761
bool doV0K0s, bool doV0Lambda, bool doV0AntiLambda, bool doV0Gamma,
37663762
bool doPhi1020, bool doJPsiToEE, bool doJPsiToMuMu, bool doKStar892, bool doKStar892Bar, bool doRho770)
37673763
{
@@ -3773,41 +3769,41 @@ struct KaonIsospinFluctuations {
37733769

37743770
const auto globalIdx = track.globalIndex();
37753771
// V0 channel checks (kPos/kNeg differ by chargeIndex)
3776-
if (doV0K0s && binarySearchAnyList(v0CndtDauList[kV0K0s][chargeIndex], globalIdx) != -1)
3772+
if (doV0K0s && binarySearchAnyList(v0CandtDauList[kV0K0s][chargeIndex], globalIdx) != -1)
37773773
BITSET(decayDauTagBit, IdBitPI);
37783774

37793775
if (doV0Lambda) {
3780-
if (binarySearchAnyList(v0CndtDauList[kV0Lambda][chargeIndex], globalIdx) != -1) {
3776+
if (binarySearchAnyList(v0CandtDauList[kV0Lambda][chargeIndex], globalIdx) != -1) {
37813777
BITSET(decayDauTagBit, (chargeIndex == kPos) ? IdBitPR : IdBitPI);
37823778
}
37833779
}
37843780

37853781
if (doV0AntiLambda) {
3786-
if (binarySearchAnyList(v0CndtDauList[kV0AntiLambda][chargeIndex], globalIdx) != -1) {
3782+
if (binarySearchAnyList(v0CandtDauList[kV0AntiLambda][chargeIndex], globalIdx) != -1) {
37873783
BITSET(decayDauTagBit, (chargeIndex == kPos) ? IdBitPI : IdBitPR);
37883784
}
37893785
}
37903786

3791-
if (doV0Gamma && binarySearchAnyList(v0CndtDauList[kV0Gamma][chargeIndex], globalIdx) != -1)
3787+
if (doV0Gamma && binarySearchAnyList(v0CandtDauList[kV0Gamma][chargeIndex], globalIdx) != -1)
37923788
BITSET(decayDauTagBit, IdBitEL);
37933789

37943790
// PrimVtx candidate decays
3795-
if (doPhi1020 && binarySearchAnyList(primVtxCndtDauList[kPrimTrkPhi1020][chargeIndex], globalIdx) != -1)
3791+
if (doPhi1020 && binarySearchAnyList(primVtxCandtDauList[kPrimTrkPhi1020][chargeIndex], globalIdx) != -1)
37963792
BITSET(decayDauTagBit, IdBitKA);
37973793

3798-
if (doJPsiToEE && binarySearchAnyList(primVtxCndtDauList[kPrimTrkJPsiToEE][chargeIndex], globalIdx) != -1)
3794+
if (doJPsiToEE && binarySearchAnyList(primVtxCandtDauList[kPrimTrkJPsiToEE][chargeIndex], globalIdx) != -1)
37993795
BITSET(decayDauTagBit, IdBitEL);
38003796

3801-
if (doJPsiToMuMu && binarySearchAnyList(primVtxCndtDauList[kPrimTrkJPsiToMuMu][chargeIndex], globalIdx) != -1)
3797+
if (doJPsiToMuMu && binarySearchAnyList(primVtxCandtDauList[kPrimTrkJPsiToMuMu][chargeIndex], globalIdx) != -1)
38023798
BITSET(decayDauTagBit, IdBitMU);
38033799

3804-
if (doKStar892 && binarySearchAnyList(primVtxCndtDauList[kPrimTrkKStar892][chargeIndex], globalIdx) != -1)
3800+
if (doKStar892 && binarySearchAnyList(primVtxCandtDauList[kPrimTrkKStar892][chargeIndex], globalIdx) != -1)
38053801
BITSET(decayDauTagBit, (chargeIndex == kPos) ? IdBitKA : IdBitPI);
38063802

3807-
if (doKStar892Bar && binarySearchAnyList(primVtxCndtDauList[kPrimTrkKStar892Bar][chargeIndex], globalIdx) != -1)
3803+
if (doKStar892Bar && binarySearchAnyList(primVtxCandtDauList[kPrimTrkKStar892Bar][chargeIndex], globalIdx) != -1)
38083804
BITSET(decayDauTagBit, (chargeIndex == kPos) ? IdBitPI : IdBitKA);
38093805

3810-
if (doRho770 && binarySearchAnyList(primVtxCndtDauList[kPrimTrkRho770][chargeIndex], globalIdx) != -1)
3806+
if (doRho770 && binarySearchAnyList(primVtxCandtDauList[kPrimTrkRho770][chargeIndex], globalIdx) != -1)
38113807
BITSET(decayDauTagBit, IdBitPI);
38123808
}
38133809

@@ -4283,7 +4279,7 @@ struct KaonIsospinFluctuations {
42834279
const int pidVecSize = kNKaPosNKaNegProd + 1; // kPrimRho770 is last enum value of different particles. and kNKaPosNKaNegProd is of last count types
42844280
// Variables for collision loop and track counting
42854281
float centrality = 0;
4286-
int nTrack;
4282+
int nTrack = 0;
42874283
std::array<std::array<int, 2>, pidVecSize> iNTrk;
42884284
std::array<std::array<float, 2>, pidVecSize> fNTrk;
42894285
std::array<std::array<float, 2>, pidVecSize> effWeightSum;
@@ -4383,7 +4379,7 @@ struct KaonIsospinFluctuations {
43834379
// Variables for track loop
43844380
int rejectionTag = 0;
43854381
bool isAcceptedTrack = true;
4386-
int nTrack = 0;
4382+
nTrack = 0;
43874383
int trackIdTag = 0;
43884384
int ptEtaBinTrk = -1;
43894385

0 commit comments

Comments
 (0)