import cv2
import numpy as np

video = cv2.VideoCapture(r'pictures/pictures.avi')

counter = 0
if video.isOpened():
    while True:
        ret, frame = video.read()
        if not ret:
            print("Video doesn't open")
            break

        x, y = np.where(np.all(frame==np.array([0,0,0]), axis=2))
        if len(x) + len(y) == 114532:
            counter+=1
            print('mine')
    
video.release()
cv2.destroyAllWindows()
# 86
print(counter)
