ibaiGorordo / ONNX-YOLOv8-Object-Detection

Python scripts performing object detection using the YOLOv8 model in ONNX.
MIT License
369 stars 93 forks source link

Capture resulting video? #9

Closed noobtoob4lyfe closed 1 year ago

noobtoob4lyfe commented 1 year ago

Thanks for sharing this great work! How did you go about capture the resulting video that your uploaded to youtube. I can see the object detection working great in the veiwport but there is no resulting "output.mp4". Here is what I'm using but the resulting video is 1kb and blank when I open it.

"# # Initialize video cap = cv2.VideoCapture("Test.mp4")

out = cv2.VideoWriter('output.mov', cv2.VideoWriter_fourcc('M', 'J', 'P', 'G'), 30, (1280, 720))"

I'm also seeing this which could be a problem? "OpenCV: FFMPEG: tag 0x47504a4d/'MJPG' is not supported with codec id 7 and format 'mov / QuickTime / MOV' OpenCV: FFMPEG: fallback to use tag 0x6765706a/'jpeg'"

noobtoob4lyfe commented 1 year ago

NM I figured it out