0% found this document useful (0 votes)
13 views10 pages

Understanding Image Sampling and Processing

Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views10 pages

Understanding Image Sampling and Processing

Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

What is Image Sampling? What is Digital Image Processing?

What is Digital Image Processing? An image may be defined Introduction to Color Spaces Singular Value Decomposition Discrete Cosine Transform
Sampling is the process of converting an analog signal into as a two dimensional function, f(x,y), where x & y are spatial Color spaces are the mathematical representation of a set of colors. There The process of Singular Value Decomposition DCT Definition
are many color models. Some of them are RGB, CMYK, YIQ, HSV, and HLS,
discrete values. In layman's terms, we can say that sampling is (plane) Coordinates and the amplitude of f at any pair of etc. These color spaces are directly related to saturation and brightness. (SVD) involves breaking down a matrix A into the form The discrete cosine transform (DCT) represents an image as a
the process of recording an Coordinates (x, y) is called the intensity gray level of the image All of these color spaces can be derived using RGB information using . This computation allows us to retain sum of sinusoids of varying magnitudes and frequencies.
analog signal at regular intervals of time. A sampling function at that point. devices such as cameras and scanners. the important singular values that the image requires while The dct2 function computes the two-dimensional discrete
is applied to the analog signal that results in the sampled when x,y and the intensity valves of f are all finite, discrete RGB Color Space also releasing the values that are not as necessary in retaining cosine transform (DCT) of an image. The DCT has the property
signal. quantities we call the image digital image. The field of digital RGB stands for Red, Green, and Blue. This color space is widely used in the quality of the image. The singular values of an m × n that, for a typical image, most of the visually significant
computer graphics. RGB are the main colors from which many colors can
We get a finite number of samples of an analog signal. The image processing refers to Processing digital Images by means be made. matrix A are the square information about the image is concentrated in just a few
number of samples gives us the number of pixels. More of Digital Computer > Digital image is composed of a finite RGB can be represented in the 3-dimensional form: roots of the eigenvalues of the n × n matrix AT A, which are coefficients of the DCT. For this reason, the DCT is often used
samples will result in higher number of elements, each of which has a particular location typically organized by magnitude in decreasing order [4]. The in image compression applications. For example, the DCT is at
image quality of the digital image because of more pixels. and value. => These elements are called picture elements"/ Singular Value Decomposition is so named due to the singular the heart of the international standard lossy image
"image elements" and "pixels"! values that are identified and isolated from matrix A. compression algorithm known as JPEG. (The name comes
#pirel is the team used most widely to denote the elements How to Compute the SVD of a Matrix from the working group that developed the standard: the
of digital image. We will rewrite an m × n matrix A in the form Joint Photographic Experts Group.)
Image processing is a method of manipulating or altering an , where U is an m × m matrix The two-dimensional DCT of an M-by-N matrix A is defined as
image to achieve a desired result, typically for improving its orthonormal columns, Σ is an m × n matrix with singular follows.
visual quality or extracting useful information from it. It values on the main diagonal, and V is an n × n matrix with
involves a variety of techniques and algorithms to modify or orthonormal columns. V T is the transpose of matrix V, which The values Bpq are called the DCT coefficients of A. (Note that
analyze images, and it is a fundamental component of is found by exchanging the rows and the columns of the matrix indices in MATLAB® always start at 1 rather than 0;
computer vision, artificial intelligence, and many other fields. matrix. therefore, the MATLAB matrix
Applications of digital image processing: Note: If two column vectors form an orthonormal set, it elements A(1,1) and B(1,1) correspond to the mathematical
Automatic character recognition. means that the inner product of the columns with each other quantities A00 and B00, respectively.)
Below table is 100% RGB color bar contains values for 100% amplitude,
Military recognition. is 0, and the inner product of any column with itself is 1. The DCT is an invertible transform, and its inverse is given by
Automatic processing of fingerprints. Hence, any matrix B that has orthonormal columns has the
Screening of X-ray and blood samples. property BTB = I = BBT, where I is the identity matrix.
It is used in the study of pollution particles. Before we apply the SVD to image processing, we will first
It is used to restore blurred pictures of rare artifacts demonstrate the method using a small (2×3) matrix A:
(application in archaeology).
The sampled signal is then quantized to get the value of each Industrial machine vision for products assembly and
pixel. Let us look at how quantization is achieved. inspection.
What is Image Quantization? Machine processing of aerial and satellite imagery for weather 100% saturated, and for video test signal.
After sampling the analog signal, we will apply quantization. prediction. and then follow a step-by-step process to rewrite the matrix A
CMYK Color Model
Quantization digitizes the amplitude of the sampled signal. In astronomy, biology, nuclear medicine, law enforcement, CMYK stands for Cyan, Magenta, Yellow and Black. CMYK color model is in the separated form .
Quantization is done by rounding off the amplitude of each defence and industry, etc. used in electrostatic and ink-jet plotters which deposits the pigmentation Step 1: Form ATA
sample and then assigning a different value according to its Fundamental steps in Digital Image on paper. In these model, specified color is subtracted from the white light We begin by forming AT A for our given matrix A by
amplitude. Each value will represent a different color tone. Processing rather than adding blackness. It follows the Cartesian coordinate system performing basic matrix multiplication as follows:
These functions are called the basis functions of the DCT. The
DCT coefficients Bpq, then, can be regarded as
the weights applied to each basis function. For 8-by-8
matrices, the 64 basis functions are illustrated by this image.
The 64 Basis Functions of an 8-by-8 Matrix

This process will result in a square matrix of dimension n × n


with non-negative values, and here we can see that we have
only non-negative values in our resulting 3 × 3 matrix.
Step 2: Determine the eigenvalues of AT A
In order to determine the eigenvalues of AT A, we need to
compute the determinant of the matrix AT A − λI. In general,
we compute the determinant of a 3 × 3 matrix in the following
and its subset is a unit cube. way:
We could clearly extend this computation to an n × n matrix as
HSV Color Model We then normalize the eigenvector by dividing by its
HSV stands for Hue, Saturation, and Value (brightness). It is a hexcone
subset of the cylindrical coordinate system. The human eye can see 128 magnitude to form a new vector:
different hues, 130 different saturations and number values between 16
(blue) and 23 (yellow).
Difference Between Image Sampling and Quantization
Let's see how sampling and quantization differ:
• ImageAcquisition Horizontal frequencies increase from left to right, and vertical
Aspect Image Sampling Image Quantization This is the first step or process of the fundamental steps of frequencies increase from top to bottom. The constant-valued
digital image processing. Image acquisition could be as simple basis function at the upper left is often called the DC basis
Digitalizing an as being given an image that is already in digital form. function, and the corresponding DCT coefficient B00 is often
Definition analog signal's x-axis Digitalizing its y-axis Generally, the image acquisition stage involves preprocessing, called the DC coefficient.
An analog signal's Amplitude values such as scaling etc. The DCT Transform Matrix
Process amplitude value rounded off, assigned • Image Enhancement There are two ways to compute the DCT using Image
noted at intervals values Image enhancement is among the simplest and most Processing Toolbox™ software. The first method is to use
appealing areas of digital image processing. Basically, the idea AT A − λI which is: the dct2 function. dct2 uses an FFT-based algorithm for
Precedes behind enhancement techniques is to bring out detail that is speedy computation with large inputs. The second method is
Order Follows sampling By setting this determinant equal to zero, we solve what is
quantization obscured, or simply to highlight certain features of interest in to use the DCT transform matrix, which is returned by the
called the characteristic equation for λ, and here we see that λ
Establishes the an image. Such as, changing brightness & contrast etc. = 0, 5, 30. We reorder the eigenvalues in decreasing function dctmtx and might be more efficient for small square
number of pixels in a Establishes the color of
Basis • ImageRestoration magnitude, so that: λ1 = 30, λ2 = 5, and λ3 = 0. inputs, such as 8-by-8 or 16-by-16. The M-by-M transform
each pixel
digital image Image restoration is an area that also deals with improving Step 3: Form the matrix V T matrix T is given by
Pixels per inch (PPI) Bits per channel (e.g., 8- the appearance of an image. However, unlike enhancement, Once we have determined the eigenvalues, we then compute
HLS Color Model
Measurement or dots per inch which is HLS stands for Hue Light Saturation. It is a double hexcone subset. The the corresponding eigenvectors and normalize them to
bit color) subjective, image restoration is objective, in the sense that maximum saturation of hue is S= 1 and L= 0.5. It is conceptually easy for produce the matrix V. In general, we compute eigenvectors by Image Compression with the Discrete Cosine Transform
(DPI)
restoration techniques tend to be based on mathematical or people who want to view white as a point. using the matrix AT A − λI and simplify the matrix for each Try This ExampleCopy Code Copy Command
Affects the probabilistic models of image degradation This example shows how to compress an image using the
sharpness and clarity Affects the color eigenvalue
Impact • Color Image Processing Discrete Cosine Transform (DCT). The example computes the
richness of the image
of the image Color image processing is an area that has been gaining its two-dimensional DCT of 8-by-8 blocks in an input image,
Advantages of Image Sampling and Quantization importance because of the significant increase in the use of discards (sets to zero) all but 10 of the 64 DCT coefficients in
-Improved Resolution: Sampling increases the resolution of digital images over the Internet. This may include color each block, and then reconstructs the image using the two-
digital images, resulting in sharper and clearer visuals. modeling and processing in a digital domain etc. dimensional inverse DCT of each block. The example uses the
-Color Depth Control: Quantization allows for precise control • Wavelets and Multiresolution Processing example, for λ1 = 30 we have: transform matrix computation method.
over color depth, enabling the creation of vibrant and richly Wavelets are the foundation for representing images in DCT is used in the JPEG image compression algorithm. The
colored images. various degrees of resolution. Images subdivision successively input image is divided into 8-by-8 or 16-by-16 blocks, and the
-Data Compression: Sampling and quantization facilitate data into smaller regions for data compression representation. two-dimensional DCT is computed for each block. The DCT
compression techniques, reducing storage requirements for and for pyramidal coefficients are then quantized, coded, and transmitted. The
images while maintaining visual quality. • Compression JPEG receiver (or JPEG file reader) decodes the quantized DCT
-Standardization: Both processes allow for standardization of Compression deals with techniques for reducing the storage coefficients, computes the inverse two-dimensional DCT of
image formats and quality, ensuring compatibility across required to save an image or the bandwidth to transmit it. each block, and then puts the blocks back together into a
different devices and platforms. Particularly in the uses of internet it is very muchnecessary to single image. For typical images, many of the DCT coefficients
Disadvantages of Image Sampling and Quantization compress data. have values close to zero. These coefficients can be discarded
-Loss of Information: Sampling and quantization may lead to • Morphological Processing without seriously affecting the quality of the reconstructed
the loss of subtle details and nuances present in the original Morphological processing deals with tools for extracting We could clearly extend this computation to an n × n matrix as image.
analog signal or image.-Artifacts: Improper sampling and image components that are useful in the representation and We then normalize the eigenvector by dividing by its Applications
quantization can introduce artifacts such as aliasing, banding, description of magnitude to form a new vector: As mentioned before, DCT does a great job of highlighting the
and color quantization errors, degrading image quality. shape. frequencies. Which can further show redundancies. This
-Processing Overhead: Both processes require computational • Segmentation Principal Component Analysis is a popular linear makes it perfect for compression applications. Some of the
resources and processing time, especially for high-resolution Segmentation procedures partition an image into its dimensionality reduction technique. Data in real world is very applications of DCT are as follows:
images or complex color palettes. constituent parts or objects. In general, autonomous high dimensional so we use dimensionality reduction methods Image compression algorithms like JPEG and HEIF.
-Limited Dynamic Range: Quantization can result in a loss of segmentation is one of the most difficult tasks in digital image to reduce the data to 2 dimensions. The aim of the article is to Audio file formats like MP3, AAC, and more.
dynamic range, especially in low-bit-depth images, leading to processing. A rugged segmentation procedure brings the compress the image using principal component analysis. Video file formats like MPEG.
loss of color fidelity and tonal gradations. process a long way toward successful solution of imaging High dimensional data is sparse and appropriate statistical Scientists and Engineers also use them for digital signal
Applications of Image Sampling and Quantization problems that require objects to be identified individually. methods can not be applied on data. The image has processing, telecommunications, and more.
-Digital Photography: Sampling and quantization are • Representation and Description dimension 200 x 200 pixels in size. “ Discrete Fourier Transform in Image Processing”
fundamental processes in digital photography, enabling the Representation and description almost always follow the Principal Component Analysis We do this for each eigenvalue to produce a full set of The Discrete Fourier Transform (DFT) is a fundamental image-
capture and processing of images from digital cameras and output of a segmentation stage, which usually is raw pixel eigenvectors that we will use to form the matrix V. For our processing tool used to decompose an image into its sine and
sensors. data, constituting either the example, cosine components. This transformation converts an image
-Medical Imaging: Sampling and quantization are used in boundary of a region or all the points in the region itself. from the spatial domain to the Fourier or frequency domain.
medical imaging techniques such as MRI, CT scans, and Choosing a representation is only part of the solution for Each point in the Fourier domain image represents a specific
ultrasound to convert analog signals into digital images for transforming raw data frequency contained within the spatial domain image.
diagnosis and analysis. into a form suitable for subsequent computer processing. The applications of the Fourier Transform are diverse, ranging
-Remote Sensing: Image sampling and quantization are Description deals with extracting attributes that result in from image analysis and filtering to reconstruction and
employed in satellite imagery and remote sensing applications some quantitative information of interest or are basic for compression. Its versatility makes it indispensable in various
to capture and process data from Earth's surface for differentiating one class of objects from another. fields of image processing.
environmental monitoring, urban planning, and agricultural • Object recognition The matrix V T can be easily obtained from V, which results in How Does it Work
analysis. Recognition is the process that assigns a label, such as, the columns interchanging with the corresponding rows. Thus, Mathematically, for a square image of size N×N, the two-
-Graphics and Multimedia: Sampling and quantization are “vehicle” to an object based on its descriptors. Principal Component Analysis is an unsupervised algorithm in we have the resulting matrix dimensional DFT is given by:
essential in graphics and multimedia applications for Components of Image Processing System which we don’t have the labels. It finds orthogonal projections
rendering, compression, and transmission of images in • Image Sensors: Image sensors senses the intensity, which are independent. The first principal component is in the
computer graphics, video streaming, and virtual reality amplitude, co-ordinates and other features of the images and direction of maximum variance in the data and so on. The
systems. passes the result to principal components are linearly uncorrelated. eg: in the
Basic Relationships Between Pixels the image processing hardware. It includes the problem above scatter plot the first principal component is c which is in
Neighborhood domain. the direction of maximum variance which means spread of
Adjacency • Image Processing Hardware: Image processing hardware is data and would give maximum information about the data. Step 4: Form the matrix Σ To determine the matrix Σ, we list
Paths the dedicated hardware that is used to process the The second principal component is a which is orthogonal the nonzero singular values, σi , in decreasing magnitude
Connectivity instructions obtained from the image sensors. It passes the to c and would give less information about the data as down the main diagonal of Σ, where . Then we add any
Regions result to general purpose computer. compared to first principal component and so on. The data in additional rows and columns of zeros as needed to retain the Here, f(a,b) represents the image in the spatial domain, and
Boundaries • Computer: Computer used in the image processing system high dimensional data would be projected onto these 2 original dimension of A in Σ. In our example we have three the exponential term is the basis function corresponding to
Neighbors of a pixel – N4(p) is the general purpose computer that is used by us in our daily principal components which would be in 2 dimension with singular values: and 0. We only need to retain the non-zero each point F(k,l) in the Fourier space. This equation can be
Any pixel p(x, y) has two vertical and two horizontal life. minimum information loss. values, and hence we form the matrix interpreted as follows: the value of each point F(k,l) is
neighbors, given by • Image Processing Software: Image processing software is Method obtained by multiplying the spatial image with the
(x+1, y),(x-1, y),(x, y+1),(x, y-1) the software that includes all the mechanisms and algorithms [Link] the image corresponding base function and summing the result.
This set of pixels are called the 4-neighbors of P, and is that are used in image processing system. [Link] the image into 400 10 by 10 pixel blocks, so that the The basis functions are sine and cosine waves with increasing
denoted by N4(P). • Mass Storage: Mass storage stores the pixels of the images first block contains pixels in rows 1–10, columns 1–10, the frequencies. F(0,0) represents the DC component of the
Neighbors of a pixel – ND(p) during the second block contains pixels in rows 1–10, columns 11–20, image, corresponding to the average brightness, while F(N−1,
Any pixel p(x, y) has four diagonal neighbors, given by processing. and so on. Each block contains 100 pixel values and can be Note that Σ has the same dimension as our original matrix A. N−1) represents the highest frequency.
(x+1, y+1), (x+1, y-1), (x-1, y+1), (x-1 ,y-1) • Hard Copy Device: Once the image is processed then it is thought of as a 100-dimensional input vector, in total you Step 5: Form the matrix U We form the matrix U by In the case of digital images, which are discrete, the Discrete
This set is denoted by ND(p). stored in the hard copy device. It can be a pen drive or any have 400 such 100-dimensional input vectors. Fourier Transform (DFT) is used. This means that images may
Neighbors of a pixel – N8(p) external ROM device. [Link] the first PCA component of this data set (400 considering our modified form , take on values from a given domain. For example, in a basic
ND(p) and N4(p) are together known as 8-Neighbors and are • Image Display: It includes the monitor or display screen that items, 100 features) and project each input vectors onto that and isolating each column of U. B grayscale image, values typically range from zero to 255. As a
denoted by N8(p) displays the component — the result is one scalar value per input vector. ecause of the diagonal nature of Σ, this results in result, the Fourier Transform must also be discrete, giving rise
ND(p) U N4(p) = N8(p) processed images. [Link] the scalar values back as a reconstruction of the to the Discrete Fourier Transform.
What about when p(x,y) is a border pixel of the image ? • Network: Network is the connection of all the above original features, the result is one 100-dimensional vector per
Adjacency elements of the input vector. Draw the resulting picture: for each pixel block,
Let V be the set of intensity values used to define adjacency image processing system instead of the original pixel values, draw the approximated
For binary images à V = {1} values.
A particular grayscale image à V = {1,3,5,…,251,253,255} [Link] the same procedure for 2 components, 5, 10, 20, and 30
4-adjacency: Two pixels p and q with values from V are 4- PCA components.
adjacent if q is in the set N4(p). for each of the singular values. We have two singular values in
8-adjacency: Two pixels p and q with values from V are 8- our example, and we use them to form the following vectors:
adjacent if q is in the set N8(p).
m-adjacency: Two pixels p and q with values from V are m-
adjacent if,
q is in N4(p)
Path
set of pixels lying in some adjacency definition
4-adjacency à 4-path We then combine these column vectors to form the matrix:
8-adjacency à 8-path
m-adjacency à m-path
path length ?
Number of pixels involved
Connectivity Step 6: Rewrite matrix A as
Let Sà subset of pixels in an image
Two pixels p and q are said to be connected in S if there exist Step 6: Rewrite matrix A as
a path between them consisting entirely of pixels in S. Finally, we rewrite A using the equation
For any pixel p in S the set of pixels that are connected to it
in S is called connected component of S.
If S has only one connected component, then it is called
connected set.
Region:A connected set is also called a Region.
Two regions (let Ri and Rj) are said to be adjacent if their
union forms a connected set. Adjacent Regions or joint This decomposition provides a broken-down form of the
regions matrix A that has isolated the most important components
Regions that are not adjacent are said to be disjoint regions. from our original matrix. This returns a modification of our
4- and 8-adjacency is considered when referring to regions original matrix A in which the components are smaller in size,
(author) thus reducing the memory requirement in storing the
Discussing a particular region, type of adjacency must be information.
specified. Applications to Image Processing The process of Singular
Fig2.25d the two regions are adjacent only if 8-adjacency is Value Decomposition can be used in many applications,
considered including watermarking an image, computing weighted least
Boundary:The boundary (border or contour) of a region R is squares, and optimal prediction. Here we will consider how
the set of points that are adjacent to the points in the this process could be used to produce reduced image sizes.
complement of R. We begin by understanding that large images are formed by
Set of pixels in the region that have at least one background correspondingly large matrices, hence requiring a sizable
neighbor. amount of memory to store the image. By rewriting the image
The boundary of the region R is the set of pixels in the region in its broken-down form and removing the smaller singular
that have one or more neighbors that are not in R. values, we can form smaller matrices which would in turn
Inner Border: Border of Foreground require less memory storage. We would lose some refinement
Outer Border: Border of Background with each loss of a singular value, but overall, we would retain
If R happens to be entire Image?There is a difference between the overall image features.
boundary and edge in Digital Image Paradigm. The author
refers this discussion to chapter 10.
What is Image Enhancement? IMAGE COMPRESSION Wavelet coding Frequency domain filtering: Noise in images:
Image enhancement is the process of making images more Image compression is the art and science of reducing amount Like transform coding, wavelet coding is based on the premise These types of filters are used for this purpose- Image noise is random variation of brightness or color information in the
useful (such as making images more visually appealing, of data required to represent an image. Image compression is that using a linear transform (here a wavelet transform) will Band Reject Filters: images captured. It is degradation in image signal caused by external
bringing out specific features, removing noise from images used in many applications like televideo conferencing, remote result in transform coefficients that can be stored more It removes a band of frequencies about the origin of the [Link] containing multiplicative noise have the characteristic that
and highlighting interesting details in images). sensing, document and medical imaging, and facsimile efficiently than the pixels themselves. Due to the facts that Fourier transformer. the brighter the area the noisier it. But mostly it is additive. We can model
[Link] transmission (FAX). wavelets are computationally efficient and that the wavelet [Link] Band reject Filter: a noisy image asA(x,y) = H(x,y) + B(x,y) Where, A(x,y)= function of noisy
Spatial domain techniques manipuletes the pixels of an image Image Compression Model basis functions are limited in duration, subdivision of the An ideal band reject filter is given by the expression image, H(x,y)= function of image noise , B(x,y)= function of original image.
directly. This process happens in the image’s coordinate The following figure shows an image compression system is original image is Unnecessary. Wavelet coding typically Sources of Image noise:
system, also known as the spatial domain. composed of two distinct functional components: an encoder produces a more efficient compression than DCTbased
The term spatial domain refers to the aggregate of pixels and decoder. The encoder performs compression and decoder systems • While image being sent electronically from one place to
composing an image. Spatial domain methods are procedures performs the complementary operation of decompression. Objectively – the mean square error of wavelet-based another.
that operate directly on these pixels. Spatial domain processes Both operations can be performed in software. Input image is reconstructions are typically lower
will be denoted by the expression g (x, y) = T [f (x, y)] where fed into the encoder, which creates a compressed Subjectively - the blocking artifacts (characteristic of DCT- • Sensor heat while clicking an image.


f(x, y) is the input image, g(x, y) is the processed image, and T representation of the input. When the compressed based systems at high compression ratios) are not present in D(u,v)- the distance from the origin of the centered frequency
is an operator on f, defined over some neighborhood of (x, y). representation is presented to its complementary decoder, a wavelet reconstructions rectangle. With varying ISO Factor which varies with the capacity of
In addition, T can operate on a set of input images, such as reconstructed image is generated The choice of wavelet to use greatly affects the compression W- the width of the band camera to absorb light.
performing the pixel-by-pixel sum of K images for noise efficiency Do- the radial center of the frequency rectangle. Types of Image noise:
reduction. [Link] Band reject Filter: There are different types of image noise. They can typically be divided into
Spatial domain techniques can be subdivided into: 3 types.
• Point Operations (Intensity Transformations):
These operations involve applying the same
transformation to each pixel in a grayscale
image, based on its original pixel value and
independent of its location or neighboring
pixels. Learn more about Point Operation.
• Spatial Filters (or Mask, Kernel): The output Error-free compression Gaussian Band reject Filter:
value of these operations is dependent on the • Useful in application where no loss of information is
values of the function f(x,y) and its Mapper - transforms the image to a (non-visual) format tolerable. This maybe due to accuracy requirements, legal
neighborhood. Explore more on Spatial Filter. designed to reduce interpixel redundancies. The operation requirements, or less than perfect quality of original image.
Simple Intensity Transformations generally is reversible and may or may not reduce directly the • Compression can be achieved by removing coding and/or
1. Image Negatives: amount of data required to represent the image. In video interpixel redundancy. • Typical compression ratios
The negative of an image with gray levels in the range [0,L-1]is applications, the mapper uses previous video frames to achievable by lossless techniques is from 2 to 10.
Variable Length Coding 1. Gaussian Noise:
obtained by using the negative transformation shown in Fig. facilitate the removal of temporal redundancy. Gaussian Noise is a statistical noise having a probability density function
3.3, which is given by the expression • Quantizer - reduces psychovisual redundancies by -This is used to reduce coding redundancy. These filters are mostly used when the location of noise equal to normal distribution, also known as Gaussian Distribution. Random
s=L-1–r quantizing data deemed less important for visual -Coding redundancy is present in any image with a non- component in the frequency domain is known. Sinusoidal
uniform histogram (i.e. when all the graylevels are not equally Gaussian function is added to Image function to generate this noise. It is
interpretation (omitted for lossless compression) noise can be easily removed by using these kinds of filters also called as electronic noise because it arises in amplifiers or detectors.
• Symbol encoder - codes the data efficiently (typically using likely). because it shows two impulses that are mirror images of each
-Given an image with, say 256 graylevels, Source: thermal vibration of atoms and discrete nature of radiation of
some form of variablelength coding scheme) and aims to other about the origin. Of the frequency transform.
reduce coding redundancies. It generates a fixed or variable {a0,a1,,a255}={0,1,,255}. This is our set of source [Link] warm objects.
length code to represent the quantizer output and maps the each graylevel ak , we need its probability p(ak ) in the image.
output in accordance with the code. In many cases, a variable -This may be obtained from the image histogram: p(ak ) = nk
–length code is used. The shortest code words are assigned to /n, nk = # pixels with value ak , n = total # pixels.
the most frequently occurring quantizer output values- thus -To each graylevel ak , we need to assign a codeword (a binary
minimizing coding redundancy. • Future application string). Suppose lk is the length of codeword (= # bits
requirements may be unknown required to represent ak ) for symbol ak .
Thresholding. -Total number of bits required to represent the image is
In digital image processing, thresholding is the simplest
method of segmenting images. It plays a crucial role in image
processing as it allows for the segmentation and extraction of
important information from an image. By dividing an image Band pass Filter:
into distinct regions based on pixel intensity or pixel value, The function of a band pass filter is opposite to that of a band
thresholding helps distinguish objects or features of interest reject filter It allows a specific frequency band of the image to
from the background. This technique is widely used in various Naturally, we need an encoding scheme with Lavg as small as be passed and blocks the rest of frequencies. The transfer
Reversing the intensity levels of an image produces the applications such as object detection, image segmentation, possible. From Shannon’s theorem, we know that Lavg ≥ H(z). function of a band pass filter can be obtained from a
equivalent of a photographic negative. This type of processing and character recognition, enabling efficient analysis and As mentioned earlier, the Huffman procedure specifies a code corresponding band reject filter with transfer function
is particularly suited for enhancing white or gray detail interpretation of digital images. Additionally, image with H(z) ≤ Lavg < H(z) +1 Hbr(u,v) by using the equation
embedded in dark regions of an image, especially when the thresholding can enhance image quality by reducing noise and Bit-plane Coding Fig.4 Plot of Probability Distribution Function
black areas are dominant in size. improving overall visual clarity A grayscale image is decomposed into a series of binary The side image is a bell shaped probability distribution function which
2. Log Transformations: The general form of the log images and each binary image is compressed by some binary have mean 0 and standard deviation(sigma) 1.
transformation s = c log (1 + r) where c is a constant, and it is compression method. 2. Impulse Noise:
assumed that r ≥ 0. The shape of the log curve in Fig. 3 shows This removes coding and interpixel redundancy. These filters cannot be applied directly on an image because it Impulse Function: In the discrete world impulse function on a vale of 1 at a
that this transformation maps a narrow range of low gray- Bit-plane decomposition: may remove too much details of an image but these are single location and In continuous world impulse function is an idealised
level values in the input image into a wider range of output Given a grayscale image with 2m graylevels, each grayvalue effective in isolating the effect of an image of selected function having unit area.
levels. The opposite is true of higher values of input levels. We can be represented by m-bits, say (am−1,am−2, ,a1,a0). frequency bands.
would use a transformation of this type to expand the values The grayvalue r represented by (am−1,am−2, ,a1,a0) is given Notch Filters:
of dark pixels in an image while compressing the higher-level by the base 2 polynomial A notch filter rejects (or passes) frequencies in predefined
values. The opposite is true of the inverse log transformation. r = am−12m−1 + am−22m−2 + + a121 + a020 neighborhoods about a center frequency.
3. Power-Law Transformations Power-law transformations This bit representation can be used to decompose the Due to the symmetry of the Fourier transform notch filters
have the basic form s = c rγ grayscale image into m binary images (bit-planes). must appear in symmetric pairs about the origin. Fig.6 Impulse function in discrete world and continuous world
where c and γ are positive constants, Also can be represented Alternatively, one can use the m-bit Gray code (gm−1,gm−2, The transfer function of an ideal notch reject filter of radius 2.1 Types of Impulse Noise:
as ,g1,g0) to represent a given grayvalue. D0 with centers a (u0 ,v0) and by symmetry at (-u0 , v0) is There are three types of impulse noises. Salt Noise, Pepper Noise, Salt and
s = c (r+ε)γ Image Thresholding Techniques The Gray code (gm−1,gm−2, ,g1,g0) can be obtained from Pepper Noise.
An offset measurable when input is zero We see in Fig. 4 that These are widely used in various fields such as medical (am−1,am−2, ,a1,a0) by the following relationship: Salt Noise: Salt noise is added to an image by addition of random bright
curves generated with values of g>1 have exactly the opposite imaging, computer vision, and remote sensing. These gm−1 = am−1, and for 0 ≤ i ≤ m− 2, gi = ai ⊕ai+1 (with 255 pixel value) all over the image.
effect as those generated with values of g. techniques are essential for accurate image processing and where ⊕ denotes exclusive OR of bits. Pepper Noise: Salt noise is added to an image by addition of random dark
interpretation. They help to convert grayscale or color images The Gray code of successive graylevels differ at only one (with 0 pixel value) all over the image.
into binary images, separating the foreground from the position. Salt and Pepper Noise: Salt and Pepper noise is added to an image by
background, allowing for better segmentation and extraction → 01111111 (binary representation) 01000000 (Gray addition of both random bright (with 255 pixel value) and random dark
of features from an image, which is crucial for various code) (with 0 pixel value) all over the [Link] model is also known as data
applications in computer vision and pattern recognition. →10000000 (binary representation) 11000000 (Gray Ideal, butterworth, Gaussian notch filters drop noise because statistically it drop the original data values [5]. Source:
Global Thresholding code) Malfunctioning of camera’s sensor cell.
Global Thresholding is a widely used technique where a single 3. Poisson Noise:
threshold value is applied to an entire image. However, this The resulting binary images are then compressed (error-free). The appearance of this noise is seen due to the statistical nature of
technique may not be suitable for images with varying We will study a popular encoding scheme called run-length electromagnetic waves such as x-rays, visible lights and gamma rays. The x-
lighting conditions or complex backgrounds. To overcome this encoding (RLC). ray and gamma ray sources emitted number of photons per unit time.
limitation, adaptive thresholding techniques may be Transform Coding These rays are injected in patient’s body from its source, in medical x rays
employed, which adjust the threshold value locally based on In transform coding a linear transform is used to map the and gamma rays imaging systems. These sources are having random
the characteristics of each pixel's neighborhood. These image data into a set of transform coefficients (which are then fluctuation of photons. Result gathered image has spatial and temporal
techniques are particularly useful in scenarios where there is quantized and coded). For reasons of computational randomness. This noise is also called as quantum (photon) noise or shot
significant variation in illumination across different regions of complexity the image is subdivided into smaller subimages noise.
the image. before the transformation computation. The goal of the 4. Speckle Noise
-Simple thresholding is a basic technique that assigns a binary transformation process is to decorrelate (minimize the A fundamental problem in optical and digital holography is the presence of
value to each pixel based on a global threshold value. It is variance) the pixels of the subimages as much as possible. This speckle noise in the image reconstruction process. Speckle is a granular
effective when the image has consistent lighting conditions will result in a localization of the image information in a Inverse Filtering: noise that inherently exists in an image and degrades its quality. Speckle
Histogram Processing and a clear foreground-background separation. However, minimal number of transform coefficients - the The simplest approach to restoration is direct inverse filtering noise can be generated by multiplying random pixel values with different
when images contain varying lighting conditions or complex transformation coefficients with little data can then be more where we complete an estimate of the pixels of an image.
The histogram of a digital image with gray levels in the range backgrounds, adaptive thresholding techniques are more coarsely quantized or eliminated. The better information transform of the original image simply by dividing the Mean Filter in Image Processing
[0, L-1] is a discrete function h(rk)=nk, where rk is the k th gray suitable. These techniques dynamically adjust the threshold compaction, the better reconstruction approximations. transform of the degraded image G(u,v) by degradation Introduction
level and nk is the number of pixels in the image having gray value for each pixel based on its local neighborhood, allowing The following figure shows a typical block transform coding function H(u,v) Therefore, mean filter is one of the techniques which is used to reduce
level rk. Histograms are the basis for numerous spatial domain for better segmentation and accurate object detection. . system. The decoder noise of the images.
processing techniques. Histogram manipulation can be used Pros and Cons of Global Thresholding implements the inverse sequence of steps of the encoder, This is a local averaging operation and it is a one of the simplest linear
effectively for image enhancement. Histograms are simple to Gobal thresholding offers several advantages, including its which performs four relatively straightforward operations: filter. The value of each pixel is replaced by the average of all the values in
calculate in software and also lend themselves to economic simplicity and efficiency in determining a single threshold subimage decomposition, transformation, quantization, and the local neighborhood.
hardware implementations, thus making them a popular tool value for the entire image. It is particularly effective in coding. M x N input image is subdivided first into subimages of (a)Arithmetic Mean filter: It is the simplest mean filter. Let Sxy represents
for real-time image processing. The horizontal axis of each scenarios where the foreground and background regions have size n X n, which are then transformed to the set of coordinates in the sub image of size m*n centered at point (x,y).
histogram plot corresponds to gray level values, rk. The distinct intensity distributions. However, global thresholding We know that The arithmetic mean filter computes the average value of the corrupted
vertical axis corresponds to values of H(rk)=nk or p(rk)=nk/n if may not be suitable for images with complex intensity image g(x,y) in the area defined by Sxy. The value of the restored image f
the values are normalized. Thus, as indicated previously, these distributions or when there is significant variation in lighting at any point (x,y) is the arithmetic mean computed using the pixels in the
histogram plots are simply plots of h(rk)=nk versus rk or conditions across the image. Additionally, it may not region defined by Sxy.
p(rk)=nk/n versus rk. accurately segment objects or regions that have overlapping
Applications of Image Enhancement intensity values. Therefore
Deblurring Images: Helps to improve image clarity. Local (Adaptive) Thresholding
Contrast Adjustment: Enhances image detail visibility. Local thresholding addresses the limitations of global
Image Brightening: Increases the lightness of an image. thresholding by considering smaller regions within the image. Lossless predictive coding
Image Smoothing and Sharpening: It calculates a threshold value for each region based on its The following figure shows the basic components of lossless This operation can be using a convolution mask in which all coefficients
Smoothing filters help reduce and suppress image noise, with local characteristics, such as mean or median intensity. This predictive coding system. The system consist of an encoder have value 1/mn A mean filter smoothes local variations in image Noise is
common types including average smoothing, Gaussian approach allows for better adaptability to varying lighting and decoder, each containing an identical predictor. As reduced as a result of blurring. For every pixel in the image, the pixel value
smoothing, and adaptive smoothing. Discover more conditions and complex intensity distributions, resulting in successive samples of discrete time input signal, f(n), are From the above equation we observe that we cannot recover is replaced by the mean value of its neighboring pixels with a weight .This
about smoothing filters. more accurate segmentation of objects or regions with introduced to the encoder, the predictor generates the the undegraded image exactly because N(u,v) is a random will resulted in a smoothing effect in the image.
Sharpening filters enhance edges by eliminating blur. Find overlapping intensity values. However, local thresholding may anticipated value of each sample based on a specified number function whose Fourier transform is not known. One approach (b)Geometric Mean filter: An image restored using a geometric mean filter
more about sharpening filters. require more computational resources and can be sensitive to of past samples. The output of the predictor is then rounded to get around the zero or small-value problem is to limit the is given by the expression
Noise Removal: noise or uneven illumination within the image, which can to the nearest integer, The prediction error filter frequencies to values near the origin.
Noise can be introduced to images during capture, printing, or affect the overall performance of the segmentation algorithm. We know that H(0,0) is equal to the average values of h(x,y).
transmission. It can be identified in image processing by Mean and Gaussian Adaptive Thresholding By Limiting the analysis to frequencies near the origin we
intensity variance between neighboring pixels. Noise removal Two commonly used methods in image processing are Mean reduce the probability of encountering zero values.
techniques help decrease noise visibility by smoothing the and Gaussian Adaptive Thresholding. Mean adaptive Wiener filtering
image using linear or non-linear filters. 1 thresholding calculates the threshold value for each sub- The inverse filtering approach has poor performance. The
Grayscale Image Histogram Equalization: region by taking the average intensity of all pixels within that wiener filtering approach uses the degradation function and Here, each restored pixel is given by the product of the pixel in the sub
Histogram equalization refers to a transformation where an region. On the other hand, Gaussian adaptive statistical characteristics of noise into the restoration process. image window, raised to the power 1/mn. A geometric mean filters but it
output image has an approximately uniform distribution of thresholding uses a weighted average of pixel intensities, The objective is to find an estimate of the uncorrupted to loose image details in the process.
pixels at each gray level. Dive into the details about grayscale giving more importance to pixels closer to the center of the image f such that the mean square error between them is (c)Harmonic Mean filter: The harmonic mean filtering operation is given
image histogram equalization. sub-region. These methods are effective in enhancing image minimized. by the expression
quality and improving accuracy in tasks such as object The error measure is given by
detection or segmentation.
Need of Image Thresholding
Image thresholding is necessary to separate the object or the The decoder shown in second part of the figure reconstruct
area of interest from the background of an image. This e(n) from the received variable-length code words and The harmonic mean filter works well for salt noise but fails for pepper
technique helps in enhancing the features of a thresholding performs the inverse operation to decompress or recreate the Where E{.} is the expected value of the argument. noise. It does well with Gaussian noise also.
image and makes it easier to detect or recognize objects in an original input sequence. We assume that the noise and the image are uncorrelated (d)Order statistics filter: Order statistics filters are spatial filters whose
image. one or the other has zero mean. response is based on ordering the pixel contained in the image area
The gray levels in the estimate are a linear function of the encompassed by the filter. The response of the filter at any point is
It is also useful in thresholding image segmentation, which is levels in the degraded image. determined by the ranking result.
the process of dividing an image into multiple segments or (e)Median filter: It is the best order statistic filter; it replaces the value of a
regions with similar properties. Lossy predictive coding pixel by the median of gray levels in the Neighborhood of the pixel.
For example, in medical imaging, thresholding is used to In this lossy predictive coding, we add quantizer to the lossless
identify tumours or abnormal tissues in a scan. In industrial predictive coding model introduced earlier and examine the
inspection, it is used to detect defects in products or to check trade –off between reconstruction accuracy and compression
the quality of goods. performance within the context of spatial predictors.
In machine vision, thresholding is used to identify objects or As it shown in following figure the quantizer, which replaces The original of the pixel is included in the computation of the median of
obstacles in an image and to guide the movement of robots or the nearest integer function of the error-free encoder, is the filter are quite possible because for certain types of random noise, the
autonomous vehicles. inserted between the symbol encoder and the point at which provide excellent noise reduction capabilities with considerably less
Overall, thresholding in image processing is a crucial the prediction error is formed. It maps the prediction error blurring then smoothing filters of similar size. These are effective for
technique in image processing that has a wide range of into a limited range of outputs, denoted e(n) , which establish bipolar and unipolar impulse noise.
applications in various fields. the amount of compression and distortion that occurs. For a Max and Min filter:
Real-world applications lossy encoder’s predictor within the feedback loop, Using the l00th percentile of ranked set of numbers is called
Object Detection: By setting a threshold value, objects can be the max filter and is given by the equation
separated from the background, allowing for more accurate Where H(u,v)= degradation function
and efficient object detection. The second part of the figure shows the lossy decoder. H*(u,v)=complex conjugate of H(u,v)
Medical Images: Image thresholding can be used to segment | H(u,v)|2=H* (u,v) H(u,v)
different structures or abnormalities for diagnosis and analysis Sn(u,v)=|N(u,v)|2= power spectrum of the noise
in medical imaging. Sf(u,v)=|F(u,v)|2= power spectrum of the underrated image
Quality Control: Image thresholding plays a crucial role in The power spectrum of the under graded image is rarely It is used for finding the brightest point in an image. Pepper
quality control processes, such as inspecting manufactured known. An approach used frequently when these quantities noise in the image has very low values; it is reduced by max
products for defects or ensuring consistency in color and are not known or cannot be estimated then the expression filter using the max selection process in the sublimated area
texture of a color image. used is sky.
Object Segmentation: Image thresholding is also commonly The 0th percentile filter is min filter.
used in computer vision tasks such as object segmentation,
where it helps to separate foreground objects from the
background. This enables more accurate and efficient
detection of objects within an image.
Noise Reduction: Thresholding can be utilized for noise This filter is useful for flinging the darkest point in image. Also,
reduction, as it can help to eliminate unwanted artifacts or it reduces salt noise of the min operation.
disturbances in an image. Where K is a specified constant. Midpoint filter:
Edge Detection: Image thresholding aids in identifying and The midpoint filter simply computes the midpoint between
highlighting the boundaries between different objects or the maximum and minimum values in the area encompassed
regions within an image with edge detection algorithms. by

It comeliness the order statistics and averaging .This filter


works best for randomly distributed noise like Gaussian or
uniform noise.
Band Reject Filters: It removes a band of frequencies about the origin of
the Fourier transformer. Ideal Band reject Filter: An ideal band reject filter
is given by the expression
Spatial filtering with a template Frequency Domain Filtering Adaptive Filters: What is Data Compression? Difference between Low pass filter and High pass filter
The filtering process is to move the filter point-by-point in the Filtering techniques in frequency domain are based on adaptive filters are also Digital filters that change their coefficients with Data compression is a technique used to reduce the size of IntrWhen it comes to processing signals, filtering is a key
image function f (x, y) so that the center of the filter coincides modifying the Fourier transform to achieve a specific objective the intention of bringing the filter closer to its optimal state. A cost data files. This process involves encoding information using aspect that helps in shaping the characteristics of the signal.
with the point (x, y). At each point (x, y), the filter’s response and then computing the inverse DFT to get us back to the function, typically the mean square of the error signal between the fewer bits than the original representation. The main goal of Low-pass and high-pass filters are two commonly used types
is calculated based on the specific content of the filter and image domain. Steps involved in the process of filtering in the adaptive filter’s output and the desired signal, serves as the optimization data compression is to save storage space or reduce the time of filters that work in opposite ways to filter signals. Low-pass
through a predefined relationship called ‘template’. frequency domain are as follows. criterion. The mean square error (MSE) converges to its minimal value as required to transmit data over networks. filters, as the name suggests, allow low-frequency signals to
If the pixel in the neighborhood is calculated as a linear Compute the Fourier Transform of the image the filter adjusts its coefficients. The coefficients have converged to a What is Lossy Compression? pass through while attenuating high-frequency signals. On the
operation, it is also called ‘linear spatial domain filtering’, Multiply the result by filter transfer function solution and the filter has been modified at this point. The desired signal, Lossy Compression reduces file size by permanently removing other hand, high-pass filters allow high-frequency signals to
otherwise, it’s called ‘nonlinear spatial domain filtering’. Take the inverse transform d(k), is said to be very closely matched by the filter output, y(k). The filter some of the original data. It’s commonly used when a file can pass through while attenuating low-frequency signals.
Figure 2.3.1 shows the process of spatial filtering with a 3 × 3 adjusts to the new environment by generating a new set of coefficients for afford to lose some data or if storage space needs to be Low pass filter: Low pass filter is the type of frequency
template (also known as a filter, kernel, or window). the new data when the characteristics of the input data are altered, a significantly freed up. domain filter that is used for smoothing the image. It
Smoothing Filters Advantages of Lossy Compression attenuates the high-frequency components and preserves the

process that is referred to as the “filter environment.”
Image smoothing is a digital image processing technique that Smaller File Sizes: Lossy compression low-frequency components.
reduces and suppresses image noises. In the spatial domain, significantly reduces file sizes, making it ideal High pass filter: High pass filter is the type of frequency
neighborhood averaging can generally be used to achieve the for web use and faster loading times. domain filter that is used for sharpening the image. It
purpose of smoothing. Commonly seen smoothing filters • Widely Supported: Many tools and software attenuates the low-frequency components and preserves the
include average smoothing, Gaussian smoothing, and adaptive support lossy formats (e.g., JPEG for high-frequency components.
smoothing. images, MP3 for audio). Applications of Low-Pass and High-Pass Filters:
Smoothing Spatial Filter • Efficient for Multimedia: Effective for Low-pass and high-pass filters find applications in a variety of
Smoothing filter is used for blurring and noise reduction in the compressing multimedia files without fields including audio processing, image processing,
image. Blurring is pre-processing steps for removal of small noticeable quality loss. communication systems, and biomedical signal processing.
details and Noise Reduction is accomplished by blurring. Disadvantages of Lossy Compression Understanding the characteristics of these filters and their
Types of Smoothing Spatial Filter • Quality Degradation: Due to data removal, applications is essential for signal-processing engineers and
1. Linear Filter (Mean Filter) Summary of steps involved for filtering in the Frequency lossy files may exhibit reduced quality. researchers.
2. Order Statistics (Non-linear) filter Domain • Not Suitable for Critical Data: Inappropriate for similarities between the two filters:
These are explained as following below. -Given an input f(x,y) of size M X N, obtain the padding situations where data integrity is crucial. Both filters are used to remove unwanted frequency
[Link] Filter: Linear spatial filter is simply the average of the parameters P and Q. Typically, we select P = 2M and Q= 2N. Application of Adaptive Filter: What is Lossless Compression? components from a signal.
pixels contained in the neighborhood of the filter mask. The -Form a padding image, fp (x, y), of size P X Q by appending 1. System Identification: Identifying Unknown Systems Lossless compression reduces file size by removing Both filters have a cut-off frequency, which is the frequency at
idea is replacing the value of every pixel in an image by the the necessary number of zeros to f(x, y). Using an Adaptive Filter- Identifying an unknown unnecessary metadata without any discernible loss in picture which the filter begins to attenuate the signal.
average of the grey levels in the neighborhood define by the -Multiply fp (x, y) by (-1)x+y to center its transform system, such as the response of an unknown quality. The original data can be perfectly reconstructed after The steepness of the cut-off slope depends on the order of
filter mask. Below are the types of mean filter: -Compute the DFT, F(u, v), of the image from step 3. communications channel or the frequency response of decompression. the filter, with higher-order filters having steeper slopes.
-Averaging filter: It is used in reduction of the detail in image. -Generate a real, symmetric filter function, H(u, v), of size P X Advantages of Lossless Compression Both filters can introduce phase shifts, which can affect the

an auditorium, to select fairly distinct applications is one
All coefficients are equal. Q with center at coordinates (P/2, Q/2). From the product common application of adaptive filters. Channel No Quality Loss: Lossless compression time-domain characteristics of the signal.
-Weighted averaging filter: In this, pixels are multiplied by G(u, v) = H(u, v) F(u, V) using array multiplication; that is, G(i, identification and echo cancellation are two additional maintains original quality during compression Both filters are used in a variety of applications including
different coefficients. Center pixel is multiplied by a higher k) = H(i, k) F(i, k). and decompression. audio processing, image processing, communication systems,

applications.
value than average filter. -Obtain the processed image; 2. Using an Adaptive Filter to Remove Noise from an Suitable for Text and Archives: Ideal for text- and biomedical signal processing.
[Link] Statistics Filter: It is based on the ordering the pixels based files, software installations, and backups. Difference between Low pass filter and High pass filter:

Unknown System: Noise or Interference Cancellation- In
contained in the image area encompassed by the filter. It commotion crossing out, versatile channels let you Minor File Size Reduction: Reduces file size
replaces the value of the center pixel with the value eliminate clamor from a sign continuously. Noise and without compromising quality significantly. Low pass filter High pass filter
determined by the ranking result. Edges are better preserved -Obtain the final processed result, g(x, y), by extracting the M Disadvantages of Lossless Compression

desired information are combined here into the desired
in this filtering. Below are the types of order statistics filter: X N region from the top, left quadrant of gp (x, y). signal, the one to be cleaned. Feed the adaptive filter a Larger Compressed Files: Compared to lossy
-Minimum filter: 0th percentile filter is the minimum filter. Smoothing Frequency Domain Filters formats they compressed larger files.

signal n'(k) that is correlated to the noise to be removed
The value of the center is replaced by the smallest value in the Smoothing is achieved in the frequency domain by dropping from the desired signal to get rid of the noise. Less Efficient for Multimedia: Not as effective It is used for smoothing It is used for sharpening
window. out the high frequency components. The basic model for 3. Identification of an Inverse Response to an Unknown for multimedia files the image. the image.
-Maximum filter: 100th percentile filter is the maximum filter. filtering is: System via Inverse System- adaptive filter becomes the Difference between Lossy Compression and Lossless
The value of the center is replaced by the largest value in the G(u,v) = H(u,v)F(u,v) inverse of the unknown system as e(k) decreases when Compression
window. where F(u,v) is the Fourier transform of the image being the unknown system is placed in series with it. In order
-Median filter: Each pixel in the image is considered. First filtered and H(u,v) is the filter transform function. to keep the data at the summation synchronized, the Lossy Compression Lossless Compression
neighboring pixels are sorted and original values of the pixel is Low pass filters – only pass the low frequencies, drop the high procedure necessitates the addition of a delay to the It attenuates the high It attenuates the low
replaced by the median of the list. ones. Ideal Low Pass Filter Changing the distance changes the desired signal d(k) path, as depicted in the figure. The frequency. frequency.
Average Smoothing behaviour of the filter. The transfer function for the ideal low system remains causal when the delay is added.
First, let’s take a look at the smoothing filter in its simplest pass filter can be given as: 4. A Periodic Signal’s Future Values Can Be Lossy compression is While Lossless
form — average template and its implementation. 1 if D(u, v) D0 Predicted Through Prediction- In order to predict the method which Compression does not
H (u, v) signals, you must make important assumptions. Assume eliminate the data eliminate the data which Low frequency is High frequency is
0 if D(u, v) D0 that the signal is periodic and either steady or slowly which is not noticeable. is not noticeable. preserved in it. preserved in it.
where D0 is a positive constant and D(u,v) is the distance changing over time.
between a point (u, v) in the frequency domain and the centre Use of Adaptive Filter:
of the frequency rectangle; that is, Modern digital signal processing (DSP) products use adaptive
D(u, v) = [(u - M / 2)2 + (v - N / 2)2 ]^1/ 2 filters extensively in applications like active noise control
Where, as before, P and Q are the padded sizes. (ANC), adaptive control systems, telephone echo cancellation, In Lossy compression, A While in Lossless It allows the frequencies It allows the frequencies
The name ideal indicates that all frequencies on or inside a noise cancellation, communications channel equalization, and file does not restore or Compression, A file can below cut off frequency above cut off frequency
circle of radius D0 are passed without attenuation, where as biomedical signal amplification. rebuilt in its original be restored in its original to pass through it. to pass through it.
The points in the 3 × 3 neighborhood centered on the point (x, all frequencies outside the circle are completely attenuated. form. form.
y) are altogether involved in determining the (x, y) point pixel The ideal lowpass filter is rapidly symmetric about the origin,
in the new image ‘g’. All coefficients being 1 means that they which means that the filter is completely defined by radial
contribute the same (weight) in the process of calculating the cross section by 3600 yields the filter in 2-D. It consists of resistor It consists of capacitor
g(x, y) value. The last coefficient, 1/9, is to ensure that the In Lossy compression, But Lossless Compression that is followed by that is followed by a
sum of the entire template elements is 1. This keeps the new Data’s quality is does not compromise the capacitor. resistor.
image in the same grayscale range as the original image (e.g., compromised. data’s quality.
[0, 255]). Such a ‘w’ is called an average template.
How it works?
In general, the intensity values of adjacent pixels are similar,
and the noise causes grayscale jumps at noise points. It helps in removal of It helps in removal of
However, it is reasonable to assume that occasional noises do For an ILPF cross section, the point of transition between Lossy compression But Lossless Compression aliasing effect. noise.
not change the local continuity of an image. Take the image H(u,v) = 1 and H(u, v) = 0 is called the cutoff frequency. reduces the size of does not reduce the size
below for example, there are two dark points in the bright Butterworth Lowpass data. of data.
area. Filters The transfer function of a Butterworth low pass filter
Gaussian Smoothing of order n with cut-off frequency at distance D0 from the
The average smoothing treats the same to all the pixels in the origin is defined as: G(u, v) = H(u, v) . F(u, v) H(u, v) = 1 – H'(u, v)
neighborhood. In order to reduce the blur in the smoothing Algorithms used
process and obtain a more natural smoothing effect, it is in Lossy compression Algorithms used
natural to think to increase the weight of the template center are: Transform in Lossless compression
point and reduce the weight of distant points. So that the new coding, Discrete Cosine are: Run Length
center point intensity is closer to its nearest neighbors. The Transform, Discrete Encoding, Lempel-Ziv-
Gaussian template is based on such consideration. Wavelet Transform, Welch, Huffman Coding,
The commonly used 3 × 3 Gaussian template is shown below. fractal compression Arithmetic encoding etc.
etc.

Lossy compression is Lossless Compression is


used in Images, audio, used in Text, images,
Unlike the ILPF, the BLPF transfer function does not have video. sound.
sharp discontinuity that gives a clear cutoff between passed
and filtered frequencies.
Sharpening Filters Gaussian Lowpass Inverse Filtering: What are Multi-resolution Expansions?
Image sharpening filters highlight edges by removing blur. It Filters Gaussian lowpass filters (GLPFs) of two dimensions is Inverse filtering is a technique used in image restoration to Multi-resolution expansions refer to techniques that
enhances the grayscale transition of an image, which is the given by remove the effects of a known degradation process, such as represent images at various levels of detail. These techniques
opposite of image smoothing. The arithmetic operators of blurring or noise. It involves applying a filter that is the inverse decompose an image into a sequence of progressively coarser
smoothing and sharpening also testifies the fact. While linear of the degradation filter to restore the original image. approximations plus a set of detail images at each level. The
smoothing is based on the weighted summation or integral Applications in Image Restoration: most common multi-resolution technique is the wavelet
operation on the neighborhood, the sharpening is based on Where D(u,v) is the distance from the centre of the frequency 1. Deblurring: Inverse filtering can be used to remove blurring transform.
the derivative (gradient) or finite difference. rectangle. 𝜎 is a measure of spread about the centre By letting caused by camera motion, lens aberrations, or atmospheric Key Concepts
How to distinguish noises and edges still matters in 𝜎 = D0 , The transfer function of a Gaussian lowpass filter is distortion. Pyramidal Representation:
sharpening. The difference is that, in smoothing we try to defined as: 2. Noise Reduction: Inverse filtering can be used to remove -Gaussian Pyramid: Each level is a smoothed and subsampled
smooth noise and ignore edges and in sharpening we try to noise added to an image during acquisition or transmission. version of the previous one. Used for reducing the image size
enhance edges and ignore noise. 3. Image Sharpening: Inverse filtering can be used to enhance while maintaining important structures.
Some applications of where sharpening filters are used image details and correct for losses due to sensor or lens -Laplacian Pyramid: Stores the difference between levels in a
include: limitations. Gaussian pyramid, capturing the detail lost during smoothing
Medical image visualization Wiener Filtering: and subsampling.
Photo enhancement Wiener filtering is a type of inverse filtering that uses a Wavelet Transform:
Industrial defect detection minimum mean square error (MMSE) approach to restore Provides a multi-resolution analysis by decomposing the
Autonomous guidance in military systems images degraded by noise and blurring. image into a set of basis functions called wavelets.
There are a couple of filters that can be used for sharpening. Advantages: Can be efficiently implemented using filter banks, leading to a
One of the most popular filters is Laplace operator. It is based Sharpening in the Frequency Domain Filters using highpass 1. Optimal Restoration: Wiener filtering provides the optimal hierarchy of image resolutions and detail coefficients.
on second order differential. filter restoration result in the MMSE sense. Applications:
The corresponding filter template is as follows: Edges and fine detail in images are associated with high 2. Flexibility: Wiener filtering can be used for various types of -Compression: Multi-resolution representations are essential
frequency components hence image sharpening can achieved degradation, including noise and blurring. in image compression algorithms, such as JPEG2000, where
in the frequency domain by highpass filtering, which 3. Efficient: Wiener filtering can be computationally efficient, wavelets are used to achieve high compression ratios with
attenuates the low frequency components without disturbing especially for large images. minimal loss of quality.
high frequency information in the Fourier transform. High Limitations: -Denoising: Noise can be isolated and removed more
pass filters – only pass the high frequencies, drop the low 1. Requires Knowledge of Degradation: Wiener filtering effectively at different scales, preserving important image
ones High pass frequencies are precisely the reverse of low requires knowledge of the degradation process, including the features.
pass filters, so: point spread function (PSF) and noise power spectrum. -Feature Extraction: Features like edges can be detected more
Hhp(u, v) = 1 – Hlp(u, v) 2. Sensitive to Noise: Wiener filtering can be sensitive to robustly across scales, improving object recognition and
With the sharpening enhancement, two numbers with the noise, especially if the noise power spectrum is not accurately tracking.
same absolute value represent the same response, so w1 is estimated. -Image Fusion: Combining images from different sources (e.g.,
equivalent to the following template w2: Ideal High Pass Filters 3. May Introduce Artifacts: Wiener filtering can introduce multi-sensor data) can be done more effectively at multiple
Ideal High Pass Filters The ideal high pass filter is given by: artifacts, such as ringing or overshoot, especially if the PSF is resolutions.
not accurately estimated. Benefits
In summary, inverse filtering and Wiener filtering are powerful -Efficiency: Multi-resolution representations enable efficient
techniques for image restoration, but they require knowledge algorithms for processing images. Coarse levels of resolution
of the degradation process and can be sensitive to allow for faster computations, while fine levels provide
noise and artifacts. detailed analysis.
Where D0 is the cut off frequency. Sub-band coding -Flexibility: They allow for adaptive processing, where
Sub-band coding is a technique used in digital image different parts of the image can be processed at different
processing to compress and decompress images. Here's a resolutions.
Taking a further look at the structure of the Laplacian brief overview: -Robustness: Noise and other artifacts can be better managed
template, we see that the template is isotropic for a 90- What is Sub-band Coding? by analyzing the image at multiple scales.
degree rotation. Laplace operator performs well for edges in Sub-band coding is a method of dividing an image into Example: Wavelet Transform in Detail
the horizontal direction and the vertical direction, thus multiple sub-bands, each representing a specific frequency In the wavelet transform, an image is decomposed into a set
avoiding the hassle of having to filter twice. range. This allows for efficient compression and of sub-bands corresponding to different frequency
Sharpening Spatial Filter reconstruction of the image. components. For a 2D image, this typically involves:
It is also known as derivative filter. The purpose of the Butterworth High Pass Filters How does it work? Low-pass filtering: Captures the approximate, low-frequency
sharpening spatial filter is just the opposite of the smoothing The Butterworth high pass filter is given as: 1. Decomposition: The image is divided into sub-bands using content of the image.
spatial filter. Its main focus in on the removal of blurring and filters (e.g., wavelet transforms). High-pass filtering: Captures the detailed, high-frequency
highlight the edges. It is based on the first and second order 2. Quantization: Each sub-band is quantized, reducing the content in horizontal, vertical, and diagonal directions.
derivative. precision of the coefficients. Subsampling: Reduces the size of the filtered images to form
First Order Derivative: 3. Entropy Coding: The quantized coefficients are encoded the next level of the pyramid.
Must be zero in flat segments. n is the order and D0 is the cut off distance as before. using entropy coding (e.g., Huffman coding). The process can be repeated to further decompose the
Must be non zero at the onset of a grey level step. 4. Compression: The encoded coefficients are compressed, approximation sub-band, resulting in a multi-level
Must be non zero along ramps. reducing the image size. decomposition.
First order derivative in 1-D is given by: Advantages
f' = f(x+1) - f(x) 1. Efficient compression: Sub-band coding can achieve high
Second Order Derivative: compression ratios while maintaining image quality.
Must be zero in flat areas. 2. Progressive transmission: The image can be transmitted
Must be non zero at the onset and end of a ramp. progressively, starting with the low-frequency sub-band.
Must be zero along ramps. 3. Robustness to noise: Sub-band coding can be more robust
Second order derivative in 1-D is given by: to noise and errors.
f'' = f(x+1) + f(x-1) - 2f(x) Applications
1. Image compression: Sub-band coding is used in image
compression standards like JPEG 2000.
Gaussian High Pass Filters 2. Image denoising: Sub-band coding can be used to remove
The Gaussian high pass filter is given as: noise from images.
3. Image fusion: Sub-band coding can be used to fuse images
from different sources.
Where D0 is the cut off distance as before.

You might also like