YuHengsss / YOLOV

This repo is an implementation of PyTorch version YOLOV Series
Apache License 2.0
278 stars 39 forks source link

Error using vid_demo.py #58

Closed medinaltbx closed 1 year ago

medinaltbx commented 1 year ago

First of all, thanks for your work, it's really useful.

I'm facing an error using the vid_demo.py for video inference using YOLOV\exps\yolov\yolov_s.py and YOLOV\weights\yolov_s.pth. The error I'm getting is ZeroDivisionError: float division by zero when trying to test the inference on a custom video. I provide a screenshot of the error below:

image

I just followed the instalation steps as referred on the README.md file, using a conda environment. I'm running it on Windows 11.

YuHengsss commented 1 year ago

Please check the --path parameter, it seems opencv doesn't get the video

medinaltbx commented 1 year ago

Thanks for answering so quickly.

It seems that is something going on with the video. Before running vid_demo.py, my target video looks normal:

image

However, after running the script the video seems corrupt somehow:

image

image

After this, the video is no longer readable

medinaltbx commented 1 year ago

The error occured because the video file was corrupted.