Method and device for identifying defect or flange based on magnetic flux leakage signal

By processing abnormal data and extracting feature values ​​from pipeline magnetic flux leakage signals, and combining them with machine learning models, flanges and defects inside pipelines can be accurately identified, solving the problem of signal differentiation in pipeline inspection and improving detection accuracy and efficiency.

CN121994908APending Publication Date: 2026-05-08PETROCHINA CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
PETROCHINA CO LTD
Filing Date
2024-11-07
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

Existing technologies struggle to effectively distinguish between pipeline defects and magnetic leakage signals generated by flanges, leading to inaccurate pipeline health detection.

Method used

Abnormal data of magnetic flux leakage signals in pipelines are obtained by using a magnetic flux leakage detection instrument. After invalid rejection and blank filling, feature values ​​are extracted and identified using a trained defect and flange recognition model and defect type recognition model.

Benefits of technology

It enables accurate identification of flanges and defects inside pipelines, reduces false alarms, improves detection accuracy and efficiency, and provides a reliable basis for pipeline maintenance and safe operation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121994908A_ABST
    Figure CN121994908A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a method and device for identifying a defect or a flange based on a magnetic flux leakage signal, and the method comprises the steps: detecting a to-be-identified pipeline through a magnetic flux leakage detection instrument, and obtaining the abnormal data of the magnetic flux leakage signal; performing invalid elimination and blank filling processing on the abnormal data of the magnetic flux leakage signal to obtain an abnormal data segment; carrying out feature value extraction on the abnormal data segment to obtain a plurality of feature values used for expressing a magnetic flux leakage signal waveform; selecting a first characteristic value and a second characteristic value in the plurality of characteristic values; inputting the first characteristic value into a trained defect and flange identification model to obtain whether the to-be-identified pipeline has defects or flanges; and when the to-be-identified pipeline has defects, inputting the second characteristic value into a trained defect type identification model to obtain a defect type corresponding to the to-be-identified pipeline. According to the embodiment of the invention, defects or flanges can be identified, so that the health condition of the pipeline can be effectively detected.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments in this specification relate to the field of nondestructive testing, and in particular, to a method and apparatus for identifying defects or flanges based on magnetic flux leakage signals. Background Technology

[0002] Generally, oil and gas are transported through pipelines. During transportation, it is necessary to avoid defects in the pipeline, such as pitted metal loss and axial grooves. Magnetic leakage signal refers to the phenomenon that when there are defects in the pipeline material that cut magnetic lines of force, the magnetic flux in the magnetic circuit is distorted due to the lower permeability and higher magnetic reluctance at the defect, thus forming a magnetic leakage field on the material surface.

[0003] This magnetic leakage field can be captured by a magnetic induction sensor and transmitted to a computer for processing. By analyzing the magnetic flux density components of the leakage field, the defect characteristics of the material, such as width and depth, can be further understood. However, in reality, in addition to defects, flanges at pipe connections can also generate magnetic leakage signals. Since flanges are essential pipe connections, it is necessary to distinguish whether the magnetic leakage signal is caused by defects or flanges during pipe inspection in order to effectively detect the health status of the pipe.

[0004] Therefore, there is an urgent need for a method to identify defects or flanges based on magnetic flux leakage signals, which can identify defects or flanges and thus achieve effective detection of pipeline health status. Summary of the Invention

[0005] The purpose of this specification is to provide a method and apparatus for identifying defects or flanges based on magnetic flux leakage signals, so as to identify defects or flanges and thereby achieve effective detection of pipeline health status.

[0006] To achieve the above objectives, this specification provides, in one aspect, a method for identifying defects or flanges based on leakage magnetic signals, comprising:

[0007] After the pipeline to be identified is tested using a magnetic flux leakage detector, abnormal data of magnetic flux leakage signal are obtained.

[0008] After invalidating and filling blanks in the abnormal data of the leakage magnetic signal, the abnormal data segment is obtained;

[0009] Feature value extraction is performed on the abnormal data segment to obtain multiple feature values ​​used to describe the waveform of the leakage magnetic field signal;

[0010] Select a first feature value and a second feature value from the plurality of feature values, wherein the first feature value is correlated with flanges and defects, and the second feature value is correlated with different types of defects;

[0011] The first feature value is input into the trained defect and flange recognition model to obtain whether the pipeline to be identified has a defect or a flange.

[0012] When the pipeline to be identified has a defect, the second feature value is input into the trained defect type identification model to obtain the defect type corresponding to the pipeline to be identified.

[0013] Preferably, the abnormal data of the magnetic flux leakage signal obtained after detecting the pipeline to be identified using a magnetic flux leakage detector further includes:

[0014] The pipeline to be identified is detected using multiple probes on a magnetic flux leakage detector;

[0015] The probe that detects abnormal data of leakage magnetic field signal is regarded as the affected probe, and all four channels of the affected probe are regarded as the affected channels;

[0016] Extract a set of abnormal data of magnetic flux leakage signals detected in each affected channel along the axial direction of the pipe to be identified.

[0017] Preferably, after performing invalid removal and blank filling processing on the abnormal data of the leakage magnetic signal, the resulting abnormal data segment further includes:

[0018] The abnormal data of each group of leakage magnetic signals are processed into curves to obtain each initial data segment, which is in the form of a curve.

[0019] Remove invalid data that appears as a single data item in each initial data segment to obtain each set of removed outlier data.

[0020] Calculate the average value of each group of removed abnormal data, and use the average value to fill the blank spaces of the initial data segment to obtain each abnormal data segment. The abnormal data segment is in the form of a continuous curve, with the horizontal axis of the abnormal data segment representing the mileage value and the vertical axis representing the value of the abnormal data.

[0021] Preferably, the multiple characteristic values ​​used to describe the waveform of the leakage magnetic signal include: peak-to-valley value, axial spacing value, amplitude, waveform area, waveform energy, and number of affected channels.

[0022] Preferably, the step of extracting feature values ​​from the abnormal data segment to obtain multiple feature values ​​used to describe the leakage magnetic field signal waveform further includes:

[0023] Select the anomaly data segment with the largest difference in anomalies as the target anomaly data segment;

[0024] Obtain the maximum and minimum values ​​of the abnormal data in the target abnormal data segment, and calculate the absolute value of the difference between the maximum and minimum values ​​as the peak-valley value;

[0025] Obtain the mileage value of the first abnormal data and the mileage value of the last abnormal data in the target abnormal data segment, and calculate the absolute value of the difference between the two mileage values ​​as the axial spacing value;

[0026] Obtain the absolute value of the abnormal data with the largest absolute value in the target abnormal data segment, and use it as the amplitude.

[0027] Obtain the area enclosed by the waveform with the largest fluctuation in the abnormal data in the target abnormal data segment, and use it as the waveform area;

[0028] The dispersion of the abnormal data in the target abnormal data segment is obtained to obtain the waveform energy;

[0029] Obtain the number of affected channels as the number of affected channels.

[0030] Preferably, the waveform energy is calculated by obtaining the dispersion of the abnormal data in the target abnormal data segment using the following formula:

[0031]

[0032] Among them, t n Let x(t) be the mileage value of the nth abnormal data, and N be the number of abnormal data in the target abnormal data segment. n ) represents the value of the nth outlier, min[x(t) n )] represents the minimum value of abnormal data in the target abnormal data segment, and E represents the waveform energy.

[0033] Preferably, the training process of the defect and flange identification model includes:

[0034] After testing a known pipeline using a magnetic flux leakage detector, known abnormal data of known magnetic flux leakage signals are obtained;

[0035] After invalidating and filling blanks in the known abnormal data of the known leakage magnetic field signal, the known abnormal data segment is obtained;

[0036] Feature value extraction is performed on the known abnormal data segment to obtain multiple known feature values ​​used to describe the known leakage magnetic signal waveform;

[0037] Select the first known feature value from a set of known feature values;

[0038] The first known feature value of the known pipeline is used as the input value of the defect and flange identification model, and the presence of a known defect or flange in the pipeline is used as the output value to train the defect and flange identification model.

[0039] Preferably, the training process of the defect type identification model includes:

[0040] After testing a known pipeline using a magnetic flux leakage detector, known abnormal data of known magnetic flux leakage signals are obtained;

[0041] After invalidating and filling blanks in the known abnormal data of the known leakage magnetic field signal, the known abnormal data segment is obtained;

[0042] Feature value extraction is performed on the known abnormal data segment to obtain multiple known feature values ​​used to describe the known leakage magnetic signal waveform;

[0043] Select the second known feature value from a set of known feature values;

[0044] The defect type identification model is trained by using the second known feature value of the known pipeline as the input value and the known defect type of the pipeline as the output value.

[0045] On the other hand, embodiments of this specification provide a device for identifying defects or flanges based on magnetic flux leakage signals, the device comprising:

[0046] The detection module is used to obtain abnormal data of magnetic flux leakage signal after the pipeline to be identified is detected by the magnetic flux leakage detection instrument;

[0047] The processing module is used to perform invalid rejection and blank filling processing on the abnormal data of the leakage magnetic signal to obtain the abnormal data segment;

[0048] The extraction module is used to extract feature values ​​from the abnormal data segment to obtain multiple feature values ​​that describe the waveform of the leakage magnetic field signal.

[0049] The selection module is used to select a first feature value and a second feature value from the plurality of feature values, wherein the first feature value is correlated with the flange and the defect, and the second feature value is correlated with different types of defects;

[0050] The first identification module is used to input the first feature value into the trained defect and flange identification model to obtain whether the pipeline to be identified has a defect or a flange.

[0051] The second identification module is used to input the second feature value into the trained defect type identification model when the pipeline to be identified has a defect, so as to obtain the defect type corresponding to the pipeline to be identified.

[0052] In another aspect, embodiments of this specification also provide a computer device, including a memory, a processor, and a computer program stored in the memory, wherein the computer program, when executed by the processor, performs instructions of any of the methods described above.

[0053] In another aspect, embodiments of this specification also provide a computer-readable storage medium having a computer program stored thereon, the computer program being executed by a processor of a computer device to perform instructions for any of the methods described above.

[0054] In another aspect, embodiments of this specification also provide a computer program product that, when run by a processor of a computer device, executes instructions according to any one of the methods described above.

[0055] As can be seen from the technical solutions provided in the embodiments of this specification above, the method described in these embodiments, after detecting the pipeline using a magnetic flux leakage (MFL) detector, firstly, invalid data of the MFL signal is removed and blanks are filled to ensure the integrity and validity of the data, thereby improving the quality of the detection signal. Subsequently, multiple feature values ​​are extracted from the processed abnormal data segments; these feature values ​​characterize the waveform characteristics of the MFL signal. Next, by selecting first feature values ​​related to flanges and defects, these are input into a trained model to achieve accurate identification of flanges and defects within the pipeline, reducing false alarms and improving detection accuracy. When a defect is detected, second feature values ​​related to different defect types are further extracted and input into a defect type identification model to accurately determine the specific type of defect. The entire process, through the combination of intelligent data processing and machine learning models, significantly improves the automation level of MFL detection, not only ensuring accurate identification and classification of pipeline defects but also improving detection efficiency and reliability, providing a reliable basis for subsequent pipeline maintenance and safe operation.

[0056] To make the above and other objects, features and advantages of this specification more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description

[0057] To more clearly illustrate the technical solutions in the embodiments or prior art of this specification, the drawings used in the description of the embodiments or prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0058] Figure 1 A flowchart illustrating a method for identifying defects or flanges based on leakage magnetic signals, as provided in an embodiment of this specification, is shown.

[0059] Figure 2 This document illustrates a flowchart of an abnormal data analysis of magnetic flux leakage signals obtained after a magnetic flux leakage detector is used to detect the pipeline to be identified, as provided in an embodiment of this specification.

[0060] Figure 3 This document illustrates a flowchart illustrating the process of removing invalid data and filling blanks in the abnormal data of the leakage magnetic field signal, as provided in an embodiment of this specification, to obtain an abnormal data segment.

[0061] Figure 4 This document illustrates a flowchart of an embodiment of the present specification, showing the process of extracting feature values ​​from an abnormal data segment to obtain multiple feature values ​​used to describe the waveform of a leakage magnetic field signal.

[0062] Figure 5 A flowchart illustrating the training process of the defect and flange identification model provided in the embodiments of this specification is shown.

[0063] Figure 6 A flowchart illustrating the training process of the defect type identification model provided in the embodiments of this specification is shown.

[0064] Figure 7 This document illustrates a schematic diagram of the module structure of a device for identifying defects or flanges based on leakage magnetic signals, as provided in an embodiment of this specification.

[0065] Figure 8 A schematic diagram of the structure of a computer device provided in an embodiment of this specification is shown.

[0066] Explanation of symbols in the attached drawings:

[0067] 100. Detection module;

[0068] 200. Processing module;

[0069] 300. Extraction module;

[0070] 400. Select module;

[0071] 500. First identification module;

[0072] 600. Second identification module;

[0073] 802. Computer equipment;

[0074] 804, Processor;

[0075] 806. Memory;

[0076] 808. Drive mechanism;

[0077] 810. Input / Output Module;

[0078] 812. Input devices;

[0079] 814. Output devices;

[0080] 816. Presentation equipment;

[0081] 818. Graphical User Interface;

[0082] 820. Network interface;

[0083] 822. Communication link;

[0084] 824. Communication bus. Detailed Implementation

[0085] The technical solutions in the embodiments of this specification will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this specification, and not all embodiments. Based on the embodiments in this specification, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the embodiments of this specification.

[0086] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties. Furthermore, the collection, storage, use, processing, transmission, provision, disclosure, and application of the relevant data all comply with the relevant laws, regulations, and standards of the relevant countries and regions, have taken necessary confidentiality measures, do not violate public order and good morals, and provide corresponding operation portals for users to choose to authorize or refuse.

[0087] Generally, oil and gas are transported through pipelines. During transportation, it is necessary to avoid defects in the pipeline, such as pitted metal loss and axial grooves. Magnetic leakage signal refers to the phenomenon that when there are defects in the pipeline material that cut magnetic lines of force, the magnetic flux in the magnetic circuit is distorted due to the lower permeability and higher magnetic reluctance at the defect, thus forming a magnetic leakage field on the material surface.

[0088] This magnetic leakage field can be captured by a magnetic induction sensor and transmitted to a computer for processing. By analyzing the magnetic flux density components of the leakage field, the defect characteristics of the material, such as width and depth, can be further understood. However, in reality, in addition to defects, flanges at pipe connections can also generate magnetic leakage signals. Since flanges are essential pipe connections, it is necessary to distinguish whether the magnetic leakage signal is caused by defects or flanges during pipe inspection in order to effectively detect the health status of the pipe.

[0089] To address the aforementioned issues, this specification provides an embodiment of a method for identifying defects or flanges based on magnetic flux leakage signals. Figure 1This is a flowchart illustrating a method for identifying defects or flanges based on magnetic flux leakage signals, as provided in the embodiments of this specification. This specification provides the operational steps of the method described in the embodiments or flowcharts, but based on conventional or non-inventive labor, more or fewer operational steps may be included. The order of steps listed in the embodiments is merely one possible execution order among many and does not represent the only possible execution order. In actual system or device products, the methods shown in the embodiments or drawings can be executed sequentially or in parallel.

[0090] It should be noted that the terms "first," "second," etc., in the description, claims, and accompanying drawings of the embodiments in this specification are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, apparatus, product, or device that includes a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or devices.

[0091] Reference Figure 1 This specification provides an embodiment of a method for identifying defects or flanges based on magnetic flux leakage signals, including:

[0092] S101: After using a magnetic flux leakage detector to test the pipeline to be identified, abnormal data of magnetic flux leakage signal are obtained;

[0093] S102: After invalidating and filling blanks in the abnormal data of the leakage magnetic signal, an abnormal data segment is obtained;

[0094] S103: Extract feature values ​​from the abnormal data segment to obtain multiple feature values ​​used to describe the waveform of the leakage magnetic field signal;

[0095] S104: Select a first feature value and a second feature value from the plurality of feature values, wherein the first feature value is correlated with the flange and the defect, and the second feature value is correlated with different types of defects;

[0096] S105: Input the first feature value into the trained defect and flange recognition model to obtain whether the pipeline to be identified has a defect or a flange;

[0097] S106: When the pipeline to be identified has a defect, the second feature value is input into the trained defect type identification model to obtain the defect type corresponding to the pipeline to be identified.

[0098] Among them, reference Figure 2 The abnormal data of the magnetic flux leakage signal obtained after detecting the pipeline to be identified using a magnetic flux leakage detector further includes:

[0099] S201: Utilize multiple probes on the magnetic flux leakage detector to detect the pipeline to be identified;

[0100] S202: The probe that detects abnormal data of leakage magnetic field signal is regarded as the affected probe, and all four channels of the affected probe are regarded as the affected channels;

[0101] S203: Extract abnormal data of a set of leakage magnetic signals detected in each of the affected channels along the axial direction of the pipe to be identified.

[0102] Magnetic flux leakage (MFL) detection instruments are equipped with multiple probes, each containing four Hall effect sensors. Each Hall effect sensor detects data from one channel, meaning one probe can detect data from four channels. After the MFL detection instrument detects data, it exports and extracts the data using existing processing software. During extraction, for each channel, normal data is discarded, retaining only abnormal data to obtain a set of abnormal MFL signals. For a defect or flange to be identified on a pipeline, multiple probes typically detect abnormal MFL signals. These probes are designated as affected probes, and the four channels of the affected probes are designated as affected channels.

[0103] For magnetic flux leakage detection instruments, existing triaxial magnetic flux leakage detection instruments can detect abnormal data in the axial, radial and circumferential directions of the pipeline to be identified. However, in the embodiments of this specification, only the abnormal data in the axial direction is needed. The abnormal data in the other two directions are not considered. Therefore, it is only necessary to extract the abnormal data of a set of magnetic flux leakage signals obtained by detecting each affected channel in the axial direction of the pipeline to be identified.

[0104] Among them, reference Figure 3 The abnormal data segment obtained after invalidating and filling blanks in the abnormal data of the leakage magnetic signal further includes:

[0105] S301: Curve the abnormal data of each group of leakage magnetic signals to obtain each initial data segment, wherein the initial data segment is in curve form;

[0106] S302: Remove invalid data that appears as a single data in each initial data segment to obtain each set of removed abnormal data;

[0107] S303: Calculate the average value of each group of removed abnormal data, and use the average value to fill the blank space of the initial data segment to obtain each abnormal data segment. The abnormal data segment is in the form of a continuous curve, with the horizontal axis of the abnormal data segment being the mileage value and the vertical axis being the value of the abnormal data.

[0108] For a set of abnormal data of magnetic flux leakage signals, these data can be fitted into the form of a smooth curve after curve processing. However, some data appear in a single form and are not on the smooth curve. These data appearing in a single form are invalid data. Invalid data are caused by factors such as magnetic field interference, uneven pipe wall thickness, and the operating speed of the magnetic flux leakage detector, and need to be removed.

[0109] In addition, this results in blank areas in the initial data segment in the form of a curve, preventing it from forming a continuous curve. This is because the process of exporting and extracting data using existing processing software removes normal data, causing discontinuities and blank areas in the curve. Therefore, these blank areas need to be filled. Specifically, the average value of each set of removed abnormal data is calculated, and this average value is used to fill the blank areas in the initial data segment. This allows for the fitting of a continuous curve-shaped abnormal data segment. The horizontal axis of the abnormal data segment represents the mileage value, and the vertical axis represents the abnormal data value. The mileage value of the pipeline head to be identified is set to 0. As the detection progresses, the mileage value of each position along the axial direction of the pipeline to be identified is obtained. The mileage value at the location of the abnormal data in the corresponding abnormal data segment can be determined. Combining the abnormal data values, a continuous curve-shaped abnormal data segment can be obtained.

[0110] The multiple characteristic values ​​used to describe the waveform of the leakage magnetic signal include: peak-to-valley value, axial spacing value, amplitude, waveform area, waveform energy, and number of affected channels.

[0111] In the embodiments described in this specification, reference is made to Figure 4 The step of extracting feature values ​​from the abnormal data segment to obtain multiple feature values ​​used to describe the leakage magnetic signal waveform further includes:

[0112] S401: Select the abnormal data segment with the largest difference in abnormal data as the target abnormal data segment;

[0113] S402: Obtain the maximum and minimum values ​​of the abnormal data in the target abnormal data segment, and calculate the absolute value of the difference between the maximum and minimum values ​​as the peak-valley value;

[0114] S403: Obtain the mileage value of the first abnormal data and the mileage value of the last abnormal data in the target abnormal data segment, and calculate the absolute value of the difference between the two mileage values ​​as the axial spacing value;

[0115] S404: Obtain the absolute value of the abnormal data with the largest absolute value in the target abnormal data segment, and use it as the amplitude;

[0116] S405: Obtain the area enclosed by the waveform with the largest fluctuation in the abnormal data in the target abnormal data segment, and use it as the waveform area;

[0117] S406: Obtain the dispersion of the abnormal data in the target abnormal data segment to obtain the waveform energy;

[0118] S407: Obtain the number of affected channels as the number of affected channels.

[0119] Each affected channel can detect a set of abnormal data of leakage magnetic signals, and each set of eliminated abnormal data corresponds to an abnormal data segment. Therefore, there are multiple abnormal data segments in the embodiments of this specification.

[0120] The segment with the largest difference in abnormal data is selected as the target abnormal data segment. The largest difference in abnormal data means that the difference between the maximum and minimum values ​​of the abnormal data in the target abnormal data segment is the largest among all abnormal data segments.

[0121] The absolute value of the difference between the maximum and minimum values ​​of abnormal data in the target abnormal data segment is the peak-to-valley value. The absolute value of the difference between the first and last abnormal data points in the target abnormal data segment is the axial spacing value. The first abnormal data point refers to the abnormal data point at the beginning of the target abnormal data segment, i.e., the abnormal data point with the smallest mileage value. The last abnormal data point refers to the abnormal data point at the end of the target abnormal data segment, i.e., the abnormal data point with the largest mileage value. The absolute value of the abnormal data point with the largest absolute value in the target abnormal data segment is used as the amplitude. The area enclosed by the waveform with the largest fluctuation in the target abnormal data segment is used as the waveform area. Since the target abnormal data segment is in the form of a continuous curve, it contains multiple waveforms, including one peak value and two trough values. For the waveform with the largest fluctuation, the area enclosed by the largest difference between the peak value (the maximum value of the abnormal data) and the smaller of the two trough values ​​(the minimum value of the abnormal data) is used as the waveform area. The number of affected channels is used as the number of affected channels.

[0122] The waveform energy is calculated by obtaining the dispersion of the abnormal data in the target abnormal data segment using the following formula:

[0123]

[0124] Among them, t nLet x(t) be the mileage value of the nth abnormal data, and N be the number of abnormal data in the target abnormal data segment. n ) represents the value of the nth outlier, min[x(t) n )] represents the minimum value of abnormal data in the target abnormal data segment, and E represents the waveform energy.

[0125] In this way, multiple characteristic values ​​can be obtained to describe the waveform of the leakage magnetic signal. The first characteristic value and the second characteristic value are further selected from the multiple characteristic values. The first characteristic value is correlated with the flange and the defect, and the second characteristic value is correlated with different types of defects.

[0126] The first feature value is input into the trained defect and flange recognition model to determine whether the pipeline to be identified has a defect or a flange. When a defect is found, the second feature value is input into the trained defect type recognition model to determine the corresponding defect type of the pipeline to be identified.

[0127] In the embodiments described in this specification, reference is made to Figure 5 The training process of the defect and flange identification model includes:

[0128] S501: After testing a known pipeline with a magnetic flux leakage detector, known abnormal data of known magnetic flux leakage signals are obtained;

[0129] S502: After invalidating and filling blanks in the known abnormal data of the known leakage magnetic signal, the known abnormal data segment is obtained;

[0130] S503: Extract feature values ​​from the known abnormal data segment to obtain multiple known feature values ​​used to describe the known leakage magnetic signal waveform;

[0131] S504: Select the first known feature value from a plurality of known feature values;

[0132] S505: Use the first known feature value of the known pipeline as the input value of the defect and flange identification model, and use the known existence of defects or flanges in the pipeline as the output value to train the defect and flange identification model.

[0133] For a known pipeline, it is known whether the pipeline has defects or flanges. If the pipeline has defects, the specific type of defect is also known. Steps S501-S504 above are similar to the processing steps for the pipeline to be identified. The known characteristic values ​​in S501-S504 also include: known peak-to-valley values, known axial spacing values, known amplitude, known waveform area, known waveform energy, and known number of affected channels.

[0134] The first known feature value of the known pipeline corresponds to the first feature value of the pipeline to be identified. The feature types of the first known feature value and the first feature value are the same. For example, if the first known feature value is determined to be the known peak and valley values ​​and the known amplitude by the method of the embodiment of this specification, then the first feature value is the peak and valley values ​​and the amplitude. Selecting the first feature value from multiple feature values ​​is equivalent to selecting the first known feature value from multiple known feature values. It is sufficient to determine one of the two. Generally, the first known feature value is first determined based on the known pipeline situation. Therefore, taking the selection of the first known feature value from multiple known feature values ​​as an example:

[0135] In the embodiments of this specification, the first known characteristic value is correlated with the flange and the defect, and the correlation can be measured using the Pearson correlation coefficient.

[0136] The selection of the first known feature value from multiple known feature values ​​specifically involves: pre-calculating the correlation coefficient between each known feature value and the flange, and the correlation coefficient between each known feature value and the defect; selecting the known feature value whose absolute value of the correlation coefficient with both the flange and the defect is greater than a first threshold as the first known feature value. The fact that the absolute value of the correlation coefficient between the first known feature value and the flange is greater than the first threshold, and the absolute value of the correlation coefficient with the defect is also greater than the first threshold, indicates that the first known feature value is correlated with both the flange and the defect. The first threshold can be determined based on the actual situation.

[0137] The correlation coefficient between each known characteristic value and the flange or defect can be obtained using the following formula:

[0138]

[0139] Where r is the correlation coefficient value, x i For the i-th known feature value, Let y be the mean of all known eigenvalues. i For flange values ​​or defect values, This represents the average value of the flange or the average value of the defects.

[0140] The correlation coefficient ranges from -1 to 1. A correlation coefficient closer to 1 indicates a stronger linear correlation between the known feature value and the flange / defect. A correlation coefficient of 0 indicates no linear relationship between the known feature value and the flange / defect. In calculating the correlation coefficient between each known feature value and the flange or defect, since the flange itself has no defects, the flange value is set to 0, and the defect value to 1.

[0141] Since it is known that the pipeline has defects or flanges, for example, it is known that pipeline A has a flange, the first known feature value is used as the input value of the defect and flange identification model, and the known pipeline has defects or flanges is used as the output value. The defect and flange identification model is trained, and the trained model can identify whether the pipeline to be identified has defects or flanges.

[0142] In the embodiments described in this specification, reference is made to Figure 6 The training process of the defect type identification model includes:

[0143] S601: After testing a known pipeline with a magnetic flux leakage detector, known abnormal data of known magnetic flux leakage signals are obtained;

[0144] S602: After invalidating and filling blanks in the known abnormal data of the known leakage magnetic field signal, the known abnormal data segment is obtained;

[0145] S603: Extract feature values ​​from the known abnormal data segment to obtain multiple known feature values ​​used to describe the known leakage magnetic signal waveform;

[0146] S604: Select the second known feature value from a plurality of known feature values;

[0147] S605: Use the second known feature value of the known pipeline as the input value of the defect type identification model, and use the known defect type of the pipeline as the output value to train the defect type identification model.

[0148] The steps S601-S604 above are similar to the aforementioned processing steps for the pipeline to be identified.

[0149] The second known feature value of the known pipe corresponds to the second feature value of the pipe to be identified. The feature types of the second known feature value and the second feature value are the same. For example, if the second known feature value is determined to be the known waveform area and the known waveform energy by the method of the embodiment of this specification, then the second feature value is the waveform area and the waveform energy. Selecting the second feature value from multiple feature values ​​is equivalent to selecting the second known feature value from multiple known feature values. It is sufficient to determine one of the two. Generally, the second known feature value is first determined based on the known pipe situation. Taking the selection of the second known feature value from multiple known feature values ​​as an example:

[0150] In the embodiments of this specification, there is a correlation between the second known feature value and different types of defects, and the correlation can be measured using the Pearson correlation coefficient.

[0151] The selection of the second known feature value from multiple known feature values ​​specifically involves: pre-calculating the correlation coefficient between each known feature value and multiple different types of defects, and selecting the known feature value whose absolute value of the correlation coefficient between it and all different types of defects is greater than the second threshold as the second known feature value. The second threshold can be determined according to the actual situation.

[0152] Similarly, the correlation coefficient between each known feature value and multiple different types of defects can be obtained using the following formula:

[0153]

[0154] Where r is the correlation coefficient value, x i For the i-th known feature value, Let y be the mean of all known eigenvalues. i Let i be the value of the i-th type of defect. This is the mean of all different types of defects.

[0155] According to industry standards, defects are classified into 7 categories: pitted metal loss, general metal loss, axial grooves, circumferential grooves, circumferential grooves, axial grooves, and the length, width, and depth of pinholes. The above classification is based on the different dimensions of the defects. Therefore, in the process of calculating the correlation coefficient between each known feature value and multiple different types of defects, the value of the i-th type of defect is the size parameter value of the i-th type of defect. The size parameter value can be obtained from the length, width, and depth values ​​of the defect.

[0156] Since the known pipe defect type is known, for example, it is known that pipe A has an axial groove defect, the second known feature value is used as the input value of the defect type identification model, and the known pipe defect type is used as the output value. The defect type identification model is trained, and the trained model can identify the defect type of the pipe to be identified.

[0157] The method described in this specification, using a magnetic flux leakage (MF) detector to inspect pipelines, firstly, invalid data in the MF signal is removed and blanks are filled to ensure data integrity and validity, thus improving the quality of the detection signal. Subsequently, multiple feature values ​​are extracted from the processed abnormal data segments; these feature values ​​characterize the waveform features of the MF signal. Next, first feature values ​​related to flanges and defects are selected and input into a trained model to accurately identify flanges and defects within the pipeline, reducing false alarms and improving detection accuracy. When a defect is detected, second feature values ​​related to different defect types are further extracted and input into a defect type identification model to accurately determine the specific type of defect. This entire process, through the combination of intelligent data processing and machine learning models, significantly improves the automation level of MF detection, ensuring not only accurate identification and classification of pipeline defects but also improving detection efficiency and reliability, providing a reliable basis for subsequent pipeline maintenance and safe operation.

[0158] This application provides users with access to relevant big data analysis (such as personal biometrics, identity data, consumption data, asset data, electronic terminal operation data, etc.), allowing users to choose to agree to or reject automated decision results; if the user chooses to reject, the process will proceed to the expert decision-making process.

[0159] Based on the method for identifying defects or flanges based on leakage magnetic signals described above, this specification also provides a device for identifying defects or flanges based on leakage magnetic signals. The device may include a system (including a distributed system), software (application), module, component, server, client, etc., using the method described in this specification, combined with necessary hardware implementation. Based on the same innovative concept, the devices in one or more embodiments provided in this specification are as described in the following embodiments. Since the implementation schemes and methods for solving the problem are similar, the implementation of specific devices in this specification can refer to the implementation of the aforementioned method, and repeated details will not be repeated. As used below, the terms "unit" or "module" can refer to a combination of software and / or hardware that performs a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.

[0160] Specifically, Figure 7 This is a schematic diagram of a module structure of an embodiment of a device for identifying defects or flanges based on leakage magnetic signals, as provided in this specification. (Refer to...) Figure 7 As shown in the embodiments of this specification, an apparatus for identifying defects or flanges based on magnetic flux leakage signals includes: a detection module 100, a processing module 200, an extraction module 300, a selection module 400, a first identification module 500, and a second identification module 600.

[0161] The detection module 100 is used to obtain abnormal data of magnetic flux leakage signal after the pipeline to be identified is detected by the magnetic flux leakage detection instrument.

[0162] The processing module 200 is used to perform invalid rejection and blank filling processing on the abnormal data of the leakage magnetic signal to obtain an abnormal data segment;

[0163] The extraction module 300 is used to extract feature values ​​from the abnormal data segment to obtain multiple feature values ​​that describe the waveform of the leakage magnetic field signal.

[0164] The selection module 400 is used to select a first feature value and a second feature value from the plurality of feature values, wherein the first feature value is correlated with the flange and the defect, and the second feature value is correlated with different types of defects;

[0165] The first identification module 500 is used to input the first feature value into the trained defect and flange identification model to obtain whether the pipeline to be identified has a defect or a flange.

[0166] The second identification module 600 is used to input the second feature value into the trained defect type identification model when the pipeline to be identified has a defect, so as to obtain the defect type corresponding to the pipeline to be identified.

[0167] Reference Figure 8As shown, based on the method for identifying defects or flanges based on leakage magnetic signals described above, one embodiment of this specification also provides a computer device 802, wherein the above method operates on the computer device 802. The computer device 802 may include one or more processors 804, such as one or more central processing units (CPUs) or graphics processing units (GPUs), each processing unit implementing one or more hardware threads. The computer device 802 may also include any memory 806 for storing any kind of information such as code, settings, data, etc. In one specific embodiment, a computer program is stored on the memory 806 and can run on the processor 804. When the computer program is run by the processor 804, it can execute instructions according to the above method. Non-limitingly, for example, the memory 806 may include any type of RAM, any type of ROM, flash memory device, hard disk, optical disk, etc. More generally, any memory can use any technology to store information. Further, any memory can provide volatile or non-volatile retention of information. Further, any memory can represent a fixed or removable component of the computer device 802. In one scenario, when processor 804 executes associated instructions stored in any memory or combination of memories, computer device 802 can perform any operation of the associated instructions. Computer device 802 also includes one or more drive mechanisms 808 for interacting with any memory, such as hard disk drive mechanisms, optical disk drive mechanisms, etc.

[0168] Computer device 802 may also include an input / output module 810 (I / O) for receiving various inputs (via input device 812) and providing various outputs (via output device 814). A specific output mechanism may include a presentation device 816 and an associated graphical user interface 818 (GUI). In other embodiments, the input / output module 810 (I / O), input device 812, and output device 814 may be omitted, and the device may function solely as a computer device within a network. Computer device 802 may also include one or more network interfaces 820 for exchanging data with other devices via one or more communication links 822. One or more communication buses 824 couple the components described above together.

[0169] Communication link 822 can be implemented in any way, such as via a local area network, a wide area network (e.g., the Internet), a point-to-point connection, or any combination thereof. Communication link 822 may include any combination of hardwired links, wireless links, routers, gateway functions, name servers, etc., governed by any protocol or combination of protocols.

[0170] Corresponding to Figures 1-6In addition to the methods described above, embodiments of this specification also provide a computer-readable storage medium storing a computer program that, when executed by a processor, performs the steps of the methods described above.

[0171] This specification also provides computer-readable instructions, wherein when a processor executes the instructions, the program therein causes the processor to perform the following... Figures 1 to 6 The method shown.

[0172] This specification also provides a computer program product, which, when executed by the processor of a computer device, performs the following... Figures 1 to 6 The method shown.

[0173] The computer program product described in this specification is a software product that mainly implements the methods described in this specification through a computer program.

[0174] It should be understood that in the various embodiments of this specification, the sequence number of each process 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 specification.

[0175] It should also be understood that, in the embodiments of this specification, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Furthermore, in the embodiments of this specification, the character " / " generally indicates that the preceding and following related objects have an "or" relationship.

[0176] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed in this specification can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of each example have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of the embodiments in this specification.

[0177] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0178] In the several embodiments provided in this specification, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the couplings or direct couplings or communication connections shown or discussed may be indirect couplings or communication connections through some interfaces, devices, or units, or they may be electrical, mechanical, or other forms of connection.

[0179] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of the embodiments described in this specification, depending on actual needs.

[0180] Furthermore, the functional units in the various embodiments of this specification can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0181] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solutions of the embodiments of this specification, in essence, or the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this specification. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0182] This specification uses specific embodiments to illustrate the principles and implementation methods of the embodiments. The above description of the embodiments is only for the purpose of helping to understand the methods and core ideas of the embodiments in this specification. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of the embodiments in this specification. Therefore, the content of this specification should not be construed as a limitation on the embodiments in this specification.

Claims

1. A method for identifying defects or flanges based on leakage magnetic signals, characterized in that, include: After the pipeline to be identified is tested using a magnetic flux leakage detector, abnormal data of magnetic flux leakage signal are obtained. After invalidating and filling blanks in the abnormal data of the leakage magnetic signal, the abnormal data segment is obtained; Feature value extraction is performed on the abnormal data segment to obtain multiple feature values ​​used to describe the waveform of the leakage magnetic field signal; Select a first feature value and a second feature value from the plurality of feature values, wherein the first feature value is correlated with flanges and defects, and the second feature value is correlated with different types of defects; The first feature value is input into the trained defect and flange recognition model to obtain whether the pipeline to be identified has a defect or a flange. When the pipeline to be identified has a defect, the second feature value is input into the trained defect type identification model to obtain the defect type corresponding to the pipeline to be identified.

2. The method according to claim 1, characterized in that, The abnormal data obtained after detecting the pipeline to be identified using a magnetic flux leakage detector further include: The pipeline to be identified is detected using multiple probes on a magnetic flux leakage detector; The probe that detects abnormal data of leakage magnetic field signal is regarded as the affected probe, and all four channels of the affected probe are regarded as the affected channels; Extract a set of abnormal data of magnetic flux leakage signals detected in each affected channel along the axial direction of the pipe to be identified.

3. The method according to claim 2, characterized in that, After invalidating and filling blanks in the abnormal data of the leakage magnetic signal, the resulting abnormal data segment further includes: The abnormal data of each group of leakage magnetic signals are processed into curves to obtain each initial data segment, which is in the form of a curve. Remove invalid data that appears as a single data item in each initial data segment to obtain each set of removed outlier data. Calculate the average value of each group of removed abnormal data, and use the average value to fill the blank spaces of the initial data segment to obtain each abnormal data segment. The abnormal data segment is in the form of a continuous curve, with the horizontal axis of the abnormal data segment representing the mileage value and the vertical axis representing the value of the abnormal data.

4. The method according to claim 3, characterized in that, The multiple characteristic values ​​used to describe the waveform of the leakage magnetic signal include: peak-to-valley value, axial spacing value, amplitude, waveform area, waveform energy, and number of affected channels.

5. The method according to claim 4, characterized in that, The step of extracting feature values ​​from the abnormal data segment to obtain multiple feature values ​​used to describe the waveform of the magnetic flux leakage signal further includes: Select the anomaly data segment with the largest difference in anomalies as the target anomaly data segment; Obtain the maximum and minimum values ​​of the abnormal data in the target abnormal data segment, and calculate the absolute value of the difference between the maximum and minimum values ​​as the peak-valley value; Obtain the mileage value of the first abnormal data and the mileage value of the last abnormal data in the target abnormal data segment, and calculate the absolute value of the difference between the two mileage values ​​as the axial spacing value; Obtain the absolute value of the abnormal data with the largest absolute value in the target abnormal data segment, and use it as the amplitude. Obtain the area enclosed by the waveform with the largest fluctuation in the abnormal data in the target abnormal data segment, and use it as the waveform area; The dispersion of the abnormal data in the target abnormal data segment is obtained to obtain the waveform energy; Obtain the number of affected channels as the number of affected channels.

6. The method according to claim 5, characterized in that, The waveform energy is calculated by obtaining the dispersion of the abnormal data in the target abnormal data segment using the following formula: Among them, t n Let x(t) be the mileage value of the nth abnormal data, and N be the number of abnormal data in the target abnormal data segment. n ) represents the value of the nth outlier, min[x(t) n )] represents the minimum value of abnormal data in the target abnormal data segment, and E represents the waveform energy.

7. The method according to claim 1, characterized in that, The training process of the defect and flange identification model includes: After testing a known pipeline using a magnetic flux leakage detector, known abnormal data of known magnetic flux leakage signals are obtained; After invalidating and filling blanks in the known abnormal data of the known leakage magnetic field signal, the known abnormal data segment is obtained; Feature value extraction is performed on the known abnormal data segment to obtain multiple known feature values ​​used to describe the known leakage magnetic signal waveform; Select the first known feature value from a set of known feature values; The first known feature value of the known pipeline is used as the input value of the defect and flange identification model, and the presence of a known defect or flange in the pipeline is used as the output value to train the defect and flange identification model.

8. The method according to claim 1, characterized in that, The training process of the defect type identification model includes: After testing a known pipeline using a magnetic flux leakage detector, known abnormal data of known magnetic flux leakage signals are obtained; After invalidating and filling blanks in the known abnormal data of the known leakage magnetic field signal, the known abnormal data segment is obtained; Feature value extraction is performed on the known abnormal data segment to obtain multiple known feature values ​​used to describe the known leakage magnetic signal waveform; Select the second known feature value from a set of known feature values; The defect type identification model is trained by using the second known feature value of the known pipeline as the input value and the known defect type of the pipeline as the output value.

9. A device for identifying defects or flanges based on leakage magnetic signals, characterized in that, The device includes: The detection module is used to obtain abnormal data of magnetic flux leakage signal after the pipeline to be identified is detected by the magnetic flux leakage detection instrument; The processing module is used to perform invalid rejection and blank filling processing on the abnormal data of the leakage magnetic signal to obtain the abnormal data segment; The extraction module is used to extract feature values ​​from the abnormal data segment to obtain multiple feature values ​​that describe the waveform of the leakage magnetic field signal. The selection module is used to select a first feature value and a second feature value from the plurality of feature values, wherein the first feature value is correlated with the flange and the defect, and the second feature value is correlated with different types of defects; The first identification module is used to input the first feature value into the trained defect and flange identification model to obtain whether the pipeline to be identified has a defect or a flange. The second identification module is used to input the second feature value into the trained defect type identification model when the pipeline to be identified has a defect, so as to obtain the defect type corresponding to the pipeline to be identified.

10. A computer device comprising a memory, a processor, and a computer program stored in the memory, characterized in that, When the computer program is run by the processor, it executes the instructions of the method according to any one of claims 1-8.

11. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is run by the processor of the computer device, it executes the instructions of the method according to any one of claims 1-8.

12. A computer program product, characterized in that, When the computer program product is run by the processor of a computer device, it executes the instructions of the method according to any one of claims 1-8.