2D Polygon

Overview: The Polygon tool is used to create geometric annotations by drawing lines between points.

Steps to Draw a Polygon

  1. By pressing the shortcut key ‘Y’, you can enable the 2D-polygon mode.

  2. Select a category from the drop-down box.

3. Draw a polygon, keeping points on the image with a left mouse click. You can label the same polygon ID by holding an “Alt” key for the first polygon point. Then continue the polygon labelling for the object with the same ID.

4. You can select the label by double-clicking on the label with a left mouse click. Then you can edit the 2D-Polygon, by dragging the highlighted points of the line with a left mouse click and also you can delete the selected highlighted point by pressing the “Delete” key.

5. You can save the Polygon label by pressing the “Esc” key twice.

Polygon (Foreground/Background): Knowing how to use the foreground and background can come in handy in data labelling for polygons. If there is an object at the back of another object, that is when this feature comes into play. Draw a polygon as Foreground:

1. Selecting a foreground option from the image editor page

2. For example, if you want to label a “Car” in the below image without interrupting the “Building” polygon, you want to select a Foreground option before saving the “Car” label as the Building is the Background and car is the foreground object.

3. If you use Background instead of Foreground option, it will not be cut by the Background polygon label(Building).

Draw a polygon as Background:

  1. Selecting a Background option from the image editor page.

2. For example, if you want to label a building in the below image without interrupting the car polygon, you want to select a background option before saving the building label because the Building is the Background and car is the foreground object.

3. When you label a background object with a background option, it will get polygon accurately to the object without disturbing the foreground label (Car).

4. If you use the foreground instead of the background option, it will interrupt the foreground polygon label (Car).