Segment Anything (SAM) is a foundation model for image segmentation that’s designed to work “out of the box” on a wide variety of images without task-specific fine-tuning. It’s a promptable segmenter: you guide it with points, boxes, or rough masks, and it predicts high-quality object masks consistent with the prompt. The architecture separates a powerful image encoder from a lightweight mask decoder, so the heavy vision work can be computed once and the interactive part stays fast. A bundled automatic mask generator can sweep an image and propose many object masks, which is useful for dataset bootstrapping or bulk annotation. The repository includes ready-to-use weights, Python APIs, and example notebooks demonstrating both interactive and automatic modes. Because SAM was trained with an extremely large and diverse mask dataset, it tends to generalize well to new domains, making it a practical starting point for research and production annotation tools.

Features

  • Promptable segmentation from points, boxes, or coarse masks
  • Fast mask decoder on top of a precomputed image embedding
  • Automatic mask generation for exhaustive object proposals
  • Pretrained checkpoints and simple Python inference APIs
  • Example notebooks and scripts for interactive annotation workflows
  • Outputs in common formats for easy integration into labeling tools

Project Samples

Project Activity

See All Activity >

License

Apache License V2.0

Follow Segment Anything

Segment Anything Web Site

Other Useful Business Software
Go from Code to Production URL in Seconds Icon
Go from Code to Production URL in Seconds

Cloud Run deploys apps in any language instantly. Scales to zero. Pay only when code runs.

Skip the Kubernetes configs. Cloud Run handles HTTPS, scaling, and infrastructure automatically. Two million requests free per month.
Start Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Segment Anything!

Additional Project Details

Registered

2025-10-06