DanaHan / Yolov5-in-Deepstream-5.0

Describe how to use yolov5 in Deepstream 5.0
209 stars 57 forks source link

在运行sudo ./yolov5 -s的时候遇到这个错,我用的是自己训练的权重,已经在yololayer.h中修改了类别数还是不行 #25

Open imustwangxin opened 3 years ago

imustwangxin commented 3 years ago

Loading weights: ../yolov5l.wts [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 Building engine, please wait for a while... [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: kernel weights has count 8640 but 6912 was expected [04/29/2021-13:04:16] [E] [TRT] (Unnamed Layer 5) [Convolution]: count of 8640 weights in kernel, but kernel dimensions (3,3) with 12 input channels, 64 output channels and 1 groups were specified. Expected Weights count is 12 33 64 / 1 = 6912 [04/29/2021-13:04:16] [E] [TRT] Could not compute dimensions for (Unnamed Layer* 5) [Convolution]_output, because the network is not valid [04/29/2021-13:04:16] [E] [TRT] Network validation failed. Build engine successfully! yolov5: /home/sources/Yolov5-in-Deepstream-5.0/yolov5.cpp:440: void APIToModel(unsigned int, nvinfer1::IHostMemory**): Assertion `engine != nullptr' failed. Aborted (core dumped)

zhaoxiaolong2020 commented 3 years ago

你解决了么?我怀疑是yolov5的版本不一样导致的,我用的yolov5-v5.0也报错,你有没有尝试yolov5-v3.0或者3.1

imustwangxin commented 3 years ago

你用yolov5s试一下,我都用s解决了,其他的还没试

Sent from my iPhone

On May 13, 2021, at 14:35, zhaoxiaolong2020 @.***> wrote:

 你解决了么?我怀疑是yolov5的版本不一样导致的,我用的yolov5-v5.0也报错,你有没有尝试yolov5-v3.0或者3.1

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

zhaoxiaolong2020 commented 3 years ago

你用yolov5s试一下,我都用s解决了,其他的还没试 Sent from my iPhone On May 13, 2021, at 14:35, zhaoxiaolong2020 @.***> wrote:  你解决了么?我怀疑是yolov5的版本不一样导致的,我用的yolov5-v5.0也报错,你有没有尝试yolov5-v3.0或者3.1 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

我用的也是yolo5s, 你用的是yolov5-v5.0这个版本还是3.1 or 3.0 这两个版本

imustwangxin commented 3 years ago

3.0的

Sent from my iPhone

On May 13, 2021, at 19:45, zhaoxiaolong2020 @.***> wrote:

 你用yolov5s试一下,我都用s解决了,其他的还没试 … Sent from my iPhone On May 13, 2021, at 14:35, zhaoxiaolong2020 @.***> wrote:  你解决了么?我怀疑是yolov5的版本不一样导致的,我用的yolov5-v5.0也报错,你有没有尝试yolov5-v3.0或者3.1 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

我用的也是yolo5s, 你用的是yolov5-v5.0这个版本还是3.1 or 3.0 这两个版本

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

1057520143 commented 2 years ago

3.0的 Sent from my iPhone On May 13, 2021, at 19:45, zhaoxiaolong2020 @.> wrote:  你用yolov5s试一下,我都用s解决了,其他的还没试 … Sent from my iPhone On May 13, 2021, at 14:35, zhaoxiaolong2020 @.> wrote:  你解决了么?我怀疑是yolov5的版本不一样导致的,我用的yolov5-v5.0也报错,你有没有尝试yolov5-v3.0或者3.1 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. 我用的也是yolo5s, 你用的是yolov5-v5.0这个版本还是3.1 or 3.0 这两个版本 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

可能是yolov5版本不一样,去https://github.com/wang-xinyu/tensorrtx/tree/master/yolov5看看版本