diff --git a/anylabeling/views/labeling/label_converter.py b/anylabeling/views/labeling/label_converter.py index f70e65b..c7b9fd8 100644 --- a/anylabeling/views/labeling/label_converter.py +++ b/anylabeling/views/labeling/label_converter.py @@ -972,6 +972,13 @@ def custom_to_yolo( # noqa: C901 elif mode == "pose": if shape_type not in ["rectangle", "point"]: continue + if shape["group_id"] is None: + logger.error( + f"group_id is None for {shape} in {input_file}." + ) + raise ValueError( + f"group_id is None for {shape} in {input_file}." + ) label = shape["label"] points = shape["points"] group_id = int(shape["group_id"])