Description
I am trying to convert YoloV5 (Pytorch) model to tensorrt INT8. I have taken 90 images which I stored in calibration folder and I have created the image directory text file (valid_calibartion.txt)
Error
undefined reference to Int8EntropyCalibrator2::Int8EntropyCalibrator2(int, int, int, char const*, char const*, char const*, bool)' CMakeFiles/yolov5.dir/yolov5.cpp.o: In function
createEngine_m(unsigned int, nvinfer1::IBuilder*, nvinfer1::IBuilderConfig*, nvinfer1::DataType)‘:
/Downloads/tensorrtx-master_2/yolov5/tensorrtx-master/yolov5/INT8_yolov5/yolov5.cpp:214: undefined reference to Int8EntropyCalibrator2::Int8EntropyCalibrator2(int, int, int, char const*, char const*, char const*, bool)' CMakeFiles/yolov5.dir/yolov5.cpp.o: In function
createEngine_l(unsigned int, nvinfer1::IBuilder*, nvinfer1::IBuilderConfig*, nvinfer1::DataType)’:
/Downloads/tensorrtx-master_2/yolov5/tensorrtx-master/yolov5/INT8_yolov5/yolov5.cpp:313: undefined reference to Int8EntropyCalibrator2::Int8EntropyCalibrator2(int, int, int, char const*, char const*, char const*, bool)' CMakeFiles/yolov5.dir/yolov5.cpp.o: In function
createEngine_x(unsigned int, nvinfer1::IBuilder*, nvinfer1::IBuilderConfig*, nvinfer1::DataType)‘:
/tensorrtx-master_2/yolov5/tensorrtx-master/yolov5/INT8_yolov5/yolov5.cpp:413: undefined reference to `Int8EntropyCalibrator2::Int8EntropyCalibrator2(int, int, int, char const*, char const*, char const*, bool)’
collect2: error: ld returned 1 exit status
CMakeFiles/yolov5.dir/build.make:114: recipe for target ‘yolov5’ failed
make[2]: *** [yolov5] Error 1
CMakeFiles/Makefile2:67: recipe for target ‘CMakeFiles/yolov5.dir/all’ failed
make[1]: *** [CMakeFiles/yolov5.dir/all] Error 2
Makefile:83: recipe for target ‘all’ failed
make: *** [all] Error 2
Environment
TensorRT Version: 6.0.1.5
GPU Type: GeForce RTX 2060/PCIe/SSE2
Nvidia Driver Version: 418.67
CUDA Version: 10.1
CUDNN Version: 10
Operating System + Version: Ubuntu +16.04
Python Version (if applicable): 3.6
PyTorch Version (if applicable): 1.6.0
Relevant Files
Github Link : tensorrtx/yolov5 at master · wang-xinyu/tensorrtx · GitHub