Skip to content

Commit

Permalink
Fix an issue with occluded field
Browse files Browse the repository at this point in the history
  • Loading branch information
yasakova-anastasia committed Feb 14, 2023
1 parent 5f68cfa commit 7b3ff12
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cvat/apps/dataset_manager/formats/cvat.py
Original file line number Diff line number Diff line change
Expand Up @@ -742,6 +742,11 @@ def dump_labeled_shapes(shapes, is_skeleton=False):
("outside", str(int(shape.outside)))
]))

if shape.type != 'skeleton':
dump_data.update(OrderedDict([
("occluded", str(int(shape.occluded)))
]))

if shape.type == "rectangle":
dump_data.update(OrderedDict([
("xtl", "{:.2f}".format(shape.points[0])),
Expand Down Expand Up @@ -795,7 +800,6 @@ def dump_labeled_shapes(shapes, is_skeleton=False):
]))
elif shape.type != 'skeleton':
dump_data.update(OrderedDict([
("occluded", str(int(shape.occluded))),
("points", ';'.join((
','.join((
"{:.2f}".format(x),
Expand Down

0 comments on commit 7b3ff12

Please sign in to comment.