Describe the problem
I've tried installing mmSegmentation for 1-2 weeks, but I can't get it to run. First I tried installing it according to the getting started page, but I encountered several problems (e.g. when I just said to install mmcv, it installed version 2.2.0 and when starting mmsegmentation afterwards, it said that a version >=2.0.0 is needed). After trying installing it on 4 different computers, I decided to write a script to install all necessary components to avoid forgetting a certain component). But the end result on every pc were some import errors.
As a side note, I'm trying to install it on a WSL Ubuntu 22.4
Up to this point, I get no errors. But after I download the test from the getting started page and try to run it, I get the error listed at the end.
(the commands to do this:
Did you make any modifications on the code or config? Did you understand what you have modified?
other than bundling the installation in a script, I didn't change anything.
What dataset did you use?
The one from the get started page in the part of "verify the installation".
Environment
Please run python mmseg/utils/collect_env.py to collect necessary environment information and paste it here.
side note: I see that it says that CUDA isn't available, but I'm not sure what I have to do different.
2. You may add addition that may be helpful for locating the problem, such as
- How you installed PyTorch \[e.g., pip, conda, source\]
- Other environment variables that may be related (such as `$PATH`, `$LD_LIBRARY_PATH`, `$PYTHONPATH`, etc.)
```none
echo "$PATH"
/home/tim/miniconda3/envs/openmmlab/bin:/home/tim/miniconda3/condabin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/wsl/lib:/mnt/c/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.1/bin:/mnt/c/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.1/libnvvp:/mnt/c/Program Files/Oculus/Support/oculus-runtime:/mnt/c/windows/system32:/mnt/c/windows:/mnt/c/windows/System32/Wbem:/mnt/c/windows/System32/WindowsPowerShell/v1.0:/mnt/c/windows/System32/OpenSSH:/mnt/c/Program Files (x86)/NVIDIA Corporation/PhysX/Common:/mnt/c/Program Files/NVIDIA Corporation/NVIDIA NvDLISR:/mnt/c/Program Files/dotnet:/mnt/c/WINDOWS/system32:/mnt/c/WINDOWS:/mnt/c/WINDOWS/System32/Wbem:/mnt/c/WINDOWS/System32/WindowsPowerShell/v1.0:/mnt/c/WINDOWS/System32/OpenSSH:/mnt/c/Program Files/nodejs:/mnt/c/ProgramData/chocolatey/bin:/mnt/c/WINDOWS/system32:/mnt/c/WINDOWS:/mnt/c/WINDOWS/System32/Wbem:/mnt/c/WINDOWS/System32/WindowsPowerShell/v1.0:/mnt/c/WINDOWS/System32/OpenSSH:/mnt/c/Program Files (x86)/Eclipse/Sumo/bin:/mnt/c/Program Files (x86)/Eclipse/Sumo/tools:/mnt/c/Program Files/Git/cmd:/mnt/c/Softwareprojekt/Sumo/bin:/mnt/c/Softwareprojekt/Sumo/tools:/mnt/c/Program Files/MATLAB/R2023a/bin:/mnt/c/Program Files/NVIDIA Corporation/Nsight Compute 2023.1.0:/mnt/c/Users/mi/AppData/Local/Programs/Python/Python310/Scripts:/mnt/c/Users/mi/AppData/Local/Programs/Python/Python310:/mnt/c/Users/mi/AppData/Local/Microsoft/WindowsApps:/mnt/c/ProgramData/mi/GitHubDesktop/bin:/mnt/c/Users/mi/AppData/Local/Programs/Microsoft VS Code/bin:/mnt/c/Users/mi/AppData/Roaming/npm:/mnt/c/Users/mi/AppData/Local/JetBrains/Toolbox/scripts:/mnt/c/Users/mi/AppData/Local/gitkraken/bin:/mnt/c/Users/mi/AppData/Local/Microsoft/WindowsApps:/mnt/c/Users/mi/AppData/Local/Packages/PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0/LocalCache/local-packages/Python310/Scripts:/snap/bin
echo "$LD_LIBRARY_PATH"
echo "$PYTHONPATH"
sidenote: in a previous installation I manually added the path in $LD_LIBRARY_PATH, but the error consisted.
Error traceback
If applicable, paste the error trackback here.
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
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/tim/mmsegmentation/mmseg/apis/__init__.py", line 2, in <module>
from .inference import inference_model, init_model, show_result_pyplot
File "/home/tim/mmsegmentation/mmseg/apis/inference.py", line 14, in <module>
from mmseg.models import BaseSegmentor
File "/home/tim/mmsegmentation/mmseg/models/__init__.py", line 3, in <module>
from .backbones import * # noqa: F401,F403
File "/home/tim/mmsegmentation/mmseg/models/backbones/__init__.py", line 2, in <module>
from .beit import BEiT
File "/home/tim/mmsegmentation/mmseg/models/backbones/beit.py", line 19, in <module>
from ..utils import PatchEmbed
File "/home/tim/mmsegmentation/mmseg/models/utils/__init__.py", line 2, in <module>
from .basic_block import BasicBlock, Bottleneck
File "/home/tim/mmsegmentation/mmseg/models/utils/basic_block.py", line 10, in <module>
from mmseg.utils import OptConfigType
File "/home/tim/mmsegmentation/mmseg/utils/__init__.py", line 24, in <module>
from .mask_classification import MatchMasks, seg_data_to_instance_data
File "/home/tim/mmsegmentation/mmseg/utils/mask_classification.py", line 5, in <module>
from mmcv.ops import point_sample
File "/home/tim/miniconda3/envs/openmmlab/lib/python3.8/site-packages/mmcv/ops/__init__.py", line 3, in <module>
from .active_rotated_filter import active_rotated_filter
File "/home/tim/miniconda3/envs/openmmlab/lib/python3.8/site-packages/mmcv/ops/active_rotated_filter.py", line 10, in <module>
ext_module = ext_loader.load_ext(
File "/home/tim/miniconda3/envs/openmmlab/lib/python3.8/site-packages/mmcv/utils/ext_loader.py", line 13, in load_ext
ext = importlib.import_module('mmcv.' + name)
File "/home/tim/miniconda3/envs/openmmlab/lib/python3.8/importlib/__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: libc10_cuda.so: cannot open shared object file: No such file or directory
Describe the problem I've tried installing mmSegmentation for 1-2 weeks, but I can't get it to run. First I tried installing it according to the getting started page, but I encountered several problems (e.g. when I just said to install mmcv, it installed version 2.2.0 and when starting mmsegmentation afterwards, it said that a version >=2.0.0 is needed). After trying installing it on 4 different computers, I decided to write a script to install all necessary components to avoid forgetting a certain component). But the end result on every pc were some import errors.
As a side note, I'm trying to install it on a WSL Ubuntu 22.4
Reproduction
After this part, I restart the WSL Ubuntu to commit the conda changes. The CUDA Version is 11.5. Afterwards, I execute the following script:
Up to this point, I get no errors. But after I download the test from the getting started page and try to run it, I get the error listed at the end. (the commands to do this:
)
Did you make any modifications on the code or config? Did you understand what you have modified? other than bundling the installation in a script, I didn't change anything.
What dataset did you use? The one from the get started page in the part of "verify the installation".
Environment
python mmseg/utils/collect_env.py
to collect necessary environment information and paste it here.TorchVision: 0.18.0 OpenCV: 4.9.0 MMEngine: 0.10.4 MMSegmentation: 1.2.2+b040e14
sidenote: in a previous installation I manually added the path in $LD_LIBRARY_PATH, but the error consisted. Error traceback
If applicable, paste the error trackback here.