[BUG]Installation Error on Torch while Torch is Installed
C:\>python -m pip install deepspeed
Collecting deepspeed
Using cached deepspeed-0.17.6.tar.gz (1.6 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... error
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> [26 lines of output]
[WARNING] Unable to import torch, pre-compiling ops will be disabled. Please visit https://pytorch.org/ to see how to properly install torch on your system.
[WARNING] unable to import torch, please install it if you want to pre-compile any deepspeed ops.
DS_BUILD_OPS=1
But Torch is clearly installed:
C:\>python
Python 3.13.3 (tags/v3.13.3:6280bb5, Apr 8 2025, 14:47:33) [MSC v.1943 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
>>> print(torch.__version__)
2.8.0+cu128
>>> print(torch.cuda.is_available())
True
>>> exit()
I have tried --no-build-isolation as mentioned in https://github.com/deepspeedai/DeepSpeed/issues/3329, but it continues to have error:
in installed_cuda_version
raise MissingCUDAException("CUDA_HOME does not exist, unable to compile CUDA op(s)")
op_builder.builder.MissingCUDAException: CUDA_HOME does not exist, unable to compile CUDA op(s)
I have also noticed https://github.com/deepspeedai/DeepSpeed/issues/7286, but no solution was reached.
I was expecting the latest version could have better support for Windows compatibility as 3329 was closed.
@evencogitate - are you trying to use DeepSpeed on Windows then? We've not published new Windows wheels lately, and the Windows version is tied to the python and torch versions as well.
Yes. May I know which version of python and torch I shall use?
I've encountered the same problem and look forward to an answer.