Neural Style Transfer Studio is a revolutionary Streamlit web application that transforms your ordinary photos into extraordinary artistic masterpieces! ๐ญ Leveraging the power of deep learning and Neural Style Transfer, this app combines the content of one image with the artistic style of another, creating unique and visually stunning results that look like they were painted by famous artists.
- ๐ค Content Image Upload: Easily upload any photograph you wish to transform
- ๐จ Multiple Style Options: Choose from predefined artistic styles or upload custom ones
- ๐๏ธ Real-time Preview: See your content and style images instantly in the app
- ๐๏ธ Predefined Gallery: Curated collection of famous artistic styles
- ๐ช Custom Style Upload: Use your own images as artistic styles
- ๐ Single or Multiple: Apply one style or experiment with multiple styles simultaneously
- ๐๏ธ Quality Settings: Adjust output resolution for optimal results
- ๐ Color Preservation: Experimental feature to maintain original colors (beta)
- โฑ๏ธ Progress Tracking: Visual feedback during the transformation process
- ๐ผ๏ธ Individual Downloads: Save each styled image as high-quality PNG
- ๐ฆ Batch Download: Download all generated images as a convenient ZIP file
- ๐ Organized Naming: Automatically timestamped and labeled files
- ๐ฅ๏ธ Responsive Design: Works beautifully on desktop, tablet, and mobile
- ๐ Professional UI: Modern, intuitive interface with smooth animations
- โน๏ธ Informative Sections: Built-in guide explaining Neural Style Transfer
graph TD
A[๐ท Content Image] --> C[๐ง Neural Network]
B[๐จ Style Image] --> C
C --> D[๐ Feature Extraction]
D --> E[๐ญ Style Transfer Process]
E --> F[โจ Artistic Masterpiece]
F --> G[๐พ Download Result]
- ๐ง Content Analysis: The neural network analyzes the structural content of your photo
- ๐จ Style Extraction: Artistic patterns and textures are extracted from the style image
- ๐ Feature Mixing: Deep learning algorithms blend content structure with artistic style
- โจ Reconstruction: A new image is generated combining both elements seamlessly
- Python 3.8 or higher ๐
- pip package manager ๐ฆ
- Internet connection (for model downloads) ๐
-
๐ฅ Clone the Repository
git clone https://github.com/HackWGaveesh/Neural-Style-Transfer-Studio.git cd Neural-Style-Transfer-Studio
-
๐ Create Virtual Environment (Recommended)
python -m venv venv # Windows venv\Scripts\activate # macOS/Linux source venv/bin/activate
-
๐ฆ Install Dependencies
pip install -r requirements.txt
-
๐จ Prepare Style Images
# Create the Styles directory and add your style images mkdir Styles # Add your style images (vangogh.jpg, monet.jpg, etc.) to this folder
-
๐ Launch the Application
streamlit run StyleGan_Main.py
-
๐ Open in Browser
- The app will automatically open at
http://localhost:8501
- Start creating your artistic masterpieces!
- The app will automatically open at
๐จ Neural-Style-Transfer-Studio/
โโโ ๐ StyleGan_Main.py # Main Streamlit application
โโโ ๐ requirements.txt # Python dependencies
โโโ ๐จ Styles/ # Predefined style images directory
โ โโโ BW.jpg # Black & White style
โ โโโ Fauvism.jpg # Fauvism artistic style
โ โโโ Ghibli.jpg # Studio Ghibli animation style
โ โโโ Impressionism.jpg # Impressionist painting style
โ โโโ Landscape.jpg # Natural landscape style
โ โโโ PopArt.jpg # Pop Art movement style
โ โโโ PsychedelicArt.jpg # Psychedelic art style
โ โโโ Ukiyoe.jpg # Japanese woodblock print
โ โโโ Vintage.jpg # Vintage/retro style
โ โโโ anime.jpg # Anime/manga style
โโโ ๐ README.md # This file
โโโ ๐ .gitignore # Git ignore rules
โโโ ๐ LICENSE # License file
- Navigate to the "๐ธ Upload & Create" tab
- Click "Choose a content image" to upload your photo
- Supported formats: JPG, JPEG, PNG, WebP
- Preview appears instantly with image dimensions
- Choose "๐จ Predefined Styles"
- Select "Single Style" or "Multiple Styles" mode
- Click on style thumbnails to select/deselect
- See real-time selection feedback
- Choose "๐๏ธ Custom Style"
- Upload your own artistic reference image
- Any image can become a style template!
- ๐๏ธ Output Quality: Adjust from 1-10 (higher = better quality, larger files)
- ๐ Color Preservation: Experimental feature to maintain original colors
- Click "๐๏ธ Generate Artwork" button
- Watch the progress bar as your masterpiece is created
- Processing time varies by image complexity
- Individual Download: Save each styled image separately
- ๐ฆ Batch Download: Get all images in one ZIP file
- ๐ท๏ธ Auto-naming: Files include style name and timestamp
Style | Description | Artistic Movement |
---|---|---|
๐จ BW | Classic black and white artistic style | Monochrome Art |
๐ญ Fauvism | Bold, non-naturalistic colors | Early 20th Century |
๐๏ธ Ghibli | Studio Ghibli animation style | Japanese Animation |
๐ธ Impressionism | Soft brushstrokes and light effects | 19th Century Movement |
๐๏ธ Landscape | Natural scenery artistic interpretation | Landscape Art |
๐ช Pop Art | Bold colors and commercial imagery | 1950s Pop Culture |
๐ Psychedelic Art | Vibrant, surreal visual effects | 1960s Counterculture |
๐ Ukiyoe | Traditional Japanese woodblock prints | Edo Period Japan |
๐ฐ Vintage | Retro and classic artistic styling | Vintage Aesthetics |
๐ Anime | Japanese anime and manga style | Modern Japanese Art |
- Add your style images to the
Styles/
directory - Supported formats: JPG, JPEG, PNG, WebP
- Recommended resolution: 512x512 pixels or higher
- Restart the app to see new styles in the gallery
- GPU Acceleration: TensorFlow automatically uses GPU if available
- Memory Management: Large images are automatically resized for processing
- Batch Processing: Multiple styles processed efficiently
- Model Loading Issues: Ensure stable internet connection for initial model download
- Memory Errors: Try reducing image size or output quality
- Style Not Appearing: Check image format and restart application
We welcome contributions from the community! ๐ Here's how you can help:
- ๐ Bug Reports: Found an issue? Open an issue with details
- โจ Feature Requests: Suggest new features or improvements
- ๐จ Style Gallery: Share interesting style images
- ๐ Documentation: Help improve our guides and tutorials
- ๐ป Code Contributions: Submit pull requests with enhancements
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature
- Make your changes and test thoroughly
- Commit changes:
git commit -m 'Add amazing feature'
- Push to branch:
git push origin feature/amazing-feature
- Open a Pull Request with detailed description
- ๐ญ Additional neural style transfer models
- ๐จ Style mixing and blending features
- ๐ฑ Mobile app version
- ๐ Video style transfer capabilities
- ๐ผ๏ธ Batch processing for multiple images
- ๐๏ธ More advanced parameter controls
This project is licensed under the MIT License - see the LICENSE file for details.
- ๐ง Google Research for the Arbitrary Image Stylization model
- ๐จ TensorFlow Hub for providing pre-trained models
- ๐ Streamlit team for the amazing web framework
- ๐ญ Art Community for inspiring styles and creativity
- ๐จโ๐ป Open Source Community for continuous inspiration
Metric | Value |
---|---|
โก Average Processing Time | 15-30 seconds |
๐ผ๏ธ Supported Image Formats | JPG, PNG, WebP |
๐ Max Image Resolution | 4K (4096x4096) |
๐จ Available Styles | 10 predefined styles |
๐พ Output Format | High-quality PNG |
- ๐ Neural Style Transfer Paper
- ๐ค TensorFlow Hub Model
- ๐จ Streamlit Documentation
- ๐ง Deep Learning Resources
- ๐ธ Use high-resolution, well-lit content images
- ๐จ Choose style images with distinct artistic characteristics
- โ๏ธ Experiment with different quality settings
- ๐ Try multiple styles to find your favorite combination
- ๐ Processing time increases with image size
- ๐พ Large images may require more memory
- ๐ Color preservation is experimental and may not work perfectly
- ๐ฅ๏ธ GPU acceleration recommended for large batches
Questions? Suggestions? Just want to share your amazing creations?
โญ If this project inspired you to create amazing art, please give it a star! โญ
Transform your world through the lens of artificial intelligence and artistic creativity ๐โจ
Created with โค๏ธ by HackWGaveesh