What's the difference between the Polygon tool and the Segmentation tool?

When to use the Polygon tool and when to use the Segmentation tool in Ango Hub

Both the Polygon tool and the Segmentation tool let labelers draw closed shapes around objects or areas of interest. The main difference is how much structure the annotation needs.

Use the Polygon tool when each annotation is one closed outline. Use the Segmentation tool when one annotation may need multiple disconnected areas, holes, or merge/subtract operations.

Need
Use Polygon when...
Use Segmentation when...

Shape complexity

The object can be represented by one closed outline.

The object may contain holes or multiple separate regions that should be treated as one object.

Editing workflow

Labelers mainly need to place, move, add, or delete outline points.

Labelers need to merge regions, subtract one region from another, cut holes, erase parts of an annotation, or add to an existing segmentation.

Export structure

You want a simple polygon list of X/Y points.

You want a segmentation object containing zones, where each zone has a region and optional holes.

Mask workflows

You mainly need straightforward vector outlines.

You need Hub's segmentation mask workflow or mask-oriented output.

Benchmarking

You need a tool currently supported by benchmarks.

You do not need benchmark support for this tool.

Polygon

A Polygon annotation is a single closed shape. In export and import JSON, it is represented as a list of X/Y coordinate pairs:

"polygon": [
  [118, 459],
  [299, 327],
  [479, 459]
]

Polygons are a good fit for objects that can be described by one boundary, such as a vehicle outline, a building footprint, or a visible object surface with no holes.

The Polygon tool also supports features such as edge sharing, continuous drawing, and nudging. See the Polygon tool page for the full drawing workflow.

Segmentation

A Segmentation annotation is an instance that can contain one or more zones. Each zone contains one region and can contain holes:

Segmentations are a better fit when one object should remain one annotation but the shape is more complex. For example, use Segmentation if an object has an internal empty area, if one object appears as multiple disconnected visible parts, or if labelers need to use merge, subtract, erase, or auto-merge workflows while labeling.

Both tools can be used with AI-assisted annotation through Auto Suggestion. See the Segmentation tool page for the full drawing workflow.

Changing from Polygon to Segmentation

In the labeling editor, a Polygon annotation can be changed to a Segmentation category. When this happens, Hub converts the polygon outline into a segmentation with one zone and no holes.

The reverse is not equivalent: a Segmentation can contain multiple zones and holes, so it cannot always be represented as one Polygon without losing structure.

Importing and exporting

When importing annotations, use the format that matches the tool in your project ontology:

  • Polygon tools expect a polygon field containing a list of X/Y points.

  • Segmentation tools expect a segmentation field containing zones, region, and holes.

When exporting annotations, segmentation point coordinates are only included if the Segmentation Points field is enabled during export. See the Ango Export Format Tools page for the exact export structure.

Last updated