Home

Awesome

FocalFormer3D: Focusing on Hard Instance for 3D Object Detection

FocalFormer3D: Focusing on Hard Instance for 3D Object Detection, ICCV 2023.

Yilun Chen, Zhiding Yu, Yukang Chen, Shiyi Lan, Anima Anandkumar, Jiaya Jia, Jose M. Alvarez

[Paper]

Abstract

False negatives (FN) in 3D object detection, {\em e.g.}, missing predictions of pedestrians, vehicles, or other obstacles, can lead to potentially dangerous situations in autonomous driving. While being fatal, this issue is understudied in many current 3D detection methods. In this work, we propose Hard Instance Probing (HIP), a general pipeline that identifies \textit{FN} in a multi-stage manner and guides the models to focus on excavating difficult instances. For 3D object detection, we instantiate this method as FocalFormer3D, a simple yet effective detector that excels at excavating difficult objects and improving prediction recall. FocalFormer3D features a multi-stage query generation to discover hard objects and a box-level transformer decoder to efficiently distinguish objects from massive object candidates. Experimental results on the nuScenes and Waymo datasets validate the superior performance of FocalFormer3D. The advantage leads to strong performance on both detection and tracking, in both LiDAR and multi-modal settings. Notably, FocalFormer3D achieves a 70.5 mAP and 73.9 NDS on nuScenes detection benchmark, while the nuScenes tracking benchmark shows 72.1 AMOTA, both ranking 1st place on the nuScenes LiDAR leaderboard.

Hard Instance Probing

<div align='center'> <img src="./doc/hip.png" height="360px" width="460px"> </div>

News

Results

3D Object Detection (nuScenes Detection & Tracking Leaderboard)

ModelModalitymAPNDSAMOTAResult Files
FocalFormer3D-FC+L72.474.573.9Detection / Tracking
FocalFormer3DL68.772.671.5Detection / Tracking
FocalFormer3D-TTAL70.573.972.1Detection / Tracking

3D Object Detection (on nuScenes validation set)

ModelModalitymAPNDSCheckpoint
FocalFormer3D-FC+L70.573.1FocalFormer3D_LC.pth
FocalFormer3DL66.470.9FocalFormer3D_L.pth
DeformFormer3DL65.570.7DeformFormer3D_L.pth
DeformFormer3D-R50C30.036.3DeformFormer3D_C_R50.pth

3D Object Detection (on Waymo validation set)

Since WOD does not allow distributing the pretrained weights, we only report the model results trained on the full training split and 20% training split of the Waymo dataset. The official metrics mAP/mAPH on the Waymo validation set are reported as follows.

ModelModalityOverall_L2Veh_L2Ped_L2Cyc_L2
FocalFormer3D (1/5 split)L68.1 / 65.666.4 / 65.969.0 / 62.869.0 / 67.9
DeformFormer3D (1/5 split)L67.2 / 64.565.8 / 65.368.3 / 61.967.4 / 66.4
FocalFormer3DL71.5 / 69.068.1 / 67.672.7 / 66.873.7 / 72.6
DeformFormer3DL70.9 / 68.467.7 / 67.372.4 / 66.472.6 / 71.4

Get Started

a. Installation and data preparation.

This implementation is build upon mmdetection3d, please follow the steps in install.md to prepare the environment.

b. Get the pretrained nuImage-pretrained image backbone weights. Downloads the pretrained backbone weights to pretrained/.

c. Train and evaluation.

# First, train deformformer3d with 8 GPUs
bash tools/dist_train.sh projects/configs/focalformer3d/DeformFormer3D_L.py 8
# Second, finetune focalformer3d with 8 GPUs
bash tools/dist_train.sh projects/configs/focalformer3d/FocalFormer3D_L.py 8
# Third, test with 8 GPUs
bash tools/dist_test.sh projects/configs/focalformer3d/FocalFormer3D_L.py ${CHECKPOINT_FILE} 8 

d. For Test-time Aug

The test-time augmentation configuration can be found in FocalFormer3D_LC_TTA.py. Available augmentations include double-flipping and 3-scale scaling.

e. For Submission

Update your configuration file and re-train the model, follow these steps:

  1. Replace all instances of xxx_train.pkl with xxx_trainval.pkl in the config file.
  2. Retrain the model using the procedure detailed above.

At the inference stage,

  1. Substitute all instances of xxx_val.pkl with xxx_test.pkl in the config file.
  2. Execute the following command:
# test with 8 GPUs
bash tools/dist_test.sh projects/configs/focalformer3d/FocalFormer3D_L.py ${CHECKPOINT_FILE} 8 --format-only

The test results will be saved in the ./work_dirs/submissions/ directory, as specified in tools/test.py.

TODO

Acknowledgement

Many thanks to the following open-source projects:

LICENSE

Copyright © 2023, NVIDIA Corporation. All rights reserved.

This work is made available under the Nvidia Source Code License-NC. Click here to view a copy of this license.

The pre-trained models are shared under CC-BY-NC-SA-4.0. If you remix, transform, or build upon the material, you must distribute your contributions under the same license as the original.

For business inquiries, please visit our website and submit the form: NVIDIA Research Licensing

Reference

@InProceedings{focalformer3d,
  title={FocalFormer3D: Focusing on Hard Instance for 3D Object Detection},
  author={Chen, Yilun and Yu, Zhiding and Chen, Yukang and Lan, Shiyi and Anandkumar, Anima and Jia, Jiaya and Alvarez, Jose M},
  journal={ICCV},
  year={2023}
}