Model weights · FastSAM
Download FastSAM weights
A CNN take on segment-anything built on YOLOv8-seg, reaching similar masks far faster than the original transformer-based SAM. Pick a size below and download the official .pt checkpoint in one click, with published parameters, size and license all in view.
FastSAM checkpoints, pick a size and download
A CNN take on segment-anything built on YOLOv8-seg, reaching similar masks far faster than the original transformer-based SAM.
The FastSAM weights are AGPL-3.0, but the Ultralytics package that most people load them with is AGPL-3.0. Running FastSAM through Ultralytics puts your own project under AGPL-3.0 too, which means publishing your source if you distribute it or offer it over a network. An Ultralytics Enterprise license removes that. The AGPL-3.0 terms only cover you if you run the weights outside the Ultralytics package.
- FastSAM-sFastSAM-s.pt
- Params
- 11.8M
- FastSAM-xFastSAM-x.pt
- Params
- 72.2M
| Model | Params | Download |
|---|---|---|
FastSAM-s FastSAM-s.pt | 11.8M | |
FastSAM-x FastSAM-x.pt | 72.2M |
Figures are published by the authors. Weights host: github.com. Clicking Download verifies the file and starts it straight from the official CDN.
How to load FastSAM weights
Install the Ultralytics package, then point the loader at the checkpoint. It downloads automatically on first use, or you can pass the local path to the file you downloaded above.
pip install ultralyticsfrom ultralytics import FastSAM
# Downloads on first use, or pass a local path to your .pt file
model = FastSAM("FastSAM-s.pt")
results = model("image.jpg")Want to see the architecture? Export to ONNX and open it in the ONNX visualizer for a labelled diagram with shapes and parameter counts.
Open visualizer →Choosing a FastSAM checkpoint
Read off the table above: what each step up the size ladder costs and returns for this family specifically, where it stops being worth it, and what the license actually permits.
What the size ladder buys
FastSAM ships 2 checkpoints, from FastSAM-s at 11.8M parameters to FastSAM-x at 72.2M, 6.1× the model. These are promptable models with no single comparable accuracy figure, so the table lists parameters and download size rather than inventing one. Size and throughput are the axis you choose on: pick the smallest checkpoint that holds up on your own data rather than the largest you can fit.
Licensing, in practice
The weights are AGPL-3.0. More importantly, the usual way to run FastSAM is through the `ultralytics` package, which is AGPL-3.0, and that reaches your application even though the weights themselves are not. A permissive badge on the weights is not permission to ship closed-source over that path. AGPL-3.0 is free for open-source, research and internal use; a closed-source commercial product needs an Ultralytics Enterprise license.
About FastSAM
FastSAM reframes segment-anything as a YOLOv8-seg instance-segmentation problem plus prompt-guided selection, reaching comparable masks at up to 50x the speed of the original SAM. A pragmatic CNN alternative when you want SAM-style prompting without a transformer's cost.
- Author
- CASIA IVA
- Released
- 2023
- Tasks
- Segment
- Framework
- Ultralytics (PyTorch)
- Input size
- 1024px
- License
- AGPL-3.0
More model weights to download
Each page lists every checkpoint with accuracy, parameters, license and a one-click download.
From the blog
Tutorials, code, and notes on computer vision, deep learning, and applied AI.
Depth EstimationJuly 27, 20269 min readVideo Depth Anything in Python: consistent depth for video
YOLO26July 19, 202619 min readYOLO26 vs YOLO11 vs YOLOv8 vs YOLOv10, YOLOv9 & YOLOv5
Object TrackingJuly 18, 20268 min readHow to use ByteTrack with YOLO for object tracking in Python
Semantic SearchJuly 6, 20267 min readBuild a semantic image search engine with CLIP and Python
YOLO26July 3, 20269 min readYOLO26 vs YOLO11: Real-time ONNX FPS benchmark in Python
Depth EstimationJuly 1, 202613 min readDepth Anything V2 in Python: image, video and webcam depth
Object TrackingJune 27, 202613 min readUltralytics object trackers comparison: ByteTrack, BoT-SORT & More
OCRJune 26, 20266 min readHow to extract text from images with LightOnOCR and Python
Frequently asked questions
- How do I download FastSAM weights?
- Click the Download button next to any variant in the table above; we verify the file and start it straight from the official CDN. You can also let the loader fetch it automatically on first use with `model = FastSAM("FastSAM-s.pt")`. All 2 FastSAM checkpoints are hosted officially.
- Is FastSAM free for commercial use?
- FastSAM is released under AGPL-3.0. That is free for open-source and research; closed-source commercial deployments need an Ultralytics Enterprise license. Always confirm against the linked license text.
- Which FastSAM model size should I use?
- Start with FastSAM-s, the smallest and fastest, ideal for prototyping, edge and CPU. Move up the ladder only when you need more accuracy and have the compute for it.