Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
33 views5 pages

Convolutional Neural Network For Diabetic Retinopathy Detection

Uploaded by

nilesh nagure
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
33 views5 pages

Convolutional Neural Network For Diabetic Retinopathy Detection

Uploaded by

nilesh nagure
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

Proceedings of the International Conference on Artificial Intelligence and Smart Systems (ICAIS-2021)

IEEE Xplore Part Number: CFP21OAB-ART; ISBN: 978-1-7281-9537-7

Convolutional Neural Network for Diabetic


Retinopathy Detection
2021 International Conference on Artificial Intelligence and Smart Systems (ICAIS) | 978-1-7281-9537-7/20/$31.00 ©2021 IEEE | DOI: 10.1109/ICAIS50930.2021.9395796

1st Shital N. Firke 2nd Ranjan Bala Jain


PG Student (Electronics and Telecommunication Professor (Electronics and Telecommunication
Engineering) Engineering)
Vivekanand Education Society’s Institute of Technology, Vivekanand Education Society’s Institute of Technology,
University of Mumbai, India. University of Mumbai, India.
[email protected] [email protected]

Abstract—The world's projected blind population will reach exudate nerve fiber sheet [4]. (fluffy) edges are included in the
40 million by 2025. A modern fundus-based algorithm that soft exudate nerve fiber sheet [4].
approves the classification of retinal tissue needs to be improved
in the early stages of healthy and diabetic retinopathy. In this Deep learning is an efficient instrument for predicting an
experiment, we have introduced a convolution neural network actionable outcome. Convolution Neural Network (CNN) is
approach to detecting diabetic retinopathy. We used the publicly mostly used for the grade of images [5]. CNN is commonly
accessible Apatos Blindness Detection database to train a used by many researchers in medical image scrutiny than
convolution neural network, where the image is processed at an other DL-based methods. The architecture of CNN contains
early stage, primarily involving image resizing, pixel rescaling, three popular layers: convolution, pooling, and fully connected
and label encoder. After that, an image is given to the convolution layer. This paper is divided as follows: In section II, some
neural network model, to decide whether the patient has diabetic literature survey is done. In section III, our approach,
retinopathy or not. About 3789 color retinal images are used in methodology, and flowcharts used for DR classification are
experiments to train the proposed model and about 948 images shown. The results of the experiments are shown in section IV.
are collected to test its efficiency in classification. Accuracy of Section V concluded the paper.
96.15\%, Sensitivity 79\%, Precision 89\%, and F1-Score 84.1\%
and Area Under Score 0.82 is achieved using the Convolution II. LITERATURE REVIEW
Neural Network-based method.
Many researchers have discussed the issue of highly accu-
Keywords—convolutional neural network, diabetic retinopathy, rate classification of images. Here are some citations relevant
deep Learning. to our paper.
Kele Xu et al., [6] has developed an approach to DR
I. INTRODUCTION detection using deep CNN. In this work, the authors used the
Diabetes is the biggest issue being suffered by the world publicly available data set Kaggle. Data augmentation Steps
today. According to a World Health Organization survey, the are used such as stretching, translation, flipping, And rotate
global incidence of diabetes was 2.8\% in 2000 and by 2030 to the labeled dataset. CNN’s architecture is then used for
current statistics will rise by 4.4\% [1]. The direct adverse automatic DR classification and achieves 94.5\% accuracy.
effect of a retina blood vessel (BV) is diabetic retinopathy
(DR). Gloomy strings in sight, fuzzy sight, irregular sight, Vishakha Chandore et al., [7] have evolved a method for
vitiated sight, vacant areas in sight, and difficulty seeing at automatic disclosure of DR using deep CNN. A large dataset
night are perfect symptoms of DR [2]. of around 35000 images is used. In this work, images are
resized into dimensions of 448x448. They also applied various
Five types of DR are available: Mild, Moderate, Severe, data augmentation steps. and Finally, the authors achieved a
Proliferative, and No DR. Mild nonproliferative Like a bal- precision for class 0 is 81\% and for class 1 88\%.
loon, the small area of BV in the retina can swell. Moderate
nonproliferative certain of the BV in the retina will be Using the Kaggle dataset, Mohammadian et al., [8]
blocked. The severe nonproliferative growing number of BV proposed a framework for categorising DR into two classes:
nourishing the eye has become blocked. Proliferative is the DR and No DR. The authors used a dataset of 35,126 images,
ultimate stage of DR. This is when fresh BV begins to evolve of which 20\% images used to test the algorithm's output
in the retina. This is called neovascularization [3]. There are against unseen data. The authors tweaked the final two blocks
various lesions of DR: The most initial clinically noticeable of the two architectures and contrasted two optimizers with
DR changes are microaneurysms. Hemorrhages occur when different LRs: stochastic gradient descent and Adam. To
weak capillary walls break down. Hard exudates are white increase the system's accuracy, the authors augmented the
yellow deposits ranging from small to large patches that images by flipping them horizontally and vertically or rotating
evolve into circular rings. Greenish-white discoloration and moving them. The accuracy of 87.12\% for the
patches with indistinct (fluffy) edges are included in the soft

978-1-7281-9537-7/21/$31.00 ©2021 IEEE 549

Authorized licensed use limited to: California State University Fresno. Downloaded on July 01,2021 at 15:43:33 UTC from IEEE Xplore. Restrictions apply.
Proceedings of the International Conference on Artificial Intelligence and Smart Systems (ICAIS-2021)
IEEE Xplore Part Number: CFP21OAB-ART; ISBN: 978-1-7281-9537-7

InceptionV3 architecture and 74.49\% for Xception is 2. Pixel Rescaling: Pixel values are rescaled into 0 and
achieved. 1 for each image by dividing by 255 for ease of
Dinial Qomariah et al., [9] have suggested a method for computation. It enhances the efficiency of the
the classification of DR and healthy retinal images using activation function. The Sigmoid function performs
CNN and SVM. They used the publicly accessible Messidor better with data between 0 and 1.
database. Here features are obtained using transfer learning 3. Label Encoder: The method of translating a label into
and accuracy of 95.83\% for base 12 and for inception v3 and a numeric format so that it can be translated to a
VGG19 95.24\% for base 13 is achieved. machine-readable format is label encoding.
Harry Pratt et al., [10] have developed a model for C. Dataset Splitting
diagnosis of DR using CNN. Here images are rescaled into Here the dataset is divided into two parts 80\% data used
512x512 pixels. Here the Kaggle dataset is used. In this for training and 20\% data used for testing. The training set
research, the CNN architecture can be built to define the contains 3,789 samples, while the validation set contains 948
dynamic characteristics involved. in the task of classification. samples, 365 of which are stable and 583 of which are
They achieved a Recall of 95\% and 75\% of accuracy. diabetic. We ensure that the images chosen for the test are not
Nidhi Kamothi., [11] have suggested a method for used during training in order to perform successfully the
Automatic Diagnosis of DR using Transfer Learning. Image binary classification task.
preprocessing steps are used such as image enhancement and
converted in the desired format. After that various CNN D. Data Augmentation
architectures are used like CNN, VGG16, and VGG19. They It is used to resolve both the criteria, the variety of training
reported the accuracy of the model based on the VGG16 is data, and the volume of data. In comparison to these two, the
71.6\%. augmented data is also used to resolve the problem of class
III. PROPOSED METHODOLOGY disparity in the classification tasks [12]. After dataset
preprocessing and splitting, a data augmentation strategy is
Different steps involved in methodology are given below: used for the process of training. In addition, the methods we
● Get the Dataset. used include data cropping, data shifting, rotation, padding,
● Data Preprocessing. flipping, etc. Data augmentation is shown in Table I.
● The dataset is divided into two parts: training and
testing. TABLE I.
● Data augmentation technique used.
● Use CNN algorithm for training the model. DATA AUGMENTATION USED
● Get the evaluation matrices.
● Get predictions. Argument Parameter
● Make a classification table. Value
A. Dataset
Zoom Range 0.2
We have obtained the dataset from the Blindness
Identification 2019 Asia Pacific Tele Ophthalmology Society Width Shift Range 0.2
(APTOS 2019 BD) [14]. APTOS has produced a
comprehensive collection of retina photography fundus Rotation Range 50
photographs that have been taken under a wide range of
imaging conditions. The data was complex and Horizontal Flip True
comprehensive. The clinician graded each picture on a scale of
0 to 4 for the seriousness of diabetic retinopathy. We have split Fill Mode Nearest
a dataset into two classes (class 0 and class 1). In 0 class NO
DR images and in 1 class combined Mild, Moderate, Severe
NPDR and PDR images as DR Images. E. Classifier
Fig. 2. Represents essentially the complete architecture of
the CNN model is simply divided into several layers such as
B. Preprocessing convolution, pooling, and fully connected layers.
As the dataset contains image data, it is first pre-processed
by using various steps such as resizing, pixel rescaling, and
label encoder.
1. Resizing: Images are resized to a pixel of 64x64. Fig.
1 shows Image Resizing.

Fig. 2. CNN Architecture

Fig 1. Image Resizing

978-1-7281-9537-7/21/$31.00 ©2021 IEEE 550

Authorized licensed use limited to: California State University Fresno. Downloaded on July 01,2021 at 15:43:33 UTC from IEEE Xplore. Restrictions apply.
Proceedings of the International Conference on Artificial Intelligence and Smart Systems (ICAIS-2021)
IEEE Xplore Part Number: CFP21OAB-ART; ISBN: 978-1-7281-9537-7

1. Convolutional Layer: It is the first layer, and this RMSprop and a different rate of learning is chosen for each
layer performs Heavy computing, which makes it parameter. The learning speed was separated by RMS prop
easier for extra work. This layer functions as an input through the average square gradient exponential decay. The
layer, with the image's input size set to 64x64x3. batch size here is set to 128 and the epoch is set to 50.
2. Max pooling Layer: The highest weighted function is
separated in the Max-pooling layer, which is F. Performance Measures
accomplished by transforming the preceding 3x3 1. Confusion Matrix: To get the idea about
matrix into a more compact matrix. The above 3x3 classification and misclassifications. The confusion
matrix is then transformed into a 2x2 matrix that only matrix is the m x m matrix [15]. Let, m is the no. of
includes the 3x3 matrix's highest weighted function. variables involved. Diagonal elements represent the
3. Flatten Layer: The flattened layer reduces the image true values and false values are expressed by
matrix to a single dimension, which serves as the non-diagonal elements. There are four parameters
dense layer inputs. inside the figure such as, False Positive (FP), True
4. Dropout Layer: The dropout layer performs a higher Negative (TN), True Positive (TP), and False
and efficient operation that significantly enhances the Negative (FN). Fig. 4. demonstrates a confusion
network's normalization capabilities. This method matrix.
uses random removal and potentially restores neurons
during training with a probability determined by a
hyperparameter called dropout rate.
5. Dense Layer: These layers serve as the final elements
of a deep neural classifier, and they are fed by the
attributes removed by the preceding convolutional
layers.
6. Output Layer: Is the final layer of the network that
generates the network's output, whether it's a Softmax
layer or a sigmoid neuron, depending on whether the
role is binary or multiclass classification.
Fig. 3. shows the Flowchart for designing an algorithm.
After designing the algorithms, we have done classification
based on four parameters: precision, accuracy, recall, and
Fl-score.

Fig. 4. Confusion Matrix

2. Accuracy: Accuracy is determined as a ratio of the


events properly classified to the total events.

ԵԱࡒԵԯ
ԢԾԾՐՍԼԾՔ ࡙  ԵԱࡒԵԯࡒԧԱࡒԧԯ
(1)

3. Sensitivity or Recall: Sensitivity measures the degree


of positively classified positive events.

ԵԱ
Sensitivity = ԵԱࡒԧԯ
(2)

4. Precision: Precision is determined as the ratio of the


number of Positive samples correctly identified to the
total number of Positive samples either correctly or
incorrectly.

ԵԱ
Precision = ԵԱࡒԧԱ
(3)
Fig. 3. Flowchart of Model
5. F1-Score: F1-score is the arithmetic average of recall
In the process of deep learning, optimizers play a key role.
and accuracy.
The optimizer for Root Mean Squared Propagation (RMS
prop) is used here. The rate of learning is set automatically in ԱՍՀԾՄՎՄՊՉŶԳՀԾԼՇՇ
F1-Score = 2* ԱՍՀԾՄՎՄՊՉࡒԳՀԾԼՇՇ (4)

978-1-7281-9537-7/21/$31.00 ©2021 IEEE 551

Authorized licensed use limited to: California State University Fresno. Downloaded on July 01,2021 at 15:43:33 UTC from IEEE Xplore. Restrictions apply.
Proceedings of the International Conference on Artificial Intelligence and Smart Systems (ICAIS-2021)
IEEE Xplore Part Number: CFP21OAB-ART; ISBN: 978-1-7281-9537-7

correctly in the normal class, but 55 were labelled as DR.


IV. RESULTS Likewise, for the second image class (DR), the model was
able to identify 463 images correctly, but 120 images were
Results of the binary classification of CNN Architecture labelled as Normal.
DR images provided in this section. Furthermore, the quality TABLE IV
and functionality of the model should be checked. Its
RESULTS OF CONFUSION MATRIX
outcomes are presented in Fig. 6-7. Using validation and
training curves of accuracy and loss. Other results are
tabulated below Table II-IV. Predicted Value
The performance evaluation reports are obtained as shown
in Table II. Class 0 Class 1
TABLE II
Actual 310 55
PERFORMANCE EVALUATION REPORTS Value
120 463
Stages Precision Recall F1-Score
Fig. 5. depicts the history of training and validation
Class 0 0.72 0.85 0.78 accuracy. Training accuracy from 80\% to about 94\% is
improved up to 30 epochs, and after 30 epochs the accuracy is
Class 1 0.89 0.79 0.84 almost constant at around 96\%. After there are slight spikes in
the graph from 75\% to 85\%, the validation accuracy
Table III shows comparison results. Kele Xu et al.,[5] used improves significantly before 20 epochs. Accuracy is simply a
8 convolutions, 3 pooling, and 2 fully connected layers. 3 metric that can only be applied to the task of classification.
convolutions, 3 pools, and 2 fully connected layers were used The exact classification of the proportion of your test data is
in the proposed model, which would reduce the model's defined. Model accuracy is normally chosen after examining
complexity. We trained the model on more datasets in this and determining the model parameters and no learning takes
experiment to further increase the model's accuracy. We may place. The test samples are then given to the model, and the
adjust parameters such as epochs to optimize the output of the model's number of errors is reported after the actual targets are
CNN model, the number of epochs decidingly affect compared.
efficiency. For a significant no. of epochs, there is an
improvement in performance. Some experimentation is needed
to determine the epochs. After a few epochs, there has been no
decrease in training loss and an increase in training accuracy.
Accordingly, a number of epochs can be determined.

TABLE III

COMPARISON OF RESULTS

Kele Xu et al. [5] Proposed Model

Size of 1000 4,737


training data Images Images

Optimizer Adam RMSprop


Fig. 5. Training and Validation Accuracy History
Data Yes Yes
Augmentation Fig. 6. depicts the history of training and validation loss.
Used The model has comparative functionality in both the train and
the validation dataset from the plot of loss. The training loss is
Accuracy 94.5% 96.15% decreasing exponential graph. It is almost constant after 30
epochs around 0.10 which is very less. Similarly, the
Loss Not Specified 0.0839 validation loss is a spike having a maximum loss at the 4th
epoch and the minimum loss is from epoch 10 to 16 and at
epoch 44. The lower the loss, the stronger the model. The loss
In Table IV Confusion matrix is shown the classification is measured on validation and training and here are two
reports of the test datasets. It is observed that in the first image explanations of how it is given. The loss, unlike precision, is
class (Normal), the model was able to identify 310 images

978-1-7281-9537-7/21/$31.00 ©2021 IEEE 552

Authorized licensed use limited to: California State University Fresno. Downloaded on July 01,2021 at 15:43:33 UTC from IEEE Xplore. Restrictions apply.
Proceedings of the International Conference on Artificial Intelligence and Smart Systems (ICAIS-2021)
IEEE Xplore Part Number: CFP21OAB-ART; ISBN: 978-1-7281-9537-7

not a percentage. This is an addition to the errors prepared in modifying distinct parameters such as the number of
each instance of the training or validation set. convolution and pooling layer optimizer to achieve better
efficiency. No manual feature removal steps are required in
our model. Our network architecture has achieved adequate
classification accuracy with dropout methods. True positive
rate (or recall) is also improved. The future scope of this
includes the model will be improved and trained on more
datasets to be capable of identifying more diseases to help the
physician in the clinic and hospitals.
REFERENCES
[1] Sarah Wild et al., “Global prevalence of diabetes estimates for the year
2000 and projections for 2030,” Diabetes care, vol. 27, no. 5, 2004; pp.
1047–1053.
[2] Navoneel Chakraborty, “A Deep Learning Method for the Detection of
Fig. 6. Training and Validation Loss History Diabetic Retinopathy” 5th IEEE Uttar Pradesh Section International
Conference on Electrical, Electronics and Computer Engineering,
(2018).
Receiver Operating Characteristic (ROC) as shown in Fig.
7. The ROC curve is most effective at the early stage of the [3] Ankita Gupta et al., “Diabetic Retinopathy: Present and Past”
International Conference on Computational Intelligence and Data
assessment of the new diagnostic test. The ROC curve is Science, pp. 1432-1440, 2018.
drawn between True Positive Rate (TPR) and False Positive [4] Biyani, R. S., and B. M. Patre. “Algorithms for red lesion detection in
Rate (FPR). TPR means Sensitivity and FPR mean Diabetic Retinopathy: A review.” Biomedicine & Pharmacotherapy, pp.
1-Specificity. The AUC is an important way of summarizing 681-688, 2018.
the improved detection accuracy of the test [13]. It takes [5] Nikhil M N et al., “Diabetic Retinopathy Stage Classification using
values from 0 to 1, where the value of 0 implies a perfectly CNN” International Research Journal of Engineering and Technology,
incorrect test and the value of 1 represents a perfectly accurate pp 5969-5974, 2019.
test. The AUC can be measured using the trapezoidal rule 3. [6] Kele Xu et al., “Deep Convolutional Neural Network Based Early
Automated Detection of Diabetic Retinopathy using Fundus Image”,
Overall, the AUC of 0.5 implies no prejudice, 0.7 to 0.8 is Molecules, vol.22, no.12, pp.1-7, 2017.
considered appropriate, 0.8 to 0.9 is considered exceptional, [7] Vishakha chandore et al., “Automatic Detection of Diabetic Retinopathy
and higher than 0.9 is considered to be outstanding. using deep Convolutional Neural Network”, International Journal of
Advance Research, Ideas and Innovations in Technology, pp.633-641,
2017.
[8] Mohammadian et al., “Comparative Study of Fine-Tuning of
Pre-Trained Convolutional Neural Networks for Diabetic Retinopathy
Screening” 24th national and 2nd International Iranian Conference on
Biomedical Engineering (ICBME), Amirkabir University of Technology,
Tehran, Iran, 2017.
[9] Dinial Qomariah et al., “Classification ofDiabetic Retinopathy and
Normal Retinal Images using CNN and SVM” 12th International
Conference on Information & Communication Technology and System
(lCTS),pp. 152-157, 2019.
[10] Harry Pratt et al., “Convolutional Neural Networks for Diabetic
Retinopathy” International Conference On Medical Imaging
Understanding and Analysis, pp. 1-6, 2016.
[11] Nidhi Kamothi “Automatic Diagnosis of Diabetic Retinopathy using
Transfer Learning Approach” International Research Journal of
Fig. 7. Receiver Operating Characteristic Engineering and Technology, pp. 3810-3814, 2020.
[12] Connor Shorten eta al., “A survey on Image Data Augmentation for
V. CONCLUSION Deep Learning” J Big Data 6, 60 (2019).
[13] Jayawant N.Mandrekar “Receiver Operating Characteristic Curve in
Most people suffer from diabetes, which is a main cause Diagnostic Test Assessment” Journal of Thoracic Oncology pp.
1315-1316, 2010.
of DR. It is a dominant cause of blindness and, with proper
[14] Aptos Blindness Detection Dataset. Available online at
treatment, its symptoms may be minimized. Therefore, a “https://www.kaggle.com/c/aptos2019-blindness-detection/data”.
model must be developed that can detect DR without any Accessed on: 02-03-2020.
expert guidance. Deep learning algorithm is a CNN that works [15] Confusion Matrix for Machine Learning. Available online at
effectively and accurately for the classification of images. In “https://www.analyticsvidhya.com/blog/2020/04/confusion-matrix
this experiment, we have compared the performance accuracy machine learning”. Accessed on: 03-03-2020
of an existing model. We have implemented the algorithm by

978-1-7281-9537-7/21/$31.00 ©2021 IEEE 553

Authorized licensed use limited to: California State University Fresno. Downloaded on July 01,2021 at 15:43:33 UTC from IEEE Xplore. Restrictions apply.

You might also like