[chrony-dev] refclock sample dispersion

[ Thread Index | Date Index | More chrony.tuxfamily.org/chrony-dev Archives ]


The latest patches change how refclock dispersion is calculated. There
were two important issues addressed.

First is the dependency on slope. If there is a sudden temperature
change and the refclock is very precise or the polling interval is
long, the dispersion will be higher, the weight of the sample in
sourcestats will be low and it will take chrony longer to adjust the
frequency. Now a linear fit is made if there are more than 3 samples
and the std dev of the intercept is used instead. This also nicely
adjusts the weight as number of processed samples increases.

Second is the noise in the dispersion. When the number of processed
samples is low, there is a high chance the result will be too close to
zero which will make the weight of the point in sourcestats too high
and chrony will be stuck to the point for a while. Ideally, the
weights should be the same for all points until there is a real change
in the input distribution.

In the current code there is now maintained a long-term average of the
variance. The latest variance is compared to the average in an upper
one-sided test (assuming chi-square distribution) and if it's lower,
the average is used instead.

Please review the code. It may not be statistically sound, but I think
it's good enough for our purposes as the values that are too low will
not go through. If there is a simple F-test that doesn't require large
tables for F-distribution, we might want to use it instead.

For chrony-1.24 users I'd recommend setting the refclock delay above
typical dispersion to reduce the effect of these issues.

-- 
Miroslav Lichvar

---
To unsubscribe email chrony-dev-request@xxxxxxxxxxxxxxxxxxxx with "unsubscribe" in the subject.
For help email chrony-dev-request@xxxxxxxxxxxxxxxxxxxx with "help" in the subject.
Trouble?  Email listmaster@xxxxxxxxxxxxxxxxxxxx.


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/