Reason: Pytorch and CUDA versions are not right
(It is also possible that there is not enough memory space, you can change the virtual space size)
Uninstall Pytorch: Conda Uninstall Pytorch, and if you install CUDA, it will automatically override the CUDA version.
Open CMD and type from the command line
import torch
print(torch.__version__)
print(torch.version.cuda)
Similar errors occur if the cudA version is not installed with the torch version.
Here’s how to install CUDA:
1. Open the NVIDIA control panel to view the CUDA version supported by the current video card driver:
2. Download CUDA address
https://developer.nvidia.com/cuda-toolkit-archive
Or offline installation package download required in https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch/linux-64/. Tar..bz2
Background Conda Install XXXX.. tar.bz2
Install after installation is complete
First anaconda Conda switches to the domestic source
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/
conda config --set show_channel_urls yes
Conda Install Pytorch Torchvision Cudatoolkit =10.0
Install other packages
Pytorch official website: Pytorch official website
Download according to the actual situation:
3. After successful download, double-click the exe file to install.
The verification method for successful installation is to enter nvcc-v
under CMD
The installation was successful. You can see in system variables:
Or you can see nvCC.exe under the installation path
Read More:
- CONDA install torch error
- Anaconda opens Navigator to report an error and a web page appears Navigator Error An unexpected error occurred on Navigator start-up Report
- Anaconda returns Python 3.7 to Python 3.6
- Condahttperror:HTTP000 Connection Failed for URL https://repo.anaconda.com/pkgs/main/win-6
- Error condahtterror: http 000 connection failed
- Conda HTTP 000 CONNECTION FAILED for url
- AttributeError: module ‘keras.backend‘ has no attribute ‘eager‘
- Solving environment: failed solution to the problem encountered when updating Anaconda
- To solve the problem of importerror when installing tensorflow: libcublas.so . 10.0, failed to load the native tensorflow runtime error
- Pytorch RuntimeError CuDNN error CUDNN_STATUS_SUCCESS (How to Fix)
- Anaconda builds a new environment and installs sklearn, numpy and other modules
- RuntimeError: cuDNN error: CUDNN_ STATUS_ EXECUTION_ Failed solutions
- FCOS No CUDA runtime is found, using CUDA_HOME=’/usr/local/cuda-10.0′
- Ubuntu 18.04 desktop installation tasksel aptitude failed (100) problem repair
- An error occurred when installing pytorch version 1.7 GPU
- Problems encountered in the installation of pyromacoustics
- Pysot installation and model testing
- RuntimeError: cuDNN error: CUDNN_STATUS_EXECUTION_FAILED
- torch.cuda.is_ Available() returns false
- Attributeerror: module “Seaborn” has no attribute “lineplot”