What it is
Folder: sam2.1_segmentation_min_6gb_vram. Promptable segmentation with SAM 2.1 hiera-large (Apache-2.0): send an image and a point or box, get pixel-accurate masks back, ranked by confidence. A general tool — the base for interactive labeling, QC tooling, or any click-to-select feature.
It runs the standard predictor contract: one class, Sam2Segmenter, whose predict() accepts JSON with prompts or bare image bytes (which default to a center-point prompt). Weights (~3.5 GB) pull from HuggingFace Hub inside __init__; there is no weights upload.
Request and response
Prompts ride in a JSON body sent as octet-stream (the predict_json pattern; plain application/json would drop the prompt fields, see serve.py):
Submit and call
From your own code, via the SDK client:
Hardware
| VRAM min → rec | CPU | RAM | Free disk |
|---|---|---|---|
| 6 → 12 GB | 4 cores | 24 GB | ~13 GB (image + ~3.5 GB weights) |
model_id to sam2.1-hiera-small (~1 GB) halves the footprint at some quality cost.