feat: keypoints/pose implementation#521
feat: keypoints/pose implementation#521michaelmohamed wants to merge 14 commits intoroboflow:developfrom
Conversation
|
Michael Mohamed seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
|
Has this been approved yet? I tried to use it by importing the package but it didn't work. |
|
@michaelmohamed can you provide benchmark results on COCO pose so we can compare this to other models / implementations? |
I've been testing and using by installing right from the fork: |
@isaacrob Thanks for the question. Unfortunately, I don’t currently have the resources to run a full benchmark on COCO Pose. If someone in the community is able to assist with this, perhaps creating a pretrained model, that would be greatly appreciated. I've been testing this fork with success, with full training, on non-public datasets, with success. Thanks in advance for any help or pointers others may be able to provide. |
60b16c1 to
523f9df
Compare
Description
For Technical Implementation Details: See docs.
This PR adds optional keypoint/pose estimation support to RF-DETR, following YOLOv11's approach for pose estimation. The implementation outputs (x, y, visibility) triplets per keypoint per detection, with full support for COCO-style 17-keypoint annotations.
Key features:
Related issues:
Addresses community requests for pose estimation support in RF-DETR.
Type of change
How has this change been tested, please provide a testcase or example of how you tested the change?
29 unit tests covering both training and inference pipelines:
29 passed in 2.28s
Test coverage includes:
Any specific deployment considerations
Docs
Added docs/learn/run/pose.md - Complete usage guide for pose estimation
Added docs/reference/pose.md - API reference for RFDETRPose
Updated docs/learn/train/index.md - Added pose tabs to all training examples
Updated mkdocs.yaml - Added navigation entries for pose documentation
Files Changed
Usage / Import Example
Training
Inference
Fix: Category ID Mapping for COCO Datasets
Problem
#330
#349
#413
When training on Roboflow or custom COCO datasets where category_id starts at 1 (or has gaps), the model would crash with a CUDA index out of bounds error. This happened because:
Additionally, COCO evaluation was returning near-zero mAP scores because predictions used 0-indexed labels but COCO evaluation expected original category IDs.
Solution
Added automatic bidirectional category ID mapping:
Training (coco.py):
Evaluation (coco_eval.py):
How It Works
Backwards Compatibility
Files Changed