Skip to content

Convert supervisely output to COCO keypoint data format

License

Notifications You must be signed in to change notification settings

SeoK106/supervisely2coco

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 

Repository files navigation

Supervisely to COCO

Convert supervisely output to COCO keypoint data format (Only convert keypoint outputs)

HowToUse

1. Set the Class

class_setting

  • setting the title to person
  • setting shape to keypoints
  • drawing the keypoints templete or uploading a keypoint image
    • set the node name : {"Head","neck","right shoulder", ...}
    • set the edge name : {"1,2","2,3",...} --> the nodes that the edge is connected to : "from,to"
            cf.I start the node with 1(not 0), but it doesn't matter what it start with. It's up to the developer.

2. Draw keypoints on the image

skeleton_drawing

3. Download annotation and meta file(.json) from supervisely

4. Execute the code

 #Anconda prompt
 
 > python supervisely2coco.py meta_file_path annotation_dir_path save_dir_path
 
 * meta_file_path: ~/meta.json
 * annotation_dir_path: ~/ann
 * save_dir_path: ~/, default = ./result.json

Output

result

cf. On the left is 'sample_1_person.png', and on the right is 'smaple_2_person.png'.

input_images


Souce code Referenced: https://gist.github.com/caiofcm/0b93b0084669a1287633d9ebf32f3833

About

Convert supervisely output to COCO keypoint data format

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Languages