AugmentationPipeline<T, TData>

Models & Types · AiDotNet.Augmentation

Represents a pipeline of augmentations that are applied in sequence or composition.

Implements: IAugmentationPolicy<T, TData>

For Beginners

Think of this as a recipe of transformations. You might want to first flip an image, then rotate it, then adjust the colors. This pipeline handles all of that automatically.

How It Works

AugmentationPipeline allows you to compose multiple augmentations together. Each augmentation in the pipeline is applied with its own probability, and the order can be sequential, random, or one-of.

Constructors

Constructor Summary
AugmentationPipeline(string name) Creates a new augmentation pipeline with an optional name.

Properties

Property Summary
AugmentationOrder Order { get; set; } Gets or sets the application order for augmentations.
IList<IAugmentation<T, TData>> Augmentations { get; }
IList<string> AugmentationNames { get; }
int AugmentationCount { get; }
string Name { get; set; }

Methods

Method Summary
AugmentationPipeline<T, TData> Add(IAugmentation<T, TData> augmentation) Adds an augmentation to the pipeline.
AugmentationPipeline<T, TData> AddRange(IEnumerable<IAugmentation<T, TData>> augmentations) Adds multiple augmentations to the pipeline.
AugmentationPipeline<T, TData> OneOf(IAugmentation<T, TData>[] augmentations) Creates a sub-pipeline that applies one-of the specified augmentations.
AugmentationPipeline<T, TData> Shuffle(IAugmentation<T, TData>[] augmentations) Creates a sub-pipeline with random ordering.
IDictionary<string, object> GetConfiguration()
TData Apply(TData data, AugmentationContext<T> context)