For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /get-started.md).
Python function
validate_video
validate_video()
max.pipelines.context.validate_video(source, max_decoded_bytes=None)
Checks a video’s header, decoding no frame.
Intended for trust boundaries (the serving layer) that want an unreadable or oversized video rejected as a client error before it reaches a model worker. The video is decoded exactly once, by whoever consumes it, so damage inside the stream surfaces there rather than here.
-
Parameters:
-
Raises:
-
- MediaDecodeError – If the source is not a readable video.
- MediaBudgetExceeded – If one frame would not fit in
max_decoded_bytes.
-
Return type:
-
None