Linear Filtering About modifying pixels based on neighborhood. Local methods simplest. Linear means linear combination of neighbors. Linear methods simplest.

Slides:



Advertisements
Similar presentations
Linear Filtering – Part I Selim Aksoy Department of Computer Engineering Bilkent University
Advertisements

Motion illusion, rotating snakes. Slide credit Fei Fei Li.
E.G.M. PetrakisFiltering1 Linear Systems Many image processing (filtering) operations are modeled as a linear system Linear System δ(x,y) h(x,y)
Edge detection Goal: Identify sudden changes (discontinuities) in an image Intuitively, most semantic and shape information from the image can be encoded.
Lecture 4 Linear Filters and Convolution
Image Filtering CS485/685 Computer Vision Prof. George Bebis.
Image processing. Image operations Operations on an image –Linear filtering –Non-linear filtering –Transformations –Noise removal –Segmentation.
Computer Vision - A Modern Approach
Computer Vision Introduction to Image formats, reading and writing images, and image environments Image filtering.
CS 376b Introduction to Computer Vision 02 / 27 / 2008 Instructor: Michael Eckmann.
Lecture 1: Images and image filtering
1 Image Filtering Readings: Ch 5: 5.4, 5.5, 5.6,5.7.3, 5.8 (This lecture does not follow the book.) Images by Pawan SinhaPawan Sinha formal terminology.
Linear filtering. Overview: Linear filtering Linear filters Definition and properties Examples Gaussian smoothing Separability Applications Denoising.
Linear filters and edges. Linear Filters General process: Form new image whose pixels are a weighted sum of original pixel values, using the same set.
CS443: Digital Imaging and Multimedia Filters Spring 2008 Ahmed Elgammal Dept. of Computer Science Rutgers University Spring 2008 Ahmed Elgammal Dept.
Announcements Kevin Matzen office hours – Tuesday 4-5pm, Thursday 2-3pm, Upson 317 TA: Yin Lou Course lab: Upson 317 – Card access will be setup soon Course.
Matlab Tutorial Continued Files, functions and images.
Linear filtering.
Basic Image Processing January 26, 30 and February 1.
Most slides from Steve Seitz
CS 376b Introduction to Computer Vision 02 / 26 / 2008 Instructor: Michael Eckmann.
Machine Vision ENT 273 Image Filters Hema C.R. Lecture 5.
CS559: Computer Graphics Lecture 3: Digital Image Representation Li Zhang Spring 2008.
Lecture 03 Area Based Image Processing Lecture 03 Area Based Image Processing Mata kuliah: T Computer Vision Tahun: 2010.
Linear Filters Monday, Jan 24 Prof. Kristen Grauman UT-Austin …
Why is computer vision difficult?
Digital Image Processing Lecture 10: Image Restoration March 28, 2005 Prof. Charlene Tsai.
Chapter 5: Neighborhood Processing
Linear filtering. Motivation: Noise reduction Given a camera and a still scene, how can you reduce noise? Take lots of images and average them! What’s.
Digital Image Processing Lecture 10: Image Restoration
CSE 473/573 Computer Vision and Image Processing (CVIP) Ifeoma Nwogu Lecture 7 – Linear Filters 1.
Course 2 Image Filtering. Image filtering is often required prior any other vision processes to remove image noise, overcome image corruption and change.
Intelligent Vision Systems ENT 496 Image Filtering and Enhancement Hema C.R. Lecture 4.
CS654: Digital Image Analysis
Mestrado em Ciência de Computadores Mestrado Integrado em Engenharia de Redes e Sistemas Informáticos VC 15/16 – TP7 Spatial Filters Miguel Tavares Coimbra.
Visual Computing Computer Vision 2 INFO410 & INFO350 S2 2015
CS 691B Computational Photography
Lecture 3: Filtering and Edge detection
Reconnaissance d’objets et vision artificielle
Linear filtering. Motivation: Image denoising How can we reduce noise in a photograph?
Instructor: Mircea Nicolescu Lecture 5 CS 485 / 685 Computer Vision.
Filtering (II) Dr. Chang Shu COMP 4900C Winter 2008.
Last Lecture photomatix.com. Today Image Processing: from basic concepts to latest techniques Filtering Edge detection Re-sampling and aliasing Image.
CSE 185 Introduction to Computer Vision Image Filtering: Spatial Domain.
Grauman Today: Image Filters Smooth/Sharpen Images... Find edges... Find waldo…
Lecture 1: Images and image filtering CS4670/5670: Intro to Computer Vision Noah Snavely Hybrid Images, Oliva et al.,
Non-linear filtering Example: Median filter Replaces pixel value by median value over neighborhood Generates no new gray levels.
Image Processing Goal –Start simple: look at small windows –Identify useful image structures (‘Clues’ useful for recognizing objects) –Eliminate irrelevant.
Filters– Chapter 6. Filter Difference between a Filter and a Point Operation is that a Filter utilizes a neighborhood of pixels from the input image to.
HCI/ComS 575X: Computational Perception Instructor: Alexander Stoytchev
Miguel Tavares Coimbra
Correlation and Convolution They replace the value of an image pixel with a combination of its neighbors Basic operations in images Shift Invariant Linear.
Digital Image Processing Lecture 10: Image Restoration
Linear Filters and Edges Chapters 7 and 8
Filtering – Part I Gokberk Cinbis Department of Computer Engineering
Recap from Wednesday Spectra and Color Light capture in cameras and humans.
Filters (Smoothing, Edge Detection)
Image filtering Images by Pawan Sinha.
Image filtering Images by Pawan Sinha.
Linear filtering.
Lecture 5: Resampling, Compositing, and Filtering Li Zhang Spring 2008
Basic Image Processing
Digital Image Processing Week IV
Most slides from Steve Seitz
Image filtering
Image filtering
Lecture 2: Image filtering
Image Filtering Readings: Ch 5: 5. 4, 5. 5, 5. 6, , 5
Most slides from Steve Seitz
Presentation transcript:

Linear Filtering About modifying pixels based on neighborhood. Local methods simplest. Linear means linear combination of neighbors. Linear methods simplest. Useful to: –Integrate information over constant regions. –Scale. –Detect changes. Fourier analysis. Many nice slides taken from Bill Freeman.

(Freeman)

Correlation Examples on white board – 1D Examples -2D

For example, let’s take a vector like: ( ), and filter it with a filter like (1/3 1/3 1/3) Ignoring the ends for the moment, we get a result like: 2 2 1/3 2 2/3 2 1/3 2. We can also graph the results and see that the original vector is smoothed out.

Boundaries Zeros Repeat values Cycle Produce shorter result Examples

Correlation For this notation, we index F from –N to N.

Convolution Like Correlation with Filter Reversed Associative 1D 2D

Some Examples

Filtering to reduce noise Noise is what we’re not interested in. –We’ll discuss simple, low-level noise today: Light fluctuations; Sensor noise; Quantization effects; Finite precision –Not complex: shadows; extraneous objects. A pixel’s neighborhood contains information about its intensity. Averaging noise reduces its effect.

Additive noise I = S + N. Noise doesn’t depend on signal. We’ll consider:

Average Filter Mask with positive entries, that sum 1. Replaces each pixel with an average of its neighborhood. If all weights are equal, it is called a BOX filter F1/9 (Camps)

Averaging Filter and noise reduction Example: try executing: k=1; figure(1); hist(sum((1/k)*rand(k,1000))) for different values of k. The average of noise is smaller than one example. –This is intuitive –Can be proven in many cases (some technical conditions: noise must be independent, many samples….) –Actually true for many real examples: Gaussian noise, flipping a coin many times

Filtering reduces noise if signal stable Suppose I(i) = I+n(i), I(i+1) = I+n(i+1) I(i+2) = I+n(i+2). Average of I(i), I(i+1), I(i+2) = I + average of n(i), n(i+1), n(i+2). When there is no noise, averaging smooths the signal. So in real life, averaging does both.

Does it reduce noise? Intuitively, takes out small variations. (Camps)

Let a and b be normally distributed, zero mean. E((a+b)/2)^2 = E(a/2)^2 + E(b/2)^2 = 2sigma^2/4 = sigma^2/2

Matlab Demo of Averaging

Example: Smoothing by Averaging

Smoothing as Inference About the Signal += Nearby points tell more about the signal than distant ones. Neighborhood for averaging.

Gaussian Averaging Rotationally symmetric. Weights nearby pixels more than distant ones. –This makes sense as probabalistic inference. A Gaussian gives a good model of a fuzzy blob

An Isotropic Gaussian The picture shows a smoothing kernel proportional to (which is a reasonable model of a circularly symmetric fuzzy blob)

Smoothing with a Gaussian

The effects of smoothing Each row shows smoothing with gaussians of different width; each column shows different realizations of an image of gaussian noise.

Efficient Implementation Both, the BOX filter and the Gaussian filter are separable: –First convolve each row with a 1D filter –Then convolve each column with a 1D filter.

Box Filter

Gaussian Filter

Smoothing as Inference About the Signal: Non-linear Filters. += What’s the best neighborhood for inference?

Filtering to reduce noise: Lessons Noise reduction is probabilistic inference. Depends on knowledge of signal and noise. In practice, simplicity and efficiency important.

Filtering and Signal Smoothing also smooths signal. Matlab Removes detail Matlab This is good and bad: - Bad: can’t remove noise w/out blurring shape. - Good: captures large scale structure; allows subsampling.

Subsampling Matlab