File size: 1,458 Bytes
108b50e
 
 
 
 
 
3f541aa
108b50e
 
 
 
 
d193fbc
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
---
title: CLIPSegmentation
emoji: 🦀
colorFrom: red
colorTo: indigo
sdk: gradio
sdk_version: 5.25.2
app_file: app.py
pinned: false
license: mit
---

# CLIP Segmentation

CLIP Segmentation Project leverages the power of OpenAI's CLIP model combined with a segmentation decoder to perform image segmentation based on textual prompts. Provide an image and a text prompt, and get segmented masks for each prompt.


## Features

- **Textual Prompt Segmentation**: Segment images based on textual prompts.
- **Multiple Prompts**: Support for multiple prompts separated by commas.
- **Interactive UI**: User-friendly interface for easy image uploads and prompt inputs.


## Usage

1. Upload an image using the provided interface.
2. Enter your text prompts separated by commas.
3. Click on "Visualize Segments" to get the segmented masks.
4. Hover over a class to view the individual segment.

## How It Works

The CLIP Segmentation Project combines the power of a pretrained CLIP model with a segmentation decoder. The CLIP model, developed by OpenAI, understands images paired with natural language. By combining this with a segmentation decoder, we can generate segmented masks for images based on textual prompts, bridging the gap between vision and language in a unique way.


## Acknowledgements

- Thanks to [OpenAI](https://openai.com/) for the CLIP model.
- Thanks to [Image Segmentation Using Text and Image Prompts](https://github.com/timojl/clipseg).