sleap.io.videowriter

Module for writing avi/mp4 videos.

Usage:

> writer = VideoWriter.safe_builder(filename, height, width, fps) > writer.add_frame(img) > writer.close()

class sleap.io.videowriter.VideoWriter(filename, height, width, fps)[source]

Abstract base class for writing avi/mp4 videos.

static safe_builder(filename, height, width, fps)[source]

Builds VideoWriter based on available dependencies.

class sleap.io.videowriter.VideoWriterOpenCV(filename, height, width, fps)[source]

Writes video using OpenCV as wrapper for ffmpeg.

class sleap.io.videowriter.VideoWriterSkvideo(filename, height, width, fps)[source]

Writes video using scikit-video as wrapper for ffmpeg.