Skip to content

Commit a25b066

Browse files
author
Val Brodsky
committed
Remove NDSegments
1 parent cf25f3a commit a25b066

File tree

2 files changed

+1
-13
lines changed

2 files changed

+1
-13
lines changed

libs/labelbox/src/labelbox/data/serialization/ndjson/label.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@
3838
from .objects import (
3939
NDObject,
4040
NDObjectType,
41-
NDSegments,
4241
NDVideoMasks,
4342
)
4443
from .relationship import NDRelationship
@@ -49,7 +48,6 @@
4948
NDPromptClassificationType,
5049
NDConfusionMatrixMetric,
5150
NDScalarMetric,
52-
NDSegments,
5351
NDVideoMasks,
5452
NDRelationship,
5553
NDPromptText,
@@ -133,15 +131,7 @@ def _generate_annotations(
133131
# deserialized objects in the _AnnotationGroupTuple
134132
# object *if* the object can be used in a relationship
135133
for uuid, ndjson_annotation in group.ndjson_annotations.items():
136-
if isinstance(ndjson_annotation, NDSegments):
137-
annotations.extend(
138-
NDSegments.to_common(
139-
ndjson_annotation,
140-
ndjson_annotation.name,
141-
ndjson_annotation.schema_id,
142-
)
143-
)
144-
elif isinstance(ndjson_annotation, NDVideoMasks):
134+
if isinstance(ndjson_annotation, NDVideoMasks):
145135
annotations.append(
146136
NDVideoMasks.to_common(ndjson_annotation)
147137
)

libs/labelbox/src/labelbox/data/serialization/ndjson/objects.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -724,8 +724,6 @@ def lookup_object(
724724
) -> "NDObjectType":
725725
if isinstance(annotation, VideoMaskAnnotation):
726726
result = NDVideoMasks
727-
elif isinstance(annotation, list):
728-
result = NDSegments
729727
else:
730728
result = {
731729
Line: NDLine,

0 commit comments

Comments
 (0)