Chapter - 2 : IMAGE ENHANCEMENT

Similar documents
Segmentation algorithm for monochrome images generally are based on one of two basic properties of gray level values: discontinuity and similarity.

Chapter 3: Intensity Transformations and Spatial Filtering

Vivekananda. Collegee of Engineering & Technology. Question and Answers on 10CS762 /10IS762 UNIT- 5 : IMAGE ENHANCEMENT.

CHAPTER 3 IMAGE ENHANCEMENT IN THE SPATIAL DOMAIN

Lecture 4 Image Enhancement in Spatial Domain

Image Enhancement in Spatial Domain. By Dr. Rajeev Srivastava

In this lecture. Background. Background. Background. PAM3012 Digital Image Processing for Radiographers

Babu Madhav Institute of Information Technology Years Integrated M.Sc.(IT)(Semester - 7)

Digital Image Processing

Basic relations between pixels (Chapter 2)

IMAGE ENHANCEMENT in SPATIAL DOMAIN by Intensity Transformations

Image Enhancement: To improve the quality of images

Filtering and Enhancing Images

Ulrik Söderström 16 Feb Image Processing. Segmentation

Motivation. Intensity Levels

EECS 556 Image Processing W 09. Image enhancement. Smoothing and noise removal Sharpening filters

Intensity Transformation and Spatial Filtering

UNIT - 5 IMAGE ENHANCEMENT IN SPATIAL DOMAIN

EELE 5310: Digital Image Processing. Lecture 2 Ch. 3. Eng. Ruba A. Salamah. iugaza.edu

Digital Image Processing, 2nd ed. Digital Image Processing, 2nd ed. The principal objective of enhancement

EELE 5310: Digital Image Processing. Ch. 3. Eng. Ruba A. Salamah. iugaza.edu

Digital Image Processing. Image Enhancement in the Spatial Domain (Chapter 4)

EEM 463 Introduction to Image Processing. Week 3: Intensity Transformations

Sampling and Reconstruction

Islamic University of Gaza Faculty of Engineering Computer Engineering Department

Image Enhancement in Spatial Domain (Chapter 3)

Topic 4 Image Segmentation

Motivation. Gray Levels

Lecture 4: Spatial Domain Transformations

Digital Image Processing. Prof. P. K. Biswas. Department of Electronic & Electrical Communication Engineering

IMAGE ENHANCEMENT IN THE SPATIAL DOMAIN

Image Processing. Traitement d images. Yuliya Tarabalka Tel.

Lecture 6: Edge Detection

IMAGING. Images are stored by capturing the binary data using some electronic devices (SENSORS)

Digital Image Processing. Lecture # 3 Image Enhancement

2D Image Processing INFORMATIK. Kaiserlautern University. DFKI Deutsches Forschungszentrum für Künstliche Intelligenz

Image Processing. BITS Pilani. Dr Jagadish Nayak. Dubai Campus

Intensity Transformations and Spatial Filtering

Hom o om o or o phi p c Processing

Edge and local feature detection - 2. Importance of edge detection in computer vision

Point operation Spatial operation Transform operation Pseudocoloring

(10) Image Segmentation

Biometrics Technology: Image Processing & Pattern Recognition (by Dr. Dickson Tong)

Lecture 4. Digital Image Enhancement. 1. Principle of image enhancement 2. Spatial domain transformation. Histogram processing

Introduction to Digital Image Processing

IT Digital Image ProcessingVII Semester - Question Bank

Chapter 10 Image Segmentation. Yinghua He

Lecture 3 - Intensity transformation

INTENSITY TRANSFORMATION AND SPATIAL FILTERING

Fundamentals of Digital Image Processing

Image processing. Reading. What is an image? Brian Curless CSE 457 Spring 2017

Chapter 10: Image Segmentation. Office room : 841

CS 490: Computer Vision Image Segmentation: Thresholding. Fall 2015 Dr. Michael J. Reale

1.Some Basic Gray Level Transformations

Computer Vision. Image Segmentation. 10. Segmentation. Computer Engineering, Sejong University. Dongil Han

CS334: Digital Imaging and Multimedia Edges and Contours. Ahmed Elgammal Dept. of Computer Science Rutgers University

Digital Image Processing

Selected Topics in Computer. Image Enhancement Part I Intensity Transformation

Computer Vision I - Basics of Image Processing Part 1

Other Linear Filters CS 211A

C E N T E R A T H O U S T O N S C H O O L of H E A L T H I N F O R M A T I O N S C I E N C E S. Image Operations I

Lecture 7: Most Common Edge Detectors

What will we learn? Neighborhood processing. Convolution and correlation. Neighborhood processing. Chapter 10 Neighborhood Processing

CS4442/9542b Artificial Intelligence II prof. Olga Veksler

Lecture 2 Image Processing and Filtering

CoE4TN4 Image Processing. Chapter 5 Image Restoration and Reconstruction

Part 3: Image Processing

Point and Spatial Processing

Original grey level r Fig.1

EXAM SOLUTIONS. Image Processing and Computer Vision Course 2D1421 Monday, 13 th of March 2006,

Digital Image Processing

Digital Image Processing

EE795: Computer Vision and Intelligent Systems

CS4442/9542b Artificial Intelligence II prof. Olga Veksler

Broad field that includes low-level operations as well as complex high-level algorithms

School of Computing University of Utah

Digital Image Processing

Chapter 1. Linear Equations and Straight Lines. 2 of 71. Copyright 2014, 2010, 2007 Pearson Education, Inc.

Chapter 3 Image Enhancement in the Spatial Domain

Digital Image Fundamentals

Digital Image Analysis and Processing

ECG782: Multidimensional Digital Signal Processing

Sharpening through spatial filtering

3. (a) Prove any four properties of 2D Fourier Transform. (b) Determine the kernel coefficients of 2D Hadamard transforms for N=8.

Basic Algorithms for Digital Image Analysis: a course

Lecture #13. Point (pixel) transformations. Neighborhood processing. Color segmentation

Noise Model. Important Noise Probability Density Functions (Cont.) Important Noise Probability Density Functions

Classification of image operations. Image enhancement (GW-Ch. 3) Point operations. Neighbourhood operation

Linear Operations Using Masks

Chapter 11 Image Processing

[Programming Assignment] (1)

1/12/2009. Image Elements (Pixels) Image Elements (Pixels) Digital Image. Digital Image =...

Point Operations and Spatial Filtering

Introduction to Digital Image Processing

Image Segmentation. Schedule. Jesus J Caban 11/2/10. Monday: Today: Image Segmentation Topic : Matting ( P. Bindu ) Assignment #3 distributed

Interpolation is a basic tool used extensively in tasks such as zooming, shrinking, rotating, and geometric corrections.

Computer Vision I. Announcements. Fourier Tansform. Efficient Implementation. Edge and Corner Detection. CSE252A Lecture 13.

EC-433 Digital Image Processing

Image Processing. Bilkent University. CS554 Computer Vision Pinar Duygulu

Digital Image Processing. Prof. P.K. Biswas. Department of Electronics & Electrical Communication Engineering

Transcription:

Chapter - : IMAGE ENHANCEMENT The principal objective of enhancement technique is to process a given image so that the result is more suitable than the original image for a specific application Image Enhancement refers to sharpening of image features such as edges, boundaries or contrast to make a graphic display more useful for display and analysis Image enhancement includes gray level and contrast manipulation, noise reduction, edge-sharpening, filtering, interpolation, magnification, pseudo-coloring and so on The enhancement process does not increase the inherent information content in the data But it does increase the dynamic range of the chosen feature so that they con be detected easily ------------------------------------------------------------------------------------------------------- Q() Explain in detail enhancement techniques in spatial domain used for images (M Dec IT) (M Dec IT) The principal objective of enhancement technique is to process a given image so that the result is more suitable than the original image for a specific application Image Enhancement Techniques are mainly classified into two broad categories (i) Spatial domain method and (ii) Frequency domain method Spatial Domain Methods are as follows:- a) Enhancement by point operations ) Contrast Stretching ) Clipping & Thresholding ) Digital Negative ) Intensity Level Slicing ) Bit Level Slicing 6) Histogram Modeling : Histogram Equalization and Specification IP Help Line : 8 8 8 wwwguideforengineerscom

6 b) Spatial Filtering ) Low pass filtering ) Weighted Average Filter ) Median filtering ) High pass filtering ) High Boost filtering 6) Derivative filters ) Magnification and zooming Refer Q() What are the different reasons for poor contrast? (M May BE Etrx) Q() Obtain the gray level transformation function that stretches gray scale range (, ) into (, ) shifts range (,) to (,) and compress range (,) into (,) Q() Explain the technique of contrast intensification If the gray level intensity changes are to be made shown in figure below, derive the necessary expression for obtaining new pixel value using the slope Draw freq Tables for original and new image and discuss the resulting changes in original image Q() A detail Enhancement Techniques is performed as per following criteria: s = r r otherwise IP Help Line : 8 8 8 6 6 6 6 6 where r and s are the intensities for the input and output image respectively Determine the output image when, detail enhancement techniques is applied on following:- (M Dec Comp) wwwguideforengineerscom 6

Q(6) A x image that uses bits to represent pixels is shown below I Max α I I γ β 8 6 8 m m Max (a) Draw Frequency table showing intensities mi and number of pixels having gray level I (b) Perform Contrast Stretching using the equations and find new image Assume α = ϒ = β = m = and m = (c) Draw a new frequency table and comment on the performance Q() Explain in detail following image enhancement technique in spatial domain (M Dec6 IT) (a) Image Negative (d) High Pass Filter (b) Bit Plane Slicing (e) Low Pass Filter (c) Contrast Stretching (f) Median Filter Q(8) Explain Image Averaging and Image Subtraction (M Dec6 Comp) (8M Dec Comp) Q() For the bit x size image perform following operations: [ M, MAY, ETRX] (M May IT) (a) Negation (b) Thresholding with T= (c) Intensity level slicing with background with r= and r= (d) Bit plane slicing for MSB and LSB plane (e) Clipping with r= and r= 6 6 IP Help Line : 8 8 8 wwwguideforengineerscom

8 Solution : (a) Negation: S = r Output Image = 6 6 6 6 6 (b) Thresholding with T = Thresholding Tx is given by s if r T = = r otherwise Output Image = (c) Intensity level slicing with background It is defined as, s = r if r otherwise Output Image = (d) Bit Plane Slicing Bit planes of Input Image: 6 6 B Bit Plane (MSB) B Bit Plane B Bit Plane (LSB) IP Help Line : 8 8 8 wwwguideforengineerscom 8

Bit plane slicing is defined as s = r if bn otherwise Applying Bit plane slicing for MSB and LSB plane we get, MSB Output LSB Output e) Clipping with r = and r = S (i) To find slope B B = = (ii) To find s for < r < s B (r, s) B = r S = B (r ) Put B = / S = ( r ) Clipping Tx is given by, S = ( r ) r < r < r Output Image = IP Help Line : 8 8 8 wwwguideforengineerscom

Q() What do you understand by Gamma correction Explain (6M May6 Comp)(M Dec Comp) (i) Most of the input and output devices such as image capturing, printing and display devices respond according to a power law (ii) The exponent γ in the power law equation is referred to as gamma (iii) This process used to correct this power law response phenomena is called gamma correction (iv) For example, Cathode Ray Tube (CRT) devices have intensity to voltage response that is a power function with γ varying from approximately 8 to (v) Such display system tends to produce images that are darker than intended Gamma correction can be applied to solve such problems (vi) Gamma correction method is as follows : First process the input image with s = c r γ Then display the image on the CRT (vii) When gamma corrected image is displayed on the screen, the output device is close in appearance to the original image Refer Q() Write short note on Thresholding (M Dec Comp) Q() Plot the histogram for the following image Perform Histogram equalization and then plot the equalized histogram and give histogram equalized image (8M Dec Comp) 6 6 6 Q() Grey level histogram of an image is given below, Compute histogram equalization Draw the histogram of input & output image (8M May 6 IT) GREY LEVEL 6 FREQUENCY 8 66 8 IP Help Line : 8 8 8 wwwguideforengineerscom

Q() The gray level distribution of an 8-level image of 6 x 6 size is specified under two different contrast conditions by two histogram A and B as given below Modify the histogram A as given in histogram B Modify above histogram such that the desired distribution is as follows, (M Dec IT) Histogram (A) Grey Level rk 6 No of pixel Nrk 8 66 8 Histogram (B) Grey Level Zk 6 No of pixel Nzk 6 8 8 6 Q() What information can be obtained from histogram of an image? (M May6 Etrx) Q(6) A digital image with 8 quantization levels is given below f(x,y)= i-j for i,j =,,,,,,6, Perform Histogram Equalization Derive the Transformation function and draw new histogram (M Dec Etrx) 6 6 6 6 6 6 IP Help Line : 8 8 8 wwwguideforengineerscom

Q() Suppose that a digital image is subjected to histogram evaluation Show that a second pass of histogram equalization will produce exactly the same result as the first pass (M May Comp) Q(8) For continuous image histogram can be perfectly equalized but it may not be so for a digital image, justify (M May6 Etrx) Q() Explain Zooming of an Image Does it increase the information content of an image? Q() Perform Zooming on the following Image by Replication and Linear Interpolation Is the result Same in both the cases? (M Dec Comp) ( Spatial Filtering ) Q() Explain Filtering in Spatial Domain (M Dec IT) (M Dec Comp) The use of spatial masks for image processing is called spatial filtering and the masks are called spatial filters For example consider digital sub-image I and x filter mask w : The response of a linear mask is, R = wz + wz + +wz If the center of the mask is at location (x,y) in the image, the gray level of the pixel located at (x,y) is replaced by R The mask is then moved to the next pixel location in the image and the process is repeated This continues until all pixel locations have been covered Refer IP Help Line : 8 8 8 wwwguideforengineerscom

Q() Four different transfer functions/operators are given below If these are operated on a large digital image repeatedly many times (say infinite times) what will be the final image? Give proper reasoning for your answer (A) Thresholding (B) Contrast Stretching L max Lmax/ Slope -/ (C) Low Pass Filter Mask Solution : a) Thresholding (D) Image Transformation (i) Thresholding Transformation is defined as, (ii) In first pass, all the input pixels greater than will get changed to and the remaining pixels will get changed to This gives binary image (iii) After first pass, thresholding operation gives binary image with only two distinct pixel values: and (iv) In second pass, input image is binary image Thresholding operation gives the same result That means, when thresholding operation is repeatedly applied, there is no change in the output image obtained after the first pass (v) Thresholding Transformation gives only one type of output image IP Help Line : 8 8 8 wwwguideforengineerscom

----------------------------------------------------------------------------------------------- -- b) Contrast Stretching (i) The Linear Contrast Stretching Transformation function is defined as, Where By substituting, we get, (ii) Each time, contrast stretching transformation will produce the following output Case - When r The output S < r ie output pixel amplitude will be smaller than input pixel amplitude Case - When r Threshold T The output S < r ie output pixel amplitude will be smaller than input pixel amplitude Case - When Threshold T r The output S > r ie output pixel amplitude will be Larger than input pixel amplitude Case - When r The output S > r ie output pixel amplitude will be Larger than input pixel amplitude To find Threshold T: That means, When r The output S > r IP Help Line : 8 8 8 wwwguideforengineerscom

IP Help Line : 8 8 8 wwwguideforengineerscom When > r The output S < r (iii) When contrast stretching transformation is repeatedly applied, all the input pixels will get reduced further in the output image After n successive applications the pixel value will become (iv) Similarly all the input pixels will get amplified in the output image After n successive applications, the pixel value will become (v) That means after n repeated applications of the contrast stretching transformation function, we get an image having only two grey levels This is Binary Image ------------------------------------------------------------------------------------------------- c) Low Pass Filter (i) LPF attenuates High Frequency components by distributing its energy in all 8 directions using averaging of neighbouring pixels (ii) LPF averaging mask is given by Consider a Digital Impulse Image F = 8 F The output of LPF is given by = L Due to averaging, the amplitude of distinct pixels reduces (iii) After second pass, = 6 6 6 6 L L P F L L P F F

(iv) The difference between neighbouring pixels gets further reduced, ie high frequency components get further suppressed (v) By repeatedly applying Low Pass filtering, a stage will come when all pixel values will become equal and the image will become Low Pass Flat Image 6 Q() Can Median Filter reduce noise? Explain in detail with example the situation where it is most effective (M) Q() Define the following Spatial filters: ) Median ) Min ) Max Consider the digital Image Calculate the value at pt g(,) = (M May Comp) 6 6 6 6 6 6 6 Solution : At (,); i) Median filter: The response of median filter at (,) is given by ii) Max Filter iii) Min Filter Q() Show that High pass = Original Low pass (M May6 IT) (M May Comp ) ( M,MAY, ETRX) Q(6) Explain operation and application of each of the following; Give x mask wherever applicable ) Low pass filter (M May6 Etrx) ) Median filter (M May6 Etrx) IP Help Line : 8 8 8 wwwguideforengineerscom 6

Q() The x matrix shown below is frequently used to compute the derivative in x direction at each point in an image Give an ALU procedure to implement this operation (M Dec Etrx) - - - Solution : Consider a Digital Subimage as shown in figure below : Z Z Z Z Z Z6 Z Z8 Z W W W W W W6 W W8 W Mask (Given ) The response of the filter is given by, Z = W Z + W Z + W Z + W Z + W Z + W 6 Z 6 + W Z + W 8 Z 8 + W Z ALU procedure : Buffer A Buffer B ------- Multiply A with W Shift Right ------- ------- Add A * W Shift Down ------- ------- Add A * W Shift Left ------- ------- Add A * W Shift Left ------- ------- Add A * W Up ------- ------- Add A * W6 Up ------- ------- Add A * W Right ------- ------- Add A * W8 Right ------- ------- Add A * W Down ------- Left IP Help Line : 8 8 8 wwwguideforengineerscom

8 Q(8) Given below is x image Operate on the central x pixels by low pass and high pass filter masks and obtain x images as outputs (M May6 Etrx) 6 6 8 8 8 Using these outputs verify Original Image = LPF Image + HPF Image In case of discrepancy explain the reasons Q() Write Short Notes on: (a) Filtering in the Spatial and Frequency Domains (M Dec6 Comp) (b) Smoothing and sharpening Filters Q() Justify /Contradict the following statements: IP Help Line : 8 8 8 (6M May6 Comp) (a) For digital images having salt pepper noise, median filter is the best filter (6M May6 Comp) (b) Laplacian is better than gradient for detection of edges (6M May6 Comp) Q() State whether True or False Hence justify (a) Image can be obtained if histogram is given (M) (b) Histogram equalization and Linear contrast stretching always give the same result (M) Q() Show that: (M each, MAY, ETRX) (a) Poorly illuminated images can be easily segmented (b) Laplacian is not a good edge detector Q() Justify/contradict following statements (M Dec IT) (a) Enhancement process does not change the information content of image (b) For digital image having salt paper noise, median filter is the best filter (c) For continuous image histogram can be perfectly equalized, but it may not be so for digital image (d) Quality of pictures depends on the number of pixels and gray level that represent the picture wwwguideforengineerscom 8

(f) Median filter is the best solution to remove salt and pepper noise (M MAY IT) Q() TRUE OR FALSE and justify (each)(m May6 Etrx) [a] Histogram is a unique representation of an image [b] Second pass of histogram equalization will produce exactly the same result as the first pass [c] The principal function of median filter is to force points with distinct intensity to be more like their neighbors Q() Show that: (M each, MAY, ETRX) (a) Poorly illuminated images can be easily segmented Poorly illuminated images can not be easily segmented as segmentation is based on one of two basic properties of gray level values : discontinuity and similarity In the first category, the approach is to partition an image based on abrupt changes in gray level The principal areas of interest within this category are detection of isolated points and detection of lines and edges in an image In the second category, the principal approach is thresholding, region growing and region splitting and merging The concept of segmenting an image based on discontinuity or similarity of the gray level values of its pixels is applicable to both static & dynamic (time varying) images As in the poorly illuminated images all the pixel have same or almost the same gray level, hence it is very difficult to decide the value of the Threshold based on which the segmentation will be done IP Help Line : 8 8 8 wwwguideforengineerscom

Q(6) If all the pixels in an image are shuffled, will there be any change in the histogram? Justify your answer (i) If all the pixels in an image are shuffled, there will not be any change in the histogram of the image A histogram gives only the frequency of occurrence of the gray level Consider two images, and, as given below: 8 6 8 6 Image Image (ii) Image is obtained by shuffling the row of image Their corresponding histograms are shown below (ii) From the two histograms, it is clear that even if all the pixels in an image are shuffled, there will not be any change in the histogram of the image Q() What is the impact of applying the following look-up table? Index 6 8 LUT 8 8 On the 8 bit image given below: 6 8 6 6 8 8 Solution : On applying the look-up table on the given image, we get the resultant image as IP Help Line : 8 8 8 wwwguideforengineerscom

8 8 8 8 8 8 8 By comparing the resultant image with the original image, it is obvious that the brightness of the resultant image is better than the original image Q(8) Given f ( x, y) = 6 Find the output image g(x,y) using logarithmic Transformation g(x,y) = 6 Log [+ f(x,y)] By Logarithmic Transformation g(x,y) = 6 Log [+ f(x,y)] 68 88 g(x, y) = 88 == By rounding == 68 6 6 8 6 Q() Given f ( x, y) = 6 Find the output image g(x,y) using Power Law Transformation g ( x, y) = [ f ( x, y)] By Power Law Transformation image pixel values s = r where r and s are normalized input and output To find Normalized input image pixel values, divide every input image pixel value by max value IP Help Line : 8 8 8 wwwguideforengineerscom

f ( x, y) Here max pixel value is So, r = 8 86 Normalized f ( x, y) = 8 8 By Power Law Transformation s = r we get, 8 8 Normalized output image g( x, y) = 6 6 8 To find de-normalized output image pixel values, multiply every output image pixel value by max value De normalized output image g( x, y) = Q() Explain High-boost Filtering (i) A high-boost filter is also known as a high-frequency emphasis filter A high-boost filter is used to retain some of the low frequency components to aid in the interpretation of an image (ii) In high-boost filtering, the input image f(m, n) is multiplied by an amplification factor A before subtracting the low-pass image Thus, the high-boost filter expression becomes, (iii) High-boost = A f(m, n) low pass Adding and subtracting with the gain factor, we get High-boost = (A - ) f(m, n) + f(m, n) low pass But f(m, n) low pass = high pass Substituting this in the above equation, we get High boost = (A-) x f(m, n) + high pass Q() State whether True or False Hence justify (a) Image can be obtained if histogram is given : TRUE (b) Histogram equalization and Linear contrast stretching always give the same result FALSE IP Help Line : 8 8 8 wwwguideforengineerscom

( c) Enhancement process does not change the information content of image TRUE (d) For digital image having salt paper noise, median filter is the best filter TRUE (e) For continuous image histogram can be perfectly equalized, but it may not be so for digital image TRUE (f) Quality of pictures depends on the number of pixels and gray level that represent the picture TRUE (g) Median filter is the best solution to remove salt and pepper noise TRUE (h) Histogram is a unique representation of an image FALSE (i) Second pass of histogram equalization will produce exactly the same result as the first pass TRUE (i) The principal function of median filter is to force points with distinct intensity to be more like their neighbors TRUE Q() Explain Zooming of an Image Does it increase the information content of an image? Zooming means magnifying the SIZE of the image Zooming operation increases the physical dimension of the image in Horizontal, vertical or in both direction Zooming increases the size of the image horizontally by repeatedly displaying the original information of the image It does not add any extra information into it There are two methods of zooming Replication and Interpolation () REPLICATION : - Replication is a zero order hold where each pixel along a scan line is repeated and then each scan line is repeated This is equivalent to taking M x N image and interlacing it by rows and columns of zerus to obtain a M x N matrix an convolving the result with an away H defined as H = IP Help Line : 8 8 8 wwwguideforengineerscom

() LINEAR INTERPOLATION : - Linear interpolation is a first order hold where a straight line is first fitted in between pixels along a row Then pixels along each column are interpolated along a straight line For ex x magnification linear - interpolation along ROW gives g (x, y) = f (x, y) g (x, y + ) = ½ [ f (x, y) + f (x, y + ) ] x M - y N - Linear interpolation along column given, g (x, y) = g (x, y) g (x +, y) = ½ [ g (x, y) + g (x +, y) ] It is assumed that input image is zero outside [ O, N ] x [ O, N ] Zero Column Interpulate Rows Zero Column Interpulate Column = By Rounding ANS IP Help Line : 8 8 8 wwwguideforengineerscom

IP Help Line : 8 8 8 wwwguideforengineerscom Q() Perform Zooming on the following Image by Replication and Linear Interpolation Is the result Same in both the cases? (M Dec Comp) Solution : Step I Interpolate ROWS () In each ROW, Insert alternate ZERO between every two elements () Interpolate ROWS by averaging neighbouring pixels in Horizontal Direction Step II Interpolate COLUMNS () In each COLUMN, Insert alternate ZERO between every two elements

() Interpolate ROWS by averaging neighbouring pixels in Horizontal Direction 6 6 After rounding we get, 6 Q() State and explain the features of median filtering Complete the output of median filter in the following cases: (8M Dec Comp) (a) x(n)={8 } and w={- } (b) x(n)={ 8 } and w={- } Solution : (a) Given x (n) { 8,,,, } with repeated border value we get, x (n) = 8 {8,,,, } (i) At n=, y() = x(n) = 8 { 8,,,, } w(n) = [-,, ] y() = median {8, 8, } = median {, [8], 8} =[8] (ii) At n =, y() = median {8,, } = median {,, 8} = [] (iii) At n =, y() = median {,, } = median {,, } = [] IP Help Line : 8 8 8 wwwguideforengineerscom 6

(iv) At n =, y() = median {,, } = median {,, } = [] (v) At n =, y() = median {,, } = [] y(n) = {8,,,, } (b) Given x(n) {,, 8,, } Considering repeated border values we get, x(n) =,, {,, 8,, },, w(n) = {-,,, } (i) At n =, y() = median {,,, 8} = Average {, } = [] (ii) At n =, y() = median {, 8,, } = median {,,, 8} = Average {, } = [] (iii) At n =, y() = median {8,,, } = median {,,, 8} = Average {, } = [] (iv) At n =, y() = median {8,,, } = median {,,, 8} = Average {, } = [] (v) At n =, y() = median {,,, } = median {,,, } = Average {, } = [] Ans = y(n) = [,,,, ] IP Help Line : 8 8 8 wwwguideforengineerscom