Description
Hi, guys.
I have two YOLOV3 models trained: a) YOLOV3 (https://github.com/ultralytics/yolov3/blob/master/cfg/yolov3-1cls.cfg) and b) YOLOV3 SPP3 (https://github.com/ultralytics/yolov3/blob/master/cfg/yolov3-spp3.cfg). The second one I did the modification to one class.
I’ve converted these models to TensorRT. (YOLOV3 > ONNX > TensorRT). When I’ve tested, the first model ran well, detections, etc. But, when I’ve tested the second one, I’ve got a strange error and I don’t know how solve it. The error message was:
for output, shape in zip(trt_outputs, self.output_shapes)] ValueError: cannot reshape array of size 173056 into shape (1,18,13,13)
I’ve printed the tensor sizes of the trt_outputs list and I’ve got these two situations:
a) YOLOV3: 3042, 12168, 48672
b) YOLOV3 SPP3: 173056, 346112, 692224
In both cases, I’m using the same image to test.
Environment
tensorrt 7.1.3.4
onnx 1.4.1
pycuda 2019.1.2
torch 1.6.0
Relevant Files
a) YOLOV3 (https://github.com/ultralytics/yolov3/blob/master/cfg/yolov3-1cls.cfg)
b) YOLOV3 SPP3 (https://github.com/ultralytics/yolov3/blob/master/cfg/yolov3-spp3.cfg).
Steps To Reproduce
Implementation used to conversion process: