Skip to content

Draft PointTracker interface with per-tool uv envs - #86

Draft
niksirbi wants to merge 2 commits into
mainfrom
point-tracker-api-draft
Draft

niksirbi wants to merge 2 commits into
mainfrom
point-tracker-api-draft

Conversation

@niksirbi

@niksirbi niksirbi commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

Draft skeleton for running point trackers from poseinterface, with each tracker in its own isolated uv env. Signatures and types only; nothing is implemented yet.

This was the result of an initial brainstorming session involving myself, @lochhh, @sfmig and @claude.

What's here

  • poseinterface/trackers.py: PointTracker ABC (no torch). Subclasses implement track(video, queries) -> (tracks, visibility); the shared run() reads PoseMark start labels and writes predictions as PoseMark clip labels.
  • envs/cotracker3/: standalone uv project (path dependency on poseinterface, not a workspace member, so each tool keeps its own lockfile) with a CoTracker3 skeleton and CLI.
  • Tests: base class in tests/test_unit/test_trackers.py (main env); tool tests in envs/cotracker3/tests/, run via uv run --project envs/cotracker3 pytest envs/cotracker3/tests.
  • Root pytest restricted to tests/; envs/ excluded from the sdist.

See HANDOFF.md for design decisions, next steps, and maintainability notes (to be removed before merge).

🤖 Generated with Claude Code

niksirbi and others added 2 commits October 15, 2026 11:46
- PointTracker ABC in poseinterface/trackers.py (no torch dependency)
- CoTracker3 skeleton in envs/cotracker3 as a standalone uv project
  (path dependency on poseinterface, not a workspace member)
- Test stubs for the base class (main env) and the tool (its own env)
- Restrict root pytest to tests/, exclude envs/ from sdist
- HANDOFF.md with design notes and next steps

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codecov

codecov Bot commented Oct 15, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 75.00000% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 93.45%. Comparing base (0df45e1) to head (26ad153).

Files with missing lines Patch % Lines
poseinterface/trackers.py 75.00% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #86      +/-   ##
==========================================
- Coverage   93.99%   93.45%   -0.54%     
==========================================
  Files           5        6       +1     
  Lines         416      428      +12     
==========================================
+ Hits          391      400       +9     
- Misses         25       28       +3     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@lochhh

lochhh commented Oct 15, 2026

Copy link
Copy Markdown
Member

Alternative design to #85

Each tool runs in its own isolated uv environment, e.g.

poseinterface/            # main env: import, export, convert, compare
envs/                     # tool-specific envs
  dlc/  pyproject.toml  uv.lock  train.py  infer.py
  lp/   pyproject.toml  uv.lock  train.py  infer.py
  <tool>/ ...
  • One env per tool: no cross-tool dependency conflicts, and adding a tool doesn't touch the others.
  • Each tool has thin wrapper scripts (train.py, infer.py) that call the tool's own API/CLI. Wrappers share a core set of arguments to allow automating looping over tools.

Workflow

  1. Import labels to PoseMark (main env): Convert existing labels (DLC, LP, SLEAP, ...) to PoseMark with annotations_to_posemark and related functions, define the Train/Test splits.
  2. Export Train split to tool formats (main env): Convert the PoseMark Train split into each tool's training layout, written to scratch directories. (exporters do not exist yet)
python -m poseinterface.export --tool dlc --split Train/<Project> --out work/dlc
  1. Train and infer (each tool using its own API/CLI inside its env)
uv run --project envs/<tool> python envs/<tool>/train.py --data work/<tool> --out models/<tool>
uv run --project envs/<tool> python envs/<tool>/infer.py --model models/<tool> --videos Test/<Project>/... --out preds/<tool>
  1. Convert predictions back to PoseMark with predictions_to_posemark and compare (main env)

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants