Simplify sliding window collapse. (#1802)
* Simplify sliding window collapse. Keep the same value collapsing simple. Add it to sliding window as long as same value is received for longer than collapse threshold. But, add a prune with three conditions to process the siliding window to ensure only valid samples are kept. * flip the order of validity window and same value pruning * increase collapse threshold to 0.5 seconds during non-probe
This commit is contained in:
@@ -60,6 +60,7 @@ type ChannelObserverParams struct {
|
||||
EstimateRequiredSamples int
|
||||
EstimateDownwardTrendThreshold float64
|
||||
EstimateCollapseThreshold time.Duration
|
||||
EstimateValidityWindow time.Duration
|
||||
NackWindowMinDuration time.Duration
|
||||
NackWindowMaxDuration time.Duration
|
||||
NackRatioThreshold float64
|
||||
@@ -87,6 +88,7 @@ func NewChannelObserver(params ChannelObserverParams, logger logger.Logger) *Cha
|
||||
RequiredSamples: params.EstimateRequiredSamples,
|
||||
DownwardTrendThreshold: params.EstimateDownwardTrendThreshold,
|
||||
CollapseThreshold: params.EstimateCollapseThreshold,
|
||||
ValidityWindow: params.EstimateValidityWindow,
|
||||
}),
|
||||
nackTracker: NewNackTracker(NackTrackerParams{
|
||||
Name: params.Name + "-nack",
|
||||
|
||||
Reference in New Issue
Block a user