1 Introduction

Retinal image analysis is an important issue for the diagnosis of various optical diseases. To this end, it is necessary to identify precisely the pertinent structures of the eye fundus as, for instance, the optic disc [13] and the arterio-venular tree [12]. With this information, a characterization of cardiovascular complications [7] or pathologies such as diabetes [17] can be achieved.

Macular pucker, more commonly known as epiretinal membrane (ERM), is a fibrocellular tissue that can cause metamorphopsia, central vision decrease or blurred vision [1, 10]. Moreover, epiretinal membranes are associated with different types of cysts (macular, paravascular, lamellar macular) [11], further contributing to the eyesight distortion or reduction.

Idiopathic ERMs are the most common, but retinal vascular diseases or changes in the vitreous humor [4] can induce a response from the immune system to protect the retina. This response causes, sometimes, that the retinal cells converge on the macular region, creating a transparent layer. This layer, that is scar tissue, causes tension on the retina by contraction, further increasing the chances of secondary ERMs to appear.

Optical Coherence Tomography (OCT) imaging [3] is frequently used to analyze the retinal morphology and detect the presence of ERM. ERM appears as a thin reflective layer on the retina [2], fact that can be used for its detection on OCT images. Irregularities on the retinal surface or retinal thickening can also indicate the presence of ERM on the patient.

The asymptomatic nature of this pathology makes necessary a reliable and accurate detection system. With an appropriate method, ERM can be early detected and treated before further complications appear. Those methods are usually based in the manual detection of the ERM by a specialist [14]. Similarly, the method of Wilkins et al. [16] uses real-time OCT images and, after an specialist establish manual markers on the image, ERM is detected by the use of information about the reflectivity and thickness of the retina on the selected points.

In this work, we aimed for the automation of the process by developing an algorithm that selects autonomously the region of interest (ROI) where the ERM can be present. We analyzed the main characteristics of the ERM and designed a complete and heterogeneous set of features that helped to characterize the regions where the ERM is present. Optimal subsets of those features were selected and used to train representative classifiers. We use those trained classifiers to identify automatically the points belonging to the region of interest and pinpoint the presence or absence of ERM in the selected area. This method aims to improve the general error tolerance of the process by avoiding the use of manual markers for ROI initialization and making them non-dependent of human interaction.

2 Methodology

The proposed system tries to identify automatically the Inner Limiting Membrane (ILM), which is the boundary between the retina and the vitreous body, area where the ERM can appear if the pathology is present on the patient. Then, using these identifications, we analyze all the points belonging to the ILM, generating a rectangular-shaped window for each point and calculating the relevant features of the constructed window. Finally, every feature vector is used to classify its associated point and obtain information about the presence of ERM in the ILM retinal layer.

2.1 Identification of the Region of Interest

In this work, we employed a new method based on the use of an active contour model (Snake) [8], which adjusts its shape to the ILM contour. A predefined number of points are initialized on the uppermost part of the OCT scan. These points adapt its contour to the shape of the ILM by using information about the intensity of this layer in contrast to the rest of the layers. We designed an adapted version of the Snake, since we restrict its movement to the vertical axis, allowing only downwards movement. All the points of the Snake are moved progressively, approaching to the ILM layer. Finally, if a point does not modify its energy after an iteration, that point is fixed and is not processed again. With this method, the Snake behaves like a cascade of points instead of a contracting closed shape.

The Snake finally reaches the ROI (defined by the ILM position) to identify the ERM presence. In order to obtain relevant information from the ROI, a large set of heterogeneous features is obtained from each point of the Snake. These features are measured in the surrounding area of each point of interest. This area is defined as a rectangular window where \(W_{\hbox {size}}\) is the width in pixels of the window and the height is \(5 \times W_{\hbox {size}}\) (Fig. 1), offering enough information of the layer tissue with respect to its surrounding area.

Fig. 1.
figure 1

Example of Region of Interest definition. (a): Snake situated on top of the ILM and window around a point of the ROI. (b): Zoom on the feature window

2.2 Feature Definition

Using the properties of the ILM with and without ERM presence, we selected a complete set of intensity and texture-based features of the windows obtained around the points of interest to be able to separate precisely the points with ERM from the normal ILM tissue.

The number of features varies between 223 and 263. This variability is caused by the use of the input parameter \(N_{\hbox {bins}}\) of the window features, depicted below. The used features can be classified in the following groups:

 

Window Features. :

Each window obtained from the Snake is divided in five different square-shaped windows. Then, we calculate the histogram for each sub-window. The number of bins was empirically selected, so the resulting number of features obtained oscillates between 35 and 85, depending on the value of \(N_{\hbox {bins}}\). This parameter is used to determine the number of bins for the histograms associated to each window. We tested configurations from 7 to 17 bins (in increments of 2). For each point we have 5 different sub-windows with an associated histogram, so the total number of features range from \(5 \times 7 = 35\) to \(5 \times 17 = 85\).

Intensity Features. :

13 features are obtained with all the intensity information of the window: maximum, minimum, mean, median, standard deviation, variance, first quartile, third quartile, skewness and maximum likelihood estimate (for a normal distribution).

Gray-Level Intensity Histogram (GLIH). :

The histogram of the full window is calculated. From it, we obtain the following metrics: obliquity, kurtosis, energy and entropy.

Gray-Level Co-Ocurrence Matrix (GLCM). :

These features provide information about the spatial relationship of the pixels [15]. We use a distance of 2 pixels and 4 directions as proposed by Haralick et al. [6], for a total of 16 features.

Histogram of Oriented Gradients (HOG). :

Gradient orientation can be an useful feature, since it can contribute to the detection of the different patterns of gradients when the epiretinal membrane is found in contrast to its absence. Besides, HOG features are suitable to recognize gradient patterns in the ROI since they are invariant to scale, rotation or translation modifications. We used 9 HOG windows with 9 bins, obtaining a total of 81 features.

Local Binary Patterns (LBP). :

Local Binary Patterns also help to detect patterns of intensity changes in the selected window. Another advantage is their low sensitivity to intensity changes, since variation in illumination is usual in OCT images. We use a total of 64 features that will give a extended range of information.

2.3 Feature Selection and Classification

Once the feature set was specified, we proceeded with the analysis and selection of those most relevant features that contain meaningful data and provide the highest discriminative power. This way, we can optimize the classification process and obtain better results by avoiding the introduction of unneeded and redundant information to the classifiers.

Feature selection was performed using representative strategies. Correlation Feature Selection (CFS) algorithm [5], which works by selecting features correlated or predictive of the class that, otherwise, are irrelevant. Relief-F algorithm [9] is also used, consisting on the repeatedly sampling of a random instance and checking the distance to the nearest instances of the same or different class.

Finally, representative classifiers with proven utility in medical imaging applications were trained and tested using the selected feature subsets: K-Nearest Neighbor (kNN), Naive Bayes and Random Forest classifiers. For each classifier, we test three window sizes and six different number of bins for the window features mentioned beforehand.

3 Results and Discussion

The validation of the method was done by the use of a set of 129 OCT images. These scans were obtained with a tomograph CIRRUS\(^\mathrm{TM}\) HD-OCT Zeiss, with Spectral Domain Technology. The resolution of the scans was \(490 \times 500\) pixels without any preprocessing stage.

The scans were labeled by an expert clinician, identifying the areas where ERM is present and absent, respectively. With this groundtruth, we selected a set of 120 samples, divided in 60 samples with ERM presence and 60 with ERM absence. Furthermore, each group of samples can also be split in the following classes (Fig. 2):

  1. 1.

    Membrane class. Points with ERM presence on top of the ILM.

  2. 2.

    Floating membrane class. Points with ERM presence on the background.

  3. 3.

    Non-membrane class. Points situated on the first layer of the retina but without ERM presence.

  4. 4.

    Background class. Points not situated on the ILM layer, but on the background.

Fig. 2.
figure 2

Example of the different types of classes to be identified

This way, we have labeled datasets for two and four class approximations. We performed experiments facing both approximations to test the capabilities of the designed method. To evaluate the results, we use the accuracy of the classifiers as our control metric. Table 1a and b present the results obtained using the 2-class approximation. Results are very similar across all configurations, only obtaining a slight improvement with \(W_{\hbox {size}} = 17\) for the Random Forest classifier.

Table 1. 2-class classification accuracy results

Table 2a and b show the results for the 4-class approximation. In this case, the improvement in the performance is more accentuated when using CFS algorithm, both with kNN and Random Forest classifiers for \(W_{\hbox {size}} = 15\). Generally, the best accuracy is found for \(W_{\hbox {size}} = 15\), while \(N_{\hbox {bins}}\) is a parameter with more discrepancy. Normally, extreme values on this parameter decrease the overall accuracy of the classifier. The best results are obtained for the 4-class approach, both with kNN and Random Forest classifiers, reaching an accuracy of 93.89% when using CFS algorithm for feature selection and Random Forest. Random Forest algorithm obtains a slightly higher accuracy than the kNN method. 28 features were selected for this configuration.

Table 2. 4-class classification accuracy results

Regarding feature selection, we present the results using the 4-class approximation. The analysis and conclusions are analogous to the other 2-class approximation. About the selected features, Fig. 3 shows the ones provided by each selector in their best configuration, for a total of 28, grouped by type. The most relevant features that were provided by both strategies belong to the window features. More precisely, information about the first bins on the third sub-window (this is, the central sub-window, which is the one where the ERM should be located) were included in the first positions. As we can observe, these features are selected because the core of the class differentiation is done by the use of information of the center of the window (luminosity values indicate presence or absence of ERM). In a lower degree, it is also relevant the information about the fourth sub-window (the second from the bottom) and the fifth sub-window (the bottom one). This is congruent with the theory that the information under the central sub-window contributes to the differentiation between floating membrane and membrane classes, the first having lower intensity values on those windows than the membrane class. The rest of the selected features are mostly HOG values and a few features from the LBP group with the CFS selection, as they provide higher information about intensity and patterns on the ROI and contribute to improve the discrimination between the ERM presence or absence. On the contrary, this information is better represented by mainly GLCM features using the Relief-F selected subset.

Fig. 3.
figure 3

Number of selected features, of a total of 28, for each feature selector method

Fig. 4.
figure 4

Evolution of accuracy using Random Forest classifier and progressive larger feature subsets with the analyzed feature selectors

Figure 4 shows the accuracy of the classification stage with the most accurate configuration (Random Forest with \(W_{\hbox {size}} = 15\) and \(N_{\hbox {bins}} = 13\)) when using progressive larger subsets of features with both selector strategies. In almost all situations, CFS selector performs better than the Relief-F selector.

Fig. 5.
figure 5

Example of 4-class classification of an OCT image. Bright points represent the ERM on the ILM layer. Medium-intensity points symbolize ERM separated from the retina. Dark points show absence of epiretinal membrane

Fig. 6.
figure 6

Example of a region incorrectly identified and classified. Medium-intensity points on the right side symbolize background points, not contributing to the task at hand

Figure 5 presents a representative classification result of an OCT image using the most accurate configuration. As we can see, most of the points are classified correctly and the ERM presence is detected in almost all the ILM surface. Differentiation between the ERM with or without separation from the ILM is also done correctly. In contrast, Fig. 6 show a common incorrect classification on the right points of the image. In this case, the Snake algorithm cannot be locally adjusted to the lower zone of the retina, being penalized the final adjustment and the points get detected at background positions.

4 Conclusions

The accurate identification of the presence of the ERM is an important issue in the retinal analysis as its early detection improves the chances of success of ERM removal surgery, avoiding the complications that its presence derive.

In this work, we proposed an automatic method to detect the ERM in OCT images. The method is fully automatic, instead of the few previous approaches that are based on manual detections by the specialist. Furthermore, we have achieved a higher level of tolerance to errors by using a deformable model to detect the ROI compared to the detection of this region based on manual markers.

The method firstly uses a deformable model (Snake) to initially identify the ILM retinal layer, ROI where the ERM is originated. Then, a complete and heterogeneous set of features were measured, based on the properties of the ERM. Representative feature selectors as CFS and Relief-F were used with the entire feature set to identify those that provide the highest discriminative power.

We defined a set of 223–263 features that were then filtered by a process of feature selection, obtaining 28 features with the method that provided the most accuracy afterwards (CFS). Different suitable classifiers were tested, for a total of 216 different configurations. For testing, we used a set of 120 samples, distributed equally between the different classes in both two and four class approximations.

The results were highly successful, obtaining an accuracy of 93.89% for the CFS algorithm, with a Random Forest classifier with \(W_{\hbox {size}}\) of 15 and a \(N_{\hbox {bins}}\) of 13.

For further works, an increase in the number of samples for training is planned in order to improve even further the accuracy of the classifiers. Furthermore, wrapper-based feature selection methods will be tested as well as a larger variability of classifiers.