下载地址:https://github.com/open-mmlab/mmdetection
下载好后可以使用pip安装mmcv
pip install mmcv-full==latest+torch1.5.0+cu101 -f http://download.openmmlab.com/mmcv/dist/index.html
但是pip可能较慢,可以直接从源码上安装:
git clone https://github.com/open-mmlab/mmcv.git
cd mmcv
MMCV_WITH_OPS=1 pip install -e . # package mmcv-full will be installed after this step
cd ..
事实上以上命令也很容易报错,直接安装简易版不容易出问题:
pip install -e .
然后进入mmdetection目录下执行如下命令:
pip install -r requirements/build.txt
pip install "git+https://github.com/cocodataset/cocoapi.git#subdirectory=PythonAPI"
pip install -v -e .
上面安装cocoapi的方式可能会很慢,可以考虑如下命令安装:
pip install "git+https://gitee.com/ztdztd/cocoapi.git#subdirectory=pycocotools"
不然有可能报错:AttributeError: COCO object has no attribute get_cat_ids,
这样便安装完成。
mmdetection配置文件参数:
http://chr10003566.github.io/2019/12/03/mmdetection(2)/
https://blog.csdn.net/hajlyx/article/details/85991400
https://blog.csdn.net/weicao1990/article/details/91879513
mmdetection v2.0训练自己的数据:
https://blog.csdn.net/cp1314971/article/details/106943959/
https://zhuanlan.zhihu.com/p/162730118
https://blog.csdn.net/duanyajun987/article/details/97659685
https://blog.csdn.net/hajlyx/article/details/83542167
https://blog.csdn.net/qq_36302589/article/details/86149293
mmdetection训练并绘制曲线:
mmdetection mAP计算
https://blog.csdn.net/weicao1990/article/details/93484603
mmdetection学习率调整:
lr = (base_lr / 8) x num_gpus x (img_per_gpu/2)
其中 base_lr 是源码中给定的 学习率,这是在 8张GPU上面,每张GPU上面放2张图片得到的学习率,所以当对应的GPU数目和每张GPU上的图片数目发生改变时,学习率成正比例变化。
修改backbone:
https://www.cnblogs.com/qiulinzhang/p/12252033.html
https://www.cnblogs.com/qiulinzhang/p/12252033.html
报错‘COCO‘ object has no attribute ‘get_cat_ids‘:
https://blog.csdn.net/space_dandy/article/details/107982122
其他常见错误集合: