OpenMMLab Detection Toolbox and Benchmark https://mmdetection.readthedocs.io/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
5.4 KiB

# Feature Selective Anchor-Free Module for Single-Shot Object Detection
add abstract and sketch to the CONFIGS/algorithm/README.md (#6654) * Fix mosaic repr typo (#6523) * Include mmflow in readme (#6545) * Include mmflow in readme * Include mmflow in README_zh-CN * Add mmflow url into the document menu in docs/conf.py and docs_zh-CN/conf.py. * Make OHEM work with seesaw loss (#6514) * [Enhance] Support file_client in Datasets and evaluating panoptic results on Ceph (#6489) * first version * Replace with our api * Add copyright * Move the runtime error to multi_core interface * Add docstring * Fix comments * Add comments * Add unit test for pq_compute_single_core * Fix MMDetection model to ONNX command (#6558) * Update README.md (#6567) * [Feature] Support custom persistent_workers (#6435) * Fix aug test error when the number of prediction bboxes is 0 (#6398) * Fix aug test error when the number of prediction bboxes is 0 * test * test * fix lint * Support custom pin_memory and persistent_workers * fix comment * fix docstr * remove pin_memory * Fix SSD512 config error (#6574) * Fix mosaic repr typo (#6523) * Include mmflow in readme (#6545) * Include mmflow in readme * Include mmflow in README_zh-CN * Add mmflow url into the document menu in docs/conf.py and docs_zh-CN/conf.py. * Make OHEM work with seesaw loss (#6514) * Fix ssd512 config error Co-authored-by: Kyungmin Lee <30465912+lkm2835@users.noreply.github.com> Co-authored-by: Czm369 <40661020+Czm369@users.noreply.github.com> Co-authored-by: ohwi <supebulous@gmail.com> * Catch symlink failure on Windows (#6482) * Catch symlink failure on Windows Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * Set copy mode on Windows Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * Fix lint Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * Fix logic error Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * [Feature] Support Label Assignment Distillation (LAD) (#6342) * add LAD * inherit LAD from KnowledgeDistillationSingleStageDetector * add configs/lad/lad_r101_paa_r50_fpn_coco_1x.py * update LAD readme * update configs/lad/README.md * try not to use abbreviations for variable names * add unittest for lad_head * update test_lad_head * remove main in tests/test_models/test_dense_heads/test_lad_head.py * [Fix] Avoid infinite GPU waiting in dist training (#6501) * [#6495] fix infinite GPU waiting in dist training * print log_vars keys in assertion msg * linting issue * Support to collect the best models (#6560) * Fix mosaic repr typo (#6523) * Include mmflow in readme (#6545) * Include mmflow in readme * Include mmflow in README_zh-CN * Add mmflow url into the document menu in docs/conf.py and docs_zh-CN/conf.py. * Make OHEM work with seesaw loss (#6514) * update * support gather best model Co-authored-by: Kyungmin Lee <30465912+lkm2835@users.noreply.github.com> Co-authored-by: Czm369 <40661020+Czm369@users.noreply.github.com> Co-authored-by: ohwi <supebulous@gmail.com> * [Enhance]: Optimize augmentation pipeline to speed up training. (#6442) * Refactor YOLOX (#6443) * Fix aug test error when the number of prediction bboxes is 0 (#6398) * Fix aug test error when the number of prediction bboxes is 0 * test * test * fix lint * Support custom pin_memory and persistent_workers * [Docs] Chinese version of robustness_benchmarking.md (#6375) * Chinese version of robustness_benchmarking.md * Update docs_zh-CN/robustness_benchmarking.md Co-authored-by: RangiLyu <lyuchqi@gmail.com> * Update docs_zh-CN/robustness_benchmarking.md Co-authored-by: RangiLyu <lyuchqi@gmail.com> * Update docs_zh-CN/robustness_benchmarking.md Co-authored-by: RangiLyu <lyuchqi@gmail.com> * Update docs_zh-CN/robustness_benchmarking.md Co-authored-by: RangiLyu <lyuchqi@gmail.com> * Update docs_zh-CN/robustness_benchmarking.md Co-authored-by: RangiLyu <lyuchqi@gmail.com> * Update docs_zh-CN/robustness_benchmarking.md Co-authored-by: RangiLyu <lyuchqi@gmail.com> * Update robustness_benchmarking.md * Update robustness_benchmarking.md * Update robustness_benchmarking.md * Update robustness_benchmarking.md * Update robustness_benchmarking.md * Update robustness_benchmarking.md Co-authored-by: RangiLyu <lyuchqi@gmail.com> * update yolox_s * update yolox_s * support dynamic eval interval * fix some error * support ceph * fix none error * fix batch error * replace resize * fix comment * fix docstr * Update the link of checkpoints (#6460) * [Feature]: Support plot confusion matrix. (#6344) * remove pin_memory * update * fix unittest * update cfg * fix error * add unittest * [Fix] Fix SpatialReductionAttention in PVT. (#6488) * [Fix] Fix SpatialReductionAttention in PVT * Add warning * Save coco summarize print information to logger (#6505) * Fix type error in 2_new_data_mode (#6469) * Always map location to cpu when load checkpoint (#6405) * configs: update groie README (#6401) Signed-off-by: Leonardo Rossi <leonardo.rossi@unipr.it> * [Fix] fix config path in docs (#6396) * [Enchance] Set a random seed when the user does not set a seed. (#6457) * fix random seed bug * add comment * enchance random seed * rename Co-authored-by: Haobo Yuan <yuanhaobo@whu.edu.cn> * [BugFixed] fix wrong trunc_normal_init use (#6432) * fix wrong trunc_normal_init use * fix wrong trunc_normal_init use * fix #6446 Co-authored-by: Uno Wu <st9007a@gmail.com> Co-authored-by: Leonardo Rossi <leonardo.rossi@unipr.it> Co-authored-by: BigDong <yudongwang@tju.edu.cn> Co-authored-by: Haian Huang(深度眸) <1286304229@qq.com> Co-authored-by: Haobo Yuan <yuanhaobo@whu.edu.cn> Co-authored-by: Shusheng Yang <shusheng.yang@qq.com> * bump version to v2.18.1 (#6510) * bump version to v2.18.1 * Update changelog.md * add some comment * fix some comment * update readme * fix lint * add reduce mean * update * update readme * update params Co-authored-by: Cedric Luo <luochunhua1996@outlook.com> Co-authored-by: RangiLyu <lyuchqi@gmail.com> Co-authored-by: Guangchen Lin <347630870@qq.com> Co-authored-by: Andrea Panizza <8233615+AndreaPi@users.noreply.github.com> Co-authored-by: Uno Wu <st9007a@gmail.com> Co-authored-by: Leonardo Rossi <leonardo.rossi@unipr.it> Co-authored-by: BigDong <yudongwang@tju.edu.cn> Co-authored-by: Haobo Yuan <yuanhaobo@whu.edu.cn> Co-authored-by: Shusheng Yang <shusheng.yang@qq.com> * [Refactor] Remove some code in `mmdet/apis/train.py` (#6576) * remove some code about custom hooks in apis/train.py * files were modified by yapf * Fix lad repeatedly output warning message (#6584) * drop support for pytorch 1.3.1. (#6589) * drop support for pytorch 1.3.1. * update ci * update ci * Skip CI on ignoring paths (#6578) * [test] Skip CI on ignoring paths Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * [skip ci] fix build.yaml Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * split lint in workflows Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * split lint in workflows Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * split lint in workflows Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * [Refactor]: refactor configs of FP16 models (#6592) * refactor configs of fp16 * update * update * update * Ignoring paths (#6615) Signed-off-by: del-zhenwu <dele.zhenwu@gmail.com> * fix FP16 CI (#6616) * Bump to 2.19.0 (#6633) * bump to 2.19.0 * resolve comments * fix typo * fix * fix yolox cuda unittest (#6636) * Support circleci (#6630) * add ci * rename * fix mmtrack unittest * update mmcv version * add abstract and sketch to the CONFIGS/algorithm/README.md * add some ## Introduction * revert Co-authored-by: Kyungmin Lee <30465912+lkm2835@users.noreply.github.com> Co-authored-by: ohwi <supebulous@gmail.com> Co-authored-by: Guangchen Lin <347630870@qq.com> Co-authored-by: Rishit Dagli <rishit.dagli@gmail.com> Co-authored-by: RangiLyu <lyuchqi@gmail.com> Co-authored-by: Haian Huang(深度眸) <1286304229@qq.com> Co-authored-by: del-zhenwu <dele.zhenwu@gmail.com> Co-authored-by: Thuy Ng <thuypn9a4@gmail.com> Co-authored-by: Han Zhang <623606860@qq.com> Co-authored-by: Cedric Luo <luochunhua1996@outlook.com> Co-authored-by: Andrea Panizza <8233615+AndreaPi@users.noreply.github.com> Co-authored-by: Uno Wu <st9007a@gmail.com> Co-authored-by: Leonardo Rossi <leonardo.rossi@unipr.it> Co-authored-by: BigDong <yudongwang@tju.edu.cn> Co-authored-by: Haobo Yuan <yuanhaobo@whu.edu.cn> Co-authored-by: Shusheng Yang <shusheng.yang@qq.com> Co-authored-by: Wenwei Zhang <40779233+ZwwWayne@users.noreply.github.com> Co-authored-by: Shilong Zhang <61961338+jshilong@users.noreply.github.com>
3 years ago
## Abstract
<!-- [ABSTRACT] -->
We motivate and present feature selective anchor-free (FSAF) module, a simple and effective building block for single-shot object detectors. It can be plugged into single-shot detectors with feature pyramid structure. The FSAF module addresses two limitations brought up by the conventional anchor-based detection: 1) heuristic-guided feature selection; 2) overlap-based anchor sampling. The general concept of the FSAF module is online feature selection applied to the training of multi-level anchor-free branches. Specifically, an anchor-free branch is attached to each level of the feature pyramid, allowing box encoding and decoding in the anchor-free manner at an arbitrary level. During training, we dynamically assign each instance to the most suitable feature level. At the time of inference, the FSAF module can work jointly with anchor-based branches by outputting predictions in parallel. We instantiate this concept with simple implementations of anchor-free branches and online feature selection strategy. Experimental results on the COCO detection track show that our FSAF module performs better than anchor-based counterparts while being faster. When working jointly with anchor-based branches, the FSAF module robustly improves the baseline RetinaNet by a large margin under various settings, while introducing nearly free inference overhead. And the resulting best model can achieve a state-of-the-art 44.6% mAP, outperforming all existing single-shot detectors on COCO.
<!-- [IMAGE] -->
<div align=center>
<img src="https://user-images.githubusercontent.com/40661020/143887228-c790b542-c0f7-4113-8597-12250c50fe8f.png"/>
</div>
<!-- [PAPER_TITLE: Feature Selective Anchor-Free Module for Single-Shot Object Detection] -->
<!-- [PAPER_URL: https://arxiv.org/abs/1903.00621] -->
## Introduction
<!-- [ALGORITHM] -->
FSAF is an anchor-free method published in CVPR2019 ([https://arxiv.org/pdf/1903.00621.pdf](https://arxiv.org/pdf/1903.00621.pdf)).
Actually it is equivalent to the anchor-based method with only one anchor at each feature map position in each FPN level.
And this is how we implemented it.
Only the anchor-free branch is released for its better compatibility with the current framework and less computational budget.
In the original paper, feature maps within the central 0.2-0.5 area of a gt box are tagged as ignored. However,
it is empirically found that a hard threshold (0.2-0.2) gives a further gain on the performance. (see the table below)
## Main Results
### Results on R50/R101/X101-FPN
| Backbone | ignore range | ms-train| Lr schd |Train Mem (GB)| Train time (s/iter) | Inf time (fps) | box AP | Config | Download |
|:----------:| :-------: |:-------:|:-------:|:------------:|:---------------:|:--------------:|:-------------:|:------:|:--------:|
| R-50 | 0.2-0.5 | N | 1x | 3.15 | 0.43 | 12.3 | 36.0 (35.9) | | [model](https://download.openmmlab.com/mmdetection/v2.0/fsaf/fsaf_pscale0.2_nscale0.5_r50_fpn_1x_coco/fsaf_pscale0.2_nscale0.5_r50_fpn_1x_coco_20200715-b555b0e0.pth) &#124; [log](https://download.openmmlab.com/mmdetection/v2.0/fsaf/fsaf_pscale0.2_nscale0.5_r50_fpn_1x_coco/fsaf_pscale0.2_nscale0.5_r50_fpn_1x_coco_20200715_094657.log.json) |
| R-50 | 0.2-0.2 | N | 1x | 3.15 | 0.43 | 13.0 | 37.4 | [config](https://github.com/open-mmlab/mmdetection/tree/master/configs/fsaf/fsaf_r50_fpn_1x_coco.py) | [model](https://download.openmmlab.com/mmdetection/v2.0/fsaf/fsaf_r50_fpn_1x_coco/fsaf_r50_fpn_1x_coco-94ccc51f.pth) &#124; [log](https://download.openmmlab.com/mmdetection/v2.0/fsaf/fsaf_r50_fpn_1x_coco/fsaf_r50_fpn_1x_coco_20200428_072327.log.json)|
| R-101 | 0.2-0.2 | N | 1x | 5.08 | 0.58 | 10.8 | 39.3 (37.9) | [config](https://github.com/open-mmlab/mmdetection/tree/master/configs/fsaf/fsaf_r101_fpn_1x_coco.py) | [model](https://download.openmmlab.com/mmdetection/v2.0/fsaf/fsaf_r101_fpn_1x_coco/fsaf_r101_fpn_1x_coco-9e71098f.pth) &#124; [log](https://download.openmmlab.com/mmdetection/v2.0/fsaf/fsaf_r101_fpn_1x_coco/fsaf_r101_fpn_1x_coco_20200428_160348.log.json)|
| X-101 | 0.2-0.2 | N | 1x | 9.38 | 1.23 | 5.6 | 42.4 (41.0) | [config](https://github.com/open-mmlab/mmdetection/tree/master/configs/fsaf/fsaf_x101_64x4d_fpn_1x_coco.py) | [model](https://download.openmmlab.com/mmdetection/v2.0/fsaf/fsaf_x101_64x4d_fpn_1x_coco/fsaf_x101_64x4d_fpn_1x_coco-e3f6e6fd.pth) &#124; [log](https://download.openmmlab.com/mmdetection/v2.0/fsaf/fsaf_x101_64x4d_fpn_1x_coco/fsaf_x101_64x4d_fpn_1x_coco_20200428_160424.log.json)|
**Notes:**
- *1x means the model is trained for 12 epochs.*
- *AP values in the brackets represent those reported in the original paper.*
- *All results are obtained with a single model and single-scale test.*
- *X-101 backbone represents ResNext-101-64x4d.*
- *All pretrained backbones use pytorch style.*
- *All models are trained on 8 Titan-XP gpus and tested on a single gpu.*
## Citations
BibTeX reference is as follows.
```latex
@inproceedings{zhu2019feature,
title={Feature Selective Anchor-Free Module for Single-Shot Object Detection},
author={Zhu, Chenchen and He, Yihui and Savvides, Marios},
booktitle={Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition},
pages={840--849},
year={2019}
}
```