0% found this document useful (0 votes)
54 views22 pages

Unit IV. Digital Image Classification

Digital image classification is a method for converting multi-band image data into thematic classes, resulting in a raster file. The process involves the operator providing training data and selecting classification algorithms, with the classification based on the similarity of pixel values to predefined classes. The accuracy of the classification is validated through comparison with reference data and the calculation of error metrics.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
54 views22 pages

Unit IV. Digital Image Classification

Digital image classification is a method for converting multi-band image data into thematic classes, resulting in a raster file. The process involves the operator providing training data and selecting classification algorithms, with the classification based on the similarity of pixel values to predefined classes. The accuracy of the classification is validated through comparison with reference data and the calculation of error metrics.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 22

Digital image classification

In this chapter, digital image classification is


introduced. In this process the (human) operator
instructs the computer to perform an interpretation
according to certain conditions. These conditions are
defined by the operator. Image classification is one of
the techniques in the domain of digital image
interpretation.
Image classification is based on the different spectral
characteristics of different materials on the Earth’s
surface. This chapter focusses on classification of
multispectral image data.
Principle of image classification

• Image space: A digital image is a 2D-array of elements. In each


element the energy reflected or emitted from the corresponding
area on the Earth’s surface is stored. The spatial arrangement of
the measurements defines the image or image space. Depending
on the sensor, data are recorded in n bands. Digital image elements
are usually stored as 8-bit DN-values (range: 0–255).

Figure 12.1: The structure


of a multi-band image
Feature space
In one pixel, the values in (for example) two bands can be regarded as
components of a two-dimensional vector, the feature vector. An example of a
feature vector is (13, 55), which tells that 13 DN and 55 DN are stored for band
1 and band 2 respectively. This vector can be plotted in a two-dimensional
graph. Similarly, this approach can be visualized
for a three band situation in a three-
dimensional graph.

A graph that shows the values of the


feature vectors is called a feature space or
feature space plot.

Figure 12.2 illustrates how a feature


vector (related to one pixel) is plotted in
the feature space for two and three
bands.
Figure 12.2: Plotting of
the values of a pixel in
the feature space for a two
and three band image.
Distances and clusters in the feature space
Distance in the feature space is expressed as ‘Euclidian
distance’ and the units are DN (as this is the unit of the
axes). In a two-dimensional feature space the distance can
be calculated according to Pythagoras’ theorem. In the
situation of Figure 12.4, the distance between (10, 10) and
(40, 30) equals the square root of (40 − 10)2 + (30 − 10)2.
For three or more dimensions, the distance is calculated in a
similar way.

Figure 12.4: Euclidian


distance between the two
points is calculated using
Pythagoras’ theorem
Image classification
Figure 12.5 shows a feature space in which the feature vectors have been
plotted for six specific land cover classes (grass, water, trees, etc). Each
cluster of feature vectors (class) occupies its own area in the feature space.
Figure 12.5 shows the basic assumption for image classification: a specific
part of the feature space corresponds to a specific class. Once the classes
have been defined in the feature space, each image pixel can be compared
to these classes and assigned to the corresponding class.

Figure 12.5: Feature


space showing the respective
clusters of six
classes; note that each
class occupies a limited
area in the feature space.
Classes to be distinguished in an image classification need to
have different spectral characteristics. The principle of image
classification is that a pixel is assigned to a class based on its
feature vector, by comparing it to predefined clusters in the
feature space.
Doing so for all image pixels results in a classified image. The
crux of image classification is in comparing it to predefined
clusters, which requires definition of the clusters and methods
for comparison.
Definition of the clusters is carried out during the training
process. Comparison of the individual pixels with the clusters
takes place using classifier algorithms.
Image classification process
The process of image classification (Figure 12.6) typically involves five steps:
1. Selection and preparation of the image data. Depending on the cover types to
be classified, the most appropriate sensor, the most appropriate date(s) of
acquisition and the most appropriate wavelength bands should be selected.

Figure 12.6: The classification


process; most
important component is
the training in combination
with selection of the algorithm.

2. Definition of the clusters in the feature space. Here two approaches are
possible: supervised classification and unsupervised classification. In a
supervised classification, the operator defines the clusters during the training
process; in an unsupervised classification a clustering algorithm
automatically finds and defines a number of clusters in the feature space .
3.Selection of classification algorithm. Once the spectral classes
have been defined in the feature space, the operator needs to
decide on how the pixels (based on their DN-values) are assigned
to the classes. The assignment can be based on different criteria
4. Running the actual classification. Once the training data have
been established and the classifier algorithm selected, the actual
classification can be carried out. This means that, based on its DN-
values, each individual pixel in the image is assigned to one of the
defined classes.
5. Validation of the result. Once the classified image has been
produced its quality is assessed by comparing it to reference data
(ground truth). This requires selection of a sampling technique,
generation of an error matrix, and the calculation of error
parameters.
Preparation for image classification
Image classification serves a specific goal: converting image data into thematic
data. In the application context, one is rather interested in thematic
characteristics of an area (pixel) rather than in its reflection values. Thematic
characteristic such as land cover, land use, soil type or mineral type can be used
for further analysis and input to models. In addition, image classification can also
be considered as data reduction: the n multispectral bands result in a single
valued raster file.
With the particular application in mind, the information classes of interest need
to be defined and their spatio-temporal characteristics assessed. Based on these
characteristics the appropriate image data can be selected. Selection of the
adequate data set concerns the type of sensor, the relevant wavelength bands
and the date(s) of acquisition.
Before starting to work with the acquired data, a selection of the available
spectral bands may be made. Reasons for not using all available bands (for
example all seven bands of Landsat TM) lie in the problem of band correlation
and, sometimes, in limitations of hard- and software. Band correlation occurs
when the spectral reflection is similar for two bands.
Supervised image classification
One of the main steps in image classification is the ‘partitioning’ of the feature
space. In supervised classification this is realized by an operator who defines the
spectral characteristics of the classes by identifying sample areas (training
areas).
Supervised classification requires that the operator be familiar with the area of
interest. The operator needs to know where to find the classes of interest in the
area covered by the image. This information can be derived from ‘general area
knowledge’ or from dedicated field observations.
A sample of a specific class, comprising of a number of training pixels, forms a
cluster in the feature space. The clusters, as selected by the operator:
• should form a representative data set for a given class; this means that the
variability of a class within the image should be taken into account.
• should not or limitedly overlap with the other clusters, otherwise, a reliable
separation is not possible. Using a specific data set, some classes may have
significant spectral overlap, which, in principle, means that these classes
cannot be discriminated by image classification. Solutions are to add other
spectral bands, and/or, add image data acquired at other moments.
Unsupervised image classification
Supervised classification requires knowledge of the area at hand. If this
knowledge is not sufficient available or the classes of interest are not yet
defined, an unsupervised classification can be applied. In an unsupervised
classification, clustering algorithms are used to partition the feature space into
a number of clusters.
Several methods of unsupervised classification system exist, their main purpose
being to produce spectral groupings based on certain similarities. In one of the
most common approaches, the user has to define the maximum number of
clusters in a data set. Based on this, the computer locates arbitrary mean
vectors as the centre points of the clusters. Each pixel is then assigned to a
cluster by the minimum distance to cluster centroid decision rule.
Once all the pixels have been labelled, recalculation of the cluster centre takes
place and the process is repeated until the proper cluster centres are found and
the pixels are labelled accordingly.
The iteration stops when the cluster centres do not change any more. At any
iteration, however, clusters with less than a specified number of pixels are
eliminated
Classification algorithms
After the training sample sets have been defined, classification of the
image can be carried out by applying a classification algorithm.
Several classification algorithms exist. The choice of the algorithm
depends on the purpose of the classification and the characteristics of
the image and training data. In the following, three classifier
algorithms are explained. First the box classifier is explained, for its
simplicity to help you understanding the principle. In practice, the box
classifier is hardly ever used. In practice the Minimum Distance to
Mean and the Maximum Likelihood classifiers are used.
Box classifier
The box classifier is the most simple classification method. For this purpose, upper
and lower limits are defined for each class. The limits may be based on the minimum
and maximum values, or on the mean and standard deviation per class. When the
lower and the upper limits are used, they define a box-like area in the feature space,
which is why it is called box classifier. The number of boxes depends on the number
of classes. Box classification is also known as parallelepiped classification since the
opposite sides are parallel (Figure 12.9). During classification, an unknown pixel will
be checked to see if it falls in any of the boxes. It is labelled with the class in which
box it falls. Pixels that do not fall inside any of the boxes will be assigned the
unknown class, sometimes also referred to as the reject class.
The disadvantage of the box classifier is the
overlap between the classes. In such a case, a
pixel is arbitrarily assigned the label of the first
box it encounters.

Figure 12.9: Principle of


the box classification in a
two-dimensional situation.
Minimum Distance to Mean classifier
The basis for the Minimum Distance to
Mean (MDM) classifier is the cluster
centres. During classification the
Euclidean distances from an unknown
pixel to various cluster centres are
calculated. The unknown pixel is assigned
to that class to which the distance is
least. Figure 12.10 illustrates how a
feature space is partitioned based on the
cluster centres. One of the flaws of the
MDM classifier is that also pixels that are
at a large distance from a cluster centre
may be assigned to this centre.
Figure 12.10: Principle
of the minimum distance to mean classification in
a two-dimensional situation. The decision boundaries
are shown for a situation without threshold distance
(upper right) and with threshold distance (lower right).
This problem can be overcome by
defining a threshold value that limits the
search distance. Figure 12.10 illustrates
this effect, the threshold distance to the
centre is shown as a circle.
A further disadvantage of the MDM
classifier is that it does not take the class
variability into account: some clusters are
small and dense while others are large
and dispersed. Maximum likelihood
classification takes class variability into Figure 12.10: Principle
account.
of the minimum distance
to mean classification in
a two-dimensional situation.
The decision boundaries
are shown for a situation without threshold
distance (upper right) and with threshold distance
(lower right).
Maximum Likelihood classifier
The Maximum Likelihood (ML)
classifier considers not only the
cluster centre but also its
shape, size and orientation.
This is achieved by calculating
a statistical distance based on
the mean values and
covariance matrix of the
clusters.
The statistical distance is a
probability value: the
probability that observation x Figure 12.11: Principle
belongs to specific cluster. The of the maximum likelihood classification. The
pixel is assigned to the class decision boundaries are shown for a situation without
(cluster) to which it has the threshold distance (upper right) and with threshold
highest probability.
distance (lower right).
Validation of the result
Image classification results in a raster file in which the individual
raster elements are class labelled. As image classification is based
on samples of the classes, the actual quality should be checked and
quantified afterwards. This is usually done by a sampling approach
in which a number of raster elements are selected and both the
classification result and the true world class are compared.
Both the classification result and the true world class are compared.
Comparison is done by creating an error matrix from which
different accuracy measures can be calculated. The ‘true world
class’ are preferable derived from field observations.
Sometimes, sources of an assumed higher accuracy, such as aerial
photos, are used as a reference.
Google earth can be also used as a good ground truth checker.
Various sampling schemes have been
proposed to select pixels to test.
Once the sampling has been carried
out and the data collected, an error
matrix can be established (Table
12.1). Other terms for this table are
confusion matrix or contingency
matrix. In the table, four classes (A,
B, C, D) are listed.
Table 12.1: The error matrix
A total of 163 samples were with derived errors
collected. From the table you can and accuracy expressed
read that, for example, 53 cases of A as percentages. A, B, C
and D refer to the reference
were found in the real world
classes; a, b, c and d
(‘reference’) while the classification refer to the classes in the
result yields 61 cases of a; in 35 classification result. Overall
cases they agree. accuracy is 53%.
The first and most commonly
cited measure of mapping
accuracy is the overall accuracy,
or Proportion Correctly Classified
(PCC). Overall accuracy is the
number of correctly classified
pixels (i.e., the sum of the
diagonal cells in the error matrix)
Table 12.1: The error matrix
divided by the total number of with derived errors
pixels checked. In Table 12.1 the and accuracy expressed
overall accuracy is as percentages. A, B, C
and D refer to the reference
(35+11+38+2)/163 = 53%. The classes; a, b, c and d
overall accuracy yields one figure refer to the classes in the
for the result as a whole. classification result. Overall
accuracy is 53%.
Most other measures derived from
the error matrix are calculated per
class. Error of omission refers to
those sample points that are
omitted in the interpretation
result. Consider class A, for which
53 samples were taken. 18 out of
the 53 samples were interpreted Table 12.1: The error matrix
as b, c or d. This results in an error with derived errors and accuracy
expressed as percentages. A, B, C
of omission of18/53 = 34%. and D refer to the reference
classes; a, b, c and d refer to the
classes in the classification result.
Overall accuracy is 53%.
The error of commission refers to
incorrectly classified samples.
Consider class d: only 2 of the 21
samples (10%) are correctly
labelled. Errors of commission and
omission are also referred to as type
I and type II errors respectively.
User accuracy is the corollary of
commission error, whilst omission
error is the corollary of producer Table 12.1: The error matrix
accuracy. The user accuracy is the with derived errors and accuracy
probability that a certain reference expressed as percentages. A, B, C
and D refer to the reference
class has also been labelled that classes; a, b, c and d refer to the
class. The producer accuracy is the classes in the classification result.
probability that a sampled point on Overall accuracy is 53%.
the map is that particular class.
Summary
Digital image classification is a technique to derive thematic classes
from image data. Input are multi-band image data; output is a raster
file containing thematic (nominal) classes. In the process of image
classification the role of the operator and additional (field) data is
significant. The operator needs to provide the computer with training
data and select the appropriate classification algorithm. The training
data are defined based on knowledge (derived by field work, or from
secondary sources) of the area being processed. Based on the
similarity between pixel values (feature vector) and the training
classes, a pixel is assigned to one of the classes defined by the training
data. An integral part of image classification is validation of the results.
Again, independent data are required. The result of the validation
process is an error matrix from which different measures of error can
be calculated.

You might also like