项目地址:BEVHeight
描述:BEVHeight is a new vision-based 3D object detector specially designed for roadside scenario. BEVHeight surpasses BEVDepth base- line by a margin of 4.85% and 4.43% on DAIR-V2X-I and Rope3D benchmarks under the traditional clean settings, and by 26.88% on robust settings where external camera parameters changes. We hope our work can shed light on studying more effective feature representation on roadside perception.
基本安装
基础环境:Ubuntu 20.04.6 ; RTX3090*2 ; CUDA Version: 12.2
Python版本:3.8 (试了3.7和3.9,都会在安装mmdet3d时遇到llvmlite报错的问题,暂时没能解决)
torch: pip install torch==1.9.0+cu111 torchvision==0.10.0+cu111 torchaudio==0.9.0 -f https://download.pytorch.org/whl/torch_stable.html
mmdet3d相关: pip install mmcv-full==1.4.0 mmdet==2.19.0
mmdet3d==0.18.1.:下载 mmdet3d 0.18.1至服务器,根据mmdet3d安装指导进行安装。
pypcd:git clone https://github.com/klintan/pypcd.git ;cd pypcd ;python setup.py install
BEVHeight:cd 到BEVHeight的文件夹,pip install -r requirements.txt
,python setup.py develop
。
调整
执行完以上步骤,可以顺利进行训练。但是不能正常进行评估。需要执行以下步骤:
出现报错:numba.cuda.cudadrv.error.NvvmError: Failed to compile (66, 23): parse expected comma after load's type NVVM_ERROR_COMPILATION
numba:从0.48.0升级为0.53.0pip install numba==0.53.0
相应的,升级numpy:pip install numpy==1.23.4
由于numba0.53.0实际上与mmdet3d0.18.1不匹配,因此需要对部分代码做调整:
把@numba.jit(nopython=True)
更改为@numba.jit()
,相当于跳过了使用numba加速的步骤。
也有可能出现这个报错,解决办法:IR version 1.6 incompatible with current version 2.0
结果
实测可以正常进行评估:
Car AP@0.70, 0.70, 0.70:
bbox AP:80.3729, 64.7785, 64.7177
bev AP:47.4879, 40.3766, 38.6037
3d AP:16.4351, 16.2231, 16.1463
aos AP:0.64, 0.54, 0.54
Car AP@0.70, 0.50, 0.50:
bbox AP:80.3729, 64.7785, 64.7177
bev AP:80.7049, 64.9141, 64.8302
3d AP:65.6440, 54.3607, 54.2617
aos AP:0.64, 0.54, 0.54
Bus AP@0.70, 0.70, 0.70:
bbox AP:43.8651, 42.5634, 42.6321
bev AP:19.4735, 21.7574, 21.8368
3d AP:6.5327, 9.4566, 9.5421
aos AP:1.19, 1.10, 1.09
Bus AP@0.70, 0.50, 0.50:
bbox AP:43.8651, 42.5634, 42.6321
bev AP:49.2963, 46.6126, 44.4360
3d AP:41.6872, 40.0342, 40.0549
aos AP:1.19, 1.10, 1.09
Overall AP@easy, moderate, hard:
bbox AP:62.1190, 53.6709, 53.6749
bev AP:33.4807, 31.0670, 30.2202
3d AP:11.4839, 12.8398, 12.8442
aos AP:0.91, 0.82, 0.82
以上使用的ckpt是5 epoch的结果。
由于没使用numba加速,所以评估时间相当长,需要接近一小时。