28 #ifndef GRT_MOVING_AVERAGE_FILTER_HEADER 29 #define GRT_MOVING_AVERAGE_FILTER_HEADER 31 #include "../CoreModules/PreProcessing.h" 104 virtual bool save(std::fstream &file)
const;
113 virtual bool load(std::fstream &file);
122 bool init(
const UINT filterSize,
const UINT numDimensions);
130 Float filter(
const Float x);
145 UINT getFilterSize()
const;
159 static std::string
getId();
171 static const std::string id;
177 #endif //GRT_MOVING_AVERAGE_FILTER_HEADER std::string getId() const
virtual bool deepCopyFrom(const PreProcessing *rhs)
The MovingAverageFilter implements a low pass moving average filter.
CircularBuffer< VectorFloat > dataBuffer
A buffer to store the previous N values, N = filterSize.
virtual bool save(const std::string &filename) const
virtual bool reset() override
UINT filterSize
The size of the filter.
virtual bool process(const VectorFloat &inputVector)
UINT inputSampleCounter
A counter to keep track of the number of input samples.
virtual bool load(const std::string &filename)