Skip to content

Commit 0cb5fc5

Browse files
committed
GPU TPC: Better formula for cluster weights
1 parent ef6e9a0 commit 0cb5fc5

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

GPU/GPUTracking/SectorTracker/GPUTPCTracker.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -160,13 +160,11 @@ class GPUTPCTracker : public GPUProcessor
160160
*/
161161
GPUdi() static int32_t CalculateHitWeight(int32_t NHits, float chi2)
162162
{
163-
const float chi2_suppress = 6.f;
164-
float weight = (((float)NHits * (chi2_suppress - chi2 / 500.f)) * (1e9f / chi2_suppress / 160.f));
163+
float weight = NHits * (NHits * 2 - 5) * 128 / chi2; // TODO: Add QPt to this formula
165164
if (weight < 0.f || weight > 2e9f) {
166165
return 0;
167166
}
168167
return ((int32_t)weight);
169-
// return( (NHits << 16) + num);
170168
}
171169
GPUd() void MaximizeHitWeight(const GPUTPCRow& row, int32_t hitIndex, int32_t weight) { mData.MaximizeHitWeight(row, hitIndex, weight); }
172170
GPUd() void SetHitWeight(const GPUTPCRow& row, int32_t hitIndex, int32_t weight) { mData.SetHitWeight(row, hitIndex, weight); }

0 commit comments

Comments
 (0)