Skip to content

Crop resize strategies (fill, center_crop) and geometry truncation semantics #786

Description

@JArmandoAnaya

The pre-processing epic (#785) ships resize as stretch and letterbox — the two strategies under which every annotation stays inside the frame, so the geometry transform is exact. A crop strategy (fill, center_crop) removes pixels, and geometry crossing the crop boundary must then be truncated, dropped, or refused.

The domain's standing rule is to refuse out-of-bounds geometry rather than clamp it, so a crop needs a ratified truncation rule before it can exist:

  • What happens to a bbox partly outside the crop — truncated to the boundary, dropped past some visibility threshold, or refused.
  • What happens to a polygon that loses vertices at the boundary, which can split it into disjoint regions.
  • What happens to a polyline, whose point order is meaning-bearing and whose truncation can break format-boundary ordering rules.
  • Whether truncation lives in the kernel transform (one rule for every driver) or per step.

Deferred until those semantics are decided. Not started; do not close this issue until a decision comment lands here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    deferred-needs-inputBlocked on a decision that belongs to the founder

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions