Application of improved multi-strategy MPA-VMD in pipeline leakage detection

This paper is concerned with the development of improved multi-strategy MPA-VMD method and its application in pipeline leakage detection. Aiming at the shortcomings of the marine predator algorithm (MPA) itself, which has a slow convergence speed and is easy to fall into local optimum, an improved MPA is proposed and used to find two important parameters in variational mode decomposition (VMD), and then dynamic entropy is used to select effective modes. In the initial stage of the population, a good point set strategy is adopted to enhance the search accuracy by increasing the diversity of the initial population; in the search process, a nonlinear convergence factor and the Cauchy distribution are introduced to optimize the predator step size to enhance the global search ability of the algorithm. The ability of the algorithm is enhanced to jump out of the local optimum, and the convergence speed of the algorithm is further improved; the effective mode after VMD is selected by the method of symbolic dynamic entropy. The experimental results show that compared with MPA-VMD, grey wolf optimization-VMD and particle swarm optimization-VMD methods, the devised method has improved signal-to-noise ratio, reduced mean square error and mean absolute error, and has better denoising effect.


Introduction
As a common method of energy storage and transportation, pipeline transportation has gradually increased its status in today's society (Hu et al., 2021;Ji et al., 2021;Lu et al., 2021;Wang et al., 2020;Yang et al., 2022).Because of its high safety, low cost and fast transportation, it has become one of the five major transportation industries.However, due to the longevity of the pipeline itself and the influence of natural disasters and man-made damage, the leakage of the pipeline occurs from time to time.Therefore, it is particularly important to determine efficiently and accurately whether the pipeline leaks to avoid the occurrence of serious disasters (Qui nones- Grueiro et al., 2021;Zhang et al., 2022).
With the rapid development of science and technology, more and more researchers use various signal denoising methods to eliminate the noise signal contained in the pipeline leakage signal to the greatest extent, including wavelet analysis (Chen et al., 2005), empirical mode decomposition (EMD) (Huang et al., 1998) and filter denoising.EMD is an adaptive signal timefrequency processing method suitable for nonlinear and non-stationary signals, but the signal components CONTACT Jingyi Lu ljywdm@126.comdecomposed by the EMD method would have the problem of modal aliasing, and it is difficult to select effective modes for reconstruction.The emergence of variational mode decomposition (VMD) (Dragomiretskiy & Zosso, 2014) succeeds in suppressing the problem of EMD mode aliasing, but the selection of the two preset parameters K and α in the VMD algorithm and the effective mode after decomposition is very difficult.Intelligent optimization algorithm, as a rapidly emerging solving method of optimization problem in recent years, can validly and correctly solve the issue that the parameters selection is challenging.The VMD parameters have been optimized by particle swarm intelligence optimization algorithm, and the optimal value of parameter combination [K, α] has been adaptively selected (Wei et al., 2020).Whale optimization algorithm (WOA) has been used to optimize the number of modes K and penalty parameter α in VMD (Zhang et al., 2021).Some people have used firefly algorithm to optimize VMD and get the optimal parameters K and α (Li et al., 2021).Aiming at the shortcomings of intelligent optimization algorithm involving easily falling into local optimum and slow convergence speed, an improved PSO optimization algorithm has been brought up based on chaos and Sigmoid function, which can successfully solve the defect of PSO algorithm easily falling into local optimal (Zhang et al., 2021).The problem of WOA convergence delay has been validly overcome by combining roulette with WOA (Kushwah et al., 2021).
To solve the problem that it is difficult to select effective modes of signals decomposed by VMD, a VMD method based on improved Bhattacharyya distance has been developed to select effective components by comparing the similarity between each intrinsic mode function (IMF) component and the original signal (Lu et al., 2020).The correlation coefficient method has been used to select effective IMF components with high correlation with the original signal for signal reconstruction (Jiang & Ge, 2017).The multi-objective optimization algorithm has been applied to drilling trajectory optimization, which is capable of solving the problem constrained by wellbore stability (Huang et al., 2022;Yu et al., 2022).A method, combining grey wolf optimization (GWO) algorithm with VMD, has been put forward to optimize the parameters of deep confidence network, which solved the problem that the early fault signal features are weak and easily submerged, resulting in low diagnosis accuracy of bearing weak faults (Jin et al., 2022;Shakiba et al., 2022).
Based on the above analysis, to find two important parameters of VMD more accurately, improve the signal denoising effect.In this paper, a multi-strategy improved marine predators algorithm (MPA) is proposed.VMD parameters are optimized by this algorithm, and then the IMF decomposed by VMD is reconstructed by using dynamic entropy, so as to complete the denoising of noisy signals.
In summary, the objective of this paper is to improve the intelligent optimization algorithm MPA, enhance the performance of optimization parameters, accurately select effective modes for reconstruction, and apply the reconstructed signal to pipeline leakage detection.The main challenges to be tackled in this paper include: (1) How to solve the unevenness issue of the population initialization of MPA algorithm?(2) How to promote the global search ability of MPA algorithm during the search process?and (3) How to use VMD algorithm to remove noise in pipeline leakage signals?The main contributions of this paper are emphasized as follows: (1) the diversity of population initialization of MPA algorithm is increased by adopting the good point set strategy; (2) both nonlinear convergence factor and Cauchy distribution algorithm are taken into consideration to enhance the global optimization ability of MPA algorithm and (3) dynamic entropy is employed to accurately select the effective modes in VMD algorithm, and the noise in the pipeline leakage signal is filtered out by reconstructing the effective modes.
The structure of this paper is generalized as follows.In Section 2, the relevant theories are given of various improvement strategies.In Section 3, several strategies are adopted to remedy the defects of MPA algorithm.The improved multi-strategy method is verified in Section 4 by a simulation example.The final experimental validation is carried out in Section 5 with the actual data of pipeline leakage, and the conclusion is derived in Section 6.

Principle of VMD
VMD is a commonly used signal decomposition method in signal processing.It can adaptively achieve frequency domain division and effective separation of components, and sort frequencies from low frequency to high frequency.The operation process of VMD algorithm consists of two parts: constructing and solving variational models.Among them, the core of constructing the variational model is to solve the constrained optimization variational problem, namely: where is the unilateral spectrum.Spectral modulation is performed by exponential e −jω k t , and then Gaussian smoothing is employed to demodulate the signal to obtain the bandwidth of each modal function.
In the process of solving the variational model, the augmented Lagrangian function is introduced as follows: where α is the penalty parameter and λ is the Lagrange multiplier.Use the alternating direction multiplier algorithm to iteratively solve the above formula.When the iterative conditions of (3) are satisfied, the total number of modes K after decomposition is obtained: where ε is the threshold judgment condition.

Marine predators algorithm
MPA (Faramarzi et al., 2020) is a new meta-heuristic optimization algorithm that simulates the relationship between predators and prey through three stages (Ho et al., 2021;Li et al., 2022;Rezk et al., 2022): Stage 1. Initialization: Randomly initialize the prey position within the search space as the initial solution: where X max and X min are the search space range, and rand(•) is a random number in [0, 1].Stage 2. Optimising: (i) At high velocity ratios or when the prey is moving faster than the predator. When (5) where − → R B is a random vector containing a normal distribution based on Brownian motion; the symbol ⊗ denotes item-wise multiplication; the multiplication of − → R B and the prey simulates the movement of the prey; P = 0.5; − → R is a vector of uniform random numbers in [0, 1]; Max_Iter represents the maximum number of iterations; and n means the population number.(ii) Unit rate ratio or when both predator and prey are moving at nearly the same speed.
When 1 3 Max_Iter < Iter < 2 3 Max_Iter: where CF = (1 − Iter Max_Iter ) (2 Iter Max_Iter ) is an adaptive parameter to control the step size of predator movement.− → R B multiplication with the Elite simulates the movement of the predator in Brownian fashion, while the prey follows the movement of the predator in Brownian motion to update its location.(iii) Predators move faster than prey at low rates. When where the multiplication of − → R L and Elite simulates the movement of predators in Levi's motion (Mantegna, 1994).Simultaneously increasing the step size to the elite position simulates predator movement to help update the prey position.
Stage 3. Eddy currents and fish aggregation (FADs) effects: where the probability of FADs affecting the optimization process is taken as FADs = 0.2.− → U is a binary vector of 0s and 1s.r is a uniform random number in the range [0, 1].

Good point set strategy
Since the random initialization is used in the population initialization, it is easy to cause local optimality.To improve the diversity and uniformity of the initial population, the initialization strategy of optimal point set is used to optimize the initialized population (He & Lu, 2022;Liu & Li, 2010;Sun & Tao, 2009).The theory of good point set (Wang et al., 2015) has been proposed by Luogeng Hua Hua and Wang (1978) and others, and its basic principle is: Let The deviation is where C(r, ε) is a constant related to r and ε, ε is a positive number, and r is a good point.Assuming that the initial population is 200, the scatter plots are displayed in Figure 1, which are generated by the optimal point set initialization strategy and the random initialization strategy.From Figure 1, we note that using the optimal point set initialization strategy can generate a better initial population than random initialization within the same range, so that the initial population has a uniform distribution, which is beneficial to enhance the convergence speed and global search ability of the algorithm.

Improved CF
To enhance the flexibility of the iterative optimization process of optimization algorithms, the weight coefficients have been ameliorated by many scholars (Agrawal, 2011;Su, 2017;Zhou et al., 2010).In this paper, the step CF of MPA algorithm is modified to make the change of CF more consistent with the rule of optimization.The improved CF is defined as follows: where Iter is the current iteration number and Max_Iter is the maximum number of iterations.It is concluded from Figure 2 that with the increase of the number of iterations, the changes of the two step sizes are first slow, then fast and then slow.Compared with the original CF, the improved CF has a slower change in the early stage of the iteration, and the predator moves with a larger step size, which can enhance the global search ability of the algorithm from the initial stage; in the middle of the iteration, the change of the step size of the predator is severe.Rapid decay can increase the possibility of predators searching for better areas; in the later stage of iteration, the change is relatively slow, which is beneficial for predators to keep a small step size and conduct earlier and more comprehensive searches in the newly searched area of merit.

Cauchy distribution
As a continuous probability distribution, the Cauchy distribution (Wang, 1976) can make the optimization algorithm have better global search ability (Gao et al., 2020;Qu & He, 2010).In this paper, the standard Cauchy transformation form is adopted: where atan is the arctangent and θ is a random number in the interval [0, 1].The standard Cauchy distribution probability density function and Brownian motion probability density function distribution curves are shown in Figure 3.The scatter plot of 1000 points is drawn in Figure 4, which are generated by the standard Cauchy distribution and Brownian motion (Hida, 1980) under the same conditions.It is recognized from Figure 3 that although the peak value of the standard Cauchy distribution at the origin is smaller than that of Brownian motion, the two sides are wider and thicker, have a wider distribution range, and obvious heavy tails.Taking advantage of the large proportion of unknown areas with heavy tails in the Cauchy distribution, the perturbation ability of the algorithm is increased, making the algorithm more likely to jump out of the local extreme value, so as to find the global optimal value.From Figure 4, we can find that when the algorithm is searching for local optimization, the Cauchy distribution can perform more comprehensive optimization in a smaller range than Brownian motion, which shows that the Cauchy distribution has better search performance in local search.To sum up, the Cauchy distribution has better abilities than Brownian motion, including high-precision local search and jumping out of the local optimum easily.

Symbolic dynamic entropy
Symbolic dynamic entropy (SDE) (Parlitz & Berg, 2012) is a kind of entropy that contains available information in a computing system.The larger the value, the more random and irregular the distribution of time series.The  smaller the SDE value, the more regular and periodic the distribution of the time series (Duarte et al., 2005;Hao, 1989).The calculation steps of SDE are mainly divided into five points: Point 1. Signal sequence symbolization (Monetti et al., 2009): Let the signal sequence S = s(i), i = 1, 2, . . ., N, where N is the number of sampling points.Transform the signal sequence X into the symbolic domain X = x(i), i = 1, 2, . . ., N. In the transformation process, it is quantized to between 0 and q−1, where q is the quantization level.When q = 2, the time is quantized to 0 or 1.The specific conversion method is expressed as follows: where signal sequence s i {s n }, symbol sequence x n = 0, 1, and r = 0.15 is the threshold.Point 2. The symbol sequence is truncated: After the sequence conversion, to understand the overall characteristics of the sequence, after a given sequence length L and time delay τ , the sequence is truncated (Zhang, 2004), and we get where k = 1, 2, . . ., N − (L − 1)τ , N is the data length of the original time series or the data number of the symbol sequence.Point 3. Decimal conversion: The conversion process (Jin & Li, 2004) is described as follows: where and q is the quantization level.
Point 4. The probability of each pattern appearing in the reconstructed symbol sequence: Count the number of times the decimal sequence appears in each state mode, and calculate the probability of its occurrence denoted as P(i): where num is the frequency of occurrence of each state pattern in the reconstructed symbol sequence.
Point 5. Calculate the information entropy of symbolic dynamics (Suo & Li, 2022;Yang et al., 2022): where n is the number of state modes.
Compared with sample entropy and permutation entropy, the SDE method has three main advantages: (1) SDE can better reflect the equivalence of amplitude information in time series; (2) SDE can better reflect the difference of amplitude information in time series and (3) SDE is better able to resist noise or fluctuation interference.

Improved MPA algorithm
The implementation steps of the improved MPA algorithm are as follows: Step 1. Input the original signal S, set the population number, iteration number and dimension of MPA and set the search range of VMD parameters.
Step 2. Use the method of good point set initialization to initialize the MPA population.
Step 3. Taking the position of the current predator as the parameter combination [K, α] in VMD, the fitness value of the decomposed mode is calculated.
Step 4. Use the improved CF and Cauchy distribution to optimize the optimization process in the iterative process, compare the fitness value, retain the optimal fitness value, and update the predator position.
Step 5. Repeat Step 3 to Step 4 until the maximum number of iterations is reached, the fitness value at this time is the global optimal fitness value, and the corresponding predator position is reserved as the optimal parameter combination [K, α] in VMD.Step 6. Select the effective components for reconstruction by calculating the SDE between the original signal and the probability density function of each IMF.
The flow chart is depicted in Figure 5.

Simulation experiment verification
To verify the superior performance of the algorithm discussed in this paper, five standard test functions (Alqattan & Abdullah, 2015;Dai & Zhan, 2005;Pei, 2017) are adopted to simulate the four optimization algorithms of MPA, GWO, PSO and IMPA in the experimental stage.f 1 − f 3 is a single-peak test function, which is used to test the development capability of the algorithm.f 4 is a multi-peak test function and f 5 is a fixed-dimensional test function, both of which are used to test the exploration ability of the algorithm.The specific test functions are as Table 1 interprets.
In the process of simulation test, the parameters of the four optimization algorithms are set uniformly as follows: the number of populations is 40 and the number of iterations is 500.Using five test functions, the four optimization algorithms are verified in the same dimension, in different search spaces or in different dimensions, and in the same search space.The verification results are shown in Table 2.
It is presented from Table 2 that in the three test functions of f 1 -f 3 , the mean and standard deviation of the optimal value of IMPA are the smallest.The mean value and standard deviation of the optimal IMPA value in f 4 and f 5 are still minimum, which proves the efficient exploration ability of the IMPA algorithm.It is indicated that for different standard test functions, in different dimensions and different search spaces, the development and exploration performance of the IMPA method is higher.

Actual data validation
The experimental data used in this paper come from the natural gas pipeline leakage detection simulation experimental platform of Northeast Petroleum University.The total length of the pipeline is 169 m, the diameter is 150 mm and the pressure range is 0-2 MPa.In this paper, the compressed air in the experimental platform is used to simulate the gas pipeline, the pressure is 0.5 MPa, the flow rate is 16 m/s and the leakage diameter is 16 mm (Liang, 2019).The waveform of the pipeline data taken is drawn in Figure 6.The data collected in the laboratory is input as a signal, and the pipeline data is denoised and analysed by the method developed in this paper.First, set the selection range of VMD parameters, namely K ∈ [2, 10] and α ∈ [200,4000].Then the method investigated in this paper is utilized to optimize the VMD parameters, and the optimization result is [8,1393].The optimization result is input into the VMD for signal decomposition, and the decomposition result is shown in Figure 7.As is observed from Figure 7, the pipeline data signal is divided into eight components, which are separated and sorted   in sequence according to the frequency.It is perceived from Figure 8 that the increment between IMF3 and IMF4 is the largest, so the first three components are effective components, and the last five components are noise components.The line chart is plotted in Figure 8 of dynamic entropy of pipeline signal.The spectrogram after reconstructing the effective components is shown in Figure 9, and from the comparison between the reconstructed signal and the original signal in Figure 10, it is revealed that the reconstructed signal can effectively remove the noise signal contained in the original signal.
It is observed from Table 3 that compared with several other optimization algorithms, the method presented in this paper has the superiority of higher signal-to-noise ratio (SNR), lower mean-square error (MSE) and mean absolute error (MAE).

Conclusion
In this paper, a multi-strategy improved MPA method has been proposed based on initialization of good point set and improvement of CF and Cauchy distribution, which overcomes the disadvantages of slow convergence speed and easy to fall into local optimum in the process of iterative optimization of MPA.A more accurate parameter combination has been found via the improved MPA to find VMD parameters, where it can well jump out of the local optimum, and quickly search the global optimum.The effective mode after VMD has been selected by    dynamic entropy, and then the effective mode has been reconstructed to get the denoised signal.It has been illustrated by the experimental results that the raised method achieves efficient signal denoising with higher SNR, lower MSE and MAE, and capability of distinguishing effective components and noise components more accurately.

Disclosure statement
No potential conflict of interest was reported by the author(s).

Figure 1 .
Figure 1.Scatter plot of good point set initialization and random initialization.

Figure 2 .
Figure 2. Iterative plots of improved CF and original CF.

Figure 3 .
Figure 3. Curves of standard Cauchy distribution probability density function and Brownian motion probability density function distribution.

Figure 4 .
Figure 4. Scatter plot of standard Cauchy distribution and Brownian motion distribution.

Figure 5 .
Figure 5. Flow chart of denoising of optimized VMD based on improved MPA.

Figure 8 .
Figure 8. Line chart of dynamic entropy of pipeline signal.

Figure 10 .
Figure 10.Original pipeline signal and reconstructed signal waveform.

Table 1 .
Five standard test functions.

Table 2 .
Test results of standard test function.

Table 3 .
Comparison of denoising effects of actual data.