Open HZWXW371 opened 1 year ago
could resolve this issues ?.
Hi, what is your mmcv version?
Did you manage to fix this issue?
hey anybody solved this issue ?
from mmengine.utils.dl_utils import TORCH_VERSION
This worked for me
than i meet a problem as follows: ImportError: cannot import name 'digit_version' from 'mmcv.utils' (/home/cyg/anaconda3/envs/tinydet/lib/python3.8/site-packages/mmcv/utils/init.py)
from mmengine.utils.dl_utils import TORCH_VERSION from mmengine.utils import digit_version
📚 The doc issue
Traceback (most recent call last): File "D:\GIS\LightCDNet-main\tools\train.py", line 15, in
from mmcv.runner import get_dist_info, init_dist
File "C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\runner__init.py", line 3, in
from .base_runner import BaseRunner
File "C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\runner\base_runner.py", line 16, in
from ..parallel import is_module_wrapper
File "C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\parallel__init__.py", line 5, in
from .distributed import MMDistributedDataParallel
File "C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\parallel\distributed.py", line 10, in
from mmcv.utils import TORCH_VERSION, digit_version
ImportError: cannot import name 'TORCH_VERSION' from 'mmcv.utils' (C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\utils\ init__.py)
Process finished with exit code 1
Suggest a potential alternative/fix
Traceback (most recent call last): File "D:\GIS\LightCDNet-main\tools\train.py", line 15, in
from mmcv.runner import get_dist_info, init_dist
File "C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\runner__init.py", line 3, in
from .base_runner import BaseRunner
File "C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\runner\base_runner.py", line 16, in
from ..parallel import is_module_wrapper
File "C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\parallel__init__.py", line 5, in
from .distributed import MMDistributedDataParallel
File "C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\parallel\distributed.py", line 10, in
from mmcv.utils import TORCH_VERSION, digit_version
ImportError: cannot import name 'TORCH_VERSION' from 'mmcv.utils' (C:\Users\hongzheng.conda\envs\opencd\lib\site-packages\mmcv\utils\ init__.py)
Process finished with exit code 1