Skip to content

Commit 51d6018

Browse files
committed
fix(tensorrt_yolox): fix cstyleCast to reinterpret_cast
Signed-off-by: Koichi Imai <kotty.0704@gmail.com>
1 parent 4e04402 commit 51d6018

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

perception/tensorrt_yolox/src/tensorrt_yolox.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -1205,8 +1205,8 @@ cv::Mat TrtYoloX::getMaskImageGpu(float * d_prob, nvinfer1::Dims dims, int out_w
12051205
cv::Mat mask = cv::Mat::zeros(out_h, out_w, CV_8UC1);
12061206
int index = b * out_w * out_h;
12071207
argmax_gpu(
1208-
reinterpret_cast<unsigned char *> argmax_buf_d_.get() + index, d_prob, out_w, out_h, width,
1209-
height, classes, 1, *stream_);
1208+
reinterpret_cast<unsigned char*>(argmax_buf_d_.get()) + index, d_prob, out_w, out_h, width, height, classes, 1,
1209+
*stream_);
12101210
CHECK_CUDA_ERROR(cudaMemcpyAsync(
12111211
argmax_buf_h_.get(), argmax_buf_d_.get(), sizeof(unsigned char) * 1 * out_w * out_h,
12121212
cudaMemcpyDeviceToHost, *stream_));

0 commit comments

Comments
 (0)