From 63241ea9d8f5d9e942556502e1978f42d03b35ab Mon Sep 17 00:00:00 2001 From: Takahiro Tamenishi Date: Mon, 4 Jul 2022 13:10:44 +0900 Subject: [PATCH] fix coco supercategory --- README.md | 2 +- fastlabel/converters.py | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 53cb245..7c60fc8 100644 --- a/README.md +++ b/README.md @@ -66,7 +66,7 @@ Supported following project types: - Image - Keypoint - Image - Line - Image - Segmentation -- Image - Pose Estimation(not support Create Task) +- Image - Pose Estimation - Image - All #### Create Task diff --git a/fastlabel/converters.py b/fastlabel/converters.py index b814abd..09a4ab9 100644 --- a/fastlabel/converters.py +++ b/fastlabel/converters.py @@ -1,5 +1,4 @@ from concurrent.futures import ThreadPoolExecutor -from curses import keyname from datetime import datetime from decimal import Decimal from typing import List @@ -667,7 +666,7 @@ def execute_coco_to_fastlabel(coco: dict ,annotation_type:str) -> dict: coco_categories = {} coco_categories_keypoints={} for c in coco["categories"]: - coco_categories[c["id"]] = c["name"] + coco_categories[c["id"]] = c["supercategory"] coco_categories_keypoints[c["id"]] = c["keypoints"] coco_annotations = coco["annotations"]