Skip to content

Streamlit based webapp combining CLIP and SAM to perform one vocabulary image segmentation

License

Notifications You must be signed in to change notification settings

prateekralhan/CLIP-SAM-Streamlit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CLIP-SAM-Streamlit Project Status: Active

CLIP + SAM for open vocabulary image segmentation

demo

Installation:

  • Simply run the command pip install -r requirements.txt to install the dependencies.

Usage:

  1. Clone this repository and install the dependencies as mentioned above.
  2. Create a model directory and save the model checkpoints which can be downloaded from here.
  3. Simply run the command:
streamlit run app.py
  1. Navigate to http://localhost:8501 in your web-browser.
  2. By default, streamlit allows us to upload files of max. 200MB. If you want to have more size for uploading images, execute the command :
streamlit run app.py --server.maxUploadSize=1028

Running the Dockerized App

  1. Ensure you have Docker Installed and Setup in your OS (Windows/Mac/Linux). For detailed Instructions, please refer this.
  2. Navigate to the folder where you have cloned this repository ( where the Dockerfile is present ).
  3. Build the Docker Image (don't forget the dot!! 😄 ):
docker build -f Dockerfile -t app:latest .
  1. Run the docker:
docker run -p 8501:8501 app:latest

This will launch the dockerized app. Navigate to http://localhost:8501/ in your browser to have a look at your application. You can check the status of your all available running dockers by:

docker 

Citation

@article{kirillov2023segany,
  title={Segment Anything}, 
  author={Kirillov, Alexander and Mintun, Eric and Ravi, Nikhila and Mao, Hanzi and Rolland, Chloe and Gustafson, Laura and Xiao, Tete and Whitehead, Spencer and Berg, Alexander C. and Lo, Wan-Yen and Doll{\'a}r, Piotr and Girshick, Ross},
  journal={arXiv:2304.02643},
  year={2023}
}
@misc{radford2021learning,
      title={Learning Transferable Visual Models From Natural Language Supervision}, 
      author={Alec Radford and Jong Wook Kim and Chris Hallacy and Aditya Ramesh and Gabriel Goh and Sandhini Agarwal and Girish Sastry and Amanda Askell and Pamela Mishkin and Jack Clark and Gretchen Krueger and Ilya Sutskever},
      year={2021},
      eprint={2103.00020},
      archivePrefix={arXiv},
      primaryClass={cs.CV}
}

About

Streamlit based webapp combining CLIP and SAM to perform one vocabulary image segmentation

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Packages

No packages published