Skip to content

Commit 5a34505

Browse files
mconcasdavidrohr
authored andcommitted
Perform some cleanups
1 parent c98069f commit 5a34505

8 files changed

Lines changed: 5 additions & 29 deletions

File tree

DataFormats/Reconstruction/src/TrackParametrization.cxx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ GPUd() TrackParametrization<value_T>::TrackParametrization(const dim3_t& xyz, co
7171
math_utils::detail::sincos(alp, sn, cs);
7272
// protection against cosp<0
7373
if (cs * pxpypz[0] + sn * pxpypz[1] < 0) {
74-
LOGP(debug, "alpha from phiPos() will invalidate this track parameters, overriding to alpha from phi()");
74+
LOG(debug) << "alpha from phiPos() will invalidate this track parameters, overriding to alpha from phi()";
7575
alp = math_utils::detail::atan2<value_T>(pxpypz[1], pxpypz[0]);
7676
if (sectorAlpha) {
7777
alp = math_utils::detail::angle2Alpha<value_t>(alp);
@@ -182,7 +182,7 @@ GPUd() bool TrackParametrization<value_T>::rotateParam(value_t alpha)
182182
// RS: check if rotation does no invalidate track model (cos(local_phi)>=0, i.e. particle
183183
// direction in local frame is along the X axis
184184
if ((csp * ca + snp * sa) < 0) {
185-
//LOGF(warning,"Rotation failed: local cos(phi) would become {:.2f}", csp * ca + snp * sa);
185+
// LOGF(warning,"Rotation failed: local cos(phi) would become {:.2f}", csp * ca + snp * sa);
186186
return false;
187187
}
188188
//
@@ -382,7 +382,7 @@ GPUd() bool TrackParametrization<value_T>::propagateParamToDCA(const math_utils:
382382
value_t xv = vtx.X() * cs + vtx.Y() * sn, yv = -vtx.X() * sn + vtx.Y() * cs, zv = vtx.Z();
383383
x -= xv;
384384
y -= yv;
385-
//Estimate the impact parameter neglecting the track curvature
385+
// Estimate the impact parameter neglecting the track curvature
386386
value_t d = math_utils::detail::abs<value_T>(x * snp - y * csp);
387387
if (d > maxD) {
388388
return false;

Detectors/ITSMFT/ITS/tracking/GPU/ITStrackingGPU/Vector.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020
#include <new>
2121
#include <type_traits>
2222
#include <vector>
23-
#include <iostream>
2423

2524
#include "Stream.h"
2625
#include "Utils.h"

Detectors/ITSMFT/ITS/tracking/GPU/ITStrackingGPU/VertexerTraitsGPU.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@
2525
#include "ITStracking/Definitions.h"
2626
#include "ITStracking/Tracklet.h"
2727

28-
// #include "DeviceStoreVertexerGPU.h"
29-
#include "UniquePointer.h"
3028
#include "ITStrackingGPU/TimeFrameGPU.h"
3129

3230
namespace o2

Detectors/ITSMFT/ITS/tracking/GPU/hip/CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ if(HIP_ENABLED)
3636
SOURCES ClusterLinesGPU.hip.cxx
3737
Context.hip.cxx
3838
TimeFrameGPU.hip.cxx
39-
# DeviceStoreVertexerGPU.hip.cxx
4039
Stream.hip.cxx
4140
TrackerTraitsGPU.hip.cxx
4241
VertexerTraitsGPU.hip.cxx

Detectors/ITSMFT/ITS/tracking/include/ITStracking/VertexerTraits.h

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@ class VertexerTraits
9393
GPUhd() static const int2 getPhiBins(float phi, float deltaPhi, const IndexTableUtils&);
9494

9595
// virtual vertexer interface
96-
// virtual void reset();
9796
virtual void initialise(const MemoryParameters& memParams, const TrackingParameters& trackingParams);
9897
virtual void computeTracklets();
9998
virtual void computeTrackletMatching();
@@ -127,25 +126,14 @@ class VertexerTraits
127126

128127
protected:
129128
unsigned char mIsGPU;
130-
131-
// std::vector<Line> mTracklets;
132-
// std::vector<Tracklet> mComb01;
133-
// std::vector<Tracklet> mComb12;
134-
// std::vector<int> mFoundTracklets01;
135-
// std::vector<int> mFoundTracklets12;
136-
// std::array<std::vector<Cluster>, constants::its::LayersNumberVertexer> mClusters;
137-
138129
unsigned int mDBGFlags = 0;
139130

140131
VertexingParameters mVrtParams;
141132
IndexTableUtils mIndexTableUtils;
142-
// std::array<std::vector<int>, LayersNumberVertexer> mIndexTables;
143133
std::vector<lightVertex> mVertices;
144134

145135
// Frame related quantities
146-
// std::array<std::vector<unsigned char>, 2> mUsedClusters;
147136
TimeFrame* mTimeFrame = nullptr;
148-
// std::vector<ClusterLines> mTrackletClusters;
149137
};
150138

151139
inline void VertexerTraits::initialise(const MemoryParameters& memParams, const TrackingParameters& trackingParams)
@@ -164,9 +152,6 @@ inline void VertexerTraits::updateVertexingParameters(const VertexingParameters&
164152
mVrtParams.phiSpan = static_cast<int>(std::ceil(mIndexTableUtils.getNphiBins() * mVrtParams.phiCut /
165153
constants::math::TwoPi));
166154
mVrtParams.zSpan = static_cast<int>(std::ceil(mVrtParams.zCut * mIndexTableUtils.getInverseZCoordinate(0)));
167-
// for (auto& table : mIndexTables) {
168-
// table.resize(mIndexTableUtils.getNphiBins() * mIndexTableUtils.getNzBins() + 1, 0);
169-
// }
170155
}
171156

172157
GPUhdi() const int2 VertexerTraits::getPhiBins(float phi, float dPhi)

Detectors/ITSMFT/ITS/tracking/src/Tracker.cxx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ Tracker::Tracker(o2::its::TrackerTraits* traits)
4545
}
4646

4747
Tracker::~Tracker() = default;
48-
#endif
4948

5049
void Tracker::clustersToTracks(std::function<void(std::string s)> logger, std::function<void(std::string s)> error)
5150
{

GPU/GPUTracking/Base/cuda/GPUReconstructionCUDA.cu

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -439,9 +439,7 @@ size_t GPUReconstructionCUDA::GPUMemCpy(void* dst, const void* src, size_t size,
439439
for (int k = 0; k < nEvents; k++) {
440440
GPUFailedMsg(cudaStreamWaitEvent(mInternals->Streams[stream], ((cudaEvent_t*)evList)[k], 0));
441441
}
442-
GPUFailedMsg(cudaMemcpyAsync(dst, src, size, toGPU == -2 ? cudaMemcpyDeviceToDevice : toGPU ? cudaMemcpyHostToDevice
443-
: cudaMemcpyDeviceToHost,
444-
mInternals->Streams[stream]));
442+
GPUFailedMsg(cudaMemcpyAsync(dst, src, size, toGPU == -2 ? cudaMemcpyDeviceToDevice : toGPU ? cudaMemcpyHostToDevice : cudaMemcpyDeviceToHost, mInternals->Streams[stream]));
445443
}
446444
if (ev) {
447445
GPUFailedMsg(cudaEventRecord(*(cudaEvent_t*)ev, mInternals->Streams[stream == -1 ? 0 : stream]));

GPU/GPUTracking/Base/hip/GPUReconstructionHIP.hip.cxx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -473,9 +473,7 @@ size_t GPUReconstructionHIPBackend::GPUMemCpy(void* dst, const void* src, size_t
473473
for (int k = 0; k < nEvents; k++) {
474474
GPUFailedMsg(hipStreamWaitEvent(mInternals->Streams[stream], ((hipEvent_t*)evList)[k], 0));
475475
}
476-
GPUFailedMsg(hipMemcpyAsync(dst, src, size, toGPU == -2 ? hipMemcpyDeviceToDevice : toGPU ? hipMemcpyHostToDevice
477-
: hipMemcpyDeviceToHost,
478-
mInternals->Streams[stream]));
476+
GPUFailedMsg(hipMemcpyAsync(dst, src, size, toGPU == -2 ? hipMemcpyDeviceToDevice : toGPU ? hipMemcpyHostToDevice : hipMemcpyDeviceToHost, mInternals->Streams[stream]));
479477
}
480478
if (ev) {
481479
GPUFailedMsg(hipEventRecord(*(hipEvent_t*)ev, mInternals->Streams[stream == -1 ? 0 : stream]));

0 commit comments

Comments
 (0)