A engine which detects prominent colors from the image.
Project description
prominent-colors-detector
A engine which detects prominent colors from the image.
Install Python Package
pip install image-pcd
Usage
from pcd import ImageProminentColor
from sklearn.cluster import KMeans
image_color = ImageProminentColor("<path to image file>")
prominent_colors = image_color.get_prominent_colors(KMeans, 3)
The above code-snippet gives you top 3 prominent colors in RGB form sorted in decreasing order of prominence from the image.
image_color.get_image_plot("<Save image file path>")
image_color.get_color_plot("<Save image file path>")
The above code-snippet allows you to save the images of plots of the prominent color and image original colors in 3D-space with RGB components as axis.
Samples (For top-3 Prominent Colors)
| Sample Image | Prominent Colors | Prominent Colors Plot | Image Colors Plot |
|---|---|---|---|
#215d1d #97244a #1d8197 |
|||
#7579b0 #fdfdfe #010101 |
|||
#fefefe #323232 #67a15d |
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file image-pcd-1.3.0.tar.gz.
File metadata
- Download URL: image-pcd-1.3.0.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.7.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
abb0bd2d225ed649a0fbfac07ae151c5fcc5ced168a6cc7c789451dfa470aa6c
|
|
| MD5 |
829ae0c24d72e0b6bfc5580e29dde1fd
|
|
| BLAKE2b-256 |
00f5ac2b96deb6274082a2e80b9870a720c0826530ec0c0eed1833b37b3725de
|
File details
Details for the file image_pcd-1.3.0-py3-none-any.whl.
File metadata
- Download URL: image_pcd-1.3.0-py3-none-any.whl
- Upload date:
- Size: 4.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.7.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8afe621c4208e4b589d997d5515be360697456044cafd629fc9d41f154be8066
|
|
| MD5 |
115a4870d7e61bcae69fe01456864a70
|
|
| BLAKE2b-256 |
0c1d3441463ea7e077cf05f6cb1d9ae4d426748c4d3e79004e1bc87a9889048a
|