onnx / onnx-tensorrt

ONNX-TensorRT: TensorRT backend for ONNX
Apache License 2.0
2.95k stars 545 forks source link

CMake Failed #1001

Open henry-fung opened 5 days ago

henry-fung commented 5 days ago

Description

While running this command :

cmake . -DCUDA_INCLUDE_DIRS=/usr/local/cuda/include -DTENSORRT_ROOT=/usr/src/tensorrt -DCMAKE_CUDA_COMPILER=/usr/local/cuda/bin/nvcc

I got below error:

Generated: /home/azureuser/onnx-tensorrt/build/third_party/onnx/onnx/onnx_onnx2trt_onnx-ml.proto
Generated: /home/azureuser/onnx-tensorrt/build/third_party/onnx/onnx/onnx-operators_onnx2trt_onnx-ml.proto
Generated: /home/azureuser/onnx-tensorrt/build/third_party/onnx/onnx/onnx-data_onnx2trt_onnx.proto`
--
-- ******** Summary ********
--   CMake version                     : 3.22.1
--   CMake command                     : /usr/bin/cmake
--   System                            : Linux
--   C++ compiler                      : /usr/bin/c++
--   C++ compiler version              : 11.4.0
--   CXX flags                         :  -Wall -Wno-deprecated-declarations -Wno-unused-function -Wnon-virtual-dtor
--   Build type                        : Release
--   Compile definitions               : SOURCE_LENGTH=30;ONNX_NAMESPACE=onnx2trt_onnx;__STDC_FORMAT_MACROS
--   CMAKE_PREFIX_PATH                 :
--   CMAKE_INSTALL_PREFIX              : /usr/local
--   CMAKE_MODULE_PATH                 :
--
--   ONNX version                      : 1.17.0
--   ONNX NAMESPACE                    : onnx2trt_onnx
--   ONNX_USE_LITE_PROTO               : OFF
--   USE_PROTOBUF_SHARED_LIBS          : OFF
--   Protobuf_USE_STATIC_LIBS          : ON
--   ONNX_DISABLE_EXCEPTIONS           : OFF
--   ONNX_DISABLE_STATIC_REGISTRATION  : OFF
--   ONNX_WERROR                       : OFF
--   ONNX_BUILD_TESTS                  : OFF
--   ONNX_BUILD_SHARED_LIBS            :
--   BUILD_SHARED_LIBS                 :
--
--   Protobuf compiler                 : /usr/local/bin/protoc
--   Protobuf includes                 : /usr/local/include
--   Protobuf libraries                : /usr/local/lib/libprotobuf.a
--   BUILD_ONNX_PYTHON                 : OFF
-- Found CUDA headers at /usr/local/cuda/include
-- Found TensorRT headers at /usr/include/x86_64-linux-gnu
Found TensorRT Python headers at TENSORRT_PYTHON_INCLUDE_DIR-NOTFOUND
-- Configuring done
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
/home/azureuser/onnx-tensorrt/TENSORRT_PYTHON_INCLUDE_DIR
   used as include directory in directory /home/azureuser/onnx-tensorrt
   used as include directory in directory /home/azureuser/onnx-tensorrt

-- Generating done
CMake Generate step failed.  Build files cannot be regenerated correctly.

What is TENSORRT_PYTHON_INCLUDE_DIR? And how it is configured?

Environment

TensorRT Version: 10.5.0 ONNX-TensorRT Version / Branch: master GPU Type: V100 Nvidia Driver Version: 550.120 CUDA Version: 12.4 CUDNN Version: 9.1.0.70 Operating System + Version: Ubuntu 22.04