Skip to content

Commit e6dd4f3

Browse files
Merge pull request #187 from fastlabel/fix-type-hint
fix dict type hint
2 parents 6d45486 + f9b002f commit e6dd4f3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

fastlabel/converters.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
from operator import itemgetter
99
from pathlib import Path
1010
from tempfile import NamedTemporaryFile
11-
from typing import List, Optional
11+
from typing import List, Dict, Optional
1212

1313
import cv2
1414
import geojson
@@ -269,7 +269,7 @@ def __get_coco_annotation(
269269
category_id: int,
270270
image_id: str,
271271
annotation_type: str,
272-
annotation_attributes: dict[str, AttributeValue],
272+
annotation_attributes: Dict[str, AttributeValue],
273273
) -> dict:
274274
annotation = {}
275275
annotation["num_keypoints"] = len(keypoints) if keypoints else 0
@@ -1128,7 +1128,7 @@ def _get_annotation_points_for_image_annotation(annotation: dict):
11281128
return annotation.get("points")
11291129

11301130

1131-
def _get_coco_annotation_attributes(annotation: dict) -> dict[str, AttributeValue]:
1131+
def _get_coco_annotation_attributes(annotation: dict) -> Dict[str, AttributeValue]:
11321132
coco_attributes = {}
11331133
attributes = annotation.get("attributes")
11341134
if not attributes:

0 commit comments

Comments
 (0)