Files
kinect/tracker-native/README.md
T

3.2 KiB

kinect-tracker (native, zero-Python)

Native replacement for the Python/MediaPipe tracker/. See docs/native-tracker.md for the architecture. One kinect-tracker.exe: camera + resolution picker, live preview, native pose + segmentation, and the shared-memory publish the Kinect10.dll shim reads.

No binaries are committed. Fetch the models and ONNX Runtime (no Python needed):

scripts/fetch_models.sh   # pose models: prebuilt .onnx + .tflite, checksum-verified
scripts/fetch_ort.sh      # prebuilt ONNX Runtime 1.20.1 (linux + win x64)
./build.sh                # headless Linux build (currently the ORT smoke test)

After fetching, verify every artifact against the pinned manifest:

sha256sum -c MANIFEST.sha256   # run from this directory (tracker-native/)

Models & ONNX Runtime acquisition

The player path is Python-free: fetch_models.sh downloads a prebuilt pose_landmarks_detector.onnx and extracts the .tflite files from the MediaPipe bundle with unzip; it never runs tf2onnx. Every download is pinned by SHA256 (MANIFEST.sha256 and the *_SHA256 constants in the scripts) and any mismatch aborts with a non-zero exit.

Artifact Version / source License
pose_landmarks_detector.onnx (runtime-required) project mirror asset, tf2onnx export of the bundle's landmark .tflite Apache-2.0 (MediaPipe BlazePose)
pose_landmarks_detector.tflite, pose_detector.tflite MediaPipe pose_landmarker_full bundle, Google model storage (.../float16/1/pose_landmarker_full.task) Apache-2.0 (MediaPipe BlazePose)
onnxruntime.dll / .lib, libonnxruntime.so ONNX Runtime 1.20.1, project mirror cga-management/third-party-mirror (tag onnxruntime-1.20.1) MIT

Upstream microsoft/onnxruntime GitHub releases were removed on 2026-11-17, so ONNX Runtime is pinned to the project mirror's unchanged 1.20.1 assets.

The runtime loads only pose_landmarks_detector.onnx (see src/win_main.cpp kModelName); the .tflite files are kept for development and reference. The ROI detector model is not converted (tf2onnx cannot convert it), so the tracker bootstraps the ROI instead.

Publishing the prebuilt .onnx: fetch_models.sh fetches the landmark .onnx from MODEL_ONNX_URL (default: the project mirror). Publish the file whose SHA256 is in MANIFEST.sha256 as that mirror asset (the same way the ORT assets are mirrored), or point MODEL_ONNX_URL at a local copy (file:///path/...). Regenerating that .onnx from the .tflite is a DEV-only step via scripts/setup_models.sh (needs Python + tf2onnx).

Status

  • Inference foundation proven: the real MediaPipe BlazePose landmark weights (pose_landmarks_detector, 33 landmarks + world + 256x256 mask) convert to ONNX faithfully (mask <=1.2% in probability space vs TFLite) and run bit-identically under the ONNX Runtime C++ API (build/ort_smoke vs scripts/ort_smoke_ref.py).
  • Next: BlazePose pre/post (ROI, letterbox, landmark/mask un-transform) validated against the MediaPipe reference; the detector model for ROI acquisition (tf2onnx can't convert it yet); native shm writer; Media Foundation capture; the Dear ImGui GUI; MinGW/MSVC Windows build.