Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

👗✨ Skin Tone-Based Clothing Color Recommendation API

Build Python License Issues Forks Stars Made with Python PRs Welcome Open Source


🧠 Overview

This project uses machine learning to classify skin tones and recommend the best clothing color palettes for each tone using HEX codes. It is particularly helpful for:

  • Fashion stylists 👗
  • E-commerce clothing stores 🛍️
  • Individuals seeking personalized wardrobe insights 🧥

🏗️ Project Structure

.
├── data/
│   ├── skin_shades_india.csv           # 56 skin tones with HEX codes
│   └── fashion_color_palette.csv       # Clothing colors by tone
├── output/
│   └── final_recommendations.csv       # Final recommendation output
├── skin_tone_mapping.py                # Main ML logic
├── requirements.txt                    # Python dependencies
├── README.md                           # You’re reading it!

🔍 Methodology

1. Data Preprocessing

  • Convert HEX → RGB
  • Normalize and clean color data

2. Skin Tone Classification

  • Use KMeans clustering to group similar tones
  • Assign tones to closest clothing palette category

3. Color Recommendation

  • Merge skin tone categories with fashion color palettes
  • Recommend 2–3 matching clothing colors per skin tone

📦 Dependencies

  • Python 3.8+
  • pandas
  • numpy
  • scikit-learn
  • matplotlib (optional, for visualizations)

Install with:

pip install -r requirements.txt

🚀 How to Run

python skin_tone_mapping.py

After execution, the final_recommendations.csv will be generated in the /output folder.

✅ Sample Output

Skin Shade ID Skin HEX Code Assigned Category Recommended Colors Color HEX Codes
Shade 1 #F5E0D8 Cool Tones Navy Blue, Emerald Green #000080, #50C878
Shade 2 #C68642 Warm Tones Coral, Mustard Yellow #FF7F50, #FFDB58

💡 API Integration (Coming Soon)

We are building a Flask/FastAPI-based interface to allow:

  • Skin tone HEX input via API
  • Receive recommended color palettes as JSON
  • Real-time predictions via model inference

Stay tuned! 🚧


🌱 Future Enhancements

  • 🔍 Use CNNs for more robust skin tone detection from images
  • 🌎 Expand datasets globally beyond India
  • 📱 Deploy as a web/mobile app
  • 📊 Integrate with e-commerce sites for live recommendations
  • 🧠 Add feedback learning loop for smarter suggestions

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.


👨‍💻 Developers

Maintained by Your Name. Contributions welcome via issues or pull requests!


⭐ If you like this project, don't forget to ⭐ the repo!`

About

A FastAPI-powered machine learning project for detecting skin tones from images and recommending clothing colors using color theory.

Topics

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages