DIP Chapter 4
DIP Chapter 4
- Instead of storing all the intensity values of all possible points in the image
we try to take samples of the image on a regular grid.
- The grid is superimposed on this particular image and what we do is we
take samples, image samples at various grid points.
- Typically for image processing applications, the image size which is used is
either 256 x 256 elements, 512 x 512 elements, 1 K x 1 K elements and so
on.
- Intensity discretization by Quantization
- After sampling, at every point the value of that particular sample is again
continuous. So it can assume any of the infinite possible values, which again
cannot be represented in a digital computer.
- Quantization is done using 8 bits for black and white image and using 24
bits for color image ( RGB planes).
Desired Output after
sampling and quantization
• Image should be represented in a form of finite two dimensional matrix like
this. So this is a matrix representation of an image and this matrix has got
finite number of elements.
Image Digitization
• Image Digitization= Sampling + Quantization
Image Digitization
Types of Images
Image Digitization
Advantage of Digitization
• Storage and retrieval of digital images are faster as well as cheaper
than analog images.
• Diagonal Neighbourhood
Relationship between Pixels
• Neighbourhood of Pixels
• 8 Neighbourhood
Connectivity
It is used for establishing boundaries of objects and components of regions
in an image.
Connectivity
Connectivity
Connectivity
Example for solving
Example for solving
Example for solving
Example for solving
Image File Formats
• BMP ( Bit Mapped Graphic Image)
• Developed by Microsoft
• Can save both monochrome and colour image
• Very Good quality images
• Occupy lot of memory
• Eg- wall paper images, Image editing
• TIFF ( Tagged Image File Format)
• Developed by ADOBE
• Large file size. Hence, Occupy lot of space.
• Very high Quality Images
• Because of large sizes, plugins are generally required to display them on
internet sites
• May or may not be compressed (Uses Huffman coding and LZW algorithm
for compression)
• Eg- OCR, HD imaging
• JPEG ( Joint Photographic Expert Group)
• Compressed Images
• Occupy very little space
• Uses DCT for compression
• Lossy compression algorithm
• Quality is not good
Distance Measures
• Euclidean Distance- Given two points p (x,y) and q(s,t)
• City Block Distance( Manhattan Distance): Given two points p (x,y) and
q(s,t)
𝑫𝟒 (p , q)= 𝐱 − 𝐬 + 𝐲 − 𝐭
𝑫𝟖 (p , q)= max( 𝐱 − 𝐬 + 𝐲 − 𝐭 )