1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.

Slides:



Advertisements
Similar presentations
Defining Rotations, Reflections, and Translations
Advertisements

電腦視覺 Computer and Robot Vision I
November 12, 2013Computer Vision Lecture 12: Texture 1Signature Another popular method of representing shape is called the signature. In order to compute.
Honors Geometry Transformations Section 2 Rotations.
Do Now:.
12.6 Rotations and Symmetry Rotation- a transformation in which a figure is turned around a point Center of rotation- the point the figure is rotated around.
Warm Up Draw an example of a reflection: Draw an example of a figure that has one or more lines of symmetry: Find the new coordinates of the image after.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
Digital Image Processing Lecture 12: Image Topology
September 10, 2013Computer Vision Lecture 3: Binary Image Processing 1Thresholding Here, the right image is created from the left image by thresholding,
Image Indexing and Retrieval using Moment Invariants Imran Ahmad School of Computer Science University of Windsor – Canada.
Introduction Now that we have built our understanding of parallel and perpendicular lines, circular arcs, functions, and symmetry, we can define three.
November 4, 2014Computer Vision Lecture 15: Shape Representation II 1Signature Another popular method of representing shape is called the signature. In.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
© 2010 Cengage Learning Engineering. All Rights Reserved.
Chapter 11 Representation and Description. Preview Representing a region involves two choices: In terms of its external characteristics (its boundary)
DIGITAL IMAGE PROCESSING
Introduction --Classification Shape ContourRegion Structural Syntactic Graph Tree Model-driven Data-driven Perimeter Compactness Eccentricity.
2.4: Rotations.
Digital Image Processing
Lecture 06 Binary Image Analysis Lecture 06 Binary Image Analysis Mata kuliah: T Computer Vision Tahun: 2010.
Digital Image Processing Lecture 20: Representation & Description
Recap CSC508.
Geometry Ch 12 Review Jeopardy Definitions Name the transformation Transform it!Potpourri Q $200 Q $400 Q $600 Q $800 Q $1000 Q $200 Q $400 Q $600 Q $800.
Digital Image Processing CSC331
September 23, 2014Computer Vision Lecture 5: Binary Image Processing 1 Binary Images Binary images are grayscale images with only two possible levels of.
Digital Image Processing CCS331 Relationships of Pixel 1.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
Introduction Image geometry studies rotation, translation, scaling, distortion, etc. Image topology studies, e.g., (i) the number of occurrences.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
Warm up What type of transformation is shown? Write the algebraic representation. Write the coordinates of the original triangle after reflection over.
CS654: Digital Image Analysis Lecture 5: Pixels Relationships.
Module 6 Mid-Chapter Test Review. Describe the Transformation from the Given Pre-Image to the Given Image 1. Pre-Image: Shape 1 Image: Shape 4 1. Answer:
Section 7.3 Rigid Motion in a Plane Rotation. Bell Work 1.Using your notes, Reflect the figure in the y-axis. 2. Write all the coordinates for both the.
Rotation Around a Point. A Rotation is… A rotation is a transformation that turns a figure around a fixed point called the center of rotation. A rotation.
Rotation Around a Point. A Rotation is… A rotation is a transformation that turns a figure around a fixed point called the center of rotation. A rotation.
October 16, 2014Computer Vision Lecture 12: Image Segmentation II 1 Hough Transform The Hough transform is a very general technique for feature detection.
1 Arrays of Arrays An array can represent a collection of any type of object - including other arrays! The world is filled with examples Monthly magazine:
1 Overview representing region in 2 ways in terms of its external characteristics (its boundary)  focus on shape characteristics in terms of its internal.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
Digital Image Processing, 3rd ed. © 1992–2008 R. C. Gonzalez & R. E. Woods Gonzalez & Woods Chapter 11 Representation and.
 After an image has been segmented into regions by methods such as those discussed in image segmentation chapter, the segmented pixels usually are represented.
Sheng-Fang Huang Chapter 11 part I.  After the image is segmented into regions, how to represent and describe these regions? ◦ In terms of its external.
: Chapter 13: Finding Basic Shapes 1 Montri Karnjanadecha ac.th/~montri Image Processing.
Image Representation and Description – Representation Schemes
IT472: Digital Image Processing
Digital Image Processing Lecture 20: Representation & Description
Find the coordinates of A(3, 2) reflected in the line y = 1.
Computer Vision Lecture 5: Binary Image Processing
Computer and Robot Vision I
Image Coding and Compression
© 2010 Cengage Learning Engineering. All Rights Reserved.
Representation and Description
Geometry Ch 12 Review Jeopardy
Finding Basic Shapes Hough Transforms
Unit 1 Transformations in the Coordinate Plane
Rotation.
Transformations with Matrices
Section 4.3 Rotations Student Learning Goal: Students will identify what a rotation is and then graph a rotation of 90, 180 or 270 degrees on a coordinate.
Warm-Ups A _____________ is a change in a figure’s position or size
Unit 1 Transformations in the Coordinate Plane
A rotation has to have three elements…
Chapter 7 Transformations.
A rotation has to have three elements…
Rotation Around a Point
Introduction to Artificial Intelligence Lecture 22: Computer Vision II
Presentation transcript:

1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng Chapter 12: Shapes and Boundaries

2 © 2010 Cengage Learning Engineering. All Rights Reserved Introduction How do we tell if two objects have the same shape? How can we classify shape? How can we describe the shape of an object? Formal means of describing shapes are called shape descriptors, which may include size, symmetry, and length of perimeter Ch12-p.355

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. The idea of a chain code is quite straightforward: We walk around the boundary of an object, taking note of the direction we take The resulting list of directions is the chain code Ch12-p.355

4 FIGURE 12.2 © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.356

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Suppose we walk along the boundary in a counter- clockwise direction starting at the leftmost point in the top row and list the directions as we go Ch12-p.356

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. A simple boundary-following algorithm has been given by Sonka et al. [35] The version for 4-connected boundaries: Start by finding the pixel in the object that has the left-most value in the topmost row; call this pixel P 0 Define a variable dir (for direction), and set it equal to 3 Ch12-p.357

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Traverse the 3 × 3 neighborhood of the current pixel in a counterclockwise direction, beginning the search at the pixel in direction This simply sets the current direction to the first direction counterclockwise from dir : Ch12-p.357

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. The first foreground pixel will be the new boundary element. Update dir Stop when the current boundary element P n is equal to the second element P 1 and the previous boundary pixel P n−1 is equal to the first boundary element P 0 im is a binary image Ch12-p.357

9 FIGURE 12.4 © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.358

10 FIGURE 12.5 © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.360

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.360

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.362

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.363

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved Normalization of Chain Codes There are two problems with the definition of the chain code as given in previous sections: The chain code is dependent on the starting pixel The chain code is dependent on the orientation of the object. Ch12-p.363

15 FIGURE 12.7 © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.364

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.363

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.364

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.365

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.365

20 FIGURE 12.8 © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.366

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved Shape Numbers We now consider the problem of defining a chain code that is independent of the orientation of the object Ch12-p.366

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.366

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Suppose we rotate the shape so that it has a different orientation (we use the rot90 function, which rotates a matrix by 90°) Ch12-p.367

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.367

25 FIGURE 12.9 © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.368

26 FIGURE © 2010 Cengage Learning Engineering. All Rights Reserved. (normalized) Ch12-p.369

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.369

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. This is already normalized Ch12-p.369

Chain Codes and Shape Numbers © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.370

Fourier Descriptors © 2010 Cengage Learning Engineering. All Rights Reserved. The idea is this: suppose we walk around an object, but instead of writing down the directions, we write down the boundary coordinates The final list of (x, y) coordinates can be turned into a list of complex numbers z = x + yi The Fourier transform of this list of numbers is a Fourier descriptor of the object Ch12-p.371

Fourier Descriptors © 2010 Cengage Learning Engineering. All Rights Reserved. We can easily modify our function chaincode4.m to boundary4.m by replacing the lines Ch12-p.371

Fourier Descriptors © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.371

Fourier Descriptors © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.372

34 FIGURE © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.372

Fourier Descriptors © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.373

36 FIGURE © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.373

Fourier Descriptors © 2010 Cengage Learning Engineering. All Rights Reserved. The Fourier transform of c contains only three nonzero terms Only two terms of the transform are enough to begin to get some idea of the shape, size, and symmetry of the object Even though the shape itself has been greatly hanged—a square has become a circle—many shape descriptors are still little changed (such as size and symmetry) Ch12-p.373

38 FIGURE © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.374

39 FIGURE © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.374

40 FIGURE © 2010 Cengage Learning Engineering. All Rights Reserved. Ch12-p.375