From 8850b86519e7daf1e0ac95b948901610cfb3af1f Mon Sep 17 00:00:00 2001 From: Abraham Monrroy Cano Date: Tue, 27 Aug 2024 13:06:46 +0900 Subject: [PATCH] fix: cpp17 namespaces (#8526) Use traditional-style nameplace nesting for nvcc Signed-off-by: Yuri Guimaraes Co-authored-by: Yuri Guimaraes --- .../include/autoware/tensorrt_yolox/preprocess.hpp | 7 +++++-- perception/autoware_tensorrt_yolox/src/preprocess.cu | 7 +++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/perception/autoware_tensorrt_yolox/include/autoware/tensorrt_yolox/preprocess.hpp b/perception/autoware_tensorrt_yolox/include/autoware/tensorrt_yolox/preprocess.hpp index 947d6cc6ecc95..7971fbd815deb 100644 --- a/perception/autoware_tensorrt_yolox/include/autoware/tensorrt_yolox/preprocess.hpp +++ b/perception/autoware_tensorrt_yolox/include/autoware/tensorrt_yolox/preprocess.hpp @@ -21,7 +21,9 @@ #include #include -namespace autoware::tensorrt_yolox +namespace autoware +{ +namespace tensorrt_yolox { struct Roi { @@ -195,5 +197,6 @@ extern void multi_scale_resize_bilinear_letterbox_nhwc_to_nchw32_batch_gpu( extern void argmax_gpu( unsigned char * dst, float * src, int d_w, int d_h, int s_w, int s_h, int s_c, int batch, cudaStream_t stream); -} // namespace autoware::tensorrt_yolox +} // namespace tensorrt_yolox +} // namespace autoware #endif // AUTOWARE__TENSORRT_YOLOX__PREPROCESS_HPP_ diff --git a/perception/autoware_tensorrt_yolox/src/preprocess.cu b/perception/autoware_tensorrt_yolox/src/preprocess.cu index ba9d456f32749..6e8ded20df709 100644 --- a/perception/autoware_tensorrt_yolox/src/preprocess.cu +++ b/perception/autoware_tensorrt_yolox/src/preprocess.cu @@ -21,7 +21,9 @@ #define MIN(x, y) x < y ? x : y -namespace autoware::tensorrt_yolox +namespace autoware +{ +namespace tensorrt_yolox { constexpr size_t block = 512; @@ -629,4 +631,5 @@ void argmax_gpu( N, dst, src, d_h, d_w, s_c, s_h, s_w, batch); } -} // namespace autoware::tensorrt_yolox +} // namespace tensorrt_yolox +} // namespace autoware