Experimental Images Analysis with Linear Change Positive

advertisement
Recent Advances in Image, Audio and Signal Processing
Experimental Images Analysis with Linear Change Positive and
Negative Degree of Brightness
1
RATKO IVKOVIC, 2BRANIMIR JAKSIC, 3PETAR SPALEVIC, 4LJUBOMIR LAZIC, 5MILE
PETROVIC,
1,2,3,5
Department of Electronic and Computer Engineering
Faculty of Technical Sciences, University of Prishtina
Kneza Milosa 7, 38220 Kosovska Mitrovica
SERBIA
4
State University of Novi Pazar
Vuka Karadzica, 36300 Novi Pazar
SERBIA
1
2
ratko.ivkovic@ymail.com, branimir.jaksic@pr.ac.rs, 3 petar.spalevic@pr.ac.rs, 4 llazic@np.ac.rs,
5
mile.petrovic@pr.ac.rs
Abstract: - In this paper we presented an analysis of the image that is applied to the linear rate of increasing and
decreasing of brightness on image. The analysis of the results are presented in tabular and graphical form. The
analysis used the parameters of the Mean Square Error (MSE), Peak Signal to Noise Ratio (PSNR), Structural
Similarity Index (SSIM), Different Structural Similarity Index (DSSIM). It was found that the different degrees
of linear brightness changes the parameters PSNR and MSE have approximately the same value, and the
mathematical changes to the image can only be analyzed through SSIM and DSSIM parameters. Analysis of
the impact of positive and negative brightness analyzed through histograms for the RGB channels.
Key-Words: - Mean Square Error (MSE), Peak Signal to Noise Ratio (PSNR), Structural similarity index
(SSIM), Different Structural similarity index (DSSIM), brightness, brightness parameter (BP)
image processing are obliged to find a way to
describe Brightness quantitatively. However,
currently, there is no conventional numerical
description for this stimulus characteristic [2]. This
paper proposes a review and analysis of the most
popular values used for Brightness representation
and discusses the effectiveness of those values in
image editing algorithms heavily dependent on the
choice of Brightness measure [3].
1 Introduction
Brightness is one of the most significant pixel
characteristics, and like this represent attribute of
visual perception in which a source seems to be
radiating or reflecting a specific amount of light. It
is involved in many image-editing algorithms such
as contrast or shadow/highlight. Currently, there is
no conventional formula for brightness calculation,
and the same image-processing tool may employ
several different brightness measures. However,
stimuli, equi-bright according to one measure, may
differ more, than ten times according to another [1].
Usually, term Brightness should be used only for
nonquantitative
references
to
physiological
sensations and perceptions of light. Wyszecki and
Stiles define Brightness as an attribute of a visual
sensation according to which a given visual stimulus
appears to be more or less intense; or, according to
which the area in which the visual stimulus is
presented appears to emit more or less light, and
range variation in Brightness from “bright” to
“dim”. Given definition is useless for digital image
processing, because provides no foundation for
image editing. Developers of algorithms for digital
ISBN: 978-960-474-350-6
2 Parameters
Analysis
for
Image
Quality
2.1 Mean Square Error (MSE) and Peak
Signal to Noise Ratio (PSNR)
A method for the estimation of image quality is
needed in order to give a view about how “lossy”
compression methods modify image quality. We
may treat an image as a matrix whose elements are
image pixels. The estimation process is then based
on the calculation of distances between appropriate
elements of input and output matrices. In this way,
not only comparison of quality of different
116
Recent Advances in Image, Audio and Signal Processing
compression methods is enabled, but also
comparison of the results of the same method using
different compression ratios [4].
We denote the matrix A at the input of the
compression system with elements aij, with
i{1...M}, j{1...N}, where M is the number of
image elements in the vertical and N is the number
of image elements in horizontal direction]. MxN is
the total number of image elements.
The output of the compression system is the
matrix A' with elements a'ij. The distance between
the elements of matrices A and A' represents the
error or the loss of image quality. Usually, the error
is larger for higher compression ratios. A user can
set the compression ratio according to the desired
image quality, and hence directly influence the data
size of the compression image.
Structural similarity index (SSIM) represents
perceptual image quality based on the structural
information. SSIM is an objective image quality
metric and is superior to traditional quantitative
measures such as MSE and PSNR [5]:

i 0 j 0
DSSIM  x, y  
E
1

MN MN
(1)
(6)
For the analysis of the objective image quality were
used 8-bit uncompressed images saved in bmp
format, with a original resolution of 512x512 pixels
available
on
the
website
http://sipi.usc.edu/database/misc.zip.
The analyzed images are bright with varying
degrees of positive and negative brightness by using
Matlab software package. Positive brightness
corresponding with increasing brightness in image,
and a negative corresponding with decreasing
brightness in image. The brightness of the image is
controlled through the Brightness parameter (BP),
so that to increase the brightness BP ranges from 1
to 255 (positive brightness), and to decrease the
brightness of -1 to -255 (negative brightness), and 0
corresponds to the value the original image.
A change in the brightness and a change in the
value of BP is directly related to the changing value
of the pixels in the image.
Fig. 1 shows one of the analyzed image with
varying degrees of positive brightness, and in Fig. 2
analyzes the images with various degrees of
negative brightness.
By using the Matlab software it has taken the
ability to present the picture with matrix expression
[m n].It is allowed that the pixel values may change
depending on some functions. This attribute of the
MATLAB software provides a great opportunity to
directly manipulate pixel values to a specific
function.
(2)
where MxN is the total number of image pixels, and
the sum is applied to all image elements.
The amplitudes of image elements are in the
range [0, 2n-1], where n is the number of bits needed
for binary representation of amplitude of each
element in the original image. MSE does not
consider amplitudes of image elements (it only
considers differences between amplitudes) and it is
the reason for introducing the Peak Signal to Noise
Ratio (PSNR).
 MAX I2 
 MAX I 
PSNR  10·log10 
  20·log10 
 (3)
 MSE 
 MSE 
The variable MAXI is the maximum amplitude
value of image element (pixel). When the amplitude
of the image pixel is represented by B bits, MAXI is
2B-1.
With n=8 bits/image element we can define:
 2552 
PSNR  10·log10 
(4)

 MSE 
Typical values for PSNR for “lossy” compressed
images are between 30 and 50 dB.
2.2 Structural similarity index (SSIM),
Different
Structural
similarity
index
(DSSIM)
ISBN: 978-960-474-350-6
2
3 System Model
m 1 n 1
| | aij  aij' ||2

i 0 j 0
1  SSIM  x, y 
DSSIM is a distance metric derived from SSIM
(though the triangle inequality is not necessarily
satisfied) [7].
The distance between matrices A and A' is
frequently calculated using the Mean Square Error
(MSE) [4]:
MSE 

where α>0, β>0 and γ >0 are parameters used to
adjust the relative importance of the three
components. Symbols x,y are image patches and
l(x,y) is luminance comparison, c(x,y) is contrast
comparison, and s(x,y) is structural comparison [6].
When DSSIM calculate:
m 1 n 1
E   | | aij  aij' ||2

SSIM  x, y   l  x, y   c  x, y   s  x, y  (5)
117
Recent Advances in Image, Audio and Signal Processing
a)
b)
c)
Fig. 1: Image with a positive brightness: a) BP=25 b) BP=100 c) BP=175
a)
b)
c)
Fig. 2: Image with negative brightness: a) BP=-25 b) BP=-100 c) BP=-175
Changing the level of brightness is not just for
one or a group of pixels, but for the total number of
pixels in the image. With applied linear functions
and increasing of the BP leads to increasing the
pixel values.
This increasing leads to a shift of the entire
histograms to the right, respectively, to the right
border of the spectrum (white). According to that it
doesn’t come to changing the number of pixels and
the form of histograms to RGB channels [8]. In case
of reduction of brightness, i.e. using a negative
brightness, the pixel values are reduced and there is
a shift to the left side of the histogram, as shown in
Fig. 3.
Based on the definition MSE, equation (2), the
values of parameter m and n represent the value of
pixel, expressed in basis RGB parameters. In this
case there exist two identical linear functions
(positive and negative brightness), and the values of
the pixels will be changed by the same law.
According to the definition of MSE where the
absolute value exists, the results will be the same
values for positive and negative picture brightness.
a)
b)
c)
Fig. 3: Histogram of the RGB channels of a) original image, b) image with a positive light BP = 25, c) image
with a negative light BP = -25
ISBN: 978-960-474-350-6
118
Recent Advances in Image, Audio and Signal Processing
Based on the differential between the original
and brightness images computed mean squared error
(MSE), Structural Similarity Model (SSIM),
Different Structural Similarity Model, Peak Signalto-Noise Ratio (PSNR)..
with different degrees of brightness of the analyzed
image. On the x-axis is given absolute value of the
parameter lighting (BP). Positive values (1 to 255)
refer to picture brightness, and negative values on
the darkening of the image.
50
4 Results
Results of the analysis for different values of
positive and negative brightness images are given in
Table 1 and Table 2.
PSNR [dB]
40
Table 1: Values of PSNR, MSE, SSIM and DSSIM
for positive brightness
PSNR
MSE
SSIM
DSSIM
1
48.1314
0.999856
0.999926
13465.8
25
20.2558
613.053
0.96851
31.7565
50
14.5083
2302.78
0.900657
10.0661
75
11.3211
4797.03
0.816795
5.45835
100 9.14973
7908.74
0.732968
3.74488
125 7.55128
11427.5
0.646493
2.8288
150 6.42872
14798.2
0.548368
2.21419
175 5.737
17353.2
0.451085
1.82178
200 5.40936
18713
0.399966
1.66657
225 5.2603
19366.4
0.381172
1.61596
255 5.2188
19552.4
0.373995
1.59743
PSNR
MSE
SSIM
0
48.1308
1.0
0.999922
12877
-25
20.232
616.42
0.934987
15.3816
-50
14.3536
2386.3
0.781113
4.56858
-75
11.0369
5121.43
0.56508
2.29928
-100
8.96371
8254.86
0.373966
1.59736
-125
7.61039
12273
0.237286
1.31111
-150
6.67849
13971.1
0.145085
1.16971
-175
5.97513
16427.4
0.0760221
1.08228
-200
5.46991
18453.9
0.0280764
1.02889
-225
5.19333
19667.4
0.0043512
1.00437
-255
5.1371
19923.7
0.0004494
1.00045
100
150
200
250
300
Fig. 4: PSNR for different degree of positive and
negative brightness
20000
15000
10000
Negative Brightness
Positive Brightnes
5000
0
0
50
100
150
200
250
300
| BP |
Fig. 5: MSE for different degree of positive and
negative brightness
In graphs there can be seen that in lower absolute
values |BP|, PSNR there is a higher value, while
with the increase of BP, PSNR there is very fast
decrease. Value of PSNR is almost the same for
positive, as well as for negative contrast of the
image.
Similar to PSNR, MSE is identical for the same
amount of positive and negative contrast of the
image, white MSE is growing with the increase of
positive brightness, i.e. negative brightness in the
image.
Based on the change of parameter PSNR and
MSE for different degree of positive and negative
brightness in the Fig. 3 and Fig. 4, respectfully,
In Fig. 4, Fig. 5 and Fig. 6 shows a graph of
changes in PSNR, MSE, SSIM and, respectively,
ISBN: 978-960-474-350-6
50
| BP |
DSSIM
-1
20
0
Table 2: Values of PSNR, MSE, SSIM and DSSIM
for negative brightness
BP
30
10
MSE
BP
Negative Brightness
Positive Brightnes
119
Recent Advances in Image, Audio and Signal Processing
there is no possibility to see the difference in
brightness and darkness of the image.
References:
[1] S. Bezryadin, P. Bourov, D. Ilinih, Brightness
Calculation in Digital Image Processing,
Symposium on Technologies for Digital Photo
Fulfillment, pp. 10-15(6), 2007.
[2] S. Bezryadin, P. Bourov, Color Coordinate
System for Accurate Color Image Editing
Software, The International Conference
Printing Technology SPb’06 proceedings, p.
145–148, St. Peterburg State University of
Technology and Design, 2006.
[3] B. Jaksic, R. Ivkovic, M. Petrovic, Analisys
brightness effect on quality pictures after
compression with JPEG and SPIHT
compression
method,
Matematicke
i
informaticke tehnologije, September 2013.
[4] Z. Wang, Alan C. Bovik, Mean Squared Error:
Love It or Leave It?, Signal Processing
Magazine, IEEE, Vol. 26, No. 1, January
2009, pp. 98 – 117.
[5] Z. Wang, A. C. Bovik, H, R. Sheikh, Structural
Similarity Based Image Quality Assessment,
Chapter 7 in Digital Video Image Quality and
Perceptual Coding (H. R. Wu, and K. R. Rao,
eds.), Marcel Dekker Series in Signal
Processing and Communications, November
2005.
[6] T. O. Aydın, R. Mantiuk, H. P. Seidel,
Extending Quality Metrics to Full Luminance
Range Images, Human Vision and Electronic
Imaging XIII, January 2008.
[7] A. Loza, L. Mihaylova, N. Canagarajah, David
Bull, Structural Similarity-Based Object
Tracking in Video Sequences, 2006.
[8] Z. Wang, A. C. Bovik, IEEE transactions on
image processing, VOL. 13, NO. 4, April 2004.
[9] B. Jaksic, R. Ivkovic, M. Petrovic, Analysis of
different influence of compression algorithm on
the image filtered Laplcian, Prewitt and Sobel
operator, International Journal of Darshan
Institute on Engineering Research and
Emerging Technology, Vol. 2, No. 1, 2013
1.0
Negative Brightness
Positive Brightnes
0.8
SSIM
0.6
0.4
0.2
0.0
0
50
100
150
200
250
300
| BP |
Fig. 6: SSIM for different degree of positive and
negative brightness
Therefore there is new parameter SSIM and
DSSIM. In the Fig. 5 there is decrease of SSIM with
increase of positive and negative brightness, but for
the difference in PSNR and MSE that are identical
with the increase of |BP|. In this case decreasing of
SSIM is much more visible with negative than in
positive brightness [9].
4 Conclusion
Apart from the visual appearance, based on
PSNR and MSE could not be mathematically
determined difference between the original
image and the image with increasing/decreasing
brightness. SSIM is a parameter that
mathematically confirms the difference when it
is impossible to determine with other
parameters. Based on the above, the SSIM can
be established in conditional different values of
BP for the same image and the same values of
MSE and PSNR, SSIM parameter values
demonstrate the diversity of images. These
results show that the SSIM and decreases in
positive and in a negative brightness, such as
the decrease in negative brightness is
significantly expressed, as a consequence of the
properties of SSIM compares pictures by
illumination and reflection.
ISBN: 978-960-474-350-6
Acknowledgment
This work was done within the research project
of the Ministry of Science and Technological
Development of Serbia TR35026, entitled as:
“Software Development Environment for optimal
software quality design“..
120
Download