Giter VIP home page Giter VIP logo

madet's Introduction

Introduction

demo image

Object detection is a fundamental yet challenging task in computer vision. Despite the great strides made over recent years, modern detectors may still produce unsatisfactory performance due to certain factors, such as non-universal object features and single regression manner. In this paper, we draw on the idea of mutual-assistance (MA) learning and accordingly propose a robust one-stage detector, referred as MADet, to address these weaknesses. First, the spirit of MA is manifested in the head design of the detector. Decoupled classification and regression features are reintegrated to provide shared offsets, avoiding inconsistency between feature-prediction pairs induced by zero or erroneous offsets. Second, the spirit of MA is captured in the optimization paradigm of the detector. Both anchor-based and anchor-free regression fashions are utilized jointly to boost the capability to retrieve objects with various characteristics, especially for large aspect ratios, occlusion from similar-sized objects, etc. Furthermore, we meticulously devise a quality assessment mechanism to facilitate adaptive sample selection and loss term reweighting. Extensive experiments on standard benchmarks verify the effectiveness of our approach. On MS-COCO, MADet achieves 42.5% AP with vanilla ResNet50 backbone, dramatically surpassing multiple strong baselines and setting a new state of the art.

Installation

Please refer to install.md for installation.

Getting Started

Please see get_started.md for the basic usage of MADet.

Results and models

MS-COCO dataset

Backbone Lr schd Box AP Set Config Baidu Yun Google Drive
R50-FPN 1x 42.5 test config key: ks5i model
R50-FPN 1x 42.2 val config key: yatj model

Acknowledgement

The implementation of MADet is based on mmdetection.

License

This project is released under the Apache 2.0 license.

Citation

@ARTICLE{MADet,
  author={Xie, Xingxing and Lang, Chunbo and Miao, Shicheng and Cheng, Gong and Li, Ke and Han, Junwei},
  journal={IEEE Transactions on Pattern Analysis and Machine Intelligence}, 
  title={Mutual-Assistance Learning for Object Detection}, 
  year={2023},
  volume={45},
  number={12},
  pages={15171-15184},
  doi={10.1109/TPAMI.2023.3319634}
}

madet's People

Contributors

shichengmiao16 avatar xiexing9212 avatar nicekokusei avatar

Stargazers

zyfone avatar  avatar Shi Tianjun avatar  avatar TOT avatar Jiaqing Zhang avatar Bigo avatar David Zhang avatar  avatar  avatar  avatar  avatar  avatar hm avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

xiexing9212

madet's Issues

ConvModule' object has no attribute 'weight',

Please tell me, I use the be command python tools/train.py configs/madet/madet_r101_fpn_1x_coco.py for training, but an error like this occurs, nexpected key in source state_dict: fc.weight, fc.bias

Traceback (most recent call last):
File "tools/train.py", line 185, in
main()
File "tools/train.py", line 158, in main
model = build_detector(
File "/root/autodl-tmp/MADet/mmdet/models/builder.py", line 67, in build_detector
return build(cfg, DETECTORS, dict(train_cfg=train_cfg, test_cfg=test_cfg))
File "/root/autodl-tmp/MADet/mmdet/models/builder.py", line 32, in build
return build_from_cfg(cfg, registry, default_args)
File "/root/miniconda3/lib/python3.8/site-packages/mmcv/utils/registry.py", line 171, in build_from_cfg
return obj_cls(**args)
File "/root/autodl-tmp/MADet/mmdet/models/detectors/madet.py", line 18, in init
super(MADet, self).init(backbone, neck, bbox_head, train_cfg,
File "/root/autodl-tmp/MADet/mmdet/models/detectors/single_stage.py", line 33, in init
self.init_weights(pretrained=pretrained)
File "/root/autodl-tmp/MADet/mmdet/models/detectors/single_stage.py", line 50, in init_weights
self.bbox_head.init_weights()
File "/root/autodl-tmp/MADet/mmdet/models/dense_heads/madet_head.py", line 177, in init_weights
normal_init(self.dcn, std=0.01)
File "/root/miniconda3/lib/python3.8/site-packages/mmcv/cnn/utils/weight_init.py", line 24, in normal_init
nn.init.normal_(module.weight, mean, std)
File "/root/miniconda3/lib/python3.8/site-packages/torch/nn/modules/module.py", line 771, in getattr
raise ModuleAttributeError("'{}' object has no attribute '{}'".format(
torch.nn.modules.module.ModuleAttributeError: 'ConvModule' object has no attribute 'weight', looking forward to your reply.

Unable to get visualization results with image_demo.py

torch_version1.6.0,cuda10.1,mmcv_full1.2.7,mmdet2.8.0,

When wishing to obtain an image of the test results, run the command:
"CUDA_VISIBLE_DEVICES=1 python demo/image_demo.py demo/images/000751.jpg configs/madet/madet_r50_fpn_1x_ssdd.py work_dirs/ssdd_prebb/madet_r50_fpn_3x_E1planA_noprocess_lr0.0005SGD_ssdd_6/epoch_36.pth --score-thr 0.3 --device cuda:0",

the program is stuck for a long time,no output:

/opt/conda/envs/MADet/lib/python3.7/site-packages/mmengine/model/utils.py:137: UserWarning: Cannot import torch.fx, merge_dict is a simple function to merge multiple dicts
warnings.warn('Cannot import torch.fx, merge_dict is a simple function '
Use load_from_local loader

What should I do to solve this problem?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.