30 #ifndef GRT_WEIGHTED_AVERAGE_FILTER_HEADER
31 #define GRT_WEIGHTED_AVERAGE_FILTER_HEADER
33 #include "../CoreModules/PreProcessing.h"
103 virtual bool save( std::fstream &file )
const;
112 virtual bool load( std::fstream &file );
121 bool init(UINT filterSize,UINT numDimensions);
129 Float filter(
const Float x);
166 #endif //GRT_MOVING_AVERAGE_FILTER_HEADER
virtual bool deepCopyFrom(const PreProcessing *rhs)
UINT inputSampleCounter
A counter to keep track of the number of input samples.
CircularBuffer< VectorFloat > dataBuffer
A buffer to store the previous N values, N = filterSize.
virtual bool save(const std::string filename) const
UINT getFilterSize() const
virtual bool load(const std::string filename)
UINT filterSize
The size of the filter.
virtual bool process(const VectorFloat &inputVector)
VectorFloat getFilteredData() const
VectorFloat weights
Stores the weights for each sample in the buffer, the size of this vector will match the filterSize...