Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion fastlabel/converters.py
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,10 @@ def __to_area(annotation_type: str, points: list) -> float:
def __calc_area(annotation_type: str, points: list) -> float:
if not points:
return 0
if annotation_type == AnnotationType.bbox.value:
if annotation_type in [
AnnotationType.bbox.value,
AnnotationType.pose_estimation.value,
]:
width = points[0] - points[2]
height = points[1] - points[3]
return width * height
Expand Down