CONTRAST ENHANCEMENT FOR MIMIMUM MEAN BRIGHTNESS ERROR FROM HISTOGRAM PARTITIONING N. Phanthuna 1,2, F. Cheevasuvt 2 and S. Chtwong 2 1 Department of Electrcal Engneerng, Faculty of Engneerng Rajamangala Unversty of Technology Phra Nakhon Bangkok, 10800 THAILAND 2 Department of Instrumentaton Engneerng, Faculty of Engneerng Kng Mongkut s Insttute of Technology Ladkrabang Bangkok, 10520 THAILAND nattapong100@gmal.com, kcfusak@kmtl.ac.th, kcsakrey@kmtl.ac.th ABSTRACT Ths paper presents the mage enhancng usng a mean separated hstogram equalzaton method. To provde the mum mean brghtness error after the hstogram modfcaton. It separates the nput mage s hstogram nto n (n=1,2,3, ) groups based on nput mean before equalzng them ndependently. The mage ntally s separated class by calculated threshold level and each class s hstogram equalzed to entre mage, and gets lowest AMBE (AMBE : Absolute Mean Brghtness Error). The result found that AMBE gradually reduces when the separaton s ncreased. Therefore, the error threshold s assgned n order to automatcally dvdng the orgnal hstogram for obtanng the desred AMBE. Ths process wll be appled to remote sensng data by treatng each regon of hstogram ndependently. Also Tenengrad s employed n order to verfy the contrast performance. The mage performance s consdered hgher f ts Tenengrad value s larger. INTRODUCTION Image enhancement s one method to ncrease contrast of mage. Dgtal mage processng s wdely used to much feld such as remote sensng, etc. One of algorthm appled s analyzng and nterpretng data of satellte mage. The accuracy of that job s dependent on qualty of such data n term of contrast. The better contrast, the more effcency for nterpretng data s. Raw data must then be enhanced to get better qualty by hstogram equalzaton. Ths method s smple and effcent when comparng wth other method. Hstogram equalzaton tres to dstrbute more concentrated gray level, sgnfcantly. One popular method of hstogram equalzaton s global hstogram equalzaton based on basc rule of probablty dstrbuton of orgnal gray level. Dsadvantage of one s some brghtness saturaton and shftng mean. Ths s losng nformaton. To solve that problem, havng many reports (Russ, J. C. 1994, Conzalez, R. C. and WnTZ, P. 1987, Sd-Ahmed, M. A. 1995, Wongsrtong, K., Kttayaruasrwat, K., Cheevasuvt, F., Dejhan, K., and Somboonkaeaw, A.,1998, Km, Y-T. 1997, and Chen, S.-D, Raml, A. R. 2003) has been proposed equalzaton technque by classng hstogram equalzaton nto sub-hstogram callng local hstogram equalzaton. Such method s stll not better enough because each regon parttoned s not approprate. The man key to apply hstogram equalzaton effcent s to class each regon of hstogram to gve mean of enhanced mage the same as orgnal mage by re-adjustng peak pont to class. Ths paper s organzed as follows. Mult-peak hstogram searchng s frstly descrbed to get a number of peak ponts. To obtan the enhanced mage preserved mean brghtness, many gray level of peak pont s shfted by the proposed hstogram partton method descrbed. Expermental results are descrbed and shown as numercal result as qualty measurng crteron together wth global hstogram equalzaton method and vsual mage. The concluson s gven n last secton.
MULTIPEAK HISTOGRAM SEARCHING We wll brefly descrbes mult-peak hstogram searchng (Wongsrtong, K., Kttayaruasrwat, K., Cheevasuvt, F., Dejhan, K., and Somboonkaeaw, A.,1998). The hstogram of an mage wll be conssted as many peaks. Each peak of hstogram can not easly be detected snce the probablty of brghtness levels are qut fluctuated and also some brghtness levels are dsappeared. The lnear nterpolaton s then employed to fll up the dsappeared brghtness levels, whle the neghborhood averagng process s appled to smooth the hstogram. Nne consecutve probabltes of brghtness levels are averaged for the new probablty of the central brghtness level. Ths new probablty value of the k th central brghtness level, defned as p ( r ) can be obtaned by the followng equaton. n k 9 1 9 pr 1 k 5+ k L = ( ) ;5 4 Pn( rk) = pr ( k ) ; k< 5, k> L 4 The new probablty p ( r ) s used only n the peak pont detecton process. In order to obtan the peak pont of n k each peak, the sgns of the dfference between two successve probabltes n the smoothed hstogram are calculated. However, the fluctuaton of sgn wll be appeared. So the sgn changng process s used when three consecutve sgns s swng such as the followng examples, +-+ change to +++ and -+- change to ---. After the sgn changng process s appled then the peak pont detecton process s utlzed. Each peak pont s smoothed, hstogram s detected when four successve negatve sgns are followed by eght successve postve sgns s occurred. That mean, the peak pont s detected only the downward path of probabltes, the hstogram s composed of N+1 regon, N peak ponts must be detected. HISTOGRAM PARTITION Lnear Contrast Expanson Snce gray level of pxel s concentrated n some narrow nterval of hstogram, such mage s then low contrast. Lnear contrast expanson n each group of hstogram s employed to solve brghtness saturaton problem. Based on peak value calculated s used to class groups of hstogram. Contrast of each of the grouped one s expanded lnearly by whch mum and mum pont of gray level s number of the prevous calculated peak. The entre mage s expanded full range as 0-255 levels. Let X and X are range of orgnal hstogram expanded nto Y and Y.shown n Fgure 1. Range of gray level n mage X s X X X. To solve problem n calculaton, f X s less than X, X s then X and f X s more than X, X s then X. New gray level can be obtaned from equaton below. ( X X ) Y = ( Y Y ) + Y ( X X ) X X Y Fgure 1. Lnear contrast expanson (a) Orgnal hstogram (b) New hstogram. Y
Qualty Measurng Crteron The proposed method s tryng to preserve brghtness mean more and more possble by consderng value of absolute mean brghtness error (AMBE). AMBE s calculated from equaton below. AMBE = E[ Y ] E[ X ] where EY [ ] and [ ] EX are mean of new and orgnal gray level of mage, respectvely. Generally, classng number of hstogram regon affects to AMBE value. The more one s, the less AMBE. Also, suddenly hangng of slope of gray level n mage ndcates that contrast s ether ncrease or decrease. Gradent s slope between pxels used to detect mage edge to verfy mage qualty. The Tenendrad crteron (TEN) s based on gradent magntude mzaton. The value of TEN s calculated from gradent of all pxels n mage. The partal dervatves are obtaned by a hgh pass flter usng Sobel operator wth the convoluton kernels x and y. The gradent s gven as S( x, y) = ( I( x, y)) + ( I( x, y)) x 2 2 y where stands for convoluton, I( xy, ) s enhanced mage. The Tenendgrad crteron s formulated as 2 TEN S( x, y) = x y The Proposed Hstogram Partton To preserve brghtness mean of fnally enhanced mage, parttonng of smoothed hstogram correspondng to qualty crteron s mportant. We wll present the method to parttons hstogram to get the lowest AMBE by shftng peak pont based on local ma both lower and upper. The shftng process s descrbed as followng. Step 1 Usng peak ponts whch has got from the smoothed mult-peak hstogram searchng, let P 1, P 2, P 3,,P N are gray levels of each peak. Hstogram s classed nto N group N=P N. Step 2 Calculatng orgnal mean, E[ X ] L 1 L 1 = f g / f = 0 = 0 where L s the mum gray level such as 255, f s frequency of th gray level, g s th gray levl. For nstance, the number of peak pont s of 3 (N=3), P 1, P 2, and P 3. Hstogram s grouped nto 4 regons [0 - P 1 ], [P 1 +1 P 2 ], [P 2 +1 P 3 ] and [P 3 +1 L]. Step 3 Calculatng mean from the enhanced mage, EY [ ] L 1 L 1 f g / f = = 0 = 0 where f s frequency of th gray level va enhancement. Step 4 Hstogram mentoned n step 1 s expanded by usng lnear contrast expanson method together wth gettng new peak P 1, P 2, P 3,,P N but the number of hstogram groups s the same as step 1. Step 5 The gray level of peak pont P 1, P 2, P 3,,P N s shfted nto both lower and upper wth ε shftng range value and AMBE of both orgnal and enhanced mage by usng hstogram equalzaton based on such peak pont to group sub-hstogram s calculated. If AMBE s stll hgher, the gray level of peak pont s then adjusted by ncreasng ε value untl the lowest AMBE s obtaned. For nstance, let N=2 and P 1 =91, P 2 =153. For ε =10, P 1 =91, that s, such hstogram s composed of 3 regons [0-91], [92 153] and [154 255]. We wll search to get new peak pont around P 1 followng. Lower sde values are of 90,.89, 88, 87, 86, 85, 84, 83, 82, 81 and upper sde 92, 93, 94, 95, 96, 97, 98, 99, 100, 101 by whch upper sde value must not be more then P 2 =153. Frstly, to search lower sde, range of hstogram, [0-90] for lower, [91-153] for upper and [154 255], s allocated and equalzed frstly, together wth calculatng AMBE value for such range. The other ranges consst of [0-89] and [90-153], [0-88] and [89-153], [0-87] and [88-153], [0-86] and [87-153], [0-85] and [86-153], [0-84] and [85-153], [0-83] and [84-153], [0-82] and [83-153], [0-81] and [82-153] whch are consecutvely allocated and equalzed the same fashon as mentoned. A number of AMBE values are of 10. Secondly, to search upper sde, range of hstogram, [0-92] for lower, [93-153] for upper and [154 255], s allocated and equalzed frstly, together wth calculatng AMBE value for such range. The other ranges consst of [0-93] and [94-153], [0-94] and [95-
153], [0-95] and [96-153], [0-96] and [97-153], [0-97] and [98-153], [0-98] and [99-153], [0-99] and [100-153], [0-100] and [101-153], [0-101] and [102-153] whch are consecutvely allocated and equalzed the same fashon as mentoned. A number of AMBE values are of 10. Total of AMBE values s of 20, one of them s the lowest AMBE value correspondng wth one of any gray level of peak pont s obtaned and assgned as new peak pont. For other peak pont, the same style s performed. If such the obtaned AMBE value s stll hgher, the shftng range value s then ncreased. AMBE value s calculated agan, so on, untl gettng the lowest AMBE. EXPERIMENTAL RESULTS The proposed method s appled to satellte mage (LS001) shown n Fgure 2(a). By usng mult-peak hstogram, results of the number of peak ponts s of 2 peak ponts (P1=91 and P2=153) and local hstogram equalzaton appled wth 2 regons has gven AMBE and TEN, numercally shown n Table 1 and vsual mage and ts hstogram shown n Fgure 2(c), seeng that there are better than global hstogram equalzaton surely shown n Fgure 2(b). To get the enhanced mage correspondng wth both AMBE and TEN qualty measurng crteron, shftng range s fnely adjusted from 10 to 40 for ths experment untl AMBE s the lowest value and TEN s the hghest value. Fgure 2(d)-(g) are shown vsual mage for shftng range from 10 to 40, respectvely. As shown n Table 1, fnally, the new peak ponts are P1=73 and P2=189, approprate. Table 1. HE Method AMBE TEN Image 46.0343 1.11 10 4 Proposed Method Shftng Range Peak 1 Peak 2 AMBE TEN (ε ) (P1) (P2) 1 91 153 8.48836 7.76 10 4 10 81 163 8.30481 9.45 10 4 LS001 20 73 173 6.03268 12.17 10 4 30 73 183 3.95550 15.00 10 4 40 73 189 0.02863 18.96 10 4 CONCLUSIONS Ths paper presents a method for preservng mean brghtness of orgnal of enhanced mage va hstogram equalzaton. The nput mage wll be parttoned nto a number of regons by detected peak pont. Each regon ndependently wll be expanded for full dynamc hstogram range, then ndependently appled the classcal local hstogram equalzaton to each regon. In order to mze the AMBE, the roughly detected peak pont wll be fnely adjusted by shftng them n a certan defned range. The results of AMBE obtaned from the proposed method gve the lowest AMBE. Also the method presents the hghest tenengrad of each enhanced mage n order to show the qualty of enhancement. REFERENCES Russ, J. C., 1994. The Image Processng Handbook, 2 nd Edton, IEEE Press. Conzalez, R.C. and P. WnTZ, 1987. Dgtal Image Processng, 2 nd Edton, Addson-Wesley Pub., Massachusetts. Sd-Ahmed, M.A., 1995. Image Processng: Theory, Algorthm & Archtectures, McGraw-Hll, New York. Wongsrtong, K., K. Kttayaruasrwat, F. Cheevasuvt, K. Dejhan, and A. Somboonkaeaw, 1998. Contrast enhancement usng multpeak hstogram equalzaton wth brghtness preservng, IEEE Asa-Pacfc Conf. Crcut and System, 455-458. Km, Y-T., 1997. Contrast enhance usng brghtness preservng b-hstogram rqualzaton, IEEE Trans. Consumer Electroncs, 43(1):1-8.
Chen, S.-D, A.R. Raml, 2003. Mnmum mean brghtness error b-hstogram equalzaton n contrast enhancement, IEEE Trans. Consumer Electroncs, 49(4):1310-1318. (a) (b) AMBE=46.0343, TEN=1.11x10 4 Peak=2, P1=91,P2=153 ε =1 AMBE=8.48836, TEN=7.76x10 4 (c) Peak=2, P1=81,P2=163 ε =10 AMBE=8.30481, TEN=9.45x10 4 (d)
Peak=2, P1=73,P2=173 ε =20 AMBE=6.03268, TEN=12.17x10 4 (e) Peak=2, P1=73,P2=183 ε =30 AMBE=3.95550, TEN=15.00x104 (f) Peak=2, P1=73,P2=189 ε =40 AMBE=0.02863, TEN=18.96x10 4 (g) Fgure 2. (a) Orgnal mage and ts hstogram, Results of enhanced mage and ts hstogram by usng (b) Global hstogram equalzaton (c) Local hstogram equalzaton (d) (g) Local hstogram equalzaton wth adjustng shftng range from 10-40.