活動地址:CSDN21天學習挑戰賽
小於3.7version cannot be installedBasicSR,It will report that there is no corresponding version
BasicSR是基於pytorch的包,不安裝pytorch直接安裝BasicSR會報錯如下
ERROR: Command errored out with exit status 1:
command: /home/jiangyvhang/anaconda3/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-oy7jrdxp/basicsr/setup.py'"'"'; __file__='"'"'/tmp/pip-install-oy7jrdxp/basicsr/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-gnmqycu3
cwd: /tmp/pip-install-oy7jrdxp/basicsr/
Complete output (5 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-oy7jrdxp/basicsr/setup.py", line 8, in <module>
import torch
ModuleNotFoundError: No module named 'torch'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
pip3 install torch
pip3 install basicsr
python
import torch
import bascisr
ImportError: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.
strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX
GLIBCXX_3.4 GLIBCXX_3.4.1 GLIBCXX_3.4.2 GLIBCXX_3.4.3 GLIBCXX_3.4.4 GLIBCXX_3.4.5 GLIBCXX_3.4.6 GLIBCXX_3.4.7 GLIBCXX_3.4.8 GLIBCXX_3.4.9 GLIBCXX_3.4.10 GLIBCXX_3.4.11 GLIBCXX_3.4.12 GLIBCXX_3.4.13 GLIBCXX_3.4.14 GLIBCXX_3.4.15 GLIBCXX_3.4.16 GLIBCXX_3.4.17 GLIBCXX_3.4.18 GLIBCXX_3.4.19 GLIBCXX_3.4.20 GLIBCXX_3.4.21 GLIBCXX_DEBUG_MESSAGE_LENGTH
sudo find -name "libstdc++.so.6*“
./anaconda3/pkgs/libstdcxx-ng-9.3.0-hd4cf53a_17/lib/libstdc++.so.6.0.28 ./anaconda3/pkgs/libstdcxx-ng-9.3.0-hd4cf53a_17/lib/libstdc++.so.6 ./anaconda3/pkgs/libstdcxx-ng-9.1.0-hdf63c60_0/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6 ./anaconda3/pkgs/libstdcxx-ng-9.1.0-hdf63c60_0/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6.0.26 ./anaconda3/pkgs/libstdcxx-ng-9.1.0-hdf63c60_0/lib/libstdc++.so.6 ./anaconda3/pkgs/libstdcxx-ng-9.1.0-hdf63c60_0/lib/libstdc++.so.6.0.26 ./anaconda3/envs/fastrcnn/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6 ./anaconda3/envs/fastrcnn/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6.0.26 ./anaconda3/envs/fastrcnn/lib/libstdc++.so.6 ./anaconda3/envs/fastrcnn/lib/libstdc++.so.6.0.26 ./anaconda3/envs/bishefuxian27train/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6 ./anaconda3/envs/bishefuxian27train/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6.0.26 ./anaconda3/envs/bishefuxian27train/lib/libstdc++.so.6 ./anaconda3/envs/bishefuxian27train/lib/libstdc++.so.6.0.26 ./anaconda3/envs/bishefuxiantxt/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6 ./anaconda3/envs/bishefuxiantxt/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6.0.26 ./anaconda3/envs/bishefuxiantxt/lib/libstdc++.so.6 ./anaconda3/envs/bishefuxiantxt/lib/libstdc++.so.6.0.26 ./anaconda3/envs/python35/lib/libstdc++.so.6.0.28 ./anaconda3/envs/python35/lib/libstdc++.so.6 ./anaconda3/envs/bishefuxian27/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6 ./anaconda3/envs/bishefuxian27/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6.0.26 ./anaconda3/envs/bishefuxian27/lib/libstdc++.so.6 ./anaconda3/envs/bishefuxian27/lib/libstdc++.so.6.0.26 ./anaconda3/envs/mc/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6 ./anaconda3/envs/mc/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6.0.26 ./anaconda3/envs/mc/lib/libstdc++.so.6 ./anaconda3/envs/mc/lib/libstdc++.so.6.0.26 ./anaconda3/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6 ./anaconda3/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6.0.26 ./anaconda3/lib/libstdc++.so.6 ./anaconda3/lib/libstdc++.so.6.0.26
strings ./anaconda3/pkgs/libstdcxx-ng-9.3.0-hd4cf53a_17/lib/libstdc++.so.6.0.28 | grep GLIBCXX
sudo cp ./anaconda3/pkgs/libstdcxx-ng-9.3.0-hd4cf53a_17/lib/libstdc++.so.6.0.28 /usr/lib/x86_64-linux-gnu
sudo rm /usr/lib/x86_64-linux-gnu/libstdc++.so.6
sudo ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.28 /usr/lib/x86_64-linux-gnu/libstdc++.so.6
Python 3.8.5 (default, Sep 4 2020, 07:30:14)
[GCC 7.3.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
>>> import basicsr
>>>