MOCAOptions<T, TInput, TOutput>
Options & Configuration ยท AiDotNet.MetaLearning.Options
Configuration options for the MOCA (Meta-learning with Online Complementary Augmentation) algorithm.
Inheritance: ModelOptions โ MOCAOptions<T, TInput, TOutput>
Implements: IMetaLearnerOptions<T>
How It Works
MOCA augments tasks in gradient space using complementary perturbations derived from historical gradient statistics. The augmented gradients explore directions orthogonal to the original task gradient, encouraging more robust meta-learned initializations.
Constructors
| Constructor | Summary |
|---|---|
MOCAOptions(IFullModel<T, TInput, TOutput> metaModel) |
Creates options for meta-learning metaModel, with the default settings. |
Properties
| Property | Summary |
|---|---|
IEpisodicDataLoader<T, TInput, TOutput> DataLoader { get; set; } |
Episodic data loader that supplies the meta-training tasks; null when tasks are passed to training directly. |
IFullModel<T, TInput, TOutput> MetaModel { get; set; } |
The model whose parameters the meta-learner trains to adapt quickly to new tasks. |
IGradientBasedOptimizer<T, TInput, TOutput> InnerOptimizer { get; set; } |
Optimizer for task adaptation. |
IGradientBasedOptimizer<T, TInput, TOutput> MetaOptimizer { get; set; } |
Optimizer for the meta-update. |
ILossFunction<T> LossFunction { get; set; } |
Loss function for meta-training; null uses the default multi-class classification loss. |
bool EnableCheckpointing { get; set; } |
|
bool UseFirstOrder { get; set; } |
Whether to use the first-order approximation of the meta-gradient. |
double AugmentationStrength { get; set; } |
Magnitude of gradient-space perturbation for augmented tasks. |
double ComplementaryWeight { get; set; } |
Weight on the augmented task loss in the meta-objective. |
double HistoryMomentum { get; set; } |
EMA momentum for accumulating gradient history statistics (mean and variance). |
double InnerLearningRate { get; set; } |
|
double OuterLearningRate { get; set; } |
|
double? GradientClipThreshold { get; set; } |
|
int AdaptationSteps { get; set; } |
|
int CheckpointFrequency { get; set; } |
|
int EvaluationFrequency { get; set; } |
|
int EvaluationTasks { get; set; } |
|
int MetaBatchSize { get; set; } |
|
int NumAugmentedTasks { get; set; } |
Number of augmented task variants generated per real task in the meta-batch. |
int NumMetaIterations { get; set; } |
|
int? RandomSeed { get; set; } |
Methods
| Method | Summary |
|---|---|
IMetaLearnerOptions<T> Clone() |
|
bool IsValid() |