Problem with installation
Hi, I am using Ubuntu and I tried to install based on get_started.md. After all the steps and on verification, I get this error:
python demo/image_demo.py demo/demo.jpg configs/pspnet/pspnet_r50-d8_512x1024_40k_cityscapes.py \ checkpoints/pspnet_r50-d8_512x1024_40k_cityscapes_20200605_003338-2966598c.pth --palette cityscapes
/home/arsalan/anaconda3/envs/open-mmlab/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 '
/home/arsalan/anaconda3/envs/open-mmlab/lib/python3.7/site-packages/mmcv/__init__.py:21: UserWarning: On January 1, 2023, MMCV will release v2.0.0, in which it will remove components related to the training process and add a data transformation module. In addition, it will rename the package names mmcv to mmcv-lite and mmcv-full to mmcv. See https://github.com/open-mmlab/mmcv/blob/master/docs/en/compatibility.md for more details.
'On January 1, 2023, MMCV will release v2.0.0, in which it will remove '
Traceback (most recent call last):
File "demo/image_demo.py", line 6, in <module>
from mmseg.apis import inference_model, init_model, show_result_pyplot
File "/home/arsalan/Desktop/seg/mmseg/mmsegmentation-0.20.2/mmsegmentation/mmseg/__init__.py", line 62, in <module>
f'MMCV=={mmcv.__version__} is used but incompatible. ' \
AssertionError: MMCV==1.7.1 is used but incompatible. Please install mmcv>=2.0.0rc4.
Any thoughts about this problem?
I even tried to solve the problem by
mim install "mmcv>=2.0.0rc1"
But it didn't help and led to this error:
ImportError: cannot import name 'inference_segmentor' from 'mmseg.apis'
Which is so weird for me!
Hi @arsalanfiroozi,
inference_segmentor is an API in the old version, you might try to use the latest demo.
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