An AI-powered fashion recommendation system that suggests complementary clothing items and styling ideas based on an uploaded image.
Built using DeepFashion2 (Kaggle version), CLIP embeddings, and ResNet50 classification, it provides occasion-aware, color-aware, and category-smart outfit recommendations.
✅ Automatic Clothing Detection
- Detects whether an uploaded image is Topwear, Bottomwear, Dress, or Outerwear using a trained ResNet50 model.
✅ Smart Outfit Suggestions
- Suggests complementary clothing items (e.g., Top → Bottomwear, Bottom → Topwear).
- Uses CLIP embeddings and FAISS similarity search for top 5 visually similar items.
✅ Color Analysis
- Extracts dominant colors using K-Means clustering and provides human-readable color names.
- Generates color harmony tips and contrast-based fashion advice.
✅ Occasion-Aware Styling
- Provides dynamic styling tips based on detected color tone and outfit type — for Casual, Formal, Party, Streetwear, or Festive occasions.
✅ Local Execution
- Works fully offline once the dataset and models are set up on your local machine.
- Python 3.10
- PyTorch / torchvision
- OpenAI CLIP
- FAISS (Facebook AI Similarity Search)
- Streamlit
- scikit-learn / OpenCV / Pillow
- Kaggle: DeepFashion2 Original Dataset
AI-Fashion-Stylist/
│
├── DeepFashion2/
│ ├── deepfashion2_original_images/
│ └── img_info_dataframes/ # train.csv, validation.csv, test.csv
│
├── data_subset/ # Prepared smaller dataset for training
│
├── models/
│ ├── cloth_classifier.pth # Trained ResNet50 model
│ ├── fashion_index.faiss # FAISS index built from CLIP embeddings
│ └── image_paths.pkl # List of images used in FAISS index
│
├── scripts/
│ ├── prepare_dataset.py # Dataset pre-processing
│ ├── train_classifier.py # Model training
│ ├── build_faiss.py # CLIP + FAISS builder
│ └── color_utils.py # Color extraction utility
│
├── demo_app.py # Streamlit application
└── README.md # You're reading it!
git clone https://github.com/ritup04/AI-Fashion-Stylist.git
cd AI-Fashion-Stylistpip install -r requirements.txt
⚠️ Make sure you’re using Python 3.10 for best compatibility with PyTorch and FAISS.
This project uses the DeepFashion2 dataset available on Kaggle.
📦 Dataset Link:
DeepFashion2 Original with Dataframes (Kaggle)
After downloading, extract it into:
AI-Fashion-Stylist/DeepFashion2/
⚠️ The dataset is not included in this repository due to its large size.
python scripts/prepare_dataset.pypython scripts/train_classifier.pypython scripts/build_faiss.pystreamlit run demo_app.py| Step | Description |
|---|---|
| 🖼️ Upload | Upload an outfit image (topwear, bottomwear, dress, etc.) |
| 🧠 Detection | The model classifies the outfit type |
| 🎨 Color Extraction | Extracts dominant colors & harmony |
| 🛍️ Similar Items | Displays top 5 similar or complementary outfits |
| 💡 Styling Tips | Gives dynamic, occasion-based fashion advice |
👩💻 Ritu Pal
🎓 B.Tech CSE (AI-ML), Adani University
📧 ritupal1626@gmail.com
💼 GitHub: ritup04
👩💻 Helly Khambhatwala
🎓 B.Tech CSE (AI-ML), Adani University
📧 helly9328@gmail.com
💼 GitHub: helly1408