No project description provided
Project description
calib-targets Python bindings
These bindings expose a native-feeling Python API backed by Rust (PyO3 + maturin).
Build & develop
pip install maturin
maturin develop
python -c "import calib_targets as ct; print(ct.detect_chessboard)"
Public API
Top-level detectors return typed dataclasses:
detect_chessboard(image, *, chess_cfg=None, params=None) -> ChessboardDetectionResult | Nonedetect_charuco(image, *, chess_cfg=None, params) -> CharucoDetectionResultdetect_marker_board(image, *, chess_cfg=None, params=None) -> MarkerBoardDetectionResult | Nonerender_target_bundle(document) -> GeneratedTargetBundlewrite_target_bundle(document, output_stem) -> WrittenTargetBundle
Configuration is typed-only (dataclasses):
ChessConfig,ChessCornerParams,CoarseToFineParams,PyramidParamsChessboardParams,OrientationClusteringParams,GridGraphParamsCharucoBoardSpec,CharucoDetectorParams,ScanDecodeConfigMarkerCircleSpec,MarkerBoardLayout,CircleScoreParams,CircleMatchParams,MarkerBoardParamsPageSize,PageSpec,RenderOptions,ChessboardTargetSpec,CharucoTargetSpec,MarkerBoardTargetSpec,PrintableTargetDocument
Enums and literals:
TargetKind,CirclePolarity,MarkerLayoutDictionaryName(Literal) andDICTIONARY_NAMES
Inputs
imagemust be a 2Dnumpy.ndarraywithdtype=uint8.chess_cfgmust beChessConfig | None.paramsmust be typed params dataclasses (orNonewhere allowed).- Dict/mapping inputs are intentionally rejected in the new API.
Results and compatibility
Result models are dataclasses with attribute access and editor navigation. Every config/result model provides:
to_dict()from_dict(...)
This is the compatibility path for JSON pipelines and legacy dict-based code.
Migration guide
| Old usage | New usage |
|---|---|
detect_chessboard(img, params={"min_corners": 16}) |
detect_chessboard(img, params=ChessboardParams(min_corners=16)) |
detect_charuco(..., params={"board": {...}}) |
detect_charuco(..., params=CharucoDetectorParams(board=CharucoBoardSpec(...))) |
result["detection"]["corners"] |
result.detection.corners |
| N/A | result.to_dict() / ResultType.from_dict(...) |
Examples
pip install pillow
python examples/detect_chessboard.py path/to/image.png
python examples/detect_charuco.py path/to/image.png
python examples/detect_marker_board.py path/to/image.png
python examples/generate_printable.py tmpdata/printable/charuco_a4
For the canonical printable-target JSON model, the repo-local CLI flow, and print-at-100%-scale guidance, see the workspace printable-target guide: https://vitalyvorobyev.github.io/calib-targets-rs/printable.html
Implementation note
The compiled module is internal (calib_targets._core).
Public API stability is guaranteed only for top-level calib_targets exports.
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 Distributions
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 calib_targets-0.4.0.tar.gz.
File metadata
- Download URL: calib_targets-0.4.0.tar.gz
- Upload date:
- Size: 220.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
463963a8b4f40c3c31fa89b10b9333bac610680a262446ee46931b8e9f689edd
|
|
| MD5 |
477ac1fba24432548305cb8e14a8aece
|
|
| BLAKE2b-256 |
49f8bc1cb33229887437d600010e924aa86cf16655f9dc544c9dd67dbdbb659b
|
Provenance
The following attestation bundles were made for calib_targets-0.4.0.tar.gz:
Publisher:
release-pypi.yml on VitalyVorobyev/calib-targets-rs
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
calib_targets-0.4.0.tar.gz -
Subject digest:
463963a8b4f40c3c31fa89b10b9333bac610680a262446ee46931b8e9f689edd - Sigstore transparency entry: 1199114994
- Sigstore integration time:
-
Permalink:
VitalyVorobyev/calib-targets-rs@71e8e6c5ccdcc683238cbc6e2831359bb95dd6ae -
Branch / Tag:
refs/tags/v0.4.0 - Owner: https://github.com/VitalyVorobyev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-pypi.yml@71e8e6c5ccdcc683238cbc6e2831359bb95dd6ae -
Trigger Event:
push
-
Statement type:
File details
Details for the file calib_targets-0.4.0-cp310-abi3-win_amd64.whl.
File metadata
- Download URL: calib_targets-0.4.0-cp310-abi3-win_amd64.whl
- Upload date:
- Size: 830.5 kB
- Tags: CPython 3.10+, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ff5f7fabaa96ea0d976f8d6b44010a9ae85afdab5202262e3cd4146acc144296
|
|
| MD5 |
7ba997b3d381014f97abc0dce45104ea
|
|
| BLAKE2b-256 |
6cd3d7d8c5b2d067973061cb94ba436cfc48cfa3b9895d9b18efbb05f551d43b
|
Provenance
The following attestation bundles were made for calib_targets-0.4.0-cp310-abi3-win_amd64.whl:
Publisher:
release-pypi.yml on VitalyVorobyev/calib-targets-rs
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
calib_targets-0.4.0-cp310-abi3-win_amd64.whl -
Subject digest:
ff5f7fabaa96ea0d976f8d6b44010a9ae85afdab5202262e3cd4146acc144296 - Sigstore transparency entry: 1199115120
- Sigstore integration time:
-
Permalink:
VitalyVorobyev/calib-targets-rs@71e8e6c5ccdcc683238cbc6e2831359bb95dd6ae -
Branch / Tag:
refs/tags/v0.4.0 - Owner: https://github.com/VitalyVorobyev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-pypi.yml@71e8e6c5ccdcc683238cbc6e2831359bb95dd6ae -
Trigger Event:
push
-
Statement type:
File details
Details for the file calib_targets-0.4.0-cp310-abi3-macosx_11_0_arm64.whl.
File metadata
- Download URL: calib_targets-0.4.0-cp310-abi3-macosx_11_0_arm64.whl
- Upload date:
- Size: 956.6 kB
- Tags: CPython 3.10+, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fb651e5f25edb2d0b19d1c952fcbf95d9d13a63405e065ec7d8312cfeca5b396
|
|
| MD5 |
16625aedb4508e134e5555a6bd2b1a05
|
|
| BLAKE2b-256 |
e5918fa57fe84558fe58561612251a3732cf8243e0336652dac7d773faa47f86
|
Provenance
The following attestation bundles were made for calib_targets-0.4.0-cp310-abi3-macosx_11_0_arm64.whl:
Publisher:
release-pypi.yml on VitalyVorobyev/calib-targets-rs
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
calib_targets-0.4.0-cp310-abi3-macosx_11_0_arm64.whl -
Subject digest:
fb651e5f25edb2d0b19d1c952fcbf95d9d13a63405e065ec7d8312cfeca5b396 - Sigstore transparency entry: 1199115256
- Sigstore integration time:
-
Permalink:
VitalyVorobyev/calib-targets-rs@71e8e6c5ccdcc683238cbc6e2831359bb95dd6ae -
Branch / Tag:
refs/tags/v0.4.0 - Owner: https://github.com/VitalyVorobyev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-pypi.yml@71e8e6c5ccdcc683238cbc6e2831359bb95dd6ae -
Trigger Event:
push
-
Statement type:
File details
Details for the file calib_targets-0.4.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: calib_targets-0.4.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.5 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9e26383ad3e2add569be724801b923cc9e5a047f52034a112c3b1978d7d5d0f3
|
|
| MD5 |
1a50adcd8d1a6852b9effe04d847daca
|
|
| BLAKE2b-256 |
8ca1670712696ea54be28f87372fb4536e213ca00f31fadd933d5fa879e0b374
|
Provenance
The following attestation bundles were made for calib_targets-0.4.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:
Publisher:
release-pypi.yml on VitalyVorobyev/calib-targets-rs
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
calib_targets-0.4.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl -
Subject digest:
9e26383ad3e2add569be724801b923cc9e5a047f52034a112c3b1978d7d5d0f3 - Sigstore transparency entry: 1199115195
- Sigstore integration time:
-
Permalink:
VitalyVorobyev/calib-targets-rs@71e8e6c5ccdcc683238cbc6e2831359bb95dd6ae -
Branch / Tag:
refs/tags/v0.4.0 - Owner: https://github.com/VitalyVorobyev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-pypi.yml@71e8e6c5ccdcc683238cbc6e2831359bb95dd6ae -
Trigger Event:
push
-
Statement type: