Segmentation of Intensity-Corrupted Medical Images Using Adaptive Weight-Based Hybrid Active Contours

Segmentation accuracy is an important criterion for evaluating the performance of segmentation techniques used to extract objects of interest from images, such as the active contour model. However, segmentation accuracy can be affected by image artifacts such as intensity inhomogeneity, which makes it difficult to extract objects with inhomogeneous intensities. To address this issue, this paper proposes a hybrid region-based active contour model for the segmentation of inhomogeneous images. The proposed hybrid energy functional combines local and global intensity functions; an incorporated weight function is parameterized based on local image contrast. The inclusion of this weight function smoothens the contours at different intensity level boundaries, thereby yielding improved segmentation. The weight function suppresses false contour evolution and also regularizes object boundaries. Compared with other state-of-the-art methods, the proposed approach achieves superior results over synthetic and real images. Based on a quantitative analysis over the mini-MIAS and PH2 databases, the superiority of the proposed model in terms of segmentation accuracy, as compared with the ground truths, was confirmed. Furthermore, when using the proposed model, the processing time for image segmentation is lower than those when using other methods.


Introduction
Image segmentation involves segmenting or partitioning a digital image into regions that contain objects of interest; this process is the basis for digital image analyses. Different techniques have been employed for image processing and computer vision in order to segment meaningful regions of interest (ROIs) in images.
Images can be classified as homogeneous or inhomogeneous based on the types of regions they comprise. Figure 1 presents an example of a homogeneous image with a strongly defined boundary, along with its histogram. Furthermore, Figure 2 depicts an inhomogeneous image along with its histogram, illustrating the inhomogeneity of the image.
Imaging technologies have played a significant role in improving the quality of medical care. By using such tech-niques, accurate diagnoses for complications in various regions of the body can be realized, such as tumors in the brain, veins, and breasts [1][2][3][4][5][6][7][8][9][10]. In medical imaging, tumor boundaries are defined to measure the sizes of the ROIs, thereby providing early cancer diagnoses [11]. However, identifying object details from images obtained via techniques such as magnetic resonance imaging, computerized tomography imaging, and X-ray imaging can be challenging due to the presence of significantly inhomogeneous intensities and blurred object boundaries.
There are different methods to perform image segmentation such as Supervised methods and unsupervised methods. The deep learning relies on the training dataset in deep learning-based image segmentation [12]. The larger and comprehensive datasets are used for better segmentation accuracy and efficiency; however, produce inferior results on small datasets. The level set methods are known as unsupervised methods to perform image segmentation and used preselected parameters, depending on the Region of Interest. The proposed method contributes the unsupervised method and surpasses previous level set methods, in terms of efficiency. Furthermore, the comparison of the proposed method with other state-of-the-art methods and the ground truth performed and shown in the result section.
Active contours, which is an image segmentation technique employing energy minimization for the extraction or separation of ROIs, can be used to overcome these issues. Active contours are computer-generated curves that move under the influence of equal and opposite internal and external forces. Active contour models are categorized into two types: edge-based [13][14][15][16][17] models and region-based [1][2][3][4][5][6][7][8][9][10][18][19][20][21][22][23][24] models. Edge-based models employ image gradientbased edge detectors to control contour evolution to the desired object boundaries. These models exhibit inferior performance on images with strong noise, weak edges, and low contrasts. Region-based models offer several advantages over the edge-based models. Region descriptors, commonly employed to control contour evolution, are less sensitive to contour initialization and do not utilize the image gradient. Therefore, images with low contrast and/or weak boundaries can also be segmented successfully.
For instance, the Chan and Vese (C-V) region-based model [2] offers advantages in terms of contour initialization and noise, as compared with edge-based models. However, region-based models tend to perform poorly when the images feature inhomogeneous intensities.
Li improved the C-V model using the local binary fitting (LBF) [3] energy to segment images with intensity inhomogeneity. LBF introduces local minima into energy functionals using local information. However, contour initialization is highly sensitive, which limits its usage in different applications [25]. Chen et al. [7] proposed an improved active contour model for intensity inhomogeneous image segmentation, employing a customized Gaussian kernel bias field estimator to address the inhomogeneity in intensity. The variational formulation accurately identifies the global energy functional minimum when segmenting images [11,[26][27][28]. However, the energy functional identifies one segment region at a time, and it was formulated under the assumption that the K-mean characteristic functions are combined linearly and represented as intensity variations [29,30]. Min et al. [31] proposed a method based on a global division algorithm; this method employed a new global intensity term, which further improved the performance of the C-V model for complex image intensities.
In this study, we formulate a hybrid region-based active contour model with variation level set derivation, using both local and global intensity fitting energy terms. This hybrid model completely eliminates reliance upon the initial contour position and incorporates an adaptive weight function to efficiently segment images with intensity inhomogeneity. Figure 3 presents the results obtained by applying the proposed method on the homogeneous and inhomogeneous images in Figures 1 and 2, respectively.
The contributions of this study to active contour model-based image segmentation can be summarized as follows: (i) A novel hybrid active contour model comprising efficient features of the local region-based and global region-based fitting energies is proposed (ii) The inclusion of the local region-based ACM statistics ensures that the contour evolution over inhomogeneous regions effectively captures the intensitycorrupted ROI (iii) The inclusion of the global region-based ACM statistics ensures robust evolution of the contour over homogeneous regions (iv) The hybrid active contour formulation makes the contour movement independent of the contour initial location, making it less sensitive to the local minima (v) The adaptive weight function helps to adapt fitting parameters over object boundaries and contributes to an increase segmentation accuracy The remainder of the paper is organized as follows. Section 2 presents a review of standard models and discusses their limitations. The proposed energy model and its level set formulation are described in Section 4. Section 6 presents the validation of the results of the proposed method for real and synthetic images. Section 5 discusses various outcomes for the quantitative analysis of the proposed approach, as compared with the ground truths. Finally, Section 6 highlights the conclusions of this research.  [20] proposed an object functional for image segmentation, defined as follows:   where Ω defines an image domain, I is the intensity of the original image, C is the length of the curve, and μ and v are positive fixed parameters. The fitting function u and the optimal segmenting curve C can be obtained via the minimization of the energy functional to approximate I. Thus, the model provides a curve C, segmenting the image into several separate ROIs. A fitting function u smoothens each subregion and thus estimates the intensity I of the original image. However, it is challenging to minimize the energy functional due to the unknown contour C. Therefore, various methods have been proposed to modify this energy functional, some of which are discussed below.

Chan-Vese (C-V)
Model. The C-V model is a regionbased active contour model that overcomes the shortcomings of the Mumford-Shah model [20] by using a simple assumption that the image intensities in each ROI are constant. The energy functional in the C-V model is expressed as where IðxÞ represents the image being analyzed, and the global fitting energies e 1 and e 2 are the image intensities inside and outside the contour C, respectively. λ 1 , λ 2 , μ,   and v are positive parameters, and area ðCÞ is the Heaviside function. On minimizing equation (2) with respect to e 1 , e 2 , and ϕ using the gradient descent [28], we obtain where H is the Heaviside function, with the Dirac delta function σ, and ϵ is a constant that controls the Dirac delta smoothness and the width in H. Approximations for the Dirac and Heaviside functions are as follows: In case of inhomogeneous images, the global fitting energy terms fail to provide sufficient statistics to the C-V model, resulting in unsatisfactory segmentation over inhomogeneous regions. Although the C-V model shows satisfactory performance for homogeneous images, its limitation for inhomogeneous images makes it less preferred.
where G σ represents the Gaussian kernel function with the standard deviation σ. The LBF energy functional can be represented in a level set formulation by minimizing equation (6) with respect to the local intensity means inside and outside the regions, termed as h 1 and h 2 , respectively. These can be defined using the gradient descent as follows [28]: LBF can segment inhomogeneous images using the local statistical information in a timeframe to decide the direction of contour evolution. Although LBF outperforms the C-V model in inhomogeneous image segmentation, it misses obscured boundaries in some inhomogeneous images. This is because the local intensity means statistics are insufficient to provide accurate segmentation results in every scenario. Figure 4 shows an example image with a blue rectangle and red outline, representing the initial contour and the evolving segmentation curve, respectively. The pixel p 1 is on the less inhomogeneous region; thus, the contour stops evolving at this level. The local intensity means h 1 and h 2 are unable to capture regions with increased inhomogeneity levels. Therefore, pixels p 2 and p 3 are determined at uncertain positions by the LBF model.  [31] includes an effective global term to help segment ROIs with complicated intensity in noisy images, which the C-V model struggles to segment accurately. The global term is an energy functional based on a global division algorithm that develops a new ROI-based term to accurately segment objects with large intensity differences and significant noise. This global energy functional is defined as E Min ϕ, e 1 , e 2 , g 11 , g 12 , g 21 , g 22 ð Þ where HðIðxÞ − e 1 Þ and HðIðxÞ − e 2 Þ are the intensity magnitudes. This method has the advantage of simultaneous calculation of the intensity means from the regions inside and  Computational and Mathematical Methods in Medicine outside the object. On minimizing equation (10) with respect to g 11 , g 12 , g 21 , and g 22 the steepest gradient descent, we obtain Þdx , where g 11 and g 12 are the larger and smaller mean intensity values inside the contour, respectively. g 21

Proposed Model
The proposed energy functional is formulated by combining gainful features of both the local and global fitting models. An adaptive weight function is appended with the hybrid energy functional to parameterize weight coefficients for images with different levels of intensity corruption. The global  Computational and Mathematical Methods in Medicine fitting part of the proposed model is termed as the global fitting energy support function ðF GFES Þ, and it is defined as where AvgðI T Þ is the average intensity of the image under analysis and reflects the global contrast for the image, p ∈ ½0, 1, where p denotes positive fixed parameters. The image intensity is defined as where T defines the local window size, I max is the maximum intensity level, and I min is the minimum intensity level within the local window. The overall image intensity level is represented by I g , and it is typically 255 for grayscale images. I T ∈ ½0, 1 reflects the rate of intensity changes in a local ROI. It is smaller for smooth ROIs and larger for ROIs near the object boundaries. Thus, the proposed energy functional, incorporating both global and local fitting energy terms as well as the adaptive weight function, is expressed as

Computational and Mathematical Methods in Medicine
The primary objective is to set the adaptive weight parameter for the global fitting energy term dynamically. The value of the weight parameter ranges from 0 to 1, depending on the inhomogeneity level of the image. Small values account for low levels of inhomogeneity, whereas high values account for high levels of inhomogeneity in the image. Therefore, in the proposed method, the global fitting energy weight function is increased to ensure accurate active contour evolution for inhomogeneous images.
Thus, minimizing E LGEF with respect to ϕ by utilizing the steepest gradient descent method, we obtain The proposed formulation eliminates computationally expensive reinitialization, by using the penalizing energy term from [1]. The initial level set function in the proposed method is defined as where ρ > 0 is a constant. Finally, the algorithm of the proposed method is as follows.

Results
The proposed method is tested using synthetic and real images, and it is quantitatively analyzed on two different datasets: mini-MIAS [32] and PH 2 [33]. All experiments were performed using MATLAB 2018, on a Windows 10 operating system with a 3.40 GHz Intel Core-i7 processor and 16 GB RAM. Table 1 lists the parameters used in the experiments, including the default parameters of compared methods, for segmenting inhomogeneous intensity images using the proposed method. Figure 6 presents the results of the inhomogeneous intensity image segmentation achieved using the LBF and proposed methods, for an original image with an initial contour. It can be seen that, unlike the LBF model, the proposed method segmented the image accurately. Furthermore, Figure 7 shows the segmentation results for four medical images with inhomogeneous intensities. From the results, it  Computational and Mathematical Methods in Medicine is evident that the proposed method achieves superior segmentation accuracy and is also time-efficient during the medical image segmentation. Figure 8 shows the real medical images used to validate the accuracy and time efficiency of the proposed method. The proposed method fitted the contour smoothly within a minimum amount to time. Figure 9 shows the segmentation results for the synthetic images. Our method achieves improved segmentation accuracy on the synthetic images. The second column in Figure 9 shows the results of the proposed method after five iterations, and the third column shows the results of the proposed method. Figure 10 compares the segmentation results for medical images obtained using the LBF, Min et al.'s, and proposed methods. The LBF contours tend to be close to the boundaries, with clear segmentation noise in the images; images processed using Min et al.'s method are inaccurately seg-mented for a few ROIs with weak boundaries. On the contrary, the proposed method yields good segmentation for all images with different levels of inhomogeneous intensities. Figure 11 compares the segmentation results of different synthetic images obtained using LBF, Min et al.'s, and proposed methods. The images processed using LBF are inefficiently segmented when the intensity levels change, whereas the images processed using Min et al.'s method exhibit inaccurate segmentation on ROI boundaries where the intensity levels change smoothly. However, all the object boundaries are accurately segmented when using the proposed method. Figure 12 presents synthetic images with different intensities segmented using C-V, LBF, Min et al.'s, FRAGL [34], and proposed methods. The CPU times for the C-V and LBF models were longer than those for the other models. This is because these methods employ convolution, which requires additional time for convergence. Segmentation

10
Computational and Mathematical Methods in Medicine   [28], and column 8=proposed method.  Results of the FRAGL model were segmented to the object boundary, although the contour moved smoothly to the object; however, these results were not accurate at the boundary. The proposed method yielded more accurate segmentation than the other methods, requiring minimum time and lesser iterations to converge the contours to object boundaries. Figure 13 compares real-life images with different inhomogeneous intensity levels, for C-V, LBF, Min et al.'s, FRAGL [34], and proposed methods. The FRAGL model achieved improved segmentation accuracy with minimum CPU time and lower number of iterations; however, the proposed method was more efficient. Thus, objects within the images were segmented according to the differences in their intensities.

Quantitative Comparison
We compared the results of the proposed method against the ground truths and other state-of-the-art methods.
The mini-MIAS database is an open source dataset for breast tumor detection. Figure 14 shows example mammograms from the mini-MIAS database used for quantitative results, and it investigates advantages of the proposed method. We compared the segmentation methods using an accuracy metric defined as where TP denotes the true positive segmented regions, TN denotes the true negative unsegmented regions, FP denotes false positives, and FN denotes false negative, i.e., the undetected tumor regions. Table 2 presents the statistics of the segmentation accuracy of Figure 14 as compared with other methods, based on the ground truth. Figure 15 indicates that the segmentation accuracy of the proposed method is significantly higher than that of the previous methods. The PH 2 database [33] was developed to encourage comparative studies for classification algorithms and the segmentation of dermoscopic images. We compared the results of the proposed method with other state-of-the-art methods using the metric for segmentation accuracy defined in equation (17). Figure 16 shows the segmentation results for example images from the PH 2 database using the proposed method and comparisons with the ground truth. The green contour indicates the ground truth, whereas the red contour indicates the segmentation via the proposed method. From the figure, it is evident that the proposed method exhibits suitable accuracy for the segmentation of the example images. Table 3 presents a comparison of the accuracy, number of iterations, and the CPU time of the proposed method on the PH 2 database [33] with other state-of-the-art methods. The overall accuracy of the segmentation results proves that the proposed method offers superior performance. Moreover, compared with other methods, the number of iterations and the CPU times of the proposed method proves the time efficiency of our model.

Conclusion
We propose a novel hybrid active contour model integrating local and global fitted energy terms, with an adaptive weight function. The weight function uses global contrast statistical information to adapt the weight parameters dynamically. The proposed method improves image segmentation accuracy 0.687 Accurary C-V [2] LBF [3] Min et.al′s [29] Asim et al.′s [27] Proposed FRAGL [30]  for regions with homogeneous and inhomogeneous intensities, and its contour stability and smoothness around accurate object boundaries are confirmed using both local and global statistics. Furthermore, the inclusion of the Gaussian kernel eliminates the need for a reinitialization time, making the proposed model independent of the initial contour positions. Compared to other state-of-the-art models, the proposed method offers superior performance for real and synthetic images with various inhomogeneous intensity levels, as well as significant improvements in terms of segmentation accuracy and processing time efficiency. Furthermore, quantitative comparisons proved the superiority of the proposed approach.

Data Availability
We have used different images (synthetic and real) publicly available on the internet. In comparison, the other databases are used for quantitative comparison are listed below with references. (1) The mini-MIAS database, to encourage comparative studies for classification algorithms and the segmentation of mammogram images, is publicly available that can be accessed at http://peipa.essex.ac.uk/info/mias.html. (2) The PH2 database, to encourage comparative studies for classification algorithms and the segmentation of dermoscopic images, is included within the article doi:10.1109/EMBC .2013.6610779.

Conflicts of Interest
The authors declare that they have no conflicts of interest.