Deep learning-based ship corrosion detection method and system
By applying deep learning technology and multiple semantic segmentation models in ship corrosion detection, the problem of difficulty in automation and intelligence of manual visual inspection is solved, and efficient and reliable ship corrosion detection and evaluation is achieved.
Patent Information
- Application Number
- CN202510061284.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-15
- Publication Date
- 2025-04-29
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
In the prior art, it is difficult to achieve automation and intelligence of ship corrosion detection by manual visual inspection, and there are problems of time costs, high costs and unreliability, and there is no similar detection system in China.
The ship corrosion detection method based on the PaddlePaddle deep learning platform is adopted, and the model training and verification is carried out through the image segmentation kit PaddleSeg and multiple semantic segmentation models (such as DeepLabV3, DeepLabV3+, PP-LiteSeg, FastFCN), and a ship corrosion detection and evaluation system is established.
It realizes the automation and intelligence of ship corrosion detection, can intuitively display the corrosion area and provide corrosion rate, reduces the detection time and cost, and improves the reliability of the detection results.
Smart Images

Figure CN119904446A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of ship corrosion detection, and in particular to a ship corrosion detection method and system based on deep learning. Background Art
[0002] Since metal materials have strong wear resistance and impact resistance, most ships choose metal hulls as their construction materials. However, due to long-term erosion by seawater, ships will suffer from varying degrees of corrosion, which seriously threatens the stability of the hull and shortens the service life of the ship. Therefore, regular corrosion inspections of ships can not only meet the requirements of the International Maritime Organization, but also provide decision-making references for ship safety control and maintenance reinforcement, ensuring the safety of ship navigation and water transportation safety.
[0003] At present, manual visual inspection is still a commonly used method for ship corrosion detection. Workers must not only pay attention to whether the ship is corroded, but also the degree of corrosion, because different degrees of corrosion correspond to different corrosion treatment measures. When inspecting ship corrosion, workers must go to the ship inspection location. The whole process is not only time-consuming and expensive, but sometimes also exposed to dangerous situations, endangering the safety of workers. In addition, manual visual inspection is difficult to quantitatively describe the degree of corrosion and corrosion area, and there is a certain degree of subjectivity, which will lead to unreliable test results; This cannot meet the current requirements of ship inspection in terms of safety or accuracy. In the past two years, the American Bureau of Shipping (ABS) has used AI algorithms to analyze images and video files to evaluate the damage and corrosion of tank coatings. However, there is a relative lack of research on intelligent detection of ship corrosion in China, and there is no completely similar detection system on the market. Therefore, research on intelligent detection and evaluation of ship corrosion needs to be urgently addressed.
[0004] In the face of the above challenges, in order to meet the needs of automation and intelligentization of ship corrosion detection and assessment, the team studied and practiced the existing intelligent detection technology, integrated image processing, deep learning and other related knowledge, studied the ship corrosion detection and assessment technology based on the PaddlePaddle deep learning framework, and designed a ship corrosion detection and assessment system. Summary of the invention
[0005] The purpose of the present invention is to provide a ship corrosion detection method based on deep learning to solve the problems raised in the above background technology.
[0006] To achieve the above purpose, a ship corrosion detection method based on deep learning is provided, comprising the following steps: Step 1: Based on the PaddlePaddle deep learning platform, use the image segmentation suite PaddleSeg and the Qt-based Python toolkit to create an erosion segmentation dataset of the original image, and use EISeg to annotate the erosion dataset to obtain an annotated image set consisting of annotated images; Step 2: Divide the original image and the annotated image into training set, validation set and test set according to the ratio, and use multiple semantic segmentation models for model training and validation; Step 3: Use DeepLabV3 to build a semantic segmentation network based on ResNet, change the stride of block3 and block4 in ResNet to 1, use a multi-gird structure in block4, use an ASPP structure after block4, and finally use bilinear upsampling to upsample the probability map to the same dimension as the input image; Step 4: Use DeepLabV3+ to perform parallel dilated convolution on the preliminary effective feature layer compressed four times, use dilated convolutions of different ratios to extract features, merge, and convolute compressed features. In the decoder, use convolution to adjust the number of channels of the preliminary effective feature layer compressed twice, and then stack it with the upsampling result of the effective feature layer, perform two depth-separable convolutions, and obtain the final effective feature layer. Use convolution to adjust the channels to the total number of categories, and use resize to upsample so that the width and height of the final output layer are the same as the input image. Step 5: Train multiple semantic segmentation models, and use the trained multiple speech segmentation models to predict the image. The prediction equation is as follows:
[0007]
[0008] in, is the total number of pixels in the eroded area, is the eroded pixel in the area, C is the ratio of the total eroded area to the image area, is the total number of pixels in the image.
[0009] Furthermore, in step 2, when the input image is too large, the image is compressed so that all input images are trained according to a preset pixel input model, where multiple semantic segmentation models include a combination of any two or more models of DeepLabV3, DeepLabV3+, PP-LiteSeg, and FastFCN.
[0010] Furthermore, the PP-LiteSeg includes a decoding module, a balanced encoding module and a fusion module. The decoding module is used to adjust the number of channels in the decoding module, and the fusion module is used to enhance the feature representation, reduce the number of channels of the intermediate feature map, and remove the jump connection.
[0011] A ship corrosion detection system based on deep learning includes a data acquisition unit for acquiring a corrosion segmentation data set of an original image; a data analysis unit for performing real-time analysis on output data from a plurality of speech segmentation models to determine whether the ship is corroded or in an abnormal condition, the data analysis unit also determining the degree of corrosion of the ship by analyzing the data; and an early warning module, which issues an early warning message when the data analysis unit determines that the ship is severely corroded.
[0012] Furthermore, the data acquisition unit also includes an ultrasonic sensor, an electrochemical sensor and an optical sensor. The ultrasonic sensor is used to detect the corrosion condition of the ship, the electrochemical sensor is used to detect the electrochemical corrosion parameters of the ship, and the optical sensor is used to obtain the original image of the ship corrosion.
[0013] Compared with the prior art, the present invention has the following beneficial effects: The ship corrosion detection and assessment system can meet the task requirements of ship corrosion detection, intuitively display the corrosion area and provide corrosion rate, and can replace the segmentation model. The staff can master the use of this system without spending a long time on training; Considering the differences in software and hardware in the usage scenarios, the system size is kept as small as possible to facilitate deployment. At the same time, the system's reliance on class libraries is minimized, simplifying the process of environment configuration. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] Figure 1 It is a flow chart of the steps of the present invention.
[0015] The meaning of each number in the figure is: Cabinet; 2. Partial discharge monitor; 3. Horizontal movement assembly; 301. Base; 302. Protective cover; 303. Top plate; 304. Mounting plate; 305. Shaft; 306. Motor; 307. Groove; 308. Pin; 309. Slot; 4. Longitudinal displacement assembly; 5. Track groove. DETAILED DESCRIPTION
[0016] 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. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0017] Those skilled in the art will appreciate that, unless otherwise stated, the singular forms "a", "an" and "the" used herein may also include plural forms. It should be further understood that the term "comprising" used in the specification of the present invention refers to the presence of the features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof.
[0018] See also Figure 1 As shown in the figure, a ship corrosion detection method based on deep learning is provided. Step 1: Based on the PaddlePaddle deep learning platform, use the image segmentation suite PaddleSeg and the Qt-based Python toolkit to create an erosion segmentation dataset of the original image, and use EISeg to annotate the erosion dataset to obtain an annotated image set consisting of annotated images; Step 2: Divide the original image and the annotated image into training set, validation set and test set according to the ratio, and use multiple semantic segmentation models for model training and validation; Step 3: Use DeepLabV3 to build a semantic segmentation network based on ResNet, change the stride of block3 and block4 in ResNet to 1, use a multi-gird structure in block4, use an ASPP structure after block4, and finally use bilinear upsampling to upsample the probability map to the same dimension as the input image; Step 4: Use DeepLabV3+ to perform parallel dilated convolution on the preliminary effective feature layer compressed four times, use dilated convolutions of different ratios to extract features, merge, and convolute compressed features. In the decoder, use convolution to adjust the number of channels of the preliminary effective feature layer compressed twice, and then stack it with the upsampling result of the effective feature layer, perform two depth-separable convolutions, and obtain the final effective feature layer. Use convolution to adjust the channels to the total number of categories, and use resize to upsample so that the width and height of the final output layer are the same as the input image. Step 5: Train multiple semantic segmentation models, and use the trained multiple speech segmentation models to predict the image. The prediction equation is as follows:
[0019]
[0020] in, is the total number of pixels in the eroded area, is the eroded pixel in the area, C is the ratio of the total eroded area to the image area, is the total number of pixels in the image.
[0021] For the DeepLabV3+ model, the principles are as follows: In the encoder, the preliminary effective feature layer compressed four times is subjected to parallel dilated convolution, and feature extraction is performed using dilated convolutions of different ratios. The convolution compression features are then merged. In the decoder, the number of channels of the preliminary effective feature layer on both sides of the compression is adjusted by convolution, and then the results of upsampling with the effective feature layer are stacked, and depth-wise separable convolution is performed on both sides to obtain the final effective feature layer.
[0022] In step 2, when the input image is too large, the image is compressed so that all input images are trained according to the preset pixel input model, where multiple semantic segmentation models include a combination of any two or more models of DeepLabV3, DeepLabV3+, PP-LiteSeg, and FastFCN.
[0023] The PP-LiteSeg includes a decoding module, a balanced encoding module and a fusion module. The decoding module is used to adjust the number of channels in the decoding module, and the fusion module is used to strengthen the feature representation, reduce the number of channels in the intermediate feature map, and remove the jump connection.
[0024] A ship corrosion detection system based on deep learning includes a data acquisition unit for acquiring a corrosion segmentation data set of an original image; a data analysis unit for performing real-time analysis on output data from a plurality of speech segmentation models to determine whether the ship is corroded or in an abnormal condition, the data analysis unit also determining the degree of corrosion of the ship by analyzing the data; and an early warning module, which issues an early warning message when the data analysis unit determines that the ship is severely corroded.
[0025] The data acquisition unit also includes an ultrasonic sensor, an electrochemical sensor and an optical sensor. The ultrasonic sensor is used to detect the corrosion condition of the ship, the electrochemical sensor is used to detect the electrochemical corrosion parameters of the ship, and the optical sensor is used to obtain the original image of the ship corrosion. Example
[0026] Take the DeepLabV3 model as an example, and train the model through the script provided by PaddleSeg. Take the semantic segmentation model DeepLabV3 as an example, and execute the following script for training. The training iter is set to 50000. PaddleSeg will write the data during the training process to the VisualDL file.
[0027] The running code is as follows: # config is the configuration file, do_eval starts the evaluation when saving the model, use_vdl turns on visualdl to record the training data # save_interval is the interval number of steps to save the model, save_dir is the root path for saving the model and visualdl log files # log_iters is the number of steps to print the log CUDA_VISIBLE_DEVICES=0 python train.py --config configs / deeplabv3 / deeplabv3_resnet50_os8_voc12aug_512x512_40k.yml --do_eval --use_vdl --save_interval 500 --save_dir output --log_iters 50; IoU, precision, recall, and Kappa coefficient were selected as indicators for model quality evaluation; After training is completed, use the val.py program code to evaluate the model effect; The val.py program code is as follows: # Select best_model for model evaluation python val.py --config configs / deeplabv3 / deeplabv3_resnet50_os8_voc12aug_512x512_40k.yml --model_path output / best_model / model.pdparams.
[0028] The evaluation results of this model are as follows: The above shows and describes the basic principles, main features and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited by the above embodiments. The above embodiments and descriptions are only preferred examples of the present invention and are not intended to limit the present invention. Without departing from the spirit and scope of the present invention, the present invention may have various changes and improvements, which fall within the scope of the present invention. The scope of protection of the present invention is defined by the attached claims and their equivalents.
Claims
1. A ship corrosion detection method based on deep learning, characterized in that: The following steps are involved: Step 1: Based on the PaddlePaddle deep learning platform, use the image segmentation suite PaddleSeg and the Qt-based Python toolkit to create an erosion segmentation dataset of the original image, and use EISeg to annotate the erosion dataset to obtain an annotated image set consisting of annotated images; Step 2: Divide the original image and the annotated image into training set, validation set and test set according to the ratio, and use multiple semantic segmentation models for model training and validation; Step 3: Use DeepLabV3 to build a semantic segmentation network based on ResNet, change the stride of block3 and block4 in ResNet to 1, use a multi-gird structure in block4, use an ASPP structure after block4, and finally use bilinear upsampling to upsample the probability map to the same dimension as the input image; Step 4: Use DeepLabV3+ to perform parallel dilated convolution on the preliminary effective feature layer compressed four times, use dilated convolutions of different ratios to extract features, merge, and convolute compressed features. In the decoder, use convolution to adjust the number of channels of the preliminary effective feature layer compressed twice, and then stack it with the upsampling result of the effective feature layer, perform two depth-separable convolutions, and obtain the final effective feature layer. Use convolution to adjust the channels to the total number of categories, and use resize to upsample so that the width and height of the final output layer are the same as the input image. Step 5: Train multiple semantic segmentation models, and use the trained multiple speech segmentation models to predict the image. The prediction equation is as follows: in, is the total number of pixels in the eroded area, is the eroded pixel in the area, C is the ratio of the total eroded area to the image area, is the total number of pixels in the image.
2. A ship corrosion detection method based on deep learning according to claim 1, characterized in that: In step 2, when the input image is too large, the image is compressed so that all input images are trained according to the preset pixel input model, where multiple semantic segmentation models include a combination of any two or more models of DeepLabV3, DeepLabV3+, PP-LiteSeg, and FastFCN.
3. A ship corrosion detection method based on deep learning according to claim 2, characterized in that: The PP-LiteSeg includes a decoding module, a balanced encoding module and a fusion module. The decoding module is used to adjust the number of channels in the decoding module, and the fusion module is used to strengthen the feature representation, reduce the number of channels of the intermediate feature map, and remove the jump connection.
4. A ship corrosion detection system based on deep learning, characterized in that: It includes a data acquisition unit for acquiring a corrosion segmentation data set of an original image; a data analysis unit for performing real-time analysis on the output data of multiple speech segmentation models to determine whether the ship is corroded or abnormal, and the data analysis unit also determines the degree of corrosion of the ship by analyzing the data; The early warning module sends out an early warning message when the data analysis unit determines that the ship is seriously corroded.
5. A ship corrosion detection system based on deep learning according to claim 4, characterized in that: The data acquisition unit also includes an ultrasonic sensor, an electrochemical sensor and an optical sensor. The ultrasonic sensor is used to detect the corrosion condition of the ship, the electrochemical sensor is used to detect the electrochemical corrosion parameters of the ship, and the optical sensor is used to obtain the original image of the ship corrosion.