Support FP16 training (#520)
* add fp16 support * fpn donot need bn normalize * refactor wrapped bn * fix bug of retinanet * add fp16 ssd300 voc, cascade r50, cascade mask r50 * fix bug in cascade rcnn testing * add support to fix bn training * add fix bn cfg * delete fixbn cfg, mv fixbn fp16 to a new branch * fix cascade mask fp16 bug in test * fix bug in cascade mask rcnn fp16 test * add more fp16 cfgs * add fp16 fast-r50 and faster-dconv-r50 * add fp16 test, minor fix * clean code * fix config work_dir name * add patch func, refactor code * fix format * clean code * move convert rois to single_level_extractor * fix bug for cascade mask, the seg mask is ndarray * refactor code, add two decorator force_fp32 and auto_fp16 * add fp16_enable attribute * add more comment, fix format and test assertion * fix pep8 format error * format commont and api * rename distribute to distributed, fix dict copy * rename function name * move function, add comment * remove unused parameter * mv decorators into decorators.py, hook related functions to hook * add auto_fp16 to forward of semantic head * add auto_fp16 to all heads and fpn * add docstrings and minor bug fix * simple refactoring * bug fix for patching forward method * roi extractor in fp32 mode * fix flake8 error * fix ci error * add fp16 support to ga head * remove parallel test assert * minor fix * add comment in build_optimizer * fix typo in comment * fix typo enable --> enabling * udpate README
Showing
- README.md 1 addition, 1 deletionREADME.md
- configs/fp16/faster_rcnn_r50_fpn_fp16_1x.py 170 additions, 0 deletionsconfigs/fp16/faster_rcnn_r50_fpn_fp16_1x.py
- configs/fp16/mask_rcnn_r50_fpn_fp16_1x.py 185 additions, 0 deletionsconfigs/fp16/mask_rcnn_r50_fpn_fp16_1x.py
- configs/fp16/retinanet_r50_fpn_fp16_1x.py 127 additions, 0 deletionsconfigs/fp16/retinanet_r50_fpn_fp16_1x.py
- mmdet/apis/train.py 26 additions, 4 deletionsmmdet/apis/train.py
- mmdet/core/__init__.py 2 additions, 1 deletionmmdet/core/__init__.py
- mmdet/core/fp16/__init__.py 4 additions, 0 deletionsmmdet/core/fp16/__init__.py
- mmdet/core/fp16/decorators.py 160 additions, 0 deletionsmmdet/core/fp16/decorators.py
- mmdet/core/fp16/hooks.py 126 additions, 0 deletionsmmdet/core/fp16/hooks.py
- mmdet/core/fp16/utils.py 23 additions, 0 deletionsmmdet/core/fp16/utils.py
- mmdet/core/utils/dist_utils.py 4 additions, 3 deletionsmmdet/core/utils/dist_utils.py
- mmdet/models/anchor_heads/anchor_head.py 4 additions, 1 deletionmmdet/models/anchor_heads/anchor_head.py
- mmdet/models/anchor_heads/fcos_head.py 6 additions, 2 deletionsmmdet/models/anchor_heads/fcos_head.py
- mmdet/models/anchor_heads/guided_anchor_head.py 33 additions, 32 deletionsmmdet/models/anchor_heads/guided_anchor_head.py
- mmdet/models/anchor_heads/ssd_head.py 1 addition, 0 deletionsmmdet/models/anchor_heads/ssd_head.py
- mmdet/models/backbones/ssd_vgg.py 6 additions, 2 deletionsmmdet/models/backbones/ssd_vgg.py
- mmdet/models/bbox_heads/bbox_head.py 8 additions, 1 deletionmmdet/models/bbox_heads/bbox_head.py
- mmdet/models/detectors/base.py 3 additions, 1 deletionmmdet/models/detectors/base.py
- mmdet/models/mask_heads/fcn_mask_head.py 7 additions, 1 deletionmmdet/models/mask_heads/fcn_mask_head.py
- mmdet/models/mask_heads/fused_semantic_head.py 4 additions, 0 deletionsmmdet/models/mask_heads/fused_semantic_head.py
Loading
Please register or sign in to comment