Semantic-Segment-Anything icon indicating copy to clipboard operation
Semantic-Segment-Anything copied to clipboard

cannot import print.log from mmcv.util using google colab

Open sulaiman1988 opened this issue 1 year ago • 4 comments

Traceback (most recent call last): File "/content/Semantic-Segment-Anything/scripts/main_ssa_engine.py", line 5, in from pipeline import semantic_annotation_pipeline File "/content/Semantic-Segment-Anything/scripts/pipeline.py", line 8, in from mmcv.utils import print_log ImportError: cannot import name 'print_log' from 'mmcv.utils' (/usr/local/lib/python3.10/dist-packages/mmcv/utils/init.py)

sulaiman1988 avatar Jul 31 '23 15:07 sulaiman1988

where is the requirements file?

sulaiman1988 avatar Aug 01 '23 07:08 sulaiman1988

I am having the same issue, did you find any solution?

ayaan-mphasis avatar Aug 21 '23 09:08 ayaan-mphasis

I am having the same issue, did you find any solution?

change it to from mmengine import print_log

lywang76 avatar Oct 05 '23 22:10 lywang76

any alternatives to this?

Still get this after running from mmengine import print_log:

/content/drive/MyDrive/AI/Semantic-Segment-Anything Traceback (most recent call last): File "/content/drive/MyDrive/AI/Semantic-Segment-Anything/scripts/main_ssa.py", line 6, in from pipeline import semantic_segment_anything_inference, eval_pipeline, img_load File "/content/drive/MyDrive/AI/Semantic-Segment-Anything/scripts/pipeline.py", line 5, in import mmcv ModuleNotFoundError: No module named 'mmcv'

This also does not work in colab currently:

!pip3 install openmim !mim install mmcv-full #https://mmdetection.readthedocs.io/en/dev/get_started.html

georgeguida avatar Mar 19 '24 18:03 georgeguida