SlideShare a Scribd company logo
1 of 15
Download to read offline
5/25/2010
1
Gaussian Filtering
Gaussian filtering is used to blur images and remove noise and detail.g g
In one dimension, the Gaussian function is:
Where σ is the standard deviation of the distribution The distribution is
2
2
2
2
1
( )
2
x
G x e σ
πσ
−
=
Where σ is the standard deviation of the distribution. The distribution is
assumed to have a mean of 0.
Shown graphically, we see the familiar bell shaped Gaussian
distribution.
18
Gaussian distribution with mean 0 and σ = 1
5/25/2010
2
Gaussian filtering
• Significant values
2 2 2 2
0.5/ 2/ 9/4 8/
0 1 2 3 4
* ( ) / 0.399 1
x
G x e e e e
σ σ σ σ
σ
− − − −
2 2 2 2
0.5/ 2/ 9/4 8/
( ) / 0.399 1
( ) / (0) 1
G x e e e e
G x G e e e e
σ σ σ σ
σ
− − − −
0 1 2x
For σ=1:
19
0 1 2
( ) 0.399 0.242 0.05
( ) / (0) 1 0.6 0.125
x
G x
G x G
5/25/2010
3
Gaussian Filtering
Standard Deviation
Th St d d d i ti f th G i f ti l i t tThe Standard deviation of the Gaussian function plays an important
role in its behaviour.
The values located between +/- σ account for 68% of the set, while two
standard deviations from the mean (blue and brown) account for
95%, and three standard deviations (blue, brown and green)
account for 99.7%.account for 99.7%.
This is very important when designing a Gaussian kernel of fixed
length.
20
Distribution of the Gaussian function values (Wikipedia)
5/25/2010
4
Gaussian Filtering
The Gaussian function is used in numerous research areas:
– It defines a probability distribution for noise or data.
– It is a smoothing operator.
– It is used in mathematics.
The Gaussian function has important properties which are verified withThe Gaussian function has important properties which are verified with
respect to its integral:
In probabilistic terms, it describes 100% of the possible values of any
given space when varying from negative to positive values
( )2
exp xI dx π
∞
−∞
= − =∫
21
given space when varying from negative to positive values
Gauss function is never equal to zero.
It is a symmetric function.
5/25/2010
5
Gaussian Filtering
Wh ki ith i d t th t di i lWhen working with images we need to use the two dimensional
Gaussian function.
This is simply the product of two 1D Gaussian functions (one for each
direction) and is given by:
2 2
2
2
1
( )
x y
G
+
−
A graphical representation of the 2D
Gaussian distribution with mean(0,0)
2
2
2
( , )
2
G x y e σ
πσ
=
22
and σ = 1 is shown to the right.
5/25/2010
6
Gaussian Filtering
Th G i filt k b i th 2D di t ib ti i t dThe Gaussian filter works by using the 2D distribution as a point-spread
function.
This is achieved by convolving the 2D Gaussian distribution function
with the image.
We need to produce a discrete approximation to the Gaussian function.
Thi th ti ll i i fi it l l l ti k l thThis theoretically requires an infinitely large convolution kernel, as the
Gaussian distribution is non-zero everywhere.
Fortunately the distribution has approached very close to zero at about
three standard deviations from the mean. 99% of the distribution
falls within 3 standard deviations.
This means we can normally limit the kernel size to contain only values
23
This means we can normally limit the kernel size to contain only values
within three standard deviations of the mean.
5/25/2010
7
Gaussian Filtering
G i k l ffi i t l d f th 2D G iGaussian kernel coefficients are sampled from the 2D Gaussian
function.
Where σ is the standard deviation of the distribution.
2 2
2
2
2
1
( , )
2
x y
G x y e σ
πσ
+
−
=
The distribution is assumed to have a mean of zero.
We need to discretize the continuous Gaussian functions to store it as
discrete pixels.
An integer valued 5 by 5 convolution
1 4 7 4 1
4 16 26 16 4
7 26 41 26 7
1
24
kernel approximating a Gaussian
with a σ of 1 is shown to the right,
7 26 41 26 7
4 16 26 16 4
1 4 7 4 1
1
273
5/25/2010
8
Gaussian Filtering
The Gaussian filter is a non-uniform low pass filter.
The kernel coefficients diminish with increasing distance from the
kernel’s centre.
Central pixels have a higher weighting than those on the periphery.
Larger values of σ produce a wider peak (greater blurring).
Kernel size must increase with increasing σ to maintain the Gaussiang
nature of the filter.
Gaussian kernel coefficients depend on the value of σ.
At the edge of the mask, coefficients must be close to 0.
The kernel is rotationally symmetric with no directional bias.
Gaussian kernel is separable which allows fast computation
25
Gaussian kernel is separable, which allows fast computation.
Gaussian filters might not preserve image brightness.
5/25/2010
9
Gaussian Filtering examples
Is the kernel a 1D Gaussian kernel?1 6 1Is the kernel a 1D Gaussian kernel?
Give a suitable integer-value 5 by 5 convolution mask
that approximates a Gaussian function with a σ of 1.4.
How many standard deviations from the mean are
required for a Gaussian function to fall to 5% or 1% of
1 6 1
required for a Gaussian function to fall to 5%, or 1% of
its peak value?
What is the value of σ for which the value of the
Gaussian function is halved at +/-1 x.
Compute the horizontal Gaussian kernel with mean=0
26
Compute the horizontal Gaussian kernel with mean=0
and σ=1, σ=5.
5/25/2010
10
Gaussian Filtering examples
15 20 24 23 16 10Apply the Gaussian filter to the image:
Borders: keep border values as they are
15 20 25 25 15 10
20 15 50 30 20 15
20 50 55 60 30 20
20 15 65 30 15 30
20 25 36 33 21 15
20 44 55 51 35 20
20 29 44 35 22 30
15 21 25 24 25 30
20 21 19 16 14 15
1 2 1
Borders: keep border values as they are
¼*
15 20 24 23 16 10
19 28 38 35 23 15
20 35 48 43 28 21
19 31 42 36 26 28
20 15 65 30 15 30
15 20 30 20 25 30
20 25 15 20 10 15
20 21 19 16 14 15
1
2
1
Original image
¼*
27
18 23 28 25 22 21
20 21 19 16 14 15
1 2 1
2 4 2
1 2 1
*1/16Or:
5/25/2010
11
Gaussian Filtering examples
Apply the Gaussian filter (μ=0, σ=1)
15 20 25 25 15 10
20 15 50 30 20 15
20 50 55 60 30 20
to the image:
20 50 55 60 30 20
20 15 65 30 15 30
15 20 30 20 25 30
20 25 15 20 10 15
28
Original image
5/25/2010
12
Gaussian Filtering examples
Apply the Gaussian filter (μ=0, σ=0.2)
t th i
15 20 25 25 15 10
20 15 50 30 20 15
20 50 55 60 30 20
to the image:
20 15 65 30 15 30
15 20 30 20 25 30
20 25 15 20 10 15
O i i l i
29
Original image
5/25/2010
13
Gaussian Filtering
Gaussian filtering is used to remove noise and detail It is notGaussian filtering is used to remove noise and detail. It is not
particularly effective at removing salt and pepper noise.
Compare the results below with those achieved by the median filter.
30
5/25/2010
14
Gaussian Filtering
Gaussian filtering is more effective at smoothing images. It has its basis
in the human visual perception system It has been found thatin the human visual perception system. It has been found that
neurons create a similar filter when processing visual images.
The halftone image at left has been smoothed with a Gaussian filter
and is displayed to the right.
31
5/25/2010
15
Gaussian Filtering
This is a common first step in edge detectionThis is a common first step in edge detection.
The images below have been processed with a Sobel filter commonly
used in edge detection applications. The image to the right has had
a Gaussian filter applied prior to processing.
32

More Related Content

What's hot

Chapter 6 color image processing
Chapter 6 color image processingChapter 6 color image processing
Chapter 6 color image processingasodariyabhavesh
 
Spatial Filters (Digital Image Processing)
Spatial Filters (Digital Image Processing)Spatial Filters (Digital Image Processing)
Spatial Filters (Digital Image Processing)Kalyan Acharjya
 
Chapter 9 morphological image processing
Chapter 9 morphological image processingChapter 9 morphological image processing
Chapter 9 morphological image processingasodariyabhavesh
 
Image Processing: Spatial filters
Image Processing: Spatial filtersImage Processing: Spatial filters
Image Processing: Spatial filtersA B Shinde
 
Digital Image Processing: Image Segmentation
Digital Image Processing: Image SegmentationDigital Image Processing: Image Segmentation
Digital Image Processing: Image SegmentationMostafa G. M. Mostafa
 
Chapter 3 image enhancement (spatial domain)
Chapter 3 image enhancement (spatial domain)Chapter 3 image enhancement (spatial domain)
Chapter 3 image enhancement (spatial domain)asodariyabhavesh
 
Image Restoration (Frequency Domain Filters):Basics
Image Restoration (Frequency Domain Filters):BasicsImage Restoration (Frequency Domain Filters):Basics
Image Restoration (Frequency Domain Filters):BasicsKalyan Acharjya
 
Region based segmentation
Region based segmentationRegion based segmentation
Region based segmentationramya marichamy
 
Lect 02 first portion
Lect 02   first portionLect 02   first portion
Lect 02 first portionMoe Moe Myint
 
Image Enhancement in Spatial Domain
Image Enhancement in Spatial DomainImage Enhancement in Spatial Domain
Image Enhancement in Spatial DomainA B Shinde
 
Chapter 1 and 2 gonzalez and woods
Chapter 1 and 2 gonzalez and woodsChapter 1 and 2 gonzalez and woods
Chapter 1 and 2 gonzalez and woodsasodariyabhavesh
 
Implementation and comparison of Low pass filters in Frequency domain
Implementation and comparison of Low pass filters in Frequency domainImplementation and comparison of Low pass filters in Frequency domain
Implementation and comparison of Low pass filters in Frequency domainZara Tariq
 
Image segmentation techniques
Image segmentation techniquesImage segmentation techniques
Image segmentation techniquesgmidhubala
 
Image Representation & Descriptors
Image Representation & DescriptorsImage Representation & Descriptors
Image Representation & DescriptorsPundrikPatel
 
Smoothing Filters in Spatial Domain
Smoothing Filters in Spatial DomainSmoothing Filters in Spatial Domain
Smoothing Filters in Spatial DomainMadhu Bala
 
digital image processing
digital image processingdigital image processing
digital image processingAbinaya B
 

What's hot (20)

Chapter 6 color image processing
Chapter 6 color image processingChapter 6 color image processing
Chapter 6 color image processing
 
Spatial Filters (Digital Image Processing)
Spatial Filters (Digital Image Processing)Spatial Filters (Digital Image Processing)
Spatial Filters (Digital Image Processing)
 
Chapter 9 morphological image processing
Chapter 9 morphological image processingChapter 9 morphological image processing
Chapter 9 morphological image processing
 
Hit and-miss transform
Hit and-miss transformHit and-miss transform
Hit and-miss transform
 
Image Processing: Spatial filters
Image Processing: Spatial filtersImage Processing: Spatial filters
Image Processing: Spatial filters
 
Digital image processing
Digital image processing  Digital image processing
Digital image processing
 
NOISE FILTERS IN IMAGE PROCESSING
NOISE FILTERS IN IMAGE PROCESSINGNOISE FILTERS IN IMAGE PROCESSING
NOISE FILTERS IN IMAGE PROCESSING
 
Digital Image Processing: Image Segmentation
Digital Image Processing: Image SegmentationDigital Image Processing: Image Segmentation
Digital Image Processing: Image Segmentation
 
Chapter 3 image enhancement (spatial domain)
Chapter 3 image enhancement (spatial domain)Chapter 3 image enhancement (spatial domain)
Chapter 3 image enhancement (spatial domain)
 
Image Restoration (Frequency Domain Filters):Basics
Image Restoration (Frequency Domain Filters):BasicsImage Restoration (Frequency Domain Filters):Basics
Image Restoration (Frequency Domain Filters):Basics
 
Digital Image Processing
Digital Image ProcessingDigital Image Processing
Digital Image Processing
 
Region based segmentation
Region based segmentationRegion based segmentation
Region based segmentation
 
Lect 02 first portion
Lect 02   first portionLect 02   first portion
Lect 02 first portion
 
Image Enhancement in Spatial Domain
Image Enhancement in Spatial DomainImage Enhancement in Spatial Domain
Image Enhancement in Spatial Domain
 
Chapter 1 and 2 gonzalez and woods
Chapter 1 and 2 gonzalez and woodsChapter 1 and 2 gonzalez and woods
Chapter 1 and 2 gonzalez and woods
 
Implementation and comparison of Low pass filters in Frequency domain
Implementation and comparison of Low pass filters in Frequency domainImplementation and comparison of Low pass filters in Frequency domain
Implementation and comparison of Low pass filters in Frequency domain
 
Image segmentation techniques
Image segmentation techniquesImage segmentation techniques
Image segmentation techniques
 
Image Representation & Descriptors
Image Representation & DescriptorsImage Representation & Descriptors
Image Representation & Descriptors
 
Smoothing Filters in Spatial Domain
Smoothing Filters in Spatial DomainSmoothing Filters in Spatial Domain
Smoothing Filters in Spatial Domain
 
digital image processing
digital image processingdigital image processing
digital image processing
 

Similar to Gaussian filtering 1up

Computer Vision - Image Filters
Computer Vision - Image FiltersComputer Vision - Image Filters
Computer Vision - Image FiltersYoss Cohen
 
ImageSegmentation (1).ppt
ImageSegmentation (1).pptImageSegmentation (1).ppt
ImageSegmentation (1).pptNoorUlHaq47
 
ImageSegmentation.ppt
ImageSegmentation.pptImageSegmentation.ppt
ImageSegmentation.pptAVUDAI1
 
ImageSegmentation.ppt
ImageSegmentation.pptImageSegmentation.ppt
ImageSegmentation.pptDEEPUKUMARR
 
Spatial Filtering in intro image processingr
Spatial Filtering in intro image processingrSpatial Filtering in intro image processingr
Spatial Filtering in intro image processingrkumarankit06875
 
DIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehr
DIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehrDIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehr
DIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehrstudyd133
 
Math behind the kernels
Math behind the kernelsMath behind the kernels
Math behind the kernelsRevanth Kumar
 
International Journal of Computational Engineering Research(IJCER)
International Journal of Computational Engineering Research(IJCER)International Journal of Computational Engineering Research(IJCER)
International Journal of Computational Engineering Research(IJCER)ijceronline
 
05_Spatial_Filtering.ppt
05_Spatial_Filtering.ppt05_Spatial_Filtering.ppt
05_Spatial_Filtering.pptpawankamal3
 
Spatial filtering
Spatial filteringSpatial filtering
Spatial filteringDeepikaT13
 
SINGLE‐PHASE TO THREE‐PHASE DRIVE SYSTEM USING TWO PARALLEL SINGLE‐PHASE RECT...
SINGLE‐PHASE TO THREE‐PHASE DRIVE SYSTEM USING TWO PARALLEL SINGLE‐PHASE RECT...SINGLE‐PHASE TO THREE‐PHASE DRIVE SYSTEM USING TWO PARALLEL SINGLE‐PHASE RECT...
SINGLE‐PHASE TO THREE‐PHASE DRIVE SYSTEM USING TWO PARALLEL SINGLE‐PHASE RECT...ijiert bestjournal
 
Global threshold and region based active contour model for accurate image seg...
Global threshold and region based active contour model for accurate image seg...Global threshold and region based active contour model for accurate image seg...
Global threshold and region based active contour model for accurate image seg...sipij
 
Applied numerical methods lec6
Applied numerical methods lec6Applied numerical methods lec6
Applied numerical methods lec6Yasser Ahmed
 
BilateralFiltering
BilateralFilteringBilateralFiltering
BilateralFilteringJacob Logas
 

Similar to Gaussian filtering 1up (20)

Computer Vision - Image Filters
Computer Vision - Image FiltersComputer Vision - Image Filters
Computer Vision - Image Filters
 
Image segmentation
Image segmentationImage segmentation
Image segmentation
 
ImageSegmentation (1).ppt
ImageSegmentation (1).pptImageSegmentation (1).ppt
ImageSegmentation (1).ppt
 
ImageSegmentation.ppt
ImageSegmentation.pptImageSegmentation.ppt
ImageSegmentation.ppt
 
ImageSegmentation.ppt
ImageSegmentation.pptImageSegmentation.ppt
ImageSegmentation.ppt
 
Spatial Filtering in intro image processingr
Spatial Filtering in intro image processingrSpatial Filtering in intro image processingr
Spatial Filtering in intro image processingr
 
DIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehr
DIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehrDIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehr
DIP_Lecture6.pdf. jdowjwdieehekehdjejrejwhehr
 
linkd
linkdlinkd
linkd
 
Math behind the kernels
Math behind the kernelsMath behind the kernels
Math behind the kernels
 
P1161211140
P1161211140P1161211140
P1161211140
 
International Journal of Computational Engineering Research(IJCER)
International Journal of Computational Engineering Research(IJCER)International Journal of Computational Engineering Research(IJCER)
International Journal of Computational Engineering Research(IJCER)
 
channel_mzhazbay.pdf
channel_mzhazbay.pdfchannel_mzhazbay.pdf
channel_mzhazbay.pdf
 
05_Spatial_Filtering.ppt
05_Spatial_Filtering.ppt05_Spatial_Filtering.ppt
05_Spatial_Filtering.ppt
 
Spatial filtering
Spatial filteringSpatial filtering
Spatial filtering
 
SINGLE‐PHASE TO THREE‐PHASE DRIVE SYSTEM USING TWO PARALLEL SINGLE‐PHASE RECT...
SINGLE‐PHASE TO THREE‐PHASE DRIVE SYSTEM USING TWO PARALLEL SINGLE‐PHASE RECT...SINGLE‐PHASE TO THREE‐PHASE DRIVE SYSTEM USING TWO PARALLEL SINGLE‐PHASE RECT...
SINGLE‐PHASE TO THREE‐PHASE DRIVE SYSTEM USING TWO PARALLEL SINGLE‐PHASE RECT...
 
Global threshold and region based active contour model for accurate image seg...
Global threshold and region based active contour model for accurate image seg...Global threshold and region based active contour model for accurate image seg...
Global threshold and region based active contour model for accurate image seg...
 
Input analysis
Input analysisInput analysis
Input analysis
 
Edge detection-LOG
Edge detection-LOGEdge detection-LOG
Edge detection-LOG
 
Applied numerical methods lec6
Applied numerical methods lec6Applied numerical methods lec6
Applied numerical methods lec6
 
BilateralFiltering
BilateralFilteringBilateralFiltering
BilateralFiltering
 

Recently uploaded

ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...Christina Lin
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio, Inc.
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptkotipi9215
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfkalichargn70th171
 
The Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfThe Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfPower Karaoke
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationkaushalgiri8080
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...gurkirankumar98700
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number SystemsJheuzeDellosa
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataAdobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataBradBedford3
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about usDynamic Netsoft
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)OPEN KNOWLEDGE GmbH
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...aditisharan08
 
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...MyIntelliSource, Inc.
 
Hand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxHand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxbodapatigopi8531
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideChristina Lin
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 

Recently uploaded (20)

ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.ppt
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
 
The Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfThe Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdf
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanation
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number Systems
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataAdobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about us
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...
 
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
 
Hand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxHand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptx
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 

Gaussian filtering 1up

  • 1. 5/25/2010 1 Gaussian Filtering Gaussian filtering is used to blur images and remove noise and detail.g g In one dimension, the Gaussian function is: Where σ is the standard deviation of the distribution The distribution is 2 2 2 2 1 ( ) 2 x G x e σ πσ − = Where σ is the standard deviation of the distribution. The distribution is assumed to have a mean of 0. Shown graphically, we see the familiar bell shaped Gaussian distribution. 18 Gaussian distribution with mean 0 and σ = 1
  • 2. 5/25/2010 2 Gaussian filtering • Significant values 2 2 2 2 0.5/ 2/ 9/4 8/ 0 1 2 3 4 * ( ) / 0.399 1 x G x e e e e σ σ σ σ σ − − − − 2 2 2 2 0.5/ 2/ 9/4 8/ ( ) / 0.399 1 ( ) / (0) 1 G x e e e e G x G e e e e σ σ σ σ σ − − − − 0 1 2x For σ=1: 19 0 1 2 ( ) 0.399 0.242 0.05 ( ) / (0) 1 0.6 0.125 x G x G x G
  • 3. 5/25/2010 3 Gaussian Filtering Standard Deviation Th St d d d i ti f th G i f ti l i t tThe Standard deviation of the Gaussian function plays an important role in its behaviour. The values located between +/- σ account for 68% of the set, while two standard deviations from the mean (blue and brown) account for 95%, and three standard deviations (blue, brown and green) account for 99.7%.account for 99.7%. This is very important when designing a Gaussian kernel of fixed length. 20 Distribution of the Gaussian function values (Wikipedia)
  • 4. 5/25/2010 4 Gaussian Filtering The Gaussian function is used in numerous research areas: – It defines a probability distribution for noise or data. – It is a smoothing operator. – It is used in mathematics. The Gaussian function has important properties which are verified withThe Gaussian function has important properties which are verified with respect to its integral: In probabilistic terms, it describes 100% of the possible values of any given space when varying from negative to positive values ( )2 exp xI dx π ∞ −∞ = − =∫ 21 given space when varying from negative to positive values Gauss function is never equal to zero. It is a symmetric function.
  • 5. 5/25/2010 5 Gaussian Filtering Wh ki ith i d t th t di i lWhen working with images we need to use the two dimensional Gaussian function. This is simply the product of two 1D Gaussian functions (one for each direction) and is given by: 2 2 2 2 1 ( ) x y G + − A graphical representation of the 2D Gaussian distribution with mean(0,0) 2 2 2 ( , ) 2 G x y e σ πσ = 22 and σ = 1 is shown to the right.
  • 6. 5/25/2010 6 Gaussian Filtering Th G i filt k b i th 2D di t ib ti i t dThe Gaussian filter works by using the 2D distribution as a point-spread function. This is achieved by convolving the 2D Gaussian distribution function with the image. We need to produce a discrete approximation to the Gaussian function. Thi th ti ll i i fi it l l l ti k l thThis theoretically requires an infinitely large convolution kernel, as the Gaussian distribution is non-zero everywhere. Fortunately the distribution has approached very close to zero at about three standard deviations from the mean. 99% of the distribution falls within 3 standard deviations. This means we can normally limit the kernel size to contain only values 23 This means we can normally limit the kernel size to contain only values within three standard deviations of the mean.
  • 7. 5/25/2010 7 Gaussian Filtering G i k l ffi i t l d f th 2D G iGaussian kernel coefficients are sampled from the 2D Gaussian function. Where σ is the standard deviation of the distribution. 2 2 2 2 2 1 ( , ) 2 x y G x y e σ πσ + − = The distribution is assumed to have a mean of zero. We need to discretize the continuous Gaussian functions to store it as discrete pixels. An integer valued 5 by 5 convolution 1 4 7 4 1 4 16 26 16 4 7 26 41 26 7 1 24 kernel approximating a Gaussian with a σ of 1 is shown to the right, 7 26 41 26 7 4 16 26 16 4 1 4 7 4 1 1 273
  • 8. 5/25/2010 8 Gaussian Filtering The Gaussian filter is a non-uniform low pass filter. The kernel coefficients diminish with increasing distance from the kernel’s centre. Central pixels have a higher weighting than those on the periphery. Larger values of σ produce a wider peak (greater blurring). Kernel size must increase with increasing σ to maintain the Gaussiang nature of the filter. Gaussian kernel coefficients depend on the value of σ. At the edge of the mask, coefficients must be close to 0. The kernel is rotationally symmetric with no directional bias. Gaussian kernel is separable which allows fast computation 25 Gaussian kernel is separable, which allows fast computation. Gaussian filters might not preserve image brightness.
  • 9. 5/25/2010 9 Gaussian Filtering examples Is the kernel a 1D Gaussian kernel?1 6 1Is the kernel a 1D Gaussian kernel? Give a suitable integer-value 5 by 5 convolution mask that approximates a Gaussian function with a σ of 1.4. How many standard deviations from the mean are required for a Gaussian function to fall to 5% or 1% of 1 6 1 required for a Gaussian function to fall to 5%, or 1% of its peak value? What is the value of σ for which the value of the Gaussian function is halved at +/-1 x. Compute the horizontal Gaussian kernel with mean=0 26 Compute the horizontal Gaussian kernel with mean=0 and σ=1, σ=5.
  • 10. 5/25/2010 10 Gaussian Filtering examples 15 20 24 23 16 10Apply the Gaussian filter to the image: Borders: keep border values as they are 15 20 25 25 15 10 20 15 50 30 20 15 20 50 55 60 30 20 20 15 65 30 15 30 20 25 36 33 21 15 20 44 55 51 35 20 20 29 44 35 22 30 15 21 25 24 25 30 20 21 19 16 14 15 1 2 1 Borders: keep border values as they are ¼* 15 20 24 23 16 10 19 28 38 35 23 15 20 35 48 43 28 21 19 31 42 36 26 28 20 15 65 30 15 30 15 20 30 20 25 30 20 25 15 20 10 15 20 21 19 16 14 15 1 2 1 Original image ¼* 27 18 23 28 25 22 21 20 21 19 16 14 15 1 2 1 2 4 2 1 2 1 *1/16Or:
  • 11. 5/25/2010 11 Gaussian Filtering examples Apply the Gaussian filter (μ=0, σ=1) 15 20 25 25 15 10 20 15 50 30 20 15 20 50 55 60 30 20 to the image: 20 50 55 60 30 20 20 15 65 30 15 30 15 20 30 20 25 30 20 25 15 20 10 15 28 Original image
  • 12. 5/25/2010 12 Gaussian Filtering examples Apply the Gaussian filter (μ=0, σ=0.2) t th i 15 20 25 25 15 10 20 15 50 30 20 15 20 50 55 60 30 20 to the image: 20 15 65 30 15 30 15 20 30 20 25 30 20 25 15 20 10 15 O i i l i 29 Original image
  • 13. 5/25/2010 13 Gaussian Filtering Gaussian filtering is used to remove noise and detail It is notGaussian filtering is used to remove noise and detail. It is not particularly effective at removing salt and pepper noise. Compare the results below with those achieved by the median filter. 30
  • 14. 5/25/2010 14 Gaussian Filtering Gaussian filtering is more effective at smoothing images. It has its basis in the human visual perception system It has been found thatin the human visual perception system. It has been found that neurons create a similar filter when processing visual images. The halftone image at left has been smoothed with a Gaussian filter and is displayed to the right. 31
  • 15. 5/25/2010 15 Gaussian Filtering This is a common first step in edge detectionThis is a common first step in edge detection. The images below have been processed with a Sobel filter commonly used in edge detection applications. The image to the right has had a Gaussian filter applied prior to processing. 32