## 3 Methods
### Detection Model for Apparent Defects in Metro Tunnel Liniings  
#### 3.1.1 Basic Framework for Modeling the Defects Detection Model  
In an environment for detecting apparent defects in metro tunnel linings, the enclosed tunnel space limits the data transmission and reception rates. Additionally, the fixed tunnel space restricts the types of edge detection equipment that can be used. For metro tunnels in operation or under construction, the allowed maintenance window periods for inspection are also limited [22]. Therefore, the spatial environment and time conditions in actual detection scenarios impose high requirements on the selection of detection models. With the aim of adapting to the metro tunnel detection environment and conditions, the designed model should include the following features: (1) high defect-detection accuracy, with the ability to assign higher weights to high-incidence areas; (2) rapid model inference speed to meet real-time detection requirements while maintaining detection accuracy; and (3) a small model size that can be easily deployed on lightweight and portable edge devices. Figure 2: The technical framework of this paper. The fundamental model for detecting apparent defects in metro tunnel linings was selected on the basis of these three design principles and further optimized in subsequent research. In deep learning-based object detection models, algorithms can be categorized into two-stage and single-stage approaches based on the process of generating prediction boxes. The two-stage algorithms (such as Faster RCNN [23] and Cascade RCNN [24]) first generate a sparse set of candidate boxes, followed by regression on these candidate boxes and classification using a classifier. These methods typically offer higher detection accuracy but come with a larger number of model parameters and higher deployment costs. On the other hand, single-stage algorithms directly utilize convolutional layers to perform regression and classification predictions on pre-defined anchor boxes of different scales. While these methods are computationally more efficient and require fewer model parameters, their detection accuracy can still be further enhanced [25; 26]. The representative single-stage algorithms include SSD [27] and YOLO (You Only Look Once) [28; 29; 30]. Among these models, the YOLO series of algorithms were designed for fast and efficient target detection. Unlike traditional two-stage detection models, YOLO processes the entire image in a single pass through the network, directly performing both bounding box regression and classification tasks. This approach eliminates the need for complex region proposal steps, streamlining the detection process. The core principle of YOLO is to treat object detection as a regression problem. Specifically, YOLO divides the input image into a fixed number of grid cells, with each cell predicting one or more bounding boxes and their associated class labels. By combining data labels and utilizing the backpropagation algorithm, YOLO adjusts the model's weights during training, enabling the network to directly output the positions of bounding boxes and the categories of objects within those boxes at the final layer. Because the YOLO model simultaneously performs detection and classification in a single forward pass, it significantly increases detection speed. Additionally, YOLO's compact network structure maintains a smaller model size, which allows it to strike an excellent balance between accuracy, speed, and model size. This makes the YOLO series of algorithms particularly well-suited for scenarios requiring real-time detection. Among the YOLO algorithm versions, YOLOv8 [31; 32] is a state-of-the-art (SOTA) model in object detection, which advances and refines the capabilities of previous YOLO versions.