At a glance
- Upstream model
-
facebook/EdgeTAM
(HF port:
yonigozlan/EdgeTAM-hf) - Browser ONNX repo
- onnx-community/EdgeTAM-ONNX
- Task & architecture
-
mask-generation·EdgeTamModel(edgetam, RepViT encoder + 2D Spatial Perceiver + SAM-2-style prompt/mask decoder,1024×1024) - Runtime & download
-
@huggingface/transformers@4.3.0local worker pin · WebGPUfp1620.59 MB · CPU WASMfp16encoder +fp32decoder 31.08 MB ·fp3240.90 MB - License
- Apache-2.0
q8 is never used): Live Chrome
probing proved that EdgeTAM's q8 / int8 export (14.21 MB)
silently collapses mask logits to IoU 0.0057 (0.00% foreground
mask). This demo automatically loads crisp WebGPU fp16 (20.59 MB)
when a GPU adapter is present or CPU WASM fp16 encoder +
fp32 decoder (31.08 MB) everywhere else.
Interactive Point & Box Promptable Mask Studio
Probing WebGPU capability…
Initialise EdgeTAM above to encode the photo and segment with clicks or boxes.
3-Mask Ambiguity Switcher
A single click is ambiguous (part vs object vs whole). EdgeTAM predicts all 3 scales in one forward pass — switch instantaneously with zero re-inference:
See inside EdgeTAM: two-stage cached decoding
Like SAM 2, EdgeTAM splits inference into a one-time vision encoder
(model.get_image_embeddings(imageInputs)) producing multi-scale RepViT
features, and a lightweight prompt encoder + mask decoder
(model({ ...embeddings, input_points, input_labels, input_boxes })) that
reuses those cached features for every click or box in ~145 ms on CPU WASM.
Colored mask overlays and 1 px contours are baked on an OffscreenCanvas inside
the worker and transferred as zero-copy ImageBitmap handles.
| Scale | Predicted IoU | Area (px) | Coverage | Status |
|---|---|---|---|---|
| Run a prompt to inspect the 3 predicted masks. | ||||