Methods, apparatus, storage media, and computer equipment for calculating the ellipticity of pipelines.

By removing outliers from pipeline deformation detection data and employing an ellipse fitting method, the problem of inaccurate ellipticity calculation caused by noise interference in traditional methods was solved, achieving more accurate pipeline ellipticity calculation.

CN121256189BActive Publication Date: 2026-06-30NORTHEASTERN UNIV CHINA

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
NORTHEASTERN UNIV CHINA
Filing Date
2025-08-13
Publication Date
2026-06-30

AI Technical Summary

Technical Problem

Traditional methods for calculating pipe ellipticity cannot effectively avoid noise interference, resulting in inaccurate calculation results. It is impossible to determine whether the calculated longest and shortest axes are the actual maximum and minimum values ​​of the ellipse.

Method used

By removing outliers from the deformation detection data, discriminant values ​​are calculated using the median and standard deviation. Outlier sampling points are then deleted based on these discriminant values. Finally, the ellipticity of the pipeline is calculated using ellipse fitting, and the elliptic coefficients are solved using the Lagrangian function and the generalized eigenvalue problem.

Benefits of technology

It effectively eliminates interference from noise and abnormal data, improves the removal of outliers in pipeline radius data, ensures the accuracy and precision of ellipticity calculation, and avoids errors caused by center point offset.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121256189B_ABST
    Figure CN121256189B_ABST
Patent Text Reader

Abstract

This application discloses a method, apparatus, storage medium, and computer device for calculating the ellipticity of a pipeline. The method includes: acquiring multiple cross-sectional sampling points of the pipeline in a preset planar coordinate system; calculating a discriminant value for each cross-sectional sampling point based on the median and standard deviation of the multiple sampling points; deleting cross-sectional sampling points with discriminant values ​​greater than the standard value from the multiple sampling points to obtain target sampling points; performing ellipse fitting on the target sampling points to calculate the elliptic coefficient of the pipeline's cross-sectional ellipse; and calculating the ellipticity of the pipeline based on the elliptic coefficient. This method effectively eliminates the problem of outliers affecting the judgment criteria during the inner diameter data filtering process, improves the removal effect of outliers in the pipeline radius data, avoids interference from outliers on subsequent ellipse fitting, and can calculate an ellipticity closer to the actual result even if the detector's sampling center point is offset relative to the center point of the pipeline ellipse.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of pipeline measurement technology, and in particular to a method, apparatus, storage medium, and computer equipment for calculating the ellipticity of a pipeline. Background Technology

[0002] In the process of detecting pipeline geometric deformation, calculating the ellipticity of the pipeline is one of the key tasks. During the manufacturing, transportation, and long-term use of long-distance oil and gas pipelines, accidental impacts may occur, leading to localized deformation. Once local buckling forms, it will propagate along the pipeline's axial direction, severely impacting subsequent normal transportation. In some cases, the pipeline may even experience localized buckling instability, causing significant economic losses and natural disasters.

[0003] The traditional method for calculating ellipticity is to directly select the extreme value from the deformation detection data as the extreme value of the pipe cross-section radius, and then use the data collected by the detection arm corresponding to the extreme value with a circumferential difference of 180° as the other radius of the same extreme value. The sum of the two is the extreme value diameter. Finally, the maximum and minimum diameters of the pipe cross-section obtained by the above method are substituted into the ellipticity calculation formula to obtain the ellipticity of the pipe cross-section, that is:

[0004]

[0005] However, the detector inside the pipeline is subject to disturbances during data collection within the subsea pipeline. Traditional methods cannot avoid noise interference, which may lead to incorrect judgments of pipeline elliptic deformation. Furthermore, directly substituting the maximum and minimum radius values ​​from the deformation data into the ellipticity formula for calculation cannot determine whether the calculated longest and shortest axes are the actual maximum and minimum values ​​of the ellipse, thus affecting the accuracy of ellipticity calculation. Summary of the Invention

[0006] In view of this, this application provides a method, apparatus, storage medium and computer equipment for calculating the ellipticity of a pipeline, which avoids the interference of abnormal points on the ellipticity calculation results by eliminating abnormal points in the deformation detection data.

[0007] According to one aspect of this application, a method for calculating the ellipticity of a pipeline is provided, comprising:

[0008] Obtain multiple cross-sectional sampling points of the pipeline in a preset planar coordinate system;

[0009] Based on the median and standard deviation of multiple cross-sectional sampling points, the discriminant value of the cross-sectional sampling points is calculated;

[0010] Target sampling points are obtained by deleting cross-sectional sampling points with discriminant values ​​greater than standard values ​​from a plurality of cross-sectional sampling points, wherein the standard value is determined based on the number of the plurality of cross-sectional sampling points and the significance coefficient;

[0011] Ellipse fitting is performed on the target sampling points to calculate the ellipse coefficient of the cross-sectional ellipse of the pipeline;

[0012] The ellipticity of the pipeline is calculated based on the elliptic coefficient.

[0013] Optionally, a deformation detector is installed inside the pipe, and the acquisition of multiple cross-sectional sampling points of the pipe in a preset planar coordinate system includes:

[0014] Based on the physical signals of the detection arm collected by the sensor of the deformation detector, the change angle between the detection arm and the horizontal direction is calculated;

[0015] Calculate the inner diameter of the pipe section corresponding to the detection arm based on the changed angle;

[0016] Based on the inner diameter of the pipe cross-section, the sampling points of the detection arm are projected onto the preset plane coordinate system to obtain the cross-section sampling points.

[0017] Optionally, calculating the pipe cross-sectional inner diameter corresponding to the detection arm based on the changed angle includes:

[0018] Based on the changing angle and the length of the detection arm, calculate the offset height of the detection arm projected into the vertical direction;

[0019] The inner diameter of the pipe section is determined by summing the offset height, the radius of the main body of the deformation detector, the radius of the detection probe on the detection arm, and the height of the support structure of the detection arm.

[0020] Optionally, the step of performing ellipse fitting on the target sampling points and calculating the ellipse coefficients of the cross-sectional ellipse of the pipe includes:

[0021] Construct a quadratic curve equation for the target sampling points, and add equality constraints to the quadratic curve equation, wherein the equality constraints are used to indicate that the curve is an ellipse;

[0022] With the goal of minimizing the sum of squared distances from the target sampling point to the specified ellipse, a Lagrange function is established based on the quadratic curve equation;

[0023] Taking the partial derivative of the Lagrange function and setting it to zero yields the generalized eigenvalue problem;

[0024] The elliptic coefficients are obtained by solving the generalized eigenvalue problem;

[0025] The equation of the quadratic curve is expressed as: F(x,y)=ax 2 +bxy+cy 2 +dx+ey+f=0;

[0026] The equality constraint condition is expressed as: 4ac-2b 2 =1;

[0027] The Lagrange function is expressed as:

[0028] The generalized eigenvalue problem is expressed as:

[0029] In the formula, x and y represent the coordinates of the target sampling point, F(x,y) represents the distance from the target sampling point to the specified ellipse, and a, b, c, d, e, and f represent the ellipse coefficients. Let λ represent the elliptic coefficient vector, D represent the data matrix of the target sampling points, C represent the constraint matrix under the equality constraint condition, and the constraint matrix is ​​a singular matrix, and λ represents the Lagrange multiplier.

[0030] Optionally, the step of solving the generalized eigenvalue problem to obtain the elliptic coefficients includes:

[0031] Construct a scatter matrix based on the multinomial sum of the data matrix;

[0032] The elliptic coefficient vector, the scatter matrix, and the constraint matrix in the generalized eigenvalue problem are decomposed to obtain the decomposed eigenvalue problem;

[0033] The elliptic coefficients are obtained by solving the eigenvalue decomposition problem.

[0034] The scatter matrix is ​​represented as S = D T D;

[0035] The eigenvalue decomposition problem is expressed as:

[0036] In the formula, S represents the scatter matrix, and S1, S2, and S3 represent the decomposed scatter matrices. C1 represents the decomposed elliptic coefficient vector, and C2 represents the decomposed constraint matrix.

[0037] Optionally, calculating the ellipticity of the pipe based on the elliptic coefficient includes:

[0038] The minor axis length and major axis length of the fitted ellipse of the pipeline are calculated based on the elliptic coefficients.

[0039] Calculate the difference between the minor axis length and the major axis length;

[0040] Calculate the quotient of the difference and the length of the major axis to determine the ellipticity;

[0041] The formulas for calculating the lengths of the minor and major axes are expressed as follows:

[0042]

[0043] In the formula, l min Indicates the length of the minor axis, l max The major axis length is represented by , and a, b, c, d, e, and f represent the elliptic coefficients.

[0044] Optionally, the deformation detector includes:

[0045] The main body is equipped with a sensor, which is used to collect physical signals from the detection arm;

[0046] Multiple detection arms are provided. One end of each detection arm is connected to the main body via a support structure, and the other end of each detection arm is rotatably connected to a detection probe. The detection arms are evenly distributed along the circumference of the main body and form a double-layer distribution structure along the axial direction of the main body. The detection arms located in different layers are staggered along the circumference of the main body. The end of the detection probe is arc-shaped.

[0047] According to another aspect of this application, a device for calculating the ellipticity of a pipeline is provided, comprising:

[0048] The measurement module is used to acquire multiple cross-sectional sampling points of the pipeline in a preset plane coordinate system;

[0049] A filtering module is configured to calculate a discriminant value for a cross-sectional sampling point based on the median and standard deviation of the multiple cross-sectional sampling points; and to delete cross-sectional sampling points with discriminant values ​​greater than a standard value from the multiple cross-sectional sampling points to obtain a target sampling point, wherein the standard value is determined based on the number of the multiple cross-sectional sampling points and the significance coefficient.

[0050] The fitting module is used to perform ellipse fitting on the target sampling points and calculate the ellipse coefficient of the cross-sectional ellipse of the pipeline.

[0051] An ellipticity calculation module is used to calculate the ellipticity of the pipeline based on the ellipticity coefficient.

[0052] Optionally, the measurement module is specifically used to calculate the change angle between the detection arm and the horizontal direction based on the physical signal of the detection arm collected by the sensor of the deformation detector; calculate the inner diameter of the pipe section corresponding to the detection arm based on the change angle; and project the sampling point of the detection arm onto the preset plane coordinate system based on the inner diameter of the pipe section to obtain the cross-sectional sampling point.

[0053] Optionally, the measurement module is specifically used to calculate the offset height of the detection arm projected into the vertical direction based on the changing angle and the length of the detection arm; and to calculate the sum of the offset height, the radius of the main body of the deformation detector, the radius of the detection probe on the detection arm, and the height of the support structure of the detection arm to determine the inner diameter of the pipe section.

[0054] Optionally, the fitting module is specifically used to construct the quadratic curve equation of the target sampling point and add equality constraints to the quadratic curve equation, wherein the equality constraints are used to indicate that the curve is an ellipse; with the objective of minimizing the sum of squared distances from the target sampling point to the specified ellipse, a Lagrange function is established based on the quadratic curve equation; the partial derivatives of the Lagrange function are calculated and set to zero to obtain the generalized eigenvalue problem; and the ellipse coefficients are obtained by solving the generalized eigenvalue problem.

[0055] The equation of the quadratic curve is expressed as: F(x,y)=ax 2 +bxy+cy 2 +dx+ey+f=0;

[0056] The equality constraint condition is expressed as: 4ac-2b 2 =1;

[0057] The Lagrange function is expressed as:

[0058] The generalized eigenvalue problem is expressed as:

[0059] In the formula, x and y represent the coordinates of the target sampling point, F(x,y) represents the distance from the target sampling point to the specified ellipse, and a, b, c, d, e, and f represent the ellipse coefficients. Let λ represent the elliptic coefficient vector, D represent the data matrix of the target sampling points, C represent the constraint matrix under the equality constraint condition, and the constraint matrix is ​​a singular matrix, and λ represents the Lagrange multiplier.

[0060] Optionally, the fitting module is specifically used to construct a scatter matrix based on the multinomial sum of the data matrix; decompose the elliptic coefficient vector, the scatter matrix, and the constraint matrix in the generalized eigenvalue problem to obtain a decomposed eigenvalue problem; and solve the decomposed eigenvalue problem to obtain the elliptic coefficients.

[0061] The scatter matrix is ​​represented as S = D T D;

[0062] The eigenvalue decomposition problem is expressed as:

[0063] In the formula, S represents the scatter matrix, and S1, S2, and S3 represent the decomposed scatter matrices. C1 represents the decomposed elliptic coefficient vector, and C2 represents the decomposed constraint matrix.

[0064] Optionally, the ellipticity calculation module is specifically used to calculate the minor axis length and major axis length of the fitted ellipse of the pipeline based on the ellipticity coefficient; calculate the difference between the minor axis length and the major axis length; calculate the quotient of the difference and the major axis length to determine the ellipticity;

[0065] The formulas for calculating the lengths of the minor and major axes are expressed as follows:

[0066]

[0067] In the formula, l min Indicates the length of the minor axis, l max The major axis length is represented by , and a, b, c, d, e, and f represent the elliptic coefficients.

[0068] According to another aspect of this application, a readable storage medium is provided that stores a program or instructions thereon, which, when executed by a processor, implement the steps of the above-described method for calculating the ellipticity of a pipeline.

[0069] According to another aspect of this application, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the above-described pipeline ellipticity calculation method.

[0070] By employing the above technical solution, the median is used to calculate the discriminant value, and outlier sampling points are removed based on this discriminant value. This reduces noise and outlier data while making outlier identification more consistent with the distribution characteristics of the sampled data. It effectively eliminates the problem of outliers skewing the judgment criteria during the inner diameter data filtering process, improves the removal of outliers from pipe radius data, and avoids interference from outliers on subsequent ellipse fitting. Even if the detector's center point is offset relative to the center point of the pipe ellipse during sampling, it can still calculate an ellipticity closer to the actual result.

[0071] The above description is only an overview of the technical solution of this application. In order to better understand the technical means of this application and to implement it in accordance with the contents of the specification, and to make the above and other objects, features and advantages of this application more obvious and understandable, the following are specific embodiments of this application. Attached Figure Description

[0072] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:

[0073] Figure 1 A flowchart illustrating the pipe ellipticity calculation method provided in an embodiment of this application is shown.

[0074] Figure 2 A schematic diagram of the detection arm structure provided in an embodiment of this application is shown;

[0075] Figure 3 A schematic diagram illustrating the calculation of the inner diameter of a pipe section provided in an embodiment of this application is shown;

[0076] Figure 4 A schematic diagram of the cross-sectional sampling points provided in an embodiment of this application is shown;

[0077] Figure 5 A structural block diagram of the pipe ellipticity calculation device provided in an embodiment of this application is shown;

[0078] Figure 6 A schematic diagram of the electronic structure of a computer device provided in an embodiment of this application is shown. Detailed Implementation

[0079] The present application will be described in detail below with reference to the accompanying drawings and embodiments. It should be noted that, unless otherwise specified, the embodiments and features described in the embodiments of the present application can be combined with each other.

[0080] The embodiments of this application are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain this application, and should not be construed as limiting this application.

[0081] Those skilled in the art will understand that, unless specifically stated otherwise, the singular forms “a,” “an,” “the,” and “the” used herein may also include the plural forms. It should be further understood that the term “comprising” as used in this application means the presence of the stated features, integers, steps, operations, elements, and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof. It should be understood that when we say an element is “connected” or “attached” to another element, it can be directly connected or attached to the other element, or there may be intermediate elements. Furthermore, “connected” or “attached” as used herein can include wireless connections or wireless interconnections. The term “and / or” as used herein includes all or any unit and all combinations of one or more associated listed items.

[0082] Exemplary embodiments according to this application will now be described in more detail with reference to the accompanying drawings. However, these exemplary embodiments may be implemented in many different forms and should not be construed as being limited to the embodiments set forth herein. It should be understood that these embodiments are provided so that the disclosure of this application is thorough and complete, and that the concept of these exemplary embodiments is fully conveyed to those skilled in the art.

[0083] This embodiment provides a method for calculating the ellipticity of a pipe, such as... Figure 1 As shown, the method includes:

[0084] Step 101: Obtain multiple cross-sectional sampling points of the pipeline in a preset planar coordinate system.

[0085] The cross-sectional sampling points can be detected by deformation detectors deployed inside the pipeline. Specifically, the deformation detector includes a main body and multiple detection arms. A sensor is installed in the main body to sense the physical signals generated by the displacement of the detection arms. These physical signals can be strain signals, voltage signals, etc., depending on the sensor type. For ease of pipeline inner diameter measurement, the main body can adopt a disc structure. One end of each detection arm is connected to the main body via a support structure. Multiple detection arms are evenly distributed along the circumference of the main body to ensure consistent deformation detection in all directions. When the pipeline deforms (e.g., bending, compression), the detection arms are compressed, resulting in corresponding mechanical displacement or rotation. A detection probe is installed on each detection arm; this probe is at least partially arc-shaped to reduce impact on the detection arm during displacement.

[0086] It is worth mentioning that, such as Figure 2 As shown, multiple detection arms 202 form a double-layer distribution structure along the axial direction of the main body 201, with the detection arms 202 in different layers staggered along the circumference of the main body 201. This double-layer distribution structure helps reduce detection blind spots and improves overall detection accuracy. Simultaneously, the staggered arrangement can also, to some extent, offset errors caused by external factors such as ambient temperature and vibration, improving measurement stability and reliability. Viewed from the detector's emission direction, even-numbered sensors (i.e., variations 2, 4, 6, ..., 36) are arranged in front, and odd-numbered sensors (i.e., variations 1, 3, 5, ..., 35) are arranged behind. Furthermore, the spacing between the front and rear layers of detection arms can be determined based on the actual application scenario and measurement requirements.

[0087] In practical applications, step 101, which involves obtaining multiple cross-sectional sampling points of the pipeline in a preset planar coordinate system, specifically includes the following steps:

[0088] Step 101-1: Calculate the change angle between the detection arm and the horizontal direction based on the physical signal of the detection arm collected by the sensor of the deformation detector.

[0089] Step 101-2: Calculate the inner diameter of the pipe section corresponding to the changing angle of the detection arm.

[0090] Specifically, step 101-2 includes: calculating the offset height of the detection arm projected onto the vertical direction based on the changing angle and the length of the detection arm; calculating the sum of the offset height, the radius of the main body of the deformation detector, the radius of the detection probe on the detection arm, and the height of the support structure of the detection arm to determine the inner diameter of the pipe section.

[0091] Step 101-3: Based on the inner diameter of the pipe cross section, project the sampling points of the detection arm onto the preset plane coordinate system to obtain the cross section sampling points.

[0092] The preset planar coordinate system can be a two-dimensional coordinate system with the center of the pipe section as the origin.

[0093] In this embodiment, the physical signal is accurately converted into the changing angle between the detection arm and the horizontal direction through the mapping relationship between the physical signal and the angle. This changing angle reflects the physical deformation of the detection arm and can be converted into the inner diameter of the pipe cross-section using trigonometric functions. By projecting the sampling points of each detection arm onto a preset plane coordinate system, the scattered inner diameter data can be transformed into an ordered set of coordinate points, eliminating positional deviations between different detection arms. Especially when a deformation detector with a double-layer distributed structure is used, it ensures the consistency and comparability of the cross-sectional contour data.

[0094] For specific examples, such as Figure 3 As shown, the sensor directly connected to the detection arm is an angle sensor. The angle of change of the detection arm is collected by the angle sensor, and then calculated using the following formula. Initial data such as the length of the detection arm and the height of the supporting structure are necessary prerequisites. The formula for calculating the inner diameter of the pipe section using deformation detection data is:

[0095]

[0096] H = l p ×sinα;

[0097] R = R0 + H s +R1+H;

[0098] In the formula, V represents the voltage signal acquired by the deformation detector, V0 represents the initial voltage of the detector, and V gain The voltage gain being detected is represented by α, which represents the angle (variable angle) between the direction of the detection arm and the horizontal direction. p H represents the length of the detection arm, H represents the height of the detection arm projected into the vertical direction (offset height), and R0 represents the radius of the internal body of the detector. s R represents the height of the supporting structure, R1 represents the radius of the detection probe, and R represents the calculated inner diameter of the pipe cross-section.

[0099] To perform refined fitting of the pipe data to its inner diameter, further calculations of the pipe inner diameter data are required. Currently, the known data are the inner diameter data of the pipe cross-section and the angular information between each inner diameter. To eliminate positional deviations between different detection arms, these pipe cross-section inner diameter data need to be further converted into coordinate points on a planar coordinate system.

[0100] Suppose that the number of detection arms arranged in a circumferential ring around the detector is n, and the detection arms are evenly distributed, with the circumferential angle between adjacent detection arms being 360 / n. For example... Figure 4 As shown, let the radial direction of the first sensor be the positive y-axis of the planar coordinate system. The other detection arms are arranged sequentially in a clockwise direction with equal spacing. The inner diameter data corresponding to the sensor on each detection arm will be projected onto this planar coordinate system. The formula for projecting the inner diameter onto the coordinate point is:

[0101]

[0102] x i =R i ×sinα;

[0103] y i =R i ×cosα;

[0104] In the formula, i represents the i-th sensor arranged in a clockwise circumferential direction, and θ i R represents the angle between the calculated inner diameter of the i-th pipe section and the positive y-axis. i Let x represent the inner diameter of the i-th pipe section. i y i This represents the projected coordinates (cross-sectional sampling point) of the sampling point corresponding to the i-th inner diameter.

[0105] Step 102: Calculate the discriminant value of the cross-sectional sampling points based on the median and standard deviation of multiple cross-sectional sampling points.

[0106] Step 103: Delete the cross-sectional sampling points with discriminant values ​​greater than the standard value from multiple cross-sectional sampling points to obtain the target sampling points.

[0107] The standard value is determined based on the number of sampling points across multiple cross sections and the significance coefficient.

[0108] In this embodiment, the data collected by the pipe deformation detector is not entirely feasible; outliers may exist. Outliers, or sampling points where the radius changes abruptly, may be due to detector malfunctions or abnormal bulges or depressions in the pipe. If all deformation detection data are directly incorporated into the pipe diameter fitting, the resulting ellipse may deviate from the overall shape shown by most of the data due to the influence of these data weights. Therefore, this embodiment proposes to verify whether the deformation detection data of the sampling points conforms to a normal distribution to improve the accuracy of the pipe diameter fitting. Specifically, the median is used instead of the average to calculate the discriminant value, and outlier sampling points are deleted based on the discriminant value. This reduces noise and outlier data while making the outlier judgment more consistent with the distribution characteristics of the sampling data. This effectively eliminates the problem of outliers skewing the judgment criteria during the inner diameter data filtering process, improves the removal effect of outliers in the pipe radius data, avoids interference from outliers on subsequent ellipse fitting, and even if the detector's center point is offset relative to the center point of the pipe ellipse during sampling, an ellipticity closer to the actual result can still be calculated.

[0109] For a specific example, when removing outliers from data at a certain sampling point, first arrange the radii of the cross-sectional sampling points in ascending order, and calculate the median value R. g And the standard deviation s. Then, substitute the radius data into the discriminant formula to determine whether the value is outlier. When the absolute value of the residual error (discriminant value) of a certain cross-sectional sampling point is greater than the standard value, the cross-sectional sampling point is considered to have a large error and its coordinates should be removed; otherwise, it is retained. The formulas for calculating the standard deviation and discriminant value are as follows:

[0110]

[0111] |v i |=λ(n,α)σ;

[0112] In the formula, v i λ(n,β)σ represents the residual error (discriminant value) of the cross-sectional sampling points, and λ(n,β)σ represents the standard value, as shown in Table 1. This standard value can be obtained by matching the number of repeated measurements n and the detection level β. β can be reasonably set according to the screening confidence probability of outliers. The confidence probability P=(1-β) is larger and the screening requirements are more stringent.

[0113] Table 1

[0114]

[0115] Step 104: Perform ellipse fitting on the target sampling points and calculate the ellipse coefficient of the pipe cross-section ellipse.

[0116] In this embodiment, ellipse fitting can completely describe the geometric features of the cross-sectional profile, avoiding local deviations caused by measuring only a few points (such as the diameter of a single point), and ensuring the objectivity and quantification accuracy of ellipticity calculation.

[0117] In practical applications, step 104, which involves ellipse fitting of the target sampling points and calculation of the ellipse coefficient of the pipe's cross-sectional ellipse, specifically includes the following steps:

[0118] Step 104-1: Construct the quadratic curve equation for the target sampling points and add equality constraints to the quadratic curve equation.

[0119] The equation of the quadratic curve is expressed as: F(x,y)=ax 2 +bxy+cy 2 +dx+ey+f=0. The equality constraint is used to indicate that the curve is an ellipse. The equality constraint can be expressed as: 4ac-2b 2 =1.

[0120] In this embodiment, the conventional inequality constraints of the quadratic curve equation are transformed into equality constraints. Introducing equality constraints makes the fitting results more closely match the actual deformation parameters, ensuring the uniqueness of the elliptical solution and preventing the results from becoming arbitrary conic curves such as hyperbolas or parabolas, thus ensuring that the results are consistent with the actual physical shape of the pipe cross-section deformation.

[0121] Step 104-2: With the goal of minimizing the sum of squared distances from the target sampling point to the specified ellipse, establish the Lagrangian function based on the quadratic curve equation.

[0122] Step 104-3: Take the partial derivative of the Lagrange function and set it to zero to obtain the generalized eigenvalue problem.

[0123] Specifically, the Lagrange function is expressed as: The generalized eigenvalue problem is represented as:

[0124] In the formula, x and y represent the coordinates of the target sampling point, F(x,y) represents the distance from the target sampling point to the specified ellipse, and a, b, c, d, e, and f represent the ellipse coefficients. Represents the vector of elliptic coefficients, i.e. D represents the data matrix of the target sampling points, C represents the constraint matrix under the equality constraint condition, and the constraint matrix is ​​a singular matrix, and λ represents the Lagrange multiplier.

[0125] For a specific example, an ellipse is a special case of a general quadratic curve, and its general equation is F(x,y)=ax. 2 +bxy+cy 2 +dx+ey+f=0. Additionally, the ellipse must satisfy the constraint: b2 -4ac < 1.

[0126] By introducing vectors: The polynomial of a general conic section can be rewritten in vector form:

[0127] The quadratic curve sampling points (x) i ,y i The fit of the quadratic curve (i = 1…N) can be approximated by finding the minimum value of the sum of squared distances from the cross-sectional sampling points to the quadratic curve. This sum of squared distances from the cross-sectional sampling points to the quadratic curve is represented by the coefficient ε as follows:

[0128]

[0129] The above equation can be solved directly using the least squares method, but the fitted result is a regular conic section rather than an ellipse. To ensure the uniqueness of the elliptical solution, the elliptical constraint formula must be considered, making such a system difficult to solve. At a suitable scale, the elliptical inequality constraints can be transformed into equality constraints: 4ac-2b 2 =1.

[0130] The special fitting problem of ellipse can be reformulated as:

[0131]

[0132]

[0133] Wherein, the data matrix D of the target sampling points is an N×6 matrix, and the constraint matrix C is a 6×6 matrix, represented as follows:

[0134]

[0135] Construct the Lagrangian function: By taking its partial derivative and setting it to 0, we can solve for the following: Right now

[0136] Step 104-4: Solve the generalized eigenvalue problem to obtain the elliptic coefficients.

[0137] In this embodiment, the objective is to minimize the sum of squared distances from the target sampling point to the ellipse. The Lagrange multiplier method is used to integrate constraints into the objective function, transforming the fitting problem from a constrained optimization to a solvable generalized eigenvalue problem. This weakens the interference of individual noise points, avoids complex nonlinear optimization iterations, and prevents non-unique solutions caused by constraint relaxation or boundary ambiguity, resulting in fitting results that more closely approximate the true contour of the pipe cross-section. This eliminates the influence of the center point offset during internal detector sampling on the ellipticity calculation results, ensuring the accuracy of ellipticity calculation even when the detector center does not coincide with the pipe center.

[0138] Further, in one embodiment, step 104-4 specifically includes: solving the generalized eigenvalue problem to obtain elliptic coefficients, including: constructing a scatter matrix based on the multinomial sum of the data matrix; decomposing the elliptic coefficient vector, scatter matrix, and constraint matrix in the generalized eigenvalue problem to obtain the decomposed eigenvalue problem; and solving the decomposed eigenvalue problem to obtain the elliptic coefficients.

[0139] The scatter matrix is ​​represented as S = D T D;

[0140] The eigenvalue decomposition problem is expressed as:

[0141] In the formula, S represents the scatter matrix, and S1, S2, and S3 represent the decomposed scatter matrices. C1 represents the decomposed elliptic coefficient vector, and C2 represents the decomposed constraint matrix.

[0142] In this embodiment, the elliptic coefficient vector, scatter matrix, and constraint matrix are decomposed into submatrices or subvectors, which can remove irrelevant variables and transform the high-dimensional generalized eigenvalue problem into a low-dimensional subproblem, significantly reducing the computational load. Furthermore, it effectively avoids inversion operations or handling singular matrices, improving the stability and accuracy of numerical computation.

[0143] For a specific example, define the scatter matrix S of matrix D, where S is a 6×6 scatter matrix, represented as the sum of multiple terms of x and y, i.e.

[0144]

[0145] The optimal solution was then obtained. The conditions are: Right now

[0146] In the equations established above, matrix C is a singular matrix, and matrix S is also approximately singular (matrix S is singular if all coordinate points are exactly located on the ellipse). Given that both matrix S and matrix C have special structures, the following decomposition can be performed to simplify the process of finding eigenvalues.

[0147] Divide matrix D into two parts: D = (D1|D2), specifically:

[0148]

[0149] The scatter matrix S, the constraint matrix C, and the vector Similarly, by splitting, we obtain:

[0150]

[0151] Based on the above breakdown It can be rewritten as:

[0152]

[0153] After solving, we can obtain the following two equations:

[0154]

[0155]

[0156] Since matrix S3 is a regular matrix, the formula can be... Convert to use The formula can be obtained as follows:

[0157]

[0158] Define a matrix M of size 3×3.

[0159] Therefore, finding the minimum fitting function is equivalent to solving:

[0160]

[0161] Solving the above formula will yield the result. and through Sure Finally, the formula is used. Calculate That is, the coefficients of the fitted pipe cross-section ellipse equation.

[0162] Step 105: Calculate the ellipticity of the pipeline based on the elliptic coefficient.

[0163] In practical applications, step 105, which involves calculating the ellipticity of the pipeline based on the elliptic coefficient, specifically includes the following steps:

[0164] Step 105-1: Calculate the minor axis length and major axis length of the fitted ellipse of the pipeline based on the elliptic coefficient.

[0165] Step 105-2: Calculate the difference between the minor axis length and the major axis length.

[0166] Step 105-3: Calculate the quotient of the difference and the length of the major axis to determine the ellipticity.

[0167] In this embodiment, after performing ellipse fitting on the pipe's inner diameter data, the longest and shortest axes of the ellipse can be obtained that more closely reflect the actual deformation of the pipe. By quantifying the difference between the major and minor axes, the ellipticity is calculated, making the calculated ellipticity closer to the actual result.

[0168] Specifically, the formulas for calculating the lengths of the minor and major axes are expressed as follows:

[0169]

[0170]

[0171] In the formula, l min Indicates the length of the minor axis, l max The major axis length is represented by , and a, b, c, d, e, and f represent the elliptic coefficients.

[0172] The pipeline ellipticity calculation method provided in this application can be applied to a terminal, a server, or software running on either a terminal or a server. In some embodiments, the terminal can be a smartphone, tablet, laptop, desktop computer, etc.; the server can be configured as an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms.

[0173] It should be noted that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.

[0174] Furthermore, such as Figure 5 As shown, as a specific implementation of the above-mentioned pipeline ellipticity calculation method, this application embodiment provides a pipeline ellipticity calculation device 300, which includes: a measurement module 301, a filtering module 302, a fitting module 303, and an ellipticity calculation module 304.

[0175] The measurement module 301 is used to acquire multiple cross-sectional sampling points of the pipeline in a preset plane coordinate system.

[0176] The filtering module 302 is used to calculate the discriminant value of the cross-sectional sampling points based on the median and standard deviation of multiple cross-sectional sampling points; and to delete the cross-sectional sampling points with discriminant values ​​greater than the standard value from the multiple cross-sectional sampling points to obtain the target sampling point, wherein the standard value is determined based on the number of multiple cross-sectional sampling points and the significance coefficient;

[0177] The fitting module 303 is used to perform ellipse fitting on the target sampling points and calculate the ellipse coefficient of the cross-sectional ellipse of the pipeline.

[0178] Ellipticity calculation module 304 is used to calculate the ellipticity of the pipeline based on the ellipticity coefficient.

[0179] Furthermore, the measurement module 301 is specifically used to calculate the change angle between the detection arm and the horizontal direction based on the physical signal collected by the sensor of the deformation detector; calculate the inner diameter of the pipe section corresponding to the detection arm based on the change angle; and project the sampling points of the detection arm onto the preset plane coordinate system based on the inner diameter of the pipe section to obtain the cross-sectional sampling points.

[0180] Furthermore, the measurement module 301 is specifically used to calculate the offset height of the detection arm projected into the vertical direction based on the changing angle and the length of the detection arm; and to calculate the sum of the offset height, the radius of the main body of the deformation detector, the radius of the detection probe on the detection arm, and the height of the support structure of the detection arm to determine the inner diameter of the pipe section.

[0181] Furthermore, the fitting module 303 is specifically used to construct the quadratic curve equation of the target sampling points and add equality constraints to the quadratic curve equation, wherein the equality constraints are used to indicate that the curve is an ellipse; with the goal of minimizing the sum of squared distances from the target sampling points to the specified ellipse, a Lagrange function is established based on the quadratic curve equation; the partial derivatives of the Lagrange function are calculated and set to zero to obtain the generalized eigenvalue problem; the ellipse coefficients are obtained by solving the generalized eigenvalue problem;

[0182] The equation of the quadratic curve is expressed as: F(x,y)=ax 2 +bxy+cy 2 +dx+ey+f=0;

[0183] The equality constraint is expressed as: 4ac-2b 2 =1;

[0184] The Lagrange function is expressed as:

[0185] The generalized eigenvalue problem is represented as:

[0186] In the formula, x and y represent the coordinates of the target sampling point, F(x,y) represents the distance from the target sampling point to the specified ellipse, and a, b, c, d, e, and f represent the ellipse coefficients. Let represent the elliptic coefficient vector, D represent the data matrix of the target sampling points, C represent the constraint matrix under the equality constraint condition, and the constraint matrix is ​​a singular matrix, and λ represents the Lagrange multiplier.

[0187] Furthermore, the fitting module 303 is specifically used to construct a scatter matrix based on the multinomial sum of the data matrix; decompose the elliptic coefficient vector, scatter matrix and constraint matrix in the generalized eigenvalue problem to obtain the decomposed eigenvalue problem; solve the decomposed eigenvalue problem to obtain the elliptic coefficients;

[0188] The scatter matrix is ​​represented as S = D T D;

[0189] The eigenvalue decomposition problem is expressed as:

[0190] In the formula, S represents the scatter matrix, and S1, S2, and S3 represent the decomposed scatter matrices. C1 represents the decomposed elliptic coefficient vector, and C2 represents the decomposed constraint matrix.

[0191] Furthermore, the ellipticity calculation module 304 is specifically used to calculate the minor axis length and major axis length of the fitted ellipse of the pipeline based on the ellipticity coefficient; calculate the difference between the minor axis length and the major axis length; calculate the quotient of the difference and the major axis length to determine the ellipticity;

[0192] The formulas for calculating the lengths of the minor and major axes are expressed as follows:

[0193]

[0194] In the formula, l min Indicates the length of the minor axis, l max The major axis length is represented by , and a, b, c, d, e, and f represent the elliptic coefficients.

[0195] Specific limitations regarding the pipe ellipticity calculation device can be found in the limitations of the pipe ellipticity calculation method described above, and will not be repeated here. Each module in the aforementioned pipe ellipticity calculation device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device in hardware form, or stored in the memory of a computer device in software form, so that the processor can call and execute the corresponding operations of each module.

[0196] Based on the above, Figure 1 Accordingly, embodiments of this application also provide a readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the above-described method. Figure 1 The method for calculating the ellipticity of the pipe is shown.

[0197] Based on this understanding, the technical solution of this application can be embodied in the form of a software product. This software product can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, or portable hard drive), and includes several instructions to cause a computer device (such as a personal computer, server, or network device) to execute the methods described in the various implementation scenarios of this application.

[0198] Based on the above, Figure 1 The method shown, and Figure 5 The virtual device embodiment shown is designed to achieve the above objectives, such as... Figure 6 As shown in the figure, this application embodiment also provides a computer device 400, which includes a processor 401 and a memory 402. The memory 402 stores a program or instructions that can run on the processor 401. When the program or instructions are executed by the processor 401, they implement the above-mentioned... Figure 1 The method for calculating the ellipticity of the pipe is shown.

[0199] The memory 402 can be used to store software programs and various data. The memory 402 may primarily include a first storage area for storing programs or instructions and a second storage area for storing data. The first storage area may store the operating system, application programs or instructions required for at least one function (such as sound playback, image playback, etc.). Furthermore, the memory 402 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct memory bus RAM (DRRAM). The memory 402 in the embodiments of this application includes, but is not limited to, these and any other suitable types of memory.

[0200] Processor 401 may include one or more processing units; optionally, processor 401 integrates an application processor and a modem processor, wherein the application processor mainly handles operations involving the operating system, user interface, and applications, and the modem processor mainly handles wireless communication signals, such as a baseband processor. It is understood that the aforementioned modem processor may also not be integrated into processor 401.

[0201] Computer equipment can specifically include personal computers, servers, network devices, etc.

[0202] Optionally, the computer device may also include a user interface, a network interface, a camera, radio frequency (RF) circuitry, sensors, audio circuitry, a Wi-Fi module, etc. The user interface may include a display screen, input units such as a keyboard, etc., and optional user interfaces may also include USB interfaces, card reader interfaces, etc. The network interface may optionally include standard wired interfaces, wireless interfaces (such as Bluetooth interfaces, Wi-Fi interfaces), etc.

[0203] Those skilled in the art will understand that the computer device structure provided in this embodiment does not constitute a limitation on the computer device, and may include more or fewer components, or combine certain components, or have different component arrangements.

[0204] Through the above description of the embodiments, those skilled in the art can clearly understand that this application can be implemented by means of software plus necessary general-purpose hardware platform, or by hardware implementation to obtain multiple cross-sectional sampling points of the pipeline in a preset plane coordinate system; calculate the discriminant value of the cross-sectional sampling points based on the median and standard deviation of the multiple cross-sectional sampling points; delete the cross-sectional sampling points whose discriminant value is greater than the standard value from the multiple cross-sectional sampling points to obtain the target sampling point, wherein the standard value is determined based on the number of multiple cross-sectional sampling points and the significance coefficient; perform ellipse fitting on the target sampling point to calculate the ellipse coefficient of the pipeline cross-section ellipse; calculate the ellipticity of the pipeline based on the ellipse coefficient. In the embodiments of this application, the median is used instead of the average value to calculate the discriminant value, and abnormal sampling points are deleted based on the discriminant value. While reducing noise and abnormal data, it makes the judgment of abnormal points more consistent with the distribution characteristics of the sampling data. It effectively eliminates the problem of the judgment standard being skewed by abnormal points during the inner diameter data filtering process, improves the removal effect of abnormal points in the pipeline radius data, avoids the interference of abnormal points on subsequent ellipse fitting, and can calculate the ellipticity closer to the actual result even if the center point of the detector is offset relative to the center point of the pipeline ellipse during sampling.

[0205] Those skilled in the art will understand that the accompanying drawings are merely schematic diagrams of a preferred embodiment, and the modules or processes shown in the drawings are not necessarily essential for implementing this application. Those skilled in the art will understand that the modules in the apparatus of the embodiment can be distributed within the apparatus of the embodiment as described, or can be modified to be located in one or more apparatuses different from this embodiment. The modules of the above-described embodiment can be combined into one module, or further divided into multiple sub-modules.

[0206] The serial numbers in this application are for descriptive purposes only and do not represent the superiority or inferiority of any particular implementation scenario. The above disclosures are merely a few specific implementation scenarios of this application; however, this application is not limited thereto, and any variations conceived by those skilled in the art should fall within the protection scope of this application.

Claims

1. A method for calculating the ellipticity of a pipe, characterized in that, The method includes: Obtain multiple cross-sectional sampling points of the pipeline arranged circumferentially along the inner wall of the pipeline in a preset planar coordinate system; Based on the median and standard deviation of multiple cross-sectional sampling points, the discriminant value of the cross-sectional sampling points is calculated; Target sampling points are obtained by deleting cross-sectional sampling points with discriminant values ​​greater than standard values ​​from a plurality of cross-sectional sampling points, wherein the standard value is determined based on the number of the plurality of cross-sectional sampling points and the significance coefficient; Construct the quadratic curve equation for the target sampling points, and add equality constraints to the quadratic curve equation; With the goal of minimizing the sum of squared distances from the target sampling point to the specified ellipse, a Lagrange function is established based on the quadratic curve equation; Taking the partial derivative of the Lagrange function and setting it to zero yields the generalized eigenvalue problem; A scatter matrix is ​​constructed based on the multinomial sum of the data matrix of the target sampling points in the generalized eigenvalue problem. The elliptic coefficient vector, the scatter matrix, and the constraint matrix in the generalized eigenvalue problem are decomposed to obtain the decomposed eigenvalue problem. The elliptic coefficients are obtained by solving the eigenvalue decomposition problem. The equation of the quadratic curve is expressed as: F ( x , y )= ax 2 + bxy + cy 2 + dx + ey + f =0; The equality constraint is used to indicate that the curve is an ellipse, and is expressed as: 4ac - 2b 2 = 1. The Lagrange function is expressed as: ; The generalized eigenvalue problem is expressed as: ; The scatter matrix is ​​represented as S=D T D; The eigenvalue decomposition problem is expressed as: ; In the formula, x , y Indicates the coordinates of the target sampling point. F ( x , y The distance () represents the distance from the target sampling point to the specified ellipse, and a, b, c, d, e, and f represent the ellipse coefficients. Let represent the elliptic coefficient vector, D represent the data matrix of the target sampling points, C represent the constraint matrix under the equality constraint conditions, and the constraint matrix is ​​a singular matrix, λ represent the Lagrange multipliers, S represent the scatter matrix, and S1, S2, and S3 represent the decomposed scatter matrices. , C1 represents the decomposed elliptic coefficient vector, and C2 represents the decomposed constraint matrix. The ellipticity of the pipeline is calculated based on the elliptic coefficient.

2. The method for calculating the ellipticity of a pipeline according to claim 1, characterized in that, A deformation detector is installed inside the pipe. The process of acquiring multiple cross-sectional sampling points arranged circumferentially along the inner wall of the pipe in a preset planar coordinate system includes: Based on the physical signals of the detection arm collected by the sensor of the deformation detector, the change angle between the detection arm and the horizontal direction is calculated; Calculate the inner diameter of the pipe section corresponding to the detection arm based on the changed angle; Based on the inner diameter of the pipe cross-section, the sampling points of the detection arm are projected onto the preset plane coordinate system to obtain the cross-section sampling points.

3. The method for calculating the ellipticity of a pipeline according to claim 2, characterized in that, The calculation of the pipe cross-section inner diameter corresponding to the detection arm based on the changed angle includes: Based on the changing angle and the length of the detection arm, calculate the offset height of the detection arm projected into the vertical direction; The inner diameter of the pipe section is determined by summing the offset height, the radius of the main body of the deformation detector, the radius of the detection probe on the detection arm, and the height of the support structure of the detection arm.

4. The method for calculating the ellipticity of a pipe according to any one of claims 1 to 3, characterized in that, The calculation of the ellipticity of the pipeline based on the elliptic coefficient includes: The minor axis length and major axis length of the fitted ellipse of the pipeline are calculated based on the elliptic coefficients. Calculate the difference between the minor axis length and the major axis length; Calculate the quotient of the difference and the length of the major axis to determine the ellipticity; The formulas for calculating the lengths of the minor and major axes are expressed as follows: ; ; ; ; In the formula, l min Indicates the length of the minor axis. l max The major axis length is represented by , and a, b, c, d, e, and f represent the elliptic coefficients.

5. The method for calculating the ellipticity of a pipe according to claim 2 or 3, characterized in that, The deformation detector includes: The main body is equipped with a sensor, which is used to collect physical signals from the detection arm; Multiple detection arms are provided. One end of each detection arm is connected to the main body via a support structure, and the other end of each detection arm is rotatably connected to a detection probe. The detection arms are evenly distributed along the circumference of the main body and form a double-layer distribution structure along the axial direction of the main body. The detection arms located in different layers are staggered along the circumference of the main body. The end of the detection probe is arc-shaped.

6. A device for calculating the ellipticity of a pipeline, characterized in that, The device includes: The measurement module is used to acquire multiple cross-sectional sampling points of the pipeline arranged circumferentially along the inner wall of the pipeline in a preset plane coordinate system; The filtering module is used to calculate the discriminant value of the cross-sectional sampling points based on the median and standard deviation of the multiple cross-sectional sampling points; and, Target sampling points are obtained by deleting cross-sectional sampling points with discriminant values ​​greater than standard values ​​from a plurality of cross-sectional sampling points, wherein the standard value is determined based on the number of the plurality of cross-sectional sampling points and the significance coefficient; The fitting module is used to construct the quadratic curve equation for the target sampling points and add equality constraints to the quadratic curve equation; with the objective of minimizing the sum of squared distances from the target sampling points to a specified ellipse, a Lagrange function is established based on the quadratic curve equation; the partial derivatives of the Lagrange function are calculated and set to zero to obtain the generalized eigenvalue problem; a scatter matrix is ​​constructed based on the multinomial sum of the data matrix of the target sampling points in the generalized eigenvalue problem; the ellipse coefficient vector, the scatter matrix, and the constraint matrix in the generalized eigenvalue problem are decomposed to obtain the decomposed eigenvalue problem; and the ellipse coefficients are obtained by solving the decomposed eigenvalue problem. The equation of the quadratic curve is expressed as: F ( x , y )= ax 2 + bxy + cy 2 + dx + ey + f =0; The equality constraint condition is used to indicate that the curve is an ellipse, and the equality constraint condition is expressed as: 4ac-2b 2 =1; The Lagrange function is expressed as: ; The generalized eigenvalue problem is expressed as: ; The scatter matrix is ​​represented as S=D T D; The eigenvalue decomposition problem is expressed as: ; In the formula, x , y Indicates the coordinates of the target sampling point. F ( x , y The distance () represents the distance from the target sampling point to the specified ellipse, and a, b, c, d, e, and f represent the ellipse coefficients. Let represent the elliptic coefficient vector, D represent the data matrix of the target sampling points, C represent the constraint matrix under the equality constraint conditions, and the constraint matrix is ​​a singular matrix, λ represent the Lagrange multipliers, S represent the scatter matrix, and S1, S2, and S3 represent the decomposed scatter matrices. , C1 represents the decomposed elliptic coefficient vector, and C2 represents the decomposed constraint matrix. An ellipticity calculation module is used to calculate the ellipticity of the pipeline based on the elliptic coefficient.

7. A readable storage medium having a program or instructions stored thereon, characterized in that, When the program or instructions are executed by the processor, they implement the pipeline ellipticity calculation method as described in any one of claims 1 to 5.

8. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the method for calculating the ellipticity of the pipeline as described in any one of claims 1 to 5.