MetaFDMixupAlgorithm<T, TInput, TOutput>
Models & Types · AiDotNet.MetaLearning.Algorithms
Implementation of Meta-FDMixup: Feature-Distribution Mixup for cross-domain few-shot learning (Xu et al., CVPR 2021).
Inheritance: ModelBase<T, TInput, TOutput> → MetaLearnerBase<T, TInput, TOutput> → MetaFDMixupAlgorithm<T, TInput, TOutput>
How It Works
Meta-FDMixup performs gradient-level mixup between tasks in a meta-batch to improve cross-domain robustness. For each task, with probability p, its inner-loop gradient is mixed with a randomly selected other task’s gradient using a Beta-distributed coefficient λ. The outer loop also applies feature distribution alignment by penalizing the variance of per-task gradient directions.
Algorithm:
Constructors
| Constructor | Summary |
|---|---|
MetaFDMixupAlgorithm(MetaFDMixupOptions<T, TInput, TOutput> options) |
Properties
| Property | Summary |
|---|---|
MetaLearningAlgorithmType AlgorithmType { get; } |
Methods
| Method | Summary |
|---|---|
IModel<TInput, TOutput, ModelMetadata<T>> Adapt(IMetaLearningTask<T, TInput, TOutput> task) |
|
T MetaTrain(TaskBatch<T, TInput, TOutput> taskBatch) |