Mileage-oriented pipeline stepped corrosion rate prediction method

By adopting a mileage-oriented method in the pipeline system, using the CART algorithm to build a regression tree model, divide the corrosion areas and predict the step corrosion rate, the problem of difficulty in accurately predicting the pipeline step corrosion rate in the prior art is solved, and accurate corrosion rate prediction and reduced the risk of over-maintenance.

CN119808578APending Publication Date: 2025-04-11CHINA SPECIAL EQUIP INSPECTION & RES INST +1
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202411976926.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-31
Publication Date
2025-04-11

AI Technical Summary

Technical Problem

The prior art is difficult to accurately predict the corrosion rate of pipeline ladders, which leads to the inability to effectively reflect the complexity and dynamics of the actual pipeline system, and is prone to excessive repairs.

Method used

Using a mileage-oriented method, corrosion data is obtained through online detection, and a regression tree model is constructed using the CART algorithm to divide the corrosion areas, and the ladder corrosion rate is predicted through the optimal probability distribution function.

Benefits of technology

Accurate prediction of pipeline step corrosion rate is achieved, reducing the occurrence of over-maintenance and improving the maintenance efficiency and safety of pipelines.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119808578A_ABST
    Figure CN119808578A_ABST
Patent Text Reader

Abstract

The invention discloses a mileage-oriented pipeline stepped corrosion rate prediction method, and relates to the technical field of pipeline data monitoring. According to the technical scheme, the method is characterized by comprising the following steps of S1, data preprocessing; s2, constructing a model; s3, mapping a mileage area by the leaf nodes; s4, obtaining an optimal probability distribution function of the region; and S5, predicting the corrosion rate of the pipeline in a stepped manner. The invention aims to provide a mileage-oriented pipeline stepped corrosion rate prediction method.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the technical field of pipeline data monitoring, and more specifically, to a mileage-oriented pipeline step corrosion rate prediction method. Background Art

[0002] Accurate prediction of pipeline corrosion rate is the key to maintaining pipeline safety, extending pipeline service life, and preventing potential leaks or accidents. Corrosion is a complex process that is affected by many factors, including but not limited to pipeline material, fluid composition, temperature, pressure, flow rate, and environmental conditions in which the pipeline is located. Traditional corrosion rate prediction methods are often based on test results in laboratory environments or rely on statistical analysis of historical data. However, these methods may not fully reflect the complexity and dynamics of actual pipeline systems, especially when facing step corrosion. Step corrosion may be caused by factors such as non-uniform distribution of fluid in the pipeline, specific flow patterns, or defects in pipeline design. Its prediction difficulty is more complicated than uniform corrosion. In the existing corrosion rate prediction methods, pipeline corrosion rate evaluation generally uses the maximum corrosion rate of the entire pipeline, the local corrosion rate, or the sum of the mean and standard deviation of the corrosion rate of the entire pipeline as the corrosion prediction rate of the pipeline.

[0003] In actual applications, the length of a pipeline can reach tens or hundreds of kilometers. Due to the different environments in which the pipeline is located (such as liquid accumulation, damage to the anti-corrosion layer, uncovered cathodic protection, corrosive ion concentration, etc.), the corrosion rates at different locations of the pipeline will be different. It is difficult to obtain the true corrosion rate of the pipeline in the existing technology. The use of a single corrosion prediction rate cannot accurately reflect the true corrosion development law of each part of the pipeline, which can easily lead to excessive maintenance of the pipeline.

[0004] Therefore, a new technical solution is urgently needed to solve the above technical problems. Summary of the invention

[0005] In view of the shortcomings of the prior art, the object of the present invention is to provide a mileage-oriented pipeline step corrosion rate prediction method.

[0006] The above technical objectives of the present invention are achieved through the following technical solutions: A mileage-oriented pipeline step corrosion rate prediction method, characterized in that it includes the following steps:

[0007] S1. Data preprocessing: Select a pipeline for multiple online inspections, take the latest two adjacent online inspection corrosion data as the original data, separate the mileage information and corrosion rate of the corrosion active point as the data to be used according to the characteristics of the original data; take the mileage information of the corrosion active point as the input variable X, and the corrosion rate as the output variable Y to obtain the initial data set A; sort the data set A according to the mileage size, so as to obtain the training data set B;

[0008] S2. Model construction: Use the CART algorithm to build a regression tree model with mileage as the input variable and corrosion rate as the output variable in data set B. After pre-pruning the pipeline according to the pipeline corrosion characteristics, build a preliminary tree model T0. Then, prune the bottom of the initial regression tree T0 until the root node of T0 to form a subtree sequence {T0, T1, ..., Tn}. Then, verify the subtree sequence through cross-validation, and select the subtree with the smallest cross-validation error as the optimal subtree;

[0009] S3, leaf node mapping mileage area: The relationship between the corrosion rate Y and the mileage data X in the final leaf node data set in the optimal regression tree model obtained by CART is mapped to the corresponding mileage, and the pipeline is divided into corrosion areas;

[0010] S4, regional optimal probability distribution function: perform probability distribution fitting and testing on the corrosion data in the leaf node data set to find the optimal probability distribution function;

[0011] S5. Prediction of pipeline step corrosion rate: Based on the optimal probability distribution function of each corrosion area, the 90% quantile is taken as the step corrosion rate of the area.

[0012] The present invention is further configured as follows: in the step S1, during the line detection process, based on the mileage information of the pipeline, the effective value is extracted according to the mileage, and the entire pipeline is divided into several sections according to the regression tree model, each section of the pipeline contains independent data, and adjacent sections do not affect each other.

[0013] The present invention is further configured as follows: the corrosion active point in step S1 refers to a corrosion point whose corrosion depth increases during two online detections. If the absolute value of the difference in corrosion depth between the two detections is greater than 10% of the normal wall thickness, the corrosion point is considered to be a corrosion active point;

[0014] The corrosion rate is: Where y is the corrosion rate, unit: mm / a; h1 is the corrosion depth at a certain mileage position during the previous online detection, unit: mm; h2 is the corrosion depth at the same position during the most recent online detection, unit: mm; t is the time interval between two detections, unit: a;

[0015] The data set A refers to the mileage information and corrosion rate of all corrosion active points as data set A = {(x1, y1), (x2, y2), ..., (xn, yn)};

[0016] The data set B refers to the subset of the data set A sorted from small to large according to the size of the mileage x, as data set B = {(x1, y1,), (x2, y2,), ..., (xn, yn,)}, where n is the sample size;

[0017] The input variable is X={x1, x2, ..., xn,}, and the output variable is Y={y1, y2, ..., yn,}.

[0018] The present invention is further configured as follows: in step S2, the mileage is used as the splitting point, the optimal splitting variable j and the splitting point s are selected, the jth eigenvector x(j) and its corresponding value s are selected to divide the input data set into two parts, and this operation is repeated continuously to traverse the entire data set. The optimal j and s are obtained by comparing the residuals of different partition intervals. The residual of an input data set partition is measured by the least squares of the true value and the calculated value of the partitioned data, that is, Among them, f(xi) is the calculated value of each partition interval, that is, In the data set, recursively divide each data set into two subsets and determine the output value on each subset to build a binary regression tree. The specific steps are as follows:

[0019] S1, select the optimal segmentation variable j and segmentation point s, and solve

[0020]

[0021] Traverse the variable j, scan the split point s for the fixed split variable j, and select (j, s) when the above formula M obtains the minimum value;

[0022] S2. Use (j, s) pairs to divide the region and calculate the output value, as shown in the following three equations;

[0023] R1(j,s)={x|x ( j ) ≤s}

[0024] R2(j,s)={x | x (j) >s},

[0025]

[0026] S3, recursively call steps ① and ② until the stopping condition is met (any subset mapping mileage is not less than 12m);

[0027] S4, divide the data set into M subsets R1, R2, R3...RM, and generate a regression tree;

[0028] S5, first prune the bottom of the initial regression tree T0 (if the leaf node mapping mileage area is less than 12m, it will be pruned) until the root node of T0, forming a subtree sequence {T0, T1, ..., Tn};

[0029] S6, when obtaining the output subset C in the final leaf node of each branch of the regression tree = {(y1, y2, y3…yi),

[0030] (yi,yi+1,yi+2…yi+j),…(yn-k-2,yn-k-1,yn-k…yn)};

[0031] S7, extract the root point D = (s1, s2, s3 ..., sk) of the previous level of each subset leaf node in C, and connect the pipeline according to

[0032] D. Regional division;

[0033] S8. Fit the subsets in C according to extreme value distribution, normal distribution, exponential function, and extreme value distribution to obtain the corresponding probability distribution function of each subset. The optimal probability distribution function of each subset is obtained through the KS test, and the 90% quantile of the distribution function is used as the step corrosion rate of the section. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] Figure 1 This is a pipeline step corrosion rate prediction flow chart of this embodiment;

[0035] Figure 2 Construct a flow chart for a single CART regression tree;

[0036] Figure 3 This is the final tree model diagram;

[0037] Figure 4 This is the final regression tree model diagram;

[0038] Figure 5 is the fitting distribution function curve;

[0039] Figure 6 It is the data fitting and KS test graph;

[0040] Figure 7 This is the pipeline step corrosion rate diagram. DETAILED DESCRIPTION

[0041] The present invention is further described in detail below in conjunction with the accompanying drawings.

[0042] The same parts are denoted by the same reference numerals. It should be noted that the words "front", "rear", "left", "right", "upper" and "lower" used in the following description refer to directions in the drawings, and the words "bottom" and "top", "inner" and "outer" refer to directions toward or away from the geometric center of a specific component, respectively.

[0043] like Figure 1 As shown, a mileage-oriented pipeline step corrosion rate prediction method includes the following steps:

[0044] S1. Data preprocessing: Select a pipeline for multiple online inspections, take the latest two adjacent online inspection corrosion data as the original data, separate the mileage information and corrosion rate of the corrosion active point as the data to be used according to the characteristics of the original data; take the mileage information of the corrosion active point as the input variable X, and the corrosion rate as the output variable Y to obtain the initial data set A; sort the data set A according to the mileage size, so as to obtain the training data set B;

[0045] S2. Model construction: Use the CART algorithm to build a regression tree model with mileage as the input variable and corrosion rate as the output variable in data set B. After pre-pruning the pipeline according to the pipeline corrosion characteristics, establish the preliminary tree model T0. Then, prune the bottom of the initial regression tree T0 until the root node of T0 to form a subtree sequence {T0, T1, ..., Tn}. Then, verify the subtree sequence through cross-validation method, and select the subtree with the smallest cross-validation error as the optimal subtree, such as Figure 2 As shown in the figure, it is the process of building a single regression tree. Each subset after the initial data division is split again according to this process until the pre-pruning termination condition is met.

[0046] S3, leaf node mapping mileage area: The relationship between the corrosion rate Y and the mileage data X in the final leaf node data set in the optimal regression tree model obtained by CART is mapped to the corresponding mileage, and the pipeline is divided into corrosion areas;

[0047] S4, Regional Optimal Probability Distribution Function: Perform probability distribution fitting and testing on the corrosion data in the leaf node data set to find the optimal probability distribution function, such as Figure 3 As shown in the figure, it is a curve of the cross-validation error and the number of leaf nodes of the embodiment. It can be seen from the figure that as the number of leaf nodes increases, the cross-validation error gradually decreases and approaches 0.09. When the number of leaf nodes is 35, the cross-validation error no longer decreases. Therefore, the termination condition is that the leaf node tree is 35. This condition is used as the termination condition to re-prune the pre-pruned regression tree to obtain the optimal regression tree model;

[0048] S5. Prediction of pipeline step corrosion rate: Based on the optimal probability distribution function of each corrosion area, the 90% quantile is taken as the step corrosion rate of the area.

[0049] In step S1, during the line detection process, based on the mileage information of the pipeline, the effective value is extracted according to the mileage, and the entire pipeline is divided into several sections according to the regression tree model. Each section of the pipeline contains independent data, and adjacent sections do not affect each other.

[0050] The corrosion active point in step S1 refers to a corrosion point whose corrosion depth increases during two online detections. If the absolute value of the difference in corrosion depth between the two detections is greater than 10% of the normal wall thickness, the corrosion point is considered to be a corrosion active point;

[0051] The corrosion rate is: Where y is the corrosion rate, unit: mm / a; h1 is the corrosion depth at a certain mileage position during the previous online detection, unit: mm; h2 is the corrosion depth at the same position during the most recent online detection, unit: mm; t is the time interval between two detections, unit: a;

[0052] The data set A refers to the mileage information and corrosion rate of all corrosion active points as data set A = {(x1, y1), (x2, y2), ..., (xn, yn)};

[0053] The data set B refers to the subset of the data set A sorted from small to large according to the size of the mileage x, as data set B = {(x1, y1,), (x2, y2,), ..., (xn, yn,)}, where n is the sample size;

[0054] The input variable is X={x1, x2, ..., xn,}, and the output variable is Y={y1, y2, ..., yn,}.

[0055] In step S2, the mileage is used as the split point, the optimal split variable j and split point s are selected, the jth eigenvector x(j) and its corresponding value s are selected to divide the input data set into two parts, and this operation is repeated continuously to traverse the entire data set. The optimal j and s are obtained by comparing the residuals of different partition intervals. The residual of an input data set partition is measured by the least squares of the true value and the calculated value of the partition data, that is, Among them, f(xi) is the calculated value of each partition interval, that is, In the data set, recursively divide each data set into two subsets and determine the output value on each subset to build a binary regression tree. The specific steps are as follows:

[0056] S1, select the optimal segmentation variable j and segmentation point s, and solve

[0057]

[0058] Traverse the variable j, scan the split point s for the fixed split variable j, and select (j, s) when the above formula M obtains the minimum value;

[0059] S2. Use (j, s) pairs to divide the region and calculate the output value, as shown in the following three equations;

[0060] R1(j,s)={x|x ( j) ≤s}

[0061] R2(j,s)={x | x (j) >s},

[0062]

[0063] S3, recursively call steps ① and ② until the stopping condition is met (any subset mapping mileage is not less than 12m);

[0064] S4, divide the data set into M subsets R1, R2, R3...RM, and generate a regression tree;

[0065] S5. First, continuously prune the bottom of the initial regression tree T0 (if the leaf node mapping mileage area is less than 12m, it will be pruned) until the root node of T0, forming a subtree sequence {T0, T1, ..., Tn}.

[0066] S6, when obtaining the output subset C in the final leaf node of each branch of the regression tree = {(y1, y2, y3…yi),

[0067] (yi,yi+1,yi+2…yi+j),…(yn-k-2,yn-k-1,yn-k…yn)};

[0068] S7, extract the root point D = (s1, s2, s3 ..., sk) of the previous level of each subset leaf node in C, and connect the pipeline according to

[0069] D. Regional division;

[0070] S8. Fit the subsets in C according to extreme value distribution, normal distribution, exponential function, and extreme value distribution to obtain the corresponding probability distribution function of each subset. The optimal probability distribution function of each subset is obtained through the KS test, and the 90% quantile of the distribution function is used as the step corrosion rate of the section.

[0071] like Figure 4 As shown in FIG. 1 , it is the final regression tree model diagram. The regression tree divides the pipeline into multiple leaf nodes. The root node corresponding to each leaf node divides the pipeline into multiple pipeline regions.

[0072] like Figure 5 As shown, the distribution function curve of the pipeline area corrosion data fitting is mapped in the embodiment. The function simulation analysis is constructed according to the parameters obtained above. It can be seen from the figure that the fitting distribution function curve is close to the detection data and can basically accurately represent the corrosion law of the pipeline.

[0073] like Figure 6As shown, the data fitting cumulative distribution function and KS test curve of the embodiment are compared with the normal distribution, logarithmic distribution, generalized extreme value distribution, and exponential distribution curves obtained by simulation analysis and the test data fitting function. The fitting distribution function with the smallest K value is used as the optimal distribution function of the subset through analysis, and then the 90% quantile is used as the step corrosion rate of the pipeline interval.

[0074] like Figure 7 As shown, it is a mileage-oriented pipeline step corrosion rate distribution diagram of the embodiment. It can be clearly seen from the figure that the pipeline root mileage and rate are divided into several sections, and accurate evaluation can be performed on different pipe sections according to the step corrosion rate, so as to carry out accurate repairs, achieve the purpose of reducing costs and increasing efficiency, and avoid excessive maintenance.

[0075] The specific embodiments are merely explanations of the present invention and are not limitations of the present invention. After reading this specification, those skilled in the art may make modifications to the embodiments without any creative contribution as needed. However, such modifications are protected by the patent law as long as they are within the scope of the claims of the present invention.

Claims

1. A mileage-oriented pipeline step corrosion rate prediction method, characterized by: The steps include: S1. Data preprocessing: Select a pipeline for multiple online inspections, take the latest two adjacent online inspection corrosion data as the original data, separate the mileage information and corrosion rate of the corrosion active point as the data to be used according to the characteristics of the original data; take the mileage information of the corrosion active point as the input variable X, and the corrosion rate as the output variable Y to obtain the initial data set A; sort the data set A according to the mileage size, so as to obtain the training data set B; S2. Model construction: Use the CART algorithm to build a regression tree model with mileage as the input variable and corrosion rate as the output variable in data set B. After pre-pruning the pipeline according to the pipeline corrosion characteristics, build a preliminary tree model T0. Then, prune the bottom of the initial regression tree T0 until the root node of T0 to form a subtree sequence {T0, T1, ..., Tn}. Then, verify the subtree sequence through cross-validation, and select the subtree with the smallest cross-validation error as the optimal subtree; S3, leaf node mapping mileage area: The relationship between the corrosion rate Y and the mileage data X in the final leaf node data set in the optimal regression tree model obtained by CART is mapped to the corresponding mileage, and the pipeline is divided into corrosion areas; S4, regional optimal probability distribution function: perform probability distribution fitting and testing on the corrosion data in the leaf node data set to find the optimal probability distribution function; S5. Prediction of pipeline step corrosion rate: Based on the optimal probability distribution function of each corrosion area, the 90% quantile is taken as the step corrosion rate of the area.

2. A mileage-oriented pipeline step corrosion rate prediction method according to claim 1, characterized in that: In the step S1, during the line detection process, based on the mileage information of the pipeline, the effective value is extracted according to Li Chen, and the entire pipeline is divided into several sections according to the regression tree model. Each section of the pipeline contains independent data, and adjacent sections do not affect each other.

3. The mileage-oriented pipeline step corrosion rate prediction method according to claim 1 is characterized by: The corrosion active point in step S1 refers to a corrosion point whose corrosion depth increases during two online detections. If the absolute value of the difference in corrosion depth between the two detections is greater than 10% of the normal wall thickness, the corrosion point is considered to be a corrosion active point; The corrosion rate is: Where y is the corrosion rate, unit: mm / a; h1 is the corrosion depth at a certain mileage position during the previous online inspection, unit: mm; h2 is the corrosion depth at the same position during the most recent online inspection, unit: mm; t is the time interval between two inspections, unit: a; The data set A refers to the mileage information and corrosion rate of all corrosion active points as data set A = {(x1, y1), (x2, y2), ..., (xn, yn)}; The data set B refers to the subset of the data set A sorted from small to large according to the size of the mileage x, as data set B = {(x1, y1,), (x2, y2,), ..., (xn, yn,)}, where n is the sample size; The input variable is X={x1, x2, ..., xn}, and the output variable is Y={y1, y2, ..., yn}.

4. The mileage-oriented pipeline step corrosion rate prediction method according to claim 1 is characterized by: In step S2, the mileage is used as the split point, the optimal split variable j and split point s are selected, the jth eigenvector x(j) and its corresponding value s are selected to divide the input data set into two parts, and this operation is repeated continuously to traverse the entire data set. The optimal j and s are obtained by comparing the residuals of different partition intervals. The residual of an input data set partition is measured by the least squares of the true value and the calculated value of the partition data, that is, Among them, f(xi) is the calculated value of each partition interval, that is, In the data set, recursively divide each data set into two subsets and determine the output value on each subset to build a binary regression tree. The specific steps are as follows: S1, select the optimal segmentation variable j and segmentation point s, and solve Traverse the variable j, scan the split point s for the fixed split variable j, and select (j, s) when the above formula M obtains the minimum value; S2. Use (j, s) pairs to divide the region and calculate the output value, as shown in the following three equations; R1(j,s)={x|x ( j ) ≤s} R2(j,s)={x | x (j) >s}, S3, recursively call steps ① and ② until the stopping condition is met (any subset mapping mileage is not less than 12m); S4, divide the data set into M subsets R1, R2, R3...RM, and generate a regression tree; S5, first prune the bottom of the initial regression tree T0 (if the leaf node mapping mileage area is less than 12m, it will be pruned) until the root node of T0, forming a subtree sequence {T0, T1, ..., Tn}; S6. Obtain the output subset C in the final leaf node of each branch when the regression tree is obtained = {(y1, y2, y3…yi), (yi, yi+1, yi+2…yi+j),…(yn-k-2, yn-k-1, yn-k…yn)}; S7, extract the root point D = (s1, s2, s3 ..., sk) of the previous level of each subset leaf node in C, and divide the pipeline into regions according to D; S8. Fit the subsets in C according to extreme value distribution, normal distribution, exponential function, and extreme value distribution to obtain the corresponding probability distribution function of each subset. The optimal probability distribution function of each subset is obtained through the KS test, and the 90% quantile of the distribution function is used as the step corrosion rate of the section.

Citation Information

Patent Citations

  • Method for predicting corrosion rate of submarine crude oil pipeline based on PCA-ABC-SVM model

    CN113268883A

  • Public pipe gallery pipeline corrosion residual life evaluation method and system

    CN113626970A

  • Prediction model for external corrosion residual life of buried pipeline

    CN116757091A

  • Method and system for predicting corrosion rate of galvanized steel of power grid

    CN117133391A