This document presents a method for automatically separating linear features from backgrounds in digital topographic maps. It is difficult to separate lines and backgrounds when their colors are similar using traditional color-based methods. The proposed method uses shear transform, energy density concepts, and template matching. Lines are separated from backgrounds based on the rule that energy density is higher for lines distributed in small areas compared to backgrounds distributed in large areas. The method was tested on a 342x198 topographic map with similar line and background colors and was able to extract the linear features.
2. Introduction
Digitalization of topographic maps is an important data
source of constructing GIS
Maps consist of linear features(roads and condor
lines) and backgrounds(green fields and water bodies)
Linear features are fundamental to GIS ;so its
separation is important
Manual separation is time consuming
Automated separation is based on the colours
2
3. Contd..
When linear feature colour and background colour
are similar then it is difficult to separate them
This paper present a method based on energy density
and shear transform
Shear transform preserves lines directional info
during one directional separation method
Horizontal and vertical templates are used to
separate lines from background
3
4. Contd..
Remaining grid background can be removed by grid
template matching
Isolated patches of one pixel and less than ten pixels are
also removed
Union operation on these sheared images give the final
result
4
5. Existing systems
In 1994 N.Ebi developed a system by converting RGB
colour to another colour space
In 1994 H.Yan proposed a system based on fuzzy theory
;which combines fuzzy clustering and neural n/w’s
In 1996 C.Feng developed a system based on colour
clustering
In 2003 L.Zheng developed a system of fuzzy clustering
based on 2D histogram
5
6. Contd..
In 2008 Aria Pezeshek introduced a semi automated
method; in this method contour lines are removed by an
algorithm based intensity quantization followed by
contrast limited adaptive histogram equalization.
In 2010 S.Leyk introduced a segmentation method which
uses information from local image plane, frequency
domain and colour space
All methods described above work where the colour
difference b/w line and background is seperable
6
7. Characteristic Analysis of Linear
Features and Background
Colour based separation is difficult in some case
7
8. Figures show histogram of image in lab colour space
The are number of peaks in the histogram of first image
But in second image; colour of pixels are close to each
other ; so there is only one peak in the histogram.
It is very hard to separate the line from background of
second image.
8
9. 1
This figure shows a binary image with complicated
background
Some portion of the image is ideal and other is
complicated
9
10. Ideal portion of background can be removed by using the
Grid templates shown
If the centre pixel and adjacent 8 pixels satisfy the fig 4(a)
and 4(a1) then the pixel is treated as background and
replaced by 1/white
If the centre pixel and adjacent 8 pixels satisfy the fig 4(b)
and 4(b1) then the pixel is treated as line info and
replaced by 0/black
In the fig 3(c) it is a portion of image with complicated
background; it cannot be operated with our grid template
matching
10
11. Energy characteristics
Energy of an image is given by
i=1,2,3...M
j=1,2,3...N
M and N are the height and width of image
f(i,j) is the gray value of pixel
Energy of one pixel f(i,j)
i-k<m<i+k
j-k<n<j+k
size of window w=2k+1
11
12. Line in gray s/m is dark; but HVS is more sensitive to
brightness so we take negative of gray image
The figure shows that, the energy of negative image is
concentrated on lines
Here the distribution of line and background in ideal case
is shown here
12
13. The figure shows the distribution of line and background
in the case of actual image
Here fig c. Represents the background and fig d.
Represents the line
13
14. The histogram of line in fig b. is shown in fig d.
It has only few pixels but all of its energy concentrated on
the lines
Energy ranging from 2.5*104 -3* 104 ;extreme case it is
6* 104
Energy of background is also in the same range; but
energy conc. is higher for lines
14
15. Horizontal and vertical templates are used to separate
lines from background
h2 corresponds to line, it is selected adaptively by
experience; generally 2*2
h1 and h3 corresponds to background pixels generally of
size 4*2 and 2*4
15
16. Energy density of the template is
Edk =
2
/m*n
m*n-area of template
k=1,2,3
Edk =energy density of each area of template
16
17. Proposed method
Traditional colour based system fails when the colour of
background and the colour of the lines are similar
This method is based on energy density
Energy density of a negative image is defined as the
average energy in an area
2
Ed =
/M*N
M*N-size of area
Ed =energy density
17
18. Rules for line separation
Rule 1:
energy of line is distributed in small area so
energy density is high
energy of background is distributed in large area
so energy density is low
Ed2>Ed1
Ed2>Ed3
ie: energy density of line >energy density of background
18
19. Rule 2:
if line and background cannot be separated by rule 1
, it is necessary to control the energy difference of line
and background to a certain range
Ed’=Ed1+Ed2+Ed3/3
T=Ed2-Ed’+α
α is acquired by experience; α =3000-5000
Ed2-Ed1>T
Ed2-Ed3>T
h2 is treated as line if and only if Ed2 satisfies rule 1 and
rule 2
19
20. Background pixel h1 and h3 and isolated patches of one
pixel or less than ten pixels are removed
Finally union operation is performed on the two images
20
21. Shear transform
Shear transform is a linear transform that displaces point
in a fixed direction
Introduced to avoid the separation difficulties while
operating lines with many direction
Ws,k is the shear operation
s=0,1 k€[-2ndir ,2ndir]
f’s,k(x,y)=f(x,y)*Ws,k
Total number of sheared image is given by
2ndir+1+1
21
22. Shear transform is performed by sampling pixel according
to the shear matrix
S=0 operation is performed in horizontal direction
S=1 operation is performed in vertical direction
(x’,y’)=(x,y)S1=(x,y)
22
23. This is the result of shear transform of s=0, ndir=2
so a total of 9 images; union of these images gives a
perfect map
23
24. Steps of proposed method
STEP 1:
colour image is converted into gray image
Gray=0.233R+0.587G+0.114B
negative of the gray image is taken
I=e*255-gray
‘e’ is a matrix with same size of gray matrix with
all elements equal to one
STEP 2:
Apply shear transform to the negative image
24
25. Contd..
STEP 3:
Establishment of template: horizontal and
vertical
STEP 4:
Linear feature separation from background:
i.e. : energy of each area in template is calculated,
line is separated from background by rule 1 and
rule 2 with α =4000
25
26. Contd...
STEP 5:
Removal of miscellaneous point:
i.e. : remaining grid background can be removed
by grid template matching and isolated points can
also be removed
STEP 6:
Inverse shear transform and union operation
26
28. Experiments and Discussions
This is a 342*198 size 7 colour topographical map image
Colour of linear feature and background are similar here
so it is very difficult to separate lines from background
28
29. Here size of h2 is 2*2
h1&h3 is 4*2 if vertical template is used
h1&h3 is 2*4 if horizontal template is used
α=4000
Fig(b) is the gray image
Fig(c) is the negative image
29
30. The first set of figures shows the sheared images with
k=-1, k=0, k=1
Second set shows energy density based extraction by
templates
30
31. Fig (a) shows the union operation of a2, b2, c2,
Fig (b) shows lines with colour info extracted from colour
image
Fig (c) shows the remaining background
31
33. Conclusion
This paper proposes a method to linear separation from
background
Here shear transform is used to overcome the limitation
of directions for lines
Energy density concept is introduced to separate lines
from background
The new method can easily be applied to maps for
efficient separation of lines
Adaptive size fixing of template is a draw back of this
method
33
34. Reference
R. Samet and E. Hancer, “A new approach to the
reconstruction of contour lines extracted from topographic
maps,” J. Visual Commun.
E. Hancer and R. Samet, “Advanced contour reconnection
in scanned topographic maps,”
H. Chen, X.-A. Tang, C.-H. Wang, and Z. Gan, “Object
oriented segmentation of scanned topographical maps,”
S. Leyk, “Segmentation of colour layers in historical maps
based on hierarchical colour sampling,” in Graphics
Recognition. Achievements, Challenges, and Evolution
(Lecture Notes in Computer Science),
34