Downloads · 30 days
156
27% of all-time downloads
erectbranch/sam3-gguf
sam3-gguf is a mask generation model from erectbranch. Use it for the mask generation task on the model card, and read the license before you ship it in a product. It is set up for gguf. The card lists the license as other.
Unofficial GGUF conversion of Meta's facebook/sam3 (HF Sam3VideoModel). This repository packages the original weights into GGUF containers for use with custom C++ inference stacks built on top of ggml / llama.cpp's gg…
Downloads · 30 days
156
27% of all-time downloads
All-time downloads
581
Public
Repo size
6.4 GB
Likes
4
Public
Click a slice to open those files.
.gguf6.4 GB · 100%
From the Hugging Face model README
Unofficial GGUF conversion of Meta's facebook/sam3
(HF Sam3VideoModel). This repository packages the original weights into GGUF
containers for use with custom C++ inference stacks built on top of
ggml / llama.cpp's gguf reader.
The original model is redistributed here unchanged in numerical content — only the on-disk container format differs. The SAM License terms of the upstream release apply in full (see LICENSE).
| File | Precision | Size |
|---|---|---|
sam3-f32.gguf | FP32 (all tensors) | ~3.21 GB |
sam3-f16.gguf | FP16 (weights) + FP32 (norms / embeddings / heads / biases) | ~1.70 GB |
sam3-q8_0.gguf | Q8_0 (2-D Linear weights) + FP32 (rest) | ~1.06 GB |
Pick one file — each is self-contained (config, tokenizer, and all tensors in a
single .gguf).
The converter follows llama.cpp's GGUF conventions and keeps the mapping from the upstream HF release intact:
model.safetensors. No renaming, no
merging, no reshaping. Any custom reader can look tensors up by their original
HF names (e.g. image_encoder.trunk.blocks.0.attn.qkv.weight).config.json is flattened into the
GGUF metadata under the sam3.* namespace (typed scalars / arrays where
possible). The full raw config is additionally embedded as a single string KV
sam3.config_json so nested structures survive round-tripping.vocab.json + merges.txt
tokenizer_config.json) is written under the standard
tokenizer.ggml.* keys, with tokenizer.ggml.model = "clip".general.architecture = "sam3".Small / quantization-sensitive tensors are always kept at FP32 regardless of the output type. These include:
mask_tokens, iou_token, obj_score_token, presence_token, …).layer3,
and .proj_out of iou_prediction_head / pred_obj_score_head /
output_hypernetworks_mlps)logit_scale, gamma tensorsFor f16: everything not in the keep-FP32 list is down-cast to FP16.
For q8_0: 2-D Linear weight matrices whose last dim is a multiple of 32 are
quantized to GGML Q8_0 (block size 32, symmetric int8); Conv (4-D), norms,
embeddings, and biases stay FP32. There is no FP16 path in the Q8_0 file — the
non-quantized tensors are plain FP32.
These files cannot be run with stock llama.cpp or llama-cli. SAM 3 is
not an LLM — it has no LLM/segmentation graph in llama.cpp. The .gguf files
here are containers intended to be consumed by a custom C++ reader (e.g. via
gguf_init_from_file in ggml) paired with a SAM 3 inference implementation
that mirrors the reference PyTorch model.
Distributed under the SAM License, inherited from the upstream facebook/sam3 release. By downloading or using these files you agree to the same terms as the original SAM 3 distribution.