Package for detecting Icons from images or screen
Project description
IconMatch
Easily select icons on the screen in any environment.
This is part of the Hands Free Computing project. Built with OpenCV 3.12 and Python 3.8.
💜 Sponsors:
Sponsor us and we can add your link, banner or other promo materials!
💜 Follow NativeSensors:
Table of Contents
Installation
- Install from PyPI:
$ pip install iconmatch
Usage
You can use the functions as shown in demo.py as a default entry point.
In the below example, the main set of functions is called within a callback function, as this allows the threshold value to be controlled from a GUI in OpenCV.
Image Scanner:
import cv2 as cv
import IconMatch.IconMatch from ImageScanner
src = cv.imread("source to your image file")
scanner = ImageScanner(thersh = 100)
detected_rectangles = scanner.scan(src)
# list of [(x,y,w,h),(x,y,w,h), ... , (x,y,w,h)]
Screen Scanner:
import IconMatch.IconMatch from ScreenScanner
scanner = ScreenScanner(thersh = 100)
detected_rectangles = scanner.scan(bbox = (x,y,w,h))
# list of [(x,y,w,h),(x,y,w,h), ... , (x,y,w,h)]
RealTime demo:
python rt_demo.py
Key Features
- Detection of areas with a high likelihood of being clickable icons.
- Detection of closest rectangle to point of interest (be it gaze, or mouse as in the examples)
API
The current available APIs encompass what your image processing pipeline should contain. Both APIs are currently still experimental as I learn more about OpenCV and optimize code.
ImageScanner
Performs Canny detection on passed images and group overlapping rectangles
ScreenScanner
Scans your display, take screnshoots and call ImageScanners
Roadmap
- Detect regions of interest with moderate accuracy
- Detect candidate region based on proximity
- Detect icon-like objects on the screen
- [?] Context provision into regions of interest
Contributing
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are genuinely appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
License
Distributed under the MIT License. See LICENSE
for more information.
Contact
Original Creator: Luis Zugasti - @luis__zugasti Original Creator blog: https://luiszugasti.me
Current Maintainer: Piotr Walas - @Piotr__Walas
Project Link: https://github.com/NativeSensors/IconMatch
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 iconmatch-0.2.0.tar.gz
.
File metadata
- Download URL: iconmatch-0.2.0.tar.gz
- Upload date:
- Size: 11.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.10.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c3c7f06ce272e84d0e913c14ff551592063912cf96671d18b6bf40e697fff3b3 |
|
MD5 | f288cb173bb148d8312128d8f855c60e |
|
BLAKE2b-256 | dfd40fc96784490e602450544f74908c6f8085c403ab55741867677b207ee02d |
File details
Details for the file iconmatch-0.2.0-py3-none-any.whl
.
File metadata
- Download URL: iconmatch-0.2.0-py3-none-any.whl
- Upload date:
- Size: 11.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.10.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 063e5577b60b5ed71c37bb536f16dc2671f3a55f5edcc5650a847283c5b564f4 |
|
MD5 | d86c3aae17049cba37f3dd32b2caf02d |
|
BLAKE2b-256 | 51b9c42e2d4c1d950ec7d2cc28c563986510230180c5adc9c7f1706da5fa13c3 |