Skip to content

Commit 22e2e61

Browse files
fweigdavidrohr
authored andcommitted
GPU: Implement TPC timebin cut.
1 parent d99e306 commit 22e2e61

File tree

4 files changed

+185
-169
lines changed

4 files changed

+185
-169
lines changed

GPU/GPUTracking/Global/GPUChainTrackingClusterizer.cxx

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,8 @@ int32_t GPUChainTracking::RunTPCClusterizer(bool synchronizeOutput)
588588
return ForwardTPCDigits();
589589
}
590590
#ifdef GPUCA_TPC_GEOMETRY_O2
591-
[[maybe_unused]] int32_t tpcTimeBinCut = (mUpdateNewCalibObjects && mNewCalibValues->newTPCTimeBinCut) ? mNewCalibValues->tpcTimeBinCut : param().tpcCutTimeBin; // TODO: Implement time bin cut fultering
591+
int32_t tpcTimeBinCut = (mUpdateNewCalibObjects && mNewCalibValues->newTPCTimeBinCut) ? mNewCalibValues->tpcTimeBinCut : param().tpcCutTimeBin;
592+
592593
mRec->PushNonPersistentMemory(qStr2Tag("TPCCLUST"));
593594
const auto& threadContext = GetThreadContext();
594595
const bool doGPU = GetRecoStepsGPU() & RecoStep::TPCClusterFinding;
@@ -911,13 +912,13 @@ int32_t GPUChainTracking::RunTPCClusterizer(bool synchronizeOutput)
911912
break;
912913
case ZSVersionRowBased10BitADC:
913914
case ZSVersionRowBased12BitADC:
914-
runKernel<GPUTPCCFDecodeZS>({GetGridBlk(nBlocks, lane), {iSector}}, firstHBF);
915+
runKernel<GPUTPCCFDecodeZS>({GetGridBlk(nBlocks, lane), {iSector}}, firstHBF, tpcTimeBinCut);
915916
break;
916917
case ZSVersionLinkBasedWithMeta:
917-
runKernel<GPUTPCCFDecodeZSLink>({GetGridBlk(nBlocks, lane), {iSector}}, firstHBF);
918+
runKernel<GPUTPCCFDecodeZSLink>({GetGridBlk(nBlocks, lane), {iSector}}, firstHBF, tpcTimeBinCut);
918919
break;
919920
case ZSVersionDenseLinkBased:
920-
runKernel<GPUTPCCFDecodeZSDenseLink>({GetGridBlk(nBlocks, lane), {iSector}}, firstHBF);
921+
runKernel<GPUTPCCFDecodeZSDenseLink>({GetGridBlk(nBlocks, lane), {iSector}}, firstHBF, tpcTimeBinCut);
921922
break;
922923
}
923924
TransferMemoryResourceLinkToHost(RecoStep::TPCClusterFinding, clusterer.mMemoryId, lane);
@@ -1273,6 +1274,11 @@ int32_t GPUChainTracking::RunTPCClusterizer(bool synchronizeOutput)
12731274
mTriggerBuffer->triggers.clear();
12741275
}
12751276

1277+
// Number of clusters is logged by tracking. This ensures clusters are still printed if it's not running
1278+
if (!(GetRecoSteps() & GPUDataTypes::RecoStep::TPCSectorTracking)) {
1279+
GPUInfo("Event has %zu TPC Clusters", nClsTotal);
1280+
}
1281+
12761282
ClusterNativeAccess::ConstMCLabelContainerView* mcLabelsConstView = nullptr;
12771283
if (propagateMCLabels) {
12781284
// TODO: write to buffer directly

0 commit comments

Comments
 (0)