Skip to content

feat : added support for keypoints dataset - #1477

Closed
shaddu wants to merge 3 commits into
roboflow:developfrom
shaddu:feat/KeypointsDataset
Closed

shaddu wants to merge 3 commits into
roboflow:developfrom
shaddu:feat/KeypointsDataset

Conversation

@shaddu

@shaddu shaddu commented Aug 24, 2024 •

Copy link
Copy Markdown
Contributor

Description

Added support for keypoints dataset

List any dependencies that are required for this change.

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)

How has this change been tested, please provide a testcase or example of how you tested the change?

Keypointdataset Colab

Any specific deployment considerations

For example, documentation changes, usability, usage/costs, secrets, etc.

Docs

  • Docs updated? What were the changes:

@onuralpszr

Copy link
Copy Markdown
Contributor

First suggestion I would say we should split the code to 2 files detections and keypoints and maybe also add base too because file getting really bigger and mix both detections and keypoints not the way I would do it. I would like to hear from others as well.

cc @LinasKo @SkalskiP

@LinasKo

LinasKo commented Aug 26, 2024

Copy link
Copy Markdown
Contributor

@onuralpszr, you're very right that it needs a split. It's a massive file.

Let's do that right after the next release, but merge this PR as is.
(after I review it)

@shaddu, fantastic work, as always.

I have one request early request: please add types to each of the split methods, for both classification, detection and keypoint dataset.

    def split(
        self,
        split_ratio: float = 0.8,
        random_state: Optional[int] = None,
        shuffle: bool = True,

Another PR will introduce this change soon, so adding it here will pre-empt the conflict.

@onuralpszr onuralpszr added the API:datasets Dataset API label Aug 27, 2024
@shaddu

shaddu commented Aug 27, 2024

Copy link
Copy Markdown
Contributor Author

Hi @onuralpszr and @LinasKo ,

I also feel that files should be split based on keypoints and detection types as there could be confusion while working with annotations.

@LinasKo I have added type to the split method for keypoint dataset and can see you have already added for the rest.

Thank you for reviewing the PR ;)

@miteshashar

miteshashar commented Feb 23, 2025 •

Copy link
Copy Markdown

Thanks for the update on #1438, @shaddu :)

@SkalskiP @shaddu @LinasKo I'd been evaluating the task and also checked the PR code.

Given their relevance & existing support in the Keypoint class, I feel it would be helpful to also add from_coco, as_coco, from_mediapipe and as_mediapipe methods.

@Borda

Borda commented Sep 9, 2026

Copy link
Copy Markdown
Member

@shaddu, I think this was implemented by @SkalskiP in some parallel path…?

@Borda

Borda commented Sep 17, 2026

Copy link
Copy Markdown
Member

Thank you, @shaddu, for putting this together. The goal of making pose/keypoint datasets easier to load and export is still reasonable, and I appreciate the work that went into the initial implementation.

However, I’m closing this PR because it has drifted too far from the current codebase to review or merge safely. The branch conflicts with develop, uses package paths that no longer exist, and the proposed implementation predates the current KeyPoints API and dataset conventions.

More importantly, YOLO pose data needs a fresh design, not a conflict-resolution pass. A pose label includes the object class, bounding box, keypoints, and, where applicable, per-keypoint visibility. The current patch does not preserve that full record or the pose metadata needed in the dataset YAML, so it cannot reliably round-trip current YOLO pose datasets.

If there is still demand for this capability, please open a new PR from the current develop branch. It should begin with a short proposal for the container/API shape, then include round-trip tests for 2-D and visibility-based keypoints, multiple instances, empty annotations, bounding-box behavior, and the required pose YAML fields such as kpt_shape and flip_idx.

Keeping this PR as historical context is useful; a clean, current implementation will be much easier to review and maintain.

@shaddu

shaddu commented Sep 18, 2026

Copy link
Copy Markdown
Contributor Author

@Borda Thanks for the update, indeed the PR was quite old by now and YOLO pose data needs a fresh design.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants