Skip to content

[KeypointsDataset] - create a new dataset format to load keypoints #1438

Open

Description

@SkalskiP

Description

Supervision can currently load object detection, instance segmentation, and classification datasets. Let's add the ability to handle keypoint datasets. The sv.KeypointDataset should offer the same functionalities as sv.DetectionDataset and sv.ClassificationDataset, including merge, split, __getitem__, __iter__, from_yolo, and as_yolo.

Additional

  • Note: Please share a Google Colab with minimal code to test the new feature. We know it's additional work, but it will speed up the review process. The reviewer must test each change. Setting up a local environment to do this is time-consuming. Please ensure that Google Colab can be accessed without any issues (make it public). Thank you! 🙏🏻

Activity

  1. shaddu commented on Aug 12, 2024

    @shaddu
    Contributor

    Hi @SkalskiP 👋

    I was analyzing the issue and understood that KeypointsDataset will be similar to DetectionDataset, with the difference being the type of annotations.

    classes: List[str],
    images: Union[List[str], Dict[str, np.ndarray]],
    annotations: Dict[str, KeyPoints]
    

    If this is a correct understanding then I will like to work on this issue.

  2. LinasKo commented on Aug 13, 2024

    @LinasKo
    Contributor

    Let's only implement the new, lazy-loaded, non-deprecated API, with images: List[str]. This will save work in the future.

  3. LinasKo commented on Aug 13, 2024

    @LinasKo
    Contributor

    @shaddu, I also made this template, which should help with starting your colab: Colab Template.
    Feel free to use as much or as little of it as you wish 😉

  4. shaddu commented on Aug 13, 2024

    @shaddu
    Contributor

    Hi @LinasKo 👋

    I also noticed the deprecated warning in the Datasets classes, and the clarification around images: List[str] is helpful.

    Thank you for sharing the Colab template 😎 . It will be helpful, and I will suggest adding some similar Colab templates to the contribution guide.

  5. miteshashar commented on Feb 21, 2025

    @miteshashar

    @shaddu Did you happen to take this up? I was thinking of reviewing this to evaluate whether it is something I can take up to attempt.

  6. SkalskiP commented on Feb 21, 2025

    @SkalskiP
    CollaboratorAuthor

    Hi @miteshashar 👋🏻 if you are up for the task I'm happy to assign it to you ;)

  7. shaddu commented on Feb 22, 2025

    @shaddu
    Contributor

    Hi @SkalskiP and @miteshashar 👋🏻

    @SkalskiP There is a PR pending for review for this issue: #1477

  8. added a commit that references this issue on Oct 17, 2026
    a48e6e2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions