fatal: not a git repository (or any parent up to mount point /home)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
sys.platform: linux
Python: 3.8.16 (default, Mar 2 2023, 03:21:46) [GCC 11.2.0]
CUDA available: True
GPU 0,1,2,3,4,5,6,7: NVIDIA GeForce RTX 3090
CUDA_HOME: /usr/local/cuda-11.1
NVCC: Cuda compilation tools, release 11.1, V11.1.74
GCC: gcc (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0
PyTorch: 1.9.0+cu111
PyTorch compiling details: PyTorch built with:
GCC 7.3
C++ Version: 201402
Intel(R) Math Kernel Library Version 2020.0.0 Product Build 20191122 for Intel(R) 64 architecture applications
in my opinion, the transform_matrix in code2 can directly transform the points from lidar coordinate into img coordinate, which is similar with the transformation in code1, and interestingly, I get a correct visualization too
so I think the BUG is in Box3DMode.convert or draw_camera_bbox3d_on_img, but I read the source code of Box3DMode.convert, the transformation in code is correct, so I think there are something wrong in draw_camera_bbox3d_on_img.
Prerequisite
Task
I'm using the official example scripts/configs for the officially supported tasks/models/datasets.
Branch
master branch https://github.com/open-mmlab/mmdetection3d
Environment
fatal: not a git repository (or any parent up to mount point /home) Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set). sys.platform: linux Python: 3.8.16 (default, Mar 2 2023, 03:21:46) [GCC 11.2.0] CUDA available: True GPU 0,1,2,3,4,5,6,7: NVIDIA GeForce RTX 3090 CUDA_HOME: /usr/local/cuda-11.1 NVCC: Cuda compilation tools, release 11.1, V11.1.74 GCC: gcc (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0 PyTorch: 1.9.0+cu111 PyTorch compiling details: PyTorch built with:
TorchVision: 0.10.0+cu111 OpenCV: 4.7.0 MMCV: 1.5.2 MMCV Compiler: GCC 7.3 MMCV CUDA Compiler: 11.1 MMDetection: 2.28.2 MMSegmentation: 0.30.0 MMDetection3D: 1.0.0rc6+ spconv2.0: False
Reproduces the problem - code sample
Reproduces the problem - command or script
Reproduces the problem - error message
when I visualize CameraInstance3DBoxes converted by function Box3DMode.convert from LiDARInstance3DBoxes, I get a wrong visualization
but when I directly visualize LiDARInstance3DBoxes, I get a correct visualization
then in order to find the bug, I change the code1 to code2
####### code1 ######## drawed_img = draw_camera_bbox3d_on_img( pred_bboxes_in_cam, img, cam_intrinsics, img_metas={}, color=(241, 101, 72), thickness=1 ) ####################
####### code2 ######## drawed_img = draw_camera_bbox3d_on_img( pred_lidar_ins_3dbbox, img, np.dot(cam_intrinsics, cam_extrinsics.T), img_metas={}, color=(241, 101, 72), thickness=1 ) ####################
in my opinion, the transform_matrix in code2 can directly transform the points from lidar coordinate into img coordinate, which is similar with the transformation in code1, and interestingly, I get a correct visualization too
so I think the BUG is in Box3DMode.convert or draw_camera_bbox3d_on_img, but I read the source code of Box3DMode.convert, the transformation in code is correct, so I think there are something wrong in draw_camera_bbox3d_on_img.
please help me solve this bug, thanks a lot!
Additional information
No response