Chapter 3 Binary Machine Vision:

Region Analysis

Region Analysis

3.1 Introduction

region properties: measurement vector, input to classifier

3.2 Thresholding

regions: produced by connected components labeling operator

region intensity histogram: gray level values for all pixels

mean gray level value: summary statistics of region's intensity

bounding rectangle: smallest rectangle circumscribes the region

area:

1#1

centroid:

2#2

3#3

border pixel: has some neighboring pixel outside the region

4#4: 4-connected perimeter: if 8-connectivity for inside and outside

5#5: 8-connected perimeter: if 4-connectivity for inside and outside

6#6

7#7

e.g. center is in 4#4 but not in 5#5 for

8#8

e.g. 9#9

e.g. 10#10

length of perimeter
11#11, successive pixels,
neighbors

12#12

13#13

where 14#14 is computed modulo 15#15 i.e. 16#16

e.g. 17#17, 18#18

mean distance 19#19 from the centroid to the shape boundary

20#20

e.g. 21#21, 22#22

standard deviation 23#23 of distances from centroid to boundary

24#24

e.g. 25#25, 26#26

Haralick shows that 27#27 has properties:

- digital shape 28#28 circular, 27#27 increases monotonically
- 27#27 similar for similar digital/continuous shapes
- orientation (rotation) and area (scale) independent

Average gray level (intensity)

29#29

Gray level (intensity) variance

30#30

right hand equation lets us compute variance with only one pass

microtexture properties: function of co-occurrence matrix

31#31: set of pixels in designated spatial relationship e.g. 4-neighbors

co-occurrence matrix 32#32

33#33

texture second moment (Haralick, Shanmugam, and Dinstein, 1973)

34#34

texture entropy

35#35

texture correlation

36#36

where

37#37

38#38

texture contrast

39#39

texture homogeneity

40#40

where 41#41 is some small constant

=====New 3:10=====

3.2.1 Extremal Points

eight distinct extremal pixels: topmost right, rightmost top, rightmost
bottom,

bottommost right, bottommost left, leftmost bottom, leftmost
top,

topmost left

=====Fig. 3.1=====

different extremal points may be coincident

=====Fig. 3.2=====

association of the name of the eight extremal points with their coordinates

=====Table 3.1=====

42#42

43#43

44#44

45#45

46#46

47#47

48#48

49#49

50#50

51#51

52#52

53#53

association of the name of an external coordinate with its definition

=====Table 3.2=====

extremal points occur in opposite pairs: topmost left 54#54 bottommost right,

topmost right 54#54 bottommost left, rightmost top 54#54 leftmost bottom,

rightmost bottom 54#54 leftmost top

each opposite extremal point pair: defines an axis

axis properties: length, orientation

the length covered by two pixels horizontally adjacent

- 1: distance between pixel centers
- 2: from left edge of left pixel to right edge of right pixel

55#55: axis between 56#56 and 57#57

58#58: axis between 59#59 and 60#60

61#61: axis between 62#62 and 63#63

64#64: axis between 65#65 and 66#66

67#67

68#68

69#69

70#70

orientation taken counterclockwise w.r.t. column (horizontal) axis

=====Fig. 3.3=====

71#71

72#72

73#73

74#74

orientation convention for the axes

=====Fig. 3.4=====

75#75

length going from left edge of left pixel to right edge of right pixel

=====Fig. 3.5=====

axes paired: 55#55 with 61#61 and 58#58 with 64#64

calculation of the axis length and orientation of a linelike shape

=====Fig. 3.6=====

distance between 76#76th and 77#77th extremal point

78#78

average value of 79#79, largest error 80#80

calculations for length of sides, base, and altitude for a triangle

=====Fig. 3.7=====

geometry of the tilted rectangle

=====Fig. 3.8=====

calculation for the orientation of an example rectangle

=====Fig. 3.9=====

axes and their mates that arise from octagonal-shaped regions

=====Fig. 3.10=====

3.2.2 Spatial Moments

second-order row moment

81#81

second-order mixed moment

82#82

second-order column moment

83#83

3.2.3 Mixed Spatial Gray Level Moments

region properties: position, extent, shape, gray level properties

second-order mixed gray level spatial moments

84#84

85#85

=====Example 3.1=====

connected components labeling of the image in Fig. 2.2

=====Fig. 3.11=====

all the properties measured from each of the regions

=====Table 3.3=====

=====joke=====

3.3 Signature Properties

vertical projection

86#86

horizontal projection

87#87

diagonal projection from lower left to upper right

88#88

diagonal projection from upper left to lower right

89#89

projections: easily obtainable in pipeline hardware

compute properties from projections

area

90#90

rmin: top row of bounding rectangle

91#91

rmax: bottom row of bounding rectangle

92#92

cmin: leftmost column of bounding rectangle

93#93

cmax: rightmost column of bounding rectangle

94#94

row centroid

95#95

96#96

column centroid

97#97

98#98

diagonal centroid

99#99

another diagonal centroid

100#100

diagonal centroid related to row and column centroid

101#101

102#102

second row moment from horizontal projection

103#103

second column moment from vertical projection

104#104

second diagonal moment

105#105

second diagonal moment related to 106#106

107#107

second mixed moment can be obtained from projection

108#108

second diagonal moment related to 106#106

109#109

second mixed moment can be obtained from projection

110#110

mixed moment 111#111 obtained directly from 112#112 and 113#113

114#114

3.3.1 Using Signature Analysis to Determine the Center and Orientation of a
Rectangle

signature analysis: important because of easy, fast implementation

surface mount device (SMD) placement: position and orientation of parts

determine center
115#115 of rectangle
by corner location 116#116,

side lengths 117#117, orientation angle 118#118

119#119

120#120

121#121

geometry for determining the translation of the center of a rectangle

=====Fig. 3.12=====

partition rectangle into six regions formed by two vertical lines

a known distance 122#122 apart and one horizontal line

=====Fig. 3.14=====

123#123

124#124

where rotation angle

125#125

3.3.2 Using Signature Analysis to Determine the Center of a Circle

partition the circle into four quadrants formed by two orthogonal lines

which meet inside the circle

geometry for the circle, its center, and a chord

=====Fig. 3.15=====

126#126

127#127

128#128

129#129

130#130

circle projected onto the four quadrants of the projection index image

=====Fig. 3.16=====

each quadrant area from histogram of the masked projection

131#131

132#132 positive if 133#133, negative otherwise, where

134#134

135#135 positive if 136#136, negative otherwise

137#137

138#138

3.4 Summary

region properties from connected components or signature analysis

R. C. Gonzalez and R. E. Woods, *Digital Image Processing*,
Addison Wesley, Reading, MA, 1992

Chapter 4 Image Enhancement

4.2 Enhancement by Point Processing

4.2.2 Histogram Processing

Histogram Equalization p. 173-180
Chapter 4 Image Enhancement

4.2 Enhancement by Point Processing

4.2.2 Histogram Processing

pixel transformation

139#139

140#140: original, new intensity, 141#141: transformation

- 142#142 single-valued, monotonically increasing
- 143#143 for 144#144

histogram equalization, histogram linearization

145#145

146#146, 147#147: number of pixels with intensity 77#77

148#148: total number of pixels

for every pixel if 149#149 then 150#150

=====Fig. 4.13=====

=====Garfield 17:3=====

Project due Oct. 26:

Write a program to do histogram equalization

2001-09-19 Counter:

FastCounter by bCentral