iArunava / YOLOv3-Object-Detection-with-OpenCV

This project implements a real-time image and video object detection classifier using pretrained yolov3 models.
MIT License
320 stars 173 forks source link

AttributeError: 'NoneType' object has no attribute 'release' #10

Open Donostia opened 4 years ago

Donostia commented 4 years ago

I was trying to run "python3 yolo.py --video-path='/media/lamp-moving.mpg". (I am using 4.1.0 version of cv2)

And then the following error comes up:

Traceback (most recent call last): File "yolo.py", line 146, in writer.release() AttributeError: 'NoneType' object has no attribute 'release'

Thank you

GreatBruceYoung commented 4 years ago

I met the same error! I want to know whether you have solved the error or not. Thank you.

abhinavkaul95 commented 3 years ago

Don't know whether it is needed or not, but faced the same issue and it seems that the issue is faced when the video is not at that path. Check if the video path is correct or there is a video file on that path.