Home

Awesome

Dynamic Head

By Lin Song, Yanwei Li, Zhengkai Jiang, Zeming Li, Hongbin Sun, Jian Sun, Nanning Zheng.

This repo is an official implementation for "Fine-Grained Dynamic Head for Object Detection" (NeurIPS2020) on PyTorch framework.

<img src="demo/introduction.png" alt="introduce image" />

Installation

Requirements

Build from source

Prepare data

See datasets/README.md.

Usage

All the projects are placed in cvpods_playground. You need to select a project and enter the corresponding folder.

# For example
cd cvpods_playground/fcos.res50.1x

Training

# Running training procedure with specific GPU number
cvpods_train --gpu-nums <GPU_NUM> [optional arguments]

# Please refer to tools/train_net.py for more optional arguments

Inference

# Running inference procedure with specific GPU number
# The program will load the lastest model weights from ./log folder
cvpods_test --gpu-nums <GPU_NUM> [optional arguments]

# Running inference procedure with specific GPU number and model path
cvpods_test --gpu-nums <GPU_NUM> MODEL.WEIGHTS <model_path> [optional arguments]

# Please refer to tools/test_net.py for more optional arguments

Visualize your image [Optional]

# Please refer to demo/demo.py for more optional arguments
python ../../demo/demo.py --config <config_path> --input <input_path> --output <output_path> MODEL.WEIGHTS <model_path> [optional arguments]

Performance

Object Detection on COCO val set

All the results are based on ResNet-50 backbone. The FLOPs are calculated on the head only. "Low", "Mid" and "High" correspond to three configurations of different computational complex.

MethodDepthAP<sub>box</sub> (%)FLOPs<sub>avg</sub>FLOPs<sub>min</sub>FLOPs<sub>max</sub>ProjectModel
FCOSD238.798.098.098.0LinkGoogleDrive
FCOS+FixD440.1198.6198.6198.6LinkGoogleDrive
FCOS+FixD839.3397.2397.2397.2LinkGoogleDrive
FCOS+Dynamic (Mid)D440.752.212.1144.4LinkGoogleDrive
FCOS+Dynamic (Low)D840.233.36.4140.2LinkGoogleDrive
FCOS+Dynamic (Mid)D841.283.921.3237.7LinkGoogleDrive
FCOS+Dynamic (High)D842.0277.5180.4328.5LinkGoogleDrive

More Results is Coming

To do

Citation

Please cite the paper in your publications if it helps your research.

@inproceedings{song2020fine-grained,
    title = {Fine-Grained Dynamic Head for Object Detection},
    author = {Song, Lin and Li, Yanwei and Jiang, Zhengkai and Li, Zeming and Sun, Hongbin and Sun, Jian and Zheng, Nanning},
    booktitle = {Advances in Neural Information Processing Systems},
    year = {2020}
}

Please cite this project in your publications if it helps your research.

@misc{dynamichead,
    author = {Song, Lin},
    title = {DynamicHead},
    howpublished = {\url{https://github.com/StevenGrove/DynamicHead}},
    year ={2020}
}