# skellytracker
The tracking backend for freemocap. Collects different pose estimation tools and aggregates them using a consistent API. Can run pose estimation on images, webcams, and videos.
## Run skelly_tracker
Installation: `pip install skellytracker`
Then it can be run with `skellytracker`.
Running the basic `skellytracker` will open the first webcam port on your computer and run pose estimaiton in realtime with mediapipe holistic as a tracker. You can specify the tracker with `skellytracker TRACKER_NAME`, where `TRACKER_NAME` is the name of an available tracker. To view the names of all available trackers, see `RUN_ME.py`.
It will take some time to initialize the tracker the first time you run it, as it will likely need to download the model.
## Using skellytracker in your project
To use skellytracker in your project, import a tracker like `from skellytracker import YOLOPoseTracker`, then instantiate it with your desired parameters like `tracker = YOLOPoseTracker(model_size="medium")`, and then use `tracker.process_image(frame)` or `tracker.process_video(video_filepath)`. Processing image by image will let you access each individual annotated frame with `tracker.annotated_image`, and you can optionally record the data with `tracker.recorder.record()`. Access recorded data with `tracker.recorder.process_tracked_objects()`. The running, recording, and processing are done separately to give control over the amount of processing done at each step in the pipeline. Processing an entire video allows you to save the annotated frames as a video, and optionally saves and returns the data as a numpy array. Each tracker has an associated `ModelInfo` class to access model attributes.
Skellytracker is still under development, so version updates may make breaking changes to the API. Please report any issues and pull requests to the [skellytracker repo](https://github.com/freemocap/skellytracker).
### Extending the API
To extend the API, import the `BaseTracker` and `BaseRecorder` abstract base classes from skellytracker. Then create a new tracker and recorder inheriting from the base classes and implement all of the abstract methods.
## Contributing
We love your input! We want to make contributing to this project as easy and transparent as possible, whether it's:
- Reporting a bug
- Discussing the current state of the code
- Submitting a fix
- Proposing new features
- Becoming a maintainer
Pull requests are the best way to propose changes to the codebase (we
use [Github Flow](https://docs.github.com/en/get-started/quickstart/github-flow)). We actively welcome your pull
requests:
1. Fork the repo and create your branch from `main`.
2. Download the development dependencies with `pip install -e '.[dev]'`.
2. If you've added code that should be tested (including any tracker), add tests.
3. If you've changed APIs, update the documentation.
4. Ensure the test suite passes by running `pytest skellytracker/tests`.
5. Make sure your code lints.
6. Make that pull request!
Raw data
{
"_id": null,
"home_page": null,
"name": "skellytracker",
"maintainer": null,
"docs_url": null,
"requires_python": "<3.13,>=3.9",
"maintainer_email": null,
"keywords": "camera, stream, video, image, opencv, skelly, freemocap, motion capture, synchronization, computer vision",
"author": null,
"author_email": "Skelly FreeMoCap <info@freemocap.org>",
"download_url": "https://files.pythonhosted.org/packages/46/5c/126fa23981ba7b9677158273ec1fcf80f24c37c336e89d09ed31e05abf34/skellytracker-2024.9.1019.tar.gz",
"platform": null,
"description": "# skellytracker\n\nThe tracking backend for freemocap. Collects different pose estimation tools and aggregates them using a consistent API. Can run pose estimation on images, webcams, and videos.\n\n## Run skelly_tracker\n\nInstallation: `pip install skellytracker`\nThen it can be run with `skellytracker`.\n\nRunning the basic `skellytracker` will open the first webcam port on your computer and run pose estimaiton in realtime with mediapipe holistic as a tracker. You can specify the tracker with `skellytracker TRACKER_NAME`, where `TRACKER_NAME` is the name of an available tracker. To view the names of all available trackers, see `RUN_ME.py`.\n\nIt will take some time to initialize the tracker the first time you run it, as it will likely need to download the model.\n\n## Using skellytracker in your project\n\nTo use skellytracker in your project, import a tracker like `from skellytracker import YOLOPoseTracker`, then instantiate it with your desired parameters like `tracker = YOLOPoseTracker(model_size=\"medium\")`, and then use `tracker.process_image(frame)` or `tracker.process_video(video_filepath)`. Processing image by image will let you access each individual annotated frame with `tracker.annotated_image`, and you can optionally record the data with `tracker.recorder.record()`. Access recorded data with `tracker.recorder.process_tracked_objects()`. The running, recording, and processing are done separately to give control over the amount of processing done at each step in the pipeline. Processing an entire video allows you to save the annotated frames as a video, and optionally saves and returns the data as a numpy array. Each tracker has an associated `ModelInfo` class to access model attributes.\n\nSkellytracker is still under development, so version updates may make breaking changes to the API. Please report any issues and pull requests to the [skellytracker repo](https://github.com/freemocap/skellytracker).\n\n### Extending the API\nTo extend the API, import the `BaseTracker` and `BaseRecorder` abstract base classes from skellytracker. Then create a new tracker and recorder inheriting from the base classes and implement all of the abstract methods.\n\n## Contributing\n\nWe love your input! We want to make contributing to this project as easy and transparent as possible, whether it's:\n\n- Reporting a bug\n- Discussing the current state of the code\n- Submitting a fix\n- Proposing new features\n- Becoming a maintainer\n\nPull requests are the best way to propose changes to the codebase (we\nuse [Github Flow](https://docs.github.com/en/get-started/quickstart/github-flow)). We actively welcome your pull\nrequests:\n\n1. Fork the repo and create your branch from `main`.\n2. Download the development dependencies with `pip install -e '.[dev]'`.\n2. If you've added code that should be tested (including any tracker), add tests.\n3. If you've changed APIs, update the documentation.\n4. Ensure the test suite passes by running `pytest skellytracker/tests`.\n5. Make sure your code lints.\n6. Make that pull request!\n\n",
"bugtrack_url": null,
"license": null,
"summary": "Top-level package for skellytracker",
"version": "2024.9.1019",
"project_urls": {
"Homepage": "https://github.com/freemocap/skellytracker"
},
"split_keywords": [
"camera",
" stream",
" video",
" image",
" opencv",
" skelly",
" freemocap",
" motion capture",
" synchronization",
" computer vision"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "d650f40475a3b41b0ee40482f2e961bdbd171b2f30bdab2afe5dfd2ac5753746",
"md5": "04e835d912c988a7d86ded79c9a79872",
"sha256": "9adc9829533eb8fda07a3270518d78e9f6d1cff058ae6463a6e031f6711eb27e"
},
"downloads": -1,
"filename": "skellytracker-2024.9.1019-py3-none-any.whl",
"has_sig": false,
"md5_digest": "04e835d912c988a7d86ded79c9a79872",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<3.13,>=3.9",
"size": 66801,
"upload_time": "2024-09-05T16:27:02",
"upload_time_iso_8601": "2024-09-05T16:27:02.424728Z",
"url": "https://files.pythonhosted.org/packages/d6/50/f40475a3b41b0ee40482f2e961bdbd171b2f30bdab2afe5dfd2ac5753746/skellytracker-2024.9.1019-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "465c126fa23981ba7b9677158273ec1fcf80f24c37c336e89d09ed31e05abf34",
"md5": "f553c09b2199404c99295446b7a9a0d4",
"sha256": "857b38dc541eefa88cfbcf85e9dacdf00bafe55885c93d6819dee015dbc3ac3c"
},
"downloads": -1,
"filename": "skellytracker-2024.9.1019.tar.gz",
"has_sig": false,
"md5_digest": "f553c09b2199404c99295446b7a9a0d4",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<3.13,>=3.9",
"size": 51000,
"upload_time": "2024-09-05T16:27:03",
"upload_time_iso_8601": "2024-09-05T16:27:03.442853Z",
"url": "https://files.pythonhosted.org/packages/46/5c/126fa23981ba7b9677158273ec1fcf80f24c37c336e89d09ed31e05abf34/skellytracker-2024.9.1019.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-09-05 16:27:03",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "freemocap",
"github_project": "skellytracker",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "skellytracker"
}