DeepSpeed icon indicating copy to clipboard operation
DeepSpeed copied to clipboard

FileNotFoundError: [Errno 2] No such file or directory: ':/usr/local/cuda/bin/nvcc'

Open 1148514800 opened this issue 1 year ago • 1 comments

When i pip install deepspeed, it seems to have a bug. How can i solve it.

error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully. │ exit code: 1 ╰─> [16 lines of output] Traceback (most recent call last): File "", line 2, in File "", line 34, in File "/tmp/pip-install-sk7po78o/deepspeed_d20b3db44cb14797a404b2aa6363909d/setup.py", line 100, in cuda_major_ver, cuda_minor_ver = installed_cuda_version() File "/tmp/pip-install-sk7po78o/deepspeed_d20b3db44cb14797a404b2aa6363909d/op_builder/builder.py", line 52, in installed_cuda_version output = subprocess.check_output([cuda_home + "/bin/nvcc", "-V"], universal_newlines=True) File "/home/hpclp/anaconda3/envs/qwen/lib/python3.8/subprocess.py", line 415, in check_output return run(*popenargs, stdout=PIPE, timeout=timeout, check=True, File "/home/hpclp/anaconda3/envs/qwen/lib/python3.8/subprocess.py", line 493, in run with Popen(*popenargs, **kwargs) as process: File "/home/hpclp/anaconda3/envs/qwen/lib/python3.8/subprocess.py", line 858, in init self._execute_child(args, executable, preexec_fn, close_fds, File "/home/hpclp/anaconda3/envs/qwen/lib/python3.8/subprocess.py", line 1720, in _execute_child raise child_exception_type(errno_num, err_msg, err_filename) FileNotFoundError: [Errno 2] No such file or directory: ':/usr/local/cuda/bin/nvcc' [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: metadata-generation-failed

× Encountered error while generating package metadata. ╰─> See above for output.

note: This is an issue with the package mentioned above, not pip. hint: See above for details.

1148514800 avatar May 09 '24 03:05 1148514800

Hi @1148514800 - do you have nvcc installed? Are you able to run which nvcc or nvcc --version

loadams avatar May 14 '24 15:05 loadams

Hi, I can run which nvcc. I have solved this problem by export CUDA_HOME=/usr/local/cuda. But I still want to thank you!

1148514800 avatar May 15 '24 08:05 1148514800

Thanks @1148514800 - that's good, I'm glad the issue is resolved and sorry for the delay in replying. I'll close the issue now but if you hit any others, please feel free to open a new issue.

loadams avatar May 15 '24 15:05 loadams

I got same error, can not resolved, why? nvcc are there, and cuda 12.1 are installed right.

lucasjinreal avatar May 27 '24 14:05 lucasjinreal

I got same error, can not resolved, why? nvcc are there, and cuda 12.1 are installed right.

just export CUDA_HOME=/usr/local/cuda before you install, i solve it. Hope it useful for you.

1148514800 avatar May 28 '24 13:05 1148514800

I got same error, can not resolved, why? nvcc are there, and cuda 12.1 are installed right.

just export CUDA_HOME=/usr/local/cuda before you install, i solve it. Hope it useful for you.

This solves my issue! thanks a lot!

milliema avatar Jul 30 '24 10:07 milliema