Skip to content

Commit 61c494f

Browse files
author
dujw
committed
fix stream
1 parent 262dc4e commit 61c494f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/application/app_yolo_gpuptr/yolo_gpuptr.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -324,6 +324,8 @@ namespace YoloGPUPtr{
324324
checkCudaRuntime(cudaMalloc(&pimage_device, image_data_size));
325325
checkCudaRuntime(cudaMemcpyPeerAsync(pimage_device, tensor->device(), image.device_data, image.device_id, image_data_size, image.stream));
326326
checkCudaRuntime(cudaStreamSynchronize(image.stream));
327+
}else{
328+
tensor->set_stream(image.stream, false);
327329
}
328330

329331
preprocess_stream = tensor->get_stream();

0 commit comments

Comments
 (0)