HyperCLIPOptions<T, TInput, TOutput>

Options & Configuration · AiDotNet.MetaLearning.Options

Configuration options for HyperCLIP meta-learning.

Inheritance: ModelOptions → HyperCLIPOptions<T, TInput, TOutput>

Implements: IMetaLearnerOptions<T>

How It Works

HyperCLIP uses contrastive alignment between task embeddings (from support gradients) and parameter embeddings (from adapted parameters). An InfoNCE-style contrastive loss ensures that a task’s embedding is closest to its own adapted parameter embedding, enabling zero-shot parameter generation for new tasks.

Constructors

Constructor Summary
HyperCLIPOptions(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 ContrastiveTemperature { get; set; } Temperature for the InfoNCE contrastive loss (τ in exp(sim/τ)).
double ContrastiveWeight { get; set; } Weight of the contrastive alignment loss relative to the task loss.
double InnerLearningRate { get; set; }
double OuterLearningRate { get; set; }
double? GradientClipThreshold { get; set; }
int AdaptationSteps { get; set; }
int CheckpointFrequency { get; set; }
int EmbeddingDim { get; set; } Gradient compression dimension for computing embeddings from gradients.
int EvaluationFrequency { get; set; }
int EvaluationTasks { get; set; }
int MetaBatchSize { get; set; }
int NumMetaIterations { get; set; }
int ProjectionDim { get; set; } Dimension of the shared projection space for contrastive alignment.
int? RandomSeed { get; set; }

Methods

Method Summary
IMetaLearnerOptions<T> Clone()
bool IsValid()