yasenh / libtorch-yolov5

A LibTorch inference implementation of the yolov5
MIT License
372 stars 114 forks source link

Why is the detection speed slow on GPU? #41

Open Mrgao9 opened 3 years ago

Mrgao9 commented 3 years ago

Dear author, I use yolov5s.pt to detect images. It takes 289 ms per frame on CPU and 127 ms per frame on rtx3070 graphics card. Why is it slow on GPU? Pytorch version yolov5 takes 11 ms per frame on rtx3070 graphics card。

I look forward to your help!

TongShuo-Demon commented 3 years ago

同样想问一下,为什么我在libtorch上面比pytorch还慢?

blackCmd commented 3 years ago

So slow on GPU...... It about 10FPS In Python version, the FPS is 45FPS.

image