Skip to content

Commit 37468c1

Browse files
committed
Fix HMPID matching (reset all caches)
1 parent d72165d commit 37468c1

2 files changed

Lines changed: 2 additions & 9 deletions

File tree

Detectors/GlobalTracking/include/GlobalTracking/MatchHMP.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,14 +183,11 @@ class MatchHMP
183183

184184
///>>>------ these are input arrays which should not be modified by the matching code
185185
// since this info is provided by external device
186-
std::vector<o2::dataformats::TrackTPCITS> mITSTPCTracksArrayInp; ///< input tracks
187186
gsl::span<const Cluster> mHMPClustersArray; ///< input HMPID clusters
188187
gsl::span<const Trigger> mHMPTriggersArray; ///< input HMPID triggers
189188

190189
const o2::dataformats::MCTruthContainer<o2::MCCompLabel>* mHMPClusLabels; ///< input HMP clusters MC labels (pointer to read from tree)
191190

192-
int mNotPropagatedToHMP[o2::globaltracking::MatchHMP::trackType::SIZE]; ///< number of tracks failing in propagation
193-
194191
///< working copy of the input tracks
195192
std::vector<matchTrack> mTracksWork[o2::globaltracking::MatchHMP::trackType::SIZE]; ///< track params prepared for matching + time value
196193
std::vector<Trigger> mHMPTriggersWork;

Detectors/GlobalTracking/src/MatchHMP.cxx

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,11 @@ void MatchHMP::run(const o2::globaltracking::RecoContainer& inp)
6969
mStartIR = inp.startIR;
7070

7171
for (int i = 0; i < o2::globaltracking::MatchHMP::trackType::SIZE; i++) {
72+
mTrackGid[i].clear();
7273
mMatchedTracks[i].clear();
7374
mOutHMPLabels[i].clear();
7475
mTracksWork[i].clear();
76+
mMatchedTracksIndex[i].clear();
7577
}
7678

7779
for (int it = 0; it < o2::globaltracking::MatchHMP::trackType::SIZE; it++) {
@@ -111,17 +113,13 @@ void MatchHMP::run(const o2::globaltracking::RecoContainer& inp)
111113
//==================================================================================================================================================
112114
bool MatchHMP::prepareTracks()
113115
{
114-
// mNotPropagatedToHMP[trkType::UNCONS] = 0;
115-
// mNotPropagatedToHMP[trkType::CONSTR] = 0;
116116

117117
auto creator = [this](auto& trk, GTrackID gid, float time0, float terr) {
118118
const int nclustersMin = 0;
119-
120119
if constexpr (isTPCTrack<decltype(trk)>()) {
121120
if (trk.getNClusters() < nclustersMin) {
122121
return true;
123122
}
124-
125123
if (std::abs(trk.getQ2Pt()) > mMaxInvPt) {
126124
return true;
127125
}
@@ -152,7 +150,6 @@ bool MatchHMP::prepareTracks()
152150
// Unconstrained tracks
153151
/*
154152
if (mIsTPCused) {
155-
// LOG(debug) << "Number of UNCONSTRAINED tracks that failed to be propagated to HMPID = " << mNotPropagatedToHMP[o2::globaltracking::MatchHMP::trackType::UNCONS];
156153
157154
// sort tracks in each sector according to their time (increasing in time)
158155
// for (int sec = o2::constants::math::NSectors; sec--;) {
@@ -417,7 +414,6 @@ void MatchHMP::doMatching()
417414
matching.setIdxHMPClus(99, 99999); // chamber not found, mip not yet considered
418415
matching.setHMPsignal(Recon::kNotPerformed); // ring reconstruction not yet performed
419416
matching.setIdxTrack(trackGid);
420-
421417
TrackHMP hmpTrk(trefTrk); // create a hmpid track to be used for propagation and matching
422418

423419
hmpTrk.set(trefTrk.getX(), trefTrk.getAlpha(), trefTrk.getParams(), trefTrk.getCharge(), trefTrk.getPID());

0 commit comments

Comments
 (0)