Lightweight instance segmentation of card IDs
Project description
microwink
Lightweight instance segmentation of card IDs.
Usage
Python
pip install microwink
from microwink import SegModel
from microwink.common import draw_mask, draw_box
from PIL import Image
seg_model = SegModel.from_path("./models/seg_model.onnx")
img = Image.open("./input.png").convert("RGB")
cards = seg_model.apply(img)
for card in cards:
print(f"score={card.score}, box={card.box}")
img = draw_mask(img, card.mask > 0.5)
img = draw_box(img, card.box)
img.save("./output.png")
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
microwink-0.0.3.tar.gz
(17.9 MB
view details)
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 microwink-0.0.3.tar.gz.
File metadata
- Download URL: microwink-0.0.3.tar.gz
- Upload date:
- Size: 17.9 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.5.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f2aace8a06974dc6a02b70616d8facfe7ef9f32045438ca5bae93499f06bf55c
|
|
| MD5 |
af5971f02c2740dc9055aad07ac2d94b
|
|
| BLAKE2b-256 |
48cbfb940e81e545cb6245faad5fb4ec1cb67d1de2b04729f871936938ae72f7
|
File details
Details for the file microwink-0.0.3-py3-none-any.whl.
File metadata
- Download URL: microwink-0.0.3-py3-none-any.whl
- Upload date:
- Size: 9.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.5.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3b2225e5833a4c697cce8346daf3d42b7116080d11d49d03f5cbede2721aab82
|
|
| MD5 |
9020c4efb1d11c7a12555910f45522e5
|
|
| BLAKE2b-256 |
0e2305fe57abfbee6c26d1bba0cca0c9a6bd3e4fead64fe0a14582163a69a7da
|