Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import time
- import numpy as np
- import cv2
- vcap = cv2.VideoCapture('rtsp://10.100.43.15:554/stander/livestream/0/0')
- n = 10
- ret, frame = vcap.read()
- images = np.array([frame])
- count = 0
- while(count / n < 31):
- ret, frame = vcap.read()
- if ret == False:
- print("no Frames")
- break
- if(count % n == 0):
- images = np.append(images, np.array([frame]), axis = 0)
- count += 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement