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

AttributeError: module 'torch.cuda' has no attribute 'get_arch_list' #29

Open
xy2012 opened this issue Apr 8, 2021 · 3 comments
Open

Comments

@xy2012
Copy link

xy2012 commented Apr 8, 2021

I tried to build a docker following the Dockerfile. When executing the last command--python setup.py install--in cule folder, I got the error:

Traceback (most recent call last):
File "setup.py", line 12, in
codes = [arch[-2] + '0' for arch in torch.cuda.get_arch_list()]
AttributeError: module 'torch.cuda' has no attribute 'get_arch_list'

In the docker, my os is 18.04.2-Ubuntu with cuda 10.0 , torch 1.2.0. I noticed that there is no get_arch_list() method in /usr/local/lib/python3.6/dist-packages/torch/cuda/init.py. Though torch 1.8.0 has attribute 'get_arch_list', torch 1.2.0 seems to be the highest version that matches with cuda 10.0.

I'm confused. How can I fix the bug? Many thanks.

@danielsnider
Copy link

Me too

@danielsnider
Copy link

I'm finding that the code works better when running from commit "Updated support for multiple architectures during compilation". Since then they tried updating the Cuda and PyTorch version which leads to more problems for me.

@Rohan138
Copy link

You might also want to try:
#34 (comment)

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

3 participants