1.安装mmcv
1.1 安装方法
- 方法1
pip install mmcv-full -f ttps://download.openmmlab.com/mmcv/dist/{cu_version}/{torch_version}/index.html
- 方法2
pip install mmcv-full -f https://download.openmmlab.com/mmcv/dist/cu110/torch1.7.0/index.html
- 方法3
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 ..
- 方法4
pip install mmcv-full
1.2 注意
mmcv要与mmdetection版本对应,对应关系如下:
MMDetection version | MMCV version |
---|---|
master | mmcv-full>=1.3.3, <1.4.0 |
2.12.0 | mmcv-full>=1.3.3, <1.4.0 |
2.11.0 | mmcv-full>=1.2.4, <1.4.0 |
2.10.0 | mmcv-full>=1.2.4, <1.4.0 |
2.9.0 | mmcv-full>=1.2.4, <1.4.0 |
2.8.0 | mmcv-full>=1.2.4, <1.4.0 |
2.7.0 | mmcv-full>=1.1.5, <1.4.0 |
2.6.0 | mmcv-full>=1.1.5, <1.4.0 |
2.5.0 | mmcv-full>=1.1.5, <1.4.0 |
2.4.0 | mmcv-full>=1.1.1, <1.4.0 |
2.3.0 | mmcv-full==1.0.5 |
2.3.0rc0 | mmcv-full>=1.0.2 |
2.2.1 | mmcv==0.6.2 |
2.2.0 | mmcv==0.6.2 |
2.1.0 | mmcv>=0.5.9, <=0.6.1 |
2.0.0 | mmcv>=0.5.1, <=0.5.8 |
2.安装mmdetection
2.1 下载mmdetection代码
git clone https://github.com/open-mmlab/mmdetection.git
cd mmdetection
2.2 setup mmdetection
pip install -r requirements/build.txt
pip install -v -e . # or "python setup.py develop"