## 2 Methodology  
### Tunnel Axis Extraction via the Slice-based Method  
The tunnel axis determines the tunnel's position and orientation, and meanwhile reflects the distribution of the tunnel points in three-dimensional space. The tunnel axis is also a basis for extraction of a cross-sectional plane at a specific location because the tunnel's central axis needs to be orthogonal to all of the cross sections. To accurately extract the tunnel axis, in this paper, we introduce a slice-based method, which transforms the problem of extracting a three-dimensional tunnel axis into extracting a two-dimensional axis problem at two projected spaces, i.e., \(xy\)- and \(xz\)-planes. That is, we use two-axis equations in two-dimensional space to commonly represent the tunnel axis equation in three-dimensional space.  
To get the tunnel axis in the projected \(xy\)-plane, the projected point clouds are first divided into a series of slices at equal intervals along the direction of \(x\)-axis. In each slice, the minimum and maximum values on \(y\)-axis are determined. The mean point calculated by averaging the minimum and maximum points is regarded as an axis point within the corresponding slice. All of the mean points constitute the complete tunnels' axis points in the projected \(xy\)-plane. As shown in Figure 1a, the point clouds are partitioned into a series of slices by the dash lines at a given interval \(\delta\). The point \(\bar{p_{i}}\) is an estimated tunnel axis point calculated by averaging the points \(p_{i}^{max}\) and \(p_{i}^{min}\) within \(i\)-th slice. Using the above method, all of the points denoted in red are extracted, representing the final tunnel axis points in the projected \(xy\)-plane. Similarly, the tunnel axis' points are extracted from the projected \(xz\)-plane as evident in Figure 1b.  
It should be noted that the calculated axis points in the beginning and ending areas might deviate from the real position of a tunnel axis due to irregular shapes of the raw data. As these pseudo axis points indicated by red ovals in Figure 1 undoubtedly weaken the accuracy of the extracted tunnel axis, they are eliminated using a local curvature measure. After that, the axis points in the \(xy\)-plane are fitted by a fifth degree polynomial regression model, i.e., \(f_{xy}(x)=\sum_{i=0}^{n}a_{i}x^{i}\). Similarly, axis points in the \(xz\)-plane are fitted by a linear regression model, i.e., \(f_{xz}(x)=ax+b\) (see Section 2.2.3). Therefore, the tunnel axis in three-dimensional data space can be represented through joining these two models together:  
\[\mathcal{L}=\left\{\begin{array}{l}y=f_{xy}(x),\\ z=f_{xz}(x).\end{array}\right. \tag{1}\]  
Compared with the designed location of the tunnel axis, the height of the tunnel axis in the \(xz\)-plane has been raised and is usually higher than the theoretical (designed) value. This discrepancy is that, when we scan tunnel point clouds, the track laying has been finished, thereby raising the bottom of a tunnel. Their geometric relationships can be vividly shown in Figure 2, from which the extracted axis point \(o\) in red is higher than a center of real tunnel, denoted by a black point \(o^{\prime}\).