← 返回
未分类 中文

video2imgs-视频关键帧获取

Capture key frames from video files at fixed time intervals. Use when you need to understand video content by extracting screenshots, or when you need to ana...
按固定时间间隔从视频文件中提取关键帧。适用于需要通过截图了解视频内容或进行分...的情况。
chentx1243 chentx1243 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 405
下载
💾 1
安装
1
版本
#latest

概述

Video Frame Capture

Overview

This skill enables capturing key frames from video files at fixed time intervals. It's designed to help you understand video content by extracting screenshots for analysis or content recognition.

When to Use This Skill

Use this skill when:

  • You need to understand video content by extracting key frames
  • You want to analyze video frames for content recognition
  • You need to create a visual summary of a video
  • You want to skip similar frames to avoid redundant captures

Quick Start

Capture frames from a video at 10-second intervals:

python scripts/video_frame_capture.py --input "D:\videos\meeting.mp4" --output-dir "D:\frames\meeting" --interval-seconds 10

Parameters

  • --input: Path to the local video file (required)
  • --output-dir: Directory where captured frames will be stored (required)
  • --interval-seconds: Capture interval in seconds, must be greater than 0 (required)
  • --skip-similar-frames: Skip frames that are similar to the previous saved frame
  • --similarity-threshold: Similarity threshold in range 0-1, defaults to 0.70
  • --image-extension: Image format for saved frames, defaults to jpg

Output Naming

Output files follow the format: 视频文件原始名称_视频时间轴_第几次截取.jpg

Example: meeting_00h01m30s_0003.jpg

Similar Frame Skipping

When --skip-similar-frames is enabled, the script compares the current candidate frame with the previous saved frame:

  • Similarity > threshold: Frame is skipped
  • Similarity ≤ threshold: Frame is saved and becomes the new comparison baseline

Examples

Basic frame capture

python scripts/video_frame_capture.py --input "D:\videos\meeting.mp4" --output-dir "D:\frames\meeting" --interval-seconds 10

Skip similar frames

python scripts/video_frame_capture.py --input "D:\videos\meeting.mp4" --output-dir "D:\frames\meeting" --interval-seconds 10 --skip-similar-frames

Custom similarity threshold

python scripts/video_frame_capture.py --input "D:\videos\meeting.mp4" --output-dir "D:\frames\meeting" --interval-seconds 10 --skip-similar-frames --similarity-threshold 0.80

Resources

scripts/

  • video_frame_capture.py: Main script for capturing video frames

references/

  • video_formats.md: Supported video formats and technical details

Note: This skill requires OpenCV (opencv-python-headless) to be installed. Install dependencies with: pip install -r requirements.txt

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-31 01:52 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

content-creation

maple-video2article

chentx1243
自动从视频生成图文并排的Markdown文章,支持本地文件或在线URL下载,完成文本提取、帧截取、时间轴匹配和撰写全流程。
★ 0 📥 533
design-media

Nano Banana Pro

steipete
使用 Nano Banana Pro (Gemini 3 Pro Image) 生成或编辑图像。支持文生图、图生图及 1K/2K/4K 分辨率,适用于图像创建、修改及编辑请求,使用 --input-image 指定输入图像。
★ 435 📥 117,904
design-media

Openai Whisper

steipete
使用 Whisper CLI 进行本地语音转文字(无需 API 密钥)
★ 335 📥 94,728