WOLFRAM
Products
Wolfram|One
Mathematica
Wolfram Notebook Assistant + LLM Kit
Wolfram|Alpha Notebook Edition
System Modeler
All Products
Consulting & Solutions
Wolfram Consulting
Industry Solutions
Solutions for Education
Learning & Support
Wolfram U Courses
Wolfram Language Resources
Wolfram Community
Support FAQs
Contact Support
Company
About Wolfram
Careers
Events
Educational Programs
All Sites and Resources
Wolfram|Alpha
Wolfram Cloud
Your Account
Your Account
User Portal
Search
Close
Enable JavaScript to interact with content and submit forms on Wolfram websites.
Learn how
Legacy Documentation
Digital Image Processing
(2000)
This is documentation for an obsolete product.
Current products and services
User's Guide
Area Operations
5.5 Nonlinear Filtering
Noise reduction is an important consideration in many image processing applications. Five noise reducing nonlinear area operators are defined in the
Digital Image Processing
package. These operators use the method of block processing to slide a typically small window across the image domain and perform nonlinear operations on each neighborhood. From a statistical perspective these filters are estimators: they estimate the value of a data sample based on the values of samples in its immediate neighborhood. These filters tend to preserve structural information (i.e., an edge) while suppressing noise.
BlockTrimmedMean
[
img
,
{
k
1
,
k
2
}
,
n
]
returns
BlockMedian
[
img
]
returns
BlockSigma
[
img
,
{
]
returns
BlockLee
[
img
]
returns
BlockOutlier
[
img
,
{
,
t
]
returns's neighborhood if |
x
| is, and, where
Noise reduction operators.
The first argument for each of the noise reduction functions may be a vector, matrix, or
ImageData
expression.
This loads the package.
In[1]:=
This generates a data array
with uniformly distributed additive noise.
In[2]:=
This sets some useful options.
In[3]:=
This shows two views of the example data array.
In[4]:=
Out[4]=
A commonly used measure of the degree of noise corruption is the so-called signal-to-noise ratio (SNR). The SNR is defined as
where
s
is the signal and
n
the noise. The units of SNR are decibels (dB). Since both signals are explicitly given the SNR of the experimental data can be calculated.
In[5]:=
Out[5]=
In the remainder of this section, we demonstrate noise suppression using the five available filters. Features to note are the degree of noise suppression and the amount of blurring. In all cases 3×3 neighborhoods were used. For ease of comparison, a line profile and a density plot are shown for each filter. We begin with an example using the trimmed-mean and the outlier noise reduction filters.
In[6]:=
This plots the results demonstrating the noise reduction achieved with these two operators.
In[7]:=
Out[7]=
Here are the resulting signal-to-noise ratios (larger values indicate better results).
In[8]:=
Out[8]=
Here we use the median and sigma noise reduction filters.
In[9]:=
Out[10]=
Here are the resulting signal-to-noise ratios.
In[11]:=
Out[11]=
Finally, two examples of the Lee operator are shown for different values of the estimate of noise variance [
Lee80
,
Lee83
].
In[12]:=
Out[13]=
Here are the resulting signal-to-noise ratios.
In[14]:=
Out[14]=
These restore the default
ListDensityPlot
and
ListPlot
options.
In[15]:=