Skip to content

Commit

Permalink
TPC: Add option to process only single sector
Browse files Browse the repository at this point in the history
  • Loading branch information
davidrohr committed Aug 5, 2023
1 parent efee419 commit 4c5734a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
1 change: 1 addition & 0 deletions GPU/GPUTracking/Definitions/GPUSettingsList.h
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,7 @@ AddOption(lateO2PropagatorProvisioning, bool, false, "", 0, "The user will provi
AddOption(lateO2MatLutProvisioningSize, unsigned int, 0u, "", 0, "Memory size to reserve for late provisioning of matlut table")
AddOption(throttleAlarms, bool, false, "", 0, "Throttle rate at which alarms are sent to the InfoLogger in online runs")
AddOption(outputSanityCheck, bool, false, "", 0, "Run some simple sanity checks finding errors in the output")
AddOption(tpcSingleSector, int, -1, "", 0, "Restrict TPC processing to a single sector")
AddVariable(eventDisplay, GPUCA_NAMESPACE::gpu::GPUDisplayFrontendInterface*, nullptr)
AddSubConfig(GPUSettingsProcessingRTC, rtc)
AddHelp("help", 'h')
Expand Down
17 changes: 11 additions & 6 deletions GPU/GPUTracking/Global/GPUChainTrackingClusterizer.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,9 @@ std::pair<unsigned int, unsigned int> GPUChainTracking::TPCClusterizerDecodeZSCo
unsigned int pageCounter = 0;
unsigned int emptyPages = 0;
for (unsigned int k = 0; k < mIOPtrs.tpcZS->slice[iSlice].count[j]; k++) {
if (GetProcessingSettings().tpcSingleSector != -1 && GetProcessingSettings().tpcSingleSector != iSlice) {
break;
}
nPages += mIOPtrs.tpcZS->slice[iSlice].nZSPtr[j][k];
for (unsigned int l = 0; l < mIOPtrs.tpcZS->slice[iSlice].nZSPtr[j][k]; l++) {
#ifndef GPUCA_NO_VC
Expand Down Expand Up @@ -697,12 +700,14 @@ int GPUChainTracking::RunTPCClusterizer(bool synchronizeOutput)
}
}

if (not mIOPtrs.tpcZS) {
runKernel<GPUTPCCFChargeMapFiller, GPUTPCCFChargeMapFiller::findFragmentStart>(GetGrid(1, lane), {iSlice}, {}, mIOPtrs.tpcZS == nullptr);
TransferMemoryResourceLinkToHost(RecoStep::TPCClusterFinding, clusterer.mMemoryId, lane);
} else if (propagateMCLabels) {
runKernel<GPUTPCCFChargeMapFiller, GPUTPCCFChargeMapFiller::findFragmentStart>(GetGrid(1, lane, GPUReconstruction::krnlDeviceType::CPU), {iSlice}, {}, mIOPtrs.tpcZS == nullptr);
TransferMemoryResourceLinkToGPU(RecoStep::TPCClusterFinding, clusterer.mMemoryId, lane);
if (GetProcessingSettings().tpcSingleSector == -1 || GetProcessingSettings().tpcSingleSector == iSlice) {
if (not mIOPtrs.tpcZS) {
runKernel<GPUTPCCFChargeMapFiller, GPUTPCCFChargeMapFiller::findFragmentStart>(GetGrid(1, lane), {iSlice}, {}, mIOPtrs.tpcZS == nullptr);
TransferMemoryResourceLinkToHost(RecoStep::TPCClusterFinding, clusterer.mMemoryId, lane);
} else if (propagateMCLabels) {
runKernel<GPUTPCCFChargeMapFiller, GPUTPCCFChargeMapFiller::findFragmentStart>(GetGrid(1, lane, GPUReconstruction::krnlDeviceType::CPU), {iSlice}, {}, mIOPtrs.tpcZS == nullptr);
TransferMemoryResourceLinkToGPU(RecoStep::TPCClusterFinding, clusterer.mMemoryId, lane);
}
}

if (mIOPtrs.tpcZS) {
Expand Down

0 comments on commit 4c5734a

Please sign in to comment.