Online sensor data anomaly diagnosis method and system based on correlation analysis
The method uses correlation analysis to diagnose sensor anomalies in natural gas pipeline stations, enhancing fault detection speed and reducing costs by identifying abnormal data through sensor combination correlations and variance analysis.
Patent Information
- Application Number
- CN202410051431.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-12
- Publication Date
- 2025-07-15
AI Technical Summary
The prior art sensor fault detection cost in the natural gas long-distance pipeline station is high and abnormality is discovered late, resulting in the SCADA system misoperation and economic losses.
The online sensor data abnormality diagnosis method based on correlation analysis is adopted. By screening the sensor combination, the correlation coefficient and variance between sensors are calculated, the abnormal data is judged and positioned.
Quickly and accurately determine abnormal data and fault sensors, reduce costs, reduce economic losses, and ensure production safety.
Smart Images

Figure CN120316422A_ABST
Abstract
Description
Background Art
[0002] The SCADA system of natural gas long-distance pipeline stations monitors the data of hundreds of sensors simultaneously, and starts and stops equipment based on this sensor data to ensure production safety. Therefore, sensor failures can have a significant adverse impact on production. Existing solutions mainly use multiple sensors to detect key data simultaneously to improve production safety, but multiple sensors are costly and this method usually discovers abnormalities relatively late, still causing misoperations in the SCADA system and resulting in significant economic losses. Summary of the Invention
[0003] The technical problem to be solved by the present invention is to provide an online sensor data anomaly diagnosis method and system based on correlation analysis in view of the deficiencies of the prior art, specifically as follows:
[0004] 1) In the first aspect, the present invention provides an online sensor data anomaly diagnosis method based on correlation analysis, and the specific technical solution is as follows:
[0005] When the natural gas long-distance pipeline station is operating normally, select a sensor combination from multiple sensors of the natural gas long-distance pipeline station, and determine the normal range of the correlation coefficient between every two sensors in the sensor combination according to the data sequences collected by each sensor in the sensor combination within a first preset time period;
[0006] Calculate the actual correlation coefficient between every two sensors in the sensor combination according to the data sequences collected by each sensor in the sensor combination within a second preset time period;
[0007] Judge whether the actual correlation coefficient between every two sensors in the sensor combination is within the corresponding normal range to obtain a plurality of first judgment results;
[0008] Judge whether there is data anomaly according to all the first judgment results.
[0009] The beneficial effects of the online sensor data anomaly diagnosis method based on correlation analysis provided by the present invention are as follows:
[0010] In view of the fact that most of the process production parameters of production equipment in natural gas long-distance pipeline stations have a large correlation, based on the actual correlation coefficient between every two sensors in the sensor combination, the determination of abnormal data is carried out. Compared with the prior art, the present invention can determine abnormal data faster, determine the range of sensors with failures, so as to facilitate subsequent fault investigation and help reduce costs.
[0011] On the basis of the above solution, the online sensor data anomaly diagnosis method based on correlation analysis of the present invention can also be improved as follows.
[0012] Further, it further includes:
[0013] When the long-distance natural gas pipeline station is operating normally, according to the data sequences collected by each sensor in the sensor combination within the first preset time period, determine the normal range of the variance corresponding to each sensor in the sensor combination;
[0014] According to the data sequences collected by each sensor in the sensor combination within the second preset time period, calculate the actual variance corresponding to each sensor in the sensor combination;
[0015] Judge whether the actual variance corresponding to each sensor in the sensor combination is within the corresponding normal range to obtain a plurality of second judgment results;
[0016] When it is determined that there is data abnormality according to all the first judgment results, perform abnormality positioning according to all the second judgment results.
[0017] The beneficial effect of adopting the above further technical solution is: Through the judgment of the actual variance corresponding to each sensor, the faulty sensor can be quickly and accurately located.
[0018] Further, calculating the actual correlation coefficient between any two sensors in the sensor combination includes:
[0019] Based on the standard deviation and covariance of the data sequences collected by any two sensors in the sensor combination within the second preset time period, calculate the correlation coefficient between the two sensors.
[0020] Further, the process of obtaining the data sequences collected by each sensor in the sensor combination within the second preset time period includes:
[0021] Through the SCADA system of the long-distance natural gas pipeline station, obtain the data sequences collected by each sensor in the sensor combination within the second preset time period.
[0022] 2) In the second aspect, the present invention also provides an online sensor data abnormality diagnosis system based on correlation analysis, and the specific technical solution is as follows:
[0023] It includes: a screening calculation module, an actual correlation coefficient calculation module, a correlation coefficient judgment module, and a data abnormality judgment module;
[0024] The screening calculation module is used for: when the long-distance natural gas pipeline station is operating normally, select a sensor combination from multiple sensors of the long-distance natural gas pipeline station, and determine the normal range of the correlation coefficient between every two sensors in the sensor combination according to the data sequences collected by each sensor in the sensor combination within the first preset time period;
[0025] The actual correlation coefficient calculation module is used to: calculate the actual correlation coefficient between every two sensors in the sensor combination according to the data sequences collected by each sensor in the sensor combination within the second preset time period;
[0026] The correlation coefficient judgment module is used to: judge whether the actual correlation coefficient between every two sensors in the sensor combination is within the corresponding normal range, and obtain a plurality of first judgment results;
[0027] The data anomaly judgment module is used to: judge whether there is data anomaly according to all the first judgment results.
[0028] On the basis of the above solution, an online sensor data anomaly diagnosis system based on correlation analysis of the present invention can also be improved as follows.
[0029] Further, it further includes a variance normal range determination module, an actual variance calculation module, a variance judgment module and an anomaly location module;
[0030] The variance normal range determination module is used to: when the long-distance natural gas pipeline station operates normally, determine the normal range of the variance of the data sequences collected by each sensor in the sensor combination within the first preset time period;
[0031] The actual variance calculation module is used to: calculate the actual variance corresponding to each sensor in the sensor combination according to the data sequences collected by each sensor in the sensor combination within the second preset time period;
[0032] The variance judgment module is used to: judge whether the actual variance corresponding to each sensor in the sensor combination is within the corresponding normal range, and obtain a plurality of second judgment results;
[0033] The anomaly location module is used to: when it is determined that there is data anomaly according to all the first judgment results, perform anomaly location according to all the second judgment results.
[0034] Further, the actual correlation coefficient calculation module is specifically used to: calculate the correlation coefficient between any two sensors based on the standard deviation and covariance of the data sequences collected by any two sensors in the sensor combination within the second preset time period.
[0035] Further, it further includes a data acquisition module, and the data acquisition module is used to: obtain the data sequences collected by each sensor in the sensor combination within the second preset time period through the SCADA system of the long-distance natural gas pipeline station.
[0036] 3) Thirdly, the present invention further provides a computer device, which includes a processor coupled to a memory. At least one computer program is stored in the memory and is loaded and executed by the processor to enable the computer device to implement any one of the above online sensor data anomaly diagnosis methods based on correlation analysis.
[0037] 4) Fourthly, the present invention further provides a computer-readable storage medium in which at least one computer program is stored. The at least one computer program is loaded and executed by a processor to enable a computer to implement any one of the above online sensor data anomaly diagnosis methods based on correlation analysis.
[0038] It should be noted that for the beneficial effects obtained by the technical solutions of the second to fourth aspects of the present invention and the corresponding possible implementation manners, reference may be made to the technical effects of the first aspect and its corresponding possible implementation manners described above, and details will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] By reading the detailed description of the non-restrictive embodiments with reference to the following drawings, other features, objects, and advantages of the present invention will become more apparent:
[0040] Figure 1 It is a schematic flowchart of an online sensor data anomaly diagnosis method based on correlation analysis according to an embodiment of the present invention;
[0041] Figure 2 It is a graph of the fluctuation of the inlet and outlet pressure data under normal working conditions;
[0042] Figure 3 It is a graph of the fluctuation of the correlation coefficient of the inlet and outlet pressure data under normal working conditions;
[0043] Figure 4 It is a graph of the fluctuation of the variance of the inlet and outlet pressure data under normal working conditions;
[0044] Figure 5 It is a graph of the fluctuation of the inlet and outlet pressure and their correlation coefficient under abnormal working condition I;
[0045] Figure 6 It is a graph of the fluctuation of the inlet and outlet pressure and their correlation coefficient under abnormal working condition II;
[0046] Figure 7 It is a graph of the fluctuation of the inlet and outlet pressure and their correlation coefficient under abnormal working condition III;
[0047] Figure 8 It is a comparison of the fluctuation of the correlation coefficient between the normal correlation data model and the data under abnormal working condition I;
[0048] Figure 9It is a variance fluctuation diagram of the inlet and outlet pressure data under abnormal condition 1;
[0049] Figure 10 It is a schematic structural diagram of an online sensor data anomaly diagnosis system based on correlation analysis according to an embodiment of the present invention;
[0050] Figure 11 It is a schematic structural diagram of a computer device according to an embodiment of the present invention. Specific embodiments
[0051] To make the objectives, technical solutions and advantages of the present invention clearer, the embodiments of the present invention will be further described in detail below in conjunction with the accompanying drawings.
[0052] As Figure 1 shown, an online sensor data anomaly diagnosis method based on correlation analysis according to an embodiment of the present invention includes the following steps:
[0053] S1. When the natural gas long-distance pipeline station operates normally, select a sensor combination from multiple sensors of the natural gas long-distance pipeline station, and determine the normal range of the correlation coefficient between every two sensors in the sensor combination according to the data sequences collected by each sensor in the sensor combination within a first preset time period;
[0054] Among them, there are the following two implementation methods for selecting the sensor combination:
[0055] 1) The first implementation method: According to artificial experience, select at least two sensors that may be correlated from multiple sensors of the natural gas long-distance pipeline station to form a sensor combination.
[0056] 2) The second implementation method: Based on the standard deviation and covariance of the data sequences collected by any two sensors in the natural gas long-distance pipeline station within a first preset time period, calculate the correlation coefficient between the any two sensors, which is specifically calculated through the correlation coefficient calculation formula. The correlation coefficient calculation formula is:
[0057]
[0058] Among them, R(x, y) represents the correlation coefficient between any two sensors in the long-distance natural gas pipeline station; x represents the data sequence within the first preset time period collected by one of any two sensors in the long-distance natural gas pipeline station; y represents the data sequence within the first preset time period collected by the other of any two sensors in the long-distance natural gas pipeline station; δ(x) represents the standard deviation of x; δ(y) represents the standard deviation of y; cov(x, y) = E(xy) - E(x)E(y), where E(x) represents the average value of x, E(y) represents the average value of y, E(xy) represents the average value of the product of the data at each same moment in x and y, and xy represents the sum of the products of the data at each same moment in x and y. By analogy, the correlation coefficient between every two sensors in the long-distance natural gas pipeline station is calculated.
[0059] After calculating the correlation coefficient between every two sensors in the long-distance natural gas pipeline station, sensor combinations are screened out, and the correlation coefficient between every two sensors in the sensor combination is greater than the preset correlation coefficient threshold, and the preset correlation coefficient threshold can be set according to the actual situation.
[0060] The normal range of the correlation coefficient between any two sensors in the sensor combination is: greater than the product of the correlation coefficient between the two sensors and the first preset coefficient. The first preset coefficient is 0.9, and the preset coefficient can also be set according to the actual situation. By analogy, the normal range of the correlation coefficient between every two sensors in the sensor combination is obtained.
[0061] Among them, the duration of the first preset time period can be determined according to the change rate of the data collected by each sensor in the sensor combination and combined with experience, or can be determined according to the actual situation, or can be directly specified. Moreover, the first preset time period can be 1 hour or 2 hours, etc. before the current moment, or the first preset time period can be 1 hour or 2 hours, etc. before other specified moments, and can be set according to the actual situation.
[0062] Optionally, it further includes: preprocessing the data sequence within the first preset time period collected by each sensor in the long-distance natural gas pipeline station, deleting the significantly different points, and replacing the blank points with the mean value.
[0063] S2. Calculate the actual correlation coefficient between every two sensors in the sensor combination according to the data sequence within the second preset time period collected by each sensor in the sensor combination. Specifically:
[0064] Based on the standard deviation and covariance of the data sequences within the second preset time period collected by any two sensors in the sensor combination, calculate the correlation coefficient between the two sensors.
[0065] Among them, replace x with x ′ , replace y with y ′ , calculate the actual correlation coefficient between every two sensors in the sensor combination by using the correlation coefficient calculation formula. x ′ represents the data sequence collected by one of any two sensors in the sensor combination within the second preset time period, y ′ represents the data sequence collected by the other of any two sensors in the sensor combination within the second preset time period, until the actual correlation coefficient between every two sensors in the sensor combination is calculated.
[0066] S3. Judge whether the actual correlation coefficient between every two sensors in the sensor combination is within the corresponding normal range, and obtain a plurality of first judgment results;
[0067] S4. Judge whether there is abnormal data according to all the first judgment results. Specifically: determine the data sequence corresponding to the first judgment result of "no" as abnormal data.
[0068] It should be noted that when all the first judgment results are "yes", it is determined that there is no abnormal data.
[0069] An online sensor data anomaly diagnosis method based on correlation analysis provided by the present invention, aiming at the situation that most of the process production parameters of production equipment in natural gas long-distance pipeline stations have a large correlation, determines abnormal data based on the actual correlation coefficient between every two sensors in the sensor combination. Compared with the prior art, the present invention can determine abnormal data faster, determine the range of sensors with faults, so as to facilitate subsequent fault troubleshooting and help reduce costs.
[0070] Optionally, in the above technical solution, it further includes:
[0071] S5. When the natural gas long-distance pipeline station is operating normally, determine the normal range of the variance corresponding to each sensor in the sensor combination according to the data sequence collected by each sensor in the sensor combination within the first preset time period. Specifically:
[0072] According to the data sequence collected by any one sensor in the sensor combination within the first preset time period, calculate the variance corresponding to this sensor, which is specifically calculated by using the variance calculation formula. The variance calculation formula is:
[0073]
[0074] Among them, S represents: the variance of the data sequence collected by any one sensor in the sensor combination within the first preset time period, x iIt is represented as: the i-th data in the data sequence collected by any sensor in the sensor combination within the first preset time period. N is represented as: the number of data in the data sequence collected by any sensor in the sensor combination within the first preset time period. μ is represented as: the average value of all data in the data sequence collected by any sensor in the sensor combination within the first preset time period. Both N and i are positive integers.
[0075] The normal range of the variance corresponding to any sensor in the sensor combination is: greater than the product of the variance corresponding to the sensor and the second preset coefficient, where the second preset coefficient is greater than 1 and can also be set according to the actual situation. By analogy, the normal range of the correlation coefficient between each sensor in the sensor combination is obtained.
[0076] S6. Calculate the actual variance corresponding to each sensor in the sensor combination according to the data sequence collected by each sensor in the second preset time period. Specifically:
[0077] Among them, replace x i with x j ′ , replace N with N ′ , replace μ with μ ′ , and use the variance calculation formula to calculate the actual variance of the data sequence collected by any sensor within the second preset time period. x j ′ is represented as: the j-th data in the data sequence collected by any sensor within the second preset time period. N ′ is represented as: the number of data in the data sequence collected by any sensor in the sensor combination within the second preset time period. μ ′ is represented as: the average value of all data in the data sequence collected by any sensor in the sensor combination within the first preset time period. N ′ and j are both positive integers until the variances of the data sequences collected by each sensor in the sensor combination within the second preset time period are calculated.
[0078] Among them, for the explanation of the second preset time period, refer to the first preset time period and can be set according to the actual situation.
[0079] S7. Determine whether the actual variance corresponding to each sensor in the sensor combination is within the corresponding normal range to obtain multiple second judgment results;
[0080] S8. When it is determined that there is data abnormality according to all the first judgment results, perform abnormality positioning according to all the second judgment results. Specifically, determine the sensor corresponding to the second judgment result that is negative as the faulty sensor to achieve abnormality positioning.
[0081] Optionally, in the above technical solution, the process of obtaining the data sequence within the second preset time period collected by each sensor in the sensor combination includes:
[0082] Through the SCADA system of the natural gas long-distance pipeline station yard, obtain the data sequence within the second preset time period collected by each sensor in the sensor combination.
[0083] Compared with the prior art, the method proposed by the present invention can more quickly reflect the occurrence of sensor failures and ensure production safety at a lower cost.
[0084] In another embodiment, it includes:
[0085] S20. According to manual experience, screen two (or more) sensors that may have a correlation to form a sensor combination M. Obtain the historical production data during a period of operation, that is, the data sequence within the first preset time period collected by each sensor in the sensor combination. Preprocess the screened sensor historical data, that is, the data sequence within the second preset time period collected by each sensor in the sensor combination. The preprocessing is as follows: delete the points with obvious differences, replace the blank points with the mean value, and use the correlation coefficient to judge the correlation of the preprocessed data. When the number of sensors in the sensor combination M is two, based on the data sequence within the second preset time period collected by these two sensors, calculate the actual correlation coefficient between these two sensors. Under normal conditions, the value range of the correlation coefficient is between -1 and 1, where -1 represents a perfect negative correlation, 0 represents no correlation, and 1 represents a perfect positive correlation. Judge the correlation of the sensors in the combination M according to the value of the correlation coefficient.
[0086] According to manual experience, it is known that the data of the pressure sensors at the inlet and outlet of the long-distance pipeline station yard has a certain correlation. The data trend of the outlet pressure sensor is the same as that of the inlet pressure sensor, while the value should be slightly less than the measured value of the inlet pressure sensor due to factors such as interference. Therefore, a simulation experiment for abnormal diagnosis using the correlation between the inlet and outlet pressure sensors of the long-distance pipeline station yard is carried out to verify the feasibility of the method.
[0087] S21. Based on the historical production data of the sensor combination, according to the data characteristics, determine a reasonable time length DT for collecting normal correlation data models, and calculate the range of the correlation coefficient R and the variance S under different working conditions. Among them, the value range of the correlation coefficient R is between -1 and 1, where -1 represents a perfect negative correlation, 0 represents no correlation, and 1 represents a perfect positive correlation; the variance S represents the degree of deviation of the data from the mean value. The larger the variance, the greater the degree of deviation. Calculate R and S at the same DT starting from different times, and establish a normal correlation data model for the sensor combination based on the ranges of each coefficient when the sensors are working normally under different working conditions, providing reference data for subsequent judgment of whether the data is abnormal.
[0088] Taking the diagnosis of abnormal operating conditions using the correlation coefficient and variance as an example, here we assume that the data of the inlet pressure sensor changes in a sinusoidal trend over time. A random function is added to the output part to simulate disturbances. At this time, the numerical value of the data at the outlet of the pressure sensor is slightly smaller than that of the inlet data. To make the fluctuation range of the correlation coefficient smaller and the alarm more accurate, one cycle of data change is selected as the time length DT. Taking this sinusoidal data as an example, with 360° of one cycle of the sinusoidal data as the time length DT, 360 data, including each moment and the previous 359 moments, are taken as a group to calculate the correlation coefficient and variance. A suitable threshold is set as the normal data change range to establish a normal correlation data model. At this time, the inlet and outlet pressures and their correlation coefficient fluctuations under normal operating conditions are respectively as Figure 2 and Figure 3 ; the inlet and outlet variance fluctuations are as Figure 4 shown.
[0089] S22. Real-time collect the sensor data to be monitored in the pipeline station yard and calculate the correlation coefficient R and variance S.
[0090] Here, the data anomalies under three abnormal operating conditions are simulated. The three abnormal operating conditions are abnormal condition one, abnormal condition two, and abnormal condition three. Their data fluctuations and the change trends of the correlation coefficient are as Figure 5 , Figure 6 and Figure 7 shown.
[0091] S23. Compare the real-time data calculation results with the normal correlation data model. When the fluctuation of the correlation coefficient R exceeds the normal data model range, an alarm is issued, indicating that a certain sensor in the sensor combination has failed.
[0092] In abnormal condition one, the abnormal point is set at the 500th data point. Comparing the correlation coefficient fluctuations between abnormal condition one and the normal correlation data model is as Figure 8 shown. It can be observed that the correlation coefficient of the 144th data point, that is, the 504th point, has exceeded the normal correlation data model range. At this time, an alarm is issued, proving that there is an abnormality in the sensor combination.
[0093] S24. Respectively compare the variance ranges of the two sensor data with the variance ranges of the two sensors in the normal correlation data model. The sensor with a variance significantly deviating from the model range is the abnormal sensor.
[0094] The variance fluctuation under the normal model is as Figure 4 shown, and the variance fluctuation under abnormal condition one is as Figure 9 shown. By comparison, it can be determined that the outlet pressure sensor has a problem. The analysis of abnormal condition two and abnormal condition three is the same.
[0095] As can be seen from the above process, an online sensor data anomaly diagnosis method based on correlation analysis provided by the present invention can, on the premise of relatively low cost, give real-time warnings of the occurrence of sensor fault data, reduce economic losses, and ensure production safety at the same time.
[0096] In the above embodiments, although the steps are numbered S1, S2, etc., these are only specific embodiments given by the present invention. Those skilled in the art can adjust the execution order of S1, S2, etc. according to the actual situation, and this is also within the protection scope of the present invention. It can be understood that in some embodiments, it may include some or all of the above embodiments.
[0097] As Figure 10 shown, an online sensor data anomaly diagnosis system 200 based on correlation analysis according to an embodiment of the present invention includes: a screening calculation module 201, an actual correlation coefficient calculation module 202, a correlation coefficient judgment module 203, and a data anomaly judgment module 204;
[0098] The screening calculation module 201 is configured to: when the natural gas long-distance pipeline station is operating normally, select a sensor combination from multiple sensors of the natural gas long-distance pipeline station, and determine the normal range of the correlation coefficient between every two sensors in the sensor combination according to the data sequences collected by each sensor in the sensor combination within a first preset time period;
[0099] The actual correlation coefficient calculation module 202 is configured to: calculate the actual correlation coefficient between every two sensors in the sensor combination according to the data sequences collected by each sensor in the sensor combination within a second preset time period;
[0100] The correlation coefficient judgment module 203 is configured to: judge whether the actual correlation coefficient between every two sensors in the sensor combination is within the corresponding normal range, and obtain a plurality of first judgment results;
[0101] The data anomaly judgment module 204 is configured to: judge whether there is data anomaly according to all the first judgment results.
[0102] Optionally, in the above technical solution, it further includes a variance normal range determination module, an actual variance calculation module, a variance judgment module, and an anomaly location module;
[0103] The variance normal range determination module is configured to: when the natural gas long-distance pipeline station is operating normally, determine the normal range of the variance of the data sequence collected by each sensor in the sensor combination within a first preset time period;
[0104] The actual variance calculation module is configured to: calculate the actual variance corresponding to each sensor in the sensor combination according to the data sequences collected by each sensor in the sensor combination within a second preset time period;
[0105] The variance judgment module is configured to: judge whether the actual variance corresponding to each sensor in the sensor combination is within the corresponding normal range, and obtain a plurality of second judgment results;
[0106] The anomaly location module is configured to: when it is determined that there is data anomaly according to all the first judgment results, perform anomaly location according to all the second judgment results.
[0107] Optionally, in the above technical solution, the actual correlation coefficient calculation module is specifically configured to: calculate the correlation coefficient between any two sensors in the sensor combination based on the standard deviations and covariances of the data sequences collected by any two sensors in the sensor combination within a second preset time period.
[0108] Optionally, in the above technical solution, a data acquisition module is further included. The data acquisition module is configured to: acquire the data sequences collected by each sensor in the sensor combination within a second preset time period through the SCADA system of the natural gas long-distance pipeline station yard.
[0109] It should be noted that the beneficial effects of the online sensor data anomaly diagnosis system 200 based on correlation analysis provided in the above embodiments are the same as those of the online sensor data anomaly diagnosis method based on correlation analysis, and will not be elaborated here. In addition, when the system provided in the above embodiments implements its functions, only the above-mentioned functional module divisions are used for illustration. In practical applications, the above functions can be allocated to different functional modules according to needs, that is, the system can be divided into different functional modules according to the actual situation to complete all or part of the functions described above. In addition, the system provided in the above embodiments and the method embodiments belong to the same concept, and the specific implementation process can be seen in the method embodiments, which will not be elaborated here.
[0110] As Figure 11 shown, a computer device 300 according to an embodiment of the present invention includes a processor 320. The processor 320 is coupled to a memory 310. At least one computer program 330 is stored in the memory 310. The at least one computer program 330 is loaded and executed by the processor 320 so that the computer device 300 implements any one of the above-mentioned online sensor data anomaly diagnosis methods based on correlation analysis. Specifically:
[0111] The computer device 300 can vary significantly due to differences in configuration or performance. It may include one or more processors 320 (Central Processing Units, CPUs) and one or more memories 310. Among them, at least one computer program 330 is stored in the one or more memories 310, and the at least one computer program 330 is loaded and executed by the one or more processors 320, so that the computer device 300 can implement any one of the online sensor data anomaly diagnosis methods based on correlation analysis provided in the above embodiments. Of course, the computer device 300 may also have components such as wired or wireless network interfaces, keyboards, and input / output interfaces for input and output. The computer device 300 may also include other components for implementing the functions of the device, which will not be elaborated here.
[0112] In an embodiment of the present invention, a computer-readable storage medium stores at least one computer program, and the at least one computer program is loaded and executed by a processor to enable a computer to implement any one of the above online sensor data anomaly diagnosis methods based on correlation analysis.
[0113] Optionally, the computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a compact disc read-only memory (CD-ROM), magnetic tape, floppy disk, and optical data storage device, etc.
[0114] In an exemplary embodiment, a computer program product or a computer program is also provided. The computer program product or the computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes any one of the above online sensor data anomaly diagnosis methods based on correlation analysis.
[0115] It should be noted that the terms "first", "second", etc. in the specification and claims of this application are used to distinguish similar objects, and do not represent a specific order or sequence. Under appropriate circumstances, the order of use of similar objects can be interchanged, so that the embodiments of the present application described here can be implemented in an order other than the illustrated or described order.
[0116] Those skilled in the art of the present technology know that the present invention can be implemented as a system, a method, or a computer program product. Therefore, the present invention can be specifically implemented in the following forms, namely: it can be completely hardware, or completely software (including firmware, resident software, microcode, etc.), or a combination of hardware and software, which is generally referred to as "circuit", "module", or "system" in this article. In addition, in some embodiments, the present invention can also be implemented in the form of a computer program product in one or more computer-readable media, which contain computer-readable program code.
[0117] Any combination of one or more computer-readable media can be adopted. The computer-readable media can be computer-readable signal media or computer-readable storage media. The computer-readable storage media can be, for example - but not limited to - an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples (non-exhaustive list) of the computer-readable storage media include: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, the computer-readable storage media can be any tangible medium that contains or stores a program, and this program can be used by or in combination with an instruction execution system, apparatus, or device.
[0118] Although the embodiments of the present invention have been shown and described above, it can be understood that the above embodiments are exemplary and should not be construed as limitations on the present invention. Those of ordinary skill in the art can make changes, modifications, substitutions, and variations to the above embodiments within the scope of the present invention.
Claims
1. An online sensor data anomaly diagnosis method based on correlation analysis, characterized in that Including: When the long-distance natural gas pipeline station is operating normally, select a sensor combination from multiple sensors of the long-distance natural gas pipeline station, and determine the normal range of the correlation coefficient between every two sensors in the sensor combination according to the data sequences within a first preset time period collected by each sensor in the sensor combination; Calculate the actual correlation coefficient between every two sensors in the sensor combination according to the data sequences within a second preset time period collected by each sensor in the sensor combination; Judge whether the actual correlation coefficient between every two sensors in the sensor combination is within the corresponding normal range, and obtain a plurality of first judgment results; Judge whether there is data abnormality according to all the first judgment results.
2. The online sensor data anomaly diagnosis method based on correlation analysis according to claim 1, wherein Also including: When the long-distance natural gas pipeline station is operating normally, determine the normal range of the variance corresponding to each sensor in the sensor combination according to the data sequences within a first preset time period collected by each sensor in the sensor combination; Calculate the actual variance corresponding to each sensor in the sensor combination according to the data sequences within a second preset time period collected by each sensor in the sensor combination; Judge whether the actual variance corresponding to each sensor in the sensor combination is within the corresponding normal range, and obtain a plurality of second judgment results; When it is determined that there is data abnormality according to all the first judgment results, perform abnormality location according to all the second judgment results.
3. An online sensor data anomaly diagnosis method based on correlation analysis according to claim 1 or 2, characterized in that, Calculating the actual correlation coefficient between any two sensors in the sensor combination includes: Calculating the correlation coefficient between the any two sensors based on the standard deviation and covariance of the data sequences within a second preset time period collected by the any two sensors in the sensor combination.
4. An online sensor data anomaly diagnosis method based on correlation analysis according to claim 1 or 2, characterized in that, The process of obtaining the data sequences within a second preset time period collected by each sensor in the sensor combination includes: Obtain the data sequences within a second preset time period collected by each sensor in the sensor combination through the SCADA system of the long-distance natural gas pipeline station.
5. An online sensor data anomaly diagnosis system based on correlation analysis, characterized in that, Including: A screening calculation module, an actual correlation coefficient calculation module, a correlation coefficient judgment module, and a data abnormality judgment module; The screening calculation module is used for: when the long-distance natural gas pipeline station is operating normally, select a sensor combination from multiple sensors of the long-distance natural gas pipeline station, and determine the normal range of the correlation coefficient between every two sensors in the sensor combination according to the data sequences within a first preset time period collected by each sensor in the sensor combination; The actual correlation coefficient calculation module is used for: calculating the actual correlation coefficient between every two sensors in the sensor combination according to the data sequences within a second preset time period collected by each sensor in the sensor combination; The correlation coefficient judgment module is used for: judging whether the actual correlation coefficient between every two sensors in the sensor combination is within the corresponding normal range, and obtaining a plurality of first judgment results; The data abnormality judgment module is used for: judging whether there is data abnormality according to all the first judgment results.
6. An online sensor data anomaly diagnosis system based on correlation analysis according to claim 5, characterized in that, It further includes a variance normal range determination module, an actual variance calculation module, a variance judgment module, and an anomaly location module; The variance normal range determination module is configured to: when the natural gas long-distance pipeline station operates normally, determine the normal range of the variance corresponding to each sensor in the sensor combination according to the data sequence within a first preset time period collected by each sensor in the sensor combination; The actual variance calculation module is configured to: calculate the actual variance corresponding to each sensor in the sensor combination according to the data sequence within a second preset time period collected by each sensor in the sensor combination; The variance judgment module is configured to: judge whether the actual variance corresponding to each sensor in the sensor combination is within the corresponding normal range, and obtain a plurality of second judgment results; The anomaly location module is configured to: when it is determined that there is data anomaly according to all the first judgment results, perform anomaly location according to all the second judgment results.
7. An online sensor data anomaly diagnosis system based on correlation analysis according to claim 5 or 6, characterized in that, The actual correlation coefficient calculation module is specifically configured to: calculate the correlation coefficient between any two sensors based on the standard deviation and covariance of the data sequences within a second preset time period collected by any two sensors in the sensor combination.
8. An online sensor data anomaly diagnosis system based on correlation analysis according to claim 5 or 6, characterized in that, It further includes a data acquisition module, and the data acquisition module is configured to: acquire the data sequence within a second preset time period collected by each sensor in the sensor combination through the SCADA system of the natural gas long-distance pipeline station.
9. A computer device, characterized in that, The computer device includes a processor, the processor is coupled with a memory, and at least one computer program is stored in the memory. The at least one computer program is loaded and executed by the processor so that the computer device implements an online sensor data anomaly diagnosis method according to any one of claims 1 to 4.
10. A computer-readable storage medium, characterized in that, At least one computer program is stored in the computer-readable storage medium, and the at least one computer program is loaded and executed by a processor so that a computer implements an online sensor data anomaly diagnosis method according to any one of claims 1 to 4.
Citation Information
Cited By
Bridge structure risk state early warning judgment method, system and equipment based on correlation network diagram
CN121148131A
