DSP.jl
DSP.jl copied to clipboard
Use new stateful filter API for filtfilt
This provides reduces the memory allocation and provides a small speed boost (on 0.4; on 0.3, where SubArrays are slow, it's probably substantially slower). We could conceivably use this to provide in-place filtfilt, although that is not yet implemented.
I removed support for non-1 initial values of a in filt_stepstate, since we don't need it if the filter is normalized before it is used.
Coverage increased (+0.05%) to 97.46% when pulling 01c365568e6afd08659c3743c0009c0acf348751 on sjk/filtfilt into bcca68b5ece29e4cfb6906209d00981cabcbfcd9 on master.
Coverage increased (+0.04%) to 97.45% when pulling e89c70286b5865afe102b444ccb616d4688237fa on sjk/filtfilt into bcca68b5ece29e4cfb6906209d00981cabcbfcd9 on master.
It seems there is a bug in SubArrays on 0.3 that prevents this from working at all there.