본문으로 건너뛰기
cccskills
무료GitHub에 공개

video-processor

Process videos by removing segments and concatenating remaining parts. Use when you need to remove detected pauses/openings from videos, create highlight reels, or batch process segment removals using ffmpeg filter_complex.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(2)

  • SKILL.md3.1 KB
  • scripts/process_video.py5.3 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Video Segment Processor

Processes videos by removing specified segments and concatenating the remaining parts. Handles multiple removal segments efficiently using ffmpeg's filter_complex.

Use Cases

  • Removing detected pauses and openings from videos
  • Creating highlight reels by keeping only specific segments
  • Batch processing multiple segment removals

Usage

python3 /root/.claude/skills/video-processor/scripts/process_video.py \
    --input /path/to/input.mp4 \
    --output /path/to/output.mp4 \
    --remove-segments /path/to/segments.json

Parameters

  • --input: Path to input video file
  • --output: Path to output video file
  • --remove-segments: JSON file containing segments to remove

Input Segment Format

{
  "segments": [
    {"start": 0, "end": 600, "duration": 600},
    {"start": 610, "end": 613, "duration": 3}
  ]
}

Or multiple segment files:

python3 /root/.claude/skills/video-processor/scripts/process_video.py \
    --input video.mp4 \
    --output output.mp4 \
    --remove-segments opening.json pauses.json

Output

Creates the processed video and a report JSON:

{
  "original_duration": 3908.61,
  "output_duration": 3078.61,
  "removed_duration": 830.0,
  "compression_percentage": 21.24,
  "segments_removed": 91,
  "segments_kept": 91
}

How It Works

  1. Load removal segments from JSON file(s)
  2. Calculate keep segments (inverse of removal segments)
  3. Build ffmpeg filter to trim and concatenate
  4. Process video using hardware-accelerated encoding
  5. Generate report with statistics

FFmpeg Filter Example

For 3 segments to keep:

[0:v]trim=start=600:end=610,setpts=PTS-STARTPTS[v0];
[0:a]atrim=start=600:end=610,asetpts=PTS-STARTPTS[a0];
[0:v]trim=start=613:end=1000,setpts=PTS-STARTPTS[v1];
[0:a]atrim=start=613:end=1000,asetpts=PTS-STARTPTS[a1];
[v0][v1]concat=n=2:v=1:a=0[outv];
[a0][a1]concat=n=2:v=0:a=1[outa]

Dependencies

  • ffmpeg with libx264 and aac support
  • Python 3.11+

Limitations

  • Processing time: ~0.3× video duration (e.g., 20 min for 65 min video)
  • Requires sufficient disk space (output ≈ 70-80% of input size)
  • May have frame-accurate cuts (not sample-accurate)

Example

# Process video with opening and pause removal
python3 /root/.claude/skills/video-processor/scripts/process_video.py \
    --input /root/lecture.mp4 \
    --output /root/compressed.mp4 \
    --remove-segments /root/opening.json /root/pauses.json

# Result: 65 min → 51 min (21.2% compression)

Performance Tips

  • Use -preset medium for balanced speed/quality
  • Use -crf 23 for good quality at reasonable size
  • Process on machines with 2+ CPU cores for faster encoding

Notes

  • Preserves video quality using CRF encoding
  • Maintains audio sync throughout
  • Handles edge cases (segments at start/end of video)
  • Generates detailed statistics for verification

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Perform various data analysis on SEC 13-F and obtain some insights of fund activities such as number of holdings, AUM, and change of holdings between two quarters.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

benchflow-ai/skillsbench1.9천2026년 10월 13일 업데이트

AC branch pi-model power flow equations (P/Q and |S|) with transformer tap ratio and phase shift, matching `acopf-math-model.md` and MATPOWER branch fields. Use when computing branch flows in either direction, aggregating bus injections for nodal balance, checking MVA (rateA) limits, computing branch loading %, or debugging sign/units issues in AC power flow.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

benchflow-ai/skillsbench1.9천2026년 10월 13일 업데이트

Redact text from PDF documents for blind review anonymization

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

benchflow-ai/skillsbench1.9천2026년 10월 13일 업데이트

Use when checking simplified ADA-derived plan-view bathroom accessibility constraints such as turning space, door clear width, toilet centerline, grab bars, and lavatory knee/toe clearance.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

benchflow-ai/skillsbench1.9천2026년 10월 13일 업데이트

Analyze failed GitHub Action jobs for a pull request.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

benchflow-ai/skillsbench1.9천2026년 10월 13일 업데이트

Use when extracting plan-view architectural geometry from DXF files with semantic CAD layers, especially when outputs must normalize rooms, doors, fixtures, clearances, and grab bars into machine-checkable JSON.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

benchflow-ai/skillsbench1.9천2026년 10월 13일 업데이트

benchflow-ai의 스킬 모두 보기

이 스킬의 문제 신고