Welcome to the YOLOv5 + Segment Anything Model project! 🚀 ✨ This project combines the power of the YOLOv5 object detection model with the Segment Anything Model from Meta Research to create bounding boxes, perform segmentation, and extract stickers in RGBA format from images, saving the output as PNG files. The project also includes a script that automates the process, although currently it only runs on CPU.
🚀 Object detection with YOLOv5
🔍 Image segmentation with Segment Anything
🎨 Sticker extraction in RGBA format
🖼️ Automation script for easy usage
💡 Jupyter notebook for visualization
- 🍴 Fork the repository to your GitHub account.
- ⬇️ Clone the forked repository to your local machine.
- 💿 Navigate to the local repository using the command line.
- 💻 Run the script using the following command:
python sticker_script.py --input_image assets/dog.jpg,
where assets/dog.jpg is the path to the input image you want to generate stickers from. - ✉️ The generated stickers will be saved in the "results" folder for further usage.
The following dependencies are required to run the YOLOv5 and Segment Anything Sticker Generator:
- Python 3.x
- YOLOv5
- Segment Anything
- Pytorch >= 1.7
- Torchvision >= 0.8
- PIL (Python Imaging Library)
- Numpy
You can install these dependencies manually using the package manager of your choice.