Robust Edge Detection Method for the Segmentation of Diabetic Foot Ulcer Images

—Segmentation is an open-ended research problem in various computer vision and image processing tasks. This pre-processing operation requires a robust edge detector to generate appealing results. However, the available approaches for edge detection underperform when applied to images corrupted by noise or impacted by poor imaging conditions. The problem becomes significant for images containing diabetic foot ulcers, which originate from people with varied skin color. Comparative performance evaluation of the edge detectors facilitates the process of deciding an appropriate method for image segmentation of diabetic foot ulcers. Our research discovered that the classical edge detectors cannot clearly locate ulcers in images with black-skin feet. In addition, these methods collapse for degraded input images. Therefore, the current research proposes a robust edge detector that can address some limitations of the previous attempts. The proposed method incorporates a hybrid diffusion-steered functional derived from the total variation and the Perona-Malik diffusivities, which have been reported to can effectively capture semantic features in images. The empirical results show that our method generates clearer and stronger edge maps with higher perceptual and objective qualities. More importantly, the proposed method offers lower computational times—an advantage that gives more insights into the possible application of the method in time-sensitive tasks.

INTRODUCTION Statistics show that the number of people with diabetes has been exponentially increasing worldwide [1]. This disease causes major life-threatening complications, including cardiovascular diseases, kidney failures, blindness, and lowerlimb amputations, often preceded by diabetic foot ulcers [2]. Among these complications, managing and diagnosing diabetic foot ulcers remains a major challenge in healthcare systems [3]. Being a serious health concern for diabetic patients, early detection and effective preventive care of the disease can greatly reduce the risk of further complications. Non-invasive vascular testing methods and imaging are crucial in improving the healing of diabetic foot ulcers, and, more importantly, to prevent early amputation referrals. Because the preliminary diagnosis of diabetes is relatively challenging with the existing conventional dermatological methods, (non-invasive) image processing techniques have been recently proposed which have demonstrated promising results [4]. These non-contact imaging methods assist clinicians to follow the prognosis and the healing status of the ulcers without compromising the sterilization techniques required to manage such ulcers [5].
Digital image processing has become an important field in analyzing medical images. More specifically, the introduction of digital image processing for the detection and evaluation of ulcers and wounds has become one of the most important methods in linking and optimizing the results of the diabetic foot ulcers [6]. For example, the accurate detection of the edges of the foot ulcers ensures better results for further processing of these images. The effectiveness of many image processing and computer vision tasks depends on the perfection of detecting meaningful features, including edges (local discontinuities or abrupt changes in image grey values and/or texture). Edge detection is one of the fundamental steps in image analysis and is useful in finding key features in images [7]. In digital images, edges are used to depict local and significant intensity changes [8]. The purpose of edge detection is to minimize the image data to be processed. Hence, edge detection has become an important part of the pre-processing stage before the segmentation or classification of medical images. Therefore, this pre-processing step plays a vital role in medical image analysis. Conventionally, edges are detected using Sobel, Prewitt, or the Laplacian of Gaussian operators. In theory, these operators belong to high-pass filtering, which is unsuitable for edge detection in most medical images because noise and edges belong to high frequencies [9]. Most of these edge detectors are based on detecting points in the image with a high image gradient value. This detection strategy is susceptible to false edge points, which are undesirable in the final output-a This paper proposes an image pre-processing edge detector for the accurate segmentation of diabetic foot ulcers in digital images. Segmentation is an essential preprocessing step in many computer guided medical image analysis and diagnosis methods [10]. We employ the idea that most shape information of the ulcers is embedded in the edges. In this work, we first detect the diabetic foot ulcer edges from the images using the proposed method, which is based on the gradient-driven quadratic functional. Then several morphological operations are performed to enhance the quality of edges in the target regions. Our method integrates two shape-defining constants that can be tuned to highlight the local edges of the ulcers. With the careful selection of the constants, the proposed edge detector can robustly reveal clear edges in ulcer images contaminated with noise. The novelty of our work can be derived from the proposed edge-locating functional, which integrates total variation [11] and Perona-Malik [12] diffusion coefficients. The hybrid nature of this formulation provides an effective way of extracting meaningful image features, including edges, contours, and textures. We noted that our edge detector outperforms the classical edge detectors, and can robustly reject unwanted artifacts that may smudge edges. This work, in addition, has established a systematic approach to locate regions of foot with diabetic ulcers. These contributions advance our current understanding of treating patients with diabetic foot ulcers.
Using MATLAB and foot ulcer images from accredited sources, different edge detectors (Canny, Sobel, Roberts, Laplacian of Gaussian, and Prewitt) were tested and their performance was evaluated. The selected edge detectors are classical and have been widely used in other image processing and computer vision tasks. Three quality metrics were used to evaluate the performance of the proposed method: peak-signalto-noise ratio (PSNR), Mean Structural Similarity (MSSIM), and execution time. The results show that our method outperforms the classical ones, signaling its possible applications in industrial settings.
II. RELATED WORK Diabetes Mellitus is a metabolic chronic disease that is associated with abnormal glucose levels in the blood. The disease leads to life-threatening complications, including diabetic foot ulcers discussed in the current work, and is generally considered as a major global health problem [13]. Diabetic foot ulcers may cause amputation of a lower limb or even death in severe cases. The current diagnostic practice of the problem involves clinicians and nurses to perform visual wound assessment to determine wound size and healing status. In essence, evaluation of diabetic foot ulcers comprises of various important tasks in early diagnosis: (1) evaluation of patients' medical history, (2) thorough examination of the foot ulcer by a specialist, and (3) initiation of additional tests, such as Computer Tomography (CT) scan, Magnetic Resonance Imaging (MRI), and X-Ray, if applicable [14]. The visual approach is subjective and inaccurate for wound area determination and tissue classification [15]. Furthermore, the imaging modalities, such as X-ray and magnetic resonance induction, are expensive, and therefore, may not be easily accessible in most developing countries with limited healthcare facilities. These challenges call for a need to establish methods that can objectify and increase the accuracy of the traditional methods of analyzing diabetic foot ulcers [16]. This work uses image processing and morphological operations as potential solutions to address the issue of inaccuracy caused by visual assessment. The solution can minimize the frequency of patient visits to the clinic to receive treatments or medical examinations.
Authors in [17] employed the Sobel operator to exclude the edges of the feet in the developed thermal imaging system for the foot ulcers. In their work, the main focus was to get the feet edges and not the particular ulcer area. As this method was fully dependent on the temperature gradient from the acquired thermal images, it tended to generate false positives around the ulcer area. To further improve the edge detection accuracy, authors in [18] used an edge detection method that is based on Active Contour Models (ACMs) as an attempt to address the drawbacks of conventional methods. Although the ACMs have superior sub-pixel accuracies as compared to the conventional methods, their outputs can be easily affected by the intrinsic disadvantages of the active contour algorithms, including contour's initial position and the presence of noise in the images. The fundamental requirement of any edge detection method is its ability to accurately extract the edge lines while maintaining their good orientations. Given this requirement, the performance of different edge detectors depends on the imaging conditions. Comparative evaluation of edge detectors facilitates the process of deciding an appropriate method for image segmentation of diabetic foot ulcers. For this purpose, two main approaches have been proposed in the literature as shown in Figure 1. The gradient-based approaches, which detect the edges by finding the maximum and minimum values of the image's first derivative and the Laplacian-based approaches which search for zero crossings in the image's second derivative [19]. A number of studies have been done to compare the edge detectors performance by conducting comprehensive analysis of the image edge detection techniques. These studies are all aimed at determining the best operator when analyzing different shapes in image processing applications [20]. Table I gives a summary of the performance for both gradient based and Laplacian based operators [21]. This summary highlights the benefits and the weaknesses of the detectors. The proposed method is derived in a way that it maintains the benefits of these detectors and remedies their weaknesses.

III. THE PROPOSED EDGE DETECTION METHOD
A. Computing the Edges Inspired by the weaknesses of the mentioned traditional methods, an alternative approach is proposed that can facilitate the segmentation of a diabetic foot ulcer from an image, ‫ݑ‬ ( Figure 2). Let ‫ݑ‬ ௫ and ‫ݑ‬ ௬ be the horizontal and vertical derivatives of ‫ݑ‬ respectively. Furthermore, because an edge denotes a significant local change in the image intensity, it is usually associated with a discontinuity in either the image intensity or in its first derivative. The change in the intensity level is measured by the gradient of the image. The diabetic foot ulcer image, ‫,ݔ‪ሺ‬ݑ‬ ‫ݕ‬ሻ, is a two-dimensional function, hence, its gradient is a vector. The magnitude and the direction of the gradient may, respectively, be computed as: The magnitude of the derivative provides a measure of the strength/contrast of the edge. Several experiments were conducted to determine the most suitable functional for computing edges, and it was empirically found that a formulation containing the diffusion kernels of both Total variation [11] and Perona-Malik [12] methods outperforms the classical methods. Therefore, our functional becomes: where ݇ ଵ 0 and ݇ ଶ 0 denote the tuning constants that determine a tradeoff between clarity of edges and noise. Considering the denominator of the proposed functional, the second and third terms from the left signify versions of the total variation and the Perona-Malik methods. The proposed functional ensures that a proper balance is established between weaknesses and strengths of the two formulations, as evidenced by clearer and stronger edges recovered by the proposed edge detector.

B. Mathematical Morphology
We employed several morphological operators to increase the accuracy of locating and connecting the edges of the ulcer area. The goal was to ensure the continuity of adjacent objects by filling "breaks" with pixels. In MATLAB, the function bwconncomp can be used to connect edges of the ulcer area from the edge maps of the input binary image. Flowchart of the proposed method.
Next, applying the MATLAB function regionprops on the binary edge map, allows us to find individual properties, such as pixelList and pixelArea. The regionprops function returns measurements for the set of properties specified for each eightconnected object in the binary image of the edge map. Using these region properties, we eliminated all areas below the pixel area of 150 pixels. The eliminated areas were due to small objects or textures in the image, and included short lines outside the region of interest. The tuning constants, ݇ ଵ and ݇ ଶ , control the sensitivity to edges, hence to ensure that the IV. PERFORMANCE EVALUATION To verify the performance of the proposed edge detection method, a range of experiments was performed using various diabetic foot ulcer images. The dataset was obtained from accredited sources including the Arusha regional hospital (Arusha, Tanzania) where images were captured from diabetic patients that voluntarily participated in the study. For the selfcaptured images, we obtained ethical clearance from the Northern Tanzania Health Research Ethics Committee. A variety of images were used to accommodate different skin types, image-capturing angles, and the separation distance between the camera and the target scene. The performance evaluation of different edge detection algorithms was accomplished through four indices: visual appealingness (ability to detect true edges), PSNR [22], MSSIM [23], and processing time. PSNR measures the strength of a signal relative to noise and is defined by: where ܴ denotes the maximum variation in the input image data, and MSE denotes the mean squared error given by: where ‫ݑ‬ሺ݉, ݊ሻ and ݂ሺ݉, ݊ሻ are respectively the original and the output images, ‫ܯ‬ and ܰ denote the horizontal and the vertical dimensions of an image; and (݉, ݊ሻ define the pixel location in the image [24]. PSNR however, disregards the human visual system and therefore may provide incomplete information on the quality of the images [25]. Authors in [26] recommended an alternative metric called Mean Structural Similarity (MSSIM) to address some of the weaknesses of PSNR. This alternative metric is defined by: where the variables, respectively defined for ‫ݑ‬ and f, are as follows: ߤ ௨ and ߤ , mean; ߪ ௨ ଶ and ߪ ଶ , variance; ߪ ௨ , covariance; and, ܿ ଵ and ܿ ଶ are stabilizing constants.
Another performance evaluation metric is computational complexity, which, in the context of our research, refers to the time taken for the edge detector to output the corresponding edge map. For this purpose, we used the MATLAB stopwatch timer functions, tic and toc to compare the execution time of the different edge detectors. In addition, we adhered to three principles governing our decisions on the quality of the results. Foremost, the edge detector should accurately find all real edges (and should ignore false edges), secondly, the edges should be found in the correct image locations, and, thirdly there should not be multiple edges found for a single edge [27].

V. RESULTS AND DISCUSSION
Visual results demonstrate that the proposed method outperforms the classic ones in several cases of input images (Figures 3-6). More specifically, our method generates appealing images that clearly reveal the location of the foot ulcers. To highlight the performance in terms of visual appeal, the proposed method produced superior edge maps compared to the results of the authors in [28], who employed the Sobel operator to determine the ulcer edges. The method has also increased pixel accuracy in locating the ulcer edges when compared to another recent study [17]. Quantitative results further demonstrate higher values of PSNR and MSSIM depicted by our method compared with the classical methods (Tables II and III). This objective evaluation confirms the effectiveness of the strategy used to formulate the edge detector. Combining the diffusivity of total variation and the Perona-Malik mask may generate more plausible edges. However, the tuning constants must be carefully selected to ensure better results. On the other hand, the Canny operator shows the least average PSNR and the visual results suggest that this operator detects weak edges, a consequence that signals a possible generation of the unrequired false edges. Furthermore, the proposed method is computationally efficient (Table IV). Therefore, we can implement the method into actual hardware to segment foot ulcer images in practical settings. Given the promising results, an extension of our approach to such hardware may provide a revealing experience to the healthcare industry  VI. CONCLUSION In this paper, a method has been proposed for detecting and locating diabetic foot ulcers in images and its performance was compared to the existing classical methods. The major contribution of this work is its ability to combine the edgepreserving models of Perona Malik and total variation to produce edge maps that are more accurate and can be used for further processing of the ulcer images especially in segmentation and documentation of their characteristics such as shape and size during diagnosis and prognosis. The method achieves higher values of PSNR and structural similarity, even under noise and varying skin colors. Also, the method offers a smaller computational load, implying that it may be useful in real-world tasks. Despite these promising achievements, the tuning constants must be manually chosen for optimal segmentation results. Future research may consider automating the process of edge detection by minimizing the dependence of the tuning constants. The method, also, underperforms for images with dimensions smaller than 107×154 pixels. Another challenge that calls for further research involves a variation of the skin color: although our method can deal with the black skin (on which other methods collapse), the results cannot be generalized across all skin types. These limitations may be addressed using other sophisticated image pre-processing techniques, including deep learning.