@@ -144,7 +144,10 @@ void TrackerTraitsGPU<nLayers>::computeTrackletsHybrid(const int iteration, int
144144 mTimeFrameGPU ->getDeviceArrayUsedClusters (),
145145 mTimeFrameGPU ->getDeviceArrayClustersIndexTables (),
146146 mTimeFrameGPU ->getDeviceArrayTracklets (),
147+ mTimeFrameGPU ->getDeviceTracklet (),
148+ mTimeFrameGPU ->getNTracklets (),
147149 mTimeFrameGPU ->getDeviceArrayTrackletsLUT (),
150+ mTimeFrameGPU ->getDeviceTrackletsLUTs (),
148151 iteration,
149152 mTrkParams [iteration].NSigmaCut ,
150153 mTimeFrameGPU ->getPhiCuts (),
@@ -161,25 +164,22 @@ void TrackerTraitsGPU<nLayers>::computeTrackletsHybrid(const int iteration, int
161164template <int nLayers>
162165void TrackerTraitsGPU<nLayers>::computeCellsHybrid(const int iteration)
163166{
164- mTimeFrameGPU ->loadTrackletsDevice ();
165- mTimeFrameGPU ->loadTrackletsLUTDevice ();
166167 mTimeFrameGPU ->createCellsLUTDevice ();
167168 auto & conf = o2::its::ITSGpuTrackingParamConfig::Instance ();
168169
169- // #pragma omp parallel for num_threads(nLayers)
170170 for (int iLayer = 0 ; iLayer < mTrkParams [iteration].CellsPerRoad (); ++iLayer) {
171- if (mTimeFrameGPU ->getTracklets ()[iLayer + 1 ]. empty () ||
172- mTimeFrameGPU -> getTracklets ()[iLayer]. empty ()) {
171+ if (! mTimeFrameGPU ->getNTracklets ()[iLayer + 1 ] || ! mTimeFrameGPU -> getNTracklets ()[iLayer]) {
172+ LOGP (info, " continuing here " );
173173 continue ;
174174 }
175-
176- const int currentLayerTrackletsNum{static_cast <int >(mTimeFrameGPU ->getTracklets ()[iLayer]. size () )};
175+ LOGP (info, " +> {} " , mTimeFrameGPU -> getNTracklets ()[iLayer]);
176+ const int currentLayerTrackletsNum{static_cast <int >(mTimeFrameGPU ->getNTracklets ()[iLayer])};
177177 countCellsHandler (mTimeFrameGPU ->getDeviceArrayClusters (),
178178 mTimeFrameGPU ->getDeviceArrayUnsortedClusters (),
179179 mTimeFrameGPU ->getDeviceArrayTrackingFrameInfo (),
180180 mTimeFrameGPU ->getDeviceArrayTracklets (),
181181 mTimeFrameGPU ->getDeviceArrayTrackletsLUT (),
182- mTimeFrameGPU ->getTracklets ()[iLayer]. size () ,
182+ mTimeFrameGPU ->getNTracklets ()[iLayer],
183183 iLayer,
184184 nullptr ,
185185 mTimeFrameGPU ->getDeviceArrayCellsLUT (),
@@ -196,7 +196,7 @@ void TrackerTraitsGPU<nLayers>::computeCellsHybrid(const int iteration)
196196 mTimeFrameGPU ->getDeviceArrayTrackingFrameInfo (),
197197 mTimeFrameGPU ->getDeviceArrayTracklets (),
198198 mTimeFrameGPU ->getDeviceArrayTrackletsLUT (),
199- mTimeFrameGPU ->getTracklets ()[iLayer]. size () ,
199+ mTimeFrameGPU ->getNTracklets ()[iLayer],
200200 iLayer,
201201 mTimeFrameGPU ->getDeviceCells ()[iLayer],
202202 mTimeFrameGPU ->getDeviceArrayCellsLUT (),
@@ -220,7 +220,7 @@ void TrackerTraitsGPU<nLayers>::findCellsNeighboursHybrid(const int iteration)
220220 auto & conf = o2::its::ITSGpuTrackingParamConfig::Instance ();
221221 std::vector<std::vector<std::pair<int , int >>> cellsNeighboursLayer (mTrkParams [iteration].CellsPerRoad () - 1 );
222222 for (int iLayer{0 }; iLayer < mTrkParams [iteration].CellsPerRoad () - 1 ; ++iLayer) {
223- const int nextLayerCellsNum{static_cast <int >(mTimeFrameGPU ->getNCellsDevice ()[iLayer + 1 ])};
223+ const int nextLayerCellsNum{static_cast <int >(mTimeFrameGPU ->getNCells ()[iLayer + 1 ])};
224224 mTimeFrameGPU ->getCellsNeighboursLUT ()[iLayer].clear ();
225225 mTimeFrameGPU ->getCellsNeighboursLUT ()[iLayer].resize (nextLayerCellsNum, 0 );
226226
@@ -283,7 +283,7 @@ void TrackerTraitsGPU<nLayers>::findRoads(const int iteration)
283283 std::vector<int > lastCellId, updatedCellId;
284284 std::vector<CellSeed> lastCellSeed, updatedCellSeed;
285285
286- processNeighbours (startLayer, startLevel, mTimeFrame ->getCells ()[startLayer], lastCellId, updatedCellSeed, updatedCellId);
286+ processNeighbours (startLayer, startLevel, mTimeFrameGPU ->getCells ()[startLayer], lastCellId, updatedCellSeed, updatedCellId);
287287
288288 int level = startLevel;
289289 for (int iLayer{startLayer - 1 }; iLayer > 0 && level > 2 ; --iLayer) {
@@ -337,8 +337,8 @@ void TrackerTraitsGPU<nLayers>::findRoads(const int iteration)
337337 if (track.getClusterIndex (iLayer) == UnusedIndex) {
338338 continue ;
339339 }
340- nShared += int (mTimeFrame ->isClusterUsed (iLayer, track.getClusterIndex (iLayer)));
341- isFirstShared |= !iLayer && mTimeFrame ->isClusterUsed (iLayer, track.getClusterIndex (iLayer));
340+ nShared += int (mTimeFrameGPU ->isClusterUsed (iLayer, track.getClusterIndex (iLayer)));
341+ isFirstShared |= !iLayer && mTimeFrameGPU ->isClusterUsed (iLayer, track.getClusterIndex (iLayer));
342342 }
343343
344344 if (nShared > mTrkParams [0 ].ClusterSharing ) {
@@ -350,8 +350,8 @@ void TrackerTraitsGPU<nLayers>::findRoads(const int iteration)
350350 if (track.getClusterIndex (iLayer) == UnusedIndex) {
351351 continue ;
352352 }
353- mTimeFrame ->markUsedCluster (iLayer, track.getClusterIndex (iLayer));
354- int currentROF = mTimeFrame ->getClusterROF (iLayer, track.getClusterIndex (iLayer));
353+ mTimeFrameGPU ->markUsedCluster (iLayer, track.getClusterIndex (iLayer));
354+ int currentROF = mTimeFrameGPU ->getClusterROF (iLayer, track.getClusterIndex (iLayer));
355355 for (int iR{0 }; iR < 3 ; ++iR) {
356356 if (rofs[iR] == INT_MAX) {
357357 rofs[iR] = currentROF;
@@ -367,7 +367,7 @@ void TrackerTraitsGPU<nLayers>::findRoads(const int iteration)
367367 if (rofs[1 ] != INT_MAX) {
368368 track.setNextROFbit ();
369369 }
370- mTimeFrame ->getTracks (std::min (rofs[0 ], rofs[1 ])).emplace_back (track);
370+ mTimeFrameGPU ->getTracks (std::min (rofs[0 ], rofs[1 ])).emplace_back (track);
371371 }
372372 }
373373 mTimeFrameGPU ->loadUsedClustersDevice ();
0 commit comments