Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CMake fails for CUDA 11 #1622

Open
alchernyavskiy opened this issue Oct 27, 2020 · 5 comments
Open

CMake fails for CUDA 11 #1622

alchernyavskiy opened this issue Oct 27, 2020 · 5 comments

Comments

@alchernyavskiy
Copy link

Hi,

Running pip install or cmake from source produces the following error for CUDA 11:

nvcc fatal : Unsupported gpu architecture 'compute_30' failed

Does anyone know how to fix it?

@neubig
Copy link
Contributor

neubig commented Oct 27, 2020

Try removing the parts of this line that refer to compute_30:
https://github.com/clab/dynet/blob/master/dynet/CMakeLists.txt#L265

We may have to update this file to cover more recent architectures, please tell me if this works and I'll do so if so.

@alchernyavskiy
Copy link
Author

Try removing the parts of this line that refer to compute_30:
https://github.com/clab/dynet/blob/master/dynet/CMakeLists.txt#L265

We may have to update this file to cover more recent architectures, please tell me if this works and I'll do so if so.

I managed to build it for cuda 11 without any errors. However, during python import it prints
ImportError: libcublas.so.10: cannot open shared object file: No such file or directory

I used the following command for cmake:
cmake .. -DEIGEN3_INCLUDE_DIR=../../eigen -DPYTHON='which python' -DBACKEND=cuda -DCUDA_TOOLKIT_ROOT_DIR=/usr/local/cuda-11.1 -DCUDA_ARCH=61

@heeh
Copy link

heeh commented Nov 5, 2020

Same error. Removing compute_30 does not help.

nvcc fatal : Unsupported gpu architecture 'compute_30'
CMake Error at dynet_generated_gpu-ops.cu.o.Release.cmake:215 (message):
Error generating
/tmp/pip-install-9ldty3ty/dynet/build/py3.7-64bit/dynet/CMakeFiles/dynet.dir//./dynet_generated_gpu-ops.cu.o

@heeh
Copy link

heeh commented Nov 5, 2020

Was able to change it to compute_60, which corresponds to NVIDIA tesla P100
Also, the Eigen repository is broken; had to download manually.
wget https://github.com/clab/dynet/releases/download/2.1/eigen-b2e267dc99d4.zip

@tranhoangkhuongvn
Copy link

I have this exact error when trying to compile on GPU RTX3090, any help would be appreciated!
I tried the above 2 suggestions by either removing compute_30 or replace it with compute_60 but it does not fix the error.

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants