Skip to content

Detect and manage "First frame only" mode in VideoMatting - #74

Open
demoulinv wants to merge 2 commits into
mainfrom
dev/videoMattingFirstFrameOnlyModeEnabling
Open

Detect and manage "First frame only" mode in VideoMatting#74
demoulinv wants to merge 2 commits into
mainfrom
dev/videoMattingFirstFrameOnlyModeEnabling

Conversation

@demoulinv

Copy link
Copy Markdown
Collaborator

This pull request introduces an improvement to the processChunk method in VideoMatting.py to optimize the handling of chunks that contain only the first frame. The main change is a check that detects when all bounding boxes in the chunk correspond to only the first frame, and in that case, restricts processing to just the first image path, which can improve efficiency.

Optimization for single-frame chunks:

  • Added logic to detect if all bounding boxes in the chunk refer only to the first frame (first_frame_only). If so, the code now limits chunk_image_paths to just the first image, reducing unnecessary processing for single-frame chunks.

@demoulinv
demoulinv requested a balanced review from Copilot August 25, 2026 14:46
@demoulinv demoulinv self-assigned this Aug 25, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Optimizes VideoMatting when tracking data contains only the first frame.

Changes:

  • Detects first-frame-only bounding boxes.
  • Limits processing to the first image for such chunks.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread meshroom/videoMatting/VideoMatting.py Outdated
@demoulinv
demoulinv requested a review from cbentejac August 25, 2026 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants