An Improved Segmentation Technique for Early Detection of Exudates of Diabetic Retinopathy Disease

Diabetic retinopathy (DR) is a diabetescaused disease that is associated with leakage of fluid from the blood vessels into the retina, leading to its damage. It is one of the most common diseases that can lead to weak vision and even blindness. Exudates is a clear indication of diabetic retinopathy, which is the main cause of blindness in people with diabetes. Therefore, early detection of exudates is a crucial and essential step to prevent blindness and vision loss is in the analysis of digital diabetic retinopathy systems. This paper presents an improved approach for detection of exudates in retina image using supervised-unsupervised Minimum Distance (MD) segmentation method. The suggested system includes three stages; First, after image acquisition, it is pre-processed for preparing and improving its quality. Second, the simple toward interpretation and analysis of image is segmentation as another stage. In this research, we presented a method which is used for segmentation of exudates by the adaptive (supervised-unsupervised) Minimum Distance (MD) creation segmentation algorithm with two non-overlapping clusters. The method was proposed based on its performance compared with other methods and followed by exudates extraction as a final stage. This proposed framework helps the ophthalmologists to distinguish the problem earlier, which enables them to recommend a superior medication for forestalling further retinal harm.


Introduction
Diabetes has related difficulties such as vision misfortune, heart disappointment and stroke. Patients with diabetes are bound to create eye issues, for example, waterfalls and glaucoma; however, the impact of the illness on the retina is the principle risk to vision. Intricacy of diabetes, causing variations from the norm in the retina and in the most pessimistic scenario serious vision misfortune, is called diabetic retinopathy (DR) [1]. For example, diabetic retinopathy causes damaged vessels and blood spillage in the retina. It is a standout amongst the most widely recognized infections that cause visual deficiency. One out of every three diabetic individual seems to have diabetic retinopathy and one out of ten experiences its most extreme and vision-compromising structures. Diabetic retinopathy is separated into two phases; non-proliferative diabetic retinopathy (NPDR) and proliferative diabetic retinopathy (PDR). Early location and ensuing treatment are fundamental for influenced patients to save their vision. In diabetes, fundus imaging assumes a significant job for observing the retinal variations from the norm. For example, diabetic retinopathy can be dealt with utilizing accessible medications, which are successful whenever analyzed early. Since diabetic retinopathy is asymptomatic until late in the ailment process, regulsr eye fundus examination is important to screen any adjustments in the retina [2].Exudates are the principal indication of (DR) which causes visual impairment. Thus, it is imperative to discover these exudates in fundus picture. Identification of exudates is significant in analysis of diabetic retinopathy. Exudates are brilliant yellow spots on the outside of the retina and are the essential indication of DR [3]. Our research focuses on the development of a PC-aided (CA) automated system for the early detection of diabetic retinopathy that depends on the reliable detection of retinal lesions in fundus images.

Diabetes and Diabetic Retinopathy
Uncontrolled diabetes can be extremely hazardous, bringing about loss of vision, harm to the nerves, kidneys and expanded danger of heart assault and the rundown could proceed. DR, if not appropriately treated, expands the danger with the expanding age of the patient and it may in the long run lead to loss of vision [4].
The diabetic retinopathy, is divided in to two levels. These levels are non-proliferative diabetic retinopathy (NPDR) and proliferative diabetic retinopathy (PDR). Non-proliferative diabetic retinopathy is also divided into three categories; mild non-proliferative diabetic retinopathy, moderate non-proliferative diabetic retinopathy and severe non-proliferative diabetic retinopathy [1]. The earliest stage of diabetic retinopathy is the non-proliferative diabetic retinopathy. Previously, it was known as background retinopathy. It occurs when blood vessels of the retina are changed. These changes are not visible by the naked eye. In the early stage, these symptoms are not noticeable but as it progresses it causes blindness. This type of diabetic retinopathy shows cotton wool spots, retinal hemorrhage, and microvascular abnormalities. If there is the development of macular edema, the NPDR person loses their vision. Swelling in the macula causes fluid leakage from retina's blood vessel. In diabetes, the most common cause of vision loss is macular edema. If a person has diabetes with mild NPDR, this does not affect the vision ofa patient. If their vision is affected, it is the result of macular edema. Generally, DR occurrence is categorized into three main stages [3]. i) Proliferate Diabetic Retinopathy (PDR): In this stage, dissemination issues cause zones of the retina of the eye to move toward becoming ischemia or oxygen-denied. Delicate new vessels create as the circulatory framework attempts to keep up satisfactory oxygen levels inside the retina. This This phenomenon is known as the extending of veins (Neovascularisation). Blood may leak into the retina and vitreous, causing spots or floaters, along with decreased vision.

Mahmood and Aziz
Iraqi Journal of Science, 2019, Vol.60, No.11, pp: 2520-2530 2522 ii) Background Diabetic Retinopathy (BDR): At this stage, the arteries in the retina become weak and begin to leak, forming tiny dots-like objects called hemorrhages. These vessels often cause leakage to the swelling or edema of the retina and reduced vision.  Severe Diabetic Retinopathy (SDR): At this stage, abnormal vessel growth and scar tissue continue, which can cause serious problems such as retinal detachment, glaucoma and progressive loss of vision. These three phases can occur with any of the following artifacts: [3]:Microaneurysms, Haemorrhagesm ,Neovascularisation: and Abnormal Vein-Supply route Hybrid The normal and abnormal retinal images and these artifacts of DR are illustrated in Figure-

Image Segmentation
Segmentation is extracting significant primitives and regions of interest (ROI). This is necessary either for performing measurements, that will allow classification and identification, or for reconstruction purposes. In order to obtain significant features; segmentation groups pixels into regions and hence define their boundaries. Image Segmentation involves the isolation of a single object from the rest of an image, or partitioning an image into groups of homogeneous pixels with respect to some predicate. Each group is called a segment, different segments must not intersect and adjacent segments must be heterogeneous [5]. Pixels within a segment need not necessarily be spatially connected. Moreover, image segmentation may be defined as the process of assigning labels to individual pixels in a volumetric data set, based on some criteria in the image. The main objective of segmentation stage is to group the image into regions with same properties or characteristics. This plays a major role in image analysis system by facilitating the description of anatomical structures and other regions of interest, [6].
Generally, image segmentation techniques can be classified into: manual segmentation techniques and Computer Aided (CAD) segmentation techniques. (CAD) segmentation techniques divided in two kind grayscale segmentation methods such as thresholding-based, edge-based, seed growing segmentation methods, etc., and Multi-spectral segmentation methods [6 ].Multi-spectral segmentation methods generally use pattern recognition approaches and they are by far successful. These methods can be further classified as supervised and unsupervised methods. The difference between supervised and unsupervised methods is important due to the need for reproducible measurements. Supervised methods require operator input for segmentation, this is done by selecting training pixels or training regions in the images. Unsupervised methods are automatic, in the sense that operator intervention might still be necessary for completion of segmentation, but the results are operator independent, [7].

Image Classification
It refers to the decomposition of an image into regions and then labeling them. These methods can be further classified as supervised and unsupervised methods .In the supervised classification, this is done by utilizing training data which are associated with anatomical tissues. Unsupervised classification method returns a segmented image with different "classes", defined priory by their intensity mean values, [8].In image segmentation, classification is used to label each image pixel which is described by a set of features; e.g. pixel's intensity, average intensity, or spatial relationships among pixel's neighborhood, [9].

Supervised Minimum Distance (MD) classification Algorithm
Supervised minimum distance (MD) classification algorithm is used to classify unknown image data to classes which reduce the distance between the image data and the class in multi-feature space. The distance is defined as an index to the similarity so that the distance is not less than identical to the maximum similarity. Figure-2 shows the concept of a supervised classification minimum distance classifier [10]. The Minimum Distance (MD) algorithm uses the mean vectors of each region of interest (ROI) and calculates the Euclidean distance from each unknown pixel to the mean vector for each class. It requires the user to provide the mean vectors for each class in each band from the training data .To perform a minimum distance classification, must calculate the distance to each mean vector, from each unknown pixel, [11]. It is possible to calculate this distance using based on the Pythagorean theorem or "around the block" distance measures as shown in Figure-2.The Euclidian distance from point "a" to the mean is given by [9] : ……………….(1) Figure 2-The concept of a minimum distance classifier [10].
In this paper we propose a supervised learning approach to finding a similarity measure, so that, the minimum distance (MD) algorithm provides the desired clustering for the task at hand. All pixels are classified to the closest ROI class unless the user specifies standard deviation or distance thresholds, in which some pixels may be unclassified if they do not meet the selected criteria [12].

Methodology
Presently, we describe the method which is proposed to detect the features of diabetic retinopathy. This framework can be divided into four stages. Figure-3 demonstrates all these stages of the framework. The suggested system includes: first, acquisition of sample retinal fundus image database and examination of these images for the application. Second, the pre-processing of the image to improve quality and reduce artifacts. Third, the simple step toward image interpretation and analysis is the segmentation process; it may be performed by utilizing certain image segmentation method (e.g. Adaptive Minimum Distance) and followed by feature extraction which is a crucial step toward recognizing the image segment parts.

Acquisition of Retinal Fundus Images
The first step is to acquire an original fundus images (FIs). In this paper, various samples of retinal images were used to estimate the effectiveness of the proposed method. In our approach, digital fundus color images were obtained from the fundus camera at a resolution of 1150 ×1234 with 256 grey levels for each of the red, green, and blue pixel elements. The samples of retinal images were obtained from the digital retinal camera from Ibn Al Haitham Teaching eye Hospital in Baghdad, Iraq.

Pre-processing stage (PPS)
The pre-processing phase involves sub-phases such as resizing, color space conversion, zero padding of image edges and histogram equalization. In our present research, we initially resized the acquired fundus images to a standard size of spatial resolution of 570 ×550 pixels with 256 grey levels for each band, while maintaining the original aspect ratio. The acquired fundus images were sometimes of low quality. Regular issues with (FI's) include presence of noise, low resolution and uneven illumination. Pre-processing of retinal image is one of the most important steps. The principle reason of pre-processing is to improve the contrast of retinal image.

a. Conversion of RGB to HSI
The input retinal fundus images can either be colored or grey images [4] .The original color image is converted to hue, saturation and intensity (HSI) color components. The intensity component I is the only one employed for further processing. The selection of HSI depends on the fact that the intensity component of the image can be separated from other components. In this research, the information needed for the diagnosis can be obtained from the intensity space. The HSI stands for the hue, saturation and ntensity, whereas in RGB, R stands for red, G represents the green and B is the blue. The hue and saturation components are intimately related to the way human eye perceives. The intensity represents of a color, which is decoupled from the color information in the represented image. The transformation equations for RGB to HSI color model conversion is given below [13].
The value represents intensity of a color, which is decoupled from the color information in the represented image. The transformation equations for RGB to HSV color model conversion is given below [13].
Where R is the red color, G is the green color and B is the blue color, while H is the hue, S is the saturation and I is the intensity. The illumination of the retina is often irregular, resulting in local brightness and contrast variance, leading to the condition that those lesions may be invisible in areas of low contrast and/or low brightness. Further, in the context of telemedicine, images are variable in terms of color and quality. Here we work with gray-scale images because exudates are mostly visible in such images. As a result, pre-processing steps are required to address these problems. Figure-4 shows the color space conversion from RGB to HIS.

Original Color Image
Hue band Saturation band Intensity band

b. Background Removing
Usually in some FIs, retina information is contained in a circularly shaped region surrounded by outer black region. The intensity of this black area is in the range of 0 to 32 gray level (On a scale of 0-255 gray level), which much of the time can be considered as noise. The quality of the image can be affected by the presence of such noise. In order remove outer black region from the fundus images it's important to create a mask which is a binary image (0 or 1's). This mask, which has the size of the retinal fundus images and its value and shape differ from one image to another, is applied on the original retinal images to discard the irrelevant information; multiplying the mask image with study image produced the masked image which is the extract retinal image. This mask is used to subtract the outer black region in the image [14]. Figure-5 shows a sample of the mask creation performed to crop outer black region. Figure-6 shows the histogram of images before and after cropping outer black region.

Intensity band
The Mask Extracted Image

Figure 6-Images and its histogram before and after Truncated outer black region.C. Histogram Equalization
There are many techniques employed for improving the contrast and color of the retinal image. Here we use Contrast Histogram Equalization (CHE), one of the most useful forms of nonlinear contrast enhancement. When an image histogram is equalized, the pixel values of the image are redistributed to have approximately an equal probability. Contrast enhancement is the most important part of pre-processing. By this we can improve the contrast of the image. This histogram equalization technique enhances contrast of an image by transforming its intensity value. It operates on small region instead of the whole image. Figure-7 shows the image before and after histogram equalization process.

Extracted foreground Image
Histogram equlization image Figure7-The image before and after histogram equalization process.

Adaptive Segmentation Stage
The adaptive (supervised-unsupervised) Minimum Distance (MD) segmentation algorithm was implemented in this research. Initially certain areas we've used selected, referred to as regions of interest "ROI's", from which statistical features are counted and saved for further processing. Using certain window size (i.e. 3×3 or 5×5), the input image then scanned top to bottom, the same statistical region black Outer features previously counted for the ROI should be computed for each window position. The window's features should then be compared with those of the ROIs; the window's center point is assigned a class number matching the nearest ROI features. Matching process is usually performed by implementing the Minimum distance (MD). The minimum distance (MD) was chosen to be 12 pixels due to the good results gained through our testing of distances less than or greater than this value during the work. In our present work, the Minimum Distance measure (MD) was preferred because of its simplicity and less computation time requirement. The shortcoming that was usually faced with the supervise segmentation was its operator's experience dependence, i.e. it is totally dependent on the correct choice of the positions of different region's. Misallocation leads to incorrect assessment of region's number to tissue's class. The features considered for differentiation between image regions are the mean, standard deviation, and minimum and maximum values.
To improve the resulted segmentation, an adaptation was proposed to refine the preliminary results by assigning each classified point to its nearest mean value. This was performed by computing the mean values of the preliminary classes and the pixel's value of the raw image. The preliminary and refining results of segmentation, using the mentioned algorithm, are illustrated in Figures-(8 -10), which is referred to as the proposed (supervised-unsupervised) segmentation technique. The closeness between the counted means obtained by the supervised operation with the image pixel values is performed using the minimum distance creation method. The operations involved in this segmentation process can be summarized in the following steps:

Results and Discussion
As explained above, the adopted (supervised-unsupervised) segmentation method requires defining priorly only numbers of classes, ROI, and window's size. The method was applied on a large number of funuds images. The segmentation method using minimum distance algorithm was implemented on fundus images (FIs) of various cases defects. Figure-11 represents the results of different segmented abnormal images obtained by 3×3 pixels window's size, and for varying number of classes.

Final Classification Stage
Exudate extract Figure 11-Show the results of exudate extract using preliminary and final classification stage

Conclusions
Eye diseases contribute mainly to blindness, and often can't be cured because patients who are diagnosed are too late with diseases. This paper presents a new automatic approach to detecting retinal abnormalities. To improve the result segmentation, have been suggested an adaptation method to refine the preliminary results by assigning each classified point to its nearest mean value. This has been done by computing the mean values of the preliminary classes and the pixel's value of the raw image. The adaptation method which is referred to the adaptive (supervised-unsupervised) Minimum Distance (MD) method showed good results in the detection of exudates. The closeness was performed between the calculated methods obtained by the supervised process and the pixel values of the image using the minimum distance. The developed algorithm helps in determining whether patients with possible retinopathy eye disease are threatened and need further study or not. We proposed a fast and robust method to extract exudates in color eye fundus image. Although computer analysis cannot replace the clinical diagnosis of ophthalmologist, but the system aims to help to early detect the diabetic retinopathy, identify fundus images with suspected lesions, and sort them by severity. The results can then be presented to the ophthalmologist for the purpose of reviewing and evaluating. Such an automated system can help ophthalmologists to reduce the examination time and increase diagnostic accuracy. Further, it can help to identify the most severe cases quickly and to focus clinical resources on cases that need more urgent and specific attention. Hence, The adaptation method t gave good results for exudates detection.