Anaconda Integration with Cuda 9.0 shows Incompatible Package Error

Viewed 6001

I am trying to install CUDA 9.0 with NVIDIA-SMI: 445.75 in Windows 10.

My Cuda 9.0 installation is successful, as shown from Command-prompt

*(DL) C:\Users\User>nvcc --version    
nvcc: NVIDIA (R) Cuda compiler driver    
Copyright (c) 2005-2017 NVIDIA Corporation    
Built on Fri_Sep__1_21:08:32_Central_Daylight_Time_2017    
**Cuda compilation tools, release **9.0**, V9.0.176***

(1) I downloaded cudnn-9.0-windows10-x64-v7.zip, extracted it, and moved it to the fold, which was created when Cuda was installed.

(2) In the terminal prompt of the Anaconda,
I input conda install pytorch=1.1.0 torchvision=0.3.0 cudatoolkit=9.0 –c pytorch.

However, Anaconda prompt gives the following error

**Error messages**    
*Collecting package metadata (current_repodata.json): done    
Solving environment: failed with initial frozen solve. Retrying with flexible solve.    
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.    
Collecting package metadata (repodata.json): done    
Solving environment: failed with initial frozen solve. Retrying with flexible solve.    
Solving environment: |    
Found conflicts! Looking for incompatible packages.    
This can take several minutes.  Press CTRL-C to abort.    
failed    

UnsatisfiableError: The following specifications were found to be incompatible with the existing python installation in your environment:    

Specifications:    

  - pytorch=1.1.0 -> python[version='>=3.5,<3.6.0a0|>=3.6,<3.7.0a0|>=3.7,<3.8.0a0']    
  - torchvision=0.3.0 -> python[version='>=3.5,<3.6.0a0|>=3.6,<3.7.0a0|>=3.7,<3.8.0a0']    

Your python: python=3.8    

If python is on the left-most side of the chain, that's the version you've asked for.
When python appears to the right, that indicates that the thing on the left is somehow not available for the python version you are constrained to. Note that conda will not change your python version to a different minor version unless you explicitly specify that.

The following specifications were found to be incompatible with each other:

Output in format: Requested package -> Available versions    

Package cudatoolkit conflicts for:    

    torchvision=0.3.0 -> cudatoolkit[version='>=10.0,<10.1|>=9.0,<9.1']    
    pytorch=1.1.0 -> cudatoolkit[version='>=10.0,<10.1|>=9.0,<9.1']    
    torchvision=0.3.0 -> pytorch[version='>=1.1.0'] -> cudatoolkit[version='>=10.1,<10.2|>=9.2,<9.3']The following specifications were found to be incompatible with your CUDA driver:    

      - feature:/win-64::__cuda==11.0=0    

    Your installed CUDA driver is: 11.0*    
3 Answers

I got solved this issue as follows.

  1. Open Anaconda Powershell Prompt by searching it on the start menu.
  2. then run conda install -c anaconda tensorflow-gpu command.
  3. it may be asked to your acceptance.

finally tensorflow-gpu listed on the installed list.

Reference: https://anaconda.org/anaconda/tensorflow-gpu

I had the same problem when installing rpy2, so maybe this helps here, too. It turned out to be a problem of the conda source. For me it worked when using:

conda install -c conda-forge <library_name>

Replacing <library_name> with the libary you want to install.

Probably you are trying to run someone else's code. So, the installed conda is incompatible with your python version. Probably your python version is too old, while conda is new. As far as I know, you have 2 options (both are bad though):

1. Downgrade your conda

2. Install newer python and try to run your code. If you face errors, try to fix them with coding, for example: replace depricated function.

As I said these solutions are not the best ones, but you can try

Related