Detecting Exudates in Color Fundus Images for Diabetic Retinopathy Detection Using Deep Learning
P Saranya1, K M Umamaheswari*1
1Department of Computer Science and Engineering, SRM Institute of Science and Technology,
Kattankulathur, Chennai, Tamilnadu, India.
Mail: [email protected]
From a medical point of view, diabetes is believed to be the foundation of several other health problems and late complications. The increase in diabetes-related disorders has posed a challenge to the healthcare sector. Diabetes can cause a variety of issues such as diabetic neuropathy, diabetic nephropathy and diabetic retinopathy. The most common complication due to diabetes is Diabetic Retinopathy (DR). The signs of Diabetic Retinopathy include red lesions, bright lesions and neovascularization. Bright lesions are second clinically observable lesions which occurs after red lesions. It includes cotton wool spots and hard exudates (soft and hard exudates). It occurs during the severe stage of the DR disease and leads to severe vision loss if not treated properly.
The proposed work's primary objective is to use deep learning architecture to construct an automated model for detecting bright lesions for non-proliferative stage diabetic retinopathy screening. Several pre-processing stages are followed by removing the background of the images, optic disc (OD) elimination and candidate lesion segmentation are done. The model was trained and tested using MESSIDOR datasets and achieved the maximum accuracy, sensitivity and specificity of 97.54%, 90.34% and 98.24% respectively.
Diabetic retinopathy: exudates: Convolutional neural networks: bright lesions Introduction
Diabetic Retinopathy (DR) is a diabetic disorder in which the blood vessels in the retina dilate and leak fluid and blood. The presence of several types of lesions on a retinal fundus image indicates DR. These lesions include microaneurysms, haemorrhages, and soft and hard exudates . Microaneurysms, which appear as minute red circular spots on the retina owing to a weakening in the vessel's lining, are the first indicator of DR. There are sharp borders and the size 10 μm and 125 μm. Haemorrhages (HM) appear as blood stains on the retina caused by blood leaking across the retina in irregular sizes and forms. Small white or yellowish white deposits with sharp borders are known as hard exudates. It is caused by lipid and protein outflow as a result of vascular rupture. Cotton wool spots are small white regions on the retina, the light- sensitive layer that lines the back of the eye. A shortage of blood flow to the tiny retinal blood vessels causes it.
Automated DR detection methods saves time and money, and are more effective than manual diagnosis . The proposed work concentrates on detecting bright lesions in the retina to predict the diabetic retinopathy disease. Bright lesions include hard and soft exudates which are also
known as hard exudates and cotton wool spots. It occurs during the severe stage of the DR disease. Ophthalmologists use fundus photographs to manually detect exudates in regular medical practice. This technique of detection, on the other hand, is time-consuming and subject to human mistake in a repetitive operation. Furthermore, conducting fundus examinations at local hospitals is difficult due to a high demand for expert skills and expensive equipment. As a result, automated HE identification is critical for prompt treatment due to the limited and perhaps diminishing number of specialists .
K. Wisaeng and W. Sa-Ngiamvibool  proposed the model for detecting exudates using mean shift algorithm and mathematical morphology algorithm. The classification of exudates is performed using the morphology algorithm and obtained the maximum accuracy, specificity and sensitivity of 98.35%, 98.13% and 98.40% respectively. The datasets used for training the model was small. W. Zhou et al.  introduced the exudates detection method using super pixel multifeatured classification. Several pre-processing steps, candidate extraction and feature extraction methods are adopted and for the classification Fisher Discriminant analysis classifier is used. The model is tested using DIARETDB1 and e-ophtha EX public datasets and achieved the maximum AUC score of 0.970 and 0.9655 respectively. The model finds difficult to detect the exudates in the retinal image when the lesions are in smaller size.
Franklin, S.W. and Rajan, S.E.  developed the exudates detection model by employing image processing steps for extracting the features and neural network is adopted for performing the classification task. The model is tested using DIARETDB1 dataset and achieved the accuracy of 99.7%. The proposed model concentrated only on detecting exudates and detecting other features such as red lesions and abnormal blood vessels are not considered. X. Guo et al.  developed a multi-feature fusion network for exudates detection in the retinal fundus images. Fusion network is constructed based on convolutional neural networks which fuses the multiple input features.
The model was evaluated using MESSIDOR, HEI-MED and e-ophtha EX public datasets and achieved the better performance.
The objective of the proposed model is to identify the exudates from retinal fundus images using convolutional neural networks (CNN). Several pre-processing steps are adopted to remove the impurities from the retinal images and feature extraction and candidate segmentation methods are developed using mathematical morphology. An attempt has been made in the proposed work to develop an automated model for detecting exudates for diabetic retinopathy detection which helps the ophthalmologists to diagnose the disease in a short span of time.
The proposed model starts with pre-processing steps such as resizing the images, green channel extraction, contrast enhancement and denoising the images. Then the foreground of the images is generated by removing background of the images followed by optic disc segmentation and blood vessel extraction are performed. After performing the candidate lesion segmentation, neural network was used to classify the exudates among the lesions. The architecture diagram for exudates detection is shown in the figure 1.
Figure 1. Architecture diagram
There are several procedures followed for preforming the pre-processing steps to remove the impurities from the images such as noise, uneven illumination and size etc. Initially all the input retinal images resized to 512x512 pixels and then the green channel of the images are extracted.
Then the contrast enhancement of the images is done using CLAHE technique and denoising is done using the gaussian filter. At the end of the denoising step the smoothened image will be generated Ismooth. The original and smoothened image is demonstrated in figure 2.
Figure 2. (a) Original image, (b) Smoothened image Ismooth
Removing background of the image and optic disc elimination
To generate the foreground of the image, the background of the image must be eliminated. The background of the image Ibg is generated by applying the mean filter of size 51x51 to the smoothened image Ismooth. Once the background image Ibg was generated, the Ibg was subtracted from the smoothened image and average intensity of the smoothened image was added with the resultant image to keep the grey scale range same as in the Ismooth.
The foreground of the image was obtained using the formula:
The optic disc was eliminated by applying the sliding window operation of size 80x80 to the smoothened image and looking for the average white pixel threshold of 0.35. when the high pixel is found, the 80x80 window is ignored by marking all the pixels in black color. The sample images after performing each step are shown in the figure 3.
Figure 3. (a) Background image Ibg, (b) Foreground image Ifg, (c) image after eliminating optic disc
Blood vessel extraction and candidate lesion segmentation
Blood vessel extraction is done by removing all the on-blood vessels object. At first, contouring operation is performed with the threshold of area<200 followed by morphological operations are performed with the kernel size of 3x3. Following the pre-processing, background removal of the image, optic disc elimination and, candidate lesion segmentation is done by removing the blood vessels IBV from the smoothened image Ismooth. The candidate lesion segmented image is shown in the figure 4.
The candidate lesion segmentation is done using the formula:
Icand= Ifg - IBV
Figure 4. Candidate lesion segmented image Icand
After the lesions were segmented, the resultant images were used as the input for the classification model. For the classification convolutional neural networks (CNN) are proposed to detect the exudates among the lesions. Here two classes are considered such as class 0 and class 1. Class 0 implies that there are no exudates in the retinal pictures, whereas class 1 shows that exudates are present. Figure 5 depicts the CNN model that has been proposed.
Figure 5. Proposed CNN model
The input lesion segmented images with the size of 512x512 was considered. Three convolutional layers are used in the model and each followed by the max pooling operation of kernel size 2x2. With 100 filters of 3x3 kernel size and a stride value of 4, the first convolutional layer was implemented. With 200 filters of 3x3 kernel size and a stride value of 4, the second convolutional layer was added. The third convolutional layer was added with 250 filters with the stride value of 1. The ReLu activation function has been defined in each of the convolutional layer. Finally flatten and three dense layers are used and at the output dense layer sigmoid activation function was used to generate the encoded outputs. Binary cross entropy loss function was used to estimate the loss value of the model. The learning rate of 0.001 was used and the number of epochs used was 100.
Results and discussions
MESSIDOR public dataset was used to train and test the model. The dataset consists of 1200 images in which 900 images were used for training and 300 images were used for testing. The performance was measured by evaluation metrics such as accuracy, specificity and sensitivity.
The formula for calculating each metric is given below.
𝐴𝑐𝑐𝑢𝑟𝑎𝑐𝑦 = 𝑇𝑟𝑢𝑒 𝑃𝑜𝑠 + 𝑇𝑟𝑢𝑒 𝑁𝑒𝑔
𝑇𝑟𝑢𝑒 𝑃𝑜𝑠 + 𝑇𝑟𝑢𝑒 𝑁𝑒𝑔 + 𝐹𝑎𝑙𝑠𝑒 𝑃𝑜𝑠 + 𝐹𝑎𝑙𝑠𝑒 𝑁𝑒𝑔 𝑆𝑒𝑛𝑠𝑖𝑡𝑖𝑣𝑖𝑡𝑦 = 𝑇𝑟𝑢𝑒 𝑃𝑜𝑠
𝑇𝑟𝑢𝑒 𝑃𝑜𝑠 + 𝐹𝑎𝑙𝑠𝑒 𝑁𝑒𝑔
𝑆𝑝𝑒𝑐𝑖𝑓𝑖𝑐𝑖𝑡𝑦 = 𝑇𝑟𝑢𝑒 𝑁𝑒𝑔 𝑇𝑟𝑢𝑒 𝑁𝑒𝑔 + 𝐹𝑎𝑙𝑠𝑒 𝑃𝑜𝑠
Table 1. Performance evaluation of the proposed model
Dataset used Accuracy Specificity Sensitivity
MESSIDOR 97.54% 90.34% 98.24%
Table 1 shows the performance evaluation of the proposed model. The maximum accuracy, specificity and sensitivity obtained was 97.54%, 90.34% and 98.24% respectively. The performance graph between the training and testing accuracy is shown in the figure 6.
Figure 6. Training accuracy vs testing accuracy
Table 2. Performance comparison with the existing models
Accuracy Specificity Sensitivity
 84.1% - 85.8%
 91.6% 94.7% 79.5%
 93% - -
97.54% 98.9% 90.34%
The performance comparison of the proposed model with few of the existing models are shown in table 2. It clearly demonstrates that the proposed model has obtained the best score than the existing models specified. The work contributes towards assisting the clinical specialists to efficiently detect the diabetic retinopathy in short span of time. The proposed work detects exudates from the candidate segmented lesions effectively with greater accuracy.
Many false detections occur because it is difficult to distinguish tiny, dull exudates from the retinal images, and also the various shape and form of OD. To overcome this challenge, a new pre-processing and feature extraction steps are developed which performs not only the normalization and also removes the unwanted features from the images and also eliminates the optic disc. The maximum accuracy of 97.54% was obtained which is better than the existing models specified. Future work focusing on enhancing the sensitivity of the model to make the model performs better on detecting true positives.
 Wejdan L. Alyoubi, Wafaa M. Shalash, Maysoon F. Abulkhair. (2020). Diabetic retinopathy detection through deep learning techniques: A review.Informatics in Medicine Unlocked, 20.
 G.S. Scotland, et al. (2010). Costs and consequences of automated algorithms versus manual grading for the detection of referable diabetic retinopathy. Br J Ophthalmol, 94 (6), 712-719
 Hui Wang, Guohui Yuan, Xuegong Zhao, Lingbing Peng, Zhuoran Wang, Yanmin He, Chao Qu, Zhenming Peng. (2020). Hard exudate detection based on deep model learned information and multi-feature joint representation for diabetic retinopathy screening.
Computer Methods and Programs in Biomedicine, 191, 105398.
 K. Wisaeng and W. Sa-Ngiamvibool. (2019). Exudates Detection Using Morphology Mean Shift Algorithm in Retinal Images. IEEE Access, 7, 1946-11958.
 W. Zhou, C. Wu, Y. Yi and W. Du. (2017). Automatic Detection of Exudates in Digital Color Fundus Images Using Superpixel Multi-Feature Classification. IEEE Access, 5, 17077-17088.
 Franklin, S.W. and Rajan, S.E. (2014). Diagnosis of diabetic retinopathy by employing image processing technique to detect exudates in retinal images. IET Image Processing, 8, 601-609.
 X. Guo, X. Lu, Q. Liu and X. Che. (2019). EMFN: Enhanced Multi-Feature Fusion Network for Hard Exudate Detection in Fundus Images. IEEE Access, 7, 176912-176920.
 Bannigidad P., Deshpande A. (2019). Exudates Detection from Digital Fundus Images Using GLCM Features with Decision Tree Classifier. In: Santosh K., Hegadi R. (eds) Recent Trends in Image Processing and Pattern Recognition. RTIP2R 2018.
Communications in Computer and Information Science, 1036.
 FarrikhAlzami et al. (2020). Exudates Detection for Multiclass Diabetic Retinopathy Grade Detection using Ensemble. Technology Reports of Kansai University, 62(3).
A biographical note on the authors
P Saranyais currently an Assistant professor in the Department of Computer Science and Engineering at SRM Institute of Science and Technology. Her research interest includes big data, image processing, medicalimage analysis, machine learning, and deep learning.
Dr. K.M. Uma Maheswari, a Ph.D. in Computer Science and Engineering. Working as an Assistant Professor, Department of Computer Science and Engineering, SRM Institute of Science and Technology has been serving the Education Profession for the past 15+ years. Earlier she was working for PonnaiyahRamajeyam College, Thanjavur, for about 4 years. Her area of interest is cloud scheduling, network resources allocation and optimization.