pnt2
Calculating the degree of similarity between geometric figures of different shapes (by 2 points)
Installation
pip install pnt2
How to use:
from pathlib import Path
from pnt2.src.get_similarity import get_similarity, calc_similarity, convert_to_canonical
""" Get input data """
path_1 = str(Path.cwd() / 'DATA' / 'first.png')
path_2 = str(Path.cwd() / 'DATA' / 'second.png')
similarity_1 = get_similarity(path_1, path_2)
image_1_can = convert_to_canonical('1', path_1)
image_2_can = convert_to_canonical('2', path_2)
similarity_2 = calc_similarity(image_1_can, image_2_can)
print(f'\nsimilarity_1 = {round(similarity_1, 7)}'
f'\nsimilarity_2 = {round(similarity_2, 7)}')
Release files for pnt2 1.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 | |
|---|---|---|---|
| pnt2-1.0.3.tar.gz | 8.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pnt2-1.0.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size:22.3 kB
Release files / pnt2-1.0.3.tar.gz
| Download URL | pnt2-1.0.3.tar.gz |
|---|---|
| Size | 8.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0f3db6d8f2afafceac1dd83aa1efae7854372373cabe6ef86b3732f0402b552a
|
|
BLAKE2b-256 checksum How to use checksums |
f6a4f4c75c004ae643d30358860072eaa2e45f94fe97af48ca40adcc557d4bd2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.5.1 CPython/3.10.11 Darwin/23.1.0
|
Release files / pnt2-1.0.3-py3-none-any.whl
| Download URL | pnt2-1.0.3-py3-none-any.whl |
|---|---|
| Size | 13.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3d96dcc6f3c792b8685fc37749b9693390b8074c94fd72df932c02bec0e2efcf
|
|
BLAKE2b-256 checksum How to use checksums |
31f8e574e3a4126823b4f8c05d737d73dac1fbb336f966a3decf792622bec8f7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.5.1 CPython/3.10.11 Darwin/23.1.0
|