Metadata-Version: 2.4
Name: camerakit
Version: 2.0.0
Summary: CLI and Python toolkit for camera calibration and synchronized capture
Home-page: https://github.com/saifkhichi96/camerakit
Author: CameraKit Contributors
License: MIT License
Project-URL: Bug Tracker, https://github.com/saifkhichi96/camerakit/issues
Keywords: camera,calibration,synchronized capture
Platform: any
Classifier: Programming Language :: Python :: 3
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Science/Research
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Information Technology
Classifier: Intended Audience :: End Users/Desktop
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Scientific/Engineering :: Image Processing
Classifier: Topic :: Multimedia :: Video
Classifier: Topic :: Multimedia :: Graphics
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Description-Content-Type: text/markdown
License-File: LICENSE
License-File: THIRD_PARTY_NOTICES.md
Requires-Dist: easydict
Requires-Dist: matplotlib
Requires-Dist: mpl_interactions
Requires-Dist: numpy
Requires-Dist: opencv-python
Requires-Dist: toml
Provides-Extra: docs
Requires-Dist: sphinx<9,>=7; extra == "docs"
Requires-Dist: furo>=2024.8.6; extra == "docs"
Dynamic: license-file

<p align="center">
  <img src="docs/_static/camerakit-header.svg" alt="CameraKit" width="100%" />
</p>

# CameraKit

CameraKit is a CLI-first Python package for camera calibration and synchronized capture.

Current package version: **v2.0.0**

## Stable Features

- Unified CLI with subcommands: `devices`, `init`, `calibrate`, `capture`, `report`
- Camera discovery with supported resolution/FPS/codec probing
- Checkerboard-based calibration (intrinsics + optional extrinsics)
- Optional fisheye intrinsics/extrinsics path in calibration workflow
- Calibration TOML outputs with separate per-camera errors:
  - `intrinsics_error_px`
  - `extrinsics_error_px`
- Synchronized software capture with per-trial recordings
- Calibration summary reporting via CLI

## Installation

```bash
pip install camerakit
```

For capture workflows, use GUI-enabled OpenCV (`opencv-python`).
`opencv-python-headless` intentionally disables the interactive capture command.

## Quickstart

```bash
# 1) Create a project
camerakit init --path /path/to/project --cameras 2

# 2) List devices
camerakit devices --max-cameras 6

# 3) Run calibration
camerakit calibrate --config /path/to/project

# 4) Summarize calibration output
camerakit report --input /path/to/project/calibration/Calib_board_outer.toml

# 5) Record synchronized videos
camerakit capture --data-dir data --max-cameras 6
```

Project layout example:

```text
project/
  Config.toml
  calibration/
    intrinsics/
      cam_00/ intrinsics.mp4
      cam_01/ intrinsics.mp4
    extrinsics/
      cam_00/ extrinsics.png
      cam_01/ extrinsics.png
```

## Python API

```python
from camerakit.calibration import run_calibration
from camerakit.utils import CameraEnumerator

run_calibration("/path/to/project")
cameras = CameraEnumerator(max_cameras=6).list()
```

## Documentation

Detailed Sphinx docs are in [`docs/`](docs/). Build locally with:

```bash
pip install -r docs/requirements.txt
make -C docs html
```

Open `docs/_build/html/index.html`.

## Contributing

See [CONTRIBUTING.md](CONTRIBUTING.md) for architecture notes, logging conventions,
documentation workflow, and roadmap priorities.

## Release Notes

See [RELEASE_NOTES.md](RELEASE_NOTES.md).

## Third-Party Notices

Some portions of this project include code derived from third-party sources under
their original licenses. See:

- [THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md)
- [licenses/BSD-3-Clause-pose2sim.txt](licenses/BSD-3-Clause-pose2sim.txt)

## License

CameraKit is licensed under the MIT License. See [LICENSE](LICENSE), plus
third-party notices and licenses listed above.

MIT License

Copyright (c) 2026 CameraKit Contributors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
