Skip to content

Replace Albumentations with Kornia for training transforms #1073

@robmarkcole

Description

@robmarkcole

Search before asking

  • I have searched the RF-DETR issues and found no similar feature requests.

Description

RF-DETR currently depends on albumentations for training resize/augmentation, but Albumentations was archived on July 10, 2025 and is now read-only. This codebase already support Kornia, so we should consider moving all training transforms to Kornia and removing Albumentations.

Benefits:

  • Removes dependency on an archived project.
  • Avoids pulling OpenCV through Albumentations.
  • Unifies CPU/GPU augmentation around one backend.
  • Reduces dependency and maintenance surface.

Acceptance criteria:

  • Training no longer requires albumentations.
  • COCO/YOLO detection and segmentation transforms still work.
  • Resize, multi-scale, square resize, masks, boxes, and normalization retain parity.
  • Tests cover the replacement paths.

Use case

No response

Additional

No response

Are you willing to submit a PR?

  • Yes I'd like to help by submitting a PR!

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions