Resizing the camera frame to a specific dimension required for your inference Jan 14, 2022 In the below example I have resized the frames from the camera to 320 * 480(weight * height) import cv2 cap = cv2.VideoCapture(0) while cap.isOpened(): ret, frame = cap.read() image_resized2 = cv2.resize(frame, (480,320))