ModelDriftDetector<T>
Models & Types · AiDotNet.FederatedLearning.DriftDetection
Model-based drift detector: uses gradient direction and weight divergence to detect drift.
Inheritance: FederatedLearningComponentBase<T> → ModelDriftDetector<T>
Implements: IFederatedDriftDetector<T>
For Beginners
Instead of monitoring loss values (like StatisticalDriftDetector), this detector looks at HOW the model is changing. If a client’s gradients suddenly point in a very different direction than before, their data distribution has likely shifted. Similarly, if their model weights diverge abnormally from the global model, they may be adapting to a changed local distribution.
How It Works
Methods:
Constructors
| Constructor | Summary |
|---|---|
ModelDriftDetector(FederatedDriftOptions options) |
Initializes a new instance of ModelDriftDetector. |
Properties
| Property | Summary |
|---|---|
string MethodName { get; } |
Methods
| Method | Summary |
|---|---|
Dictionary<int, double> GetAdaptiveWeights(Dictionary<int, double> originalWeights, DriftReport driftReport) |
|
DriftReport DetectDrift(int round, Dictionary<int, Tensor<T>> clientModels, Tensor<T> globalModel, Dictionary<int, double> clientMetrics) |
|
void Reset() |