## 3 Thermal Image Segmentation and Classification  
### Design and Training of the Kohonen Self-Organizing Feature Map  
The Kohonen SOFM was used for the segmentation of the IRT images obtained with the thermal camera at a resolution of \(320\times 240\) pixels as described in Section 2.4. Each pixel was defined as a five-dimensional vector _P_\({}_{-i}\) (t) = {R,G,B,x,y}_, where R, G, and B represent the values of the color spectrum {_R,G,B_} = <0,255> and \(x\) and \(y\) represent the coordinates of each pixel where \(x\) = <0,320>_; \(y\) = <0,240>. The engine's temperature as evaluated and processed by the camera was not taken into account, since it may contain errors created by the camera compensating for environmental conditions and assigning different temperatures to a single color, thus confusing the classifier. In order to evaluate the technical state of the engine, the relative temperature-field displacement was used as it is holds the most important diagnostic information. The dynamic range of the camera was set in the interval <0,500> \({}^{\circ}\)C and was fixed. These parameters define the design of the SOFM. The pilot testing showed that these multi-dimensional vectors should be classified into five classes. As proposed in Section 2.2,  
Figure 12: The measured parameters of the iSTC-21v turbojet engine that are usable for infrared thermography-based diagnostics. a feature map with a single row is able to acceptably segment the IRT image, with low demands of computational time and complexity, which was one of the design goals. The classes are labeled as N\({}_{\text{i}}\) and represented by different colors as follows:  
* N\({}_{1}\): the hottest and most critical part of the IRT image, red. * N\({}_{2}\): a hot and critical part of the IRT image, yellow. * N\({}_{3}\): a hot and non-critical part of the IRT image, green. * N\({}_{4}\): a low-temperature and non-critical part, cyan. * N\({}_{5}\): the temperature of the surrounding objects (not a part of the diagnosed object), blue. The structure of the network can be visualized as shown in Figure 13. The training parameters which were found to be efficient were set as defined in Table 1, and the standard Kohonen network learning rule was used [42; 43]. A training dataset was prepared to train the network as follows. The engine was run for 120 s and thermal images were recorded at two frames per second, as the pilot experiments showed that this timing is sufficient since the dynamics of the temperature of the engine casing have a time constant of 1.2 s. The training sample therefore contained a set of 240 thermal images. The run of the engine, which was used to obtain the IRT images is shown in Figure 14. To demonstrate the ability of the trained Kohonen SOFM, five operational points are shown in Figure 14, where the network was tested if it produced sensible results. The first operational point, \(O_{p1}\), corresponds to the lowest evaluated rotational speed of the engine 42,058 rpm, and the last, \(O_{p5}\), corresponds to the highest rotational speed (i.e., 50,289 rpm). The classifications of the five example images are shown in Figure 15a, and the created segment areas are shown in Figure 15b. Following expert examination of the infrared images and heuristic evaluation of the temperature field, it can be concluded that the Kohonen network works as expected and is able to sensibly assign the hottest and coldest parts of the object to each of the five classes/segments. In order to quantify the results, the number of activations of each neuron are summed, giving the total segment areas \(S_{1}\),..., \(S_{5}\) corresponding to each of the classes \(N_{1}\),..., \(N_{5}\). This can be formalized as follows:  
\[S_{i}=\sum\
olimits_{j=1}^{p}x_{j};\ x\ =\ \{0;1\} \tag{5}\]  
where \(p\) is the number of activations of the \(i\)-th neuron.