数字图像处理第九章

合集下载
  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

© Mingyan Jiang, SDU, Copyrights Reserved
8/70
Digital Image Processing Using MATLAB ®
®
© Mingyan Jiang, SDU, Copyrights Reserved
9/70
Digital Image Processing Using MATLAB ®



0,1 , 1,1 , 2,1 , 2,2 , 3,0 , 0,2 , 1,2 , 2,2 , 2,3 , 3,1
A B的意义A用B扩张, 即所有A的点集使Ba 击中A且交集非零。
© Mingyan Jiang, SDU, Copyrights Reserved 11/70
© Mingyan Jiang, SDU, Copyrights Reserved
6/70
Digital Image Processing Using MATLAB ®
®
The set operations defined in Fig. 9.1 can be performed on binary images using MATLAB's logical operators OR (|), AND (&), and NOT (~), as Table 9.1 shows.
®
Dilation is commutative; that is,
A B B A.
It is a convention in image processing to let the first operand of A B be the image and the second operand be the structuring element, which usually is much smaller than the image.
Digital Image Processing Using MATLAB ®
®
Chapter 9
Morphological Image Processing
江铭炎
教授/博导
网址: 信息学院=> 精品课程=> 数字图像处理
© Mingyan Jiang, SDU, Copyrights Reserved 1/70
© Mingyan Jiang, SDU, Copyrights Reserved 4/70
Digital Image Processing Using MATLAB ®
®
© Mingyan Jiang, SDU, Copyrights Reserved
5/70
Digital Image Processing Using MATLAB ®
®
9.2 Dilation and Erosion
The operations of dilation and erosion are fundamental to morphological image processing. Dilation is an operation that "grows" or "thickens" objects in a binary image. The specific manner and extent of this thickening is controlled by a shape referred to as a structuring element.
© Mingyan Jiang, SDU, Copyrights Reserved 16/70
Digital Image Processing Using MATLAB ®
®
IPT function strel constructs structuring elements with a variety of shapes and sizes. Its basic syntax is: se = strel(shape, parameters), where shape is a string specifying the desired shape, and parameters is a list of parameters that specify information about the shape. In addition to simplifying the generation of common structuring element shapes, function strel also has the important property of producing structuring elements in decomposed form.
© Mingyan Jiang, SDU, Copyrights Reserved 3/70
Digital Image Processing Using MATLAB ®
®
9.1 Preliminaries(set theory)
1、 w A 2、 w A 3、 B = {w | condition} 4、 A c {w | w A} complement of A 5、 C A B union of two sets 6、 C A B intersection of two sets 7、 A - B {w | w A, w B} difference of two sets ˆ {w | w - b, for b B} 8、 B reflection of set B 9、 (A)z {c | c a z, for a A} translation of set A
© Mingyan Jiang, SDU, Copyrights Reserved
12/70
Digital Image Processing Using MATLAB ®
®
© Mingyan Jiang, SDU, Copyrights Reserved
13/70
Digital Image Processing Using MATLAB ®
则A B
Digital Image Processing Using MATLAB ®
®
Figure 9.4 illustrates how dilation works.
Figure 9.4(a) shows a simple binary image containing a
rectangular object. Figure 9.4(b) is a structuring element, a five-pixel-long diagonal line in this case. Figure 9.4(b) shows the origin of the structuring element using a black outline. Figure 9.4(c) graphically depicts dilation as a process that translates the origin of the structuring element throughout the domain of the image and checks to see where it overlaps with 1-valued pixels. Fig. 9.4(d) is 1 at each location of the origin such that the structuring element overlaps at least one 1-valued pixel in the input image.
© Mingyan Jiang, SDU, Copyrights Reserved 10/70
Digital Image Processing Using MATLAB ®
®
dilation
定义A用B结构单元扩张记作A B,定义为 A B c E N , c a b, a A, b B或 A B Ba , a A 例:A 0,1 , 1,1 , 2,1 , 2,2 , 3,0 B 0,0 , 0,1
© Mingyan Jiang, SDU, Copyrights Reserved
7/70
Digital Image Processing Using MATLAB ®
®
As a simple illustration, Fig. 9.3 shows the results of applying several logical operators to two binary images containing text.
A B A (B1 B2 ) (A Bl ) B2 .
The associative property is important because the time required to compute dilation is proportional to the number of nonzero pixels in the structuring element. The gain in speed with the decomposed implementation is still significant.
Digital Image Processing Using MATLAB ®
®
The word morphology commonly denotes a branch of biology that deals with the form and structure of animals and plants Mathematical morphology : as a tool for extracting image components that are useful in the representation and description of region shape, such as boundaries, skeletons, and the convex hull.
®
Morphological theory views a binary image as the set of its foreground (1valued) pixels, the elements of which are in Z2. (Z is the set of integers) Set operations such as union and intersection can be applied directly to binary image sets.

© Mingyan Jiang, SDU, Copyrights Reserved
15/70
wk.baidu.com
Digital Image Processing Using MATLAB ®
®
Dilation is associative. That is, A (B C) (A B) C, B B1 B2 Suppose:
We follow this convention from this point
on.
© Mingyan Jiang, SDU, Copyrights Reserved
14/70
Digital Image Processing Using MATLAB ®
®
IPT function imdilate performs dilation. Its basic calling syntax is A2 = imdilate(A, B) A = imread('broken_text.tif'); B = [0 1 0; 1 1 1; 0 1 0]; A2 = imdilate(A, B); imshow(A2)
© Mingyan Jiang, SDU, Copyrights Reserved 2/70
Digital Image Processing Using MATLAB ®
®
Morphological techniques for pre- or postprocessing, such as morphological filtering, thinning, and pruning. Morphology is a cornerstone of the mathematical set of tools underlying the development of techniques that extract "meaning" from an image.
相关文档
最新文档