Detect and recognize colors in images or video
Project description
ColorDetect
ColorDetect
Documentation |
Package
ColorDetect works to recognize and identify different colors in an image or video.
Installation
pip install ColorDetect
Basic Usage
Images
from colordetect import ColorDetect
user_image = ColorDetect(<path_to_image>)
# return dictionary of color count. Do anything with this
user_image.get_color_count()
# write color count
user_image.write_color_count()
# optionally, write any text to the image
user_image.write_text(text="any text")
# save the image after using either of the options (write_color_count/write_text) or both
user_image.save_image(<storage_path>,<image_name>)
Resultant image is stored in the string storage_path
of choice with the image_name
which will default to the current location and out.jpg respectively by default.
Videos
from colordetect import VideoColor,col_share
user_video = VideoColor(<path_to_video>)
# return dictionary of color count. Do anything with this result
user_video.get_video_frames(progress=True)
# to order this rather long result and get only a specific number look up the `col_share` module
Project Documentation
For further project documentation, visit ColorDetect's page
Contributions
Contributions are welcome. Do remember to take a look at the project contribution guidelines
Tests
To run tests:
pytest
Hall of Code
To the amazing human beings and developers that made this possible.
Project details
Release history Release notifications | RSS feed
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
File details
Details for the file ColorDetect-1.3.0.tar.gz
.
File metadata
- Download URL: ColorDetect-1.3.0.tar.gz
- Upload date:
- Size: 8.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.9.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f0a63a0ac8611e74ffe83fa93ceac76cb3a1243630e3215c53149d1dc594bfcc |
|
MD5 | 1f8dd298a0749ead2c8aee6e9ad3c429 |
|
BLAKE2b-256 | d1873bdb78da3ec343677f3aadebc8f32c491b8cd9abfaf790f73151ab6bf694 |
File details
Details for the file ColorDetect-1.3.0-py3-none-any.whl
.
File metadata
- Download URL: ColorDetect-1.3.0-py3-none-any.whl
- Upload date:
- Size: 11.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.9.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f89f751a5d20ea532c8ad407913554ac181abf75a473c921acff96f6424cba07 |
|
MD5 | ee0529ba004de96b14661e379f296d3b |
|
BLAKE2b-256 | 0cc97e02e0fe0796afb9da79ee08eb128c827f7f4c7c50297d3c4ed9698f9b13 |