视频介绍:视频地址:https://www.bilibili.com/video/BV11s4y1N7Hv/

Github项目主页:https://github.com/facebookresearch/segment-anything

论文下载地址:https://arxiv.org/abs/2304.02643 { [Paper] [Project] [Demo] [Dataset] [Blog] [BibTeX] }

打开这里自己可以尝试:https://segment-anything.com/demo

我的尝试结果:(左边是分割图,右边是原图)

 

以下内容来自Github上的项目介绍

Segment Anything

Meta AI Research, FAIR

Alexander KirillovEric MintunNikhila RaviHanzi Mao, Chloe Rolland, Laura Gustafson, Tete XiaoSpencer Whitehead, Alex Berg, Wan-Yen Lo, Piotr DollarRoss Girshick

[Paper] [Project] [Demo] [Dataset] [Blog] [BibTeX]

SAM design

The Segment Anything Model (SAM) produces high quality object masks from input prompts such as points or boxes, and it can be used to generate masks for all objects in an image. It has been trained on a dataset of 11 million images and 1.1 billion masks, and has strong zero-shot performance on a variety of segmentation tasks.

 

Installation

The code requires python>=3.8, as well as pytorch>=1.7 and torchvision>=0.8. Please follow the instructions here to install both PyTorch and TorchVision dependencies. Installing both PyTorch and TorchVision with CUDA support is strongly recommended.

Install Segment Anything:

or clone the repository locally and install with

The following optional dependencies are necessary for mask post-processing, saving masks in COCO format, the example notebooks, and exporting the model in ONNX format. jupyter is also required to run the example notebooks.

Getting Started

First download a model checkpoint. Then the model can be used in just a few lines to get masks from a given prompt:

or generate masks for an entire image:

Additionally, masks can be generated for images from the command line:

See the examples notebooks on using SAM with prompts and automatically generating masks for more details.

 

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注