Bridge bottom surface crack detection method and system based on unmanned aerial vehicle and ai
By using GAN parameterized synthesis of labeled samples and improving U-Net to fuse CNN and Transformer, combined with an edge-cloud collaborative architecture and bridge BIM model, the problems of low efficiency and high safety risk in traditional bridge bottom crack detection are solved, achieving efficient and comprehensive bridge bottom crack detection and standardized assessment.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- 临朐县公路事业发展中心
- Filing Date
- 2026-03-06
- Publication Date
- 2026-06-23
AI Technical Summary
Traditional bridge underside crack detection relies on manual inspection, which is inefficient and poses high safety risks. Existing drone inspection lacks environmental adaptability, data validity, annotation costs, model fusion capabilities, and positioning accuracy. The assessment reports are also non-standard, making it difficult to achieve full coverage and accurate assessment.
We employ GAN parameterization to synthesize labeled samples, optimize the labeling process through weakly supervised learning, improve U-Net by integrating CNN and Transformer, construct an edge-cloud collaborative architecture, combine bridge BIM models for path planning and positioning, and build a two-dimensional and three-dimensional quantization system to achieve efficient and full-coverage crack detection.
It significantly improves the accuracy of identifying minute cracks, reduces the cost of manual annotation, achieves efficient and full-coverage detection of cracks on the bottom of bridges, generates standardized evaluation reports, and provides reliable data support for bridge maintenance.
Smart Images

Figure CN122265877A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the technical field of bridge bottom surface crack detection methods, and particularly relates to a bridge bottom surface crack detection method and system based on drones and AI. Background Technology
[0002] As a critical load-bearing component of bridge structures, the early and accurate detection of cracks on the bridge underside is crucial for ensuring the bridge's safe operation. Traditional methods for detecting cracks on bridge undersides often rely on manual climbing or scaffolding, which is not only labor-intensive and inefficient but also poses safety risks such as falls from heights. This is especially true for long-span, high-pier bridges, where manual inspection has poor accessibility and cannot cover all critical areas, easily leading to missed or misdiagnosed cracks. Although drones equipped with cameras have been introduced for image acquisition in some inspection scenarios, current applications are mostly limited to simple image recording. They lack comprehensive adaptation to the acquisition environment (lighting, angle), crack morphology (small, intersecting, network), and background interference (stains, water stains), resulting in insufficient validity and diversity of the collected data, making it difficult to support subsequent accurate analysis.
[0003] In the intelligent processing stage of crack detection, existing technologies face multiple bottlenecks: On the one hand, it is difficult to construct high-quality labeled datasets. The collection of natural crack samples is limited by the distribution of bridges and the development stage of the disease, resulting in a limited sample coverage. Moreover, manual labeling is costly and inefficient, making it difficult to meet the needs of model training for massive and diverse samples. On the other hand, the image preprocessing effect is not good. Images collected from the bottom of bridges are often affected by uneven lighting, tilted shooting angles, and surface noise interference. Existing denoising and lighting correction algorithms are difficult to effectively eliminate interference while preserving crack details. Furthermore, traditional detection models mostly rely on CNN or Transformer architectures, which are insufficient in their ability to fuse local texture details and global structural features of cracks, resulting in low recognition accuracy for small cracks and blurred cracks.
[0004] Furthermore, the collaborative and quantitative assessment capabilities of existing detection systems need improvement: they lack an efficient architecture for three-level collaboration between the edge, cloud, and terminal; the linkage between drone data acquisition, data processing, and flight attitude adjustment is poor, making it difficult to achieve real-time verification and accurate re-photographing of suspected cracks; in areas where GPS signals are blocked on the bridge underside, the stability of the positioning system is insufficient, resulting in low mapping accuracy between crack locations and the bridge BIM model; crack quantification is mostly limited to two-dimensional length and width measurements, and the methods for obtaining parameters such as three-dimensional depth and spatial distribution are complex and have limited accuracy; damage level assessment lacks a dynamic correlation model with quantitative parameters; and the standardization and practicality of assessment reports are insufficient, making it difficult to directly support bridge maintenance decisions. Summary of the Invention
[0005] In view of the aforementioned problems, and in conjunction with the first aspect of the present invention, embodiments of the present invention provide a method for detecting cracks on the underside of bridges based on unmanned aerial vehicles (UAVs) and AI, the method comprising:
[0006] A basic dataset is constructed by collecting various bridge underside images. Annotated samples are synthesized using GAN parameterization to supplement the data. The annotation process is optimized by combining weakly supervised learning with active learning.
[0007] The preprocessing stage optimizes the image using multi-scale denoising, illumination normalization, and angle correction, based on an improved U-Net fusion of CNN and Transformer;
[0008] A two-dimensional and three-dimensional quantization system is constructed. In the two-dimensional system, the length and width of the crack are measured by sub-pixel segmentation, skeleton extraction and minimum bounding rectangle, and gray-level gradient method. In the three-dimensional system, the point cloud is reconstructed by SFM and stereo matching, and the depth is calculated by mapping the two-dimensional crack. A mapping model between quantization parameters and damage level is established, and a standardized assessment report is output.
[0009] A three-tier collaborative architecture is built, including lightweight AI on the drone side to identify suspected cracks, high-precision verification and feedback at the edge, and the flight control system adjusting attitude and reshooting based on the feedback.
[0010] Import the bridge BIM model preset path, and dynamically adjust the path priority in flight by combining visual perception and crack heat map. Ensure effective data collection in the whole area through multi-objective optimization and local replanning.
[0011] A fusion positioning system integrating visual SLAM, IMU, and reference markers was constructed. The pose of the UAV in the GPS failure zone was calculated and optimized by filtering. The cracks were mapped to the BIM model through coordinate association.
[0012] Furthermore, embodiments of the present invention also provide a bridge underside crack detection system based on drones and AI, characterized in that it includes:
[0013] A processor; a machine-readable storage medium for storing machine-executable instructions of the processor; wherein the processor is configured to execute the aforementioned method for detecting cracks on the underside of bridges based on drones and AI by executing the machine-executable instructions.
[0014] In another aspect, embodiments of the present invention also provide a computer program product, the computer program product including machine-executable instructions, the machine-executable instructions being stored in a computer-readable storage medium, the processor of a computer device reading the machine-executable instructions from the computer-readable storage medium, the processor executing the machine-executable instructions, causing the computer device to execute the above-described method for detecting cracks on the underside of bridges based on drones and AI.
[0015] Based on the above, the improved StyleGAN2 model effectively overcomes the bottlenecks of scarce samples and high annotation costs in traditional bridge crack detection by optimizing the annotation process through GAN parameterized synthesis and weakly supervised-active learning. The improved model can generate diverse and highly realistic synthetic samples, supplementing the coverage gaps in real datasets. The iterative mechanism of weakly supervised and active learning significantly reduces the workload of manual annotation while improving the quality of annotated data. Based on the improved U-Net feature extraction architecture that integrates CNN and Transformer, it retains the accurate capture capability of CNN for local crack textures and edge details while strengthening the correlation learning of global structural features through Transformer. This significantly improves the recognition accuracy of small cracks, blurred cracks, and cracks in complex backgrounds, solving the problem of one-sided feature extraction in traditional models.
[0016] By leveraging a three-tiered collaborative architecture and dynamic path planning mechanism, this invention achieves highly efficient and comprehensive detection of cracks on the underside of bridges. A lightweight AI model on the drone side quickly identifies suspected cracks, while the edge side verifies them with high precision and provides real-time feedback on re-shooting commands. The flight control system dynamically adjusts its attitude to complete accurate re-shooting, forming a closed-loop collaboration of acquisition, identification, verification, and re-shooting, significantly reducing the invalid acquisition rate. Combining the bridge BIM model's preset path with dynamic priority adjustment based on crack heatmaps, multi-objective optimization and local replanning ensure that no key areas under complex bridge structures are missed. Compared to traditional manual inspection and single drone acquisition, the detection efficiency is improved several times, and the risks of high-altitude operations are effectively avoided.
[0017] This invention constructs a two-dimensional-three-dimensional quantification system and a fusion positioning and mapping mechanism, achieving a leap from qualitative identification to quantitative assessment in crack detection. Sub-pixel segmentation and point cloud reconstruction technologies accurately quantify multi-dimensional parameters such as crack length, width, depth, and spatial distribution. The damage level mapping model, combined with a dynamic calibration mechanism, ensures the objectivity and accuracy of the assessment results. The fusion positioning system of visual SLAM, IMU, and benchmark markers can still stably output high-precision UAV pose even in GPS-deficient areas, achieving accurate mapping of crack features to the BIM model. The generated standardized assessment report includes quantitative parameters, risk analysis, and treatment recommendations, providing comprehensive and reliable data support for bridge maintenance decisions and significantly improving the scientific level of bridge defect management. Attached Figure Description
[0018] Figure 1 This is a schematic diagram of the execution flow of the bridge bottom surface crack detection method based on UAV and AI provided in an embodiment of the present invention.
[0019] Figure 2 This is a schematic diagram of exemplary hardware and software components of the bridge underside crack detection system based on UAV and AI provided in an embodiment of the present invention. Detailed Implementation
[0020] The present invention will now be described in detail with reference to the accompanying drawings. Figure 1 This is a flowchart illustrating a method for detecting cracks on the bottom surface of a bridge based on drones and AI, according to an embodiment of the present invention. The following is a detailed description of this method for detecting cracks on the bottom surface of a bridge based on drones and AI.
[0021] Step S110: Collect various bridge bottom surface images to construct a basic dataset, supplement the data by synthesizing labeled samples through GAN parameterization, and optimize the labeling process by combining weakly supervised learning with active learning.
[0022] This step involves first covering mainstream bridge types such as beam bridges, arch bridges, and cable-stayed bridges, collecting bridge bottom images according to service life of 1-5 years, 6-15 years, and over 15 years, and the stages of micro, medium, and macroscopic crack damage, and then filtering them to form a basic dataset. Next, a GAN model is built based on StyleGAN2, and a parameterized control module is designed to generate diverse synthetic samples. High-quality samples are selected using the FID index and automatically labeled. Then, synthetic samples are mixed with real samples to construct a training set. No more than 30% of the samples are manually fine-labeled as seed data, and a weakly supervised segmentation model is built for pre-training. Initial pseudo-labels are generated for unlabeled data, and high-confidence pseudo-labels are selected and included in the labeling pool after a confidence threshold is used. Self-supervised pre-training is used to optimize the model and iteratively update the pseudo-labels. High-value samples are selected for manual labeling based on uncertainty and diversity sampling, supplemented to the seed data, and the model is retrained. This process is repeated until the model performance improvement is below a preset threshold, ultimately forming a high-quality labeled dataset. This process significantly reduces the cost of manual labeling and improves labeling efficiency.
[0023] Step S111: Determine the coverage area of bridge types, plan the bottom surface inspection area for bridges with different service years and disease development stages, clarify the crack morphology and interference sample types to be collected, select a drone equipped with a high-definition camera and macro lens and set reasonable flight parameters, record the lighting, shooting angle and environmental parameters simultaneously during the collection process, perform distortion correction, cropping, grayscale stretching and invalid image screening on the original images to form a basic dataset.
[0024] In this step, the bridge type is first determined, covering reinforced concrete beam bridges, prestressed concrete arch bridges, and steel-concrete composite cable-stayed bridges, etc. Based on service life, they are divided into initial service (≤5 years), medium service (6-15 years), and long service (≥16 years). The disease stage covers micro, medium, and macro cracks. Simultaneously, the types of interfering samples to be collected, such as stains, water stains, and formwork seams, are identified. A multi-rotor drone equipped with a 20-megapixel high-definition industrial camera and a 10x macro lens is selected, with the flight altitude set at 3-8m, flight speed at 1-2m / s, and filming... For flight parameters with an overlap rate of ≥70%, environmental parameters such as light intensity and shooting angle are recorded synchronously by sensors on the UAV during data acquisition. The original images are calibrated using the Zhang Zhengyou calibration method for distortion correction, cropped to 800×800 pixels, and contrast is enhanced by linear grayscale stretching. Combined with image sharpness algorithms and manual screening, invalid images that are blurry, overexposed, or underexposed are removed. The selected images are classified and stored according to bridge type, service life, and crack type, ultimately forming a basic dataset with a sample size of no less than 10,000 images.
[0025] Step S112: Select the StyleGAN2 architecture to build a crack generation model, optimize the generator and discriminator structure, complete pre-training based on the basic dataset, enable the model to learn the feature patterns of real cracks and interference samples, design a parameterized control module, set adjustable parameter dimensions related to crack geometry, acquisition environment, and background interference, and support the generation of diverse samples.
[0026] In this step, a crack generation model was first built based on the open-source StyleGAN2 framework. The network structures of the generator and discriminator were optimized in a targeted manner. Background interference features were incorporated into the generator, and texture perception and interference feature discrimination branches were added to the discriminator. Then, a training framework was built, adding crack feature constraint loss and interference sample fusion loss. The AdamW optimizer was selected and configured with a cosine annealing adaptive learning rate decay strategy. The batch training size was set to 32 according to the hardware computing power. Using the basic dataset as the training set, a cold start training of 50 epochs was completed with a low learning rate of 1e-5, and then formal pre-training was performed for 200 epochs at 1e-4. The loss function and the generated image effect were monitored in real time. After the adversarial loss was stabilized, targeted fine-tuning was performed for difficult-to-identify samples such as micro-cracks and cross cracks. At the same time, a parameterized control module with three sub-modules was designed to complete the linkage adaptation with the generator. Single-parameter and multi-parameter combination verification was carried out, and the module weights and generator parameters were adjusted so that the model could generate crack samples with different features and the FID value of the generated samples was controlled below 30.
[0027] Step S1121: Optimize the StyleGAN2 generator structure. On the basis of the original architecture, introduce a multi-level multi-scale convolution module, adjust the generator upsampling module to the form of transposed convolution combined with pixel shuffling, fuse the background interference sample features of the bridge bottom surface in the generator feature extraction layer, and adapt the generator output layer to the channel format of the bridge detection image.
[0028] In this step, based on the original StyleGAN2 generator architecture, a three-level multi-scale convolution module is introduced with kernel sizes of 3×3, 5×5, and 7×7 to achieve multi-scale crack feature extraction. The generator upsampling module is replaced with a transposed convolution combined with pixel shuffling, with the transposed convolution stride set to 2 and the pixel shuffling factor set to 2 to improve the texture clarity of the upsampled image. In the 4th and 5th feature extraction layers of the generator, feature vectors of background interference samples such as concrete texture, stains, and water stains on the bridge bottom are incorporated, with the feature fusion weight set to 0.3 to make the generated samples more consistent with the actual detection scenario. The number of channels in the generator output layer is adapted from 3 channels to the single-channel grayscale image format commonly used in bridge detection, and the output image resolution is fixed at 800×800 pixels. The convolution weights of each layer of the generator are initialized with a He normal distribution to avoid gradient vanishing or exploding problems during training. The optimized generator can effectively learn the fusion features of real cracks and background interference, improving the realism of the generated samples.
[0029] Step S1122: Optimize the StyleGAN2 discriminator structure by adding a texture perception branch and an interference feature discrimination branch to the basic discriminator architecture. The texture perception branch extracts local features of cracks through shallow small convolutional kernels, and the interference feature discrimination branch identifies the naturalness of background interference fusion. A multi-scale downsampling module is added to the discriminator, and spectral normalization technology is adopted at the same time.
[0030] In this step, in addition to the basic StyleGAN2 discriminator architecture, a texture perception branch and an interference feature discrimination branch are added. The texture perception branch consists of three shallow 3×3 small convolutional kernels with a stride of 1 and padding of 1, specifically for extracting local subtle features such as crack edges and textures. The interference feature discrimination branch consists of two 5×5 convolutional kernels, used to identify the naturalness of the fusion between background interference and cracks, and to distinguish the differences in interference features between real and synthetic samples. A four-level multi-scale downsampling module is added to the discriminator, using 2×2 average pooling with a stride of 2 to achieve multi-scale feature discrimination. Spectral normalization is applied to all convolutional layers of the discriminator, and the Lipschitz constant is set to 1 to prevent overfitting during discriminator training. The output features of the three branches are concatenated and mapped to a one-dimensional discrimination result through a fully connected layer. The discriminator activation function is LeakyReLU with a slope of 0.2 to improve nonlinear expression. The optimized discriminator can achieve an accuracy of over 95% in identifying the authenticity of synthetic samples, effectively guiding the training and optimization of the generator.
[0031] Step S1123: Build the model training framework, add crack feature constraint loss and interference sample fusion loss on the basis of the original adversarial loss and style loss, select AdamW optimizer and configure adaptive learning rate decay strategy, and set batch training scale to adapt to hardware computing power.
[0032] In this step, in addition to the existing adversarial loss and style loss in StyleGAN2, two new losses are added: crack feature constraint loss and interference sample fusion loss. The crack feature constraint loss uses mean squared error loss with a weight of 0.4 to ensure that the geometric features of the generated cracks are consistent with the real samples. The interference sample fusion loss uses cross-entropy loss with a weight of 0.2 to ensure that the fusion effect between the background interference and the cracks is realistic. The weights of the adversarial loss and style loss are set to 0.3 and 0.1, respectively. The optimizer used is AdamW with weight decay coefficients of 1e-4, β1=0.9, and β... =2=0.999, configured with a cosine annealing adaptive learning rate decay strategy, initial learning rate 1e-4, decaying to 0.5 every 50 epochs, minimum 1e-6; distributed training based on 4 NVIDIA A100 graphics cards, batch training size 32, single card batch size 8, training framework based on PyTorch, using mixed precision training mode; data augmentation of training samples by random rotation, translation, and scaling, loading data to GPU memory to improve training efficiency, real-time monitoring of the convergence of each loss function during training to ensure stable model training.
[0033] Step S1124: Based on the basic dataset of cracks on the bottom of bridges, conduct model pre-training. First, use a low learning rate for cold start training, then enter the formal pre-training stage and monitor the visual effect of the generated images and the convergence status of the loss function in real time. When the adversarial loss tends to be stable and the generated images have no obvious morphological distortion, perform targeted fine-tuning training for difficult-to-identify crack samples until the model can stably generate crack images that conform to the real feature rules.
[0034] In this step, the basic dataset of bridge bottom cracks is divided into training and validation sets in a 9:1 ratio. A cold start training of 50 epochs is conducted with a low learning rate of 1e-5, updating only the shallow network parameters of the generator to avoid excessive initial parameter fluctuations. After the cold start, the learning rate is adjusted to 1e-4 for 200 epochs of formal pre-training. TensorBoard is used to monitor the convergence status of various loss functions and the visual effect of generated images in real time, saving the model weights every 10 epochs. Formal pre-training is stopped when the adversarial loss fluctuates ≤0.05 within 20 consecutive epochs, and the generated images show no morphological distortion or unnatural texture. A fine-tuning dataset of 2000 images is constructed using difficult-to-identify samples such as micro-cracks and intersecting cracks, and 50 epochs of targeted fine-tuning are conducted with a learning rate of 5e-5, focusing on updating the parameters of the generator's deep feature extraction layer. Pre-training is completed when the model can stably generate crack samples that conform to real-world feature patterns, and the validation set FID value is consistently below 30.
[0035] Step S1125: Design the overall architecture of the parameterized control module. This module is used as the front control unit of the generator and seamlessly connected with the generator input layer. It is divided into three independent parameter sub-modules: crack geometry, acquisition environment, and background interference. A parameter mapping layer is designed within the module to convert manually set parameter values into feature vectors that the generator can recognize.
[0036] In this step, the parameterized control module is designed as the pre-control unit of the StyleGAN2 generator. It seamlessly connects to the generator's input layer through a fully connected layer. The module's input is manually set parameter values, and the output is a 256-dimensional feature vector, consistent with the generator's original random noise vector dimension. The module is divided into three independent parameter sub-modules: crack geometry, acquisition environment, and background interference. Each sub-module consists of two fully connected layers with ReLU activation function. A parameter mapping layer is designed within each sub-module, using a linear mapping method to transform manually set continuous or discrete parameter values into normalized feature vectors in the range [-1,1], adapting to the generator's input requirements. Corresponding weight matrices are set for the parameter mapping layer: 256×8 for the crack geometry sub-module, 256×6 for the acquisition environment, and 256×5 for the background interference. The module is built on PyTorch and shares training hardware with the generator. The weights of the parameter mapping layer are updated synchronously during the model pre-training stage to ensure the linkage between the module and the generator.
[0037] Step S1126: Set the adjustable parameters and action mechanisms for the three parameter sub-modules respectively. The crack geometry parameter sub-module controls the crack geometry features. The acquisition environment parameter sub-module simulates the acquisition environment changes of the generated image by adjusting the corresponding feature layer of the generator. The background interference parameter sub-module controls the background interference feature performance. All parameters in each dimension support gradient adjustment.
[0038] In this step, eight adjustable parameters are set for the crack geometry parameter submodule, including crack length, width, and orientation angle. Each parameter supports gradient adjustment in increments of 0.1. By adjusting the generator's geometric feature layer parameters, the geometric shape of the generated crack can be precisely controlled. Six adjustable parameters are set for the acquisition environment parameter submodule, including light intensity, shooting angle, and shooting distance. Light intensity can be adjusted from 0-1000 lux, and the shooting angle from 0-90°. By adjusting the generator's environment feature layer parameters, image effects under different acquisition environments can be simulated. Five adjustable parameters are set for the background interference parameter submodule, including stain area, water stain concentration, and template seam width. Each parameter supports gradient adjustment in increments of 0.05. By adjusting the generator's interference feature layer parameters, the characteristic performance of background interference can be controlled. All parameters are manually set through a visual interface. The set values are converted into feature vectors by the parameter mapping layer and then input into the generator, enabling precise control of the generated sample features to meet diverse sample generation needs.
[0039] Step S1127: Implement the linkage adaptation between the parameterized control module and the StyleGAN2 generator. The feature vector output by the parameterized control module is fused with the original random noise vector of the generator as the joint input of the generator. The parameter combination adjustment logic that supports single-parameter independent gradient adjustment and multi-parameter random combination adjustment is designed, and a parameter validity verification mechanism is added.
[0040] In this step, the 256-dimensional feature vector output by the parameterized control module is element-wise added to and fused with the generator's original 256-dimensional random noise vector, with all fusion weights set to 0.5, serving as the generator's joint input. A parameter combination adjustment logic is designed, supporting independent gradient adjustment of single parameters and random combination adjustment of multiple parameters. When adjusting a single parameter, only the weights of the corresponding submodule parameter mapping layer are updated; when adjusting multiple parameters, the weights of multiple submodules are updated simultaneously, and the saving and recall of parameter combinations are supported. A parameter validity verification mechanism is added to the module, setting reasonable value ranges for each parameter. If the set value exceeds the range, the system automatically prompts and corrects it to the critical value, while simultaneously normalizing the fused feature vector. During the generator's forward propagation, a linkage monitoring interface between parameters and the feature layer is added to provide real-time feedback on the impact of each parameter on the corresponding feature layer of the generator, facilitating subsequent model optimization. After linkage adaptation, the model can quickly generate crack samples that meet the requirements based on the parameter settings.
[0041] Step S1128: Conduct parameterized control function verification and overall model optimization. First, perform single-parameter adjustment verification, and then perform multi-parameter combination verification. For the problems that occur during the verification process, adjust the weight coefficients of the parameter mapping layer and the network parameters of the corresponding feature layer of the generator to complete the overall model optimization.
[0042] In this step, single-parameter adjustment verification is first performed. Gradient adjustments are made to each adjustable parameter of the three sub-modules in turn, changing only one parameter at a time and generating corresponding samples. The control effect of parameter adjustment on sample features is evaluated. If the parameter adjustment does not match the changes in sample features, the weight coefficients of the corresponding parameter mapping layer are adjusted immediately. After the single-parameter verification is passed, multi-parameter combination verification is performed. Parameter combinations of different sub-modules are randomly selected for adjustment to generate diverse samples. The sample quality is evaluated using a combination of FID index and human visual evaluation, requiring an FID value ≤ 30 and a human visual evaluation pass rate ≥ 90%. If feature fusion distortion occurs, the network parameters of the corresponding feature layer of the generator are adjusted. For problems such as low precision in crack geometry control and unnatural background interference fusion found in the verification, the learning rate is fine-tuned by 1e-5. The weight coefficients of the parameter mapping layer and the parameters of the generator convolution and fully connected layers are fine-tuned one by one. After fine-tuning, the verification is repeated until all parameter adjustment effects meet expectations and the quality and controllability of the generated samples reach the optimal level, completing the overall model optimization.
[0043] Step S113: Start batch synthetic image generation, generate samples by random combination of parameters, automatically complete crack annotation using generated parameters, evaluate the quality of synthetic data using FID index, screen high-quality samples that are similar to the distribution of real data, and remove invalid samples with distorted shape and unnatural texture.
[0044] In this step, random sampling and combination are performed based on the reasonable value range of each parameter in the parameterized control module. Batch generation of 1000 synthetic crack images is initiated, automatically generating pixel-level crack annotations using geometric and positional parameters generated during the generation process, without manual intervention. The FID (Firmware ID) metric is used to evaluate the quality of the synthetic data. The feature distributions of the real base dataset and the synthetic samples are input into the pre-trained Inception-v3 model to calculate the FID value. An FID ≤ 30 is set as the threshold for high-quality samples, and samples meeting the threshold are selected. Simultaneously, invalid samples with morphological distortion, blurred texture, or unnatural background interference are removed through visual verification. The selected high-quality synthetic samples are classified and stored according to crack type and interference features, providing data support for subsequent training set construction.
[0045] Step S114: Mix the selected synthetic samples with the real base dataset in proportion to construct a mixed training set, and perform manual fine annotation on some samples in the mixed training set as seed annotation data for weakly supervised learning.
[0046] In this step, the selected synthetic samples are mixed with the real base dataset at a 7:3 ratio to construct a hybrid training set that balances realism and diversity. The data is stratified by bridge type, service life, and crack development stage to ensure uniform distribution. Stratified sampling is used to select 25% of the samples in the hybrid training set for meticulous manual annotation. Professional pixel-level annotation tools are used to outline the crack contours, and double-person cross-validation is performed during the annotation process to remove samples with annotation errors exceeding 5%. The validated annotated samples are used as seed annotation data for weakly supervised learning. A unique association index between the sample and the annotation file is established, and the data is packaged and stored in TFRecord format. The data also records the sample's acquisition environment, crack characteristics, and other attribute information to meet the data reading requirements of model training.
[0047] Step S115: Select a lightweight backbone network combined with a fully convolutional network to construct a weakly supervised segmentation model, complete pre-training with seed labeled data, use the pre-trained model to infer and generate initial pseudo-labels for unlabeled data, set a confidence threshold to filter high-confidence pseudo-labels and include them in the labeling pool.
[0048] In this step, MobileNetV3 was selected as the lightweight backbone network, and a weakly supervised segmentation model was built by combining it with a fully convolutional network. The input layer was adapted to the 800×800 bridge underside image size. The seed labeled data was divided into training and validation sets in an 8:2 ratio. The model was pre-trained for 50 epochs using the cross-entropy loss function, with the Adam optimizer configured and an initial learning rate of 1e-4. After pre-training, the model was used to infer the unlabeled data in the mixed training set to generate pixel-level initial pseudo-labels. A confidence threshold of 0.85 was set, and pseudo-labels with confidence scores higher than the threshold were included in the label pool. The labeled pool data was deduplicated and outlier filtered to remove duplicate samples and samples with distorted pseudo-label contours, ensuring the effectiveness of the labeled pool data.
[0049] Step S116: Optimize the model using a self-supervised pre-training strategy, learn the crack invariance features of the model through various data augmentation methods, regenerate pseudo labels based on the optimized model, iteratively update the label pool and remove low-quality pseudo labels, design an active learning sampling strategy, combine uncertainty sampling and diversity sampling to screen high-value samples, and submit them for manual fine labeling to supplement the seed label data.
[0050] In this step, a self-supervised pre-training strategy using contrastive learning is employed to optimize the model. Various data augmentations are performed on the samples, including random rotation, flipping, brightness adjustment, and noise addition, allowing the model to learn the scale and illumination invariance characteristics of cracks. Based on the optimized model, pseudo-labels are regenerated for unlabeled data. Low-quality pseudo-labels with a confidence level below 0.8 are removed from the labeling pool, completing the iterative update of the labeling pool. An active learning sampling strategy is designed, using entropy-based uncertainty sampling to filter samples difficult for the model to identify, combined with K-means clustering diversity sampling to ensure sample coverage. Each round selects 200 high-value unlabeled samples, which are then manually fine-labeled and added to the seed labeling data, enriching the sample types and feature coverage of the seed data.
[0051] Step S117: Retrain the weakly supervised model with the updated seed labeled data, repeat the process of pseudo-label generation, high-value sample screening, manual labeling and model iteration, evaluate the model performance after each iteration, and stop the iteration when the performance improvement is lower than the preset threshold, and finally form a complete high-quality labeled dataset.
[0052] In this step, the weakly supervised segmentation model is retrained using the updated seed-labeled data, with training parameters consistent with the pre-training parameters. After each iteration, mIoU, precision, and recall are used as evaluation metrics to test the model's performance on the validation set. A stopping threshold is set for performance improvement ≤1%. If the model's performance improvement is below this threshold for two consecutive iterations, the iteration is terminated. During the iteration process, a closed-loop operation is continuously performed, including pseudo-label generation, high-value sample screening, manual annotation, and seed data supplementation, removing low-quality pseudo-labels from the annotation pool and unqualified labeled samples from the seed data. Finally, all high-quality labeled samples are integrated to construct a labeled dataset containing both real and synthetic samples, covering multiple types of crack features, with a sample size of no less than 50,000 images.
[0053] Step S120: In the preprocessing stage, the image is optimized using multi-scale denoising, illumination normalization, and angle correction, based on an improved U-Net fusion of CNN and Transformer;
[0054] In this step, the original images of the bridge's underside captured by the UAV are first subjected to a full-process preprocessing operation, sequentially performing angle correction, multi-scale denoising, illumination normalization, and feature standardization to eliminate interference factors such as tilted shooting angles, uneven illumination, and image noise, preserving the texture and contour details of the cracks to the greatest extent possible. Next, an improved U-Net network architecture is built, retaining the classic encoder-decoder symmetrical structure and skip connection core mechanism of U-Net, with targeted adjustments to the encoder-decoder stride and optimization of the skip connection path. A dual-branch feature fusion module of CNN and Transformer is constructed between the encoder and decoder, enabling CNN to capture local texture features of the cracks and Transformer to enhance global structural features, laying the foundation for subsequent pixel-level crack segmentation and feature extraction.
[0055] Step S121: Perform full-process preprocessing on the images acquired from the bottom of the bridge. First, extract the bridge structural feature points using the SIFT algorithm. After matching, solve the homography transformation matrix and complete the perspective transformation to achieve angle correction. Verify the consistency by feature point matching degree. Then, divide the images into scale levels according to resolution. Use bilateral filtering for shallow low-scale images and non-local mean filtering for deep high-scale images to remove noise. Restore the original resolution output by feature fusion. Finally, convert the images to grayscale space, optimize the illumination using the CLAHE algorithm and adaptive gamma correction, and normalize the pixel values to the specified range to achieve feature standardization.
[0056] In this step, the SIFT algorithm is used to extract structural corner points, joints, and other feature points from the bridge's underside image. KNN matching algorithm is then used to match these feature points. The homography transformation matrix is solved, and perspective transformation is performed to correct the angle. Only corrected images with a feature point matching degree ≥ 80% are retained. The corrected image is divided into three scale levels according to resolution. Shallow, low-scale images are denoised using bilateral filtering (σd=5, σr=0.1), while deep, high-scale images are denoised using non-local mean filtering. Feature fusion restores the original image resolution. The image is converted to grayscale space, and the CLAHE algorithm (block size 8×8) and adaptive gamma correction (γ=0.5-2.0) are used to optimize illumination uniformity. Finally, pixel values are normalized to the [0,1] interval to complete image feature standardization.
[0057] Step S122: Build the basic U-Net network architecture, retain the classic U-Net encoder-decoder symmetrical structure and skip connection mechanism, adjust the step size of encoder downsampling and decoder upsampling, and optimize the skip connection path.
[0058] In this step, based on the actual needs of bridge underside crack detection, an improved U-Net basic network architecture was built, retaining the classic symmetrical encoder-decoder structure and the skip connection mechanism for passing shallow features from the encoder to the corresponding layer of the decoder. For an 800×800 input image, a hierarchical structure of 5 levels of downsampling for the encoder and 5 levels of upsampling for the decoder was set. The encoder downsampling stride was adjusted accordingly, employing a combination of max pooling and convolution to balance the need for crack detail preservation and global feature capture. The decoder upsampling stride and implementation method were adjusted simultaneously. The feature propagation path of the skip connections was optimized to reduce redundant feature propagation and to reserve a standardized interface for subsequent fusion of CNN and Transformer features.
[0059] Step S1221: Based on the image features and crack scale features of the cracks on the bottom of the bridge, build the U-Net basic framework, retain the classic encoder-decoder symmetrical hierarchical structure of U-Net and the core mechanism of skip connection for passing shallow features of the encoder to the corresponding layer of the decoder, configure the input layer adapted to the bridge detection image, and set the downsampling and upsampling hierarchical structure of the encoder and decoder in a one-to-one correspondence.
[0060] In this step, based on the 800×800 resolution of the images of cracks on the bridge underside and the scale characteristics of micro, medium, and macro cracks, a U-Net basic framework was built. This framework retains a symmetrical hierarchical structure of a 5-level encoder and a 5-level decoder, along with the core mechanism of skip connections for transferring shallow features from the encoder to the corresponding layers of the decoder. A single-channel grayscale input layer was configured to adapt to the format of the preprocessed bridge underside image. The scaling ratio for downsampling at each level of the encoder and upsampling at each level of the decoder was set to 2x, creating a one-to-one hierarchical structure between the encoder and decoder. The framework is built on PyTorch, and the input layer and each level of convolutional layers undergo weight initialization to avoid the gradient vanishing problem during training, laying the foundation for subsequent architecture optimization.
[0061] Step S1222: Adjust the encoder downsampling step size specifically for the crack features on the bottom of the bridge. Adopt a downsampling combination that combines crack detail preservation and global feature capture. Simultaneously match and adjust the decoder upsampling step size and implementation method to ensure that the scaling ratio of the decoder and encoder at the corresponding level of downsampling is consistent, so as to achieve feature map dimension matching. After each level of upsampling in the decoder, the number of feature map channels is adapted and adjusted.
[0062] In this step, considering the detailed features and distribution characteristics of cracks on the bridge's underside, the encoder downsampling employs a combination of "max pooling (stride 2) + 3×3 convolution (stride 1)" to preserve crack edge details while achieving downsampling, thus meeting the dual requirements of crack detail preservation and global feature capture. The decoder simultaneously uses transposed convolution (stride 2) as the upsampling method to ensure consistency with the scaling ratio of the encoder's downsampling at the corresponding level, achieving precise dimensionality matching between the encoder and decoder feature maps. After each level of upsampling in the decoder, the number of feature map channels is adjusted by half using a 1×1 convolution kernel, reducing the computational load of subsequent feature fusion while maintaining feature expressiveness.
[0063] Step S1223: Optimize the feature transmission path of the skip connection. Add a lightweight feature filtering module at the output end of each level of the encoder to perform redundant filtering and retain effective features of the encoder output features. Design a feature alignment module at the input end of each level of the decoder to perform spatial position correction of the feature map transmitted by the encoder. At the same time, reconstruct the feature fusion method of the skip connection. Set a feature fusion layer at the corresponding level input end of the decoder to fuse and integrate the shallow features of the encoder after filtering and alignment with the deep features of the decoder after upsampling. Optimize the feature transmission link of the skip connection.
[0064] In this step, a lightweight feature filtering module consisting of a 1×1 convolution + ReLU activation function is added to the output of each level of the encoder to filter redundant features such as concrete background, retaining only effective features related to cracks. A feature alignment module is designed at the input of each level of the decoder to correct the spatial position of the feature maps transmitted by the encoder using a bilinear interpolation algorithm, ensuring that the feature map position deviation is ≤1 pixel. A feature fusion layer is set at the corresponding level input of the decoder to perform channel-by-channel splicing and fusion of the filtered and aligned shallow features from the encoder with the upsampled deep features from the decoder. Simultaneously, the feature transmission links with skip connections are optimized, and a direct-connection transmission method is adopted to reduce information loss during feature transmission.
[0065] Step S1224: Fix the hierarchical connection relationship of the U-Net basic architecture, clarify the skip connection matching relationship of the corresponding layers of the encoder and decoder, uniformly configure the convolutional layers and activation functions of each layer of the architecture, keep the feature map resolution unchanged and ensure the non-linear expressive ability of feature extraction, and reserve standardized feature input and output interfaces for subsequent fusion of local feature extraction module and global feature enhancement module;
[0066] In this step, the encoder-decoder hierarchical connection relationships of the U-Net basic architecture are fixed, and the unique matching relationship of the skip connections between the i-th level of the encoder and the 6-i-th level of the decoder is clearly defined to avoid feature confusion caused by cross connections. All convolutional layers in each level of the architecture are uniformly configured with 3×3 convolutional kernels and padding=1, and the activation function is uniformly selected as ReLU. This ensures that the resolution of the feature maps at each level remains unchanged while improving the non-linear feature representation capability of the model. Standardized feature input and output interfaces are set at the encoder output and decoder input, respectively. The interface dimensions are set according to the number of channels and resolution of the feature maps at each level, realizing seamless feature access and providing adaptability for subsequent fusion of CNN local feature extraction modules and Transformer global feature enhancement modules.
[0067] Step S1225: Perform architecture dimension matching and forward propagation verification. Input the preprocessed bridge bottom crack image and perform architecture forward propagation. Verify the dimension parameters of the feature maps at each level of the encoder and decoder, focusing on verifying the dimension consistency of the feature maps at jump connections. Correct the dimension mismatch problem, and at the same time verify the information integrity of the feature transmission link and the effectiveness of the feature extraction and transmission functions.
[0068] In this step, a preprocessed 800×800 grayscale image of cracks on the bridge's underside is input. The U-Net architecture is then forward-propagated, extracting dimensional parameters such as resolution and number of channels from the feature maps at each level of the encoder and decoder. Special emphasis is placed on verifying the dimensionality consistency of feature maps at jump connections. If dimensionality mismatches occur, they are corrected by adjusting the number of channels using 1×1 convolutional kernels and adjusting the resolution using bilinear interpolation / center clipping. Simultaneously, feature map visualization technology is used to verify the integrity of the feature transfer chain, checking whether the shallow crack detail features of the encoder can be effectively transferred to the corresponding levels of the decoder. This comprehensively verifies the effectiveness of the architecture's feature extraction and transfer functions, correcting any functional anomalies.
[0069] Step S1226: While ensuring the symmetric structure of the encoder and decoder and the optimization effect of skip connections, perform lightweight adaptation optimization on the basic architecture, differentiate the number of feature channels at each level, and use lightweight convolution to reduce the number of model parameters and computation, adapt to the deployment requirements of the edge end and maintain the feature extraction performance of the architecture, and complete the construction of the U-Net basic network architecture.
[0070] In this step, while ensuring the optimization of the symmetrical structure of the encoder and decoder and the skip connections, the U-Net basic architecture is lightweighted and adapted. The number of feature channels at each level is configured differently, with the encoder levels 1-5 having 64, 128, 256, 256, and 512 channels respectively, reducing the number of channels in non-critical levels. Depthwise separable convolutions are used instead of traditional convolutions, combined with kernel sparsity processing, reducing the number of model parameters and computational cost by more than 60%. During the lightweight optimization process, the feature extraction performance of the architecture is maintained, ensuring that the model's mIoU decrease on the validation set is ≤2%. This makes the optimized architecture suitable for lightweight deployment requirements on drones and edge devices, ultimately completing the construction of the improved U-Net basic network architecture.
[0071] Step S123: Construct a dual-branch feature extraction module. On the one hand, a CNN feature extraction encoder is built with a lightweight residual convolutional network as the backbone. Stacked convolution, batch normalization and activation function layers are downsampled layer by layer. A multi-scale dilated convolution module is introduced to extract and output multi-scale CNN local feature maps. On the other hand, a Transformer global feature enhancement module is designed to flatten and map the deep CNN feature map into a feature sequence and add position encoding. Global correlation features are captured through a multi-head self-attention mechanism. After reinforcement learning by a feedforward neural network, the global feature map is output and then restored to the dimension and resolution that match the CNN feature map.
[0072] In this step, a CNN feature extraction encoder is built using a lightweight residual convolutional network (MobileNetV3) as the backbone. Stacked convolutions, batch normalization, and SiLU activation function layers are used for layer-by-layer downsampling. Multi-scale dilated convolutional modules with dilation rates of 1, 3, and 5 are introduced to extract and output a 5-scale CNN local feature map, capturing detailed features such as crack edges and textures. The deep 512-dimensional feature map of the CNN is flattened into a feature sequence, sinusoidal positional encoding is added, and an 8-head self-attention mechanism Transformer global feature enhancement module is designed to capture the global structure and associated features of the crack. After reinforcement learning via a feedforward neural network, the output global feature map is restored to a dimension and resolution matching the CNN feature map through deconvolution.
[0073] Step S124: Establish feature fusion between CNN and Transformer. Set up a feature fusion layer between encoder and decoder. Concatenate the local feature maps of CNN at each scale with the global feature maps of Transformer. Use 1×1 convolution kernels to complete dimension fusion and feature compression to generate a hybrid feature map. During the upsampling process of decoder, fuse the fused feature map with the corresponding shallow CNN feature map of encoder through skip connections.
[0074] In this step, a multi-scale feature fusion layer is set between the U-Net encoder and decoder, and features are fused with CNN and Transformer features according to scale levels. Figure 1 A one-to-one correspondence is achieved. Local feature maps from each scale of the CNN are concatenated with the global feature map from the Transformer, channel-wise. A 1×1 convolutional kernel is used to perform cross-channel fusion and dimensionality compression, generating a hybrid feature map that combines local and global features. During the decoder upsampling process, the hybrid feature map is fused again with the corresponding shallow CNN feature map from the encoder via skip connections. A channel-weighted concatenation strategy is used during fusion to highlight the key features of the cracks. Through these two feature fusions, a deep fusion of local crack details and global structural features is achieved, improving the completeness of feature representation.
[0075] Step S1241: Perform dimensionality pre-alignment on the multi-scale CNN local feature maps and Transformer global feature maps, extract the multi-scale CNN local feature maps output by the encoder and the dimensionality restored Transformer global feature maps, establish a one-to-one correspondence matching relationship according to the scale level, adjust the feature maps with different resolutions to the same size by interpolation or cropping, and adjust the number of channels of feature maps with inconsistent channel numbers by adapting with 1×1 convolution kernels to ensure that the resolution and number of channels of the two types of feature maps are consistent at the same scale;
[0076] In this step, the 5-scale CNN local feature maps output by the encoder and the dimensionality-restored Transformer global feature maps are extracted, and a one-to-one matching relationship is established according to the 1-5 scale levels. For feature maps with different resolutions, bilinear interpolation is used to enlarge them or center clipping is used to reduce them, so that the resolution of the two types of feature maps at the same scale is consistent. For feature maps with different numbers of channels, dimensionality adjustment is performed using 1×1 convolution kernels to achieve channel number matching. All adjustment operations ensure that no feature information is lost from the feature maps, ensuring that the resolution and number of channels of the CNN local feature maps and the Transformer global feature maps at the same scale are completely consistent, laying the foundation for subsequent channel stitching and fusion. The feature map alignment error is ≤1 pixel.
[0077] Step S1242: Build a multi-scale feature fusion layer in the feature transfer link between the U-Net encoder and decoder. Divide the feature fusion layer into a corresponding number of independent fusion sub-modules according to the scale level of CNN and Transformer features. The fusion layer adopts a parallel structure design and reserves a feature caching interface.
[0078] In this step, a multi-scale feature fusion layer is built in the feature transfer link between the U-Net encoder and decoder. Based on the 5-scale features of CNN and Transformer, five independent fusion sub-modules are defined. The fusion layer adopts a parallel structure design, with each sub-module independently completing feature fusion at its corresponding scale, improving overall fusion efficiency. Each fusion sub-module has standardized feature input and output interfaces, seamlessly connecting with the feature transfer link between the encoder and decoder. The fusion layer as a whole reserves a feature caching interface, which can temporarily cache the intermediate feature maps after fusion at each scale, supporting rapid retrieval of feature maps during decoder upsampling without repetitive calculations, thus improving model inference efficiency.
[0079] Step S1243: Perform the first feature fusion in each scale fusion submodule. The CNN local feature map of the same scale with the dimension pre-aligned and the Transformer global feature map are concatenated by channel dimension to form a concatenated feature map. After the concatenated feature map is connected, a 1×1 convolution kernel is connected to complete cross-channel fusion and dimension compression to generate a mixed feature map of each scale. After the mixed feature map is scale-labeled, it is stored in the feature cache pool that is managed by scale level partitioning.
[0080] In this step, within each scale fusion submodule, the pre-aligned CNN local feature maps of the same scale are concatenated with the Transformer global feature maps along the channel dimension to form a concatenated feature map. A 1×1 convolutional kernel is then applied to the concatenated feature map to complete cross-channel feature fusion and dimensionality compression. The compression ratio is set to 1 / 2, reducing computation while preserving core features. After generating the mixed feature maps for each scale, a unique scale marker is added to each map, and they are stored in a feature cache pool managed by scale hierarchy. The cache pool uses a memory partitioning storage method, with each scale feature map stored independently and indexed, facilitating rapid retrieval by scale during decoder upsampling and ensuring real-time feature retrieval.
[0081] Step S1244: Combine the decoder upsampling process to perform the second feature fusion and complete feature integration. After each level of upsampling, the decoder retrieves the matching mixed feature map from the feature buffer pool and superimposes it with the upsampled feature map. Then, through skip connections, it introduces the shallow CNN feature map of the corresponding level of the encoder and concatenates it with the superimposed feature map again. After concatenation, a lightweight feature integration module composed of 3×3 convolution kernels is added to perform feature aggregation and generate the decoder input feature map.
[0082] In this step, after each level of upsampling, the decoder retrieves a matching hybrid feature map from the feature cache based on the scale index and adds it element-wise to the upsampled feature map. A skip connection is then used to introduce a shallow CNN feature map from the corresponding encoder layer, which is concatenated with the superimposed feature map along the channel dimension to fuse shallow crack detail features. After concatenation, a lightweight feature integration module consisting of two 3×3 convolutional layers is added to aggregate and extract the concatenated features, filtering redundant features and enhancing effective features. Finally, the input feature map for the corresponding decoder layer is generated, achieving a triple fusion of local features, global features, and shallow detail features, thus enhancing the richness of feature representation.
[0083] Step S1245: Establish a hierarchical linkage mechanism between feature fusion and decoder upsampling. Before the upsampling operation is started, the corresponding mixed feature map is retrieved. After the upsampling is completed, the secondary feature fusion and integration are performed immediately. At the same time, feature monitoring interfaces are set at each level feature fusion node to provide real-time feedback on the resolution, number of channels, and effective feature values of the feature map.
[0084] In this step, a hierarchical linkage mechanism is established between feature fusion and decoder upsampling. Through program logic settings, before the decoder upsampling operation starts, the corresponding scale of the mixed feature map is automatically retrieved from the feature cache pool and loaded into memory. After the upsampling operation is completed, the secondary feature fusion and feature integration process is immediately triggered, achieving seamless connection between each operation without intermediate waiting steps. Feature monitoring interfaces are set up at each level of feature fusion nodes to collect and report key parameters such as feature map resolution, number of channels, and effective feature values in real time. If parameter anomalies occur, an early warning is issued immediately, and abnormal data is recorded to provide data support for subsequent model parameter optimization and ensure the stability of the entire feature fusion process.
[0085] Step S1246: Conduct forward propagation verification of the entire feature fusion chain. Input the preprocessed image of the crack on the bottom of the bridge and let the features go through the entire process of CNN feature extraction, Transformer global enhancement, first feature fusion, decoder upsampling, second feature fusion and feature integration in sequence. Verify the dimensionality consistency of the feature maps at each stage layer by layer. Verify the effect of the fused features on the preservation of local details and global structural features of the crack through feature map visualization.
[0086] In this step, a preprocessed image of the cracks on the bridge's underside is input, and the image features are sequentially processed through a complete workflow: CNN feature extraction, Transformer global enhancement, first feature fusion, decoder upsampling, second feature fusion, and feature integration. The dimensionality parameters of the feature maps at each stage are extracted layer by layer, and the consistency of resolution and number of channels is verified. Any dimensionality deviations are corrected promptly using methods such as 1×1 convolution and interpolation. Feature map visualization technology is used to transform the feature maps at each stage into visual images. Combined with the mIoU quantitative metric, the effectiveness of the fused features in preserving local texture details and global structural features of the cracks is verified, ensuring that no crack details are lost and global structural features are clearly discernible.
[0087] Step S1247: Fine-tune and optimize parameters based on feature fusion effect. If local detail features are weakened, adjust the channel compression ratio of the 1×1 convolution kernel. If the global structural features are not sufficiently expressed, optimize the splicing weight of the two types of feature maps. At the same time, adjust the convolution parameters of the 3×3 convolution kernel to optimize the feature aggregation effect.
[0088] In this step, parameters are fine-tuned and optimized based on the visualization and quantitative evaluation results of feature fusion. If weakened local details of cracks are detected, the channel compression ratio of the 1×1 convolution kernel is adjusted to 1 / 1.5 to reduce channel compression and retain more local texture features. If the global structural features are insufficient, weighting coefficients are added to the CNN and Transformer feature maps, increasing the weight of the Transformer features to 0.6-0.7 to strengthen global features. Simultaneously, the weight initialization method and stride of the 3×3 convolution kernel are adjusted to optimize the feature aggregation effect of the feature integration module. After fine-tuning, the full-link forward propagation verification is re-executed until the fused features clearly retain both local crack details and the complete global structure, meeting the feature requirements for crack detection.
[0089] Step S125: Optimize the decoder and output layer. The decoder adopts a transposed convolution combined with pixel shuffling upsampling method to upsample the fused feature map layer by layer to the same resolution as the original image. In the last layer of the decoder, a spatial attention mechanism is introduced to generate a pixel-level attention weight map to focus on the crack region and suppress background interference. The output layer outputs a pixel-level crack segmentation probability map through the sigmoid activation function.
[0090] In this step, the decoder employs a transposed convolution (stride 2) combined with pixel shuffling (factor 2) upsampling to progressively upsample the fused feature map, ultimately restoring it to an 800×800 resolution consistent with the original acquired image. The final layer of the decoder introduces a CBAM spatial attention mechanism, generating a pixel-level attention weight map through pooling and convolution operations. The weight values are distributed between 0 and 1, enhancing the weights of the crack region and suppressing background interference regions, thus accurately focusing on the crack target. The output layer reduces the number of feature map channels to 1 using a 1×1 convolution kernel, and outputs a pixel-level crack segmentation probability map with probability values between 0 and 1 after passing through a sigmoid activation function, providing a foundation for subsequent pixel-level crack segmentation and parameter quantization.
[0091] Step S126: Perform end-to-end training and targeted fine-tuning of the U-Net model. Use the bridge bottom crack annotation dataset to train the model, select the segmentation task-adaptive loss function, configure the adaptive learning rate decay strategy and optimizer, iteratively optimize the network parameters through forward and backward propagation, monitor the crack segmentation accuracy index in real time during training, and perform targeted fine-tuning for the difficulty of identifying small cracks and fuzzy cracks until the model stably outputs high-precision crack segmentation results.
[0092] In this step, the improved U-Net model was trained end-to-end using a bridge underside crack annotation dataset. A combination of Dice loss and cross-entropy loss was selected to address the imbalanced sample problem in crack segmentation. The AdamW optimizer and cosine annealing adaptive learning rate decay strategy were configured with an initial learning rate of 1e-4 and a total of 200 epochs of training. During training, crack segmentation accuracy metrics such as mIoU, precision, and recall were monitored in real time. Features were extracted through forward propagation, and network parameters were iteratively optimized through backpropagation. To address the challenges of identifying micro-cracks and blurry cracks, a dedicated fine-tuning dataset was constructed. 50 epochs of targeted fine-tuning were performed with a low learning rate of 5e-5, focusing on optimizing the deep feature extraction layer of the model until the model's mIoU ≥ 90% and the accuracy of micro-crack identification ≥ 85%, resulting in stable high-precision crack segmentation results.
[0093] Step S130: Construct two-dimensional and three-dimensional quantization systems. In the two-dimensional system, the length and width of the crack are measured by sub-pixel segmentation, skeleton extraction and minimum bounding rectangle, and gray-level gradient method. In the three-dimensional system, the point cloud is reconstructed by SFM and stereo matching, the depth of the two-dimensional crack is calculated by mapping, a mapping model between quantization parameters and damage level is established, and a standardized assessment report is output.
[0094] In this step, a two-dimensional crack quantification process is first established. Based on pixel-level segmentation results, sub-pixel segmentation optimization and skeleton extraction are performed. Then, the length and width of the crack are accurately calculated using the minimum bounding rectangle and gray-level gradient method. Next, a three-dimensional point cloud model of the bridge underside is reconstructed from the sequence of images collected by UAVs using the SFM algorithm and stereo matching technology. A spatial mapping relationship between the two-dimensional image and the three-dimensional point cloud is established, and the crack depth is calculated by fitting a reference plane. After integrating the two-dimensional and three-dimensional quantification parameters, a mapping model between the quantification parameters and the damage level is built using a classification regression algorithm, referencing bridge inspection industry standards. The model's accuracy is ensured through training and verification. Finally, quantification data, damage level, and other information are extracted according to a standardized framework to complete the disease risk analysis and output an assessment report containing treatment recommendations, achieving a full-dimensional analysis of cracks from qualitative identification to quantitative assessment.
[0095] Step S131: Perform two-dimensional crack geometric parameter quantization, optimize sub-pixel segmentation based on crack pixel-level segmentation results, extract crack skeleton and repair disconnected areas, combine skeleton analysis and edge detection methods to complete two-dimensional quantization of crack length and width, and filter outliers in the quantization results.
[0096] In this step, based on the pixel-level segmentation results of the crack, bilinear interpolation is used for sub-pixel segmentation optimization to improve the crack edge localization accuracy to the sub-pixel level and reduce edge detection errors. Crack skeleton features are extracted using a skeleton refinement algorithm, and morphological closing operations are used to repair broken areas of the skeleton, ensuring its continuity and integrity. The actual crack length is calculated by combining the number of skeleton pixels and pixel resolution. The edges on both sides of the crack are detected using the gray-level gradient method, and the width value of the crack at different locations is calculated using the minimum bounding rectangle fitting algorithm. Outlier filtering is performed on the length and width quantization results according to the 3σ principle to remove abnormal data caused by image noise and interference, ensuring that the error of the two-dimensional quantization parameters is controlled within 5% and guaranteeing data validity.
[0097] Step S132: Construct a three-dimensional point cloud model of the bridge bottom and complete three-dimensional quantization. Based on the sequence of images collected by UAV, construct a three-dimensional point cloud model through feature association and three-dimensional reconstruction algorithm, establish the spatial registration relationship between two-dimensional images and three-dimensional point cloud, map two-dimensional crack features to three-dimensional point cloud, and calculate crack depth and three-dimensional spatial parameters by fitting the reference surface.
[0098] In this step, SIFT feature points are extracted from the sequence of bridge underside images captured by the UAV to complete cross-image feature association. The SFM algorithm is then used to calculate camera pose. Next, stereo matching technology is used to reconstruct the 3D sparse point cloud of the bridge underside, which is then densified to obtain a high-precision point cloud model. Using camera intrinsic and extrinsic parameters and calibration parameters, a conversion relationship between 2D image pixel coordinates and 3D point cloud world coordinates is established, accurately mapping 2D crack features to the 3D point cloud space. A random sampling consensus algorithm is used to fit the bridge underside flat reference surface, calculating the vertical distance between the crack area point cloud and the reference surface to obtain the actual crack depth. Simultaneously, parameters such as the 3D spatial orientation and distribution range of the crack are extracted, achieving accurate quantification of the crack's 3D geometric features.
[0099] Step S133: Integrate two-dimensional and three-dimensional quantization parameters and perform standardization processing to form a multi-dimensional crack quantization parameter set. Refer to industry standards to normalize and standardize the parameters and construct a standardized quantization feature library.
[0100] This step integrates quantitative parameters such as the length, maximum width, average width, and direction of two-dimensional cracks, as well as the depth, spatial coordinates, and volume of three-dimensional cracks, forming a multi-dimensional crack quantitative parameter set. Referring to industry standards such as the "Technical Condition Assessment Standard for Highway Bridges," each parameter is normalized, linearly mapping the parameter values to the [0,1] interval. Simultaneously, the quantitative parameters are standardized and calibrated for different bridge types (beam bridges, arch bridges, etc.) and different load-bearing components to eliminate parameter deviations caused by differences in bridge type and component. The standardized parameters are categorized and stored according to bridge type, service life, and component type. A unique identifier is established for each crack sample, associated with attribute information such as the acquisition environment and UAV positioning, constructing a standardized quantitative feature library to support rapid parameter retrieval and model invocation.
[0101] Step S134: Build a mapping model between crack quantification parameters and damage level, formulate damage level classification standards in combination with bridge structural characteristics and industry assessment specifications, construct a training sample library containing standardized quantification parameters and corresponding damage level labels, build a mapping model using classification and regression algorithms, and optimize the model performance through training, verification and testing.
[0102] In this step, considering the structural stress characteristics of different bridge types such as beam bridges, arch bridges, and cable-stayed bridges, and referring to industry assessment standards, bridge crack damage is classified into four levels: minor, light, medium, and severe. Quantitative parameter thresholds are established for each level; for example, minor damage corresponds to crack length <5cm and depth <2mm. Samples are extracted stratified from a standardized quantitative feature library, and corresponding damage level labels are manually labeled to construct a training sample library, which is then divided into training, validation, and test sets in an 8:1:1 ratio. An XGBoost classification and regression algorithm is used to build a mapping model, with standardized quantitative parameters as input and damage level as output. The Adam optimizer and adaptive learning rate decay strategy are configured to complete model training. Hyperparameters are optimized through grid search to ensure that the model's damage level prediction accuracy on the validation set is ≥90%, guaranteeing the model's generalization ability.
[0103] Step S135: Establish a dynamic calibration mechanism for the mapping model, apply the model to actual detection and compare the prediction results with the manual evaluation results, analyze the reasons for the deviation, and achieve dynamic iterative optimization of the model by supplementing quantitative indicators, adjusting the grade threshold or updating the sample library;
[0104] In this step, the damage level mapping model is applied to actual bridge inspection projects. The damage levels predicted by the model are recorded simultaneously with the manual assessments by professional engineers. Error analysis is used to compare the discrepancies, identifying reasons such as missing quantitative indicators, unreasonable level thresholds, or insufficient sample coverage. If the discrepancy is due to missing indicators, quantitative indicators such as crack density and propagation rate are added. If the discrepancy is due to unreasonable thresholds, the parameter threshold ranges for each damage level are adjusted based on the actual engineering situation. If the discrepancy is due to insufficient sample coverage, samples from different bridge types and disease stages are added to the training library. The model is then retrained based on the corrected indicators, thresholds, or sample library.
[0105] Step S136: Generate a standardized damage assessment report. Based on the preset report framework, automatically extract quantitative parameters, spatial distribution characteristics and damage level prediction results. After graphical display and disease risk analysis, output a standardized report containing treatment recommendations, and retain data traceability and association management interfaces.
[0106] This step involves a pre-defined standardized damage assessment report framework, comprising eight modules: basic project information, inspection overview, crack quantitative parameters, spatial distribution characteristics, damage level, risk analysis, treatment recommendations, and data traceability. Based on this framework, information such as bridge number, inspection time, crack length, width, depth, three-dimensional spatial location, and predicted damage level are automatically extracted from the quantitative feature library and mapping model. Heat maps and line graphs are used to graphically display the quantitative parameters and spatial distribution. Combining the stress characteristics of the component containing the crack, the impact of the damage on the bridge structure is analyzed, classifying it into low, medium, and high risk levels, and providing targeted treatment recommendations, such as regular monitoring for low-risk cases, local repairs for medium-risk cases, and reinforcement for high-risk cases. The report adds a timestamp and unique identifier to each data point, retains data traceability and association management interfaces, and supports integration with bridge BIM models and maintenance management systems.
[0107] Step S140: Build a three-level collaborative architecture of end-edge-cloud, including lightweight AI on the drone end to identify suspected cracks, high-precision verification and feedback at the edge end, and flight control system to adjust attitude and retake photos based on feedback;
[0108] This step involves first deploying the hardware and communication links for a three-tiered, edge-cloud collaborative system. The drone is equipped with lightweight edge computing and multi-mode communication modules, while high-performance servers are deployed at the edge. Distributed data storage and global scheduling nodes are built in the cloud, establishing a low-latency transmission link with 5G as the primary and 4G as a backup. A pruned and quantized lightweight AI model is deployed on the drone to achieve real-time identification of suspected cracks. A high-precision crack detection model is deployed at the edge to accurately verify suspected data and generate re-shooting commands. The drone's flight control system receives the commands and dynamically adjusts its flight attitude to complete the accurate re-shooting. Simultaneously, collaborative scheduling, load balancing, and fault tolerance mechanisms are constructed to achieve closed-loop collaboration between data acquisition, identification, verification, and re-shooting, significantly improving detection efficiency and reducing the rate of invalid image acquisition.
[0109] Step S141: Deploy a three-level collaborative hardware and communication link between the end, edge, and cloud. Configure lightweight edge computing, image acquisition, sensing, and multi-mode communication modules on the drone end. Set up an edge server with integrated computing power unit and a high-speed data receiving module on the edge end. Deploy data storage and global scheduling nodes on the cloud. Build a low-latency, high-bandwidth transmission link with a dual-mode communication architecture. Clarify the bidirectional data interaction protocol between the drone and the edge end, and agree on the transmission format and priority of suspected crack data, verification results, and reshoot instructions.
[0110] During this step, the drone is equipped with an embedded lightweight edge computing module, a high-definition industrial camera, multiple sensors, and a 4G / 5G dual-mode communication module to meet the requirements of real-time inference and data transmission. At the edge, an edge server integrating GPU computing power and a high-speed data receiving module are deployed to achieve high-precision model inference. A distributed data storage node and a global scheduling platform are built in the cloud to handle data storage and global scheduling. A dual-mode communication architecture with 5G as the primary mode and 4G as a backup is established to achieve low-latency, high-bandwidth data transmission. A clear bidirectional data interaction protocol between the drone and the edge is defined, stipulating that suspected crack data will be transmitted in binary compression format, and reshoot instructions will be transmitted in JSON format. The data transmission priority for suspected cracks is set as the highest, followed by reshoot instructions, and then non-critical data, ensuring that critical data is transmitted first.
[0111] Step S142: Deploy a lightweight AI model on the drone. During the drone's flight, the image acquisition device continuously acquires images of the bridge's underside according to preset parameters. After lightweight preprocessing, the images are input into the lightweight AI model to identify suspected crack areas in real time and output relevant area information and device status parameters during acquisition. The suspected area data is transmitted to the edge terminal via the communication link first.
[0112] In this step, the improved U-Net model undergoes model pruning, weight quantization, and channel compression to achieve lightweight transformation. This reduces the number of model parameters by more than 70% and increases inference speed by 3 times, before being deployed to the edge computing module on the drone. When the drone operates according to preset flight parameters, the image acquisition device continuously acquires images of the bridge's underside. After lightweight preprocessing including cropping and pixel value normalization, these images are input into the lightweight AI model in real time. The model quickly infers and identifies suspected crack areas, outputting the region's pixel coordinates, area, and equipment status parameters such as drone flight altitude, shooting angle, and light intensity. Suspected area images and parameters are compressed and prioritized for upload to the edge via a dual-mode communication link. Data from non-suspected areas is temporarily stored in the drone's local storage module to reduce bandwidth consumption.
[0113] Step S143: Deploy a high-precision crack detection model at the edge, receive data uploaded by the drone, start high-precision inference verification, distinguish real cracks from background interference through pixel-level segmentation, evaluate the integrity and clarity of cracks and determine whether reshooting is needed, analyze the cause of defects in areas that do not meet the standards, generate targeted reshooting instructions including target reshooting position, attitude adjustment parameters, and shooting parameter suggestions, and mark the priority.
[0114] In this step, a high-precision improved U-Net crack detection model (without lightweighting) is deployed on an edge server. Upon receiving suspected crack data uploaded by the drone, high-precision inference verification is immediately initiated. Pixel-level segmentation accurately distinguishes genuine cracks from background interference such as stains, water stains, and template seams. For areas identified as genuine cracks, evaluation is conducted based on feature integrity and image clarity. If issues such as missing crack edges, blurred textures, or partial occlusion exist, it is determined that reshooting is required. The reasons for these defects are analyzed as tilted shooting angle, excessive flight distance, and uneven lighting. A reshooting command is generated, including the world coordinates of the target reshoot location, drone pitch / head angle adjustment parameters, optimal shooting altitude, and focal length. The command priority is marked according to the importance of the component containing the crack, and it is immediately sent to the drone flight control system.
[0115] Step S144: After receiving the reshoot command, the UAV flight control system calculates the deviation between the current state and the target state by combining its own sensor unit and positioning data. It dynamically adjusts the flight parameters through the control algorithm to ensure that the UAV accurately arrives at the reshoot area and aligns with the suspected area from the optimal perspective. During the adjustment process, the progress is fed back to the edge device in real time, and the edge device dynamically corrects the reshoot command based on the feedback.
[0116] During this step, after receiving the reshoot command from the edge device, the UAV flight control system combines real-time data from visual SLAM, IMU, and reference marker fusion positioning to calculate the deviation between the UAV's current position, attitude, shooting altitude, and target state. A PID control algorithm is used to dynamically adjust the UAV's flight speed, heading angle, pitch angle, and other flight parameters, controlling the UAV to accurately reach the reshoot area with a positioning accuracy of ±0.5m, and adjusting the shooting angle to the optimal angle perpendicular to the crack area. During the adjustment process, the flight control system feeds back the UAV's real-time position, attitude adjustment progress, and completion rate to the edge device at a frequency of 500ms / time. Based on the actual feedback, the edge device dynamically corrects the parameters in the reshoot command to ensure the accuracy and effectiveness of the reshoot.
[0117] Step S145: The drone performs reshooting according to the adjusted parameters. The lightweight AI model re-identifies and confirms the reshooting image. If the requirements are met, the reshooting data is uploaded to the edge device. The edge device performs secondary verification through the high-precision model. After confirming that the crack features are completely extracted, the final verification result is generated. If the standard is not met, the feedback, adjustment, and reshooting process is repeated to form a collaborative closed loop.
[0118] During this step, the UAV performs a reshoot operation according to the flight parameters adjusted by the flight control system. The image acquisition device acquires images of the suspected area using optimal focal length and exposure parameters. The lightweight AI model on the UAV performs rapid secondary recognition on the reshoot images to determine whether features such as crack edges and textures are clear and extractable. If the extraction requirements are met, the reshoot image and acquisition parameters are compressed and uploaded to the edge device. The edge device performs secondary verification using a high-precision detection model. After confirming that the crack features are completely extracted and the quantification parameters are measurable, the final verification result is generated and synchronized to the cloud. If the reshoot image still does not meet the standards, the edge device analyzes the reasons for the failure and regenerates a corrected reshoot command, which is then sent to the flight control system. The attitude adjustment, reshoot, and verification process is repeated, forming a collaborative closed loop of acquisition-recognition-verification-reshoot.
[0119] Step S146: Optimize the three-level collaborative scheduling and load balancing strategy. The edge terminal prioritizes the data uploaded by multiple UAVs and dynamically allocates computing resources through the task scheduling module. The UAV terminal adopts a data fragmentation transmission mechanism to reduce bandwidth consumption. The cloud synchronizes the edge terminal verification results, UAV flight data and crack-related information in real time and builds a global data index.
[0120] During this step, a task scheduling module is built at the edge, employing a priority queue algorithm to prioritize suspected crack data uploaded by multiple drones. Computational resources are dynamically allocated based on the server's GPU load, prioritizing high-priority crack data for high-precision inference. The drones utilize a data fragmentation transmission mechanism, dividing each high-resolution image into 4×4 grid pieces for batch transmission, reducing the amount of data transmitted per batch and lowering bandwidth usage and transmission latency. The cloud, through distributed storage technology, synchronizes all relevant information from the edge, including crack verification results, drone flight trajectories and acquisition parameters, and crack quantification parameters, in real time. A global data index is built based on bridge type, detection time, and bridge number, supporting rapid data retrieval, statistics, and multi-dimensional analysis, achieving unified global management of detection data.
[0121] Step S147: Establish a system synchronization calibration and fault tolerance mechanism. Use timestamp synchronization technology to unify the time of each terminal. Regularly calibrate the equipment parameters and model verification results to correct system errors. When the communication link is interrupted, the UAV terminal automatically caches relevant data and uploads it first after the connection is restored. The edge terminal starts the timeout retransmission mechanism. When the flight control system detects that the attitude adjustment exceeds the safe range, it automatically triggers emergency correction to ensure flight safety.
[0122] This step employs network time protocol timestamp synchronization technology to unify the system time across the drone, edge, and cloud, keeping the time synchronization error within 1ms. Weekly calibration of the drone's camera intrinsics, IMU parameters, and model validation results is performed, and inherent system errors are corrected using standard crack samples to ensure detection accuracy. In the event of a communication link interruption, the drone automatically caches acquired images, recognition results, and device parameters using its local large-capacity storage module, prioritizing the uploading of cached data upon reconnection. The edge device initiates a timeout retransmission mechanism, retransmitting supplementary shooting commands that have not received feedback from the drone at 30-second intervals, up to a maximum of three retransmissions. The flight control system monitors attitude adjustment parameters in real time. If the pitch angle exceeds ±30° or the yaw angle exceeds ±45°, an emergency correction procedure is immediately triggered to adjust the drone to a safe horizontal attitude, ensuring safe flight operations.
[0123] Step S150: Import the bridge BIM model preset path, dynamically adjust the path priority during flight by combining visual perception and crack heat map, and ensure effective data collection in the whole area through multi-objective optimization and local replanning.
[0124] In this step, a detailed BIM model of the bridge is imported into the UAV flight control system. Based on the bridge's structural features, key stress areas, and bottom component distribution from the BIM model, a basic UAV flight path is pre-set, ensuring a coverage of ≥95% and an overlap rate of ≥70% between adjacent images. During flight, the UAV uses real-time environmental perception data from the visual perception module to identify obstructions in the path. Simultaneously, based on the crack heatmap generated in real-time by the lightweight AI model, the path priority is dynamically adjusted, prioritizing areas with dense cracks, main beams, piers, and other key stress areas for image acquisition. If obstructions are detected in the pre-set path, or if the UAV cannot reach certain areas, a multi-objective optimization algorithm is used to locally replan the path, optimizing coverage, detection accuracy, and flight efficiency. The flight trajectory is adjusted in real-time to ensure effective acquisition of the entire bridge bottom surface without any omissions.
[0125] Step S160: Construct a visual SLAM, IMU, and reference marker fusion positioning system, calculate the UAV pose in the GPS failure area and optimize it through filtering, and map the crack to the BIM model through coordinate association.
[0126] In this step, the hardware deployment and system setup for visual SLAM, IMU, and reference marker fusion positioning were completed first. Reference markers were deployed in key areas of the bridge, and joint calibration and time synchronization of multi-device parameters were completed. After the UAV entered the GPS failure zone, the bridge feature points were extracted using visual SLAM, and the initial pose was calculated using the reference markers. Simultaneously, the raw IMU data was preprocessed, and pose prediction was completed based on the inertial navigation model. A fusion filtering framework was constructed to fuse and optimize the two types of pose data. The optimization results were calibrated and corrected using the absolute coordinates of the reference markers to eliminate cumulative drift. Based on the calibration parameters and high-precision fused pose, a complete transformation link from crack pixel coordinates to the BIM model coordinate system was established, accurately mapping crack features to the bridge BIM model. Crack quantification parameters were associated to complete visualization marking, achieving accurate UAV pose calculation in the GPS failure zone and accurate association between cracks and the BIM model.
[0127] Step S161: Deploy the fusion positioning hardware and reference marking system. The UAV is equipped with a binocular vision sensor, a high sampling rate IMU and a high-definition camera. High-contrast reference markings are set in the key areas of the bridge. The absolute coordinates of the reference markings in the world coordinate system are measured in advance and entered into the system. The joint calibration of the camera intrinsic parameters and IMU parameters is completed. The data acquisition time of the vision sensor, IMU and camera is aligned through the timestamp synchronization module.
[0128] In this step, the UAV is equipped with a binocular vision sensor, a high-sampling-rate IMU, and a high-definition industrial camera. High-contrast reference marks are deployed in key load-bearing components such as the main beam, piers, and supports of the bridge. The absolute coordinates of these reference marks in the world coordinate system are obtained using professional measuring instruments and entered into the system according to the mark numbers. Camera intrinsic parameters are calibrated using the Zhang calibration method, and parameters such as IMU zero bias and scale factor are calibrated using a dedicated calibration platform. Simultaneously, joint calibration of the camera and IMU is performed to calculate the extrinsic parameter conversion relationship between them. A hardware-triggered timestamp synchronization module is built to perform time calibration on the signals acquired by the vision sensor, IMU, and camera, achieving time alignment of data acquisition from multiple devices and ensuring the time consistency of multi-source data for subsequent pose fusion calculation.
[0129] Step S162: Initial visual SLAM pose calculation is performed in the GPS failure area. After the UAV enters the GPS occlusion area, the visual sensor collects images in real time, extracts the natural feature points of the bridge and the reference markers in the images and performs feature tracking, constructs a local feature map, strengthens the feature matching priority of the reference markers for sparse feature areas, solves the initial pose of the camera by combining the PnP algorithm with ICP point cloud registration, and outputs the pose data and confidence.
[0130] In this step, after the UAV enters the GPS-deficient area such as the bridge underside, the binocular vision sensor acquires images of the bridge underside in real time at a preset frequency. A feature extraction algorithm extracts natural feature points of the bridge structure and baseline marker feature points from the images. A feature tracking algorithm completes cross-frame feature point matching, and a local feature map of the bridge underside is constructed based on the matching results. For sparsely characterized areas such as areas with simple concrete textures, the system automatically increases the matching priority of baseline marker feature points, prioritizing their feature tracking and matching. The PnP algorithm is used to initially solve the camera pose, and then the ICP point cloud registration algorithm is used to optimize and correct the initial pose. Finally, the initial camera pose data and corresponding confidence index are output, providing effective observation data for subsequent pose fusion calculations.
[0131] Step S163: Preprocess the IMU data and predict the inertial pose, remove the zero-bias drift and high-frequency noise from the IMU data, and use the high-frequency IMU data to predict the UAV pose changes in real time based on the inertial navigation solution model, generating a continuous inertial pose sequence.
[0132] In this step, the raw angular velocity and acceleration data acquired by the IMU undergo full-process preprocessing. A zero-bias estimation algorithm removes zero-bias drift from the data, and a low-pass filtering algorithm filters out high-frequency noise, resulting in interference-free, clean IMU measurement data. Based on the strapdown inertial navigation solution model, the preprocessed IMU data is substituted into the solution formula. Leveraging the IMU's high sampling rate, the dynamic changes in the UAV's attitude, position, and velocity are calculated in real time, generating a continuous inertial pose sequence through recursive calculation. This inertial pose sequence can compensate for the pose calculation gaps in visual SLAM when features are sparse and images are blurred, providing continuous pose prediction data for the subsequent fusion filtering framework and ensuring the continuity of pose calculation.
[0133] Step S164: Construct a fusion filtering framework to achieve fusion optimization of visual SLAM and IMU. Use the IMU inertial pose prediction result as the filter prediction value and the visual SLAM initial pose data as the observation value. Design the state equation and observation equation. Dynamically adjust the weight ratio of the two types of data through residual calculation and covariance update. Iteratively optimize to obtain the high-precision UAV pose estimation result in the world coordinate system.
[0134] In this step, a fusion filtering framework for visual SLAM and IMU is constructed based on extended Kalman filtering. The IMU inertial pose prediction result is used as the prior prediction value of the filtering system, and the initial pose data calculated by visual SLAM is used as the observation value of the filtering system. The state equation of the filtering system is designed based on the kinematic characteristics of the UAV, and the observation equation is designed based on the error characteristics of visual SLAM pose calculation. The prior prediction of UAV pose is completed through the state equation. The residual between the observation value and the prior prediction value is calculated, and the covariance matrix of the filtering system is dynamically updated according to the residual calculation result. This adaptively adjusts the weight ratio of IMU and visual SLAM data. After multiple rounds of iterative optimization, the high-precision UAV pose estimation result in the world coordinate system is output.
[0135] Step S165: Perform absolute coordinate calibration and error correction based on the reference mark. After the UAV recognizes the reference mark, it calculates the relative pose through the PnP algorithm and back-calculates the absolute pose of the UAV by combining the known absolute coordinates of the reference mark. The absolute pose is used as the calibration value to correct the pose result after fusion filtering. The calibration cycle is set to complete the global calibration to eliminate cumulative drift.
[0136] In this step, after the UAV identifies the reference markers on the bridge during flight, it extracts the feature points of the reference markers in real time and calculates the UAV's pose data relative to these reference markers using the PnP algorithm. Combined with the pre-entered absolute coordinates of the reference markers in the world coordinate system, the absolute pose of the UAV in the world coordinate system is derived through coordinate transformation formulas. This absolute pose is used as a calibration value to correct the pose results output by the fusion filtering framework, eliminating accumulated errors generated during the filtering process. Simultaneously, a fixed calibration cycle is set for the system; the UAV completes a global calibration every preset flight distance or duration, continuously correcting deviations in subsequent pose calculation results to ensure the accuracy of pose calculations during long-term UAV flight.
[0137] Step S166: Implement crack coordinate mapping and BIM model association. Based on camera calibration parameters and fused UAV pose, establish crack pixel coordinate transformation link, transform to camera coordinate system and world coordinate system in sequence, and then map to BIM model coordinate system through preset coordinate system transformation matrix. Associate crack quantization parameters, mark crack related information in BIM model and generate BIM model instance with crack attributes.
[0138] In this step, based on the previously completed camera intrinsic and extrinsic parameters and the joint calibration parameters of the equipment, as well as the high-precision pose data of the UAV after fusion filtering, a complete crack pixel coordinate transformation link is established. First, the pixel coordinates of the crack in the acquired image are transformed to the camera coordinate system through the camera projection model. Then, the crack coordinates in the camera coordinate system are transformed to the world coordinate system using a coordinate transformation matrix. The preset transformation matrix between the world coordinate system and the BIM model coordinate system is retrieved from the system to accurately map the crack coordinates in the world coordinate system to the BIM model coordinate system. The two-dimensional and three-dimensional quantization parameters of the crack are associated with the corresponding bridge component positions in the BIM model. The crack positions are then visually marked in the BIM model, generating a BIM model instance with complete crack attribute information.
[0139] Step S167: Conduct system accuracy verification and parameter optimization. Compare the positioning results of the benchmark markers with the known absolute coordinates to calculate the positioning error. Adjust the fusion filter parameters, feature extraction matching threshold, and IMU calibration parameters. Conduct tests in different bridge structure areas to verify the stability of the system under GPS failure scenarios and ensure that the coordinate error of the crack mapping to the BIM model meets the engineering requirements.
[0140] In this step, bridges of different structural types, such as beam bridges, arch bridges, and cable-stayed bridges, were selected. Accuracy verification tests of the fusion positioning system were conducted in the bottom areas where GPS failed. The positioning results of the system on the reference markers were collected and compared with the known absolute coordinates of the pre-measured reference markers to calculate relevant positioning error indicators. Based on the error analysis results, core parameters such as the process noise covariance and observation noise covariance of the fusion filtering framework were adjusted, the matching threshold for feature extraction was optimized, and calibration parameters such as the IMU's zero bias and scaling factor were corrected. Tests were repeatedly conducted in different areas of the bridge, including feature-dense areas, feature-sparse areas, and component connections, to verify the stability of the system's long-term continuous operation under GPS failure scenarios. System parameters were continuously iterated and adjusted until the coordinate error of the crack mapping to the BIM model met the engineering and technical requirements for bridge inspection, completing the overall system parameter optimization.
[0141] Based on the same inventive concept, please refer to Figure 2 The diagram shows a schematic block diagram of a bridge underside crack detection system 100 based on UAV and AI, which is provided in an embodiment of this application for performing the above-described bridge underside crack detection method based on UAV and AI. The bridge underside crack detection system 100 based on UAV and AI may include a communication unit 110, a machine-readable storage medium 120, and a processor 130.
[0142] In this embodiment, both the machine-readable storage medium 120 and the processor 130 are located within the UAV-based and AI-powered bridge underside crack detection system 100 and are separately configured. However, it should be understood that the machine-readable storage medium 120 may also be independent of the UAV-based and AI-powered bridge underside crack detection system 100 and may be accessed by the processor 130 via a bus interface. Alternatively, the machine-readable storage medium 120 may be integrated into the processor 130 and may communicate with external systems via the communication unit 110.
[0143] The processor 130 is the control center of the UAV-based AI-powered bridge underside crack detection system 100. It connects various parts of the system via various interfaces and lines, and performs overall monitoring of the system by running or executing software programs and / or modules stored in the machine-readable storage medium 120, and by accessing data stored in the machine-readable storage medium 120. Optionally, the processor 130 may include one or more processing cores; for example, it may integrate an application processor and a modem processor, where the application processor primarily handles the operating system, user interface, and applications, and the modem processor primarily handles wireless communication. It is understood that the modem processor may also not be integrated into the processor. The machine-readable storage medium 120 is used to store machine-executable instructions for executing the scheme of this application, and the processor 130 is used to execute the machine-executable instructions stored in the machine-readable storage medium 120 to implement the bridge bottom surface crack detection method based on UAV and AI provided in the aforementioned method embodiment.
[0144] It should be noted that, in order to simplify the description of the present invention and thus help to understand one or more embodiments of the invention, multiple features may sometimes be grouped into one embodiment, drawing or description thereof in the foregoing description of the embodiments of the present invention.
Claims
1. A method for detecting cracks on the underside of bridges based on drones and AI, characterized by: Includes the following steps: A basic dataset is constructed by collecting various bridge underside images. Annotated samples are synthesized using GAN parameterization to supplement the data. The annotation process is optimized by combining weakly supervised learning with active learning. The preprocessing stage optimizes the image using multi-scale denoising, illumination normalization, and angle correction, based on an improved U-Net fusion of CNN and Transformer; A two-dimensional and three-dimensional quantization system is constructed. In the two-dimensional system, the length and width of the crack are measured by sub-pixel segmentation, skeleton extraction and minimum bounding rectangle, and gray-level gradient method. In the three-dimensional system, the point cloud is reconstructed by SFM and stereo matching, and the depth is calculated by mapping the two-dimensional crack. A mapping model between quantization parameters and damage level is established, and a standardized assessment report is output. A three-tier collaborative architecture is built, including lightweight AI on the drone side to identify suspected cracks, high-precision verification and feedback at the edge, and the flight control system adjusting attitude and reshooting based on the feedback. Import the bridge BIM model preset path, and dynamically adjust the path priority in flight by combining visual perception and crack heat map. Ensure effective data collection in the whole area through multi-objective optimization and local replanning. A fusion positioning system integrating visual SLAM, IMU, and reference markers was constructed. The pose of the UAV in the GPS failure zone was calculated and optimized by filtering. The cracks were mapped to the BIM model through coordinate association.
2. The method for detecting cracks on the underside of bridges based on unmanned aerial vehicles and AI according to claim 1, characterized in that: The process involves collecting various bridge underside images to construct a basic dataset, supplementing the data with labeled samples synthesized using GAN parameterization, and optimizing the labeling process through a combination of weakly supervised learning and active learning. This includes: Determine the coverage area for different bridge types, plan the bottom surface inspection area for bridges with different service years and disease development stages, identify the crack morphology and interference sample types to be collected, select a drone equipped with a high-definition camera and macro lens and set reasonable flight parameters, record the lighting, shooting angle and environmental parameters simultaneously during the collection process, and perform distortion correction, cropping, grayscale stretching and invalid image screening on the original images to form a basic dataset. The StyleGAN2 architecture was selected to build a crack generation model. The generator and discriminator structures were optimized. Pre-training was completed based on the basic dataset, enabling the model to learn the characteristics and patterns of real cracks and interference samples. A parameterized control module was designed to set adjustable parameter dimensions related to crack geometry, acquisition environment, and background interference, supporting the generation of diverse samples. Initiate batch image generation, generate samples by random combination of parameters, automatically complete crack annotation using generated parameters, evaluate the quality of synthesized data using FID index, screen high-quality samples that are similar to the distribution of real data, and remove invalid samples with distorted shape and unnatural texture. The selected synthetic samples are mixed with the real base dataset in proportion to construct a hybrid training set. Some samples in the hybrid training set are manually and finely annotated as seed annotation data for weakly supervised learning. A lightweight backbone network combined with a fully convolutional network was selected to construct a weakly supervised segmentation model. The model was pre-trained using seed labeled data. The pre-trained model was used to infer and generate initial pseudo-labels from unlabeled data. A confidence threshold was set to filter out high-confidence pseudo-labels and include them in the labeling pool. A self-supervised pre-training strategy is adopted to optimize the model. Various data augmentation methods are used to enable the model to learn crack invariance features. Based on the optimized model, pseudo-labels are regenerated. The label pool is iteratively updated and low-quality pseudo-labels are removed. An active learning sampling strategy is designed. High-value samples are selected by combining uncertainty sampling and diversity sampling. After being submitted for fine manual labeling, they are added to the seed labeling data. The weakly supervised model is retrained using the updated seed-labeled data. The process of generating pseudo-labels, selecting high-value samples, manually labeling, and iterating the model is repeated. The model performance is evaluated after each iteration. The iteration is stopped when the performance improvement is lower than a preset threshold, and finally a complete high-quality labeled dataset is formed.
3. The method for detecting cracks on the bottom surface of bridges based on UAVs and AI according to claim 2, characterized in that: The StyleGAN2 architecture is selected to construct the crack generation model. The generator and discriminator structures are optimized, and pre-training is completed based on a basic dataset. This allows the model to learn the characteristics and patterns of real cracks and interference samples. A parameterized control module is designed to set adjustable parameter dimensions related to crack geometry, acquisition environment, and background interference, supporting diverse sample generation, including: The StyleGAN2 generator structure was optimized by introducing a multi-level, multi-scale convolution module on the basis of the original architecture, adjusting the generator upsampling module to a transposed convolution combined with pixel shuffling, fusing the background interference sample features of the bridge bottom surface in the generator feature extraction layer, and adapting the generator output layer to the channel format of the bridge detection image. The StyleGAN2 discriminator structure is optimized by adding a texture perception branch and an interference feature discrimination branch to the basic discriminator architecture. The texture perception branch extracts local features of cracks through shallow small convolutional kernels, and the interference feature discrimination branch identifies background interference and fusion naturalness. A multi-scale downsampling module is added to the discriminator, and spectral normalization technology is adopted. A model training framework was built, and crack feature constraint loss and interference sample fusion loss were added on the basis of the original adversarial loss and style loss. The AdamW optimizer was selected and an adaptive learning rate decay strategy was configured. At the same time, the batch training scale was set to adapt to the hardware computing power. Based on the basic dataset of cracks on the bottom of bridges, the model is pre-trained. First, a low learning rate is used for cold start training, and then the formal pre-training stage is entered. The visual effect of the generated image and the convergence status of the loss function are monitored in real time. When the adversarial loss tends to be stable and the generated image has no obvious morphological distortion, targeted fine-tuning training is carried out for the difficult-to-identify crack samples until the model can stably generate crack images that conform to the real feature rules. The overall architecture of the parameterized control module is designed, and the module is seamlessly connected to the generator's input layer as a front-end control unit. It is divided into three independent parameter sub-modules: crack geometry, acquisition environment, and background interference. A parameter mapping layer is designed within the module to convert manually set parameter values into feature vectors that the generator can recognize. The three parameter submodules are configured with adjustable parameters and mechanisms for their respective dimensions. The crack geometry parameter submodule controls the geometric features of the crack. The acquisition environment parameter submodule simulates changes in the acquisition environment of the generated image by adjusting the corresponding feature layer of the generator. The background interference parameter submodule controls the performance of background interference features. All parameters in each dimension support gradient adjustment. To achieve linkage and adaptation between the parameterized control module and the StyleGAN2 generator, the feature vector output by the parameterized control module is fused with the original random noise vector of the generator as the joint input of the generator. The parameter combination adjustment logic that supports single-parameter independent gradient adjustment and multi-parameter random combination adjustment is designed, and a parameter validity verification mechanism is added. The parameterized control function was verified and the overall model was optimized. First, single-parameter adjustment was verified, and then multi-parameter combination was verified. For the problems that occurred during the verification process, the weight coefficients of the parameter mapping layer and the network parameters of the corresponding feature layer of the generator were adjusted to complete the overall model optimization.
4. The bridge underside crack detection method based on UAV and AI according to claim 1, characterized in that: The preprocessing stage optimizes the image using multi-scale denoising, illumination normalization, and angle correction, based on an improved U-Net fusion of CNN and Transformer, including: The images of the bridge's underside are preprocessed in a full-process manner. First, the bridge's structural feature points are extracted using the SIFT algorithm. After matching, the homography transformation matrix is solved and perspective transformation is performed to achieve angle correction. The consistency is verified by the feature point matching degree. Then, the images are divided into scale levels according to resolution. Shallow low-scale images are denoised using bilateral filtering, and deep high-scale images are denoised using nonlocal mean filtering. The original resolution is restored by feature fusion. Finally, the images are converted to grayscale space, and the illumination is optimized using the CLAHE algorithm and adaptive gamma correction. Then, the pixel values are normalized to a specified range to achieve feature standardization. The basic U-Net network architecture is built, retaining the classic symmetrical encoder-decoder structure and skip connection mechanism of U-Net. The step size of encoder downsampling and decoder upsampling is adjusted in a targeted manner, and the skip connection path is optimized. A dual-branch feature extraction module is constructed. On the one hand, a CNN feature extraction encoder is built with a lightweight residual convolutional network as the backbone. Stacked convolution, batch normalization and activation function layers are downsampled layer by layer. A multi-scale dilated convolution module is introduced to extract and output multi-scale CNN local feature maps. On the other hand, a Transformer global feature enhancement module is designed to flatten the deep CNN feature map and map it into a feature sequence and add position encoding. Global correlation features are captured through a multi-head self-attention mechanism. After reinforcement learning by a feedforward neural network, the global feature map is output and then restored to the dimension and resolution that match the CNN feature map. A feature fusion layer is established between CNN and Transformer. A feature fusion layer is set between the encoder and decoder. The local feature maps of CNN at each scale are concatenated with the global feature maps of Transformer. The dimension fusion and feature compression are completed by a 1×1 convolution kernel to generate a hybrid feature map. During the upsampling process of the decoder, the fused feature map is fused with the corresponding shallow CNN feature map of the encoder again through skip connections. The decoder and output layer are optimized. The decoder adopts a transposed convolution combined with pixel shuffling upsampling method to upsample the fused feature map layer by layer to the same resolution as the original image. In the last layer of the decoder, a spatial attention mechanism is introduced to generate a pixel-level attention weight map to focus on the crack region and suppress background interference. The output layer outputs a pixel-level crack segmentation probability map through the sigmoid activation function. End-to-end training and targeted fine-tuning of the U-Net model were carried out. The model was trained using a bridge bottom crack annotation dataset. A segmentation task-adaptive loss function was selected, and an adaptive learning rate decay strategy and optimizer were configured. The network parameters were iteratively optimized through forward and backward propagation. The crack segmentation accuracy index was monitored in real time during training. Targeted fine-tuning was carried out to address the difficulties in identifying small cracks and fuzzy cracks until the model stably outputs high-precision crack segmentation results.
5. The bridge underside crack detection method based on UAV and AI according to claim 4, characterized in that: The aforementioned construction of the U-Net basic network architecture retains the classic U-Net encoder-decoder symmetrical structure and skip connection mechanism, specifically adjusts the step size of encoder downsampling and decoder upsampling, and optimizes the skip connection path, including: Based on the image features and scale features of cracks on the bottom of bridges, a U-Net basic framework is built. The classic U-Net encoder-decoder symmetrical hierarchical structure and the core mechanism of skip connection for passing shallow features of the encoder to the corresponding layer of the decoder are retained. An input layer adapted to the bridge detection image is configured, and a downsampling and upsampling hierarchical structure with one-to-one correspondence between the encoder and the decoder is set. To address the crack features on the bridge bottom surface, the encoder downsampling step size was adjusted accordingly. A downsampling combination that combines crack detail preservation with global feature capture was adopted. The decoder upsampling step size and implementation method were adjusted synchronously to ensure that the scaling ratio of the decoder and encoder downsampling at the corresponding level is consistent, thereby achieving feature map dimension matching. Furthermore, the number of feature map channels was adjusted after each level of upsampling in the decoder. The feature transmission path of the skip connection is optimized. A lightweight feature filtering module is added to the output end of each level of the encoder to perform redundant filtering and retain effective features of the encoder output features. A feature alignment module is designed at the input end of each level of the decoder to perform spatial position correction of the feature map transmitted by the encoder. At the same time, the feature fusion method of the skip connection is reconstructed. A feature fusion layer is set at the corresponding level input end of the decoder to fuse and integrate the shallow features of the encoder after filtering and alignment with the deep features of the decoder after upsampling. The feature transmission link of the skip connection is also optimized. The hierarchical connection relationship of the fixed U-Net basic architecture is defined, the skip connection matching relationship of the corresponding layers of the encoder and decoder is clarified, the convolutional layers and activation functions of each layer of the architecture are uniformly configured, the feature map resolution remains unchanged and the non-linear expressive ability of feature extraction is guaranteed, and standardized feature input and output interfaces are reserved for subsequent fusion of local feature extraction module and global feature enhancement module. Architecture dimension matching and forward propagation verification were carried out. The preprocessed image of the crack on the bottom of the bridge was input for architecture forward propagation. The dimension parameters of the feature maps at each level of the encoder and decoder were verified layer by layer. The dimension consistency of the feature maps at the jump connection was verified as a key point. The dimension mismatch problem was corrected. At the same time, the information integrity of the feature transmission link and the effectiveness of the feature extraction and transmission functions were verified. While ensuring the symmetric structure of the encoder and decoder and the optimization effect of skip connections, the basic architecture is optimized for lightweight adaptation. The number of feature channels at each level is configured differently, and lightweight convolution is used to reduce the number of model parameters and computation. This adapts to the deployment requirements of edge devices while maintaining the feature extraction performance of the architecture, thus completing the construction of the U-Net basic network architecture.
6. The method for detecting cracks on the underside of bridges based on unmanned aerial vehicles and AI according to claim 5, characterized in that: The feature fusion between CNN and Transformer is established by setting a feature fusion layer between the encoder and decoder. Local feature maps of CNN at various scales are concatenated with global feature maps of Transformer. Dimensional fusion and feature compression are achieved using 1×1 convolutional kernels to generate a hybrid feature map. During the decoder upsampling process, the fused feature map is fused again with the corresponding shallow CNN feature map from the encoder through skip connections. This includes: Multi-scale CNN local feature maps and Transformer global feature maps are pre-aligned in terms of dimensions. Multi-scale CNN local feature maps output by the encoder and dimensionally restored Transformer global feature maps are extracted. A one-to-one correspondence matching relationship is established according to the scale level. Feature maps with different resolutions are adjusted to the same size by interpolation or cropping. Feature maps with inconsistent channel numbers are adapted by 1×1 convolution kernel to adjust the channel number, ensuring that the resolution and channel number of the two types of feature maps are consistent at the same scale. A multi-scale feature fusion layer is built in the feature transfer link between the U-Net encoder and decoder. The number of independent fusion sub-modules is divided according to the scale level of CNN and Transformer features. The fusion layer adopts a parallel structure design and reserves a feature caching interface. The first feature fusion is performed in each scale fusion submodule. The local feature map of the same scale CNN with pre-aligned dimension is concatenated with the global feature map of Transformer by channel dimension to form a concatenated feature map. After the concatenated feature map is connected to a 1×1 convolution kernel to complete cross-channel fusion and dimension compression, generating a mixed feature map of each scale. After the mixed feature map is scale-labeled, it is stored in the feature cache pool that is managed by scale level partitioning. The second feature fusion and feature integration are performed in conjunction with the decoder upsampling process. After each level of upsampling, the decoder retrieves the matching mixed feature map from the feature buffer pool and superimposes it with the upsampled feature map. Then, the shallow CNN feature map of the corresponding level of the encoder is introduced through skip connections and the superimposed feature map is concatenated again. After concatenation, a lightweight feature integration module composed of 3×3 convolution kernels is added to perform feature aggregation and generate the decoder input feature map. Establish a hierarchical linkage mechanism between feature fusion and decoder upsampling. Before the upsampling operation is started, the corresponding mixed feature map is retrieved. After the upsampling is completed, the secondary feature fusion and integration are performed immediately. At the same time, feature monitoring interfaces are set at each level of feature fusion node to provide real-time feedback on the resolution, number of channels and effective feature values of the feature map. To conduct forward propagation verification of the entire feature fusion process, a preprocessed image of the cracks on the bottom of a bridge is input. The features are sequentially processed through CNN feature extraction, Transformer global enhancement, first feature fusion, decoder upsampling, second feature fusion, and feature integration. The dimensionality consistency of the feature maps at each stage is verified layer by layer. The effect of the fused features on preserving local details and global structural features of the cracks is verified by visualizing the feature maps. Based on the feature fusion effect, the parameters are fine-tuned and optimized. If the local detail features are weakened, the channel compression ratio of the 1×1 convolution kernel is adjusted. If the global structural features are not sufficiently expressed, the concatenation weight of the two types of feature maps is optimized. At the same time, the convolution parameters of the 3×3 convolution kernel are adjusted to optimize the feature aggregation effect.
7. The method for detecting cracks on the underside of bridges based on unmanned aerial vehicles and AI according to claim 1, characterized in that: The aforementioned construction of a two-dimensional and three-dimensional quantization system involves measuring crack length and width in the two-dimensional phase using sub-pixel segmentation, skeleton extraction, minimum bounding rectangle, and gray-level gradient methods. In the three-dimensional phase, point clouds are reconstructed using SFM and stereo matching to map the two-dimensional crack depth. A mapping model between quantization parameters and damage levels is established, and a standardized assessment report is output, including: Two-dimensional crack geometric parameter quantization was carried out. Sub-pixel segmentation optimization was performed based on crack pixel-level segmentation results. Crack skeleton was extracted and disconnected areas were repaired. Two-dimensional quantization of crack length and width was completed by combining skeleton analysis and edge detection methods. Outlier filtering was performed on the quantization results. A three-dimensional point cloud model of the bridge bottom surface was constructed and three-dimensional quantization was completed. Based on the sequence of images collected by UAV, a three-dimensional point cloud model was constructed through feature association and three-dimensional reconstruction algorithms. The spatial registration relationship between two-dimensional images and three-dimensional point clouds was established. Two-dimensional crack features were mapped to three-dimensional point clouds. Crack depth and three-dimensional spatial parameters were calculated by fitting the reference surface. Integrate two-dimensional and three-dimensional quantization parameters and perform standardization processing to form a multi-dimensional crack quantization parameter set. Refer to industry standards to normalize and standardize the parameters and construct a standardized quantization feature library. A mapping model between crack quantification parameters and damage levels was established. Damage level classification standards were formulated in combination with bridge structural characteristics and industry assessment specifications. A training sample library containing standardized quantification parameters and corresponding damage level labels was constructed. A classification regression algorithm was used to build the mapping model, and the model performance was optimized through training, verification, and testing. Establish a dynamic calibration mechanism for the mapping model, apply the model to actual detection and compare the prediction results with the manual evaluation results, analyze the reasons for the deviation, and achieve dynamic iterative optimization of the model by supplementing quantitative indicators, adjusting the level threshold or updating the sample library; Generate a standardized damage assessment report. Based on a preset report framework, automatically extract quantitative parameters, spatial distribution characteristics, and damage level prediction results. After graphical display and disease risk analysis, output a standardized report containing treatment recommendations, while retaining data traceability and association management interfaces.
8. The method for detecting cracks on the underside of bridges based on unmanned aerial vehicles and AI according to claim 1, characterized in that: The aforementioned three-tiered collaborative architecture, encompassing edge-cloud, includes lightweight AI identification of suspected cracks on the drone end, high-precision verification and feedback at the edge, and attitude adjustment and reshooting by the flight control system based on the feedback. The system deploys a three-tiered collaborative hardware and communication link between the edge and cloud. The drone is equipped with lightweight edge computing, image acquisition, sensing, and multi-mode communication modules. The edge is equipped with an edge server with integrated computing power and a high-speed data receiving module. Data storage and global scheduling nodes are deployed in the cloud. A low-latency, high-bandwidth transmission link is built using a dual-mode communication architecture. The system defines the bidirectional data interaction protocol between the drone and the edge, and specifies the transmission format and priority of suspected crack data, verification results, and reshoot instructions. A lightweight AI model is deployed on the drone. During the drone's flight, the image acquisition device continuously acquires images of the bridge's underside according to preset parameters. After lightweight preprocessing, the images are input into the lightweight AI model, which identifies suspected crack areas in real time and outputs relevant area information and equipment status parameters during acquisition. The suspected area data is transmitted to the edge terminal via the communication link. A high-precision crack detection model is deployed at the edge. After receiving data uploaded by the drone, high-precision inference verification is initiated. The model distinguishes between real cracks and background interference through pixel-level segmentation, evaluates the integrity and clarity of cracks and determines whether reshooting is needed. For areas that do not meet the standards, the model analyzes the causes of defects, generates targeted reshooting instructions that include target reshooting positions, attitude adjustment parameters, and shooting parameter suggestions, and marks the priority. After receiving the reshoot command, the drone flight control system calculates the deviation between the current state and the target state by combining its own sensor unit and positioning data. It then dynamically adjusts the flight parameters through the control algorithm to ensure that the drone accurately arrives at the reshoot area and aligns with the suspected area from the optimal perspective. During the adjustment process, the progress is fed back to the edge device in real time, and the edge device dynamically corrects the reshoot command based on the feedback. The drone performs reshoots according to the adjusted parameters. The lightweight AI model re-identifies and confirms the reshoot images. Once the requirements are met, the reshoot data is uploaded to the edge device. The edge device performs secondary verification through a high-precision model. After confirming that the crack features have been completely extracted, the final verification result is generated. If the standard is not met, the feedback, adjustment, and reshoot process is repeated to form a collaborative closed loop. The three-level collaborative scheduling and load balancing strategy is optimized. The edge terminal prioritizes the data uploaded by multiple drones and dynamically allocates computing resources through the task scheduling module. The drone terminal adopts a data fragmentation transmission mechanism to reduce bandwidth consumption. The cloud synchronizes the edge terminal verification results, drone flight data and crack-related information in real time and builds a global data index. Establish a system synchronization calibration and fault tolerance mechanism. Use timestamp synchronization technology to unify the time of each terminal. Regularly calibrate the equipment parameters and model verification results to correct system errors. When the communication link is interrupted, the UAV terminal automatically caches relevant data and uploads it first after the connection is restored. The edge terminal starts a timeout retransmission mechanism. When the flight control system detects that the attitude adjustment exceeds the safe range, it automatically triggers emergency correction to ensure flight safety.
9. The method for detecting cracks on the underside of bridges based on unmanned aerial vehicles and AI according to claim 1, characterized in that: The construction of a visual SLAM, IMU, and reference marker fusion positioning system, the calculation of UAV pose in the GPS failure zone followed by filtering and optimization, and the mapping of cracks to the BIM model through coordinate association include: Deploy integrated positioning hardware and reference marking system. The UAV is equipped with binocular vision sensor, high sampling rate IMU and high-definition camera. High contrast reference marks are set in key areas of the bridge. The absolute coordinates of the reference marks in the world coordinate system are measured in advance and entered into the system. The joint calibration of camera intrinsic parameters and IMU parameters is completed. The data acquisition time of vision sensor, IMU and camera is aligned through the timestamp synchronization module. Initial visual SLAM pose calculation is performed in the GPS-invalidated area. After the UAV enters the GPS-obscured area, the visual sensor acquires images in real time, extracts natural feature points of the bridge and reference marks in the images and performs feature tracking, constructs a local feature map, strengthens the feature matching priority of the reference marks for sparse feature areas, and solves the initial pose of the camera by combining the PnP algorithm with ICP point cloud registration and outputs pose data and confidence. IMU data is preprocessed and inertial pose prediction is performed to remove zero-bias drift and high-frequency noise from the IMU data. Based on the inertial navigation solution model, the UAV pose change is predicted in real time using high-frequency IMU data to generate a continuous inertial pose sequence. A fusion filtering framework is constructed to achieve the fusion optimization of visual SLAM and IMU. The IMU inertial pose prediction result is used as the filtered prediction value, and the visual SLAM initial pose data is used as the observation value. The state equation and observation equation are designed. The weight ratio of the two types of data is dynamically adjusted through residual calculation and covariance update. The high-precision UAV pose estimation result in the world coordinate system is obtained through iterative optimization. Absolute coordinate calibration and error correction are performed based on reference markers. After the UAV recognizes the reference markers, the relative pose is calculated by the PnP algorithm and the absolute pose of the UAV is inferred by combining the known absolute coordinates of the reference markers. The absolute pose is used as the calibration value to correct the pose result after fusion filtering. The calibration cycle is set to complete the global calibration to eliminate cumulative drift. To achieve the mapping of crack coordinates and the association with the BIM model, a crack pixel coordinate transformation link is established based on the camera calibration parameters and the fused UAV pose. The crack coordinates are transformed sequentially to the camera coordinate system and the world coordinate system, and then mapped to the BIM model coordinate system through a preset coordinate system transformation matrix. Crack quantization parameters are associated, crack-related information is marked in the BIM model, and a BIM model instance with crack attributes is generated. System accuracy verification and parameter optimization were carried out. The positioning error was calculated by comparing the positioning results of the benchmark marker with the known absolute coordinates. The fusion filter parameters, feature extraction matching threshold and IMU calibration parameters were adjusted. Tests were conducted in different bridge structure areas to verify the stability of the system under GPS failure scenarios and ensure that the coordinate error of the crack mapping to the BIM model meets the engineering requirements.
10. A bridge underside crack detection system based on drones and AI, characterized in that, include: processor; A machine-readable storage medium for storing machine-executable instructions of the processor; The processor is configured to execute the bridge underside crack detection method based on drones and AI as described in any one of claims 1 to 9 by executing the machine-executable instructions.