mmsegmentation icon indicating copy to clipboard operation
mmsegmentation copied to clipboard

assert (mmcv_version >= digit_version(mmcv_minimum_version) AssertionError: MMCV==2.0.0 is used but incompatible. Please install mmcv>=1.3.17, <=1.7.0.

Open Kenneth-X opened this issue 2 years ago • 5 comments

  • after using: pip install -U openmim mim install mmengine mim install "mmcv>=2.0.0" pip install "mmsegmentation>=1.0.0"
  • then using: mim download mmsegmentation --config pspnet_r50-d8_4xb2-40k_cityscapes-512x1024 --dest .

python demo/image_demo.py demo/demo.png configs/pspnet/pspnet_r50-d8_4xb2-40k_cityscapes-512x1024.py pspnet_r50-d8_512x1024_40k_cityscapes_20200605_003338-2966598c.pth --device cuda:0 --out-file result.jpg

  • got error : assert (mmcv_version >= digit_version(mmcv_minimum_version) AssertionError: MMCV==2.0.0 is used but incompatible. Please install mmcv>=1.3.17, <=1.7.0.

Kenneth-X avatar May 19 '23 07:05 Kenneth-X

same problem

MatlabChen avatar May 25 '23 09:05 MatlabChen

Facing the same issue while running python tools/train.py configs/convnext/convnext-small_upernet_8xb2-amp-160k_ade20k-512x512.py since it requires mmcls with mmcv compatible version mmcv>=1.4.2, <1.9.0, however the mmseg requires mmcv minimum version 2.0.0.

apbose avatar May 25 '23 22:05 apbose

just change " mmcv_maximum_version = '1.8.0' " to "2.1.0" in the site-packages.mmdet.init.py

shuaijun-36 avatar Jun 21 '23 12:06 shuaijun-36

just change " mmcv_maximum_version = '1.8.0' " to "2.1.0" in the site-packages.mmdet.init.py

That's not enough, there are many breaking changes in mmcv 2.x. The correct way may be install mmpretrain and replace all occurrence of 'mmcls' to 'mmpretrain' in the whole mmseg package.

wdx04 avatar Jun 25 '23 09:06 wdx04

I got a similiar error and I fixed it. You should install mmcv==2.0.0rc4 and mmcv_full==1.7.1 and pip install ftfy

erencsknn avatar May 04 '24 21:05 erencsknn