Computer Vision
Mr. Sivadasan E T
Associate Professor
Vidya Academy of Science and Technology, Thrissur
Computer Vision
Computer vision has traditionally been one of the
most active research areas for deep learning
applications.
It is because vision is a task that is effortless for
humans and many animals but challenging for
computers.
Computer Vision
Many of the most popular standard benchmark
tasks for deep learning algorithms are forms of:
Object recognition or
Optical character recognition.
Computer Vision
Computer vision is a very broad field
encompassing a wide variety of ways of
processing images, and an amazing diversity of
applications.
Applications of computer vision range from
reproducing human visual abilities, such as
recognizing faces, to creating entirely new
categories of visual abilities.
Computer Vision
As an example of the latter category, one
recent computer vision application is to
recognize sound waves from the vibrations they
induce in objects visible in a video.
Most deep learning research on computer
vision has not focused on such exotic
applications that expand the realm of what is
possible with imagery but rather a small core of
AI goals aimed at replicating human abilities.
Preprocessing
Various steps of preprocessing include;
1. Formatting images to have the same scale.
2. Dataset augmentation.
3. Putting each example into a more canonical
form in order to reduce the amount of
variation.
1. Formatting images to have the same scale
The images should be standardized so that their
pixels all lie in the same, reasonable range, like
[0,1] or [-1, 1]. Mixing images that lie in [0,1] with
images that lie in [0, 255] will usually result in
failure.
2. Dataset augmentation
Dataset augmentation is a preprocessing technique
applied only to the training set.
It helps reduce generalization error in computer vision
models.
A similar approach can be used at test time by showing
multiple versions of the same input (e.g., images cropped
differently).
These variations allow different model instances to vote for
the final output.
This method acts as an ensemble approach, further
reducing generalization error.
3. Canonical Form
Other kinds of preprocessing are applied to both the
train and the test set with the goal of putting each
example into a more canonical form in order to reduce
the amount of variation that the model needs to
account for.
Reducing the amount of variation in the data can both
reduce generalization error and reduce the size of the
model needed to fit the training set.
Simpler tasks may be solved by smaller models, and
simpler solutions are more likely to generalize well.
Contrast Normalization
Contrast refers to the magnitude of the difference
between the bright and the dark pixels in an image.
One of the most obvious sources of variation that can
be safely removed for many tasks is the amount of
contrast in the image.
In the context of deep learning, contrast usually refers
to the standard deviation of the pixels in an image or
region of an image.
Contrast Normalization
Suppose we have an image represented by:
a tensor X ∈ Rr×c×3,
with Xi,j,1 being the red intensity at row i and column j ,
Xi,j,2 giving the green intensity and
Xi,j,3 giving the blue intensity.
Then the contrast of the entire image is given by:
Contrast Normalization
This above formula computes the standard deviation of
pixel intensities, which represents the overall contrast of
the image.
A higher σ value indicates greater contrast, while a
lower value suggests a more uniform or low-contrast
image.
Global Contrast Normalization (GCN)
Global Contrast Normalization (GCN) is a preprocessing
technique used in machine learning and deep learning
to enhance image data by standardizing its contrast.
It is particularly useful for datasets where images have
varying lighting conditions or intensity scales.
Global Contrast Normalization (GCN)
Why Use Global Contrast Normalization?
Improves contrast by adjusting brightness variations
across images.
Reduces sensitivity to global intensity differences, making
the model focus on structural details.
Enhances feature extraction by normalizing pixel values,
helping deep learning models learn more efficiently.
Global Contrast Normalization (GCN)
Images with very low but non-zero contrast often have
little information content.
Dividing by the true standard deviation usually
accomplishes nothing more than amplifying sensor noise
or compression artifacts in such cases.
This motivates introducing a small, positive regularization
parameter λ to bias the estimate of the standard
deviation.
How GCN Works
Given an input image X, GCN produces an output
image X`, defined such that:
Global Contrast Normalization (GCN)
Datasets consisting of large images cropped to
interesting objects are unlikely to contain any images
with nearly constant intensity.
In these cases, it is safe to practically ignore the small
denominator problem by setting λ = 0 and avoid division
by 0 in extremely rare cases by setting ϵ to an extremely
low value like 10−8.
local contrast normalization
Local contrast normalization ensures that the contrast is
normalized across each small window, rather than over
the image as a whole.
Local contrast normalization modifies the image much
more, discarding all regions of constant intensity. This
allows the model to focus on just the edges..
GCN and local contrast normalization
Thank You!