• No results found

Computer-Vision Based Retinal Image Analysis for Diagnosis and Treatment

N/A
N/A
Protected

Academic year: 2021

Share "Computer-Vision Based Retinal Image Analysis for Diagnosis and Treatment"

Copied!
36
0
0

Loading.... (view fulltext now)

Full text

(1)

Master of Science in Computer Science June 2017

Computer-Vision Based Retinal Image

Analysis for Diagnosis and Treatment

Vaishnavi Annavarjula

Faculty of Computing

Blekinge Institute of Technology SE–371 79 Karlskrona, Sweden

(2)

This thesis is submitted to the Faculty of Computing at Blekinge Institute of Technology in partial fulfillment of the requirements for the degree of Master of Science in Computer Science. The thesis is equivalent to 20 weeks of full time studies.

Contact Information: Author: Vaishnavi Annavarjula E-mail: vaan15@student.bth.se University advisor: Dr. Abbas Cheddad

Department of Computer Science

Faculty of Computing Internet : www.bth.se Blekinge Institute of Technology Phone : +46 455 38 50 00 SE–371 79 Karlskrona, Sweden Fax : +46 455 38 50 57

(3)

Abstract

Context. Vision is one of the five elementary physiologial senses. Vision is enabled via the eye, a very delicate sense organ which is highly susceptible to damage which results in loss of vision. The damage comes in the form of injuries or diseases such as diabetic retinopathy and glaucoma. While it is not possible to predict accidents, predicting the onset of disease in the earliest stages is highly attainable. Owing to the leaps in imaging technol-ogy,it is also possible to provide near instant diagnosis by utilizing computer vision and image processing capabilities.

Objectives. In this thesis, an algorithm is proposed and implemented to classify images of the retina into healthy or two classes of unhealthy images, i.e, diabetic retinopathy, and glaucoma thus aiding diagnosis. Additionally the algorithm is studied to investigate which image transformation is more feasible in implementation within the scope of this algorithm and which re-gion of retina helps in accurate diagnosis.

Methods. An experiment has been designed to facilitate the development of the algorithm. The algorithm is developed in such a way that it can ac-cept all the values of a dataset concurrently and perform both the domain transforms independent of each other.

Results. It is found that blood vessels help best in predicting disease asso-ciations, with the classifier giving an accuracy of 0.93 and a Cohen’s kappa score of 0.90. Frequency transformed images also presented a accuracy in prediction with 0.93 on blood vessel images and 0.87 on optic disk images. Conclusions.It is concluded that blood vessels from the fundus images af-ter frequency transformation gives the highest accuracy for the algorithm developed when the algorithm is using a bag of visual words and an image category classifier model.

Keywords:Image Processing, Machine Learning, Medical Imaging

(4)

This thesis is dedicated to Ms.R.Mahalakshmi, and Ms.Lalitha Subramaniam. I would like to take this opportunity to thank my supervisor Dr.Abbas Cheddad for his valuable time and guidance. Dr.Martin Boldt for working tirelessly to ensure the smooth functioning of the thesis process, and the IT department for the resources.

I would also like to extend my gratitude to my parents, R.Hymavathi and A.Rajashekar for everything I have, my brother, Kashyap for being there to make me laugh, my friend Aparna for proof-reading everything, and all the others who supported me at this time.

(5)

Contents

Abstract i 1 Introduction 1 1.1 Problem Background . . . 2 1.2 Problem Statement . . . 3 1.3 Objectives . . . 3 1.4 Research Questions . . . 4 2 Background 5 2.1 Computer Vision . . . 5 2.2 Medical Imaging . . . 5 2.3 Image Processing . . . 6 2.3.1 Image Enhancement . . . 6 2.3.2 Image Transformation . . . 6 2.3.3 Segmentation of Images . . . 7 2.3.4 Feature Selection . . . 8

2.4 Analyzing the Results . . . 8

2.4.1 Confusion Matrix . . . 8

2.4.2 Inferences from the Confusion Matrix . . . 9

3 Related Work 10 3.1 Advances in retinal image processing . . . 10

3.1.1 A Brief History . . . 10

3.1.2 Contemporary Research . . . 10

3.2 Formulating Research gap . . . 11

4 Method 13 4.1 Dependent and Independent Variables . . . 13

4.2 Choosing the Dataset . . . 13

4.3 Motivation of Choices . . . 13

4.3.1 Preprocessing Stage . . . 13

4.3.2 Classification . . . 14

4.4 Development of Algorithm . . . 16

4.5 Approach to Obtaining Results for RQs . . . 17 iii

(6)

5 Results 18

5.1 Result of Phase 1 . . . 18

5.2 Results from Phase 2 . . . 19

5.2.1 Results on Blood Vessel Datasets . . . 20

5.2.2 Results on Optic Disk Datasets . . . 20

6 Analysis and Discussion 21 6.1 Analysis . . . 21 6.2 Comparison of Results . . . 21 6.3 Validity Threats . . . 22 6.3.1 Internal Threats . . . 22 6.3.2 External Threats . . . 22 6.4 Further Discussions . . . 22

7 Conclusions and Future Work 23 7.1 Conclusion . . . 23

7.1.1 Answering RQs . . . 23

7.2 Future Work . . . 24

References 25

(7)

List of Figures

1.1 Human eye cross section[1] . . . 1 1.2 A comparision of the retina at various stages of health [2][3] . . . 2 4.1 Color Channels[4] . . . 15 5.1 Original Image[4] . . . 18 5.2 Sample Images from Output Datasets . . . 19

(8)

List of Tables

5.1 Confusion Matrix BVf . . . 20

5.2 Confusion Matrix BVs . . . 20

5.3 Confusion Matrix ODf . . . 20

5.4 Confusion Matrix ODs . . . 20

6.1 Inferences from Confusion Matrices on All Datasets. . . 21

(9)

List of Algorithms

1 Retina classification . . . 17

(10)

Chapter 1

Introduction

Sense organs are those parts of the body that keep a human in touch with the physical world by allowing the body to feel touch,taste, sight, sound, and smell. The eye is a sensory organ that allows sight. The working of the eye is similar to a pin-hole camera where light first accumulates across the cornea, a spherical transparent layer that is spread across two-thirds of the human eye surface. The iris, the variable pupil of the eye, controls the amount of light passed to the eye to prevent over saturation of photo-receptors, much like how the aperture of a camera lens controls the light. The light then travels via the lens onto the retina,

Figure 1.1: Human eye cross section[1]

where an inverted image of the object being seen is created. This image is trans-mitted to the brain via neurons and is corrected in order for the brain to see an

(11)

Chapter 1. Introduction 2 upright image[5]. An image of the human eye is displayed in figure 1.1.

Computational diagnosis is the integration of computing methods and learn-ing capabilities to process medical data and contrive a diagnosis. The methods refered to here are the various artificial intelligence, machine learning, and data science facilities and practices in order to provide automated diagnosis with a minimal chance of error. [6]

1.1

Problem Background

Glaucoma, a disease of the eye that causes damage to the optic nerve is the second highest cause of blindness in the world[7]. Diabetic retinopathy is characterized by a gradual loss of vision due to damage to the retina caused by diabetes[8].This

(a) Healthy retina (b) Diabetic retina

(c) Glaucoma retina

Figure 1.2: A comparision of the retina at various stages of health [2][3] also one of the top five causes for blindness. While there are various other diseases, these two are the main focus of study as they are concentrated in the area of the

(12)

Chapter 1. Introduction 3 retina in the human eye. They each display unique changes in their onset, thus making the diagnoses at early stages possible. While there is no permanent cure for both, there is a chance of preventing permanent damage by early diagnosis. Due to computer imaging techniques, the procedure for diagnosis is non-invasive, i.e, the patient isn’t operated upon or has any blood tests conducted at an early stage.

Getting an image of the retina has been made easy due to two main imaging techniques, Fundus Photography and Optical coherence tomography (OCT). Fun-dus photography can be defined as a process where a 2-D representation of the retinal tissues obtained using reflected light being projected onto a plane. The image intensity changes with the reflected light’s intensity[9]. OCT on the other hand, obtains results by showing the differences in the refractive indices of vari-ous tissue surfaces and measuring the depth of the distance traversed by the back propagation of light[9].

1.2

Problem Statement

The need for swift diagnosis plays a very important role. While physicians with their knowledge and experience can make accurate diagnosis, they may or may not be equipped to handle more than one case at once. This causes unintended delay which is not the best thing for a patient. By the use of tools of computer vision and machine learning techniques, computer scientists are trying to improve the speed of diagnosis. This thesis aims to bridge the gap between the image processing and diagnosis part by developing an algorithm that will not only process the image to show the traits of diseases clearly, but will also classify them into two seperate catogories.

1.3

Objectives

The objectives of the thesis are:

• To develop an algorithm to extract descriptive features from the retina images that can be used to classify them into healthy or unhealthy im-ages/patients.

• To investigate which among those features work best for the above classifi-cation.

• To detect which image transformations can have a positive impact on the prediction process.

(13)

Chapter 1. Introduction 4

1.4

Research Questions

RQ1: Which features, extracted from the fundus images , can be used to best characterize the health status of the retina (disease association)?

Motivation: While there is extensive research on retinal imaging and computer diagnosis [8], this perspective of diagnosis where a specific feature set could po-tentially assist in classification better than other with regard to an algorithm is novel.

RQ2: Which of the different image transformations (e.g., spatial or frequency based transformations) work best for providing accurate disease predictions? Motivation: Enhancing the image in two separate domains can alter the results for better or worse. In the context of this algorithm, finding the best conditions for the algorithm to work is the motive for this RQ.

Thesis Outline

The document has been organized into six sections,

• Introduction: Discusses background of the problem, the problem state-ments, objectives of the thesis, and RQs.

• Background: This section contains introduction to the topics relevant to the thesis.

• Related Work: Discussion on previous research in the relevant fields and how those findings are imperative for this thesis.

• Method: Elaboration of the experiment set-up, steps in development and the setbacks faced and the solutions to counter the setbacks.

• Results: Detailed results obtained by running the algorithm based on the precedent set in the research qustions introduced in section 1.4.

• Analysis and Discussion: The evaluation stratergies used in the thesis will be detailed here.

• Conclusion and future work: Offers conclusions and a structure future re-search can utilize to better this thesis.

(14)

Chapter 2

Background

This chapter deals with the terms frequently addressed in the thesis and their relevance to the study. Each section introduces the topic and ties it to the over-all thesis within two or more paragraphs.

2.1

Computer Vision

Computer vision is a field of study that deals with making computers read and react to real world visual media in order to automatize generic human visual aid tasks[10]. Computer vision is primarily used to extract dimensional real world data and then to process the data into computer understandable decisions or nu-meric attributes[11].

Medical image processing is an area where computer vision is gaining more promi-nence. Image data gathered is in the form of x-rays, ultrasounds, fundus images, tomographs etc. All the data that is gathered must be processed, and as there is a lot of data, it becomes hard to do manual processing, it must be automated. A lot of tools are being developed for this purpose. One such toolkit is the computer vision toolkit offered by Mathworks in their packages for MATLAB[12].

2.2

Medical Imaging

Medical imaging is the science of visualising internal body parts by various meth-ods as mentioned in the previous section. Medical imaging has become an insepa-rable part of modern medicine and is perhaps the most effective means of enabling physician diagnosis.As this field deals with image data, computer scientists have been working closely with medical scientists to provide better diagnostic tools that can be used in real time. Various successful tools have been developed such as the tools for breast cancer detection[13]. This is also applicable in other areas of medicine such as ophthalmology, orthopedics, etc.

Retinal Imaging

Retinal imaging is a branch of medical imaging pertaining to the visualisation of the retina. As discussed in section 1.1, there are various methods to obtain such

(15)

Chapter 2. Background 6 images for research, there are quite a few databases that provide the necessary retinal image data for the purpose of image processing studies as this can help improve diagnostic standards.

2.3

Image Processing

Image processing is a branch of science that deals with the analysing images to use them for further studies. The steps involved in image processing that are most applicable to this thesis are[14]:

• Image Enhancement: to refine the quality of image.

• Image Transformation: These are mathematical operations applied on the image to transform them into spatial domain(default) or frequency domain. In the spatial domain, the image is processed as pixels. In frequency domain, the image is processed in terms of intensity of the image.

• Image Segmentation: This is the step where the regions of interest are seperated into smaller units.

2.3.1

Image Enhancement

Image enhancement is the first step in image processing. This is undertaken so as to improve quality of the image in terms of clarity inducing details including, but not limited to contrast, detailing, noise-removal, sharpening the image. The end result of image processing is a much clear image with clearly distinguishable objects which make the task of segmentation simpler[15].

There are many techniques that can be used in image enhancement, some of them are

1. Histogram Equalization: A histogram in image processing is a graph depict-ing the pixels of an image with respect to the varydepict-ing intensities[14]. 2. Contrast-Limited Adaptive Histogram Equalization (CLAHE): This method

enhances the contrast of the image by breaking down a given image into tile, and enhancing the contrast and rejoining the tiles such that the output is a similar histogram to the parameters set [16]

2.3.2

Image Transformation

Image transforms are mathematical operations that can convert an image from one domain to another.Two important domain transformations relevant to this

(16)

Chapter 2. Background 7 thesis are:

1. Spatial Domain Filters: Spatial domain is where pixels can be manipulated relative to each other.Spatial filters can be classified into linear and non linear filters.

Linear filters are those filters that change the values of the pixel by a func-tion f(x) when applied. Examples of linear filters are Gaussian, Laplacian, prewitt, etc [14].

Non linear spatial filters use a statistical approach to change the pixel value to a mean or median value. Non-linear filters include median filters, ranking filters etc.

2. Frequency Domain Filters: Frequency domain is a plane where the image studied is in terms of intensity of the pixels rather than the positioning of the pixels as in spatial domain. Images by default are studied in spatial domain, they can be converted to frequency domain by applying Fourier Transformations. It is not necessary for an image to be converted into frequency domain in order to apply frequency domain filters. Frequency domain filters are classified into high-pass filters, low-pass filters and selec-tive filters.

High-pass filters allows signals at frequencies higher than the threshold to pass, and they attenuate lower frequency signals. These filters sharpen the contrasts in the image.

Low-pass filters allow signals at frequencies lower than the lower threshold to pass while attenuating higher frequencies. These filters smoothen the contrast in the image.

Selective filters operate on smaller regions which require both high-pass and low-pass filtering.

The most used filters in frequency domain are the Gaussian filter and the Butterworth filters. They are implemented as both high pass and low pass filters[14].

2.3.3

Segmentation of Images

Dividing an image based on regions that are distinctive by the variation of color or intensity is segmentation. Segmentation is the most crucial step towards the right analysis of an image.

There are numerous approaches to segmentation, some of them are discussed below[14],

1. Edge detection: This is an approach where it is imperative to detect the boundaries of regions present within the image. Based on this, the image is segmented into regions. The boundaries are detected by discontinuity of the intensity within the image.

(17)

Chapter 2. Background 8 2. Thresholding: This method differentiates the intensity of pixels from one region to another and segments the image based on a set threshold for high and low intesity.

3. Region based segmentation: This is a technique where the image is sub-divided based on seedpoints. A seed is a starting point in region based segmentation that has a set of predefined properties such as pixel value or range of color value. This seed point then iteratively expands as more re-gions with similar properties are added thus resulting in an image that is divided based on regions.

2.3.4

Feature Selection

After segmentation, it is important to ensure that the regions are made to a more optimal data that can easily be processed.

The segmented image shall further be divided based on regions of interest. A region of interest is a section of the image that can be further studied so as to arrive at a comprehensive analysis of the image.

2.4

Analyzing the Results

2.4.1

Confusion Matrix

A confusion matrix is a table that represents predicted and actual class in a classification problem. It holds the number of instances of correct predictions, incorrect predictions, false labels.

Terms commonly associated with a confusion matrix are:

• Condition Positive(P)- All the values marked positive, i.e all the true posi-tive and false posiposi-tive values.

• True Positive(TP)- All the correctly predicted values. • True Negative(TN)- All the correctly rejected values.

• False Positive(FP)- This is when a value is marked positive in spite of actually being negative.

• False Negative(FN)-All the incorrectly marked values, i.e all the wrong pre-dictions.

(18)

Chapter 2. Background 9

2.4.2

Inferences from the Confusion Matrix

The following are the inferences that can be made from a confusion matrix. • Accuracy: This provides the information of how often the classifier gives

the right answer.

Accuracy=TP+TN/total

• Recall: This gives the information on how often the algorithm predicts a true result.

Recall=TP/P

• Precision:Gives the number of true predictions that are correct. Precision=TP/TP+FP.

These inferences lead to better understanding of performance by giving way to certain other metrics such as Cohen’s Kappa co-efficent which denotes the conse-nous of the results by also allowing for a window of error.

The scores or co-efficents obtained in this case work as measures of agreement, i.e, if the Kappa score is 0.9 for a classifier, it means it is in very good agreement or works well [17].

(19)

Chapter 3

Related Work

This section discusses the existing work done in the area of interest in this thesis and how that helped in detecting a problem area.

3.1

Advances in retinal image processing

3.1.1

A Brief History

Some of the earliest advances in retinal imaging occurred in the 1980s with the in-troduction of various algorithms to register the image to study differences between healthy and diseased images[18]. The initial work in retinal image processing was started in 1973 by Matsui et al.to segment the blood vessels by morphological operations on slides of angiograms [19]. The first method to segment the ab-normalities that are indicative of disorders was done in 1984 on the angiograms. This was done by the application of top-hat filters on the image [20]. The 1990’s brought about a lot of radical advances in digital image processing therefore up-dating retinal image processing to the present day standards of research.

3.1.2

Contemporary Research

Most research in retinal imaging obtains inputs from either fundus images or OCT images. Fundus images are images which can be worked on by most mod-ern image processing methods. OCT images are more like signals extending to time domain in some cases[9].

Fundus images require enhancement before they can be processed further. This is done because fundus images are usually low contrast, and to emphasise certain features like the blood vessels while muting others. Some methods that are com-monly used are discussed further. a) Mahalanobis Distance: This method was initially used to study x-rays. It requires the programmer to identify background and foreground pixels and eliminating the background pixels based on pixel in-tensity values. based on a study conducted in [21], it was found that this method

(20)

Chapter 3. Related Work 11 retained most of the optic disk and blood vessel distinction. b) Histogram Equal-ization: This method plots the histogram of a gray-scale image. The plot has the frequency of occurrence of various intensities across the image. It was found that this method emphasized the blood vessels in the image[21]. c) Contrast Lim-ited Adaptive Histogram Equalization CLAHE: This method doesn’t convert the image into gray-scale, instead histogram equalization is performed on RGB im-ages. Each pixel is transformmed based on a heuristic function and the contrast is controlled by setting a threshold to the histogram plot. In retinal imaging, CLAHE displays better blood vessels as well as retaining the background[21] An image can exist in two planes, spatial and frequency. In spatial, the image is referred to in terms of it’s pixel value and in frequency it is referred to in terms of frequency of intensity. By applying filters, the images can be changed into the different planes. In case of spatial filters, the most prominent set of filters are median filters. They are used to remove high levels of noise from the image in the enhancement stage [22]. By doing so an image with very less extra values is obtained. In [22] a switching median filter is used which can remove spotty noise termed as salt and pepper noise effectively.

There are several segmentation methods that have been implemented on fundus images for the express purpose of studying retinal diseases and classify the im-ages based on their properties. Some methods studied frequently are a) Histogram based: The intensity of a group of pixels is found and plotted on a histogram of intensities. By grouping pixels of similar intensities, it becomes easier to pinpoint different regions of an image [23] By doing so, researchers locate the optic disk more easily than the blood vessels, and successfully isolate the area. b) Entropy threshold: This method is based on how effectively the information is passed from one pixel to an other. In the retina this is prefered when the blood vessels need to be segmented and are too thin to use other methods [24]. Other parts of a retina that are frequently segmented so as to study their characteristics are, the fovea and the macula, the darkest parts of the retina.

Classifying the image based on the segmented areas is where the main purpose of retinal analysis is realised. In classifying the retina, a lot of parts of the retina are studied. Most frequently, the blood vessels and micro-haemorrages. These are the prominant signs of diabetic retinopathy. Localizing the optic disk results in easier study of glaucoma. most often, hough transforms are used to study the optic disk.Some algorithms that are used in classyifying retinal images are KNN[9], BP neural networks[25] and general linear model[21].

3.2

Formulating Research gap

Upon reading up a wide range of literature, there was a noticeable lack of discus-sion about a comparitive study of the filters in various domains and a study on which features could be deemed best for which disease identification.

(21)

Chapter 3. Related Work 12 That has been the motive behind the research questions formulated and this thesis aims to address that gap.

(22)

Chapter 4

Method

4.1

Dependent and Independent Variables

Independent: Adaptive Histogram Equalization, color channel separation. These are variables that won’t change regardless of modifications in the experi-ment. These are values that are integral to the core working of the algorithm. Dependent: Time taken for execution, the pre-processed image.

These values will change depending on the situation under which the algorithm will be implemented. Depending on the type of filter time of execution and the image will change. Different datasets can be used on the same algorithm.

4.2

Choosing the Dataset

This is one of the most critical steps in designing this algorithm. There are many datasets openly available for retinal fundus imaging such as STARE[26] and DRIVE[27]. But in these, a golden truth dataset called the High resolution Fundus image dataset was used[4]. This is a set of 45 images where there are 15 healthy, retinopathic and glaucomatous images each. Other datasets were rejected as they lacked the golden truth.

4.3

Motivation of Choices

This section offers an explanation as to why certain methods and techniques were chosen over the other.

4.3.1

Preprocessing Stage

• Reading images from the data set: High Resolution Fundus(HRF)image dataset[4] was used for this thesis. In order to read multiple images at the same time, a loop was built at the very beginning as follows

imgPath = ’filepath’

(23)

Chapter 4. Method 14 dCell = dir(imgPath);

for d = 3 : length(dCell)

fullFileName = fullfile(imgPath, dCell(d).name); Seqd = imread(fullFileName);

I = imresize(Seqd,[500 700]);

• Switch Case: The unique aspect of this algorithm was that it had both spatial and frequency domain filtering. In order to toggle between these senarios a switch case was introduced.

• Colo Channels: The image was converted into a green plane in order to extract blood vessels as they are most striking in that spectrum.

To segment optic disk, the red channel was used as the disk was more promi-nent and the blood vessels subdued in this case.

In both scenarios, it didn’t make sense to use a blue channel image as there was little to distinguish the parts the image in this case.

• Adaptive filter: Adaptive filters were applied in both channels to eliminate background noise.

• Spatial filter: In the first case, medfilt2(); was used as it was the best fit for the green channel image with it’s 2D image filtering capabilities.

• The blood vessels were segmented using discrete wavelet transformation and gray level thresholding.

• The The optic disk was segmented based on intensity thresholding by finding the mean bright spot across the optic disk.

• Gaussian filter was used in the frequency domain. The Gaussian filter is a lowpass filter used in this case because it blurred out the foreround just enough to distinguish it.

4.3.2

Classification

• In this case, feature extraction is done using bag ofvisual words and classi-fication using an SVM based image classifier[28].

(24)

Chapter 4. Method 15

Figure 4.1: Color Channels[4]

The bag of visual words model uses a k-means clustering approach to ag-gregate similar features. K-means is used as mapping similar occurances together offers a more detailed feature vector.

• An SVM based image classifier was used as it works significantly better than other classification models on images that are high dimensional and characterized by histograms. This is because of the generalization of data to avoid over fitting[29].

• Owing to the small size of the dataset, a random split was done on the dataset to divide it into training and test sets. As this is a dataset that has been frequently used to study retinal imaging, it was found that most

(25)

Chapter 4. Method 16 studies on this dataset were done using a random split.

It must be noted that in order to use imageCategoryClassifier, a GPU enabled computer was used as it requires using Parallel Computing Toolbox from MAT-LAB.

4.4

Development of Algorithm

Conducting the study for related work, it was relatively easy to glean which methods would work best on which types of images. With this knowledge the algorithm was implemented. This algorithm has been written in two phases.

The first phase of the algorithm deals with pre-processing of images. All the method used have been described above.The second phase deals with the classi-fication.

It must be noted that in order to use imageCategoryClassifier, a GPU enabled computer was used as it requires using Parallel Computing Toolbox from MAT-LAB.

(26)

Chapter 4. Method 17 Result: Confusion matrix of classifier

/* Phase 1: Preprocess the image */

Step 1: Set path to datasets

Step 2: Set condition variables for the ordered passage of files. Step 3: switch n do

Case 1 Spatial Transform Step 4:resize input images

Step 5: adaptive histogram on image Step 6: medianfilter on image

Step 7: convert to green channel Step 8:Apply graythresh on image

Step 9:Discrete wavelet transform on the filtered image

// o/p approximately segmented blood vessels

Step11: convert image output from 6 to a red channel image. Step 12: Set a threshold value greater than 133(brightest pixel intensity)

Step 13: Apply the threshold on the image. // o/p Segmented optic disk

Step 11: Seperate Segmented disk and blood vessel from original image end case

Case 2 Frequency transform Repeat steps 4->6

Step 7: Apply Gaussfilt Repeat steps 8-> 11 End case end

/* Classification */

Divide the training set and test set Feature descriptors

// BoF

Classification

// imagecatogoryclassifier

Predict results

Print confusion matrix End

Algorithm 1: Retina classification

4.5

Approach to Obtaining Results for RQs

The pre-processing phase gave four datasets as outputs. They are named BV,BVf,OD,ODf, i.e Blood vessels after spatial and frequency transformation and optic disk after

spatial and frequency transformations.The classifier is run on all the datasets. To arrive at the results, the outputs of the test runs are compared. The outputs are in the form of confusion matrices.

(27)

Chapter 5

Results

5.1

Result of Phase 1

Below are the output images from phase 1 of the algorithm. First is the original image, followed by the four outputs obtained by running the program in the two different cases consecutively. The time taken for the spatial filter to run on the image was 49seconds, and the time taken for the frequency filter was 47 seconds. While the blood vessels obtained in both the cases are not black and white mages as the mask has been retained in this case. The optic disk is a black and white segmented portion from he original image. This was because in most prominent literature, the blood vessel has extensively studied in it’s gra form whereas the optic disk segment was only studied based on a cup to disk ratio. This allows researchers to study the optic disk as a gray image as well.

This phase yields four datasets, the blood vessel datasets obtained using spatial and frequency, and the optic disk datasets obtained from spatial and frequency. This is passed as an input into the feature extraction and classification phase.

Figure 5.1: Original Image[4]

(28)

Chapter 5. Results 19

(a) Blood vessel spatial (b) Blood vessel frequency

(c) Optic disk spatial (d) Optic disk frequency

Figure 5.2: Sample Images from Output Datasets

5.2

Results from Phase 2

The results obtained from classification of the various cases are given below. They are displayed as confusion matrices. As the classifier worked on more than one dataset, a confusion matrix was tabulated for each dataset separately.

The original results were replicated as a table in order to display them coher-ently.

The shorthand used in representation is

optic disk-OD; blood vessel-BV; frequency-f; spatial-s; glaucoma-G; healthy-H; diabetic retinopathy-DR.

These terms are used to describe the datasets considered, and which filter was applied on the datasets. The dataset is split into optic disk and blood vessels to measure which feature provides better results.

(29)

Chapter 5. Results 20

5.2.1

Results on Blood Vessel Datasets

Following are the results of the classifier on blood vessels. The blood vessel images are further segregated into frequency filtered images and spatial filtered images.

Actual

Predicted G H DR G 1.0 0.0 0.0 H 0.0 1.0 0.0 DR 0.0 0.2 0.8 Table 5.1: Confusion Matrix BVf

Actual

Predicted G H DR G 1.0 0.0 0.0 H 0.0 0.8 0.2 DR 0.2 0.2 0.6 Table 5.2: Confusion Matrix BVs

5.2.2

Results on Optic Disk Datasets

Following are the results of the classifier on optic disk images. The optic disk images are further segregated into frequency filtered images and spatial filtered images. Actual Predicted G H DR G 0.8 0.2 0.0 H 0.0 1.0 0.0 DR 0.0 0.2 0.8 Table 5.3: Confusion Matrix ODf

Actual

Predicted G H DR G 0.8 0.0 0.2 H 0.0 0.75 0.25 DR 0.0 0.0 1.0 Table 5.4: Confusion Matrix ODs

(30)

Chapter 6

Analysis and Discussion

This chapter deals with the analysis of the results so as to get a clearer idea of how well the proposed solution works. The confusion matrices in the previous section will be analyzed.

6.1

Analysis

This section will contain a table with the dataset used, the accuracy on the dataset, precision,recall and the kappa score.

Table 6.1: Inferences from Confusion Matrices on All Datasets. Dataset Accuracy Recall Precision Kappa Score

BVf 93.33 94.44 93.33 0.9 BVs 80 79.44 80 0.7 ODf 86.63 90.46 86.67 0.8 ODs 85 89.66 85 0.77 The average accuracy of the classifier = 86.24

The average kappa score is almost 0.8

This indicates that the classifier is in near consensus with the requirement as evidenced by[17].

From the result table, this classifier has most accuracy on the images of fre-quency transformed Blood Vessels and the least accuracy on spatial transformed images of Optic disks.

6.2

Comparison of Results

This section compares the results obtained on the best performing dataset to a similar experiment done on the same original HRF dataset. The paper used for comparision is[30]. The authors of this paper have a goal of classifying the same

(31)

Chapter 6. Analysis and Discussion 22 HRF dataset that was used in this thesis into Healthy, Glaucoma and Diabetic Retinopathy. The approach taken was entirely different. They worked solely on the blood vessels in their gray scale form. features were extracted using vascu-lar trees and classified using ANNs with Back-propagation algorithms. For each individual class, they have mentioned the results as accuracy of the classifier on that class. They achieved accuracies of 97, 99 and 96 on Retinopathy, Glaucoma and healthy images respectively.

On the best performing dataset in this thesis, the accuracies were tabulated as 93.33,100 and 100 on retinopathy, glaucoma and healthy images. This allows the conclusion that this algorithm works better in classifying glaucomatous and healthy eyes better than the existing methods.

6.3

Validity Threats

This section discusses all the possible threats that can harm the credibility of the research and how they can be negated.

6.3.1

Internal Threats

Datasets: The dataset is fairly limited(45 images in 3 classes) and due to MAT-LAB’s constraints, the dataset was taken as it were. This dataset was split using a randomized split functionthat is allowed by MATLAB. The training set is 70per-cent and the test set is 30 per70per-cent.The images are randomly selected. This dataset was used in numourous other papers in a simialar way to avoid validity threats.

6.3.2

External Threats

Due to thehighly specific nature of the problem area, the work done can’t become a plain image classification algorithm. While this is true, using the same steps with modified parameters can make this a domain independent algorithm.

6.4

Further Discussions

Beyond these results, an other interesting trait that can be observed is that when a black and white image of the blood vessels was used, the accuracy of blood vessels was far lower than that of the optic disk.

(32)

Chapter 7

Conclusions and Future Work

7.1

Conclusion

In this thesis an algorithm was designed to find which section of a fundus image works best in disease association prediction, and which transformation techniques work best in prediction.

The results were analyzed using a confusion matrix and the accuracy was calculated. Cohen’s Kappa was calculated to check the window of error. It was found that blood vessels had a higher score especially when they were frequency transformed.

Based on the results obtained, it can be concluded that blood vessels are the best feature for predicting disease associations while frequency transformations were more efficient.

7.1.1

Answering RQs

RQ1

Based on the tables given above, the best feature from a fundus image for disease association is found to be the blood vessels. This conclusion is formed as the blood vessel dataset offers higher accuracy(93.33) than using the optic disk. RQ2

The best transformation for predicting disease associations is frequency domain transformations because

1. The highest accuracy across both the features, i.e blood vessels and optic disks is obtained by a frequency domain image. in case of blood vessels the accuray obtained is 93.33 and in optic disk, the accuracy is 87.

2. Frequency domain transformation takes lesser time than spatial domain.

(33)

Chapter 7. Conclusions and Future Work 24

7.2

Future Work

In order to extend the work presented in this thesis, a good implementation would be trying out the algorithm in Python or R where multiclass classification seems to have a wider range of tools.

Implementing this algorithm on the other datasets can also be an interesting out-come.

Validation of the HRF dataset using standard methods such as cross-validation can be studied to better understand the datasets.

Working on more features than just the blood vessels and optic disk can be done to provide a more all round diagnosis.

The sparsity of labelled datasets can be rectified by creating a dataset with the assistance of a human expert.

(34)

References

[1] Eye anatomy | ocular anatomy | vision conditions & problems. http://www. mastereyeassociates.com/eye-anatomy.

[2] Glaucoma treatment bayside. http://www.dragaeyecare.com/glaucoma. php.

[3] Retinal imaging. http://www.northbayeyecare.ca/retinal-imaging/. [4] High-resolution fundus (hrf) image database. https://www5.cs.fau.de/

research/data/fundus-images/.

[5] Barry W. Connors Mark F. Bear and Michael A. Paradiso. Neuroscience, Exploring the brain. Lippincott Williams & Wilkins, fourth edition, 2015. [6] Manfred Schmitt. Computational Intelligence Processing in Medical

Diagno-sis. Physica-Verlag, first edition, 2002.

[7] Who | causes of blindness and visual impairment. http://www.who.int/ blindness/causes/en/.

[8] Diabetic retinopathy - causes, symptoms, risks & prevention. http://www. diabetes.co.uk/diabetes-complications/diabetic-retinopathy. html.

[9] Michael D. Abramoff, Mona K. Garvin, and Milan Sonka. Retinal imaging and image analysis. IEEE Reviews in Biomedical Engineering, 3:169–208, 2010.

[10] Reinhard Klette. Concise computer vision. Springer, 1 edition, 2014.

[11] George C Shapiro, Linda GStockman. Computer vision. Prentice Hall, 1 edition, 2001.

[12] Hewett D Chase JG Shaw GM Hann CE, Revie JA. Screening for diabetic retinopathy using computer vision and physiological markers. Journal of diabetes science and technology (Online)., 3.((4)):819–834, 2009.

(35)

References 26 [13] C.P.Sumathi B.M.Gayathri. and T.Santhanam. Breast cancer diagnosis us-ing machine learnus-ing algorithms –a survey. International Journal of Dis-tributed and Parallel Systems (IJDPS), Vol.4(No.3), may 2013.

[14] Rafael C. Gonzalez and Richard E. Woods. Digital Image Processing (3rd Edition). Prentice-Hall, Inc., Upper Saddle River, NJ, USA, 2006.

[15] Rati Bedi, S.S Khandelwal. Various image enhancement techniques- a crit-ical review. International Journal of Advanced Research in Computer and Communication Engineering, 2(3), 2013.

[16] Contrast-limited adaptive histogram equalization (clahe) - matlab adapthis-teq - mathworks nordic. https://se.mathworks.com/help/images/ref/ adapthisteq.html.

[17] J. Richard Landis and Gary G. Koch. The measurement of observer agree-ment for categorical data. Biometrics, 33(1):159, 1977.

[18] E. Peli, R. A. Augliere, and G. T. Timberlake. Feature-based registration of retinal images. IEEE Transactions on Medical Imaging, 6(3):272–278, Sept 1987.

[19] Matsui M, Tashiro T, Matsumoto K, Yamamoto S Nippon Ganka, and Gakkai Zasshi.

[20]

[21] H. A. Rahim, A. S. Ibrahim, W. M. D. W. Zaki, and A. Hussain. Methods to enhance digital fundus image for diabetic retinopathy detection. In 2014 IEEE 10th International Colloquium on Signal Processing and its Applica-tions, pages 221–224, March 2014.

[22] A. Kaur and P. Kaur. An integrated approach for diabetic retinopathy exu-date segmentation by using genetic algorithm and switching median filter. In 2016 International Conference on Image, Vision and Computing (ICIVC), pages 119–123, Aug 2016.

[23] Hamid Abrishami MoghaddamEmail Amin Dehghani and Mohammad-Shahram Moin. Optic disc localization in retinal images using histogram matching. EURASIP Journal on Image and Video Processing, 2012.

[24] N. P. Singh, R. Kumar, and R. Srivastava. Local entropy thresholding based fast retinal vessels segmentation by modifying matched filter. In Interna-tional Conference on Computing, Communication Automation, pages 1166– 1170, May 2015.

(36)

References 27 [25] M. You and Y. Li. Automatic classification of the diabetes retina image based on improved bp neural network. In Proceedings of the 33rd Chinese Control Conference, pages 5021–5025, July 2014.

[26] The stare project. http://cecas.clemson.edu/~ahoover/stare/.

[27] Image sciences institute: Drive: Digital retinal images for vessel extraction. http://www.isi.uu.nl/Research/Databases/DRIVE/.

[28] Predict image category - matlab - mathworks nordic. http://se. mathworks.com/help/vision/ref/imagecategoryclassifier-class. html.

[29] Olivier Chapelle, Patrick Haffner, and Vladimir Vapnik. Svms for histogram-based image classification, 1999.

[30] B. Barua and M. M. Hasan. A new approach of detection and segmentation of blood vessels for the classification of healthy and diseased retinal images. In 2016 3rd International Conference on Electrical Engineering and Information Communication Technology (ICEEICT), pages 1–6, Sept 2016.

References

Related documents

Industrial Emissions Directive, supplemented by horizontal legislation (e.g., Framework Directives on Waste and Water, Emissions Trading System, etc) and guidance on operating

Re-examination of the actual 2 ♀♀ (ZML) revealed that they are Andrena labialis (det.. Andrena jacobi Perkins: Paxton & al. -Species synonymy- Schwarz & al. scotica while

This is especially true for the study of the his- togram of oriented gradient (HOGs) features (the descriptor of the SIFT algorithm[12]). We will present both how these are very

46 Konkreta exempel skulle kunna vara främjandeinsatser för affärsänglar/affärsängelnätverk, skapa arenor där aktörer från utbuds- och efterfrågesidan kan mötas eller

Both Brazil and Sweden have made bilateral cooperation in areas of technology and innovation a top priority. It has been formalized in a series of agreements and made explicit

The increasing availability of data and attention to services has increased the understanding of the contribution of services to innovation and productivity in

Generella styrmedel kan ha varit mindre verksamma än man har trott De generella styrmedlen, till skillnad från de specifika styrmedlen, har kommit att användas i större

Parallellmarknader innebär dock inte en drivkraft för en grön omställning Ökad andel direktförsäljning räddar många lokala producenter och kan tyckas utgöra en drivkraft