๐ง What is SAM?
Studying ใSegment Anythingใ (ICCV, 2023)
๐ Paper Title: Segment Anything
โ๏ธ Authors: Meta AI Research (Kirillov, Alexey et al.)
๐ One-line Summary: A general-purpose segmentation model that can segment anything, in any image, from any prompt!
๐ Key Idea
- SAM stands for Segment Anything Model
- Unlike traditional segmentation models,
- SAM is a universal segmentation AI that can extract any object using a single pre-trained model
- Without predefined classes, SAM can segment targets from user prompts
- Itโs often called the โGPT for Segmentationโ due to its generalization ability
๐ Background of the SAM Research
- The era of Foundation Models:
- Language models work well with large-scale data
- In vision, CLIP, ALIGN, and image encoders have emerged
- But vision segmentation lacks data diversity
- Research Goal: Build a foundation model for image segmentation
- Three key challenges: a. Task: What segmentation task to define? b. Model: What architecture to use? c. Data: How to collect it?
๐ฏ The Task Definition in SAM
- Limitations of existing segmentation models:
- Rely on predefined classes
- Require labelled data
- Need fine-tuning for new objects
- Need for Prompt-based, Open-Vocabulary segmentation:
- With multimodal models like CLIP, now we want:
- Models that can segment user-defined targets using text, point, box prompts
๐ So SAM was defined as a โsegment-anythingโ universal segmentation system
โ๏ธ SAM Model Architecture
Component | Description |
---|
Image Encoder | Encodes entire image into a fixed embedding (done once) |
Prompt Encoder | Encodes prompts like points, boxes, masks |
Mask Decoder | Combines image & prompt embeddings to predict segmentation mask |
Components in Detail
- Image Encoder (ViT-H, MAE pre-trained)
- Uses ViT with Masked Autoencoder (MAE) training
- Produces rich visual representation
- Image embeddings are reused for multiple prompts
- Prompt Encoder
- Handles two types of inputs:
Type | Example | Encoding | Notes |
---|
Sparse | Point, Box, Text | Position + learned embeddings / CLIP text encoder | Text uses CLIP text encoder |
Dense | Mask | Convolution + element-wise sum with image embedding | Used for dense prompts like masks |
- Mask Decoder
- Core logic that fuses prompt and image to output the final mask
Step | Description |
---|
1. Input | Image Embedding + Prompt Embedding + Output Token |
2. Decoder Blocks ร2 | Transformer decoder variant + self & cross attention |
3. Upsampling | Upsamples decoder output using image embedding |
4. Dynamic Prediction | MLP โ Linear classifier to produce per-pixel FG probabilities |
5. Output | Generates 3 mask candidates with confidence scores (to resolve ambiguity) |
๐๏ธ SA-1B Dataset and the Data Engine
- SA-1B: The largest segmentation dataset ever, built by Meta for SAM
- Contains 11M images and over 1.1B masks
- 400ร more masks than prior datasets
- โ
Fully automatic annotation, โ
High diversity and quality
๐ ๏ธ 3-Stage Data Engine
Stage | Name | Who | Method | Key Features |
---|
1๏ธโฃ | Assisted-manual | Human + SAM | Human segments, SAM assists | Interactive tool, semantic-free |
2๏ธโฃ | Semi-automatic | SAM + Human | SAM segments, human fills the rest | Efficient + diverse |
3๏ธโฃ | Fully-automatic | SAM only | Grid prompts, full automation | ~100 masks/image, 99.1% of SA-1B |
Assisted-manual Stage
- Professional annotators use browser tool with SAM
- Click foreground/background points
- Refinement via brush & eraser
- Focused on recognizable objects (but no label stored)
- Moved to next image if took >30 seconds
Metric | Result |
---|
Avg. annotation time | 34 โ 14 sec (6.5ร faster than COCO) |
Masks/image | 20 โ 44 |
Total | 120K images, 4.3M masks |
Retraining | 6 times total |
Semi-automatic Stage
Metric | Result |
---|
Additional masks | +5.9M (total 10.2M) |
Images | 180K |
Retraining | 5 more times |
Time/image | 34 sec (excluding auto-masks) |
Masks/image | 44 โ 72 |
Fully Automatic Stage
- Grid of 32ร32 point prompts
- Predicts multiple masks per point (sub-part, part, whole)
- IoU prediction module filters reliable masks
- Stability check with probability thresholding
- Non-Max Suppression (NMS) removes duplicates
- Cropped regions help improve small object coverage
๐ฆ Final SA-1B Dataset Summary
Aspect | Description |
---|
Image count | 11M |
Resolution | Avg. 3300ร4950 px |
Licensing | Licensed from photographers |
Privacy | Faces/plates blurred |
Released images | Resized (short side 1500 px) |
Comparison | Higher-res than COCO (480ร640) |
Masks | Details |
---|
Total | 1.1B masks |
Auto-generated | 99.1% |
Human-level quality | 94% of masks have IoU > 90% w/ expert |
Fair & diverse | Balanced across gender, regions |
๐ฌ Zero-Shot Transfer Experiments
SAM proves itโs not just a segmentation tool, but a universal model.
Evaluated on 5 tasks without fine-tuning:
Task | Outcome |
---|
1. Single-Point Mask | Outperforms RITM (auto & human eval) |
2. Edge Detection | Strong edges from prompts (even w/o training) |
3. Object Proposal | Excellent for mid/rare objects (beats ViTDet) |
4. Instance Segmentation | Better visual quality than ViTDet, even if AP is lower |
5. Text-to-Mask | Uses CLIP text embeddings for free-text segmentation |
1๏ธโฃ Single-Point Valid Mask
- Only one foreground point โ segment object
- Evaluation: mIoU + human rating (1โ10)
- SAM beats RITM on 16/23 datasets (mIoU), and all datasets (oracle mode)
- Human ratings: 7โ9 (higher than RITM)
2๏ธโฃ Edge Detection
- Dataset: BSDS500
- Prompted via 16ร16 grid
- Sobel edge detection applied to mask probabilities
- Matches early DL models like HED
- Recallโ, Precisionโ due to over-segmentation (expected)
3๏ธโฃ Object Proposal (LVIS)
- Method: Mask output used as object proposals
- Compared to ViTDet-H + Mask R-CNN
- SAM outperforms in:
- Medium/large objects
- Common/rare categories
- Falls behind on small/frequent ones
4๏ธโฃ Instance Segmentation
- ViTDet boxes โ fed as prompt to SAM
- COCO/LVIS: SAM slightly behind in AP, but
- Visual quality better (confirmed via human study)
- Less biased by noisy ground truth (unlike ViTDet)
5๏ธโฃ Text-to-Mask
- Uses CLIP text encoder as prompt
- Training with CLIP image embedding โ inference with text embedding
- Example prompts: โa wheelโ, โwipersโ
- Additional point improves ambiguous cases
โจ Final Thoughts
Meta didnโt just build a model โ they released the model + high-quality data with strong fairness,
making a true contribution to the open AI community.
Letโs hope we can do the same in the future โ building & sharing great models and datasets!
(ํ๊ตญ์ด) ๐ง SAM์ด๋ ๋ฌด์์ธ๊ฐ?
ใSegment Anythingใ(ICCV, 2023) ๊ณต๋ถ
๐ ๋
ผ๋ฌธ ์ ๋ชฉ: Segment Anything
โ๏ธ ์ ์: Meta AI Research (Kirillov, Mintun et al.)
๐ ํ์ค ์์ฝ: ์ด๋ค ๊ฐ์ฒด๋ , ์ด๋ค ์ด๋ฏธ์ง๋ , ์ด๋ค ์
๋ ฅ์ด๋ โ๋ฌด์์ด๋ โ ์๋ผ๋ด๋ ๋ฒ์ฉ ์ธ๊ทธ๋ฉํ
์ด์
๋ชจ๋ธ์ ๋ฑ์ฅ!!
๐ ํต์ฌ ์์ด๋์ด
- SAM์ Segment Anything Model์ ์ฝ์๋ก,
- ๊ธฐ์กด์ ์์ญ ๋ถํ (Segmentation) ๋ชจ๋ธ๋ค๊ณผ๋ ๋ฌ๋ฆฌ,
- ์ด๋ค ๊ฐ์ฒด๋ ์ฌ์ ํ์ต๋ ๋ชจ๋ธ ํ๋๋ก ์๋ผ๋ผ ์ ์๋ ๋ฒ์ฉ Segmentation ์ธ๊ณต์ง๋ฅ์
๋๋ค!
- ์ฆ, ๋ฏธ๋ฆฌ ์ ์๋ ํด๋์ค๊ฐ ์์ด๋, โ์ฌ์ฉ์ ์
๋ ฅ(Prompt)โ๋ง์ผ๋ก ์ํ๋ ๋์์ ๋ถ๋ฆฌํ ์ ์์ด์.
- SAM์ โSegmentation์ ์ํ GPTโ๋ผ๊ณ ๋ถ๋ฆด ์ ๋๋ก ๋ฒ์ฉ์ฑ์ด ๊ฐ๋ ฅํฉ๋๋ค.
๐ SAM ์ฐ๊ตฌ์ ๋ฐฐ๊ฒฝ
- ๋ฐ์ผํ๋ก Foundation Model์ ์๋!!
- ๋๋์ ๋ฐ์ดํฐ๋ก Language Model๋ค์ ๋๋๊ฒ ์ ์๋!!
- Computer Vision ์์๋ CLIP, ALIGN ๋ฑ ์ด๋ฏธ์ง ์ธ์ฝ๋๋ค์ด ๋ฑ์ฅ, ์ด๋ฏธ์ง ์์ฑ์๋ ์ํฅ์ ๋ฏธ์นจ!!
- ํ์ง๋ง, Vision ๋ฐ์ดํฐ์ ๋ถ์กฑ์ผ๋ก ์ธํด ํ๊ณ๊ฐ ์์์!!
- ๊ทธ๋์!! ์ด๋ฒ ์ฐ๊ตฌ์ ๋ชฉํ๋ โbuild a foundation model for image segmentationโ ์ผ๋ก ์ ์!!
- ๊ทธ๋ฆฌ๊ณ ์ฑ๊ณต์ ์ฐ๊ตฌ๋ฅผ ์ํด์ ์๋ 3๊ฐ์ง ์์๋ฅผ ๊ณ ๋ฏผํจ!!
a. ๊ณผ์ : ์ด๋ค ๊ณผ์ ๋ฅผ ์ค์ ํ ๊ฒ์ธ๊ฐ!
b. ๋ชจ๋ธ : ์ด๋ค ๋ชจ๋ธ์ ์ธ๊ฒ์ธ๊ฐ!
c. ๋ฐ์ดํฐ : ์ด๋ค ๋ฐ์ดํฐ๋ฅผ ์ธ๊ฒ์ธ๊ฐ!
SAM ์ฐ๊ตฌ์ ๊ณผ์ (Task)์ ์ ์
- ๊ธฐ์กด Segmentation ๋ชจ๋ธ์ ํ๊ณ
- ๋๋ถ๋ถ์ segmentation ๋ชจ๋ธ์ ์ฌ์ ์ ์๋ ํด๋์ค(class)๊ฐ ์์ด์ผ ํ์ต ๊ฐ๋ฅ
- ํน์ ๊ฐ์ฒด(ex: ๊ณ ์์ด, ๊ฐ, ์๋์ฐจ)๋ง ๋ถํ ๊ฐ๋ฅํ๋ฉฐ, ๋ผ๋ฒจ๋ง ๋ฐ์ดํฐ์ ๋งค์ฐ ์์กด
- ์๋ก์ด ํด๋์ค์ ๋ํด์ ์ฌํ์ต(fine-tuning)์ด ํ์
- Open-Vocabulary, Prompt ๊ธฐ๋ฐ ๋ชจ๋ธ ํ์์ฑ
- ์ต๊ทผ CLIP ๋ฑ ๋ฉํฐ๋ชจ๋ฌ ๋ชจ๋ธ์ ๋ฑ์ฅ๊ณผ ํจ๊ป,
- โํ
์คํธโ๋ โํฌ์ธํธโ ๋ฑ์ ํตํด ์ฌ์ฉ์ ์ค์ฌ์ผ๋ก ๊ฐ์ฒด๋ฅผ ์ง์ ํ๊ณ ๋ถํ ํ๋ ๋ชจ๋ธ์ด ์๊ตฌ๋จ
- ๊ทธ๋์!! โ๋ฌด์์ด๋ ์๋ผ๋ด๋ ๋ฒ์ฉ ๋ถํ ๊ธฐโ๋ฅผ ๊ณผ์ ๋ก ์ ์!
โ๏ธ SAM์ ๋ชจ๋ธ ๊ตฌ์กฐ
๊ตฌ์ฑ ์์ | ์ค๋ช
|
---|
Image Encoder | ์ด๋ฏธ์ง ์ ์ฒด๋ฅผ ์ธ์ฝ๋ฉํ์ฌ ๊ณ ์ ๋ image embedding ์์ฑ (ํ ๋ฒ๋ง ์ํ) |
Prompt Encoder | ์ , ๋ฐ์ค, ๋ง์คํฌ ๋ฑ ๋ค์ํ ํ๋กฌํํธ๋ฅผ ์ธ์ฝ๋ฉ |
Mask Decoder | ์ด๋ฏธ์ง์ ํ๋กฌํํธ ์ธ์ฝ๋ฉ์ ๊ฒฐํฉํ์ฌ ๋ง์คํฌ ์์ธก ์ํ |
SAM์ ์ธ ๊ฐ์ง ์ฃผ์ ๊ตฌ์ฑ ์์ ๋ฐ ๊ทธ ๊ธฐ๋ฅ!!
- Image Encoder (ViT-H ๊ธฐ๋ฐ)
- MAE (Masked Autoencoders) ๋ฐฉ์์ ViT๋ฅผ ์ฌ์ฉ! - MAE๊ฐ ๋ญ์ง ๊ณต๋ถํด๋ณด์!!
| Masked Autoencoders Are Scalable Vision Learners (CVPR, 2022) - ์ด๋ฏธ์ง๋ฅผ ๊ณ ํด์๋๋ก ์ธ์ฝ๋ฉํ์ฌ ํ๋ถํ ์๊ฐ ํํ ์์ฑ
- ํ๋ฒ ์ธ์ฝ๋ฉ๋ ์ด๋ฏธ์ง๋ ์ฌ๋ฌ ํ๋กฌํํธ์๋ ์ฌ์ฌ์ฉ ๊ฐ๋ฅ
- Prompt Encoder
- ์ฌ์ฉ์์ ์
๋ ฅ์ ์ธ์ฝ๋ฉ
- ์
๋ ฅ ์ข
๋ฅ - ํฌ๊ฒ 2๊ฐ์ง!
์ข
๋ฅ | ์์ | ์ธ์ฝ๋ฉ ๋ฐฉ์ | ์ค๋ช
|
---|
ํฌ์ (Sparse) | Point, Box, Text | ์์น + ํ์ต๋ ์๋ฒ ๋ฉ / ํ
์คํธ ์ธ์ฝ๋(CLIP) | - ์์น ์ ๋ณด์ Positional Encoding + ํ์ต๋ ์๋ฒ ๋ฉ - ํ
์คํธ๋ CLIP ํ
์คํธ ์ธ์ฝ๋ ์ฌ์ฉ |
๋ฐ์ง (Dense) | Mask | Convolution + Element-wise Sum | - ๋ง์คํฌ๋ฅผ Conv๋ก ์๋ฒ ๋ฉ ํ ์ด๋ฏธ์ง ์๋ฒ ๋ฉ๊ณผ ์์ ๋จ์ ํฉ์ฐ |
Mask Decoder
- ์ธ์ฝ๋ ์ถ๋ ฅ์ ๊ธฐ๋ฐ์ผ๋ก ์ต์ข
๋ง์คํฌ๋ฅผ ์์ฑ
- ์ด๋ฏธ์ง์ ํ๋กฌํํธ ์ ๋ณด๋ฅผ ๊ฒฐํฉํ์ฌ ๋ง์คํฌ๋ฅผ ์์ฑํ๋ ํต์ฌ ๊ตฌ์ฑ
- ๐ง ์ฃผ์ ๊ตฌ์ฑ ์์ ๋ฐ ์ฒ๋ฆฌ ๊ณผ์
๋จ๊ณ | ์ค๋ช
|
---|
1. ์
๋ ฅ | - Image Embedding - Prompt Embedding (Point, Box, Text ๋ฑ) - Output Token |
2. ๋์ฝ๋ ๋ธ๋ก (ร2) | - Transformer Decoder ๋ณํ ๋ฒ์ ์ฌ์ฉ - Prompt Self-Attention - Cross-Attention (Prompt โ Image ์๋ฒ ๋ฉ) ์๋ฐฉํฅ ์ํ |
3. ์
์ํ๋ง | - ๋์ฝ๋ ์ถ๋ ฅ์์ Image Embedding์ ์
์ํ๋ง |
4. ๋์ ๋ง์คํฌ ์์ธก | - Output Token โ MLP โ ๋์ Linear Classifier - ๊ฐ ํฝ์
์์น๋ง๋ค Foreground ํ๋ฅ ๊ณ์ฐ |
5. ์ต์ข
์ถ๋ ฅ | - ์ ๊ฒฝ ํ๋ฅ (foreground probability) ๋งต โ Binary Mask ์ถ๋ ฅ |
๏ผ๋ชจํธ์ฑ์ ํด๊ฒฐ์ ์ํ์ฌ! : ์ธ ๊ฐ์ ํ๋ณด ๋ง์คํฌ๋ฅผ ์ถ๋ ฅ, ๊ฐ ๋ง์คํฌ ๋ณ ํ์ ๋(uncertainty score) ์ ๊ณต
๐๏ธ SAM์ ๋ฐ์ดํฐ (SA-1B) ๋ฐ ๋ฐ์ดํฐ ์์ง
- SA-1B: SAM ํ์ต์ ์ํด Meta๊ฐ ๋ง๋ ์ด๋๊ท๋ชจ ์ธ๊ทธ๋ฉํ
์ด์
๋ฐ์ดํฐ์
- ์ด 11M๊ฐ์ ์ด๋ฏธ์ง์์ ์๋์ผ๋ก ์์ง๋ 1B+ ๋ง์คํฌ
- ๊ธฐ์กด ์ธ๊ทธ๋ฉํ
์ด์
๋ฐ์ดํฐ์
๋ณด๋ค 400๋ฐฐ ๋ ๋ง์ ๋ง์คํฌ ๋ณด์
- โ
์์ ์๋ ์์ง, โ
๊ณ ํ์ง & ๋ค์์ฑ ๋ณด์ฅ
- SAM์ ๋ฒ์ฉ์ฑ ๋ฐ ๊ฒฌ๊ณ ์ฑ ํ๋ณด์ ํต์ฌ ์ญํ
- ๐ ํฅํ ํ์ด๋ฐ์ด์
๋ชจ๋ธ ์ฐ๊ตฌ๋ฅผ ์ํ ๊ณต๊ณต ์์์ผ๋ก ํ์ฉ ๊ฐ๋ฅ
- SA-1B ๋ฐ์ดํฐ์
์์ฑ ์ ์ฐจ ์์ฝ ํ
๋จ๊ณ | ๋ช
์นญ | ์ฃผ์ฒด | ์ฃผ์ ์์
| ํน์ง |
---|
1๏ธโฃ | ๋ณด์กฐ ์๋ ์ฃผ์ (Assisted-manual) | ์ฌ๋ + SAM | ์ฌ๋์ด ๋ง์คํฌ๋ฅผ ์ง์ ๋ง๋ค๊ณ , SAM์ด ๋ณด์กฐ | ์ธํฐ๋ํฐ๋ธ ์ธ๊ทธ๋ฉํ
์ด์
๋ฐฉ์, ์ด๊ธฐ ํ์ง ํ๋ณด |
2๏ธโฃ | ๋ฐ์๋ ์ฃผ์ (Semi-automatic) | SAM + ์ฌ๋ | SAM์ด ์ผ๋ถ ๊ฐ์ฒด ๋ง์คํฌ ์์ฑ, ์ฌ๋์ ๋๋จธ์ง๋ฅผ ์ฃผ์ | ๋ค์์ฑ ํฅ์, ์๊ฐ ํจ์จ ์ฆ๊ฐ |
3๏ธโฃ | ์์ ์๋ ์ฃผ์ (Fully automatic) | SAM | SAM์ด ํฌ์ธํธ ํ๋กฌํํธ ๊ธฐ๋ฐ์ผ๋ก ์ ์ฒด ๋ง์คํฌ ์์ฑ | ์ด๋ฏธ์ง๋น ํ๊ท 100๊ฐ ๋ง์คํฌ, SA-1B ๋๋ถ๋ถ ๊ตฌ์ฑ |
1๋จ๊ณ: Assisted-Manual Stage
- ๋ธ๋ผ์ฐ์ ๊ธฐ๋ฐ ์ธํฐ๋ํฐ๋ธ ํด์์ SAM์ด ์ค์๊ฐ์ผ๋ก ์ฃผ์ ์ง์
- ์ ๋ฌธ ์ฃผ์์๊ฐ ์ ๊ฒฝ/๋ฐฐ๊ฒฝ ํฌ์ธํธ ํด๋ฆญํ์ฌ ๋ง์คํฌ ์์ฑ
- ๋ธ๋ฌ์ & ์ง์ฐ๊ฐ๋ก ์ ๋ฐ ์์ ๊ฐ๋ฅ
- โ์ค๋ช
๊ฐ๋ฅํโ ๊ฐ์ฒด ์ค์ฌ์ผ๋ก ์์ ๋กญ๊ฒ ๋ผ๋ฒจ๋ง (semantic ์ ํ ์์)
- ๋ง์คํฌ์ ์ด๋ฆ/์ค๋ช
์ ์ ์ฅํ์ง ์์
- 30์ด ์ด์ ๊ฑธ๋ฆฌ๋ฉด ๋ค์ ์ด๋ฏธ์ง๋ก ๋์ด๊ฐ
- ์์ง๋ ๋ง์คํฌ๋ก 6ํ ์ฌํ์ต!!
๐ ๋ชจ๋ธ ํฅ์ ๊ณผ์
ํญ๋ชฉ | ๋ด์ฉ |
---|
์ด๊ธฐ ๋ชจ๋ธ | ๊ณต๊ฐ ์ธ๊ทธ๋ฉํ
์ด์
๋ฐ์ดํฐ๋ก ํ์ต๋ SAM |
๋ฐ๋ณต ํ์ต | ์์ง๋ ๋ง์คํฌ๋ง์ผ๋ก ์ด 6ํ ์ฌํ์ต |
ViT ๋ฐฑ๋ณธ | ViT-B โ ViT-H๋ก ์ ์ง์ ํ์ฅ |
๊ตฌ์กฐ ๊ฐ์ | ๋ค์ํ ์ธ๋ถ ๊ตฌ์กฐ ์งํ ํฌํจ |
๐ ์ฑ๋ฅ ๊ฐ์ ์งํ
์งํ | ๋ณํ |
---|
ํ๊ท ์ฃผ์ ์๊ฐ | 34์ด โ 14์ด (COCO๋ณด๋ค 6.5๋ฐฐ ๋น ๋ฆ) |
ํ๊ท ๋ง์คํฌ ์ | ์ด๋ฏธ์ง๋น 20๊ฐ โ 44๊ฐ |
์์ง๋ | 12๋ง ์ด๋ฏธ์ง, 430๋ง ๋ง์คํฌ ์์ง ์๋ฃ |
2๋จ๊ณ: Semi-Automatic Stage
- ์ด ๋จ๊ณ๋ โ์๋ + ์๋ ํ์
๊ตฌ์กฐโ๋ก, ๋ ์ด๋ ค์ด ๊ฐ์ฒด, ๋ ๋ค์ํ ๊ฐ์ฒด๋ฅผ ์ปค๋ฒํ๋ ๋ฐ ์ค์ํ ์ญํ ์ํ
- ๋ง์คํฌ ๋ค์์ฑ ํฅ์์ ํตํด SAM์ ๋ฒ์ฉ ๋ถํ ๋ฅ๋ ฅ ๊ฐํ
- 1๋จ๊ณ ๋ง์คํฌ๋ฅผ ๊ธฐ๋ฐ์ผ๋ก โobjectโ ํด๋์ค ํ๋๋ก ๋ฐ์ด๋ฉ ๋ฐ์ค ํ์ง๊ธฐ ํ์ต
- ์๋ ํ์ง๋ ๋ง์คํฌ(confident masks)๋ฅผ ์ด๋ฏธ์ง์ ๋ฏธ๋ฆฌ ์ฝ์
- ์ฃผ์์๋ ์๋ ๋ง์คํฌ ์ธ์ ๋๋ฝ๋ ๊ฐ์ฒด๋ง ์๋์ผ๋ก ์ถ๊ฐ ์ฃผ์
๐ ์ฑ๋ฅ ๋ฐ ์์น
ํญ๋ชฉ | ๋ด์ฉ |
---|
์์ง ๋ง์คํฌ ์ | 590๋ง ๊ฐ ์ถ๊ฐ ์์ง (์ด 1,020๋ง ๊ฐ ๋๋ฌ) |
์ด๋ฏธ์ง ์ | 18๋ง ์ฅ |
SAM ์ฌํ์ต ํ์ | 5ํ ๋ฐ๋ณต ํ์ต |
ํ๊ท ์ฃผ์ ์๊ฐ | 34์ด (์๋ ๋ง์คํฌ ์ ์ธ) |
์ด๋ฏธ์ง๋น ํ๊ท ๋ง์คํฌ ์ | 44๊ฐ โ 72๊ฐ (์๋ + ์๋ ํฌํจ) |
3๋จ๊ณ: Fully Automatic Stage
- 2๋จ๊ณ๊น์ง ๋ฐ์ดํฐ๋ก ํ์ต๋ ๋ชจ๋ธ๋ก, ์์ ์๋์ผ๋ก!!, ๋ฐ์ดํฐ์
์์ฑ!!
- ์ด๋ก์จ Segment Anything์ SA-1B ๋ฐ์ดํฐ์
์ด ์์ฑ
- SAM ๋ชจ๋ธ๋ ์ค์ํ์ง๋ง, ์ด์ฒ๋ผ ๋ฒ์ฉ ๋ถํ ๋ชจ๋ธ ํ์ต์ ์์ด ์ ๋ก ์๋ ๋ฆฌ์์ค ์ ๊ณตํ๋ค๋์ ๋ ํฐ ์๋ฏธ!!
๐ง ์๋ ์์ฑ ์ ์ฐจ
- 32ร32 ํฌ์ธํธ ๊ทธ๋ฆฌ๋๋ก ์ด๋ฏธ์ง ํ๋กฌํํธ
- ๊ฐ ํฌ์ธํธ์ ๋ํด ๋ค์ค ๋ง์คํฌ ์์ธก
- ์: โํโ ํฌ์ธํธ โ ํ / ํ+๋ชธํต / ์ ์ฒด ์ฌ๋ ๋ง์คํฌ
- IoU ์์ธก ๋ชจ๋๋ก ์ ๋ขฐ๋ ๋์ ๋ง์คํฌ๋ง ์ ํ
- ์์ ์ฑ ๊ฒ์ฌ:
- ํ๋ฅ ๋งต์ 0.5, 0.55 ๋ฑ์ผ๋ก thresholdํด๋ ๋น์ทํ๋ฉด โ์์ ๋ ๋ง์คํฌโ
- NMS (Non-Max Suppression)๋ก ์ค๋ณต ์ ๊ฑฐ
- ์์ ๊ฐ์ฒด ๋ณด์์ ์ํด ํ๋๋ ์ด๋ฏธ์ง crop๋ ๋ณ๋ ฌ ์ฒ๋ฆฌ
์ต์ข
์์ฑ๋ ๋ฐ์ดํฐ(SA-1B)๋!?
๐ผ๏ธ ์ด๋ฏธ์ง ๊ตฌ์ฑ
ํญ๋ชฉ | ๋ด์ฉ |
---|
์ด๋ฏธ์ง ์ | 11,000,000์ฅ |
ํด์๋ | ํ๊ท 3300 ร 4950 ํฝ์
|
์ถ์ฒ | ์ฌ์ง์๊ฐ์ ์ง์ ํ์
ํ๋ ๊ณต๊ธ์
์ฒด๋ก๋ถํฐ ๋ผ์ด์ ์ค ํ๋ |
๋ณดํธ ์กฐ์น | ์ผ๊ตด ๋ฐ ์ฐจ๋ ๋ฒํธํ ๋ธ๋ฌ ์ฒ๋ฆฌ ํฌํจ |
๋ฐฐํฌ ํ์ | ์ต๋จ ๋ณ ๊ธฐ์ค 1500ํฝ์
๋ค์ด์ํ ๋ฒ์ ์ ๊ณต |
๋น๊ต | COCO: 480ร640 โ SA-1B๋ ํจ์ฌ ๋ ๊ณ ํด์๋ |
๐งฉ ๋ง์คํฌ ๊ตฌ์ฑ
ํญ๋ชฉ | ๋ด์ฉ |
---|
์ด ๋ง์คํฌ ์ | 1.1B (11์ต ๊ฐ) |
์์ฑ ๋ฐฉ์ | 99.1% ์๋ ์์ฑ (Fully Automatic Stage) |
ํฌํจ ๋ง์คํฌ | ์ต์ข
์ ์ผ๋ก๋ ์๋ ์์ฑ๋ ๋ง์คํฌ๋ง ํฌํจ๋จ |
ํ์ง ํ๊ฐ | ์ ๋ฌธ๊ฐ ๋ณด์ ๋๋น 94%๊ฐ IoU > 90% ์์ค์ ์ผ์น์จ |
๐ ํ์ง ๊ฒ์ฆ: ์๋ vs ์ ๋ฌธ๊ฐ์ ๊ฒ์ฆ!!
- ๋ฌด์์ 500๊ฐ ์ด๋ฏธ์ง(์ด 5๋ง ๋ง์คํฌ)๋ฅผ ์ํ๋งํ์ฌ
์ ๋ฌธ๊ฐ๊ฐ ๋ธ๋ฌ์ & ์ง์ฐ๊ฐ๋ก ๋ง์คํฌ๋ฅผ ์ ๊ตํ๊ฒ ๋ณด์ - ๊ทธ ๊ฒฐ๊ณผ:
- 94%์ ๋ง์คํฌ ์์ด IoU > 90%
- 97%๋ IoU > 75%
- ์ฐธ๊ณ : ๊ธฐ์กด ๋
ผ๋ฌธ ๊ธฐ์ค ์ฌ๋ ๊ฐ IoU ์ผ์น์จ์ 85~91% ์์ค
- โ SAM์ ์๋ ๋ง์คํฌ๋ ์ ๋ฌธ๊ฐ ์์ค์ ํ์ง ํ๋ณด
PC์ ๋ฐ์ดํฐ!!
- ๋จ์ฑ ์ฌ์ฑ, ์ ๋ฝ ์์์ ์ํ๋ผ์นด ๋ฑ ์ด๋ค์ ์์๋ ์น์ฐ์น์ง ์์ Fairness ๋ฐ์ดํฐ์์!!^^*
Zero-Shot Transfer Experiments (SAM์ ๋ฒ์ฉ์ฑ ์คํ)
SAM(Segment Anything Model)์ ๋จ์ํ ์ด๋ฏธ์ง์ ๋ง์คํฌ๋ฅผ ๊ทธ๋ฆฌ๋ ๋๊ตฌ๋ฅผ ๋์ด!!
์ถ๊ฐ ํ์ต ์์ด ๋ค์ํ ๋น์ ๊ณผ์ ์ ์ง์ ์ ์ฉ ๊ฐ๋ฅํ ๋ฒ์ฉ ๋ชจ๋ธ์ด๋ผ๋ ์ ์ ์คํ์ ํตํด ์
์ฆ
์ด 5๊ฐ์ง ์คํ์ ํตํด SAM์ Zero-Shot ์ฑ๋ฅ์ ์ธก์
๐งญ Zero-shot ์คํ ๊ฐ์
- Zero-Shot Transfer: SAM์ ํ์ต์ ์ฌ์ฉ๋์ง ์์ ๋ฐ์ดํฐ์
๊ณผ ์์
์ ๋ํด ์ง์ ์ ์ฉ
- ํ๊ฐ ๋์ ๊ณผ์ 5์ข
:
- Single-Point Valid Mask (๋จ์ผ ํฌ์ธํธ ๊ฐ์ฒด ๋ถํ )
- Edge Detection (์์ง ๊ฐ์ง)
- Object Proposal Generation (๊ฐ์ฒด ์ ์)
- Instance Segmentation (์ธ์คํด์ค ๋ถํ )
- Text-to-Mask (ํ
์คํธ โ ๋ง์คํฌ)
- ์คํ ์์ฝ!
์คํ | ๊ฒฐ๊ณผ ์์ฝ |
---|
Single-Point Mask | RITM ๋๋น ์ ์ฑยท์ ๋ ์ฑ๋ฅ ๋ชจ๋ ์ฐ์ |
Edge Detection | ํ์ต ์์ด๋ ์๋ฏธ ์๋ ์์ง ์ถ์ถ ๊ฐ๋ฅ |
Object Proposal | ์ค๊ฐ/ํฌ๊ท ๊ฐ์ฒด ์ ์์์ ์ต๊ณ ์์ค ์ฑ๋ฅ |
Instance Segmentation | AP๋ ๋ฎ์ง๋ง ์๊ฐ์ ํ์ง๊ณผ ์ฌ์ฉ์ ํ๊ฐ ์ฐ์ |
Text-to-Mask | CLIP ์๋ฒ ๋ฉ ํ์ฉํด ์์ฐ์ด ๋ถํ ๊น์ง ํ์ฅ ์ฑ๊ณต |
1๏ธโฃ ๋จ์ผ ํฌ์ธํธ ๊ฐ์ฒด ๋ถํ (Single-Point Valid Mask)
- ์ค์ : ์ ๊ฒฝ ํฌ์ธํธ ํ๋๋ง์ผ๋ก ๊ฐ์ฒด ๋ถํ
- ํ๊ฐ: mIoU + ์ฌ๋ ์ฃผ์์ ํ๊ฐ (1~10์ )
- ๊ฒฐ๊ณผ:
- 23๊ฐ ์ค 16๊ฐ ๋ฐ์ดํฐ์
์์ RITM ๋๋น mIoU ์ฐ์
- Oracle ์ ํ ์ ์ ๋ฐ์ดํฐ์
์์ RITM ๋ฅ๊ฐ
- ์ฌ๋ ํ๊ฐ๋ 7~9์ ์ผ๋ก RITM๋ณด๋ค ์ผ๊ด๋๊ฒ ๋์
- SAM์ ๋ชจํธํ ์
๋ ฅ์์๋ ์ ํจํ ๋ง์คํฌ ์์ฑ ๋ฅ๋ ฅ ์
์ฆ
2๏ธโฃ ์ฃ์ง ๊ฐ์ง (Zero-Shot Edge Detection)
- ์ค์ : BSDS500์์ ์์ง ๊ฐ์ง ์ํ
- 16ร16 ํฌ์ธํธ๋ก SAM์ ํ๋กฌํํธ โ Sobel ํํฐ๋ก ๊ฒฝ๊ณ ์ถ์ถ
- ๊ฒฐ๊ณผ:
- ์์ง ๊ฐ์ง์ฉ ํ์ต ์์ด๋ ์๋ฏธ ์๋ ์์ง ๋งต ์์ฑ
- ์ต์ ๊ธฐ๋ฒ๋ณด๋จ ์ ๋ฐ๋๋ ๋ฎ์ง๋ง, HED ๋ฑ ์ด๊ธฐ ๋ฅ๋ฌ๋ ๋ชจ๋ธ ์์ค ์ด์
- Zero-shot ์น๊ณ ๋งค์ฐ ์ฐ์ํ ์ฑ๋ฅ
3๏ธโฃ ๊ฐ์ฒด ์ ์ (Zero-Shot Object Proposal)
- ์ค์ : LVIS์์ ์ ์๋ ๋ง์คํฌ๋ค๋ก ๊ฐ์ฒด ์ ์
- ๋น๊ต: ViTDet-H + Mask R-CNN (DMP ๋ฐฉ๋ฒ)
- ํ๊ฐ ์งํ: Average Recall (AR@1000)
- ๊ฒฐ๊ณผ:
- ์ค๊ฐ/ํฐ ๊ฐ์ฒด, ํฌ๊ท/์ผ๋ฐ ๊ฐ์ฒด์์ ViTDet-H๋ณด๋ค ์ฐ์
- ์์ ๊ฐ์ฒด์์๋ ViTDet-H๊ฐ ์ฐ์ธ (LVIS์ ํนํ๋ ํ์ต ๋๋ฌธ)
- Ambiguity-aware ๋ฒ์ ์ด ์๋์ ์ฑ๋ฅ ํฅ์ ์ ๊ณต
4๏ธโฃ ์ธ์คํด์ค ์ธ๋ถํ (Zero-Shot Instance Segmentation)
- ์ค์ : ๊ฐ์ง๊ธฐ(ViTDet) ๋ฐ์ค๋ฅผ ํ๋กฌํํธ๋ก SAM์ ๋ง์คํฌ ์์ฑ
- ๊ฒฐ๊ณผ:
- COCO/LVIS์์ AP๋ ViTDet๋ณด๋ค ๋ฎ์ง๋ง
- ๊ฒฝ๊ณ ํ์ง์ SAM์ด ๋ ์ฐ์
- ์ฌ๋ ํ๊ฐ์์๋ SAM ๋ง์คํฌ๊ฐ ๋ ๋๊ฒ ํ๊ฐ๋จ
- ๋ถ์:
- COCO๋ ํ์ง ๋ฎ์ GT โ ViTDet๋ ๋ฐ์ดํฐ ํธํฅ ํ์ต
- SAM์ ๊ทธ๋ฐ ํธํฅ ์์ด ๋ณด๋ค ์ผ๋ฐ์ ์ธ ๋ถํ ์ํ
5๏ธโฃ ํ
์คํธ โ ๋ง์คํฌ (Zero-Shot Text-to-Mask)
- ์ค์ : ํ
์คํธ ํ๋กฌํํธ๋ง์ผ๋ก ๊ฐ์ฒด ๋ถํ
- CLIP์ ์ด๋ฏธ์ง ์๋ฒ ๋ฉ โ ํ
์คํธ ์๋ฒ ๋ฉ ์ ๋ ฌ์ ์ด์ฉํด ํ์ต
- ๊ฒฐ๊ณผ:
- โa wheelโ, โbeaver tooth grilleโ ๋ฑ ์์ฐ์ด๋ก ๊ฐ์ฒด ๋ถํ ๊ฐ๋ฅ
- ํ
์คํธ๋ง์ผ๋ก ์ ์๋ ๊ฒฝ์ฐ, ํฌ์ธํธ ํ๋กฌํํธ๋ฅผ ์ถ๊ฐํ๋ฉด ๊ฐ์ ๋จ
- ์์ฌ์ :
- SAM์ ๋ฉํฐ๋ชจ๋ฌ ์ธํฐํ์ด์ค๋ก ๋ฐ์ ๊ฐ๋ฅ์ฑ์ด ํผ
โจ ๋ง๋ฌด๋ฆฌํ๋ฉฐ
๋จ์ํ ์ฐ๊ตฌ๋ง ํ๊ธฐ๋ ๋ฐ์๋ฐ,, ๋น
ํ
ํฌ ๊ธฐ์
์์ ์ฐ๊ตฌ ๋ชจ๋ธ + ๋ฐ์ดํฐ์
์ ๊ณต๊ฐํด์ค๋ค๋๊ฒ์!
๊ฒ๋ค๊ฐ Fairness๋ฅผ ๊ฐ์ถ ์ข์๋ฐ์ดํฐ๋ฅผ ์ ๊ณตํด์ค๋ค๋ ๊ฒ์ ์ฐธ ๊ณ ๋ง์ด ์ผ์ธ๊ฒ ๊ฐ์ต๋๋ค!
์ธ์ ๊ฐ! ์ฐ๋ฆฌ๋ ๋์ ํ์ง์ ๋ฐ์ดํฐ์
๊ณผ ๊ณ ์ฑ๋ฅ์ ๋ชจ๋ธ์ ๊ณต๊ฐํ๋ ๋ ์ด ์ค๊ธฐ๋ฅผ!@!!