Skip to content

Commit

Permalink
update geometry_to_task_type dict
Browse files Browse the repository at this point in the history
  • Loading branch information
almazgimaev committed Aug 30, 2024
1 parent cb4e57a commit aed21f1
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/functions.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import src.globals as g
import supervisely as sly
from supervisely.nn import TaskType
from supervisely.nn.inference import Session

geometry_to_task_type = {
"object detection": [sly.Rectangle],
"instance segmentation": [sly.Bitmap, sly.Polygon, sly.AlphaMask],
# "semantic segmentation": [sly.Bitmap, sly.Polygon, sly.AlphaMask],
TaskType.OBJECT_DETECTION: [sly.Rectangle],
TaskType.INSTANCE_SEGMENTATION: [sly.Bitmap, sly.Polygon],
}


Expand Down Expand Up @@ -46,6 +46,7 @@ def get_classes():

return (matched_proj_cls, matched_model_cls), (not_matched_proj_cls, not_matched_model_cls)


def get_matched_class_names():
(cls_collection, _), _ = get_classes()
return [obj_cls.name for obj_cls in cls_collection]
return [obj_cls.name for obj_cls in cls_collection]

0 comments on commit aed21f1

Please sign in to comment.