Jump to content

Connect Leeroopedia MCP: Equip your AI agents to search best practices, build plans, verify code, diagnose failures, and look up hyperparameter defaults.

Principle:Kornia Kornia Automatic Augmentation

From Leeroopedia


Knowledge Sources
Domains Deep_Learning, Augmentation, AutoML
Last Updated 2026-02-09 15:00 GMT

Overview

Technique of using predefined or learned augmentation policies to automatically select and parameterize data augmentation strategies.

Description

Automatic augmentation methods reduce the need for manual augmentation tuning. The two primary approaches are:

RandAugment selects N random transforms from a policy set and applies them with uniform magnitude M (scaled 0-30). This reduces the augmentation search space to just two hyperparameters: the number of transforms and their shared magnitude.

TrivialAugment selects a single transform per image with uniformly sampled magnitude. This approach has zero hyperparameters to tune, making it the simplest automatic augmentation method.

Both approaches have been shown to match or exceed manually tuned augmentation across diverse vision tasks with minimal hyperparameters, eliminating the costly search process of methods like AutoAugment.

Usage

Use when you want strong augmentation without extensive hyperparameter search:

  • RandAugment when you need control over the number and strength of transforms
  • TrivialAugment for zero-hyperparameter augmentation that works well out of the box

Theoretical Basis

RandAugment: For each image, sample N transforms from policy set P without replacement. Apply each with magnitude scaled as:

# RandAugment magnitude scaling
effective_magnitude = (m / 30) * (max_val - min_val) + min_val

TrivialAugment: Sample one transform from P uniformly, sample magnitude uniformly from [min, max]:

# TrivialAugment: single transform, random magnitude
transform = uniform_sample(policy_set)
magnitude = uniform(min_magnitude, max_magnitude)
output = transform(image, magnitude)

Both reduce the search space dramatically:

  • AutoAugment: O(|P|^K * M^K) -- exponential in number of sub-policies
  • RandAugment: O(2) -- only N and M
  • TrivialAugment: O(0) -- no hyperparameters

Related Pages

Implemented By

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment