robwasab / HalfBand

HalfBand IIR Filter
4 stars 0 forks source link

License of half_band.py #1

Closed ryukau closed 3 years ago

ryukau commented 3 years ago

Hi.

This repository doesn't contain license text. Is it OK to modify and redistribute half_band.py?

Also many thanks to this implementation. I'm making software synthesizer as a hobby, and this half band decimator is crucial for wavetable oscillator.

robwasab commented 3 years ago

dude, so glad this is helpful, do whatever you want.

robwasab commented 3 years ago

this filter unfortunately distorts the phase because it is an IIR, so that may be an issue.

ryukau commented 3 years ago

Thank you for the permission!


Phase distortion is not the problem, because human ear is insensitive to phase. The requirement of the filter I was seeking is following:

I found the -140dB attenuation when analyzing the output of Vital.

Because of the -140dB attenuation, FIR becomes too long and too slow to compute. I don't have access to Matlab, so I'm not sure if approximately linear phase IIR is better than half_band.py filter. Either way, I'm satisfied with half_band.py filter.


Below is the link to Python 3 translation of half_band.py. Maybe useful to someone who look into this repo.

https://gist.github.com/ryukau/07af221fe64465febbaa8ef69e19d845