Skip to content

cannot add new labels to a labelled dataset #2723

Closed

Description

@ashwin-miriyala

Is there an existing issue for this?

  • I have searched the existing issues

Bug description

I have an already labelled dataset. I wanted to add additional bodyparts, so i appended these bodyparts to the config.yaml file under the bodyparts section. However, when I run deeplabcut.label_frames(config_path), my new bodyparts are not showing in the list.

Checking the config.yaml file through the gui shows that the bodyparts are indeed listed in the config file, but they're not showing up while labelling.

Operating System

Ubuntu 20.04

DeepLabCut version

dlc version 3.0.0rc3

DeepLabCut mode

single animal

Device type

gpu

Steps To Reproduce

append bodyparts to config file and run label_frames

Relevant log output

No response

Anything else?

No response

Code of Conduct

Activity

  1. JulianAlvarezdeGiorgi commented on Aug 30, 2024

    @JulianAlvarezdeGiorgi
    Contributor

    Hello, I had the same need while ago.

    I had originally created a dataset with 14 body parts. Later I decided to make another project, where I kept the body parts of the previous project (these 14) but added new body parts. As I already had many frames with the 14 labels, I wanted to be able to transfer them to the new project, and only have to label the new body parts. For this, I created a new project, with all the body parts I was interested in (old and new), I kept the labeled-data folder of the old project, and I created a function called adapt_labeled_data_to_new_project to add the new body parts to the .csv and .h5 files, so I could label the new bodyparts from the GUI.

    Please review the function implemented in deeplabcut/utils/conversioncode.py within the main repository. To use it, create a new project with all the desired body parts, copy and paste the labeled-data folder, and then run the function. It's crucial to keep the same names for the body parts that you have already labeled.

  2. n-poulsen commented on Sep 2, 2024

    @n-poulsen
    Contributor

    Hi @ashwin-miriyala - to be able to label the new keypoint, you need to drag-and-drop your project's config.yaml file (with the added keypoint(s)) into the GUI. It will ask you "Do you want to display the new keypoints only", to which you should reply "No".

    This is important - answering "No" means you want to keep your existing annotated data, and simply add new bodyparts.

    You only need to do this step the first time you open the folder for a video (when the keypoints in the GUI don't match the ones in your project's config.yaml file).

    Short example:

    add_new_keypoint.mov
  3. added
    GUI
    on Sep 2, 2024
  4. ashwin-miriyala commented on Sep 12, 2024

    @ashwin-miriyala
    Author
  5. sdhers commented on Feb 4, 2025

    @sdhers

    Hello! Should I follow the same strategy to remove keypoints that I dont want to use for training my new model?

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

Metadata

Metadata

Assignees

Labels

GUI

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions