Sign in

username:

password:



Not a member?

Search compdsp



Search tips

comp.dsp by Keywords

Adaptive Filter | ADPCM | ADSP | ADSP-2181 | Aliasing | AMR | Anti-Aliasing | ARMA | Autocorrelation | AutoCovariance | Beamforming | Bessel | Blackfin | Butterworth | C6713 | CCS | Chebyshev | CIC Filter | Circular Convolution | Code Composer Studio | Comb Filter | Compression | Convolution | Cross Correlation | DCT | Decimation | Deconvolution | Demodulation | DM642 | DSP Boards | DSP/BIOS | DTMF | Echo Cancellation | Equalization | Equalizer | ETSI | EZLITE (Ez-kit Lite) | FFT | FFTW | FIR Filter | Fixed Point | FSK | G.711 | G.723 | G.729 | Gaussian Noise | Goertzel | GPIO | Hilbert Transform | IFFT | IIR Filter | Interpolation | Invariance | JTAG | Kalman | Laplace Transform | Levinson | LPC | McBSP | MIPS | Modulation | MPEG | Multirate | Notch Filter | Nyquist | OFDM | Oversampling | Pink Noise | Pitch | PLL | Polyphase | QAM | QDMA | Quantization | Quantizer | Radar | Random Noise | Reed Solomon | Remez | Resampling | RTDX | Sampling | Sharc | TI C6711 | Undersampling | Viterbi | Wavelets | White Noise | Wiener Filter | Windowing | XDS510PP | Z Transform

Sponsor

Industry's highest performing at the lowest power DSPs now as low as $5.00*
Start development today!
*volume pricing for 10ku

Discussion Groups

Free Online Books

See Also

Embedded SystemsFPGAElectronics

Discussion Groups | Comp.DSP | Wiener filtering using mean-squared method: variance problem

There are 1 messages in this thread.

You are currently looking at messages 0 to 1.


Wiener filtering using mean-squared method: variance problem - 2008-12-22 18:23:00



I am trying to implement a low pass Wiener filter using the mean-
squared method, to provide elimination of noisy areas, background
texture smoothing, and contrast enhancement. The algorithm I'm using
is (to produce output image Q from input image P), to evaluate a 3x3
neighbourhood for each pixel, and

  Q(x,y) =  mu + [  (sigmasquared - nusquared)/sigmasquared  ]  ( P
(x,y) - mu )

Where:
  mu  is the local mean across the neighbourhood
  sigmasquared is the variance of the 3x3 neighbourhood
  nusquared is the estimated local variance

Now, I don't know the source of the putative high frequency noise, so
I have to estimate nusquared, which is where I am running into
problems. All the code I can find on the net estimates nusquared by
using the variance of the whole of the original image. Not a canonical
source I know, but see, e.g., the bottom of:
  http://www.vislab.uq.edu.au/education/sc3/2000/xinghe/project/theory.html

Now this doesn't work for me, as in images to which noise has NOT been
added, the local variance is consistently SMALLER than the image
variance (in one test image it is never larger than image variance.
This seems to me bound to be the case on (for example) an image that
has been enlarged by bicubic interpolation and thus is already
"smooth". The problem here is that the Wiener filter does terrible
things to the image because the term in square brackets goes
substantially negative (as sigmasquared << nusquared), causing the
output to wildly oscillate.

I think the problem here is that all the code examples I have found
have assumed that the image variance is a good estimate for the local
variance. That's true if you are doing a compsci project where the
input image has had a lot of noise added to it, but isn't universally
true. I think the problem is that I need a better estimate for
nusquared.

What would you recommend here? Taking the mean of the 3x3 variances
across the image?

Alex

______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.