IGradientConstraintStrategy<T, TInput, TOutput>

Interfaces · AiDotNet.ContinualLearning.Interfaces

Extended strategy interface for gradient-based constraint strategies.

Implements: IMemoryBasedStrategy<T, TInput, TOutput>

Known implementations: GradientEpisodicMemory<T, TInput, TOutput>

Properties

Property Summary
int StoredGradientCount { get; } Gets the number of tasks with stored gradients.

Methods

Method Summary
Vector<T> ProjectGradient(Vector<T> gradient) Projects a gradient to satisfy all task constraints.
bool ViolatesConstraint(Vector<T> gradient) Checks if a gradient violates any task constraint.
void StoreTaskGradient(Vector<T> taskGradient) Stores the gradient for a completed task.