DynAIkonTrap.filtering.iir#

The IIR filter architecture provided in this module can be used to filter/smooth “continuous” data signals in time. In particular, it is used in the motion filtering stage of the filtering pipeline.

Classes

IIR2Filter(coeffs)

Second order IIR filter stage

IIRFilter(SOS)

IIR filter constructed from IIR2Filters

class IIR2Filter(coeffs: numpy.ndarray)#

Second order IIR filter stage

Parameters:

coeffs (numpy.ndarray) – SOS coefficients as returned by the utility functions from scipy

filter(x: float) float#

Perform time-based filtering based on the provided data sample

Parameters:

x (float) – A data sample

Returns:

The filtered sample

Return type:

float

reset()#
class IIRFilter(SOS: numpy.ndarray)#

IIR filter constructed from IIR2Filters

Creates a chain of 2nd order filter instances of IIR2Filter

Parameters:

SOS (numpy.ndarray) – SOS coefficients as returned by the utility functions from scipy

filter(x: float) float#

Perform time-based filtering based on the provided data sample

Parameters:

x (float) – A data sample

Returns:

The filtered sample

Return type:

float

reset()#