This repository includes the official implementation of the paper:
Robust Object Detection With Inaccurate Bounding Boxes
European Conference on Computer Vision (ECCV), 2022
Chengxin Liu1, Kewei Wang1, Hao Lu1, Zhiguo Cao1, and Ziming Zhang2
1Huazhong University of Science and Technology, China
2Worcester Polytechnic Institute, USA
# env
conda create -n oamil python=3.7
conda activate oamil
# install pytorch
conda install pytorch==1.10.0 torchvision==0.11.0 -c pytorch -c conda-forge
# clone
git clone https://github.com/cxliu0/OA-MIL.git
cd OA-MIL
# install dependecies
pip install -r requirements/build.txt
# install mmcv (will take a while to process)
cd mmcv
MMCV_WITH_OPS=1 pip install -e .
# install OA-MIL
cd ..
pip install -e .
OA-MIL
├── data
│ ├── VOCdevkit
│ │ ├── VOC2007
│ │ ├── Annotations
│ │ ├── ImageSets
│ │ ├── JPEGImages
│ ├── coco
│ ├── train2017
│ ├── val2017
│ ├── annotations
│ ├── instances_train2017.json
│ ├── instances_val2017.json
├── configs
├── mmcv
├── ...
# generate noisy VOC2007 (e.g., 40% noise)
python ./utils/gen_noisy_voc.py --box_noise_level 0.4
# generate noisy COCO (e.g., 40% noise)
python ./utils/gen_noisy_coco.py --box_noise_level 0.4
All models of OA-MIL are trained with a total batch size of 16.
sh train_voc07.sh
Please refer to faster_rcnn_r50_fpn_voc_oamil.py for model configuration
sh train_coco.sh
Please refer to faster_rcnn_r50_fpn_coco_oamil.py for model configuration
/path/to/model_config
: modify it to the path of model config, e.g., ./configs/faster_rcnn/faster_rcnn_r50_fpn_1x_voc_oamil.py
/path/to/model_checkpoint
: modify it to the path of model checkpoint
sh test.sh
Yes, OA-MIL is applicable to clean data. Here we show some results on the clean VOC2007 and COCO datasets:
Method | mAP@0.5 |
---|---|
FasterRCNN | 77.2 |
OA-MIL FasterRCNN | 78.6 |
Method | AP | AP50 | AP75 |
---|---|---|---|
FasterRCNN | 37.9 | 58.1 | 40.9 |
OA-MIL FasterRCNN | 38.1 | 58.1 | 41.4 |
If you find this work or code useful for your research, please consider citing:
@inproceedings{liu2022oamil,
title={Robust Object Detection With Inaccurate Bounding Boxes},
author={Liu, Chengxin and Wang, Kewei and Lu, Hao and Cao, Zhiguo and Zhang, Ziming},
booktitle={Proceeding of European Conference on Computer Vision (ECCV)},
year={2022}
}
This repository is based on mmdetection.