likyoo / open-cd

A Change Detection Repo Standing on the Shoulders of Giants
https://arxiv.org/abs/2407.15317
Apache License 2.0
494 stars 72 forks source link

No module named 'mmcv' #21

Open Sushant-summit opened 1 year ago

Sushant-summit commented 1 year ago

Hey I'm getting this error on running infer command:

Traceback (most recent call last):
  File "tools/test.py", line 10, in <module>
    import mmcv
ModuleNotFoundError: No module named 'mmcv'

and when i'm install mmcv, i'm getting this error

Collecting mmcv
  Using cached mmcv-2.0.0.tar.gz (473 kB)
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [12 lines of output]
      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File "/private/var/folders/ff/1k6ltqsd42gb85qy9gx5jvyr0000gn/T/pip-install-z3afg0xg/mmcv_5de6ac3785ee44dd94dd614be11c4631/setup.py", line 10, in <module>
          import torch
        File "/Users/sushantmishra/miniconda3/envs/changeDetection/lib/python3.8/site-packages/torch/__init__.py", line 1146, in <module>
          _C._initExtension(manager_path())
        File "/Users/sushantmishra/miniconda3/envs/changeDetection/lib/python3.8/site-packages/torch/cuda/__init__.py", line 15, in <module>
          from . import profiler
        File "/Users/sushantmishra/miniconda3/envs/changeDetection/lib/python3.8/site-packages/torch/cuda/profiler.py", line 3, in <module>
          from . import cudart, check_error
      ImportError: cannot import name 'cudart' from partially initialized module 'torch.cuda' (most likely due to a circular import) (/Users/sushantmishra/miniconda3/envs/changeDetection/lib/python3.8/site-packages/torch/cuda/__init__.py)
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

System : MacOS 13.3.1 (chip M1)

likyoo commented 1 year ago

see mmcv document or issues ?

kk-kaii commented 1 year ago

Hey I'm getting this error on running infer command:

Traceback (most recent call last):
  File "tools/test.py", line 10, in <module>
    import mmcv
ModuleNotFoundError: No module named 'mmcv'

and when i'm install mmcv, i'm getting this error

Collecting mmcv
  Using cached mmcv-2.0.0.tar.gz (473 kB)
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [12 lines of output]
      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File "/private/var/folders/ff/1k6ltqsd42gb85qy9gx5jvyr0000gn/T/pip-install-z3afg0xg/mmcv_5de6ac3785ee44dd94dd614be11c4631/setup.py", line 10, in <module>
          import torch
        File "/Users/sushantmishra/miniconda3/envs/changeDetection/lib/python3.8/site-packages/torch/__init__.py", line 1146, in <module>
          _C._initExtension(manager_path())
        File "/Users/sushantmishra/miniconda3/envs/changeDetection/lib/python3.8/site-packages/torch/cuda/__init__.py", line 15, in <module>
          from . import profiler
        File "/Users/sushantmishra/miniconda3/envs/changeDetection/lib/python3.8/site-packages/torch/cuda/profiler.py", line 3, in <module>
          from . import cudart, check_error
      ImportError: cannot import name 'cudart' from partially initialized module 'torch.cuda' (most likely due to a circular import) (/Users/sushantmishra/miniconda3/envs/changeDetection/lib/python3.8/site-packages/torch/cuda/__init__.py)
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

System : MacOS 13.3.1 (chip M1)

Hello, have you run through this open CD yet