-
-
Notifications
You must be signed in to change notification settings - Fork 56.5k
Assertion failure when accessing a video file in icvExtractPattern #17879
Copy link
Copy link
Closed
Description
System information (version)
- OpenCV => 4.4.0 (from git)
- Operating System / Platform => Linux
- Compiler => Clang
Detailed description
When I open a video file, I get this error:
[ERROR:0] global opencv/modules/videoio/src/cap.cpp (142) open VIDEOIO(CV_IMAGES): raised OpenCV exception:
OpenCV(4.4.0-pre) opencv/modules/videoio/src/cap_images.cpp:267: error: (-215:Assertion failed) number < max_number in function 'icvExtractPattern'
It doesn't seem harmful, as the program does continue running even though it claims to be an assertion failure.
Steps to reproduce
It's hard to tell precisely which line of code generates the message but I believe I am just running:
video = cv2.VideoCapture(args.video)
video.set(cv2.CAP_PROP_POS_FRAMES, workunit[0])
timestamp = int(video.get(cv2.CAP_PROP_POS_MSEC))
success, frame = video.read()
The input is an .avi file I believe using MJPEG as the codec. I can get more info if needed.
Enabled backends(7, sorted by priority): FFMPEG(1000); GSTREAMER(990); INTEL_MFX(980); MSMF(970); V4L2(960); CV_IMAGES(950); CV_MJPEG(940)
Issue submission checklist
- I report the issue, it's not a question
- I checked the problem with documentation, FAQ, open issues,
answers.opencv.org, Stack Overflow, etc and have not found solution - I updated to latest OpenCV version and the issue is still there
- There is reproducer code and related data files: videos, images, onnx, etc
Reactions are currently unavailable