Skip to content

Move Polygon

Overview ​

The Move Polygon node moves a polygon by adding horizontal and vertical offsets to every point. All coordinates are normalized (0 – 1), and each moved point is clipped so it never leaves the image boundaries.

Use Move Polygon when:

  • You need to shift a detected region based on a dynamic offset (e.g. a calculated distance or sensor value).

💡 Tip

Negative offsets move the polygon left (horizontal) or up (vertical). The node clamps each point individually, so a polygon near the edge may change shape rather than disappear.

Clamping behavior when a polygon is moved beyond the image boundary
A polygon near the bottom-right corner is shifted by horizontal = 0.20 and vertical = 0.30. The red dashed outline shows where it would land without clipping — partially outside the image. The green shape is the actual result after each point is clipped to the 0 – 1 range.

Inputs ​

NameTypeDescription
polygonpolygonThe polygon to move.
horizontalnumberOffset along the x-axis (normalized). Positive moves right, negative moves left.
verticalnumberOffset along the y-axis (normalized). Positive moves down, negative moves up.

âš ī¸ Warning

All three inputs are required.

Outputs ​

NameTypeDescription
moved_polygonpolygonThe translated polygon, with every point clipped to 0 – 1.

â„šī¸ Note

Point and polygon probability values are preserved through the polygon move.

Parameters ​

This node has no configurable parameters.

Example ​

Shifting a detection region ​

A model detects an object and outputs a bounding polygon. A downstream calculation determines that the region of interest is offset 0.20 to the right and 0.25 downward from the detection. The Move Polygon node applies these offsets to reposition the polygon.

Move Polygon node shifting a polygon by horizontal and vertical offsets
The original polygon (dashed grey, centered at 0.35, 0.35) is shifted right by 0.20 and down by 0.25. The green rectangle shows the result, now centered at (0.55, 0.60).

Reference: