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
Copy file name to clipboardExpand all lines: docs/source/guide/export.md
+142-2Lines changed: 142 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -121,7 +121,144 @@ Export your brush mask labels as NumPy 2d arrays and PNG images. Each label outp
121
121
122
122
### COCO
123
123
124
-
A popular machine learning format used by the [COCO dataset](http://cocodataset.org/#home) for object detection and image segmentation tasks. Supports bounding box and polygon image labeling projects that use the `BrushLabels`, `RectangleLabels`, or `PolygonLabels` tags.
124
+
A popular machine learning format used by the [COCO dataset](http://cocodataset.org/#home) for object detection and image segmentation tasks. Supports bounding box and polygon image labeling projects that use the `BrushLabels`, `RectangleLabels`, `KeyPointLabels` (see note below), or `PolygonLabels` tags.
If using `KeyPointLabels`, you will need to add the following to your labeling config:
130
+
131
+
* At least one `<RectangleLabels>` option. You will use this as a parent bounding box for the keypoints.
132
+
* Add a `model_index` to every `<Label>` inside your `<KeyPointLabels>` tag. The `model_index` value defines the order of the keypoint coordinates in the output array for YOLO.
133
+
134
+
For example:
135
+
136
+
```xml
137
+
<View>
138
+
<Imagename="image"value="$image"/>
139
+
140
+
<KeyPointLabelsname="kp"toName="image">
141
+
<Labelvalue="nose"model_index="0"/>
142
+
<Labelvalue="eye"model_index="1"/>
143
+
<Labelvalue="tail"model_index="2"/>
144
+
</KeyPointLabels>
145
+
146
+
<RectangleLabelsname="bbox"toName="image">
147
+
<Labelvalue="animal"/>
148
+
</RectangleLabels>
149
+
</View>
150
+
151
+
```
152
+
153
+
After annotating, you must drag-and-drop each keypoint region under its corresponding rectangle region in the **Regions** panel.
154
+
155
+
This establishes a parent–child hierarchy (via parentID), which is necessary for export. See the export examples below.
156
+
157
+

@@ -189,7 +326,10 @@ Results are stored in a tab-separated tabular file with column names specified b
189
326
190
327
### YOLO
191
328
192
-
Export object detection annotations in the YOLOv3 and YOLOv4 format. Supports object detection labeling projects that use the `RectangleLabels` tag.
329
+
Export object detection annotations in the YOLOv3 and YOLOv4 format. Supports object detection labeling projects that use the `RectangleLabels` and `KeyPointLabels` tags.
330
+
331
+
!!! note
332
+
If using KeyPointLabels, see the note under [COCO](#COCO).
0 commit comments