Forums

Fast down sample filtering

Started by km December 9, 2009
Hi All,
  Does anyone have a suggestion for a fast down sampling filter?

km wrote:

> Hi All, > Does anyone have a suggestion for a fast down sampling filter?
Do it yourself or hire a consultant? VLV
On Dec 9, 8:54&#2013266080;am, km <kylei...@gmail.com> wrote:
> Hi All, > &#2013266080; Does anyone have a suggestion for a fast down sampling filter?
Please be more specific. What is sample rate of your input data? What is your required downsampling rate? Is this for a hardware or software implementation? Darol Klawetter
On 12/9/2009 7:54 AM, km wrote:
> Hi All, > Does anyone have a suggestion for a fast down sampling filter?
For N:1 reduction, add N consecutive samples together and output that. Move to the next window of N samples. The response will not be great, but it is, in fact, a fast down sampling filter. Case closed. -- Eric Jacobsen Minister of Algorithms Abineau Communications http://www.abineau.com
Eric Jacobsen wrote:
> On 12/9/2009 7:54 AM, km wrote: > > > Hi All, > > &#2013266080; &#2013266080;Does anyone have a suggestion for a fast down sampling filter? > > For N:1 reduction, add N consecutive samples together and output that. > &#2013266080; Move to the next window of N samples. > > The response will not be great, but it is, in fact, a fast down sampling > filter. > > Case closed.
You think you are joking, but read this: http://www.stereophile.com/features/104law/index1.html BTW, an even faster downsampling algorithm is to simply sub-sample (take every N-th sample). Regards, Andor
Eric Jacobsen wrote:
> On 12/9/2009 7:54 AM, km wrote: >> Hi All, >> Does anyone have a suggestion for a fast down sampling filter? > > For N:1 reduction, add N consecutive samples together and output that. > Move to the next window of N samples. > > The response will not be great, but it is, in fact, a fast down sampling > filter. > > Case closed. >
Eric's suggestion is a very good one in terms of simplicity. Conceptually, you can think of it as a moving average, followed by Rune's suggestion of throwing out all but every Nth sample, aka, downsampling. However, if you want something fancier, you can use a decimation algorithm. Decimation combines The ScopeFIR distribution file, which contains an optimized and free/open decimation function in C, is available at http://www.iowegian.com/download . Also, decimation is a special case of the more general method of resampling, which combines decimation with interpolation. Free resampling software is online at https://ccrma.stanford.edu/~jos/resample/Free_Resampling_Software.html . See dspGuru's Multirate FAQ at http://dspguru.com/dsp/faqs/multirate for some introductory material on multirate topics like downsampling, decimation, and resampling. <RTFFAQ> Grant -- _____________________________________________________________________ Grant R. Griffin Publisher of dspGuru http://www.dspguru.com Iowegian International Corporation http://www.iowegian.com See http://www.iowegian.com/img/contact.gif for e-mail address
On 12/10/2009 2:51 AM, Andor wrote:
> Eric Jacobsen wrote: >> On 12/9/2009 7:54 AM, km wrote: >> >>> Hi All, >>> Does anyone have a suggestion for a fast down sampling filter? >> For N:1 reduction, add N consecutive samples together and output that. >> Move to the next window of N samples. >> >> The response will not be great, but it is, in fact, a fast down sampling >> filter. >> >> Case closed. > > You think you are joking, but read this: > > http://www.stereophile.com/features/104law/index1.html > > BTW, an even faster downsampling algorithm is to simply sub-sample > (take every N-th sample). > > Regards, > Andor
I wasn't joking, it's just the simplest thing I could think of that fully meets the OP's specifications. It's unlikely to be all that useful in many, if not most, applications, but it meets the spec as stated. Dropping all but every Nth sample doesn't "filter", which was part of the OPs problem statement, so I didn't suggest that. -- Eric Jacobsen Minister of Algorithms Abineau Communications http://www.abineau.com
km <kyleinva@gmail.com> wrote:

> Does anyone have a suggestion for a fast down sampling filter?
Good question. I have been wondering for a while now how HDTV receivers do the down conversion. At the frame rate they run at and the available processing I am sure they don't do the full add zero sample/filter/select sample method, especially not in two dimensions. Maybe a simple low pass filter and linear interpolation. As simple as it can be and give reasonable results. -- glen