5.2 Features Extraction
5.2.2 Colour Histogram Generation without Optic Disc
To generate colour histograms with the optic disc pixels removed, identification and segmentation of the optic disc are required. There is a significant amount of reported work that has been conducted to identify the optic disc. The reported approaches tended to founded on four different mechanisms for locating the optic disc: (i) colour appearance [177], (ii) model fitting [123, 139], (iii) template based [140] and (iii) retinal blood vessels structure based [62, 211]. With respect to the work described in this chapter, an approach to localise the optic disc by projecting the 2-D retinal image onto two 1-D signals (representing the horizontal and vertical axis of the retinal image), similar to that proposed in [129] and [118] was adopted. This approach has been shown [129] to be fast and achieved a comparable accuracy to other approaches. The following sub-section describes the procedure employed to identify the optic disc.
5.2.2.1 The Optic Disc Segmentation and Removal
To identify the optic disc (OD detection), the numbers of horizontal and vertical edges together with the sum of the intensity value of a region in a retinal image were used as features. Figure 5.3 shows a block diagram of the optic disc localisation process. Details of the processing steps are given below [129]:
1. Generate horizontal and vertical edge images. This was conducted by applying a gradient operator [1 0 -1] and its transpose to the pre-processed green channel of imageI,Igreen, to generate the vertical,EV, and horizontal,EH, edge images of image Igreen. Note that the author in [129] used the original image to perform OD detection. In the context of the work described in this thesis pre-processed images were used so as to enhance the visibility of objects in the images (OD, blood vessels and pathologies). Green channel images were selected because they tend to display the highest contrast between the retinal objects (blood vessels, fovea and etc.) and the background [32, 158]. The generated horizontal and vertical edge images were of the same size as the initialIgreen image.
2. Compute “edge difference” and “sum” images. Both these images are also as the same size to theIgreen image. The edge difference image,Edif f, betweenEV and
EH, and the edge sum image, Esum, were calculated as follows:
Edif f =|EV| − |EH| (5.4)
Green channel image Generate 𝐸𝑉 and 𝐸𝐻 images Generate 𝐸𝑑𝑖𝑓𝑓 and 𝐸𝑠𝑢𝑚 images Project horizontal axis Project vertical axis Localise optic disc Segment and remove optic disc 𝐸𝑉 and 𝐸𝐻 images 𝐸𝑑𝑖𝑓𝑓 and 𝐸𝑠𝑢𝑚 images Horizontal axis projected Vertical axis projected Optic disc localised Optic disc segmented
3. Project the horizontal axis, Hprojection. The projection was carried out using a rectangle window of size $× image height centered at horizontal point x. Pa- rameter$is equivalent to twice of the thickness (in pixels) of the identified main retinal vessel. The resulting window was then slid over the Edif f and Igreen images from left to right and for each pointx the following was computed:
• Fhorz = sum of Edif f inside the window.
• Ghorz = sum of pixels intensities inside the window.
• Hprojection(x) =Fhorz/Ghorz.
The “peak” of the Hprojection indicates the candidate horizontal location of the optic disc,Hcand. Figure 5.4(a) and (b) show an example of a green channel image and its corresponding Hprojection and horizontal sliding window. Looking at the horizontal sliding window in Figure 5.4(a), a larger number of vertical edges and low horizontal edges occur in this area (the optic disc) than any other area on the image, thus representing the maximum value of Fhorz. With respect to the intensity value, a large number of retinal vessel pixels on the optic disc results in an average or low value ofGhorz. Thus, theHprojection has a maximum value at this location. From the figure,Hcand is identified at locationxi on the X-axis.
4. Project the vertical axis, Vprojection. The projection was conducted in a similar manner to that described for the horizontal axis. A rectangular window of size
ϕ×ϕ, where ϕ is the optic disc diameter, centred at horizontal line Hcand was defined. This window was then slid over theEsum andIgreen images individually from top to bottom. Then for each vertical locationythe following was computed:
• Fvert = sum ofEsum inside the window.
• Gvert= sum of pixel intensities inside the window.
• Vprojection(y) =Fvert×Gvert.
The “peak” of theVprojectionrepresents the candidate vertical location of the optic disc, Vcand. Figure 5.5(a) shows an example of the Vprojection and the vertical sliding window. The bright region in the image in Figure 5.5(b) is where the vertical sliding window scanned the image from top to bottom. The optic disc contains a large number of vertical and horizontal edges, as well as producing the maximum sum of the intensity values (as most of the bright pixels occur in this area). This then defines the peak of the Vprojection. As shown in the figure, the projection peak,Vcand, is located at pointyi on the Y-axis.
5. Identify the central location of the optic disc. The centre of the optic disc,
ODcentre, is located at the image point (xi, yi). Figure 5.6(a) shows an exam- ple of retinal image with the optic disc localised (the centre of the optic disc is
Sliding direction
𝑥𝑖 (a)
(b)
𝑥𝑖
Figure 5.4: Example of horizontal axis projection: (a) green channel image, (b) the projected horizontal axis
Sliding direction
𝒚𝒊
(a) (b)
𝒚𝒊
Figure 5.5: Example of vertical axis projection: (a) the projected vertical axis, (b) green channel image with vertical sliding window
marked with white coloured ‘+’). For illustrative purposes the retinal image in Figure 5.6(a) was deliberately darkened so as to enhance the visibility of the optic disc centre mark.
+
(a) (b)
Figure 5.6: Example of retinal image with the optic disc: (a) localised and (b) seg- mented and removed
6. Segment and remove the optic disc. Once the centre of the optic disc was localised, the optic disc location could be estimated using a template with a prescribed radius, ρ, whose value was dependent on the image size (see Figure 5.6(b)). A circular optic disc boundary was thus drawn centred on ODcentre with radius ρ, and the pixel values within this boundary replaces with null values (indicated by the white circle in Figure 5.6(b)).
Figure 5.7: The spatial-colour histogram image partitioning process
Note that the dark background was excluded from the optic disc localisation process. Once the optic disc was identified and removed, the generation of colour histograms without the optic disc information and time series normalisation were conducted using a similar method to that described in Sub-section 5.2.1.