register2d
Given a black-and-white binary image A and another smaller black-and-white binary image B, perform translation and rotation on B, and find the position in A that is closest to the transformed B. A and B should be saved in grey PNG image (mode='L').
GitHub repo: https://github.com/GGN-2015/register2d
Installation
pip install register2d
Usage
import register2d
image_a_path = "<Image A Path>"
image_b_path = "<Image B Path>"
# calculate registration
posY, posX, score, rot_deg = register2d.find_match_pos_and_rotate(image_a_path, image_b_path)
# show the position of image B in image A
register2d.get_red_mask_image(image_a_path, image_b_path, posY, posX, rot_deg).show()
# show the position of image B in a white image same size as A
register2d.get_rotated_and_moved_image(image_a_path, image_b_path, posY, posX, rot_deg).show()
Metadata
Release files for register2d 0.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| register2d-0.0.3.tar.gz | 6.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| register2d-0.0.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 14.7 kB
Release files / register2d-0.0.3.tar.gz
| Download URL | register2d-0.0.3.tar.gz |
|---|---|
| Size | 6.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f383fdd17e716e7ad5ef549f624db78b9b0044d321d8b8f0e8f42a3fc89959e2
|
|
BLAKE2b-256 checksum How to use checksums |
a67ca192e0cbb7d20386830666572dba14cee525e0a07b92cb52ba466fddc054
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.3 CPython/3.10.18 Linux/6.17.7-aosc-main
|
Release files / register2d-0.0.3-py3-none-any.whl
| Download URL | register2d-0.0.3-py3-none-any.whl |
|---|---|
| Size | 7.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c73390b5327cbb42d26af10a03e3224cf773946e0a93a1a418ae8d5973aa9c00
|
|
BLAKE2b-256 checksum How to use checksums |
9a015cbffade890b3a8e4afc53e31c98084e62ca4472f847aa48484331f45c22
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.3 CPython/3.10.18 Linux/6.17.7-aosc-main
|