Green Channel and Top Hat based Image Enhancement for Diabetic Retinopathy Screening

Diabetic Retinopathy remains one of the most feared diabetes complications that could lead to blindness. Image processing techniques have been widely used all around the world for early detection of diabetic retinopathy. However, most techniques used do not focus on the low visual quality problems in the fundus image. Low visual quality of fundus image may lead to difficulty in evaluation by ophthalmologist before reading it out to the patients. Hence, Automated Screening for Diabetic Retinopathy was created to focus on image enhancement of the fundus image. In this study, two main algorithms for image processing have been used which are green channel conversion and top-hat filters. Green channel in fundus image is selected due to better contrast of the features and background compared to the red and blue channel. While Top-hat filter used to details out small features in the fundus image. The evaluation result of the techniques is compared by using Mean-Squared Error (MSE), Peak Signal-to-Noise Ratio (PSNR) and Entropy calculations to measure quality of the enhanced fundus images. Results of image enhancement techniques implemented has proved that quality of the fundus image is improved.


Introduction
Diabetic Retinopathy is a medical condition that could lead to blindness particularly in patients with diabetes for more than 20 years. In the last decades, incidence of diabetes among adults around the world has increased [1]. The International Diabetes Federation (IDF) estimates that global diabetes crisis would continue to grow [2]. Three main types of diabetes are type 1 diabetes, type 2 diabetes and gestational diabetes (GDM). Type 1 diabetes could develop at any age, whether children or adolescents. In type 1 diabetes, the body produces little or no insulin while type 2 diabetes is more common among overweight or obese individuals. Type 2 diabetes is due to effects of insulin resistance. On the other hand, gestational diabetes is term used in pregnant women with high glucose levels diagnosed after 20 weeks of gestation and resolves within 6 weeks postpartum. Tight sugar control is mandatory in gestational diabetes due to the fact that uncontrolled sugars would have detrimental effects on mother as well as fetus. Duration of longstanding diabetes leads to higher risk of complications including  [3]. Both people with type 1 and type 2 diabetes are at high risk of having diabetic retinopathy. Study among 7000 diabetic patients showed that 80% patients with diabetic retinopathy face difficulties doing everyday chores such as driving, working, and reading [4]. The early stage of diabetic retinopathy is known as non-proliferative diabetic retinopathy (NPDR) which shows mild or non-existent symptoms while the more advanced form is known as proliferative diabetic retinopathy (PDR).
In 2006, the World Health Organization (WHO) estimated that Malaysia would have 2.48 million people suffering from Diabetes by the year 2030 [5]. However, in 2019, former Minister of Health, Datuk Seri Dr Dzulkefly Ahmad stated that 3.6 million Malaysians already suffer from diabetes. This incidence contributes to the highest rates in Asia and one of the highest in the world [6]. Diabetes has become a worrying concern in Malaysia. Therefore, the Government of Malaysia is giving serious attention to this issue and has developed a comprehensive strategy and approach to strengthen diabetes prevention, treatment and control as an urgent response to this. However, the work-load of repetitive manual grading in diabetic retinopathy would be increased as diabetic fundus was only screened by the ophthalmologist in most hospitals in Malaysia. The screening puts a tremendous workload on the ophthalmologists as they need to analyze the results individually before reading it out to the patients. Besides that, before the condition worsens to late stages of diabetic retinopathy, rapid screening technique is required for early detection of retinopathy as delays in diagnosis would result in a substantial economic burden on the healthcare system and national economy. Despite the fact that Malaysia has both public and private healthcare systems, most of the treatment for this chronic disease has been provided by the public health system and a study in 2011 found that about RM 2 billion has been spent for the healthcare budget in that year [7].
Past studies reported that Image Processing techniques have been widely used on fundus images to help the ophthalmologists for early detection of diabetic retinopathy. Fundus images that have been taken through the fundus camera might degrade quality of the images [8]. Therefore, many image processing techniques such as image enhancement, image segmentation, image fusion classification and morphology have been used to improve quality of the fundus images and at the same time extract all abnormal features in the image such as microaneurysms, cotton wool, hemorrhages, abnormal growth of blood vessels and exudates.
This study presents the implementation of image enhancement for diabetic retinopathy screening based on fundus image. Image enhancement techniques that have been used can be an effective early screening technique in diagnosis of diabetic retinopathy, as early detection is critical key for early prevention. This will help the ophthalmologists in early awareness and educating diabetic patients so that proper preventive measures are taken to help prevent progression of diabetic retinopathy. MATLAB software has been used to develop all the processes involved. The main processes are green channel conversion where green channel of the image is selected as it enhances contrast of the fundus image more as compared to red and blue channel, and top-hat filters methods is performed to remove uneven background and isolate various shapes in the image to see clearer features of the image. An experiment on comparison within these two methods will be conducted and explained in methodology. In order to measure the quality of original and processed images, performance evaluation such as Mean Squared Error, Peak Signal-to-Noise Ratio and Entropy has been performed on the images.

Related Work
Diabetic retinopathy is difficult to detect in the early stages as features of diabetic retinopathy in fundus image could not be clearly seen. Furthermore, rapid detection tests in diabetic patients need a long time to be done. In technique such as Fluorescein Angiography, patient's eyes are dilated to widen pupil so that there is better visualisation of retina, optic nerve and macula. Subsequently, a yellow dye is injected to have a better visualisation of the posterior segment of eyes. Optical Coher-ence Tomography (OCT) is also another way to have a closer look at the retina. The machine scans the retina and shows its thickness in detail and they would use a special camera to capture the fundus image [9]. However, quality of the fundus images taken could be decreased because of the unnecessary brightness, 3 environment and process of acquisition [10]. Hence, image processing techniques were involved in diagnosing diabetic retinopathy to enhance the quality of the fundus images. Several methods have been proposed by researchers in order to find the best way to improve the fundus images' quality. The following papers have been studied and analysed in detail to determine suitable algorithm that can be used.
Research by Subhashini, Nithin and Koushik focused on the enhancement of fundus images by using a gaussian filtering method to remove noise in the image. The processed image then goes through bilateral filtering to preserve sharp edges before converting to grayscale image. After converting to grayscale, the image was sent for contouring where unnecessary parts of the image are detected and removed. Then, blood vessel segmentation is used for differentiating or identifying the haemorrhages or swollen blood vessels [11]. However, the researchers stated that image enhancement methods used could be optionally disabled because the grayscale image processing in the project decreased the contrasts, sharpness, shadow and structure of the fundus images as shown in figure 1. Another research by Peng Feng, Yingjun Pan Biao Wei, Wei Jin and Deling Mi focused on image enhancement by using Contourlet transform. Others processes involved in the project are histogram equalization, local normalization, linear un-sharp masking, wavelet-based and Contourlet-based enhancement. The researchers stated that image contrast has been improved after using the Contourlet transform approach. However, the function tends to change the width of blood vessels which could negatively affect the blood vessels segmentation that would be performed later [12]. The researchers planned on improving the project by concentrating on Contourlet shift-variance transformation and finding the right parameters for the methods.
Therefore, in this study we propose an experiment on two methods that consciously improve the quality of fundus images by enhancing contrast of the images and improve all the features of diabetic retinopathy in the image. Even though, there would be some previous study that used same methods, but in this study, the concept for methods used is experiment based and we only focus on different dataset which is fundus image. Besides, image performance evaluation will compare the quality of enhanced image based on the method applied.

Methodology
The proposed method is developed and presented here. The flowchart of the processes is illustrated in figure 2. All the processes involved is explained in this section.

User Input Fundus Image.
A dataset of 20 fundus images of type 2 diabetic patients were obtained from local hospital in Malaysia. The fundus images obtained have been categorized into Non-Proliferative Diabetic Retinopathy (NPDR) and Proliferative Diabetic Retinopathy (PDR) by optometrist. There are 3 right eye and 7 left eye images of NPDR; and 6 right eye and 4 left eye images of PDR that were used in this study. All the images had no link to the patients' identities.

Green Channel Conversion from Original Image.
Human eye is most sensitive to green colour because human eyes cones are more sensitive to green frequencies than red and blue frequencies [13]. Therefore, the fundus image is converted into a green channel image as it is inexpensive replacement from RGB to intensity conversion. Green channel provides maximum local contrast between the background and foreground so it could increase visibility of haemorrhages and microaneurysmys and decrease computational time [14].
Hence, the green channel of the fundus image is focused and displayed to enhance the image contrast where the haemorrhages and microaneurysmys can be clearly seen through green channel conversion. In figure 3, the selected channel from the input image is shown.

Top-hat Filtering on Original Image.
Morphological top-hat filtering has been performed to fundus image as shown in figure 4. It measures the image's morphological opening, then subtracts the result from the original image [15]. Top-hat filter is an operation that enhances image details. There are two types of top-hat filters. The one that has been used in this project is white top-hat which is defined by its opening on input image in certain structuring element (strel) differences while the black top-hat also known as bottom-hat is defined as closing on the input image differences.  Figure 4. Top-hat Filters Implementation

Green Channel on Top-hat Filter's Image Conversion.
Usually, Top-hat filter's image is converted to a green channel to facilitate blood vessels as we know, fundus image was best seen in the green component [13]. As we could see in the fundus image, blood vessels tend to look like a network structure that originates from centre of the optic disk. Blood vessels grow and expand to different branches. Therefore, green channel conversion is used to screen blood vessels and make it easier for ophthalmologists to see the abnormal growth of blood vessels in fundus images. Screening of blood vessels abnormality is important as complications could lead to serious vision problems.

Evaluation Performance
There are three types of conventional methods to measure quality of fundus images. The conventional methods are MSE, PSNR, and Entropy. Purpose of using all these three parameters is to see and compare differences of the images' performance before and after processing.

Mean Squared Error (MSE)
Mean Squared Error represents the cumulative squared error between original and processed image. It measures the average squares of the errors which means the value provided should have a slight difference between original and processed images. MSE is almost always strictly positive. Therefore, in order to evaluate the better images, MSE value processed image should be smaller than original image, which is the processed image are in the better fit because the image contains lower error.

Peak Signal-to-Noise Ratio (PSNR)
PSNR represents a measure of the image's peak error. It computes the peak signal-to-noise ratio to measure quality of original image and processed image. Therefore, in order to evaluate the better image, PSNR values of processed image should be higher than original image because it proves the better quality of the image.

Entropy
Entropy is a statistical randomness measure that could be used to characterize texture of the input image. It measures 'disorder' of the images. Therefore, to prove that the images are better, entropy values should be higher in processed image which means it provides better image details.

Result
In order to evaluate the better images, MSE values should be smaller, PSNR values should be increased and entropy values should be higher than the original image. 20 fundus images have been used in this experiment. Table 1 shows comparison between the image performance values (mean) among green channel process, top-hat filtering process and green channel (top-hat) process. Figure 6 below shows one of the resultant images.  From the evaluation of performance value, we can see that MSE value is decreased from the original image to the green channel conversion processed image which indicates that the green channel conversion image is in the best fit. PSNR value of the green channel conversion image is increased compared to the original image, showing that the green channel conversion image is of better quality. However, as entropy of the image is increased, it did not show much details of the image but the green channel conversion image successfully enhanced contrast of the original image because microaneurysms are clearly visible in the processed image. While, the result between top-hat filters of the same PDR fundus image and the conversion to green channel image shows that MSE value is decreased, PSNR value is increased and entropy value is increased. It proves that the image is of better quality because ophthalmologists could clearly see features of the fundus image and at the same time could see abnormal growth of blood vessels.