EE465: Introduction to Digital Image Processing 1 What is in Common?

Slides:



Advertisements
Similar presentations
Course Syllabus 1.Color 2.Camera models, camera calibration 3.Advanced image pre-processing Line detection Corner detection Maximally stable extremal regions.
Advertisements

Chapter 9: Morphological Image Processing
Some Basic Morphological Algorithm
Course Syllabus 1.Color 2.Camera models, camera calibration 3.Advanced image pre-processing Line detection Corner detection Maximally stable extremal regions.
Digital Image Processing Lecture 12: Image Topology
Each pixel is 0 or 1, background or foreground Image processing to
Morphological Image Processing Md. Rokanujjaman Assistant Professor Dept of Computer Science and Engineering Rajshahi University.
September 10, 2013Computer Vision Lecture 3: Binary Image Processing 1Thresholding Here, the right image is created from the left image by thresholding,
Provides mathematical tools for shape analysis in both binary and grayscale images Chapter 13 – Mathematical Morphology Usages: (i)Image pre-processing.
Chapter 5 Raster –based algorithms in CAC. 5.1 area filling algorithm 5.2 distance transformation graph and skeleton graph generation algorithm 5.3 convolution.
Digital Image Processing, 2nd ed. © 2002 R. C. Gonzalez & R. E. Woods Chapter 9 Morphological Image Processing Chapter 9 Morphological.
Morphology Structural processing of images Image Processing and Computer Vision: 33 Morphological Transformations Set theoretic methods of extracting.
Chapter 9 Morphological Image Processing. Preview Morphology: denotes a branch of biology that deals with the form and structure of animals and planets.
Introduction to Computer Vision
Morphological Image Processing Spring 2006, Jen-Chang Liu.
Course Website: Digital Image Processing Morphological Image Processing.
Computer Vision Basics Image Terminology Binary Operations Filtering Edge Operators.
Lectures 10&11: Representation and description
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
Morphological Image Processing
2007Theo Schouten1 Morphology Set theory is the mathematical basis for morphology. Sets in Euclidic space E 2 (or rather Z 2 : the set of pairs of integers)
E.G.M. PetrakisBinary Image Processing1 Binary Image Analysis Segmentation produces homogenous regions –each region has uniform gray-level –each region.
Lecture 5. Morphological Image Processing. 10/6/20152 Introduction ► ► Morphology: a branch of biology that deals with the form and structure of animals.
MATHEMATICAL MORPHOLOGY I.INTRODUCTION II.BINARY MORPHOLOGY III.GREY-LEVEL MORPHOLOGY.
Mathematical Morphology Lecture 14 Course book reading: GW Lucia Ballerini Digital Image Processing.
Chapter 9.  Mathematical morphology: ◦ A useful tool for extracting image components in the representation of region shape.  Boundaries, skeletons,
Course Syllabus 1.Color 2.Camera models, camera calibration 3.Advanced image pre-processing Line detection Corner detection Maximally stable extremal regions.
Digital Image Processing Chapter 9: Morphological Image Processing 5 September 2007 Digital Image Processing Chapter 9: Morphological Image Processing.
Morphological Processing
Digital Image Processing CCS331 Relationships of Pixel 1.
Morphological Image Processing
Gianni Ramponi University of Trieste Images © 2002 Gonzalez & Woods Digital Image Processing Chapter 9 Morphological Image.
Digital Image Processing CSC331 Morphological image processing 1.
Morphological Image Processing การทำงานกับรูปภาพด้วยวิธีมอร์โฟโลจิคัล
CS654: Digital Image Analysis
Low level Computer Vision 1. Thresholding 2. Convolution 3. Morphological Operations 4. Connected Component Extraction 5. Feature Extraction 1.
References Books: Chapter 11, Image Processing, Analysis, and Machine Vision, Sonka et al Chapter 9, Digital Image Processing, Gonzalez & Woods.
Morphological Filtering
CS654: Digital Image Analysis
EE 4780 Morphological Image Processing. Bahadir K. Gunturk2 Example Two semiconductor wafer images are given. You are supposed to determine the defects.
Image Processing and Analysis (ImagePandA)
1 Mathematic Morphology used to extract image components that are useful in the representation and description of region shape, such as boundaries extraction.
Morphological Image Processing Robotics. 2/22/2016Introduction to Machine Vision Remember from Lecture 12: GRAY LEVEL THRESHOLDING Objects Set threshold.
BYST Morp-1 DIP - WS2002: Morphology Digital Image Processing Morphological Image Processing Bundit Thipakorn, Ph.D. Computer Engineering Department.
Morphology Morphology deals with form and structure Mathematical morphology is a tool for extracting image components useful in: –representation and description.
Course 3 Binary Image Binary Images have only two gray levels: “1” and “0”, i.e., black / white. —— save memory —— fast processing —— many features of.
Lecture(s) 3-4. Morphological Image Processing. 3/13/20162 Introduction ► ► Morphology: a branch of biology that deals with the form and structure of.
Chapter 6 Skeleton & Morphological Operation. Image Processing for Pattern Recognition Feature Extraction Acquisition Preprocessing Classification Post.
Digital Image Processing, Spring ECES 682 Digital Image Processing Week 8 Oleh Tretiak ECE Department Drexel University.
Morphological Image Processing (Chapter 9) CSC 446 Lecturer: Nada ALZaben.
Morphological Image Processing
Lecture 11+x+1 Chapter 9 Morphological Image Processing.
Digital Image Processing Lecture 15: Morphological Algorithms April 27, 2005 Prof. Charlene Tsai.
Image Representation and Description – Representation Schemes
Digital Image Processing CP-7008 Lecture # 09 Morphological Image Processing Fall 2011.
CSE 554 Lecture 1: Binary Pictures
Binary Image Processing
Introduction to Morphological Operators
Computer Vision Lecture 5: Binary Image Processing
Binary Image Analysis used in a variety of applications:
EE465: Introduction to Digital Image Processing
CS Digital Image Processing Lecture 5
Binary Image processing بهمن 92
Department of Computer Engineering
Morphological Image Processing
Digital Image Processing Lecture 15: Morphological Algorithms
ECE 692 – Advanced Topics in Computer Vision
Digital Image Processing Lecture 14: Morphology
DIGITAL IMAGE PROCESSING Elective 3 (5th Sem.)
Binary Image Analysis used in a variety of applications:
Presentation transcript:

EE465: Introduction to Digital Image Processing 1 What is in Common?

EE465: Introduction to Digital Image Processing 2 A BW Image and Its Inverse

EE465: Introduction to Digital Image Processing 3 Application (I): FAX Document

EE465: Introduction to Digital Image Processing 4 Application (II): Scanned Documents

EE465: Introduction to Digital Image Processing 5 Application (III): Biometrics

EE465: Introduction to Digital Image Processing 6 Application (IV): Image Matting figure-ground segmentation in computer vision

EE465: Introduction to Digital Image Processing 7 Binary Image Processing Introduction Set theory review Morphological filtering operators Erosion and dilation Opening and closing Hit-or-miss Boundary extraction Region-filling Thinning (for finding skeleton) Other processing algorithms Area calculation, finding connected components Skeleton finding via distance transform

EE465: Introduction to Digital Image Processing 8 Binary Images Images only consist of two colors (tones): white or black Numerical example (image of a square block)

EE465: Introduction to Digital Image Processing 9 Why are binary images special? Since pixels are either white or black, the locations of white (black) pixels carry ALL information of binary images Example f(m,n) L={(3,3),(3,4),(4,3),(4,4)} location of white pixels It is often more convenient to consider the set representation than the matrix representation for binary images matrix representationset representation

EE465: Introduction to Digital Image Processing 10 Binary Image Processing Introduction Set theory review Morphological filtering operators Erosion and dilation Opening and closing Hit-or-miss Boundary extraction Region-filling Thinning (for finding skeleton) Other processing algorithms Area calculation, finding connected components Skeleton finding via distance transform

EE465: Introduction to Digital Image Processing 11 Set Theory Review Think of sets A and B as the collections of spatial coordinates

EE465: Introduction to Digital Image Processing 12 Translation Operator Example

EE465: Introduction to Digital Image Processing 13 Reflection Operator Example B B ^

EE465: Introduction to Digital Image Processing 14 Binary Image Processing Introduction Set theory review Morphological filtering operators Erosion and dilation Opening and closing Hit-or-miss Boundary extraction Region-filling Thinning (for finding skeleton) Other processing algorithms Area calculation, finding connected components Skeleton finding via distance transform

EE465: Introduction to Digital Image Processing 15 Structuring Element B Definition: a set of local neighborhood with specified origin Examples origin B1B1 B2B2 Note: different structuring element leads to different filtering result

EE465: Introduction to Digital Image Processing 16 mask B X Y Definition Example Dilation or

EE465: Introduction to Digital Image Processing 17 X XcaXca B={a,b,c} a=(0,0),b=(0,-1),c=(-1,0) origin XcbXcb B XccXcc Illustration by Animation

EE465: Introduction to Digital Image Processing 18 mask B X Y Definition Example Erosion Y=X B _

EE465: Introduction to Digital Image Processing 19 mask B X Y Illustration By Animation

EE465: Introduction to Digital Image Processing 20 (X B) c _ =X c  B ^ Duality Property* Proof: (X B) c _ ={z | B z  A } c = {z | B z  A c =  } c = {z | B z  A c  } =X c  B ^

EE465: Introduction to Digital Image Processing 21 X B XcXc B ^ (X B) c _ X B _ XcBXcB ^ Example

EE465: Introduction to Digital Image Processing 22 Binary Image Processing Introduction Set theory review Morphological filtering operators Erosion and dilation Opening and closing Hit-or-miss Boundary extraction Region-filling Thinning (for finding skeleton) Other processing algorithms Area calculation, finding connected components Skeleton finding via distance transform

EE465: Introduction to Digital Image Processing 23 (X B) B _ + Definition mask B X _ + Opening Operator Example

EE465: Introduction to Digital Image Processing 24 Geometric Interpretation of Opening Operator

EE465: Introduction to Digital Image Processing 25 Definition (X B) B+ _ _ + mask B X Closing Operator Example

EE465: Introduction to Digital Image Processing 26 Geometric Interpretation of Closing Operator

EE465: Introduction to Digital Image Processing 27 Properties of Opening and Closing Operators* Opening Closing ● ● ● ● ● ●

EE465: Introduction to Digital Image Processing 28 Binary Image Processing Introduction Set theory review Morphological filtering operators Erosion and dilation Opening and closing Hit-or-miss Boundary extraction Region-filling Thinning (for finding skeleton) Other processing algorithms Area calculation, finding connected components Skeleton finding via distance transform

EE465: Introduction to Digital Image Processing 29 A Little Game of Matching Templates A B

EE465: Introduction to Digital Image Processing 30 Illustration by a Simpler Case Template B How to find the match of A in X using a computer? X Hit: the southwest quadrant must be black in X origin Hit: the other three quadrants must be white in X Hit: the southwest quadrant must be black in X Hit: the other three quadrants must be black in X c

EE465: Introduction to Digital Image Processing 31 Matching via Hit-or-Miss Template B origin Hit: the southwest quadrant must be black in X Hit: the other three quadrants must be black in X c Template B 1 Template B 2 X 1 =X B 1 _ X 2 =X c B 2 _ To satisfy both conditions, we need to take the intersection of X 1 and X 2

EE465: Introduction to Digital Image Processing 32 mask B 1 (MATLAB function: bwhitmiss) (X B 1 )  (X c B 2 ) __ X B= * HitMiss mask B 2 origin mask B x xx MATLAB Hit-or-Miss Operator Definition Structuring element example Why ? _ Why complement? Why intersection?

EE465: Introduction to Digital Image Processing 33 X Example 1 mask B 1 mask B 2 origin XcXc X c B 2 X B 1 __ X B *

EE465: Introduction to Digital Image Processing 34 mask B 1 mask B 2 mask B MATLAB Example 2 origin X XcXc X c B 2 X B 1 __ X B * Now, take the intersection and note that only two points Remain (highlighted by red)

EE465: Introduction to Digital Image Processing 35 Binary Image Processing Introduction Set theory review Morphological filtering operators Erosion and dilation Opening and closing Hit-or-miss Boundary extraction Region-filling Thinning (for finding skeleton) Other processing algorithms Area calculation, finding connected components Skeleton finding via distance transform

EE465: Introduction to Digital Image Processing 36 “BAD EXAMPLE” Y=X-(X B) _ mask B XX B _

EE465: Introduction to Digital Image Processing 37 X-(X B) _ mask B XX B _ Boundary Extraction Example  X=X-(X B) _ Definition  X=(X B) – B? + How about Note that

EE465: Introduction to Digital Image Processing 38 XX X Image Example

EE465: Introduction to Digital Image Processing 39 Inner vs. Outer Boundary

EE465: Introduction to Digital Image Processing 40 Binary Image Processing Introduction Set theory review Morphological filtering operators Erosion and dilation Opening and closing Hit-or-miss Boundary extraction Region-filling Thinning (for finding skeleton) Other processing algorithms Area calculation, finding connected components Skeleton finding via distance transform

EE465: Introduction to Digital Image Processing 41 P X Iterations: Y 0 =P Y k =(Y k-1  B)  X c, k=1,2,3… mask B Terminate when Y k =Y k-1,output Y k  X Idea: recursively expand the region around P but stop the expansion at the boundary of X Region Filling expansionstop at the boundary Why dilation? Why intersection with X c ?

EE465: Introduction to Digital Image Processing 42 XY0Y0 P Y0BY0B XcXc Y1Y1 Y1BY1B Y2Y2 Y2BY2B Y 3 =Y 2 Image Example

EE465: Introduction to Digital Image Processing 43 Additional Example P

EE465: Introduction to Digital Image Processing 44 Binary Image Processing Introduction Set theory review Morphological filtering operators Erosion and dilation Opening and closing Hit-or-miss Boundary extraction Region-filling Thinning (for finding skeleton) Other processing algorithms Area calculation, finding connected components Skeleton finding via distance transform

EE465: Introduction to Digital Image Processing 45 Thinning thinning Intuitively, thinning finds the skeleton of a binary image (you will learn a different way of finding skeleton by distance transform later)

EE465: Introduction to Digital Image Processing 46 Thinning Algorithm Basic idea:  Use Hit-or-Miss operator as a sifter  Use multiple masks to characterize different patterns x x B2B2 xx B1B1 x x B3B3 x x B4B4 B6B6 xx B5B5 B7B7 B8B8 x x x x x x X 0 =X X k =(…( (X k-1  B 1 )  B 2 …  B 8 ) where X  B=X – X B * Stop the iteration when X k =X k-1 Why eight different B’s? Why hit-or-miss?

EE465: Introduction to Digital Image Processing 47 Image Example

EE465: Introduction to Digital Image Processing 48 Image Example (Con’t) Binary fingerprint image Skeleton image

EE465: Introduction to Digital Image Processing 49 Morphological Filtering: Skeletons* X kB=(((X B) B) … B) ____ k-fold Define S k (A)=(A kB)-(A KB) B __ and Then the skeleton of an image A is given by

EE465: Introduction to Digital Image Processing 50 Textbook Example*

EE465: Introduction to Digital Image Processing 51 Image Example* Binary fingerprint image Skeleton image

EE465: Introduction to Digital Image Processing 52 Summary of Morphological Filtering MATLAB codes circshift(A,z) fliplr(flipud(B)) ~A or 1-A A &~B imdilate(A,B) imerode(A,B) imopen(A,B) imclose(A,B)

EE465: Introduction to Digital Image Processing 53 Summary (Con ’ d) bwhitmiss(A,B) A&~(imerode(A,B)) region_fill.m bwmorph(A,’thin’);

EE465: Introduction to Digital Image Processing 54 What is Common?

EE465: Introduction to Digital Image Processing 55 One-Minute Survey If X={even integers}, Y={multiples of 6}, what is X-Y? How long did you spend on CA#1? What do you think of the pace of this course so far? What is the muddiest point in the last two weeks’ lectures? Do you mind my posting the class grade using the last 4-digit of your ID?

EE465: Introduction to Digital Image Processing 56 Binary Image Processing Introduction Set theory review Morphological filtering operators Erosion and dilation Opening and closing Hit-or-miss Boundary extraction Region-filling Thinning (for finding skeleton) Other processing algorithms Area calculation, finding connected components Skeleton finding via distance transform

EE465: Introduction to Digital Image Processing 57 Building New Pieces How to calculate the perimeter of a binary object A? Find the boundary first (MATLAB: bwperim(A)) How to calculate the area of a binary object A? MATLAB: bwarea or sum(sum(A)) Complication: what if there are multiple binary objects? (this relates to binary image analysis. MATLAB: bwlabel) How to get rid of small holes of a binary object? Recall region filling routine (MATLAB: bwareaopen)

EE465: Introduction to Digital Image Processing 58 Image Examples A label2rgb(bwlabel(A))bwareaopen(A,50)

EE465: Introduction to Digital Image Processing 59 Medial Axis Transform (a.k.a. Skeleton) What is medial axis? Examples Suppose that a fire line propagates with constant speed from the contour of a connected object towards its inside, then all those points lying in positions where at least two wave fronts of the fire line meet during the propagation will constitute a form of a skeleton

EE465: Introduction to Digital Image Processing 60 Distance Transform

EE465: Introduction to Digital Image Processing 61 Skeleton Algorithm Distance transform: find the distance from the nearest boundary for each point Skeleton is the set of points whose distance from the nearest boundary is locally maximum - initialization - iteration

EE465: Introduction to Digital Image Processing x 0 (m,n) x 1 (m,n)x 3 (m,n) skeleton local maximum Example Skeleton Algorithm (Cont’d)

EE465: Introduction to Digital Image Processing 63 Image Example originalskeleton

EE465: Introduction to Digital Image Processing 64 Binary Image Processing Summary