## 2 Data Description and Preprocessing
### Data Mile-Point Alignment  
Because of the effects of GPS accuracy, uncertain vehicle operating conditions, and complex human interference, there is an absolute error between the measured and actual mile-point values of track inspection data. Field surveys reveal that measured mile-point positions can be off by up to 200 m [49]. Even if the same inspection vehicle is used to detect the same section repeatedly, the mile-point values of each inspection may also be different. As for slab arching detection, multiple historical data will be compared to determine whether the damages have occurred and developed. Therefore, it is necessary to correct the mile-point error among multiple inspections firstly. In the normal service without major maintenance, the track geometry data among different inspections have similar waveforms. However, the wheels may slip or slide randomly during operation, thereby distorting the data waveforms in space (i.e., the mile-point deviation changes nonlinearly and randomly with the mileage) [50]. On account of this, we establish a mile-point alignment algorithm combining CA and DTW (CA-DTW). The specific process is as follows. 1. Sequence segmentation  
Firstly, an inspection sequence with high quality is selected as the reference sequence, and its absolute mile-point error is corrected according to infrastructure ledger information. Then, the reference sequence is divided into consecutive 100-m segments (\(X_{1}\), \(X_{2}\),...) by mileage. Through correlation-based and DTW-based alignment, each unaligned sequence can be matched with the reference sequence segment by segment. 2. CA-based initial alignment  
As shown in Figure 4, the matching window and \(X_{i}\) are of equal length (i.e., 100 m). Within \(X_{i}\)\(\pm\) 100 m, the window moves point by point on the unaligned sequence, to obtain different segments (\(Y_{i1}\),..., \(Y_{ip}\),..., \(Y_{in}\)) corresponding to \(X_{i}\). The correlation coefficient \(\rho\) between \(X_{i}\) and \(Y_{ip}\) can be calculated by Equation (1)  
\[\rho(X_{i},Y_{ip})=\frac{Cov(X_{i},Y_{ip})}{\sqrt{Var[X_{i}]Var[Y_{ip}]}} \tag{1}\]  
where \(Cov(\bullet)\) is the covariance between the sequences; \(Var[\bullet]\) is the variance of the sequence. According to the maximum \(\rho\) criterion, the initial aligned segment \(Y_{i}^{*}\) and deviation distance \(d\) can be determined. By shifting initial aligned segments, the initial aligned sequence can be obtained. 3. DTW-based secondary alignment  
DTW is a matching method for similar but warping sequences, which is essentially a dynamic programming problem [51]. It can search the optimal alignment relations between sequences efficiently and has been widely used to process series data [52; 53]. Considering the spatial distortion of inspection data, the initial aligned segment \(Y_{i}^{*}\) is locally scaled based on DTW so that the mileage offset can be further corrected. A dynamic program is established, taking the minimum sum of squared differences between \(Y_{i}^{*}\) and \(X_{i}\) as the goal. The objective function and constraints are as follows. Figure 4: Correlation-based initial alignment algorithm. \[D=\min\sum_{j=1}^{size(Y_{i}^{*})}\left(Y_{i}^{*}(j)-X_{i}(P(j))\right)^{2}+\zeta(j) \tag{2}\]  
\[\zeta(j)=\left\{ \begin{array}{ll}\alpha\times(\frac{M_{X_{i}}(P(j))-M_{X_{i}}( P(j-1))}{M_{Y_{i}}(j)-M_{Y_{i}}(j-1)}-1)^{2}&j\
eq 1,\alpha=3\\ 0&j=1\end{array} \right. \tag{3}\]  
\[s.t.\left\{ \begin{array}{ll}P(1)=1\\ P(size(Y_{i}^{*}))=size(X_{i})\\ -k+j\leq P(j)\leq k+j\leq size(Y_{i}^{*})\\ P(j-1)\leq P(j)\end{array} \right. \tag{4}\]  
where \(j\) is the point of \(Y_{i}^{*}\), \(P(j)\) is the point of \(X_{i}\) that matches \(j\), and \(size(\bullet)\) is the sample size of the segment. \(\zeta(j)\) denotes the distance loss, and \(M_{A}(\bullet)\) denotes the mileage coordinates of the point on sequence \(A\). The farther the mileage between \(P(j\)-1) and \(P(j)\), the higher the distance loss. \(k\) is the farthest distance between \(j\) and \(P(j)\) under consideration.