Skip to content

Video segmentation example cvat#415

Open
Varfalamei wants to merge 6 commits into
features/UIfrom
video-segmentation-cvat
Open

Video segmentation example cvat#415
Varfalamei wants to merge 6 commits into
features/UIfrom
video-segmentation-cvat

Conversation

@Varfalamei

Copy link
Copy Markdown
Contributor

No description provided.

… CVAT example

New example: drop a long first-person video into a folder; the pipeline samples frames
(ffmpeg fps=1 -> perceptual-hash dedup), runs SAM3 open-vocabulary text-prompt segmentation
(person), and uploads box+polygon pre-annotations to CVAT for review. Reuses the SAM3->CVAT
tail from sam_cvat verbatim; the new part is the video ingest + frame sampling front stage.
…: one task per video split into jobs of N frames

Adds a backward-compatible segment_size param to CVATStep, passed to the CVAT TaskWriteRequest so a
task is split into jobs of N frames. robots_ego_cvat scopes the CVAT batch by video_id (one task per
video), sets SEGMENT_SIZE (jobs) and a large FILES_BATCH, and defaults SAMPLE_FPS to 0.2 (1 frame/5s).
…ont renders the pipeline graph, table browser and per-stage run triggers
…setup skill

- infer_image: downscale frames to SAM_MAX_INFER_SIDE (default 640) before SAM3
  and map detections back to full-res coords (CVAT still gets the full-res frame);
  on OOM retry at 512/384 and skip the frame as a last resort so one frame never
  kills the run; empty_cache between frames
- config: set PYTORCH_CUDA_ALLOC_CONF=expandable_segments:True before importing
  torch so it applies to both CLI and UI-triggered runs; add SAM_MAX_INFER_SIDE knob
- models: take HF_TOKEN from the env instead of persisting it to disk (works on
  read-only home dirs)
- README: GPU-memory/OOM section, HF_HOME note, and a datapipe-api-vs-CLI run-log
  collision warning; ffmpeg now optional (imageio-ffmpeg fallback)
- add setup-video-segmentation-cvat skill
- commit the .env.example template (was gitignored, unlike sibling examples)
@Varfalamei Varfalamei self-assigned this Jul 23, 2026
@Varfalamei Varfalamei changed the title Video segmentation cvat Video segmentation example cvat Jul 23, 2026
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.

1 participant