You are on page 1of 44

EE 604

Image Processing
Sampling Theory


Sampling theory for two dimensions

A K Jain
Sampling theory for two dimensions


Sampling theory for two dimensions


Sampling theory for two dimensions
The aliasing problem, foldover frequencies

A K Jain
Towards more efficient use of the frequency space
• This injected energy from its neighbouring aliases results
in a distorted spectrum being picked up by the
reconstruction lowpass filter.

• Of course, if sampling is adequate, this won’t happen.


But what does it mean to be adequate? Importantly, it
only means that aliasing should be avoided at all costs.
• As long as we remain committed to arranging the
samples in a strictly rectangular grid, the aliases in the
frequency domain will also arrange themselves in a
rectangular grid.
• For the example alongside, this is a very bad idea, A K Jain

because…
Efficient Sampling

• It makes sense to arrange things so that there is


the minimum number of samples per unit area
(sampling density) as it saves data storage space
while still achieving perfect reconstruction.
• Given the inverse relationship between the
distance between adjacent samples on the one
hand and the distance between adjacent aliases
on the other hand, the most efficient sampling
will result from the most compact placement of
the aliases.
• In light of this, the packing of aliases shown
alongside is much more efficient than the
previous. There is much void space now.
Non-rectangular grids

• Essentially, then, sampling must be adequate as


well as efficient.
• The shape of the sampling grid must be tuned to
the shape of the support of the image spectrum.
• The example alongside illustrates this: compare
it with the way the aliases were arranged in the
previous slide, causing regular overlaps.
• Here, despite even more compact packing,
there are no overlaps.
• Thie last means that a suitable 2D lowpass filter
can be designed that will reconstruct the image
exactly.
Making efficient non-rectangular grids
Circularly bandlimited signals

Google Images
Random fields

• Random fields are stochastic processes in higher dimensions. They are suitable
for modeling unpredictable phenomena such as noise.
• They are described by their statistical properties rather than by deterministic
values. As with 1D stochastic processes, a wide sense stationary random field
possesses a so called power spectral density (PSD) function, which is the 2D FT of
its stochastic autocorrelation function.
• Sampling of a random field is carried out along similar lines to that of ordinary
images. The support of the PSD determines the minimum sampling density that
will ensure that the reconstruction approaches the original with the minimum
mean squared error.
Quantization

A K Jain
Nonuniform quantization

AAKKJain
Jain
Nonuniform quantization


Nonuniform quantization


Nonuniform quantization


Quantization error and SNR


Uniform quantizer on nonuniform distributions


Properties of the Lloyd Max quantizer


Companding

Companding is a completely different approach to the optimal quantization of a nonuniform


distribution simply tries to convert it into as nearly a uniform distribution as possible, using a
suitably designed transformation, then easily computing the levels and thresholds of the
uniform distribution, and finally reverse mapping the levels using the inverse transformation:.
Multivariate signal quantization


Vector quantization


Sequential scalar quantization


Enhancement
Space and Frequency Domain
Perspectives
The principle of enhancement

• The objective of enhancement techniques is to process a given image so that the result is
more suitable than the original image for a specific application. The work " specific " is
important because enhancement techniques are to a great extent requirement oriented.
• The methods used for enhancing x-ray images may not be suitable for enhancing pictures
transmitted by a space probe.
• Enhancement can, if excessively applied, engender artifacts. Medical experts are very wary
of enhancement procedures, as they can seriously mislead them sometimes.
• Unlike image restoration (to be taken up later in the course), enhancement is not at all
about approximating the ‘truth’ about a ‘distorted’ image. It is just about making a given
image look ‘better’ for something or someone, so that features become now discernable in
it that were hard to discern before.
• There are and cannot be, any objective measures for the performance of an enhancement
procedure. Evaluation is necessarily subjective.
The 2 domains for enhancement

We can enhance an image by manipulating it either in the spatial domain or in the frequency
domain
• The spatial domain has the advantage that operations are more intuitive. We usually can
predict what will result from an operation on a given image. Spatial domain operations may
be computationally very simple as with point operations (eg, gamma correction) or local
(eg. Smoothing, edge enhancement) or global (Fourier Transform).
• The frequency domain operations are a bit abstract, in the sense that the outcome of a
certain operation is not very easy to predict. But it provides certain kinds of control over
images that cannot be achieved from spatial operations.
• In the processing of speech/acoustic signals, there is a much greater prevalence of
frequency domain processing than there is in image processing.
Spatial point operations
Brightness and contrast
Brightness manipulation just changes the dc level (adds a constant)
Contrast manipulation changes the dynamic range keeping the same dc level.
Brightness

Contrast
Thresholding

Gonzalves et al

Soft and Hard Thresholding


Thresholding examples

Original Threshold = 49

Threshold = 130 Threshold = 226


Gamma (power law) modification


Gamma (power law) modification examples
Intensity inversion


Histogram equalization


Histogram equalization


Histogram matching


Histogram matching explained

Gonzales
Local equalization/matching

• Sometimes, the use of the global image statistics to force changes may lead to
undesirable results. For example, a badly taken photocopy of a document might have a
gradually increasing dark background due to improper illumination . If global histogram
operations are applied, one part will be improved at the expense of the other.
• The solution to this is to make the histogram to apply at a particular point on the image
on the basis of the immediate surrounding input image only.

Gonzales

Original Global al
Grey level slicing

• This involves the emphasis of a certain range


at the expense of the other grey levels.
• One approach is to uniformly suppress all
other grey levels and highlight only the ones
we want to show (column 1, alongside).
• The other option is to leave unchanged all
other grey levels and highlight only the ones
we want to show (column 2, alongside).
• The grey level transformations to be applied
are shown above.
Bit plane slicing
Chromatic Adaptation


Chromatic Adaptation Example

The appearance of a colour is affected by what you saw just before.

You might also like