low fps and no bounding box on Tensorflow 2

Author: sachinkmohanCreated Apr 25, 2022Updated Nov 19, 2022

I was testing this repository https://github.com/susnato/keras-yolo3 by @susnato on Tensorflow 2.6.0

But when I run the below

bash
python yolo_video.py --model model_data/yolo.h5  --input /home/mohan/git/backups/drive.mp4 --anchors model_data/yolo_anchors.txt --classes model_data/coco_classes.txt

I am getting low fps and no bounding boxes are generated too. Can someone please help.

I was getting the below error when running the inference before

ValueError: Subshape must have computed start >= end since stride is negative, but is 0 and 2 

So I applied the fix given here -> https://stackoverflow.com/questions/57558476/training-a-keras-model-yields-multiple-optimizer-errors

Now my output looks like the below.

https://user-images.githubusercontent.com/26414662/165150438-2456eee1-0d76-4fe7-9c50-4de7283813d3.mp4