You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Refactor result handling of DetectionResult and InstanceSegResult (#239)
* Refactor detection handling to use DetectionResult and update related documentation
* Refactor DetectionResult class and YOLO
* Fix detection bounding box types
* Refactor segmentation handling to use RotatedSegmentationResult and update related tests
* Remove unused 'strict' parameter from detection and segmentation result classes and update label handling in tilers
* Remove unused 'strict' parameter from zip function in instance segmentation models and tilers
* update docs
* move parsers back to ssd
Copy file name to clipboardExpand all lines: docs/source/python/models/detection_model.md
+13-13Lines changed: 13 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,15 +12,12 @@ A single input image of shape (H, W, 3) where H and W are the height and width o
12
12
13
13
### Outputs
14
14
15
-
Detection model outputs a list of detection objects (i.e `list[Detection]`) wrapped in `DetectionResult`, each object containing the following attributes:
15
+
Detection model outputs a `DetectionResult` objects containing the following attributes:
16
16
17
-
-`score` (float) - Confidence score of the object.
18
-
-`id` (int) - Class label of the object.
19
-
-`str_label` (str) - String label of the object.
20
-
-`xmin` (int) - X-coordinate of the top-left corner of the bounding box.
21
-
-`ymin` (int) - Y-coordinate of the top-left corner of the bounding box.
22
-
-`xmax` (int) - X-coordinate of the bottom-right corner of the bounding box.
23
-
-`ymax` (int) - Y-coordinate of the bottom-right corner of the bounding box.
17
+
-`boxes` (np.ndarray) - Bounding boxes of the detected objects. Each in format of x1, y1, x2 y2.
18
+
-`scores` (np.ndarray) - Confidence scores of the detected objects.
19
+
-`labels` (np.ndarray) - Class labels of the detected objects.
20
+
-`label_names` (list[str]) - List of class names of the detected objects.
24
21
25
22
## Example
26
23
@@ -34,11 +31,14 @@ model = SSD.create_model("model.xml")
Copy file name to clipboardExpand all lines: docs/source/python/models/instance_segmentation.md
+17-14Lines changed: 17 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,16 +12,13 @@ A single input image of shape (H, W, 3) where H and W are the height and width o
12
12
13
13
### Outputs
14
14
15
-
Instance segmentation model outputs a list of segmented objects (i.e `list[SegmentedObject]`)wrapped in `InstanceSegmentationResult.segmentedObjects`, each containing the following attributes:
15
+
Instance segmentation model outputs a `InstanceSegmentationResult` object containing the following attributes:
16
16
17
-
-`mask` (numpy.ndarray) - A binary mask of the object.
18
-
-`score` (float) - Confidence score of the object.
19
-
-`id` (int) - Class label of the object.
20
-
-`str_label` (str) - String label of the object.
21
-
-`xmin` (int) - X-coordinate of the top-left corner of the bounding box.
22
-
-`ymin` (int) - Y-coordinate of the top-left corner of the bounding box.
23
-
-`xmax` (int) - X-coordinate of the bottom-right corner of the bounding box.
24
-
-`ymax` (int) - Y-coordinate of the bottom-right corner of the bounding box.
17
+
-`boxes` (np.ndarray) - Bounding boxes of the detected objects. Each in format of x1, y1, x2 y2.
18
+
-`scores` (np.ndarray) - Confidence scores of the detected objects.
19
+
-`masks` (np.ndarray) - Segmentation masks of the detected objects.
20
+
-`labels` (np.ndarray) - Class labels of the detected objects.
21
+
-`label_names` (list[str]) - List of class names of the detected objects.
25
22
26
23
## Example
27
24
@@ -36,11 +33,17 @@ model = MaskRCNNModel.create_model("model.xml")
0 commit comments