Closed didnmj closed 2 years ago
KeyError Traceback (most recent call last) in () 84 85 # Create images and annotations sections ---> 86 coco_format["images"], coco_format["annotations"], annotation_cnt = images_annotations_info(mask_path) 87 88 with open("output/{}.json".format(keyword),"w") as outfile:
in images_annotations_info(maskpath) 47 sub_masks = create_sub_masks(mask_image_open, w, h) 48 for color, sub_mask in sub_masks.items(): ---> 49 category_id = category_colors[color] 50 51 # "annotations" info
KeyError: '(130, 130, 130)'
Hi @ikjoooon, You can define this RGB value in category_colors in the main notebook.
category_colors
KeyError Traceback (most recent call last) in ()
84
85 # Create images and annotations sections
---> 86 coco_format["images"], coco_format["annotations"], annotation_cnt = images_annotations_info(mask_path)
87
88 with open("output/{}.json".format(keyword),"w") as outfile:
KeyError: '(130, 130, 130)'