Multipeak Mean Based Optimized Histogram Modification Framework Using Swarm Intelligence for Image Contrast Enhancement

A novel approach, Multipeak mean based optimized histogrammodification framework (MMOHM) is introduced for the purpose of enhancing the contrast as well as preserving essential details for any given gray scale and colour images. The basic idea of this technique is the calculation of multiple peaks (local maxima) from the original histogram. The mean value of multiple peaks is computed and the input image’s histogram is segmented into two subhistograms based on this multipeak mean (mmean) value. Then, a bicriteria optimization problem is formulated and the subhistograms are modified by selecting optimal contrast enhancement parameters. While formulating the enhancement parameters, particle swarm optimization is employed to find optimal values of them. Finally, the union of the modified subhistograms produces a contrast enhanced and details preserved output image. This mechanism enhances the contrast of the input image better than the existing contemporary HE methods. The performance of the proposed method is well supported by the contrast enhancement quantitative metrics such as discrete entropy, natural image quality evaluator, and absolute mean brightness error.


Introduction
Contrast enhancement plays an important role in the improvement of visual quality for computer vision, pattern recognition, and the processing of digital images. Poor contrast in digital video or images can result from many circumstances, including lack of operator expertise and inadequacy of the image capture device [1]. Contrast enhancement of an image is achieved through redistribution of intensity values. The resultant contrast enhanced image provides feature extraction in computer vision system. Histogram equalization (HE) is one of the commonly used algorithms for contrast enhancement due to its simplicity and effectiveness. It remaps the gray levels based on the probability distribution of the input gray levels. It flattens and stretches the dynamic range of the images histogram which results in overall contrast improvement [2].
HE methods can be categorized into two methods: improved global HE methods (GHE) and adaptive HE (AHE) methods. The GHE methods improve image quality by extending the dynamic range of intensity using the histogram of the whole image. Since GHE is based on the intensity distribution of the whole image, it causes washed out effect and changes average intensity to middle level [3]. In AHE methods, the equalization is based on the histogram and statistics obtained from neighbourhood around each pixel. These methods can usually provide stronger enhancement effects than global methods. They divide the original image into several nonoverlapped subblocks and perform HE on individual subblocks. The resultant image is produced by merging the subblocks using bilinear interpolation method. However, due to their high computational load, AHE methods are not well suited for real time video applications [4].
The objective of an image enhancement technique is to bring out hidden image details or to increase the contrast of an image with the low dynamic range. Such a technique produces an output image that subjectively looks better than the 2 Mathematical Problems in Engineering original image by increasing the gray-level differences among objects and background. Numerous enhancement techniques have been introduced and can be divided into three groups: (1) techniques that decompose an image into high and low frequency signals for manipulation, (2) transform based techniques, and (3) histogram modification techniques. Among the three groups, the third group received the most attention due to their straightforward and intuitive implementation qualities [5]. Some research works have focused on improving HE based contrast enhancement such as brightness preserving bihistogram equalization (BBHE), equal area dualistic subimage histogram equalization (DSIHE), recursive mean separate histogram equalization (RMSHE), weighted thresholded histogram equalization (WTHE), range limited bihistogram equalization (RLBHE), efficient contrast enhancement using adaptive gamma correction with weighting distribution (AGCWD), and contrast enhancement based on layered difference representation of 2D histograms (LDR). Efficient histogram modification using bilateral Bezier curve for the contrast enhancement (BBC) has been proposed in the past years. The aforementioned techniques may create problems when the histogram has spikes or when a natural looking enhanced image is required. The detailed literature of these techniques was given in next section. This paper uses the particle swarm optimization (PSO) and multipeak mean ( ) value for the segmentation of histogram and hence trying to improve the contrast enhancement with the help of optimal threshold value as the enhancement parameters. The technique, multipeak mean based optimized histogram modification framework using particle swarm optimization (MMOHM) is proposed for the purpose of enhancing the contrast as well as preserving essential details for any given input image. Multiple peaks (local maxima) are identified from the input histogram. Then, the mean value of multipeaks is computed and the input image's histogram is segmented into two subhistograms based on this multipeak mean value. Then, a bicriteria optimization problem is formulated to satisfy aforementioned requirements and the subhistograms are modified by selecting the optimal contrast enhancement parameters. Finally, the union of the modified subhistograms produces a contrast enhanced and details preserved output image. While formulating the optimization problem, PSO is employed to find the optimal values of contrast enhancement parameters.
The traditional HE and several HE based methods are analyzed in Section 2. Section 3 presents the proposed MMOHM method along with the statistical measurements to measure the image quality. The results are discussed in Section 4. The conclusion is given in Section 5.

Review of Histogram Equalization Methods
Consider the input image = { ( , )}, where ( , ) denotes the gray-level of a pixel at ( , ). The total number of pixels in the image is and the image intensity is digitized into gray levels that are [ 0 , 1 , . . . , −1 ]. If represents the number of times that the level appears in the input image , then the probability density function (PDF) ( ) for the level is defined as Based on (1), the cumulative density function (CDF) is defined as HE maps the input image into the entire dynamic range, ( 0 , −1 ), by using the CDF as a transform function. The transform function ( ) based on the CDF is defined as HE technique is rarely used because it flattens the histogram of an image which results in bringing significant change in brightness and causes undesirable artifacts. Kim has proposed a method known as brightness preserving bihistogram equalization (BBHE) to preserve the brightness [6]. BBHE decomposes the input histogram into two subhistograms based on its input mean . It is clearly proved that BBHE can preserve the original brightness to a certain extent. Wang et al. proposed a method called equal area dualistic subimage histogram equalization (DSIHE) which is an extension of BBHE [7]. DSIHE differs from BBHE only in the segmentation process. The input image is segmented into two subimages based on median rather than mean. This method is well suited for some images but fails to preserve original brightness for most of the images. Chen and Ramli proposed a method called minimum mean brightness error bihistogram equalization (MMBEBHE) which is an extension of BBHE [8]. It performs the separation process based on the threshold level and it preserves the original brightness of the image. Chen and Ramli proposed a method called recursive mean separate histogram equalization (RMSHE) in which histogram of the given image is partitioned recursively [9]. Unlike BBHE which decomposes the input histogram only once, RMSHE decomposes it recursively up to a recursion level and thereby generating 2 subhistograms. The resultant subhistograms are then equalized individually to get the contrast enhanced image. Sim et al. proposed a similar method called recursive subimage histogram equalization (RSIHE) [10]. It shares similar recursive framework with RMSHE except that for histogram segmentation, RSIHE uses the median of subhistograms instead of the mean of subhistograms in RMSHE. But, the fact is that as the recursion level increases, the computational complexity also increases and finding an optimal recursion level is a difficult task for all such methods. A detailed study of various bilevel and multilevel partitioning methods are analyzed in [11]. A fast and effective method for video and image contrast enhancement known as weighted thresholded histogram equalization (WTHE) was presented in [4]. WTHE provides a good tradeoff between the two features, adaptively to different images and ease of control, which is difficult to achieve through GHE based enhancement methods. In recursively separated and Mathematical Problems in Engineering 3 weighted HE (RSWHE) and weight clustering HE (WCHE), different weighing principles are applied successfully [12,13]. But these methods fail to preserve the spatial relationship among the pixels and their surroundings. Ibrahim and Pik Kong proposed subregions histogram equalization (SRHE) for sharpening the images [14]. Zuo et al. developed the range limited bihistogram equalization (RLBHE) for image contrast enhancement in which the input image's histogram is divided into two independent subhistograms through a threshold that minimizes the intraclass variance [15]. Then the range of the equalized image is calculated to yield minimum absolute mean brightness error between the original and equalized image. Sundaram et al. proposed a method called histogram modified local contrast enhancement for mammogram images in which the contrast enhancement of the mammogram image can be achieved by histogram modification and local contrast enhancement [16]. BBHE is combined with local enhancement to preserve the brightness and improve performance of detail preservation. It combines spatial edge information with gray information to enhance the local details [17]. In thresholded and optimized histogram equalisation (TOHE), histogram modification was carried out based on otsu's optimality principle. Then, weighing constraints are applied; mean errors are calculated and the error values were added to the original probability density values for contrast enhancement [18]. Lee and Kim proposed a novel contrast enhancement technique based on layered difference representation (LDR) of 2D histograms [19]. They attempt to enhance the contrast by amplifying the graylevel differences between the adjacent pixels. A constrained optimization problem is formulated based on the observation that the gray-level differences, occurring more frequently in the input image, should be more emphasized in the output image. The optimization problem is solved to derive the transformation function at each layer and then combine the transformation functions at all layers to map input gray levels to output gray levels. Huang et al. proposed an automatic histogram transformation technique called efficient contrast enhancement using adaptive gamma correction with weighting distribution (AGCWD) that improves the brightness of dimmed images via gamma correction and probability distribution of luminance pixels [1]. To enhance the video, AGCWD uses temporal information regarding the differences between the discrete entropy values of each frame to reduce the computational complexity. Efficient histogram modification using bilateral Bezier curve for the contrast enhancement (BBC) is proposed to enhance the quality of the input image and reduce the processing time [20]. The control points of the mapping curve are automatically calculated by Bezier curve which performs in dark and bright regions separately. Using the fast and accurate histogram modification allows this method to transform the intensity for both image and video. Ghita et al. introduced a new variational approach for HE which involves the application of the total variation minimization with a L 1 fidelity (TV-L 1 ) model to achieve cartoon-texture decomposition [21]. The texture information is also employed along with the intensity information to emphasize the contribution of local textural features in the contrast enhancement process. This is achieved by implementing a nonlinear histogram warping strategy that will maximize the information content in the transformed image. Celik and Tjahjadi proposed an algorithm for contrast enhancement which is free from parameter setting [5]. In this method, the pixel values of an input image are modeled using Gaussian mixture model. The intersection points of the Gaussian components are used in partitioning the dynamic range of the image into input gray-level intervals. The gray levels in each input interval are transformed according to the dominant Gaussian component and the CDF of the interval to obtain the contrast equalized image.

Multipeak Mean Based Optimized Histogram Modification (MMOHM)
HE is the simple and straightforward method for image contrast enhancement. Several HE based techniques were proposed in the past years and a detailed discussion on it is given in the literature. Most of the contemporary HE based techniques have the common drawback of mean shift, which results in brightness degradation, lack of details preservation, and overenhancement. In addition, computational complexity and controllable contrast enhancement become an important issue when the goal is to design a contrast enhancement algorithm for gray scale and color images.
The main objective of this paper is to obtain a visually pleasing brightness preserved enhancement method, which incorporates a provision to have a control over the level of contrast enhancement and works well for all types of images. The proposed MMOHM method is an effective technique to combat with the aforementioned pitfalls. MMOHM produces contrast enhanced as well as details preserved output image with the help of the following steps.

Identification of Peaks and Mean
Computation. The first step of the proposed method finds the local maximum points of the histogram by tracing the histogram of the given input image. Generally, peak in the histogram specifies the highest occurrence of some specific gray valued pixel. The histograms of consumer electronics images in general consist of many peaks and, hence, it is desirable to enhance the image around its peaks, which is of prime importance in order to have controlled contrast enhancement and brightness preservation. A point on the histogram is a peak value (local maximum) if its amplitude is more than its neighbors. In order to obtain the peak point, the signs of the difference between two successive probabilities in the histogram are calculated. Let denote a random variable representing discrete gray levels in the range [0, − 1] and let ( ) denote the peak value corresponding to the th value of . Then, the value is calculated as where represents the total number of peaks in the input image histogram. While doing this, if the histogram value is found lower than the value, then it is made to reach the value by increasing it or if the histogram value is higher than the value, it is made to decrease its 4 Mathematical Problems in Engineering value to reach the value. Based on value, the input histogram ( ) is segmented into two subhistograms, namely, ( ) and ( ), where the lower subhistogram ( ) is associated with gray levels ranging from minimum to , that is, { 0 , 1 , . . . , } and the upper subhistogram ( ) is associated with gray-level to maximum gray-level, that is, { + 1, . . . , −1 }. This type of histogram partitioning helps to avoid some portions of the histogram from being dominated by other portions. The motivation of computing value is to improve the mean image brightness preserving capability.

Lower Subhistogram
Modification. HE often produces overenhanced, unnatural looking in the output image which leads to loss of information in the original image. Another problem with HE is its large backward difference values of mapping functions. When the input histogram distribution is already uniform, the mapping obtained from cumulative distribution is ( ) = , which identically maps input to output. In order to find the level of contrast enhancement, the input histogram can be altered so that the modified histogram is closer to uniform histogram of the lower subimage. It also aims to make the difference between the histograms of modified and input image ( − ) small, resulting in the increased potentiality of image contrast enhancement. This is a bicriteria optimization problem since the optimization enhances the contrast of the input image while preserving the details of the original image. So, the output image would be more relevant to the input image. The optimization problem for lower subimage can be defined as The modified histogram for lower subimage can be obtained by finding an analytical solution for (5) as follows: Equation (6) can be rewritten as where , , , and 1 are the modified histogram, input histogram, uniform histogram, and the contrast enhancement parameter for lower subhistogram, respectively.

Upper Subhistogram Modification.
The main objective of this method is to find a modified histogram for upper subhistogram that is closer to uniform histogram and to make the difference between histograms of modified image and original image ( − ) small, which results in increasing the potentiality of image contrast enhancement. Then, the bicriteria optimization problem for upper subimage can be written as The modified histogram for upper subimage can be obtained by finding an analytical solution for (8) as follows: Equation (9) can be rewritten as where , , , and 2 are the modified histogram, input histogram, uniform histogram, and the contrast enhancement parameter for upper subhistogram, respectively.
The value of the contrast enhancement parameters, 1 and 2 , is in the range from 0.0 to 1.0 practically in order to avoid overenhancement. For very low value of these parameters, the mapping function gets saturated leading to overenhancement in the output image. When the value of enhancement parameters is zero, this method tends to behave like a traditional HE. When it is nearer to 1.0, the mapping gradually reaches a maximum value, which preserves the naturalness of the image with increased image quality. When these values are greater than 1.0, the mapping function closely reaches identity mapping which means there is no difference between the original image and output image, resulting in no contrast enhancement. The various changes in the levels of contrast enhancement can be achieved by changing the values of these parameters. The optimal value of 1 and 2 for both subhistograms can be obtained by using PSO. The MMOHM procedure is given in Algorithm 1.
The flowchart representation of MMOHM process is given in Figure 1 3.4. Optimizing the Contrast Enhancement Parameters Using PSO. In the proposed technique, the parameters identified to be optimized are 1 and 2 , as these parameters play an important role in controlling the degree of enhancement. PSO is used to find the optimal value of these parameters, since PSO takes lesser time to converge into better optima than the other evolutionary soft computing techniques [18]. PSO is one of the evolutionary computational techniques based on movement and intelligence of swarms looking for most fertile feeding location. A "swarm" is a disorganized collection (population) of moving individuals that tend to cluster together while each individual seems to be moving in a random direction. It uses a number of agents (particles) that constitute swarm moving around in search space looking for the best solution. Each particle is treated as a point in a two-dimensional space which adjusts its "flying" according to its own flying experience as well as the flying experience of other particles. Each particle keeps track of its coordinates in the problem space which are associated with best solution (fitness) that has been achieved so far. This value is called . Another best value that is tracked by the PSO is the maximum value obtained so far by any particle among the neighboring particle. This value is called . The PSO concept consists of changing the velocity of each particle Mathematical Problems in Engineering 5 Input: An image with a total number of pixels in the gray-level range [ 0 , −1 ], 1 , 2 . Output: The contrast enhanced, details preserved image BEGIN Step 1. Segment the input image into two sub-images (lower and upper sub-histogram of the object) based on multi-peak mean value.
Step 2. Generate the input histograms and for lower and upper sub-images separately.
Step 4. Obtain an optimal value of the contrast enhancement parameters 1 and 2 for lower and upper sub-images using optimization PSO procedure.
Step 5. Compute the modified histogram using the analytical solution of (7) Step 6. For upper sub-image image, obtain an uniform histogram using (1), (2)   toward its and the position at each time step. The velocity of each particle is modified by using the following equation: where V +1 is the velocity of particle at + 1th iteration; is the velocity of particle at th iteration; 1 and 2 are the acceleration factors related to and ; rand1( ) and rand2( ) are the random numbers between 0 and 1; is the position of swarm; is the position of particle.
Using the modified velocity, the particle's position is updated as where +1 is the position of particle at + 1th iteration; is the position of particle at th iteration; V +1 is the particle velocity at + 1th iteration.
The optimized values of 1 and 2 are found using Algorithm 2.
Two iterations are concerned with PSO algorithm in which the former is involved in processing the number of generations and the latter is used for processing the size of the particles. The performance of this proposed method is INPUT: Image with a total number of pixels in the gray-level range [ 0 , −1 ] Output: Optimal value of 1 and 2

BEGIN
Step 1. For each particle (a) Initialize particle with feasible random number End Step 2. Do (a) For each particle (i) Calculate the fitness value (i.e) find the difference between Discrete Entropy values of original and enhanced image.
(ii) If the fitness value is better than the best fitness value (pbest) in history then Set current value as the new pbest End (b) Choose the particle with the best fitness value of all the particles as the gbest (c) For each particle (i) Calculate particle velocity according to velocity update (11) (ii) Update particle position according to position update (12) End While (maximum iterations are not attained); Step 3. Output the new population with the optimal values of enhancement parameters 1 and 2 Step 4. Stop END.
Algorithm 2: Optimization PSO procedure. decided by number of generations and size of the particles. So, the computational complexity of the proposed method is ( 2 ). This process is repeated until a predefined termination condition is satisfied, such as the expiration of a maximum number of iterations. Even though the time complexity is more, the selection of PSO is done because of its incredible performance for finding the optimal values of the enhancement parameters for better contrast enhancement. The PSO algorithm is renowned for its implementation simplicity as there is no need to simulate evolutionary operations such as selection, crossover, and mutation. Another salient feature of the PSO is that the best solution is always maintained without explicitly applying elitism; thus a higher diversification can be applied during the search. This algorithm returns the optimal value of the enhancement parameters once it is terminated.

Image Quality Assessment.
The image quality assessment (IQA) aims to use computational models so as to measure the image quality consistently with subjective evaluations. An IQA index used in the evaluation includes discrete entropy (DE) [22], absolute mean brightness error (AMBE) [16], and natural image quality evaluator (NIQE) [23]. Among these measures, the DE can be considered to be an objective function since it provides better tradeoff than the other measures. NIQE and AMBE can be used as supportive measures to evaluate the degree of enhancement and brightness preservation. A detailed discussion of IQA metrics used in the proposed method is given in the following subsections.

Discrete Entropy (DE).
DE is used to measure the richness of details in the image after enhancement, where an original DE value is obtained in an enhanced image. It indicates that more information is brought out from the images. It is defined as where ( ) is the probability density function of the th graylevel. When the entropy value of an enhanced image is closer to that of the original image, it is considered that the details of the input image are preserved in the enhanced image. The performance of the HE based methods are evaluated by using 80 test images.

Natural Image Quality Evaluator (NIQE)
. NIQE is used for measuring image quality. It is mainly based on the construction of a "quality aware" collection of statistical features which are again based on simple and successful space domain natural scene statistic (NSS) model. These features are derived from a corpus of natural, undistorted images. The quality of a given test image is expressed as the distance between a multivariate Gaussian (MVG) fit of the NSS features extracted from the test image and a MVG model of the quality aware features extracted from the corpus of natural images and it is given by where V 1 , V 2 and 1 , 2 are the mean vectors and covariance matrices of the natural MVG model and the distorted image's MVG model. When the NIQE value of an enhanced image is smaller than that of the original image, it is considered as better image quality [23].
Mathematical Problems in Engineering

Absolute Mean Brightness Error (AMBE)
. AMBE is used to measure whether the proposed method preserves the original brightness in the enhanced image and it is defined as where ( ) is the average intensity of input image and ( ) is the average intensity of the corresponding enhanced output image. AMBE provides a sense of how the image global appearance gets changed. A median value of AMBE indicates better brightness preservation. Either a very low or a high AMBE value indicates poor performance in the case of contrast enhancement [16].

Extending the Proposed Method to Colour Images.
The similar approach extending to the coloured images uses their luminance component only and preserves the chrominance components. Another approach for color image enhancement is to multiply the chrominance values with the ratio of their input and output luminance values to preserve the hue. The former approach is employed in this paper, where RGB image is transformed to the CIE * * * color space and the luminance component * is processed for contrast enhancement. The inverse transformation is then applied to obtain the contrast enhanced RGB image. Hence, the proposed method produces better contrast enhancement for color images also.

Results and Discussion
The results obtained from existing contemporary methods and the proposed method are simulated on various standard gray scale images like truck, Einstein, aircraft, cameraman, airport, Elaine, bottle, circuit, F16, girl, peppers, pirate, putrajaya, village, house, Jet, and so forth and are compared with the enhancement quality of the proposed algorithm. 80 test images are used to evaluate the performance and are subjected to PSO based MMOHM process with 40 iterations. The proposed system has been implemented and evaluated on MATLAB. Figure 2 shows PSO based minimum entropy search (convergence graph) for truck and Einstein images. The graphs clearly show the successful implementation of optimal search mechanism. The optimal value of enhancement parameters are obtained in 9th iteration for truck image, since the objective function (difference between DE value of original and enhanced image) reaches minimal value (i.e., zero). The corresponding optimal values for 1 and 2 are substituted in (7) and (10) to get the modified histogram for lower and upper subimage. Finally, merge the two subhistograms and display the contrast enhanced details preserved output image. Similarly, the optimal value of enhancement parameters are obtained in 11th iteration for Einstein image since the objective function reaches minimal value in 11th iteration. The convergence graph clearly shows the difference between DE values of original and enhanced image for each iteration.
To compare the performance of the proposed method, the same images are enhanced by using the existing contrast enhancement techniques such as GHE, BBHE, DSIHE, WTHE, RMSHE (with recursion level = 2), and RLBHE. In all of these methods, the performance is measured qualitatively by using human visual perception and quantitatively by using three widely used metrics such as DE, AMBE, and NIQE index. The qualitative performance of MMOHM and the contemporary methods are illustrated using Einstein and truck image, which are given in Figures 3 and 5. The original images are given in Figures 3(a) and 5(a). The enhanced images using contemporary enhancement techniques are also shown from show brightness degradation and over enhancement. HEed image in Figure 3 Figure 4(a). The marked portion in the histogram of RLBHE (Figure 4(g)) shows that this method fails to preserve the original details whereas Figure 4(h) exhibits the controlled distribution, which results in the expected contrast enhancement.
The proposed MMOHM method can be extended for color images also. The original fireworks and light house images are shown in Figures 6(a) and 6(b). The resulting images obtained by the various existing methods and proposed method are also given from Figures 6(c) to 6(f). Figures 6(c) and 6(d) show that GHE provides a significant improvement in image contrast. However, it also amplifies the noise level of the images along with some artifacts and undesirable side effects such as washed-out appearance. The enhancement result of RLBHE is visually unpleasing (Figures 6(e) and 6(f)) and some portions are found to be overenhanced. The results of GHE and RLBHE show that they do not prevent the washed-out appearance in overall image due to significant change in brightness. The visual appearance result shows that the proposed method preserves the naturalness of image and also prevents the side effect due to the significant change in brightness effectively (Figures 6(g) and 6(h)). By visually inspecting the images on these figures, it can clearly be noted that only the proposed method is able to generate natural looking image and still offer contrast enhancement. Hence, MMOHM works well for the color images too.

Experimental Analysis.
Initially, the input image gray-level ranging from ( 0 , −1 ) is partitioned into 3 equal subsections. These subsections are ranging between ( 0 , . . . , 1 ), ( 1 + 1, . . . , 2 ), and ( 2 + 1, . . . , −1 ). Then, peak value is found for each subsection. Finally, of these peak values is computed. The same procedure is to be followed for partitioning the gray-level range into 10 equal subsections and 20 equal subsections of entire gray-level. The decision is to use any of these three cases (3 subsections, 10 subsections, or 20 subsections) which depend on the nature of the input image. This procedure is experimented on three different images, namely, aircraft, u2, and circuit. The aircraft image and the corresponding histogram are shown in Figures 7(a) and 7(b). This image is dominated  histograms, it is observed that whenever the number of subsections increased, the enhanced image tends to be original, if the image histogram is evenly distributed. From the above observations, it is understood that the input image is dominated by high frequency or low frequency components as given in Figures 7(a) and 8(a). One should identify the peaks from large number of subsections and value is found based on the peaks identified. This will improve the contrast effectively. When the input image has its histogram components evenly distributed like circuit image (Figure 9(a)), it is better to identify the peaks from smaller number of subsections. The value is computed and it is enough to obtain better contrast enhancement.

Mathematical Problems in Engineering
Further, the qualities of 80 test images which are enhanced using the above mentioned techniques are measured in terms of DE, NIQE, and AMBE. The DE values obtained from some of the test images are given in Table 1. Table 1 enables us to understand that the proposed method proves to produce better entropy values which are closer to the original image. This signifies that the proposed method is found to preserve the details of the original image in the enhanced image also. In Table 2, the NIQE values of the test images for various HE methods along with the proposed method are given. For most of the test images, NIQE is found to have lower values than other methods for corresponding images. This authenticates that the proposed method is found to increase the quality of the output image. Table 3  Most of the HE based enhancement techniques, invariably, attribute to mean shift in output image. This is due to redistribution of intensity values during intensity normalization. However, the proposed technique preserves the mean of the input image. Figure 10(a) shows the comparison of the average DE values of the original, HE, BBHE, RMSHE, WTHE, RLBHE, BBC, LDR, and AGCWD methods along with the proposed method. It is observed that HE drastically changes the original mean of the input image which results in degradation of brightness. But the controlled procedure adopted by MMOHM gives average DE values which are closer to that of original ones. This shows that MMOHM preserves the details of the original image in the enhanced image. The same observation is endorsed from Figure 10(b) by the average NIQE values which make it evident that the MMOHM improves the contrast better than the rest. Figure 10(c) shows the comparison of the average AMBE values of the HE, BBHE, RMSHE, WTHE, RLBHE, BBC, LDR, and AGCWD methods along with the proposed method. From the above results, it is inferred that the proposed method MMOHM produces and preserves brightness along with controlled contrast enhanced output image.
The computation of algorithm was implemented using the MATLAB version 6.0. In a personal computer with 3 GHz Processor, most HE based methods required about less than one minute to process one full HD 256 × 256 pixels image. The discussion of time complexity provides only rough comparison as the procedure depends upon many factors such as the choice of the hardware platform and the level of the software optimization.

Conclusion
This paper uses multipeak mean value to partition the input image into two subimages. Then the particle swarm optimization is used to find optimal contrast enhancement parameters to modify the subhistograms. Finally, the union of the two modified subhistograms produces a contrast enhanced and details preserved output image. It is apparent from the experiments that the proposed MMOHM method creates visually pleasant enhancement effects. This method also eliminates the problems of over enhancement and white saturation which may cause degradation in brightness in the input images. Also, MMOHM accomplishes two major desired objectives of brightness preservation and contrast enhancement for any colored or gray scale images without eliminating the original characteristics of the input image. Moreover, it is not recursive in nature like RMSHE, RSWHE, or RSIHE. This is substantially proved with well known metrics such as DE, NIQE, and AMBE. Hence, this method is more suitable to be employed in consumer electronics for enhancing the contrast of the image without compromising on its visual quality.