unstable frame count
Hi, I am getting different frame count for the same video on different machines.
Video usedhttp://commondatastorage.googleapis.c...
Code used to find frame count:
import cv2
cap= cv2.VideoCapture("BigBuckBunny.mp4")
i=0
while(cap.isOpened()):
ret, frame = cap.read()
if ret == False:
break
i+=1
print(i)
Output on machine 1 14300
Output on machine 2 14308
System Information Machine 1 OpenCV = 4.1.1.26 OS = Ubuntu 18.04.4 LTS 16 Core / 32GB RAM [cv2.videoio_registry.getBackendName(b) for b in cv2.videoio_registry.getBackends()] ['FFMPEG', 'GSTREAMER', 'INTEL_MFX', 'V4L2', 'CV_IMAGES', 'CV_MJPEG'] cap.getBackendName() FFMPEG
Machine 2 OpenCV = 4.1.1.26 OS = Ubuntu 18.04.3 LTS 8 Core /16GB RAM [cv2.videoio_registry.getBackendName(b) for b in cv2.videoio_registry.getBackends()] ['FFMPEG', 'GSTREAMER', 'INTEL_MFX', 'V4L2', 'CV_IMAGES', 'CV_MJPEG'] cap.getBackendName() FFMPEG
frame count will vary depends on machines? please help me out.
Used
cv2.CAP_PROP_FRAME_COUNT