Shedding Damage Detection of Metal Underwater Pipeline External Anticorrosive Coating by Ultrasonic Imaging Based on HOG + SVM

: Underwater pipelines are the channels for oil transportation in the sea. In the course of pipeline operation, leakage accidents occur from time to time for natural and man-made reasons which result in economic losses and environmental pollution. To avoid economic losses and environmental pollution, damage detection of underwater pipelines must be carried out. In this paper, based on the histogram of oriented gradient (HOG) and support vector machine (SVM), a non-contact ultrasonic imaging method is proposed to detect the shedding damage of the metal underwater pipeline external anti-corrosion layer. Firstly, the principle of acoustic scattering characteristics for detecting the metal underwater pipelines is introduced. Following this, a HOG+SVM image-extracting algorithm is used to extract the pipeline area from the underwater ultrasonic image. According to the difference of mean gray value in the horizontal direction of the pipeline project area, the shedding damage parts are identiﬁed. Subsequently, taking the metal underwater pipelines with three layers of polyethylene outer anti-corrosive coatings as the detection object, an Autonomous Surface Vehicle (ASV) for underwater pipelines defect detection is developed to verify the detection effect of the method. Finally, the underwater ultrasonic image which used to detect the metal underwater pipeline shedding damage is obtained by acoustic sensor. The results show that the shedding damage can be detected by the proposed method. With the increase of shedding damage width, the effect of pipeline defect location detection is better.


Introduction
With the development of science and technology, the demand for oil and natural gas resources has been increasing. There are abundant oil and gas resources in the ocean. An underwater metal pipeline is a longstanding transportation tool for exploitation of marine resources. Because of the harsh marine environment and the difficulty of damage detection, oil leak accidents occur from time to time [1]. If the underwater pipeline leaks, it causes great economic losses and environmental pollution and, therefore, it is of great importance to detect the underwater pipeline damage accurately [2].
The types of underwater metal pipeline damage are mainly divided into pipeline leakage, pipeline corrosion and shedding of the external anticorrosive coating of the pipeline. There is a progressive relationship between the three pipeline defects. The pipeline corrosion causes the shedding of external anticorrosive coating. Shedding of external anticorrosive coating accelerates the corrosion of the pipeline body, which leads to leaks from the pipeline [3]. Many researchers have tried to design reasonable damagedetection methods [4,5]. In view of the difficulty and high cost of underwater metal pipeline damage detection, a variety of detection methods have been proposed by researchers across 2 of 17 the world [6][7][8]. For inshore underwater pipeline inspection, a testing person usually carries professional instruments for manual inspection. Other detection methods include deformation measurement [9], potential measurement, current in the tube [10], sonar [11], image recognition [12], a magnetic flux leakage method and ultrasonic detection [13].
Leakage of underwater metal pipelines cause great losses, which need to be detected and repaired rapidly. Mahmutoglu [14] introduced a method which uses a passive acousticbased received signal strength difference technique to localize leakages in underwater natural gas pipelines. The leakages can be localized with small position error by depending on receiver number, leak holes diameter and ambient noise. However, the sensors density and the distance between the sensors and the pipeline have a great influence on the results. To improve the positioning accuracy, Huang [15] used the particle swarm optimization algorithm (PSO) tuning of the support vector machine (SVM) to predict the leakage points based on gathered leakage data. The leakage position predicted by the PSO algorithm after optimization of the parameters is more accurate. Wang [16] investigated the feasibility of monitoring the leakage of an oil pipeline by using Brillouin optical time domain reflectometry with both laboratory experiments and field tests. Testing results show that a much more sensitive laying style by wrapping up the sensing cable and pipeline with plastic film can detect the leakage. Magnetic flux leakage detection can be inspected both inside and outside the pipeline with high accuracy [17]. However, the longitudinal crack detection of a pipeline is blind zone in this method. Wu [18] proposed a composite magnetic flux leakage method using alternating magnetic field excitation for the detection of cracks. This method can implement synchronous detection in two orthogonal directions to avoid missed detection caused by the crack orientation. However, the magnetic flux leakage method needs high technical requirements.
Corrosion of underwater metal pipelines and external anticorrosive coatings are early forms of pipeline damage. Early detection can reduce maintenance costs [19,20]. Real-time condition monitoring of structures in service has also been of concern to researchers [21][22][23]. To detect small diameter thick wall pipelines, the finite element calculation was carried out by Gloria [24] to optimize the combined structure of the internal corrosion sensor. The experimental results on a prototype showed that the proposed theoretical model is effective. Khan et al. [25] proposed a wavelet-based fusion method to enhance and dehaze the underwater hazy images of corroded pipeline. The main aim was to inspect the underwater pipelines for the corrosion estimation. Yang et al. [26] presented a method for analysis of abnormal events observed by underwater pipelines. A model was established to analyze the failure probability of corrosion and potential consequences in order to monitor and analyze the corrosion status of pipelines. Xiong [27] used three-dimensional (3D) models constructed from multi-sensor data fusion for underwater pipeline inspection. The status of a pipeline obtained by a 3D model construction is more accurate and reliable. Yazdekhasti [28] presented an approach for leak detection that involves continuous monitoring of the changes in the correlation between surface acceleration measured at discrete locations along the pipeline length. The preliminary results seem promising. Compared with contact detection, non-contact detection has less impact on the structure. Seemakurthy [29] restored the blurring caused by the flow dynamics in underwater photographs by processing underwater photographs. The direct-current (DC) potential gradient measurement method judges the position of the damaged point in the external coating of the pipeline by measuring the potential gradient along the underwater pipeline [30]. The DC potential gradient measurement method is the main method to detect damage defects of the corrosion layer of underwater metal pipelines in China. However, this method has some shortcomings, such as the high price of testing equipment, low detection efficiency and high requirement of professional skills of the technicians. The economy and safety of diver detection are poor, and it is greatly affected by sea conditions and operating depth. Therefore, non-contact non-destructive testing has been paid more attention by researchers.
Image recognition, as a non-contact method, has always been concerned by researchers. Tian et al. [31] develop an automated and optimized detection procedure that mimics these operations. The primary goal of the methodology is to reduce the number of images requiring visual evaluation by filtering out images that are overwhelmingly definitive on the existence or absence of a flaw. Fernando [32] describes a method to support the non-destructive testing, especially, in radiographic inspection activities. It aims at detecting welded joints of oil pipelines in radiographs with double wall double image exposure. The proposed approach extracts information from the pipeline region in the radiographic image and then applies deep neural network models to identify which windows correspond to welded joints. Ravanbod [33] trained a generalized regression neural network to determine the dimensions of the corrosions and generate the whole image of both the internal and external walls of the oil pipeline. As an improvement to the detection algorithm, we introduce fuzzy decision-based neural network algorithms for the detection and classification of corrosion. The simulation and experimental results show the effectiveness of the existing methods. However, traditional image recognition requires a high detection environment. Compared to image-based detection approaches, ultrasonic detection has higher penetration [34].
In view of the advantages and disadvantages of detection methods, an ultrasonic imaging detection method based on histogram of oriented gradient (HOG) + SVM for the shedding damage of an underwater metal pipeline's external anticorrosive coating is presented in this paper. Based on non-contact underwater acoustic imaging technology, the real-time and long-distance on-line detection system is established by using an unmanned ship as a carrier. The remaining part of the paper is organized as follows: Section 2 introduces the principle and methodology of damage detection for the underwater pipeline external anti-corrosion layer shedding damage. In Section 3, experiments are carried out by the detection system designed in this paper, and the experimental results are discussed. Section 4 concludes the whole work.

Principle and Methodology
In this section, the principle and methodology of underwater pipeline damage detection is introduced. Firstly, the principle of underwater pipeline damage ultrasound imaging detecting is studied. The feasibility of external anticorrosive coatings shedding damage detection by non-contact ultrasonic imaging is demonstrated theoretically. Following this, HOG feature extraction and the SVM algorithm is used to extract underwater metal pipeline area from underwater ultrasonic image. A detection method based on average gray value is proposed to realize the underwater pipeline shedding damage detection. In this paper, an underwater pipeline laying in shallow water area is taken as the research object, and the theoretical analysis of the metal underwater pipeline shedding damage model are established. The model, as shown in Figure 1, is divided into three parts: the external anti-corrosion layer, the pipeline body and the shedding place of the external anti-corrosion layer. The external anti-corrosion layer is three-layer PE material, and the tube body is high-strength steel material. The model has uniform thickness of external anticorrosive coating, smooth surface and uniform thickness of the tube itself. The coupling between the tube and the external anti-corrosive coating is good. To obtain the ultrasonic image of the underwater pipeline, an acoustic sensor is used to collect underwater information. The acoustic sensor probe is composed of left and right acoustic arrays, which can realize imaging detection on both sides. The acoustic array is composed of point sources arranged in regular order. The transmitted sound wave emit by the array are reflected back when it meets underwater target. The reflected echo carries the characteristic information of the underwater target. The acoustic sensor can obtain a band gray value once a sound wave is emitted and received. After several emissions and receptions, the underwater target information image is obtained. The different sound intensity in the underwater target is reflected in the image. Taking the underwater metal pipeline model as an example, the principle of ultrasonic imaging detection for the underwater metal pipeline with external anticorrosive coating shedding damage is shown in Figure 2. From Figure 2, the pipeline body is exposed in the water when the underwater metal pipeline external anticorrosive coating shedding off. When the acoustic wave meets the underwater metal pipeline, mirror reflection is caused. The elastic reflection occurs when the external anti-corrosion layer is intact. Because of the difference of sound intensity between the two echoes, the images generated by them are different. In conclusion, according to the difference of the gray ultrasound image, it can effectively distinguish whether there is shedding damage in underwater metal pipelines' external anticorrosive coating. Next, the difference of sound intensity between the pipeline defect area and the pipeline normal area is analyzed.

Analysis of Underwater Pipeline Acoustic Scattering Characteristics
The metal pipeline studied in this paper has three layers of PE material, and the inner is high strength steel material which is commonly used in underwater metal pipelines. To analyse the acoustic scattering characteristics, the outer part of the pipeline is To obtain the ultrasonic image of the underwater pipeline, an acoustic sensor is used to collect underwater information. The acoustic sensor probe is composed of left and right acoustic arrays, which can realize imaging detection on both sides. The acoustic array is composed of point sources arranged in regular order. The transmitted sound wave emit by the array are reflected back when it meets underwater target. The reflected echo carries the characteristic information of the underwater target. The acoustic sensor can obtain a band gray value once a sound wave is emitted and received. After several emissions and receptions, the underwater target information image is obtained. The different sound intensity in the underwater target is reflected in the image. Taking the underwater metal pipeline model as an example, the principle of ultrasonic imaging detection for the underwater metal pipeline with external anticorrosive coating shedding damage is shown in Figure 2. To obtain the ultrasonic image of the underwater pipeline, an acoustic sensor is used to collect underwater information. The acoustic sensor probe is composed of left and right acoustic arrays, which can realize imaging detection on both sides. The acoustic array is composed of point sources arranged in regular order. The transmitted sound wave emit by the array are reflected back when it meets underwater target. The reflected echo carries the characteristic information of the underwater target. The acoustic sensor can obtain a band gray value once a sound wave is emitted and received. After several emissions and receptions, the underwater target information image is obtained. The different sound intensity in the underwater target is reflected in the image. Taking the underwater metal pipeline model as an example, the principle of ultrasonic imaging detection for the underwater metal pipeline with external anticorrosive coating shedding damage is shown in Figure 2. From Figure 2, the pipeline body is exposed in the water when the underwater metal pipeline external anticorrosive coating shedding off. When the acoustic wave meets the underwater metal pipeline, mirror reflection is caused. The elastic reflection occurs when the external anti-corrosion layer is intact. Because of the difference of sound intensity between the two echoes, the images generated by them are different. In conclusion, according to the difference of the gray ultrasound image, it can effectively distinguish whether there is shedding damage in underwater metal pipelines' external anticorrosive coating. Next, the difference of sound intensity between the pipeline defect area and the pipeline normal area is analyzed.

Analysis of Underwater Pipeline Acoustic Scattering Characteristics
The metal pipeline studied in this paper has three layers of PE material, and the inner is high strength steel material which is commonly used in underwater metal pipelines. To analyse the acoustic scattering characteristics, the outer part of the pipeline is From Figure 2, the pipeline body is exposed in the water when the underwater metal pipeline external anticorrosive coating shedding off. When the acoustic wave meets the underwater metal pipeline, mirror reflection is caused. The elastic reflection occurs when the external anti-corrosion layer is intact. Because of the difference of sound intensity between the two echoes, the images generated by them are different. In conclusion, according to the difference of the gray ultrasound image, it can effectively distinguish whether there is shedding damage in underwater metal pipelines' external anticorrosive coating. Next, the difference of sound intensity between the pipeline defect area and the pipeline normal area is analyzed.

Analysis of Underwater Pipeline Acoustic Scattering Characteristics
The metal pipeline studied in this paper has three layers of PE material, and the inner is high strength steel material which is commonly used in underwater metal pipelines. To analyse the acoustic scattering characteristics, the outer part of the pipeline is regarded as elastic medium and the inner part as rigid medium respectively. According to the theory of underwater acoustics, there is a difference between the scattering of elastic and rigid media. Under the same incident sound field, the intensity of acoustic is different between them. The different characteristics of the acoustic scattering field between them provide theoretical basis for ultrasonic imaging detection. Considering the convenience of the experimental study, the experimental object in this paper is a finite length underwater metal pipeline. The finite length pipeline is simplified to a cylinder with two different materials inside and outside. The Figure 3 and parameters are as follows.
regarded as elastic medium and the inner part as rigid medium respectively. According to the theory of underwater acoustics, there is a difference between the scattering of elastic and rigid media. Under the same incident sound field, the intensity of acoustic is different between them. The different characteristics of the acoustic scattering field between them provide theoretical basis for ultrasonic imaging detection. Considering the convenience of the experimental study, the experimental object in this paper is a finite length underwater metal pipeline. The finite length pipeline is simplified to a cylinder with two different materials inside and outside. The Figure 3 and parameters are as follows.
Let the length be 2L, the diameter be a, and the distance from a point on the axis to the center O is t. In space, the distance between a point and the central point O is , the distance from a point on the central axis is d, and the vertical distance from the central axis is r. It is assumed that the two ends of the finite cylindrical body satisfy the simple boundary conditions, ignoring the effect of acoustic scattering at the end position. We assume that the cylinder is slender, that is to say, it satisfies / ≪ 1, and the cylinder satisfies Donnel's thin shell theory [35]. Solving the intensity of sound field in a space position of the fluid outside the cylinder, the sound field is the sum of the incident sound field, the specular reflection sound field and the elastic reflection sound field [36,37].
The incident sound field is   Let the length be 2 L, the diameter be a, and the distance from a point on the axis to the center O is t. In space, the distance between a point O and the central point O is d 0 , the distance from a point on the central axis is d, and the vertical distance from the central axis is r. It is assumed that the two ends of the finite cylindrical body satisfy the simple boundary conditions, ignoring the effect of acoustic scattering at the end position. We assume that the cylinder is slender, that is to say, it satisfies a/L 1, and the cylinder satisfies Donnel's thin shell theory [35].
Solving the intensity of sound field in a space position of the fluid outside the cylinder, the sound field is the sum of the incident sound field, the specular reflection sound field and the elastic reflection sound field [36,37].
The incident sound field is p i = e i(k z z+k x x−ωt) , among them: k z = k cos θ i , k x = k sin θ i , k = ω/c 0 are the number of sound waves in the fluid. In cylindrical coordinates (r, ϕ, z), the elastic reflected sound field p res is as follows: Among them, b np is a parameter determined by the vibration equation of external anticorrosive coating in underwater metal pipeline.  ε n is the Neumann factor. When n = 0, ε n = 1 and n > 0, ε n = 2. Then the elastic reflection sound field is obtained.
Mirror reflected sound field: Among them: . The initial grazing angle is α 0 ,α i , There are only rigid boundary conditions at shedding of external anticorrosive coating in the underwater metal pipeline, therefore, only the mirror reflection sound field is considered.
where there is no shedding, there are both elastic sound field and specular reflection sound field.
From Formula 5, it can be seen that whether there is a defect in the pipeline causing the difference of the reflected sound field strength. The difference of sound field intensity provides a theoretical basis for calculating whether there are defects in pipelines.

Underwater Pipeline Shedding Damage Detection Method
After comparing the difference of sound intensity between pipeline shedding and the normal part, the detection methods is introduced in this section. In this paper, a damage detection method based on a HOG + SVM target detection algorithm is proposed. Firstly, the image is divided into the pipeline area and non-pipeline area. Then the HOG feature extraction algorithm is used to extract underwater image features. The SVM algorithm is used to train the feature data of underwater metal pipeline, to build a model which can identifies pipeline area and non-pipeline area. Finally, we input the test image into the model to extract the pipeline area. The projection area of the pipeline is extracted from it, and the shedding damage position is calculated by the gray average value. The flow of this method is shown in Figure 4.
There are only rigid boundary conditions at shedding of external anticorrosiv coating in the underwater metal pipeline, therefore, only the mirror reflection sound field is considered.
where there is no shedding, there are both elastic sound field and specular reflection sound field. s rig res From Formula 5, it can be seen that whether there is a defect in the pipeline causing the difference of the reflected sound field strength. The difference of sound field intensity provides a theoretical basis for calculating whether there are defects in pipelines.

Underwater Pipeline Shedding Damage Detection Method
After comparing the difference of sound intensity between pipeline shedding and the normal part, the detection methods is introduced in this section. In this paper, damage detection method based on a HOG + SVM target detection algorithm is pro posed. Firstly, the image is divided into the pipeline area and non-pipeline area. Then th HOG feature extraction algorithm is used to extract underwater image features. The SVM algorithm is used to train the feature data of underwater metal pipeline, to build a mode which can identifies pipeline area and non-pipeline area. Finally, we input the test imag into the model to extract the pipeline area. The projection area of the pipeline is extracted from it, and the shedding damage position is calculated by the gray average value. Th flow of this method is shown in Figure 4.

Extracting Pipeline Area from the Underwater Ultrasound Image
After obtaining the images of the pipeline area and non-pipeline area, the HOG algorithm is used to extract the features. HOG is a description method used for object detection in computer vision and pattern recognition [38,39]. It is mainly used for pedestrian detection in static images and videos [40]. HOG requires the detected object shape to be described by the distribution of light intensity gradient or edge direction, and the feature is constructed by calculating and statistically analysing the image gradient direction. HOG algorithm uses block slider to extract image features. Block contains cell, which contains the features of the target. Its algorithm flow is shown in Figure 5. After obtaining the images of the pipeline area and non-pipeline area, the HOG al gorithm is used to extract the features. HOG is a description method used for object de tection in computer vision and pattern recognition [38,39]. It is mainly used for pedes trian detection in static images and videos [40]. HOG requires the detected object shape to be described by the distribution of light intensity gradient or edge direction, and the feature is constructed by calculating and statistically analysing the image gradient direc tion. HOG algorithm uses block slider to extract image features. Block contains cell which contains the features of the target. Its algorithm flow is shown in Figure 5. After the image information of pipeline area and non-pipeline area is represented by characteristic matrix, Support vector machine (SVM) is used to build training model SVM is machine learning algorithm based on statistical learning theory and the structura risk minimization principle. It has many unique advantages in solving small sample non-linear and high-dimensional pattern recognition problems. The mechanism of SVM is to find a classification hyperplane with the largest spacing, which not only guarantee the accuracy of classification, but also has the highest reliability and gives the classifie strong generalization. In theory, SVM can achieve the optimal classification of linea separable samples. For the case of non-linear separability, SVM maps the non-linea separable samples from low-dimensional input space to high-dimensional feature space by introducing a kernel function, and processes the non-linear separable samples in high-dimensional feature space by using the method of processing linear separable samples [41,42].
This paper is a two-class problem. It aims to classify the pipeline area and non-pipeline area. In this paper, the HOG algorithm is used to extract the image feature of different regions and label them. Then SVM is used to train the classification model The training data sample set ( , ), i=1, 2, …, l, ∈ , ∈ ±1 . l is the total number o training samples. Hyperplane is ( ⋅ ) + = 0. To classify all samples correctly, the constraints should be satisfied： ( ⋅ ) + ≥ 1, = 1,2, … , .
The calculable classification interval is 2 ‖ ‖. The problem of constructing an op timal hyperplane is transformed into finding minΦ( ) under constraint: ( ) = ‖ ‖ = ( ⋅ ). Lagrange function is introduced to solve constrained optimization problems. After the image information of pipeline area and non-pipeline area is represented by characteristic matrix, Support vector machine (SVM) is used to build training model. SVM is machine learning algorithm based on statistical learning theory and the structural risk minimization principle. It has many unique advantages in solving small sample, non-linear and high-dimensional pattern recognition problems. The mechanism of SVM is to find a classification hyperplane with the largest spacing, which not only guarantees the accuracy of classification, but also has the highest reliability and gives the classifier strong generalization. In theory, SVM can achieve the optimal classification of linear separable samples. For the case of non-linear separability, SVM maps the non-linear separable samples from low-dimensional input space to high-dimensional feature space by introducing a kernel function, and processes the non-linear separable samples in high-dimensional feature space by using the method of processing linear separable samples [41,42].
This paper is a two-class problem. It aims to classify the pipeline area and non-pipeline area. In this paper, the HOG algorithm is used to extract the image features of different regions and label them. Then SVM is used to train the classification model. The training data sample set (x i , y i ), i = 1, 2, . . . , l, x ∈ R n , y ∈ {±1}. l is the total number of training samples. Hyperplane is (w · x) + b = 0. To classify all samples correctly, the constraints should be satisfied: The calculable classification interval is 2l||w||. The problem of constructing an optimal hyperplane is transformed into finding minΦ(w) under constraint: minΦ(w) = 1 2 ||w|| 2 = 1 2 (w · w). Lagrange function is introduced to solve constrained optimization problems.
In the formula, a i (a i > 0) is Lagrange multiplier. The solution of constrained optimization is determined by the saddle point of Lagrange function. When the partial derivatives of w and b are 0 at saddle point, the problem is turned into a dual problem: Among them, s.t. l ∑ j=1 a j y j = 0 j = 1, 2, . . . , l, a j > 0. The optimal solution is a * = (a * 1 , a * 2 , . . . , a * j ) T . Computing the optimal weight vector w * and optimal partial b * .
In the formula, the subscript j ∈ j a j > 0 . Then the optimal classification hyperplane (w * .x) + b * = 0 is obtained. The optimal classification function is as follows: The transformation of x from input space R n to feature space H is Φ: The optimal classification function can be obtained by replacing the input vector x with the eigenvector Φ(x).
After the classification function is obtained, the test data can be classified. By inputting the underwater ultrasonic image, the pipeline area can be extracted.

Identification Method of Shedding Damage in Metal Underwater Pipeline
Following this, the extracted pipeline image area is transformed into a gray value feature matrix. The pipeline area includes a pipeline projection area and a dark area. The principle is shown in Figure 2. The dark area cannot reflect whether the pipeline is damaged, so the pipeline projection area needs to be extracted from the pipeline area. The method is as follows. Assuming that the pipeline image is placed vertically, the right area is the projection area. We calculate the mean value of the three columns on the right side of the pipeline area, and then compare each column on the left side with the mean value to determine whether that column is a projection area. If more than half of the characteristic values of a column suddenly change, that is, the characteristic value is less than 70% or more than 130% of the mean value. Than it is considered that the shadow area starts from this column.
After the pipeline projection area is extracted, the average gray value is calculated. In this paper, we use the adaptive threshold binarization method to calculate the shedding width. For gray row mean vector f (i), their mean value ave is calculated. Because the defect location value is smaller, the pixel points with gray value less than the mean value are multiplied by a parameter less than 1 (0.8), and the mean value ave is updated. All gray values are compared with ave. If f (i) is greater than the ave, the g(i) assignment 1 and less assignment 0. The position of 0 in g(i) is the defect position. The damage position of the pipeline can be obtained with this method. Note, the parameters in Section 2.2.2 are determined by the training data of underwater pipeline ultrasonic images. The judgment formula of the pixel points is as follows:

Experiments and Analyses
To verify the effectiveness of this method, an experimental platform based on an Autonomous Surface Vehicle (ASV) is designed, and the shedding damage test of threelayer polyethylene (PE) pipeline is carried out in an experimental pool. The experimental platform and experimental process are introduced in this section.

Experimental Setup
As shown in Figure 6, the ASV include control module, sensor module and wireless transmission module. And the sensor model is Starfish 450H. The experimental site is a 2 m deep pool.

Experimental Setup
As shown in Figure 6, the ASV include control module, sensor module and wireless transmission module. And the sensor model is Starfish 450H. The experimental site is a 2m deep pool. The experimental platform is divided into a shore-based system that for human-computer interaction and an unmanned ship acoustic sensor system for acoustic emission, reception and processing. The ASV transmits real-time data with shore-based system in the form of radio frequency. The shore-based part is composed of an upper computer server and radio frequency receiving module. The acoustic sensor system of ASV includes operation control system and sensor system. The framework of the experimental platform is shown in Figure 7. To ensure the acoustic sensor is unaffected by the ASV propeller noise, the acoustic sensor is installed 0.5 m away from the propeller. To reduce the interference of surface water wave, the probe installation depth should be below 0.2 m. The installation schematic diagram of the acoustic sensor is shown in Figure 8. The experimental platform is divided into a shore-based system that for humancomputer interaction and an unmanned ship acoustic sensor system for acoustic emission, reception and processing. The ASV transmits real-time data with shore-based system in the form of radio frequency. The shore-based part is composed of an upper computer server and radio frequency receiving module. The acoustic sensor system of ASV includes operation control system and sensor system. The framework of the experimental platform is shown in Figure 7.

Experimental Setup
As shown in Figure 6, the ASV include control module, sensor module and wireless transmission module. And the sensor model is Starfish 450H. The experimental site is a 2m deep pool. The experimental platform is divided into a shore-based system that for human-computer interaction and an unmanned ship acoustic sensor system for acoustic emission, reception and processing. The ASV transmits real-time data with shore-based system in the form of radio frequency. The shore-based part is composed of an upper computer server and radio frequency receiving module. The acoustic sensor system of ASV includes operation control system and sensor system. The framework of the experimental platform is shown in Figure 7. To ensure the acoustic sensor is unaffected by the ASV propeller noise, the acoustic sensor is installed 0.5 m away from the propeller. To reduce the interference of surface water wave, the probe installation depth should be below 0.2 m. The installation schematic diagram of the acoustic sensor is shown in Figure 8. To ensure the acoustic sensor is unaffected by the ASV propeller noise, the acoustic sensor is installed 0.5 m away from the propeller. To reduce the interference of surface water wave, the probe installation depth should be below 0.2 m. The installation schematic diagram of the acoustic sensor is shown in Figure 8. To ensure the acoustic sensor is unaffected by the ASV propeller noise, the acoustic sensor is installed 0.5 m away from the propeller. To reduce the interference of surface water wave, the probe installation depth should be below 0.2 m. The installation schematic diagram of the acoustic sensor is shown in Figure 8.  In the experiment, an underwater metal pipeline of 1 m length, 133 mm diameter and 3 mm thickness of the external anticorrosive coating is taken as the object. The method presented in this paper is used to detect the pipeline shedding damage. The underwater metal pipeline with three PE external corrosion protection layers is shown in Figure 9. In the experiment, an underwater metal pipeline of 1 m length, 133 mm diameter and 3 mm thickness of the external anticorrosive coating is taken as the object. The method presented in this paper is used to detect the pipeline shedding damage. The underwater metal pipeline with three PE external corrosion protection layers is shown in Figure 9. The reflected sound field is related to the width of pipeline shedding damage according to the analysis of acoustic scattering characteristics. Therefore, the experiments are carried out with 10 mm, 20 mm and 30 mm of the shedding width in the underwater metal pipeline external anticorrosive coating. The experimental content is introduced in the next section.

Experimental Process
Firstly, the pipeline data and detection location information are taken into the analysis formula in Section 2. The difference between the defect pipeline area and the normal pipeline area are analyzed before the experiment. Then we analyze the difference of different defect and different incidence angle. We determine the angle of the sensor to the pipeline. The difference of different pipe diameters is shown in Figure 10. It can be seen from the figure that there are obvious differences between the normal area and the defective area.  Figure 10 shows that the sound intensity increases with the increase of abscissa ka (k is constant, a is cylindrical pipe radius) at the same incident angle and reflection direction. At the same ka value, the sound intensity of the intact underwater metal pipeline is greater than that shedding of the external anticorrosive coating. When the radius of the The reflected sound field is related to the width of pipeline shedding damage according to the analysis of acoustic scattering characteristics. Therefore, the experiments are carried out with 10 mm, 20 mm and 30 mm of the shedding width in the underwater metal pipeline external anticorrosive coating. The experimental content is introduced in the next section.

Experimental Process
Firstly, the pipeline data and detection location information are taken into the analysis formula in Section 2. The difference between the defect pipeline area and the normal pipeline area are analyzed before the experiment. Then we analyze the difference of different defect and different incidence angle. We determine the angle of the sensor to the pipeline. The difference of different pipe diameters is shown in Figure 10. It can be seen from the figure that there are obvious differences between the normal area and the defective area. In the experiment, an underwater metal pipeline of 1 m length, 133 mm diameter and 3 mm thickness of the external anticorrosive coating is taken as the object. The method presented in this paper is used to detect the pipeline shedding damage. The underwater metal pipeline with three PE external corrosion protection layers is shown in Figure 9. The reflected sound field is related to the width of pipeline shedding damage according to the analysis of acoustic scattering characteristics. Therefore, the experiments are carried out with 10 mm, 20 mm and 30 mm of the shedding width in the underwater metal pipeline external anticorrosive coating. The experimental content is introduced in the next section.

Experimental Process
Firstly, the pipeline data and detection location information are taken into the analysis formula in Section 2. The difference between the defect pipeline area and the normal pipeline area are analyzed before the experiment. Then we analyze the difference of different defect and different incidence angle. We determine the angle of the sensor to the pipeline. The difference of different pipe diameters is shown in Figure 10. It can be seen from the figure that there are obvious differences between the normal area and the defective area.  Figure 10 shows that the sound intensity increases with the increase of abscissa ka (k is constant, a is cylindrical pipe radius) at the same incident angle and reflection direction. At the same ka value, the sound intensity of the intact underwater metal pipeline is greater than that shedding of the external anticorrosive coating. When the radius of the pipeline is determined, the size of the shedding damage and the incident angle is affected by the sound intensity. The shedding damage size means the width along the axis  Figure 10 shows that the sound intensity increases with the increase of abscissa ka (k is constant, a is cylindrical pipe radius) at the same incident angle and reflection direction. At the same ka value, the sound intensity of the intact underwater metal pipeline is greater than that shedding of the external anticorrosive coating. When the radius of the pipeline is determined, the size of the shedding damage and the incident angle is affected by the sound intensity. The shedding damage size means the width along the axis of the pipeline. The influence of pipeline shedding damage width and sound wave intensity angle on the sound intensity are calculated. The results are shown in Figure 11. Angle of incidence /rad Figure 11. Sound intensity of rigid finite-length cylinder with shedding damage.
From Figure 11, the sound intensity is increased with the increase of the shedding damage width. It can be seen from the figure that there is a maximum sound intensity value at 90°, which means the maximum intensity of the acoustic target in the case of backscattering. To increase the difference of sound intensity between different state pipelines in the experiment, the incident angle of the acoustic sensor is π, and the reflection angle is 90°.
After determining the experimental parameters, the experiment is carried out. The acoustic sensor emits a sector beam at fixed frequency of 450 k Hz. The fan-shaped beam has a vertical opening angle of 60° and a horizontal opening angle of 1.8°. The ASV scans underwater at a fixed speed of 0.5 m/s. The operational process of the field experiment is shown in Figure 12. According to the underwater imaging test, the acoustic sensor has the clearest image From Figure 11, the sound intensity is increased with the increase of the shedding damage width. It can be seen from the figure that there is a maximum sound intensity value at 90 • , which means the maximum intensity of the acoustic target in the case of backscattering. To increase the difference of sound intensity between different state pipelines in the experiment, the incident angle of the acoustic sensor is π, and the reflection angle is 90 • .
After determining the experimental parameters, the experiment is carried out. The acoustic sensor emits a sector beam at fixed frequency of 450 k Hz. The fan-shaped beam has a vertical opening angle of 60 • and a horizontal opening angle of 1.8 • . The ASV scans underwater at a fixed speed of 0.5 m/s. The operational process of the field experiment is shown in Figure 12. Sound intensity/dB Shedding 30mm Shedding 20mm Shedding 10mm Angle of incidence /rad Figure 11. Sound intensity of rigid finite-length cylinder with shedding damage.
From Figure 11, the sound intensity is increased with the increase of the shedding damage width. It can be seen from the figure that there is a maximum sound intensity value at 90°, which means the maximum intensity of the acoustic target in the case of backscattering. To increase the difference of sound intensity between different state pipelines in the experiment, the incident angle of the acoustic sensor is π, and the reflection angle is 90°.
After determining the experimental parameters, the experiment is carried out. The acoustic sensor emits a sector beam at fixed frequency of 450 k Hz. The fan-shaped beam has a vertical opening angle of 60° and a horizontal opening angle of 1.8°. The ASV scans underwater at a fixed speed of 0.5 m/s. The operational process of the field experiment is shown in Figure 12. According to the underwater imaging test, the acoustic sensor has the clearest image at the horizontal distance of 3 m from the measured target. Therefore, the metal underwater pipeline is placed at the horizontal distance of the ASV at 3 m in this experiment. The direction of the ASV is parallel to the axis of the underwater metal pipeline. At the same time, the ASV's direction is perpendicular to the shore and the ASV keeps moving at a uniform speed. The underwater pipelines with three different shedding widths are According to the underwater imaging test, the acoustic sensor has the clearest image at the horizontal distance of 3 m from the measured target. Therefore, the metal underwater pipeline is placed at the horizontal distance of the ASV at 3 m in this experiment. The direction of the ASV is parallel to the axis of the underwater metal pipeline. At the same time, the ASV's direction is perpendicular to the shore and the ASV keeps moving at a uniform speed. The underwater pipelines with three different shedding widths are tested 20 times respectively. The underwater ultrasound images are obtained through the experiment's platform. This is used to identify the location and width of the underwater metal pipeline external anticorrosive coating shedding damage.

Experimental Results and Discussion
After the experiment, 60(20 × three kinds shedding damage) images were obtained. They were used to train the SVM model and test damage identification. Firstly, 10 images were randomly selected from each kind of defect, which meant a total 30 images to train SVM models. To introduce the image data processing process, one picture was randomly selected as an example. The original ultrasonic image collected in the experiment is shown in the left side of Figure 13. To highlight the pipeline position, the gray enhancement method was used to process the image, and the result is shown in the right side of Figure 13. the experiment's platform. This is used to identify the location and width of the underwater metal pipeline external anticorrosive coating shedding damage.

Experimental Results and Discussion
After the experiment, 60(20 × three kinds shedding damage) images were obtained. They were used to train the SVM model and test damage identification. Firstly, 10 images were randomly selected from each kind of defect, which meant a total 30 images to train SVM models. To introduce the image data processing process, one picture was randomly selected as an example. The original ultrasonic image collected in the experiment is shown in the left side of Figure 13. To highlight the pipeline position, the gray enhancement method was used to process the image, and the result is shown in the right side of Figure 13. After processing images, we selected the pipeline area artificially. Because the size of the pipeline, distance between pipeline and sensor are the same in all images, the pixel points occupied by the pipeline area were equal. In the image, the pipeline area occupies the position of 180 × 65 pixel points, which is the pipeline area sample. Next, four different positions were randomly selected as non-pipeline sample. as shown in Figure 14. After all the images were processed in this way, 30 samples of pipeline area and 120 samples of non-pipeline area were obtained. They were used to train SVM model. Next, the HOG was used to extract the feature vector. The parameters of the HOG are shown in Table 1. Among them, small cells lead to large amount of calculation and large cells lead to a rough model. Because the structure in this paper is simple, we chose cell size of 8 × 8. NumBins indicates the magnitude of the gradient value in 9 directions.  After processing images, we selected the pipeline area artificially. Because the size of the pipeline, distance between pipeline and sensor are the same in all images, the pixel points occupied by the pipeline area were equal. In the image, the pipeline area occupies the position of 180 × 65 pixel points, which is the pipeline area sample. Next, four different positions were randomly selected as non-pipeline sample. as shown in Figure 14. After all the images were processed in this way, 30 samples of pipeline area and 120 samples of non-pipeline area were obtained. They were used to train SVM model. the experiment's platform. This is used to identify the location and width of the underwater metal pipeline external anticorrosive coating shedding damage.

Experimental Results and Discussion
After the experiment, 60(20 × three kinds shedding damage) images were obtained. They were used to train the SVM model and test damage identification. Firstly, 10 images were randomly selected from each kind of defect, which meant a total 30 images to train SVM models. To introduce the image data processing process, one picture was randomly selected as an example. The original ultrasonic image collected in the experiment is shown in the left side of Figure 13. To highlight the pipeline position, the gray enhancement method was used to process the image, and the result is shown in the right side of Figure 13. After processing images, we selected the pipeline area artificially. Because the size of the pipeline, distance between pipeline and sensor are the same in all images, the pixel points occupied by the pipeline area were equal. In the image, the pipeline area occupies the position of 180 × 65 pixel points, which is the pipeline area sample. Next, four different positions were randomly selected as non-pipeline sample. as shown in Figure 14. After all the images were processed in this way, 30 samples of pipeline area and 120 samples of non-pipeline area were obtained. They were used to train SVM model. Next, the HOG was used to extract the feature vector. The parameters of the HOG are shown in Table 1. Among them, small cells lead to large amount of calculation and large cells lead to a rough model. Because the structure in this paper is simple, we chose cell size of 8 × 8. NumBins indicates the magnitude of the gradient value in 9 directions.  Next, the HOG was used to extract the feature vector. The parameters of the HOG are shown in Table 1. Among them, small cells lead to large amount of calculation and large cells lead to a rough model. Because the structure in this paper is simple, we chose cell size of 8 × 8. NumBins indicates the magnitude of the gradient value in 9 directions. The representation of the HOG algorithm eigenvalues is shown in Figure 15. The representation of the HOG algorithm eigenvalues is shown in Figure 15. After the image information is transformed into a feature vector, it can be input into SVM model for training. Next, we used it as a test model. We extracted the pipeline area of the test image. Before the test image was input into the model, we first divide the test image into several samples according to the size of the pipeline area (180 × 65), and the specific division method is shown in Figure 16. First, the upper left corner of the image is sample 1, then moved 5 pixels to the right as sample 2 and so on, until the box moves to the upper right corner and now it is sample n, then moves five pixels down as sample n+1, then moves left until the box covers the test image. After the sample is divided and input into the model, the pipeline area can be obtained, as shown in Figure 17a. Next, according to the gray value of the pipeline projection area and the pipeline shadow area, the pipeline projection area is extracted from the pipeline area. This paper uses the numerical difference method, which is introduced in Section 2.2.2, to extracted the pipeline projection area, as shown in Figure 17b. To identify the shedding damage, the feature matrix extracted from the pipeline project gray images is used to calculate the average gray value. The line average gray value damage identification curve is shown in Figure 17c. The damage location can be calculated by the method introduced in Section 2.2.2. After the image information is transformed into a feature vector, it can be input into SVM model for training. Next, we used it as a test model. We extracted the pipeline area of the test image. Before the test image was input into the model, we first divide the test image into several samples according to the size of the pipeline area (180 × 65), and the specific division method is shown in Figure 16. First, the upper left corner of the image is sample 1, then moved 5 pixels to the right as sample 2 and so on, until the box moves to the upper right corner and now it is sample n, then moves five pixels down as sample n + 1, then moves left until the box covers the test image. The representation of the HOG algorithm eigenvalues is shown in Figure 15. After the image information is transformed into a feature vector, it can be input into SVM model for training. Next, we used it as a test model. We extracted the pipeline area of the test image. Before the test image was input into the model, we first divide the test image into several samples according to the size of the pipeline area (180 × 65), and the specific division method is shown in Figure 16. First, the upper left corner of the image is sample 1, then moved 5 pixels to the right as sample 2 and so on, until the box moves to the upper right corner and now it is sample n, then moves five pixels down as sample n+1, then moves left until the box covers the test image. After the sample is divided and input into the model, the pipeline area can be obtained, as shown in Figure 17a. Next, according to the gray value of the pipeline projection area and the pipeline shadow area, the pipeline projection area is extracted from the pipeline area. This paper uses the numerical difference method, which is introduced in Section 2.2.2, to extracted the pipeline projection area, as shown in Figure 17b. To identify the shedding damage, the feature matrix extracted from the pipeline project gray images is used to calculate the average gray value. The line average gray value damage identification curve is shown in Figure 17c. The damage location can be calculated by the method introduced in Section 2.2.2. After the sample is divided and input into the model, the pipeline area can be obtained, as shown in Figure 17a. Next, according to the gray value of the pipeline projection area and the pipeline shadow area, the pipeline projection area is extracted from the pipeline area. This paper uses the numerical difference method, which is introduced in Section 2.2.2, to extracted the pipeline projection area, as shown in Figure 17b. To identify the shedding damage, the feature matrix extracted from the pipeline project gray images is used to calculate the average gray value. The line average gray value damage identification curve is shown in Figure 17c. The damage location can be calculated by the method introduced in Section 2.2.2. This pipeline of 1 m has 180 pixel points in total, which means a pixel point is 5.6 mm. As shown in Figure 17, the final defect identification position accounts for 2 pixel points. The recognition accuracy of this pipeline defect width is 37.3%. Next, the detection differences between different defect widths were compared. As shown in Figure 18, images of three different shedding damage were randomly selected. As shown in Figure 18, they can all extract the pipeline area. Then, we identified their damage location. The results are shown in Figure 19.

Shedding width 10mm
Shedding width 20mm Shedding width 30mm Figure 19. Picture of defect location recognition.
The red points in Figure 19 are the pixel points calculated as shedding damage. According to the pixel points occupied by the pipeline in the gray scale image, the widths of defects identified of 10 mm, 20 mm and 30 mm shedding damage are calculated to be 11.2 mm. However, when the shedding width is 20 mm, we mistakenly checked other normal positions as defects. Then we put 30 test images into the model for testing, and the results are shown in Table 2. This pipeline of 1 m has 180 pixel points in total, which means a pixel point is 5.6 mm. As shown in Figure 17, the final defect identification position accounts for 2 pixel points. The recognition accuracy of this pipeline defect width is 37.3%. Next, the detection differences between different defect widths were compared. As shown in Figure 18, images of three different shedding damage were randomly selected. This pipeline of 1 m has 180 pixel points in total, which means a pixel point is 5.6 mm. As shown in Figure 17, the final defect identification position accounts for 2 pixel points. The recognition accuracy of this pipeline defect width is 37.3%. Next, the detection differences between different defect widths were compared. As shown in Figure 18, images of three different shedding damage were randomly selected. As shown in Figure 18, they can all extract the pipeline area. Then, we identified their damage location. The results are shown in Figure 19.

Shedding width 10mm
Shedding width 20mm Shedding width 30mm Figure 19. Picture of defect location recognition.
The red points in Figure 19 are the pixel points calculated as shedding damage. According to the pixel points occupied by the pipeline in the gray scale image, the widths of defects identified of 10 mm, 20 mm and 30 mm shedding damage are calculated to be 11.2 mm. However, when the shedding width is 20 mm, we mistakenly checked other normal positions as defects. Then we put 30 test images into the model for As shown in Figure 18, they can all extract the pipeline area. Then, we identified their damage location. The results are shown in Figure 19. This pipeline of 1 m has 180 pixel points in total, which means a pixel point is 5.6 mm. As shown in Figure 17, the final defect identification position accounts for 2 pixel points. The recognition accuracy of this pipeline defect width is 37.3%. Next, the detection differences between different defect widths were compared. As shown in Figure 18, images of three different shedding damage were randomly selected. As shown in Figure 18, they can all extract the pipeline area. Then, we identified their damage location. The results are shown in Figure 19.

Shedding width 10mm
Shedding width 20mm Shedding width 30mm Figure 19. Picture of defect location recognition.
The red points in Figure 19 are the pixel points calculated as shedding damage. According to the pixel points occupied by the pipeline in the gray scale image, the widths of defects identified of 10 mm, 20 mm and 30 mm shedding damage are calculated to be 11.2 mm. However, when the shedding width is 20 mm, we mistakenly checked other normal positions as defects. Then we put 30 test images into the model for testing, and the results are shown in Table 2. The red points in Figure 19 are the pixel points calculated as shedding damage. According to the pixel points occupied by the pipeline in the gray scale image, the widths of defects identified of 10 mm, 20 mm and 30 mm shedding damage are calculated to be 11.2 mm. However, when the shedding width is 20 mm, we mistakenly checked other normal positions as defects. Then we put 30 test images into the model for testing, and the results are shown in Table 2. As shown in Table 2, all the pipeline areas are accurately extracted in test images. In this paper, if the damage location can be detected, we think the detection accuracy is accurate. The results show that the detection accuracy is 80% when the shedding width is 10 mm and 20 mm. When the defect width is 30 mm, the detection accuracy is 90%. The detection accuracy of all defect width is less than 65%.

Conclusions
In this paper, a method based on HOG+SVM for ultrasonic imaging detection of an external anticorrosive coating in an underwater metal pipeline was proposed. The non-contact underwater acoustic imaging method was used to detect the damage in the underwater metal pipeline. An Autonomous Surface Vehicle (ASV) was used as carrying tool to realize unmanned real-time remote online detection. Firstly, the acoustic scattering characteristics analysis model was established, and the factors affecting the acoustic scattering characteristics analyzed. The feasibility of non-contact ultrasonic imaging for the detection of the outer anti-corrosion layer was proved from the theoretical. After that, the target detection algorithm of HOG+SVM was introduced. Finally, an experimental platform based on the ASV researched by the team was built, and the real-time transmission of reflected data was realized by wireless communication. Taking the pipeline with three PE outer anti-corrosion coatings as the object, the experiment was carried out in an experimental pool. Underwater pipelines with 10 mm, 20 mm and 30 mm outer anti-corrosion layer shedding damage defects were tested, respectively. The identification curve of shedding damage detection was made, and the location of shedding damage was realized. The results show that the method can extract the pipeline area from the ultrasonic image accurately. For detecting the damaged position of the pipeline, the detection accuracy is higher when the width is larger. For the detection of defect width, the results are less than 65%. The inaccurate identification of damage width is mainly due to the insufficient resolution of detection equipment.
In summary, the method in this paper can be used for distinguishing the shedding damage of underwater pipeline external anticorrosive coating. By this method, the damage location can be accurately identified, and the defect size can even be quantified. However, the current experimental conditions are ideal, and the influence of underwater fluctuations, pipeline surface attachments and other real detection factors will be considered in future research.  Informed Consent Statement: Informed consent was obtained from all subjects involved in the study.

Data Availability Statement:
The data presented in this study are available on request from the corresponding author. The data are not publicly available.

Conflicts of Interest:
The authors declare this paper has no conflict of interest.