Steel bridge corrosion evaluation method and system based on instance segmentation and image fusion

Through the method based on instance segmentation and image fusion, combined with the Yolov8-seg model and infrared temperature difference, the problem of low efficiency and accuracy of steel bridge corrosion detection is solved, the rapid and accurate identification of steel bridge corrosion is achieved, and the safety and stability of the bridge are ensured. sex.

CN118628456APending Publication Date: 2024-09-10NANJING URBAN CONSTR MUNICIPAL ENG MANAGEMENT CO LTD +1
View PDF 0 Cites 5 Cited by

Patent Information

Application Number
CN202410753424.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-12
Publication Date
2024-09-10

AI Technical Summary

Technical Problem

The existing steel bridge corrosion detection methods have low efficiency and accuracy, making it difficult to identify and evaluate the corrosion of steel bridges in a timely and effective manner, affecting the safety and stability of the bridge.

Method used

Using a method based on instance segmentation and image fusion, the Yolov8-seg image segmentation model is used to perform instance segmentation on visible light rust images, and a comprehensive evaluation is performed based on the temperature difference in infrared rust images. The attention module and GIoU loss function are used to optimize the model. Improve recognition accuracy and speed.

Benefits of technology

It achieves rapid and accurate identification of steel bridge corrosion, ensures full identification and assessment of rusted areas, and improves detection efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118628456A
    Figure CN118628456A
Patent Text Reader

Abstract

The invention relates to the technical field of bridges, in particular to a steel bridge corrosion evaluation method and system based on instance segmentation and image fusion, and the method comprises the steps: collecting an image of a steel bridge corrosion region, and obtaining a visible light corrosion image and an infrared corrosion image; marking the visible light corrosion image to obtain a steel bridge corrosion data set; a Yov8-seg image segmentation model is constructed, a Yov8 algorithm network structure is optimized, and the Yov8 algorithm network structure is trained; performing instance segmentation on the marked visible light corrosion image in the steel bridge corrosion data set through a Yov8-seg image segmentation model to obtain a steel bridge corrosion segmentation result; the temperature difference of the steel bridge corrosion area is judged, and the steel bridge corrosion condition is comprehensively evaluated. According to the invention, the Yov8 algorithm network is improved, accurate and rapid steel bridge corrosion identification is realized, the steel bridge area with abnormal temperature in the infrared corrosion image is compared with the Yov8 algorithm network prediction area, the precision of the model is verified, and the corrosion area of the steel bridge can be fully identified.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of bridges, and in particular to a steel bridge corrosion evaluation method and system based on instance segmentation and image fusion. Background Art

[0002] Steel bridge corrosion is one of the main diseases of steel bridges, which poses a direct threat to the safety and stability of bridges. Timely detection of steel bridge corrosion is crucial to maintaining the safety and stability of bridges. With the passage of time and the influence of the external environment, the coating on the surface of the steel bridge may be corroded by corrosive substances, which will destroy the coating of the steel bridge and cause varying degrees of corrosion on the surface of the steel bridge.

[0003] At present, in order to timely discover and deal with the corrosion problem of steel bridges, the most commonly used detection methods include infrared thermal imaging detection, infrared thermal imaging detection, etc. With the rapid development of random computer vision, artificial intelligence programs have shown great potential in the field of steel bridge corrosion detection. Using artificial intelligence programs to detect the corrosion on the surface of steel bridges has become a reliable method. Based on this, the present invention designs a comprehensive evaluation method for steel bridge corrosion based on instance segmentation and image fusion. Summary of the invention

[0004] The present invention provides a steel bridge corrosion evaluation method and system based on instance segmentation and image fusion, which can effectively solve the problems in the background technology.

[0005] In order to achieve the above object, the technical solution adopted by the present invention is:

[0006] A steel bridge corrosion evaluation method based on instance segmentation and image fusion, the method comprising:

[0007] Collect images of the corroded area of ​​the steel bridge to obtain visible light corrosion images and infrared corrosion images;

[0008] Annotating the visible light corrosion image to obtain a steel bridge corrosion dataset;

[0009] Constructing a Yolov8-seg image segmentation model, optimizing the Yolov8 algorithm network structure, and training the Yolov8 algorithm network structure according to the steel bridge corrosion dataset;

[0010] Using the Yolov8-seg image segmentation model, instance segmentation is performed on the visible light corrosion images annotated in the steel bridge corrosion dataset to obtain a steel bridge corrosion segmentation result;

[0011] According to the infrared corrosion image and the steel bridge corrosion segmentation result, the temperature difference of the steel bridge corrosion area is judged, and the steel bridge corrosion condition is comprehensively evaluated.

[0012] Furthermore, the visible light corrosion image is annotated to obtain a steel bridge corrosion dataset, including:

[0013] Perform instance segmentation and annotation on the visible light corrosion image through the Labelme plug-in, annotate the steel bridge corrosion area in the visible light corrosion image according to the json format standard, and obtain a json format annotation file;

[0014] Use Python code to convert the json format annotation file into a txt format annotation file suitable for the Yolov8 algorithm network structure training;

[0015] According to the txt format annotation file, a labeled steel bridge corrosion data set is established, and the marked area is the steel bridge corrosion area.

[0016] Furthermore, the Yolov8-seg image segmentation model is constructed, the Yolov8 algorithm network structure is optimized, and the Yolov8 algorithm network structure is trained according to the steel bridge corrosion data set, including:

[0017] Configure the yaml file for the Yolov8 algorithm network structure and add an attention module to the Yolov8-seg image segmentation model;

[0018] Change the loss function of the Yolov8-seg image segmentation model to adapt to the instance segmentation task;

[0019] Using the Bayesian hyperparameter optimization method to perform hyperparameter tuning on the Yolov8-seg image segmentation model to obtain a hyperparameter model;

[0020] The steel bridge corrosion dataset is randomly divided into a validation set, a test set and a training set in proportion;

[0021] The Yolov8 algorithm network structure is trained according to the trained hyperparameter model and the validation set, test set and training set to obtain the trained Yolov8-seg image segmentation model.

[0022] Furthermore, a yaml file is configured for the Yolov8 algorithm network structure, and an attention module is added to the Yolov8-seg image segmentation model, including:

[0023] Configure a yaml file for the Yolov8 algorithm network structure to form a first network structure, and store the yaml file in the segments folder, wherein the first network structure includes: the number of instance segmentation categories, the model dimension, the backbone network, the neck network, and the head network;

[0024] Put the source code files of CoordAttentation module and ShuffleAttention module in the Yolov8 algorithm source code nn folder, and import the source code files in the tasks file;

[0025] Add the CoordAttentation attention module after the second C2f module of the backbone network;

[0026] The ShuffleAttention module is added after the 12th layer of the head network.

[0027] Furthermore, the loss function of the Yolov8-seg image segmentation model is changed to adapt to the instance segmentation task, including:

[0028] Put the GIoU loss function source code in the metrics file in the utils folder of the Yolov8 algorithm source code;

[0029] In the forward function of the BboxLoss class in the loss file, change the default loss function of the Yolov8-seg image segmentation model to the GIoU loss function.

[0030] Furthermore, the Bayesian hyperparameter optimization method is used to perform hyperparameter tuning on the Yolov8-seg image segmentation model to obtain a hyperparameter model, including:

[0031] Define the hyperparameter optimization space, select appropriate hyperparameters, and select recall as the evaluation metric for optimizing the hyperparameters;

[0032] The Bayesian hyperparameter optimization method is used to iterate the Yolov8-seg image segmentation model 100 times, and the hyperparameter with the highest recall rate is selected as the hyperparameter for training the Yolov8-seg image segmentation model.

[0033] Further, the evaluation indicator recall rate of the optimization hyperparameter is expressed by Recall, and its calculation method is as follows:

[0034]

[0035] Among them, TP represents the number of positive samples that are correctly identified, and FN represents the number of negative samples that are incorrectly identified.

[0036] Furthermore, the evaluation indicators for training the Yolov8 algorithm network structure include mean accuracy mAP, accuracy Precision and recall Recall, and the evaluation indicator calculation formula is as follows:

[0037]

[0038] Among them, K is the number of samples, AP i represents the average accuracy of the i-th sample;

[0039]

[0040] Among them, TP represents the number of positive samples that are correctly identified, and FP represents the number of positive samples that are incorrectly identified;

[0041]

[0042] Among them, FN represents the number of negative samples that are misidentified.

[0043] Furthermore, according to the infrared corrosion image and the steel bridge corrosion segmentation result, the temperature difference of the steel bridge corrosion area is judged, and the steel bridge corrosion condition is comprehensively evaluated, including:

[0044] Generate a temperature matrix for the infrared corrosion image by using an analytical algorithm;

[0045] Calculate the temperature difference between the highest temperature and the lowest temperature in the infrared corrosion image according to the temperature matrix;

[0046] Based on the temperature difference, the steel bridge corrosion segmentation result is compared with the area in the infrared corrosion image where the temperature is higher than other parts, the segmentation accuracy of the Yolov8-seg image segmentation model is verified, and the steel bridge corrosion condition is comprehensively evaluated.

[0047] A steel bridge corrosion evaluation system based on instance segmentation and image fusion, the system comprising:

[0048] Corrosion image acquisition module: collects images of the corroded area of ​​the steel bridge to obtain visible light corrosion images and infrared corrosion images;

[0049] A corrosion image annotation module is used to annotate the visible light corrosion image to obtain a steel bridge corrosion dataset;

[0050] Segmentation model training module: constructing a Yolov8-seg image segmentation model, optimizing the Yolov8 algorithm network structure, and training the Yolov8 algorithm network structure according to the steel bridge corrosion dataset;

[0051] Corrosion image segmentation module: using the Yolov8-seg image segmentation model to perform instance segmentation on the visible light corrosion images annotated in the steel bridge corrosion dataset to obtain the steel bridge corrosion segmentation results;

[0052] Steel bridge corrosion evaluation module: based on the infrared corrosion image and the steel bridge corrosion segmentation result, the temperature difference of the steel bridge corrosion area is judged, and the steel bridge corrosion condition is comprehensively evaluated.

[0053] The technical solution of the present invention can achieve the following technical effects:

[0054] By adding a lightweight attention module to the backbone network and head network of the original Yolov8 algorithm network structure, the model's perception and learning efficiency of important features are improved and the dependence on unimportant features is reduced. At the same time, the overall parameter quantity of the model is slightly affected, the model reasoning speed is guaranteed, and the accurate and fast steel bridge corrosion identification is achieved.

[0055] By changing the default loss function in the metric file in the Yolov8 algorithm source code, the GIoU loss function is added as the loss function of the Yolov8 algorithm network. Compared with the ordinary IoU, GIoU adds a term that measures the minimum closure rectangle area of ​​the predicted bounding box and the true bounding box and the sum of the areas of the predicted bounding box and the true bounding box, and adds constraints on the position. While optimizing the model prediction, the accuracy of the predicted position is also optimized. The GIoU loss function locates the object more accurately and better reflects the accuracy of the prediction results during the training process, ultimately achieving accurate prediction of steel bridge corrosion.

[0056] While improving the Yolov8 algorithm network structure to accurately segment the corroded area of ​​the steel bridge, the steel bridge area with abnormal temperature in the infrared corrosion image is compared with the predicted area of ​​the Yolov8 algorithm network to verify the accuracy of the model and further identify the corrosion of the steel bridge to ensure that the corroded area of ​​the steel bridge is fully identified and realize the comprehensive evaluation of the corrosion of the steel bridge.

[0057] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0059] Figure 1 It is a flowchart of a steel bridge corrosion evaluation method based on instance segmentation and image fusion;

[0060] Figure 2 A schematic diagram of the process of annotating visible light corrosion images;

[0061] Figure 3 It is a schematic diagram of the process for comprehensive evaluation of the corrosion of steel bridges;

[0062] Figure 4 Schematic diagram of the structure of a steel bridge corrosion evaluation system based on instance segmentation and image fusion. DETAILED DESCRIPTION

[0063] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments.

[0064] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art of the present invention. The terms used in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The term "and / or" used herein includes any and all combinations of one or more related listed items.

[0065] Embodiment 1

[0066] like Figure 1 As shown, a steel bridge corrosion evaluation method based on instance segmentation and image fusion, the method includes:

[0067] S1: Collect images of the corroded area of ​​the steel bridge to obtain visible light corrosion images and infrared corrosion images;

[0068] Specifically, DJI drones can be used to collect images of corroded areas of steel bridges. DJI drones have high-resolution cameras and infrared imaging capabilities, which can not only capture the details of the steel bridge surface, but also detect the temperature distribution on the steel bridge surface. They are ideal tools for steel bridge corrosion detection and can efficiently and accurately collect images of corroded areas of steel bridges.

[0069] S2: Annotate the visible light corrosion images to obtain the steel bridge corrosion dataset;

[0070] Before annotating the visible light corrosion images, the visible light corrosion images can be cropped and image enhancement operations can be selected to expand the dataset.

[0071] S3: Build the Yolov8-seg image segmentation model, optimize the Yolov8 algorithm network structure, and train the Yolov8 algorithm network structure based on the steel bridge corrosion dataset;

[0072] S4: The Yolov8-seg image segmentation model is used to perform instance segmentation on the annotated visible light corrosion images in the steel bridge corrosion dataset to obtain the steel bridge corrosion segmentation results;

[0073] S5: Based on the infrared corrosion image and the steel bridge corrosion segmentation results, the temperature difference of the steel bridge corrosion area is judged, and the steel bridge corrosion condition is comprehensively evaluated.

[0074] In this step, the visible light images and infrared temperature measurement images taken by the drone are used, and the Yolov8-seg semantic segmentation model is used to perform mask extraction on the rust in the visible light images. The size and position of the rusted part can be accurately identified. Then the infrared rust image is analyzed to obtain the temperature distribution of the steel bridge and determine the temperature difference in the rusted area of ​​the steel bridge. The steel bridge area with abnormal temperature in the infrared image and the area predicted by the Yolov8 algorithm network are combined to ensure that the rusted area of ​​the steel bridge is fully identified, and a comprehensive assessment of the rust of the steel bridge can be achieved.

[0075] The technical solution of the present invention effectively solves the problem of low efficiency and accuracy in steel bridge corrosion identification. By adding a lightweight attention module to the backbone network and head network of the original Yolov8 algorithm network, the model's perception and learning efficiency of important features are improved, and the dependence on unimportant features is reduced. At the same time, the overall parameter quantity of the model is not greatly affected, the model reasoning speed is guaranteed, and the steel bridge corrosion identification is accurate and fast. In addition, the steel bridge area with abnormal temperature in the infrared image is compared with the predicted area of ​​the Yolov8 algorithm network to verify the accuracy of the model, and further identify the steel bridge corrosion to ensure that the corrosion area of ​​the steel bridge is fully identified.

[0076] As a preferred embodiment of the above, Figure 2 As shown in the figure, the visible light corrosion images are annotated to obtain the steel bridge corrosion dataset, including:

[0077] S21: Use the Labelme plug-in to perform instance segmentation and annotation on the visible light corrosion image, and annotate the steel bridge corrosion area in the visible light corrosion image according to the json format standard to obtain a json format annotation file;

[0078] S22: Use Python code to convert the json format annotation file into a txt format annotation file suitable for Yolov8 algorithm network structure training;

[0079] S23: According to the annotation file in txt format, a labeled steel bridge corrosion data set is established, and the labeled area is the steel bridge corrosion area.

[0080] Specifically, in the example of the present invention, the steel bridge corrosion dataset uses the Labelme annotation plug-in to perform instance segmentation and annotation on the visible light corrosion image. The Labelme plug-in is installed in the Python3.11 environment. The Labelme plug-in is used for polygon annotation. The format of the annotation file generated after annotation is json format. Python code is used to traverse each JSON file path, read the JSON file content, and load it into a dictionary form. Then, the height and width of the image are obtained, and the corresponding path saved as a text file is constructed according to the name of the original JSON file. The converted file format is a txt text file, and the annotated txt format annotation file is placed in the label folder under the mydata folder.

[0081] Furthermore, a Yolov8-seg image segmentation model is constructed, the Yolov8 algorithm network structure is optimized, and the Yolov8 algorithm network structure is trained according to the steel bridge corrosion dataset, including:

[0082] S31: Configure the yaml file for the Yolov8 algorithm network structure and add the attention module to the Yolov8-seg image segmentation model;

[0083] In order to enhance the feature expression ability of the model and improve the performance of the model in the task, attention modules can be added to the model, including CoordAttentation attention module, ShuffleAttention attention module, Non-Local attention module, Squeeze-and-Excitation attention module, etc.

[0084] S32: Change the loss function of the Yolov8-seg image segmentation model to adapt to the instance segmentation task;

[0085] In order to make the Yolov8-seg image segmentation model have higher accuracy and better detection effect, the loss function of the model can be further modified, for example, GIOU loss function, binary cross entropy loss function, Dice Loss, etc.

[0086] S33: Use the Bayesian hyperparameter optimization method to tune the hyperparameters of the Yolov8-seg image segmentation model to obtain a hyperparameter model;

[0087] S34: The steel bridge corrosion dataset is randomly divided into validation set, test set and training set in proportion;

[0088] The annotated steel bridge corrosion images can be randomly divided into a test set, a validation set, and a training set in a ratio of 1:1:8 to ensure that the distribution of samples in each set is representative.

[0089] S35: Train the Yolov8 algorithm network structure according to the trained hyperparameter model and the validation set, test set and training set to obtain a trained Yolov8-seg image segmentation model.

[0090] In this step, a high-performance YOLOv8-seg image segmentation model can be built and trained. This model can be used to accurately segment and evaluate the corrosion condition of the steel bridge surface, providing reliable technical support for bridge maintenance and management.

[0091] Furthermore, configure the yaml file for the Yolov8 algorithm network structure and add the attention module to the Yolov8-seg image segmentation model, including:

[0092] Configure the yaml file for the Yolov8 algorithm network structure to form the first network structure, and store the yaml file in the segments folder, where the first network structure includes: the number of instance segmentation categories, model dimensions, backbone network, neck network and head network;

[0093] Put the source code files of CoordAttentation module and ShuffleAttention module in the nn folder of Yolov8 algorithm source code, and import the source code files in the tasks file;

[0094] Add the CoordAttentation attention module after the second C2f module of the backbone network;

[0095] Adding the CoordAttentation attention module can help the model better capture the global correlation of the image and improve the quality of feature representation.

[0096] Add the ShuffleAttention module after the 12th layer of the head network;

[0097] Adding the ShuffleAttention module can improve the model's perception and learning efficiency of important features, while reducing dependence on unimportant features.

[0098] In this embodiment, the ShuffleAttention module is an attention mechanism based on channel exchange and channel attention. It generates different channel combinations by randomly exchanging the channels of the input tensor and calculates the attention weight of each channel combination; the CoordAttention module is an attention mechanism based on coordinates. It calculates the attention weight of each position by using the position information of the input tensor; the CoordAttentation module and the ShuffleAttention module perform weighted processing on the input tensor without changing the dimension and shape of the tensor.

[0099] Furthermore, the loss function of the Yolov8-seg image segmentation model is changed to adapt to the instance segmentation task, including:

[0100] Put the GIoU loss function source code in the metrics file in the utils folder of the Yolov8 algorithm source code;

[0101] In the forward function of the BboxLoss class in the loss file, change the default loss function of the Yolov8-seg image segmentation model to the GIoU loss function.

[0102] As a preferred embodiment of this embodiment, compared with the default cross entropy loss function of the Yolov8 algorithm, the GIOU loss function can obtain higher accuracy and better detection effect. The GIoU loss function divides the intersection area of ​​the two bounding boxes by the area of ​​the minimum enclosing box (minimum bounding box) of the two bounding boxes, and subtracts the difference metric. This difference metric refers to the area of ​​the minimum enclosing box minus the area of ​​the union of the two bounding boxes divided by the area of ​​the minimum enclosing box. The calculation formula of the GIoU loss function is as follows: GIoU = IoU-(CU) / C, where IoU represents the intersection of the two bounding boxes divided by the area of ​​the union, C represents the area of ​​the minimum enclosing box, and U represents the area of ​​the union of the two bounding boxes. When calculating the degree of overlap between bounding boxes, the GIoU loss function not only considers the position and area information of the bounding boxes, but also considers the box-shaped covering relationship between them, which can more accurately reflect the differences between bounding boxes and help improve the performance of the object detection model.

[0103] Furthermore, the Bayesian hyperparameter optimization method is used to tune the hyperparameters of the Yolov8-seg image segmentation model to obtain a hyperparameter model, including:

[0104] Define the hyperparameter optimization space, select appropriate hyperparameters, and choose recall as the evaluation indicator for optimizing hyperparameters;

[0105] Specifically, the hyperparameters that need to be optimized and their value ranges can be determined, including learning rate, batch size, weight decay, etc. In corrosion evaluation, recall rate is a key indicator, which measures the proportion of real corrosion areas identified by the model to all actual corrosion areas. Therefore, recall rate can be selected as an evaluation indicator for optimizing hyperparameters.

[0106] The Bayesian hyperparameter optimization method was used to iterate the Yolov8-seg image segmentation model 100 times, and the hyperparameter with the highest recall rate was selected as the hyperparameter for training the Yolov8-seg image segmentation model.

[0107] The Bayesian optimization method is used to tune the hyperparameters of the Yolov8-seg image segmentation model. This can be achieved by calling the corresponding Bayesian optimization library, such as scikit-optimize, hyperopt, etc., iterating the model 100 times, and updating the value of the hyperparameter according to the recall rate in each iteration. Based on the above operations, the optimal hyperparameter model can be obtained to improve the performance and accuracy of the Yolov8-seg image segmentation model in the evaluation of steel bridge corrosion.

[0108] Furthermore, the recall rate of the evaluation index for optimizing the hyperparameters is expressed by Recall, and its calculation method is as follows:

[0109]

[0110] Among them, TP represents the number of positive samples that are correctly identified, and FN represents the number of negative samples that are incorrectly identified.

[0111] Furthermore, the evaluation indicators for training the Yolov8 algorithm network structure include mean accuracy (mAP), precision (Precision) and recall (Recall). The calculation formula for the evaluation indicators is as follows:

[0112]

[0113] Among them, K is the number of samples, AP i represents the average accuracy of the i-th sample;

[0114]

[0115] Among them, TP represents the number of positive samples that are correctly identified, and FP represents the number of positive samples that are incorrectly identified;

[0116]

[0117] Among them, FN represents the number of negative samples that are misidentified.

[0118] Based on the above embodiments, Figure 3As shown in the figure, based on the infrared corrosion image and the steel bridge corrosion segmentation results, the temperature difference of the steel bridge corrosion area is judged, and the steel bridge corrosion condition is comprehensively evaluated, including:

[0119] S51: Generate a temperature matrix for the infrared corrosion image through an analytical algorithm;

[0120] S52: calculating the temperature difference between the highest temperature and the lowest temperature in the infrared corrosion image according to the temperature matrix;

[0121] S53: Based on the temperature difference, the steel bridge corrosion segmentation results are compared with the areas with higher temperatures than other parts in the infrared corrosion image to verify the segmentation accuracy of the Yolov8-seg image segmentation model and comprehensively evaluate the corrosion of the steel bridge.

[0122] Specifically, in order to make the data more structured and orderly, and to facilitate subsequent data processing and analysis, the temperature value of each pixel in the infrared image can be organized into a matrix. The temperature matrix makes it more convenient to count and analyze the temperatures of different areas in the image. In addition, the generated temperature matrix can integrate the temperature information in the infrared image with other data. By comparing and analyzing the temperature information with the corrosion segmentation results, the corrosion condition of the steel bridge can be evaluated more accurately.

[0123] Embodiment 2:

[0124] like Figure 4 As shown, a steel bridge corrosion evaluation system based on instance segmentation and image fusion, the system includes:

[0125] Corrosion image acquisition module: collects images of the corroded area of ​​the steel bridge to obtain visible light corrosion images and infrared corrosion images;

[0126] Corrosion image annotation module: annotate visible light corrosion images to obtain a steel bridge corrosion dataset;

[0127] Segmentation model training module: build Yolov8-seg image segmentation model, optimize Yolov8 algorithm network structure, and train Yolov8 algorithm network structure according to steel bridge corrosion dataset;

[0128] Corrosion image segmentation module: The Yolov8-seg image segmentation model is used to perform instance segmentation on the annotated visible light corrosion images in the steel bridge corrosion dataset to obtain the steel bridge corrosion segmentation results;

[0129] Steel bridge corrosion evaluation module: Based on the infrared corrosion images and steel bridge corrosion segmentation results, the temperature difference of the steel bridge corrosion area is judged and the steel bridge corrosion condition is comprehensively evaluated.

[0130] The above-mentioned adjustment system in the present invention can effectively implement the steel bridge corrosion evaluation method based on instance segmentation and image fusion, and the technical effects that can be achieved are as described in the above-mentioned embodiments and will not be repeated here.

[0131] Although the present application has been described in conjunction with specific features and embodiments thereof, it is apparent that various modifications and combinations may be made thereto without departing from the spirit and scope of the present application. Accordingly, this specification and the accompanying drawings are merely exemplary illustrations of the present application as defined herein, and are deemed to have covered any and all modifications, variations, combinations or equivalents within the scope of the present application. Obviously, a person skilled in the art may make various modifications and variations to the present application without departing from the scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the present application and its equivalents, the present application is intended to include these modifications and variations.

Claims

1. A steel bridge corrosion evaluation method based on instance segmentation and image fusion, characterized in that: The method comprises: Collect images of the corroded area of ​​the steel bridge to obtain visible light corrosion images and infrared corrosion images; Annotating the visible light corrosion image to obtain a steel bridge corrosion dataset; Constructing a Yolov8-seg image segmentation model, optimizing the Yolov8 algorithm network structure, and training the Yolov8 algorithm network structure according to the steel bridge corrosion dataset; Using the Yolov8-seg image segmentation model, instance segmentation is performed on the visible light corrosion images annotated in the steel bridge corrosion dataset to obtain a steel bridge corrosion segmentation result; According to the infrared corrosion image and the steel bridge corrosion segmentation result, the temperature difference of the steel bridge corrosion area is judged, and the steel bridge corrosion condition is comprehensively evaluated.

2. The steel bridge corrosion evaluation method based on instance segmentation and image fusion according to claim 1, characterized in that: The visible light corrosion image is annotated to obtain a steel bridge corrosion dataset, including: Perform instance segmentation and annotation on the visible light corrosion image through the Labelme plug-in, annotate the steel bridge corrosion area in the visible light corrosion image according to the json format standard, and obtain a json format annotation file; Use Python code to convert the json format annotation file into a txt format annotation file suitable for the Yolov8 algorithm network structure training; According to the txt format annotation file, a labeled steel bridge corrosion data set is established, and the marked area is the steel bridge corrosion area.

3. The steel bridge corrosion evaluation method based on instance segmentation and image fusion according to claim 1, characterized in that: The Yolov8-seg image segmentation model is constructed, the Yolov8 algorithm network structure is optimized, and the Yolov8 algorithm network structure is trained according to the steel bridge corrosion data set, including: Configure the yaml file for the Yolov8 algorithm network structure and add an attention module to the Yolov8-seg image segmentation model; Change the loss function of the Yolov8-seg image segmentation model to adapt to the instance segmentation task; Using the Bayesian hyperparameter optimization method to perform hyperparameter tuning on the Yolov8-seg image segmentation model to obtain a hyperparameter model; The steel bridge corrosion dataset is randomly divided into a validation set, a test set and a training set in proportion; The Yolov8 algorithm network structure is trained according to the trained hyperparameter model and the validation set, test set and training set to obtain the trained Yolov8-seg image segmentation model.

4. The steel bridge corrosion evaluation method based on instance segmentation and image fusion according to claim 3 is characterized in that: Configure the yaml file for the Yolov8 algorithm network structure and add an attention module to the Yolov8-seg image segmentation model, including: Configure a yaml file for the Yolov8 algorithm network structure to form a first network structure, and store the yaml file in the segments folder, wherein the first network structure includes: the number of instance segmentation categories, the model dimension, the backbone network, the neck network, and the head network; Put the source code files of CoordAttentation module and ShuffleAttention module in the nn folder of Yolov8 algorithm source code, and import the source code files in the tasks file; Add the CoordAttentation attention module after the second C2f module of the backbone network; The ShuffleAttention module is added after the 12th layer of the head network.

5. The steel bridge corrosion evaluation method based on instance segmentation and image fusion according to claim 3 is characterized in that: Change the loss function of the Yolov8-seg image segmentation model to adapt to the instance segmentation task, including: Put the GIoU loss function source code in the metrics file in the utils folder of the Yolov8 algorithm source code; In the forward function of the BboxLoss class in the loss file, change the default loss function of the Yolov8-seg image segmentation model to the GIoU loss function.

6. The steel bridge corrosion evaluation method based on instance segmentation and image fusion according to claim 3 is characterized in that: The Bayesian hyperparameter optimization method is used to perform hyperparameter tuning on the Yolov8-seg image segmentation model to obtain a hyperparameter model, including: Define the hyperparameter optimization space, select appropriate hyperparameters, and select recall as the evaluation metric for optimizing the hyperparameters; The Bayesian hyperparameter optimization method is used to iterate the Yolov8-seg image segmentation model 100 times, and the hyperparameter with the highest recall rate is selected as the hyperparameter for training the Yolov8-seg image segmentation model.

7. The steel bridge corrosion evaluation method based on instance segmentation and image fusion according to claim 6, characterized in that: include: The evaluation indicator recall rate for optimizing the hyperparameters is represented by Recall, which is calculated as follows: Among them, TP represents the number of positive samples that are correctly identified, and FN represents the number of negative samples that are incorrectly identified.

8. The steel bridge corrosion evaluation method based on instance segmentation and image fusion according to claim 3 is characterized in that: The evaluation indicators for training the Yolov8 algorithm network structure include mean accuracy (mAP), accuracy (Precision) and recall (Recall). The calculation formula of the evaluation indicators is as follows: Among them, K is the number of samples, AP i represents the average accuracy of the i-th sample; Among them, TP represents the number of positive samples that are correctly identified, and FP represents the number of positive samples that are incorrectly identified; Among them, FN represents the number of negative samples that are misidentified.

9. The steel bridge corrosion evaluation method based on instance segmentation and image fusion according to claim 1, characterized in that: According to the infrared corrosion image and the steel bridge corrosion segmentation result, the temperature difference of the steel bridge corrosion area is judged, and the steel bridge corrosion condition is comprehensively evaluated, including: Generate a temperature matrix for the infrared corrosion image by using an analytical algorithm; Calculate the temperature difference between the highest temperature and the lowest temperature in the infrared corrosion image according to the temperature matrix; Based on the temperature difference, the steel bridge corrosion segmentation result is compared with the area in the infrared corrosion image where the temperature is higher than other parts, the segmentation accuracy of the Yolov8-seg image segmentation model is verified, and the steel bridge corrosion condition is comprehensively evaluated.

10. A steel bridge corrosion evaluation system based on instance segmentation and image fusion, characterized in that: The system comprises: Corrosion image acquisition module: collects images of the corroded area of ​​the steel bridge to obtain visible light corrosion images and infrared corrosion images; A corrosion image annotation module is used to annotate the visible light corrosion image to obtain a steel bridge corrosion dataset; Segmentation model training module: constructing a Yolov8-seg image segmentation model, optimizing the Yolov8 algorithm network structure, and training the Yolov8 algorithm network structure according to the steel bridge corrosion dataset; Corrosion image segmentation module: using the Yolov8-seg image segmentation model to perform instance segmentation on the visible light corrosion images annotated in the steel bridge corrosion dataset to obtain the steel bridge corrosion segmentation results; Steel bridge corrosion evaluation module: based on the infrared corrosion image and the steel bridge corrosion segmentation result, the temperature difference of the steel bridge corrosion area is judged, and the steel bridge corrosion condition is comprehensively evaluated.

Citation Information

Cited By

  • Rust degree detection method and device for steel member

    CN119000717A

  • Steel structure bridge corrosion detection and segmentation method and device

    CN119445109A

  • A steel structure bridge corrosion detection segmentation method and device

    CN119445109B

  • Portable crop water stress index automatic detection device and method

    CN119574550A

  • Hydraulic metal structure corrosion detection and sample expansion method and system

    CN119672430A