Re: Best resampling approach for different types of data?
- From: jim <"sjedgingN0Sp"@m@mwt,net>
- Date: Thu, 03 Sep 2009 16:58:09 -0500
chrah wrote:
chrah wrote:different
Hi,
I need to downsample a bunch of signals, all of which have very
Allproperties (the Nyquist criteria will not be fulfilled after the
downsampling). My question is how to proceed in the best possible way.
apply unprocessing is off-line but has to be fairly fast.
Case 1: An analogue signal (continuous amplitude and time) has been
sampled and needs to be downsampled. I have no problems here, just
byantialias filter and resample properly.
Case 2: An analogue signal with discontinuous jumps. Ripples introduced
help.the antialias filter makes the downsampled signal useless. Please
this be
Case 3: An analogue signal which contains constant segments. Antialias
filters introduce ripples at the edge of each constant segment. Can
sampleavoided in a clever way?
Case 4: An enum signal (a few discrete amplitude levels and continuous
time). I guess the best approach here is to, kind of, just pick the
ofwhich is closest to the new sampling time (nearest neighbour
interpolation).
Case 5: Noisy enum signal. Using a linear filter will introduce lots
changesripple since there are discontinuous jumps every time the signal
medianfrom one amplitude state to another. My approach would be to use a
betterfilter followed by the case 2 approach, but I guess there must be a
degree.]way?
I hope you can help
Best regards
Christer
Christer,
Let's try to break this down into a few fundamental things:
By "downsample" we generally mean bringing a passband signal down to
baseband with quadrature samples. This usually involves reducing the
sample rate at the same time.
By "decimate" or "sample rate reduction" we generally mean reducing the
sample rate but leaving the signal spectrum location the same.
I think you mean to decimate here / to reduce the sample rate.
When there are discontinuities in the analog signal then you "should"
filter before sampling so as to meet the Nyquist criterion.
When there are discontinuities in a sampled signal then you "should"
filter before sample rate reduction.
[I say "should" because the degree, etc. becomes subjective to a
Ripple at the discontinuities is caused by using a rectangular spectral
window as in a "perfect" brick wall lowpass filter.
Applying any filter causes convolution in the time domain.
A brick wall filter has a sinc as its temporal response.
The convolution with a sinc causes the ripples at transient edges.
The solution to the ripples is to use a filter whose transition from
passband to stopband is more gradual. There are even optimum filters
that have monotonic temporal transitions - with *no* ripple and still
have minimum rise time. This is as good as it gets.
So, you pick a lowpass filter that has "nice" characteristics for your
application and use that as a pre-decimation filter. You may want to
decimate in stages using half-band filters - that's one option.
With any lowpass filter you're going to have a transient in the impulse
/ unit sample response as the filter "fills up" with the next change in
the signal. So, you may be motivated to ignore the ends of a filtered
record and perhaps even to ignore the information around a step change -
although that really isn't necessary. The signal, post-decimation is
what it is, transients and all.
Obviously you can't lowpass filter and *then* expect to identify exactly
where the step changes have occurred ... at least not more accurately
than the lower bandwidth allows. In general, the temporal resolution
for this sort of thing is the reciprocal of the filter bandwidth.
You'll be stuck with that.
This ignores any fancy nonlinear processing one might do.
Fred
Please tell me more about the fancy nonlinear processing. As I already
mentioned, bilateral filtering works pretty good in the case where it is
important to preserve the edges of a jump in the signal. Weighted median
filters should also be able to do the trick fairly well. Any other
suggestions?
Maybe you just need data compression. Is your task to store as much of
the original data in a small amount of space.
-jim
/Christer.
- References:
- Best resampling approach for different types of data?
- From: chrah
- Re: Best resampling approach for different types of data?
- From: Fred Marshall
- Re: Best resampling approach for different types of data?
- From: chrah
- Best resampling approach for different types of data?
- Prev by Date: Re: Interfacing a serial ADC to TMS320C5509 DSP
- Next by Date: Re: FIR or IIR? Filter help
- Previous by thread: Re: Best resampling approach for different types of data?
- Next by thread: Re: Best resampling approach for different types of data?
- Index(es):
Relevant Pages
|