SlideShare a Scribd company logo
1 of 9
Download to read offline
Lecture 5: Image Enhancement
Image Filtering
Computer Vision In MATLAB
By. Assist. Prof. Ielaf O.Abdul Majjed
2022-2023
Image filtering is a technique for modifying or enhancing an image
and its useful for many applications, including smoothing, sharpening,
removing noise, and edge detection. A filter is defined by a kernel or
mask , which is a small array applied to each pixel and its neighbors
within an image.
The process used to apply filters to an image is known as
convolution, and may be applied in either the spatial or frequency
domain.
Convolution is a mathematical operation on two signals that forms a
third signal. It expresses how the form of one is changed by the other
using the integral of the product of two functions after one is moved
over the other.
Convolution relates three signals of interest:
 input signal: an array of pixels (input image).
 filtering kernel: a small matrix of numbers that contains specific
coefficients
 output signal: a new modified filtered image
It can be explained as “image convolved with mask”.
g(x,y) = f(x,y) * h(x,y)
There are two ways to represent this because the convolution operator
(*) is commutative. The h(x,y) is the mask or filter.
Mask is also a signal. It can be represented by a two dimensional
matrix. The mask is usually of the order of 1x1, 3x3, 5x5, 7x7. A mask
should always be in odd number, because other wise you cannot find
the mid of the mask. Why do we need to find the mid of the mask.
• Simple box blur
Here's a first and simplest. This convolution kernel has an averaging
effect. So you end up with a slight blur. The image convolution kernel
is:
Note that the sum of all elements of this matrix is 1.0. This is
important. If the sum is not exactly one, the resultant image will be
brighter or darker.
• Gaussian blur
Gaussian blur has certain mathematical properties that makes it
important for computer vision. And you can approximate it with an
image convolution. The image convolution kernel for a Gaussian blur
is:
• Line detection with image convolutions
With image convolutions, you can easily
detect lines. Here are four convolutions to
detect horizontal, vertical and lines at 45
degrees:
• Edge detection
• The Sobel Edge Operator
• The laplacian operator
• The Laplacian of Gaussian
H.W:
• Low Pass Filter
• High Pass Filter

More Related Content

Similar to Lecture 5-2023.pdf

Image enhancement
Image enhancementImage enhancement
Image enhancement
Ayaelshiwi
 
1 of 6 LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
1 of 6  LAB 5 IMAGE FILTERING ECE180 Introduction to.docx1 of 6  LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
1 of 6 LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
mercysuttle
 

Similar to Lecture 5-2023.pdf (20)

Convolutional Neural Network and Its Applications
Convolutional Neural Network and Its ApplicationsConvolutional Neural Network and Its Applications
Convolutional Neural Network and Its Applications
 
DL.pdf
DL.pdfDL.pdf
DL.pdf
 
A NOBEL HYBRID APPROACH FOR EDGE DETECTION
A NOBEL HYBRID APPROACH FOR EDGE  DETECTIONA NOBEL HYBRID APPROACH FOR EDGE  DETECTION
A NOBEL HYBRID APPROACH FOR EDGE DETECTION
 
Mnist report
Mnist reportMnist report
Mnist report
 
New microsoft power point presentation
New microsoft power point presentationNew microsoft power point presentation
New microsoft power point presentation
 
Image enhancement
Image enhancementImage enhancement
Image enhancement
 
IMAGE SEGMENTATION.
IMAGE SEGMENTATION.IMAGE SEGMENTATION.
IMAGE SEGMENTATION.
 
1 of 6 LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
1 of 6  LAB 5 IMAGE FILTERING ECE180 Introduction to.docx1 of 6  LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
1 of 6 LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
 
An Approach for Image Deblurring: Based on Sparse Representation and Regulari...
An Approach for Image Deblurring: Based on Sparse Representation and Regulari...An Approach for Image Deblurring: Based on Sparse Representation and Regulari...
An Approach for Image Deblurring: Based on Sparse Representation and Regulari...
 
Spatial Filtering in intro image processingr
Spatial Filtering in intro image processingrSpatial Filtering in intro image processingr
Spatial Filtering in intro image processingr
 
Spatial Filters (Digital Image Processing)
Spatial Filters (Digital Image Processing)Spatial Filters (Digital Image Processing)
Spatial Filters (Digital Image Processing)
 
Visual Quality for both Images and Display of Systems by Visual Enhancement u...
Visual Quality for both Images and Display of Systems by Visual Enhancement u...Visual Quality for both Images and Display of Systems by Visual Enhancement u...
Visual Quality for both Images and Display of Systems by Visual Enhancement u...
 
I010634450
I010634450I010634450
I010634450
 
Performance of Efficient Closed-Form Solution to Comprehensive Frontier Exposure
Performance of Efficient Closed-Form Solution to Comprehensive Frontier ExposurePerformance of Efficient Closed-Form Solution to Comprehensive Frontier Exposure
Performance of Efficient Closed-Form Solution to Comprehensive Frontier Exposure
 
DIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehr
DIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehrDIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehr
DIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehr
 
Digital image processing - Image Enhancement (MATERIAL)
Digital image processing  - Image Enhancement (MATERIAL)Digital image processing  - Image Enhancement (MATERIAL)
Digital image processing - Image Enhancement (MATERIAL)
 
Digital Image Processing - Image Enhancement
Digital Image Processing  - Image EnhancementDigital Image Processing  - Image Enhancement
Digital Image Processing - Image Enhancement
 
CNN.pptx
CNN.pptxCNN.pptx
CNN.pptx
 
Introductory Digital Image Processing using Matlab, IIT Roorkee
Introductory Digital Image Processing using Matlab, IIT RoorkeeIntroductory Digital Image Processing using Matlab, IIT Roorkee
Introductory Digital Image Processing using Matlab, IIT Roorkee
 
ResearchPaper_Final
ResearchPaper_FinalResearchPaper_Final
ResearchPaper_Final
 

More from ssuserff72e4

More from ssuserff72e4 (13)

Lecture 6-2023.pdf
Lecture 6-2023.pdfLecture 6-2023.pdf
Lecture 6-2023.pdf
 
informationhiding-181103070958 (1).pdf
informationhiding-181103070958 (1).pdfinformationhiding-181103070958 (1).pdf
informationhiding-181103070958 (1).pdf
 
chapter10-queue-161018120329.en.ar.pdf
chapter10-queue-161018120329.en.ar.pdfchapter10-queue-161018120329.en.ar.pdf
chapter10-queue-161018120329.en.ar.pdf
 
Queues.ppt
Queues.pptQueues.ppt
Queues.ppt
 
cp264_lecture18_queue.ppt
cp264_lecture18_queue.pptcp264_lecture18_queue.ppt
cp264_lecture18_queue.ppt
 
11.pptx
11.pptx11.pptx
11.pptx
 
Queues.ppt
Queues.pptQueues.ppt
Queues.ppt
 
chapter10-queue-161018120329.pdf
chapter10-queue-161018120329.pdfchapter10-queue-161018120329.pdf
chapter10-queue-161018120329.pdf
 
11.pdf
11.pdf11.pdf
11.pdf
 
Parts of speech in English.pptx
Parts of speech in English.pptxParts of speech in English.pptx
Parts of speech in English.pptx
 
Lecture 2-2023.pdf
Lecture 2-2023.pdfLecture 2-2023.pdf
Lecture 2-2023.pdf
 
Lecture1_computer vision-2023.pdf
Lecture1_computer vision-2023.pdfLecture1_computer vision-2023.pdf
Lecture1_computer vision-2023.pdf
 
Lecture 2-2023.pdf
Lecture 2-2023.pdfLecture 2-2023.pdf
Lecture 2-2023.pdf
 

Recently uploaded

FULL NIGHT — 9999894380 Call Girls In Delhi | Delhi
FULL NIGHT — 9999894380 Call Girls In Delhi | DelhiFULL NIGHT — 9999894380 Call Girls In Delhi | Delhi
FULL NIGHT — 9999894380 Call Girls In Delhi | Delhi
SaketCallGirlsCallUs
 
UAE Call Girls # 0528675665 # Independent Call Girls In Dubai ~ (UAE)
UAE Call Girls # 0528675665 # Independent Call Girls In Dubai ~ (UAE)UAE Call Girls # 0528675665 # Independent Call Girls In Dubai ~ (UAE)
UAE Call Girls # 0528675665 # Independent Call Girls In Dubai ~ (UAE)
Business Bay Call Girls || 0529877582 || Call Girls Service in Business Bay Dubai
 
FULL NIGHT — 9999894380 Call Girls In Dwarka Mor | Delhi
FULL NIGHT — 9999894380 Call Girls In Dwarka Mor | DelhiFULL NIGHT — 9999894380 Call Girls In Dwarka Mor | Delhi
FULL NIGHT — 9999894380 Call Girls In Dwarka Mor | Delhi
SaketCallGirlsCallUs
 
FULL NIGHT — 9999894380 Call Girls In New Ashok Nagar | Delhi
FULL NIGHT — 9999894380 Call Girls In New Ashok Nagar | DelhiFULL NIGHT — 9999894380 Call Girls In New Ashok Nagar | Delhi
FULL NIGHT — 9999894380 Call Girls In New Ashok Nagar | Delhi
SaketCallGirlsCallUs
 
Dubai Call Girls # 00971528860074 # 24/7 Call Girls In Dubai || (UAE)
Dubai Call Girls # 00971528860074 # 24/7 Call Girls In Dubai || (UAE)Dubai Call Girls # 00971528860074 # 24/7 Call Girls In Dubai || (UAE)
Dubai Call Girls # 00971528860074 # 24/7 Call Girls In Dubai || (UAE)
Business Bay Call Girls || 0529877582 || Call Girls Service in Business Bay Dubai
 
Dubai Call Girl Number # 0522916705 # Call Girl Number In Dubai # (UAE)
Dubai Call Girl Number # 0522916705 # Call Girl Number In Dubai # (UAE)Dubai Call Girl Number # 0522916705 # Call Girl Number In Dubai # (UAE)
Dubai Call Girl Number # 0522916705 # Call Girl Number In Dubai # (UAE)
Business Bay Call Girls || 0529877582 || Call Girls Service in Business Bay Dubai
 
FULL NIGHT — 9999894380 Call Girls In Najafgarh | Delhi
FULL NIGHT — 9999894380 Call Girls In Najafgarh | DelhiFULL NIGHT — 9999894380 Call Girls In Najafgarh | Delhi
FULL NIGHT — 9999894380 Call Girls In Najafgarh | Delhi
SaketCallGirlsCallUs
 
Admirable # 00971529501107 # Call Girls at dubai by Dubai Call Girl
Admirable # 00971529501107 # Call Girls at dubai by Dubai Call GirlAdmirable # 00971529501107 # Call Girls at dubai by Dubai Call Girl
Admirable # 00971529501107 # Call Girls at dubai by Dubai Call Girl
home
 
FULL NIGHT — 9999894380 Call Girls In Ashok Vihar | Delhi
FULL NIGHT — 9999894380 Call Girls In Ashok Vihar | DelhiFULL NIGHT — 9999894380 Call Girls In Ashok Vihar | Delhi
FULL NIGHT — 9999894380 Call Girls In Ashok Vihar | Delhi
SaketCallGirlsCallUs
 
Deira Call Girls # 0588312479 # Call Girls In Deira Dubai ~ (UAE)
Deira Call Girls # 0588312479 # Call Girls In Deira Dubai ~ (UAE)Deira Call Girls # 0588312479 # Call Girls In Deira Dubai ~ (UAE)
Deira Call Girls # 0588312479 # Call Girls In Deira Dubai ~ (UAE)
Business Bay Call Girls || 0529877582 || Call Girls Service in Business Bay Dubai
 
Authentic # 00971556872006 # Hot Call Girls Service in Dubai By International...
Authentic # 00971556872006 # Hot Call Girls Service in Dubai By International...Authentic # 00971556872006 # Hot Call Girls Service in Dubai By International...
Authentic # 00971556872006 # Hot Call Girls Service in Dubai By International...
home
 

Recently uploaded (20)

FULL NIGHT — 9999894380 Call Girls In Delhi | Delhi
FULL NIGHT — 9999894380 Call Girls In Delhi | DelhiFULL NIGHT — 9999894380 Call Girls In Delhi | Delhi
FULL NIGHT — 9999894380 Call Girls In Delhi | Delhi
 
Deconstructing Gendered Language; Feminist World-Making 2024
Deconstructing Gendered Language; Feminist World-Making 2024Deconstructing Gendered Language; Feminist World-Making 2024
Deconstructing Gendered Language; Feminist World-Making 2024
 
UAE Call Girls # 0528675665 # Independent Call Girls In Dubai ~ (UAE)
UAE Call Girls # 0528675665 # Independent Call Girls In Dubai ~ (UAE)UAE Call Girls # 0528675665 # Independent Call Girls In Dubai ~ (UAE)
UAE Call Girls # 0528675665 # Independent Call Girls In Dubai ~ (UAE)
 
(INDIRA) Call Girl Dehradun Call Now 8617697112 Dehradun Escorts 24x7
(INDIRA) Call Girl Dehradun Call Now 8617697112 Dehradun Escorts 24x7(INDIRA) Call Girl Dehradun Call Now 8617697112 Dehradun Escorts 24x7
(INDIRA) Call Girl Dehradun Call Now 8617697112 Dehradun Escorts 24x7
 
FULL NIGHT — 9999894380 Call Girls In Dwarka Mor | Delhi
FULL NIGHT — 9999894380 Call Girls In Dwarka Mor | DelhiFULL NIGHT — 9999894380 Call Girls In Dwarka Mor | Delhi
FULL NIGHT — 9999894380 Call Girls In Dwarka Mor | Delhi
 
FULL NIGHT — 9999894380 Call Girls In New Ashok Nagar | Delhi
FULL NIGHT — 9999894380 Call Girls In New Ashok Nagar | DelhiFULL NIGHT — 9999894380 Call Girls In New Ashok Nagar | Delhi
FULL NIGHT — 9999894380 Call Girls In New Ashok Nagar | Delhi
 
Dubai Call Girls # 00971528860074 # 24/7 Call Girls In Dubai || (UAE)
Dubai Call Girls # 00971528860074 # 24/7 Call Girls In Dubai || (UAE)Dubai Call Girls # 00971528860074 # 24/7 Call Girls In Dubai || (UAE)
Dubai Call Girls # 00971528860074 # 24/7 Call Girls In Dubai || (UAE)
 
Dubai Call Girl Number # 0522916705 # Call Girl Number In Dubai # (UAE)
Dubai Call Girl Number # 0522916705 # Call Girl Number In Dubai # (UAE)Dubai Call Girl Number # 0522916705 # Call Girl Number In Dubai # (UAE)
Dubai Call Girl Number # 0522916705 # Call Girl Number In Dubai # (UAE)
 
FULL NIGHT — 9999894380 Call Girls In Najafgarh | Delhi
FULL NIGHT — 9999894380 Call Girls In Najafgarh | DelhiFULL NIGHT — 9999894380 Call Girls In Najafgarh | Delhi
FULL NIGHT — 9999894380 Call Girls In Najafgarh | Delhi
 
Admirable # 00971529501107 # Call Girls at dubai by Dubai Call Girl
Admirable # 00971529501107 # Call Girls at dubai by Dubai Call GirlAdmirable # 00971529501107 # Call Girls at dubai by Dubai Call Girl
Admirable # 00971529501107 # Call Girls at dubai by Dubai Call Girl
 
Editorial sephora annual report design project
Editorial sephora annual report design projectEditorial sephora annual report design project
Editorial sephora annual report design project
 
FULL NIGHT — 9999894380 Call Girls In Ashok Vihar | Delhi
FULL NIGHT — 9999894380 Call Girls In Ashok Vihar | DelhiFULL NIGHT — 9999894380 Call Girls In Ashok Vihar | Delhi
FULL NIGHT — 9999894380 Call Girls In Ashok Vihar | Delhi
 
Deira Call Girls # 0588312479 # Call Girls In Deira Dubai ~ (UAE)
Deira Call Girls # 0588312479 # Call Girls In Deira Dubai ~ (UAE)Deira Call Girls # 0588312479 # Call Girls In Deira Dubai ~ (UAE)
Deira Call Girls # 0588312479 # Call Girls In Deira Dubai ~ (UAE)
 
VIP Ramnagar Call Girls, Ramnagar escorts Girls 📞 8617697112
VIP Ramnagar Call Girls, Ramnagar escorts Girls 📞 8617697112VIP Ramnagar Call Girls, Ramnagar escorts Girls 📞 8617697112
VIP Ramnagar Call Girls, Ramnagar escorts Girls 📞 8617697112
 
Authentic # 00971556872006 # Hot Call Girls Service in Dubai By International...
Authentic # 00971556872006 # Hot Call Girls Service in Dubai By International...Authentic # 00971556872006 # Hot Call Girls Service in Dubai By International...
Authentic # 00971556872006 # Hot Call Girls Service in Dubai By International...
 
Jeremy Casson - Top Tips for Pottery Wheel Throwing
Jeremy Casson - Top Tips for Pottery Wheel ThrowingJeremy Casson - Top Tips for Pottery Wheel Throwing
Jeremy Casson - Top Tips for Pottery Wheel Throwing
 
Call Girls Ludhiana Just Call 98765-12871 Top Class Call Girl Service Available
Call Girls Ludhiana Just Call 98765-12871 Top Class Call Girl Service AvailableCall Girls Ludhiana Just Call 98765-12871 Top Class Call Girl Service Available
Call Girls Ludhiana Just Call 98765-12871 Top Class Call Girl Service Available
 
Sirmaur Call Girls Book Now 8617697112 Top Class Pondicherry Escort Service A...
Sirmaur Call Girls Book Now 8617697112 Top Class Pondicherry Escort Service A...Sirmaur Call Girls Book Now 8617697112 Top Class Pondicherry Escort Service A...
Sirmaur Call Girls Book Now 8617697112 Top Class Pondicherry Escort Service A...
 
Completed Event Presentation for Huma 1305
Completed Event Presentation for Huma 1305Completed Event Presentation for Huma 1305
Completed Event Presentation for Huma 1305
 
Mayiladuthurai Call Girls 8617697112 Short 3000 Night 8000 Best call girls Se...
Mayiladuthurai Call Girls 8617697112 Short 3000 Night 8000 Best call girls Se...Mayiladuthurai Call Girls 8617697112 Short 3000 Night 8000 Best call girls Se...
Mayiladuthurai Call Girls 8617697112 Short 3000 Night 8000 Best call girls Se...
 

Lecture 5-2023.pdf

  • 1. Lecture 5: Image Enhancement Image Filtering Computer Vision In MATLAB By. Assist. Prof. Ielaf O.Abdul Majjed 2022-2023
  • 2. Image filtering is a technique for modifying or enhancing an image and its useful for many applications, including smoothing, sharpening, removing noise, and edge detection. A filter is defined by a kernel or mask , which is a small array applied to each pixel and its neighbors within an image. The process used to apply filters to an image is known as convolution, and may be applied in either the spatial or frequency domain. Convolution is a mathematical operation on two signals that forms a third signal. It expresses how the form of one is changed by the other using the integral of the product of two functions after one is moved over the other. Convolution relates three signals of interest:  input signal: an array of pixels (input image).  filtering kernel: a small matrix of numbers that contains specific coefficients  output signal: a new modified filtered image
  • 3. It can be explained as “image convolved with mask”. g(x,y) = f(x,y) * h(x,y) There are two ways to represent this because the convolution operator (*) is commutative. The h(x,y) is the mask or filter. Mask is also a signal. It can be represented by a two dimensional matrix. The mask is usually of the order of 1x1, 3x3, 5x5, 7x7. A mask should always be in odd number, because other wise you cannot find the mid of the mask. Why do we need to find the mid of the mask.
  • 4.
  • 5.
  • 6. • Simple box blur Here's a first and simplest. This convolution kernel has an averaging effect. So you end up with a slight blur. The image convolution kernel is: Note that the sum of all elements of this matrix is 1.0. This is important. If the sum is not exactly one, the resultant image will be brighter or darker.
  • 7. • Gaussian blur Gaussian blur has certain mathematical properties that makes it important for computer vision. And you can approximate it with an image convolution. The image convolution kernel for a Gaussian blur is: • Line detection with image convolutions With image convolutions, you can easily detect lines. Here are four convolutions to detect horizontal, vertical and lines at 45 degrees:
  • 8. • Edge detection • The Sobel Edge Operator • The laplacian operator • The Laplacian of Gaussian
  • 9. H.W: • Low Pass Filter • High Pass Filter