Вы находитесь на странице: 1из 10

1

REGION BASED COMPRESSION OF MULTI-SPECTRAL SATELLITE


IMAGE USING DISCRETE WAVELET TRANSFOM

Abstract
Image compression is necessary now days to transmit the image data with reduced
bandwidth and storage capacity. Region based compression is a special type of compression
technique in which the required portion is not altered and the remaining portion of the image is
compressed using discrete wavelet transform. The image is segmented by using Kmeans
clustering algorithm (unsupervised classification) and then Area of Interest (AOI) is subtracted
from the original image. The background image (remaining portion) is compressed using various
wavelet functions and its performance is also analysed. Then the compressed image is added
with the AOI and its performance is analysed. This image is encoded using any one of the
lossless coding technique.

1.Introduction

1.1 Original image


The original multi-spectral satellite image is a Landsat image. It consists of spectral bands band1
to band7.

The seven spectral bands and its frequency spectrum are given below.

Band1 - blue region – 0.45 - 0.52µm


Band2 – green region – 0.53 - 0.60µm
Band3 – red region – 0.63 - 0.69µm
Band4 – near IR region – 0.76 – 0.90µm
Band5 – mid IR region – 1.1 to 3.0µm
Band6 – thermal IR region – 10.4 – 12.8µm
Band7 – far IR region – 2.45 – 2.58µm

Figure 1. Original Landsat image

1.2 AOI selection


The original image consists of agriculture, forest, urban and water images. AOI is done
3

by converting the seven spectral bands into three primary color bands. The primary color bands
are Red, Blue and Green. The advantage of these primary colors is, objects can be easily
partitioned in these regions. Red signifies the NIR band, Green signifies the visible red band, and
Blue signifies the visible green band.In the CIR image, water features are very dark (the Seine
River)and green vegetation appears red (urban areas).

1.3 Image segmentation

Segmentation refers to the process of partitioning a digital image into


multiple segments (sets of pixels, also known as super pixels). The goal of segmentation is to
simplify and/or change the representation of an image into something that is more meaningful
and easier to analyze. Image segmentation is typically used to locate objects and boundaries
(lines, curves, etc.) in images. More precisely, image segmentation is the process of assigning a
label to every pixel in an image such that pixels with the same label share certain visual
characteristics.
The result of image segmentation is a set of segments that collectively cover the entire image, or
a set of contours extracted from the image. Each of the pixels in a region is similar with respect
to some characteristic or computed property, such as color, intensity, or texture. Adjacent regions
are significantly different with respect to the same characteristic(s).

2. K-means Algorithm

The K-means algorithm is an iterative technique that is used to partition an image into K clusters.
The basic algorithm is:

1. Pick K cluster centers, either randomly or based on some heuristic

2. Assign each pixel in the image to the cluster that minimizes the distance between the
pixel and the cluster center

3. Re-compute the cluster centers by averaging all of the pixels in the cluster

4. Repeat steps 2 and 3 until convergence is attained (e.g. no pixels change clusters)

In this case, distance is the squared or absolute difference between a pixel and a cluster center.
The difference is typically based on pixel color, intensity, texture, and location, or a weighted
combination of these factors. K can be selected manually, randomly, or by a heuristic.
This algorithm is guaranteed to converge, but it may not return the optimal solution. The quality
of the solution depends on the initial set of clusters and the value of K.

In statistics and machine learning, the k-means algorithm is a clustering algorithm to partition n
objects into k clusters, where k < n. It is similar to the expectation-maximization algorithm for
mixtures of Gaussians in that they both attempt to find the centers of natural clusters in the data.
The model requires that the object attributes correspond to elements of a vector space. The
objective it tries to achieve is to minimize total intra-cluster variance, or, the squared error
function.

The most common form of the algorithm uses an iterative refinement heuristic known
as Lloyd's algorithm. Lloyd's algorithm starts by partitioning the input points into k initial sets,
either at random or using some heuristic data. It then calculates the mean point, or centroid, of
each set. It constructs a new partition by associating each point with the closest centroid. Then
the centroids are recalculated for the new clusters, and algorithm repeated by alternate
application of these two steps until convergence, which is obtained when the points no longer
switch clusters (or alternatively centroids are no longer changed).

Lloyd's algorithm and k-means are often used synonymously, but in reality Lloyd's
algorithm is a heuristic for solving the k-means problem, as with certain combinations of starting
points and centroids, Lloyd's algorithm can in fact converge to the wrong answer. Other
variations exist, but Lloyd's algorithm has remained popular, because it converges extremely
quickly in practice. In terms of performance the algorithm is not guaranteed to return a global
optimum. The quality of the final solution depends largely on the initial set of clusters, and may,
in practice, be much poorer than the global optimum. Since the algorithm is extremely fast, a
common method is to run the algorithm several times and return the best clustering found. A
drawback of the k-means algorithm is that the number of clusters k is an input parameter. An
inappropriate choice of k may yield poor results. The algorithm also assumes that the variance is
an appropriate measure of cluster scatter.

2.1 K-Means Algorithm Properties


• There are always K clusters.
• There is always at least one item in each cluster.
• The clusters are non-hierarchical and they do not overlap.
• Every member of a cluster is closer to its cluster than any other cluster because
closeness does not always involve the 'center' of clusters.

2.2 Advantages of K-means clustering


5

• Simple to use: Extensive hand-labeling of images by experts to generate training data is not
necessary

• Probabilistic framework allows to approximate the actual edge probabilities for optimal
segmentation

Our goal is to segment colors in an automated fashion using the L*a*b* color space and K-
means clustering.
Thematic Mapper 4, 3, and 2 bands cover the near infrared (NIR), the visible red, and the visible
green parts of the electromagnetic spectrum. When they are mapped to the red, green, and blue
planes, respectively, of an RGB image the result is a standard color-infrared (CIR) composite.
The final input argument to multiband read specifies which bands to read, and in which order, so
that you can construct a composite in a single step.

Variable CIR is a 512-by-512-by-3 array of class uint8. It is an RGB image, but with false
colors. When the image is displayed, red signifies the NIR band, green signifies the visible red
band, and blue signifies the visible green band. In the CIR image, water features are very dark.

3. Image Segmentation Procedure


Step 1: Read Image.

The LAN file, paris.lan, contains a 7-band 512-by-512 Landsat image. A 128-byte header is
followed by the pixel values, which are band interleaved by line (BIL) in order of increasing
band number. They are stored as unsigned 8-bit integers, in little-endian byte order. The first step
is to read bands 4, 3, and 2 from the LAN file using the MATLAB function multiband read.
Seine River) and green vegetation appears red (parks and shade trees).
Step 2: Convert Image from RGB Color Space to L*a*b* Color Space.
There are three colors: green, blue, and red. Notice how easily you can visually distinguish
these colors from one another. The L*a*b* color space (also known as CIELAB or CIE L*a*b*)
enables you to quantify these visual differences.
The L*a*b* color space is derived from the CIE XYZ tri stimulus values. The L*a*b* space
consists of a luminosity layer 'L*', chromaticity-layer 'a*' indicating where color falls along the
red-green axis, and chromaticity-layer 'b*' indicating where the color falls along the blue-green
axis. All of the color information is in the 'a*' and 'b*' layers. You can measure the difference
between two colors using the Euclidean distance metric.

Convert the image to L*a*b* color space using makecform and applycform.
MAKECFORM Create a color transformation structure.
makecform(TYPE) creates the color transformation structure, C
that defines the color space conversion specified by TYPE. To
perform the transformation, pass the color transformation structure

as an argument to the APPLYCFORM function

Step 3: Classify the Colors in 'a*b*' Space Using K-Means


Clustering.
Clustering is a way to separate groups of objects. K-means clustering
treats each object as having a location in space. It finds partitions such
that objects within each cluster are as close to each other as possible, and
as far from objects in other clusters as possible. K-means clustering
7

requires that you specify the number of clusters to be partitioned and a


distance metric to quantify how close two objects are to each other.
Since the color information exists in the 'a*b*' space, your objects are
pixels with 'a*' and 'b*' values. Use kmeans to cluster the objects into
three clusters using the Euclidean distance metric.
KMEANS clustering.
IDX = KMEANS(X, K) partitions the points in the N-by-P data
matrix X into K clusters. This partition minimizes the sum, over all
clusters, of the within-cluster sums of point-to-cluster-centroid.
Distances refers rows of X correspond to points, columns correspond
to variables. KMEANS returns an N-by-1 vector IDX containing the
cluster indices of each point. By default, KMEANS uses squared
Euclidean distances.
Sqeuclidean refers Squared Euclidean distance (the default)
A replicate means number of times to repeat the clustering, each with a
new set of initial centroids. A positive integer, default is 1.
Step 4: Label Every Pixel in the Image Using the Results from
KMEANS.
For every object in your input, kmeans returns an index
corresponding to a cluster. The cluster_center output from kmeans will
be used later in the demo. Label every pixel in the image with its
cluster_index. Then we go for reshaping the image.
Reshape means changes the pixel size of an image.
9

Step 5: Create Images that Segment the Image by Color.


Using pixel_labels, you can separate objects in paris.lan by color,
which will result in three images. In this segmentation, we have three
different segmented images to separate the primary colours. So in this
process we are using the function REPMAT. It is used for replicate and
tile an array.
For example:
REPMAT(A,M,N) when A is a scalar is commonly used to produce an
M-by-Nmatrix filled with A's value and having A's CLASS. For certain
values.
IMAGE SUBTRACTION
An image subtraction algorithm is used in this project to recognize a
moving object. The major reason for using this algorithm is that it is
simple and can be implemented by the limited real-time processing
capabilities of the image processing board. It turned out to work
acceptably well. This method is used for recognizing the pinball and
flippers. It simply compares the previous frame image with the current
one. The result of the subtraction is visible from the monitor, which
shows the same data as is ``seen'' by the computer, i.e. if something is
moving, then a white pixel shows up on the screen in that position.
In the image subtraction process,

Вам также может понравиться