# A Quantitative Detection Method for Surface Cracks on Slab Track Based on Infrared Thermography
## 2 Infrared-Thermogram Processing
### Non-Subsampled Contourlet Transform (NSCT)-Based Image-Enhancement Algorithm  
Key to the quantitative assessment of the surface cracks in track slabs is the quality of the infrared thermography of the rail track. In this regard, this section presents the image-enhancement and edge-detection methods used to process the original infrared thermography. The non-subsampled contourlet transform (NSCT)-based image-enhancement algorithm is used to transform the infrared thermogram from time domain to frequency domain, and modifies the frequency-domain coefficients at different levels. It can highlight the crack edges and details in the thermal image of the track-slab surface. The NSCT is characterized by multiple scales and directions, compared with traditional methods, such as wavelet transform, which are based on the scale correlation of transformation coefficients. It is composed of non-subsampled pyramid (NSP) and non-subsampled directional filter banks (NSDFB) [19]. During image decomposition, NSP decomposes the raw image into high-frequency and low-frequency components, and then NSDFB decomposes the high-frequency component into multiple band-pass directional sub-bands. The multi-scale and multi-directional decomposition principle of NSCT is shown in Figure 3. \begin{table}
\begin{tabular}{c c} \hline \hline
**Category** & **Value** \\ \hline Image resolution & 640 \(\times\) 480 (307,200 pixels) \\ Instantaneous field of view (IFOV) & 0.85 mRad \\ Field of view (FOV) w/standard 30 mm lens & 32.7\({}^{\circ}\)\(\times\) 24.0\({}^{\circ}\) \\ Frame rate (@ max. image resolution) & 30 and 9 Hz \\ Thermal sensitivity (NETD) & \textless{}0.04 \({}^{\circ}\)C at 30 \({}^{\circ}\)C target temp (40 mK) \\ Measurement range & \(-\)40 \({}^{\circ}\)C to 600 \({}^{\circ}\)C (\(-\)40 \({}^{\circ}\)F to 1112 \({}^{\circ}\)F) \\ Measurement accuracy & \(\pm\)2 K or \(\pm\)2\% \\ Photo & \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Key specifications of the IR camera (Fluke TIX620). Figure 2: Acquisition of the infrared thermography of slab track by IR camera: (**a**) experimental setup; (**b**) infrared thermography of slab track [5]. In the image-enhancement algorithm for infrared thermograms, it is necessary to select the appropriate threshold according to the transformation coefficient obtained from the original image after frequency-domain transformation. The threshold is used to distinguish the noise and effective edge details in the image, to avoid image distortion and the amplification of noise. In this paper, the threshold value is determined by the transformation coefficients at different scales and directions obtained from the original image after NSCT. The relationship between the threshold value and the standard deviation of the transformation coefficient is expressed as:  
\[T_{k}^{l}=\frac{1}{2}\sqrt{\frac{1}{MN}\sum_{m=1}^{M}\sum_{n=1}^{N}\left(W_{k} ^{l}f(m,n)-mean_{W_{k}^{l}}\right)^{2}} \tag{1}\]  
where \(T_{k}^{l}\) is the threshold value at the \(k\)-th directional sub-band of the \(l\)-th scale, \(W_{k}^{l}f(m,n)\) is the transformation coefficient at the \(k\)-th directional sub-band of the \(l\)-th scale at coordinates \((m,n)\), \(mean_{W_{k}^{l}}\) is the mean value of all transformation coefficients in the \(k\)-th directional sub-band on the \(l\)-th scale, \(M\)\(\times\)\(N\) is the size of the sub-band image. By using NSCT, the original image can be transformed to obtain transformation coefficients of multiple scales and directions. Next, the nonlinear enhancement function is adopted to modify the coefficients in the transformed domain. The enhancement function can be expressed as [19]:  
\[f(x)=a[\mathit{sigm}(c(x-b))-\mathit{sigm}(-\mathit{c}(x\ +b))] \tag{2}\]  
\[a\ =\ \frac{1}{\mathit{sigm}(c(1-b))-\mathit{sigm}(-\mathit{c}(1\ +b))} \tag{3}\]  
\[\mathit{sigm}(x)=\frac{1}{1+\mathit{e}^{-x}} \tag{4}\]  
where coefficient \(b\) controls the enhancement range, \(0<b<1\), \(c\) controls the enhancement intensity, and its variation range is \((20,50)\).