Merge PR #400: Improve adaptive logging filter
This commit is contained in:
commit
b62060d57d
@ -124,11 +124,11 @@ void StateValueFilterAdaptive::update()
|
||||
m_outputValueCount++;
|
||||
}
|
||||
}
|
||||
|
||||
// Poor mans solution to calculate standard deviation. Not as precise, but much faster than looping over history again
|
||||
m_standardDeviation = ((m_standardDeviation * m_windowSize) + qAbs(changeRatioToAverage)) / (m_windowSize + 1);
|
||||
}
|
||||
|
||||
// Poor mans solution to calculate standard deviation. Not as precise, but much faster than looping over history again
|
||||
m_standardDeviation = ((m_standardDeviation * m_windowSize) + qAbs(changeRatioToAverage)) / (m_windowSize + 1);
|
||||
|
||||
// reset stats on overflow of counters
|
||||
if (m_inputValueCount < m_outputValueCount) {
|
||||
m_outputValueCount = 0;
|
||||
|
||||
Reference in New Issue
Block a user