Is the installation supported on Windows 10?
See original GitHub issueIs the installation supported on Windows 10?
I have installed TensorRT on my windows. When I installe it on windows 10 I got this issue: Cannot open include file: ‘NvInfer.h’: No such file or directory
\torch2trt>python setup.py install --plugins
running install
running bdist_egg
running egg_info
writing torch2trt.egg-info\PKG-INFO
writing dependency_links to torch2trt.egg-info\dependency_links.txt
writing top-level names to torch2trt.egg-info\top_level.txt
reading manifest file 'torch2trt.egg-info\SOURCES.txt'
writing manifest file 'torch2trt.egg-info\SOURCES.txt'
installing library code to build\bdist.win-amd64\egg
running install_lib
running build_py
running build_ext
C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\utils\cpp_extension.py:270: 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 'plugins' extension
Emitting ninja build file C:\Users\bigtree\Documents\prototype\segmentation\torch2trt\build\temp.win-amd64-3.7\Release\build.ninja...
Compiling objects...
Allowing ninja to set a default number of workers... (overridable by setting the environment variable MAX_JOBS=N)
[1/1] cl /showIncludes /nologo /Ox /W3 /GL /DNDEBUG /MD /MD /wd4819 /wd4251 /wd4244 /wd4267 /wd4275 /wd4018 /wd4190 /EHsc -I/usr/include/aarch64-linux-gnu -IC:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\include -IC:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\include\torch\csrc\api\include -IC:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\include\TH -IC:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\include\THC "-IC:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\include" -IC:\Users\bigtree\.conda\envs\pytorch_env\include -IC:\Users\bigtree\.conda\envs\pytorch_env\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29910\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29910\include" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\include\um" "-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\bigtree\Documents\prototype\segmentation\torch2trt\torch2trt\plugins\plugins.cpp /FoC:\Users\bigtree\Documents\prototype\segmentation\torch2trt\build\temp.win-amd64-3.7\Release\torch2trt/plugins/plugins.obj -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=plugins -D_GLIBCXX_USE_CXX11_ABI=0 /std:c++14
FAILED: C:/Users/bigtree/Documents/prototype/segmentation/torch2trt/build/temp.win-amd64-3.7/Release/torch2trt/plugins/plugins.obj
cl /showIncludes /nologo /Ox /W3 /GL /DNDEBUG /MD /MD /wd4819 /wd4251 /wd4244 /wd4267 /wd4275 /wd4018 /wd4190 /EHsc -I/usr/include/aarch64-linux-gnu -IC:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\include -IC:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\include\torch\csrc\api\include -IC:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\include\TH -IC:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\include\THC "-IC:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\include" -IC:\Users\bigtree\.conda\envs\pytorch_env\include -IC:\Users\bigtree\.conda\envs\pytorch_env\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29910\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29910\include" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\include\um" "-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\bigtree\Documents\prototype\segmentation\torch2trt\torch2trt\plugins\plugins.cpp /FoC:\Users\bigtree\Documents\prototype\segmentation\torch2trt\build\temp.win-amd64-3.7\Release\torch2trt/plugins/plugins.obj -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=plugins -D_GLIBCXX_USE_CXX11_ABI=0 /std:c++14
C:\Users\bigtree\Documents\prototype\segmentation\torch2trt\torch2trt\plugins\interpolate.cpp(6): fatal error C1083: Cannot open include file: 'NvInfer.h': No such file or directory
ninja: build stopped: subcommand failed.
Traceback (most recent call last):
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\utils\cpp_extension.py", line 1515, in _run_ninja_build
env=env)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\subprocess.py", line 512, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['ninja', '-v']' returned non-zero exit status 1.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "setup.py", line 45, in <module>
cmdclass={'build_ext': BuildExtension}
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\setuptools\__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\dist.py", line 966, in run_commands
self.run_command(cmd)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\setuptools\command\install.py", line 67, in run
self.do_egg_install()
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\setuptools\command\install.py", line 109, in do_egg_install
self.run_command('bdist_egg')
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\setuptools\command\bdist_egg.py", line 164, in run
cmd = self.call_command('install_lib', warn_dir=0)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\setuptools\command\bdist_egg.py", line 150, in call_command
self.run_command(cmdname)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\setuptools\command\install_lib.py", line 11, in run
self.build()
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\command\install_lib.py", line 107, in build
self.run_command('build_ext')
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\setuptools\command\build_ext.py", line 79, in run
_build_ext.run(self)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\Cython\Distutils\old_build_ext.py", line 186, in run
_build_ext.build_ext.run(self)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\command\build_ext.py", line 340, in run
self.build_extensions()
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\utils\cpp_extension.py", line 649, in build_extensions
build_ext.build_extensions(self)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\Cython\Distutils\old_build_ext.py", line 195, in build_extensions
_build_ext.build_ext.build_extensions(self)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\command\build_ext.py", line 449, in build_extensions
self._build_extensions_serial()
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\command\build_ext.py", line 474, in _build_extensions_serial
self.build_extension(ext)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\setuptools\command\build_ext.py", line 196, in build_extension
_build_ext.build_extension(self, ext)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\distutils\command\build_ext.py", line 534, in build_extension
depends=ext.depends)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\utils\cpp_extension.py", line 631, in win_wrap_ninja_compile
with_cuda=with_cuda)
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\utils\cpp_extension.py", line 1233, in _write_ninja_file_and_compile_objects
error_prefix='Error compiling objects for extension')
File "C:\Users\bigtree\.conda\envs\pytorch_env\lib\site-packages\torch\utils\cpp_extension.py", line 1529, in _run_ninja_build
raise RuntimeError(message)
RuntimeError: Error compiling objects for extension
Please help.
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (1 by maintainers)
Top Results From Across the Web
Get help with Windows upgrade and installation errors
See some of the most common upgrade and installation errors for Windows 10 and Windows 11, and what you can do to try...
Read more >Check Windows 10 System Requirements & Specs - Microsoft
System requirements for installing Windows 10 ; Processor: 1 gigahertz (GHz) or faster compatible processor or System on a Chip (SoC) ; RAM:...
Read more >Windows 10 system requirements - Microsoft Support
Windows 10 system requirements ; Processor: 1 gigahertz (GHz) or faster processor or SoC ; RAM: 1 gigabyte (GB) for 32-bit or 2...
Read more >Windows 10 Enterprise: FAQ for IT professionals
Get answers to common questions around compatibility, installation, and support for Windows 10 Enterprise.
Read more >Download Windows 10 - Microsoft
Create Windows 10 installation media · Attach the USB flash drive or insert the DVD on the PC where you want to install...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I solved it; you must modify the
setup.py
file, let it known where is you tensorRT path of include and libI modified it to look like this
Convert line No.1496 into command = [‘ninja’, ‘–version’].