Closed kimo20200 closed 3 years ago
Hi Qing,
Can you post the entire error message? It would be more helpful for debugging.
Best, Alex
Hi Alex,
Sorry for that, I will attach my error message below. And I used Anaconda. I do not know if it is fine.
Best wishes, Qing
Error message:
Microsoft Windows [Version 10.0.18363.1316] (c) 2019 Microsoft Corporation. All rights reserved.
C:\Users\Manticket>cd SoftPool/pytorch
C:\Users\Manticket\SoftPool\pytorch>set CUDA_HOME=/usr/local/cuda
C:\Users\Manticket\SoftPool\pytorch>python setup.py install running install running bdist_egg running egg_info writing SoftPool.egg-info\PKG-INFO writing dependency_links to SoftPool.egg-info\dependency_links.txt writing top-level names to SoftPool.egg-info\top_level.txt reading manifest file 'SoftPool.egg-info\SOURCES.txt' writing manifest file 'SoftPool.egg-info\SOURCES.txt' installing library code to build\bdist.win-amd64\egg running install_lib running build_py running build_ext D:\DL\lib\site-packages\torch\utils\cpp_extension.py:287: UserWarning: Error checking compiler version for cl: [WinError 2] The system cannot find the file specified warnings.warn('Error checking compiler version for {}: {}'.format(compiler, error)) building 'softpool_cuda' extension Emitting ninja build file C:\Users\Manticket\SoftPool\pytorch\build\temp.win-amd64-3.8\Release\build.ninja... Compiling objects... Allowing ninja to set a default number of workers... (overridable by setting the environment variable MAX_JOBS=N) [1/2] /usr/local/cuda\bin\nvcc --use-local-env -Xcompiler /MD -Xcompiler /wd4819 -Xcompiler /wd4251 -Xcompiler /wd4244 -Xcompiler /wd4267 -Xcompiler /wd4275 -Xcompiler /wd4018 -Xcompiler /wd4190 -Xcompiler /EHsc -Xcudafe --diag_suppress=base_class_has_different_dll_interface -Xcudafe --diag_suppress=field_without_dll_interface -Xcudafe --diag_suppress=dll_interface_conflict_none_assumed -Xcudafe --diag_suppress=dll_interface_conflict_dllexport_assumed -ID:\DL\lib\site-packages\torch\include -ID:\DL\lib\site-packages\torch\include\torch\csrc\api\include -ID:\DL\lib\site-packages\torch\include\TH -ID:\DL\lib\site-packages\torch\include\THC -I/usr/local/cuda\include -ID:\DL\include -ID:\DL\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\cppwinrt" -c C:\Users\Manticket\SoftPool\pytorch\CUDA\softpool_cuda_kernel.cu -o C:\Users\Manticket\SoftPool\pytorch\build\temp.win-amd64-3.8\Release\CUDA/softpool_cuda_kernel.obj -DCUDA_NO_HALF_OPERATORS -DCUDA_NO_HALF_CONVERSIONS -DCUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=softpool_cuda -D_GLIBCXX_USE_CXX11_ABI=0 -gencode=arch=compute_75,code=sm_75 FAILED: C:/Users/Manticket/SoftPool/pytorch/build/temp.win-amd64-3.8/Release/CUDA/softpool_cuda_kernel.obj /usr/local/cuda\bin\nvcc --use-local-env -Xcompiler /MD -Xcompiler /wd4819 -Xcompiler /wd4251 -Xcompiler /wd4244 -Xcompiler /wd4267 -Xcompiler /wd4275 -Xcompiler /wd4018 -Xcompiler /wd4190 -Xcompiler /EHsc -Xcudafe --diag_suppress=base_class_has_different_dll_interface -Xcudafe --diag_suppress=field_without_dll_interface -Xcudafe --diag_suppress=dll_interface_conflict_none_assumed -Xcudafe --diag_suppress=dll_interface_conflict_dllexport_assumed -ID:\DL\lib\site-packages\torch\include -ID:\DL\lib\site-packages\torch\include\torch\csrc\api\include -ID:\DL\lib\site-packages\torch\include\TH -ID:\DL\lib\site-packages\torch\include\THC -I/usr/local/cuda\include -ID:\DL\include -ID:\DL\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\cppwinrt" -c C:\Users\Manticket\SoftPool\pytorch\CUDA\softpool_cuda_kernel.cu -o C:\Users\Manticket\SoftPool\pytorch\build\temp.win-amd64-3.8\Release\CUDA/softpool_cuda_kernel.obj -DCUDA_NO_HALF_OPERATORS -DCUDA_NO_HALF_CONVERSIONS -DCUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=softpool_cuda -D_GLIBCXX_USE_CXX11_ABI=0 -gencode=arch=compute_75,code=sm_75 CreateProcess failed: The system cannot find the file specified. ninja: fatal: ReadFile: The handle is invalid.
Traceback (most recent call last): File "D:\DL\lib\site-packages\torch\utils\cpp_extension.py", line 1533, in _run_ninja_build subprocess.run( File "D:\DL\lib\subprocess.py", line 512, in run raise CalledProcessError(retcode, process.args, subprocess.CalledProcessError: Command '['ninja', '-v']' returned non-zero exit status 1.
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "setup.py", line 4, in
Hi Qing,
From this line: D:\DL\lib\site-packages\torch\utils\cpp_extension.py:287: UserWarning: Error checking compiler version for cl: [WinError 2] The system cannot find the file specified
. I am assuming that the problem is with the compiler cl
not being found by torch for cpp_extension
. Since I have not tested the install for Windows I can only suggest a couple of things:
cpp_extension.py
so you could debug it and see which of the four lines fails (the filepath based on the error is "D:\DL\lib\site-packages\torch\utils\cpp_extension.py")Hope that any of the above helps!
Best, Alex
Hi Alex,
Thank you for your answer. I will try by myself.
Best wishes, Qing
Will close this for now, but feel free to re-open it if the issue re-occurs.
Best, Alex
Hi Alex,
I just got a problem for installation. The error is: 'RuntimeError: Error compiling objects for extension'. I am using pytorch 1,7 and cuda 10.1. I do not know if it is related to my Pytorch or CUDA version. Do you have any advice?
Best wishes, Qing