Release Notes β€” 2.0.16

πŸ“ Oriented Bounding Boxes (OBB): Pads & Crops

What’s new in 2.0.16

AlbumentationsX extends oriented bounding box (OBB) support to padding and cropping transforms.

This release builds on the OBB foundation introduced in 2.0.15 and closes an important gap in practical detection pipelines that rely on crop β†’ pad β†’ rotate β†’ scale workflows.


Supported transforms (OBB)

As of 2.0.16, OBBs are supported in the following transform families:

βœ… Supported

  • Flips
  • Rotations
  • Scaling
  • Padding
    • Pad
    • PadIfNeeded
    • related pad variants
  • Cropping
    • Crop
    • RandomCrop
    • CenterCrop
    • RandomResizedCrop
    • BBoxSafeRandomCrop
    • related crop variants

❌ Not supported

Some spatial transforms remain unsupported for OBB, for example:

  • GridShuffle

These transforms operate on discontinuous spatial regions where OBB semantics are not well-defined.


What changed compared to 2.0.15

Before 2.0.16:

  • OBBs were supported in flips, rotations, and scaling
  • Padding and cropping required manual handling or workarounds

As of 2.0.16:

  • Padding correctly shifts OBB coordinates without modifying angles
  • Cropping correctly:
    • clips rotated boxes
    • preserves angle semantics
    • applies existing visibility and area filtering

No special flags. No alternate APIs.


Geometry guarantees

For supported transforms, OBB behavior satisfies:

  • Angle preservation
    Padding and cropping never alter the rotation angle

  • Correct clipping
    Cropped OBBs are clipped in rotated space, not approximated as axis-aligned boxes

  • Consistent filtering
    All existing constraints continue to work:

    • min_area
    • min_visibility
    • min_width / min_height
    • max_accept_ratio

Why this matters

OBBs are now usable in realistic augmentation pipelines that depend on aggressive cropping and padding β€” common in:

  • aerial and satellite imagery
  • OCR and document analysis
  • industrial inspection
  • rotated-object detection models (YOLO-OBB, MMRotate, etc.)

You can now safely combine: