GithubHelp home page GithubHelp logo

join2aj / image-color-analyser Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 96 KB

This is a Python Streamlit app that takes an image as input from the user, analyzes the colors in the image, and displays the results & their hex value with a beautiful pie chart

License: MIT License

Jupyter Notebook 98.35% Python 1.65%
opencv python matplotlib-pyplot matplotlib sklearn collection stramlit

image-color-analyser's Introduction

Image Color Analysis App

This is a Python Streamlit app that takes an image as input from the user, analyzes the colors in the image, and displays the results.

Usage

  1. Choose an image file to upload using the file upload widget.
  2. Click the "Analyze" button to perform color analysis on the image.
  3. The app will display the top colors used in the image, along with the percentage of each color used and the color name.

Program

The program uses the following Python packages:

  • collections
  • sklearn.cluster
  • matplotlib.colors
  • matplotlib.pyplot
  • cv2

The program consists of the following steps:

  1. Load the image from the specified file path.
  2. Convert the image from BGR to RGB color space.
  3. Resize and reshape the image to prepare it for color analysis.
  4. Perform color analysis using KMeans clustering.
  5. Determine the top colors used in the image and their percentage of usage.
  6. Display the top colors used in the image, along with their percentage of usage and color name.

Future Improvements

In the future, we might consider adding the ability to save the color analysis report as a PDF or image file. We might also explore more sophisticated methods for color analysis, such as deep learning models that can detect subtle variations in color and texture.

Buy Me A Coffee

image-color-analyser's People

Contributors

join2aj avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.