A newer version of the Streamlit SDK is available:
1.52.2
metadata
title: Stable Diffusion Image Generator
emoji: π’
colorFrom: blue
colorTo: purple
sdk: streamlit
sdk_version: 1.42.2
app_file: src/app.py
pinned: false
license: apache-2.0
short_description: Transform your ideas into artistic masterpieces
π¨ AI Style Transfer Studio
Transform your ideas into artistic masterpieces using Stable Diffusion with custom style embeddings.
π Features
- Multiple pre-trained style embeddings (Dhoni, Mickey Mouse, Balloon, Lion King, Rose Flower)
- Advanced color enhancement technology
- User-friendly Streamlit interface
- Real-time image generation
- Example gallery with style comparisons
π οΈ Local Setup
- Clone the repository:
git clone https://github.com/yourusername/stable-diffusion-image-generator.git
cd stable-diffusion-image-generator
- Create and activate a virtual environment (recommended):
python -m venv venv
# On Windows
venv\Scripts\activate
# On Unix or MacOS
source venv/bin/activate
- Install dependencies:
pip install -r requirements.txt
- Run the Streamlit app:
streamlit run src/app.py
The app will open in your default web browser at http://localhost:8501
π Deploying to Hugging Face Spaces
Create a new Space on Hugging Face:
- Go to https://huggingface.co/spaces
- Click "Create new Space"
- Choose "Streamlit" as the SDK
- Set the Space name and visibility
Push your code to Hugging Face:
git add .
git commit -m "Initial commit"
git remote add space https://huggingface.co/spaces/yourusername/your-space-name
git push space main
- The deployment will start automatically. Monitor the build logs on your Space's page.
π― Usage
- Enter your creative prompt in the text area
- Select a style from the available options
- Click "Generate Artwork"
- View both the original and color-enhanced versions of your creation
π Requirements
- Python 3.8+
- CUDA-capable GPU (recommended)
- 8GB+ RAM
π Environment Variables
No additional environment variables are required for basic usage.
π License
This project is licensed under the Apache 2.0 License.
π Acknowledgments
- Stable Diffusion for the base model
- Hugging Face for model hosting and Spaces
- Streamlit for the web interface