A water quality abnormal data monitoring method and system based on deep learning generated error
By using deep learning to generate errors, and combining Class I and Class II verification with deep learning models, the problem of low accuracy in traditional water quality monitoring is solved, enabling timely and accurate detection of water quality anomalies and improving the accuracy and reliability of water quality monitoring.
Patent Information
- Application Number
- CN202411538410.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-31
- Publication Date
- 2025-11-18
- Estimated Expiration
- 2044-10-31
AI Technical Summary
Traditional water quality monitoring methods suffer from low accuracy due to manual sampling, making it difficult to detect water quality anomalies in a timely and accurate manner.
A deep learning-based error generation method is employed, combining Class I and Class II verification with a deep learning model to monitor water quality data. This includes acquiring data using temperature, pH, dissolved oxygen, turbidity, and conductivity sensors, and utilizing recurrent neural networks to process time-series data to improve monitoring accuracy.
It significantly improves the accuracy and reliability of water quality monitoring, enabling timely detection of water quality anomalies and reducing the risk of pollution spread.
Smart Images

Figure CN119416119B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of data processing, and more specifically, to a method and system for monitoring water quality anomaly data based on deep learning-generated errors. Background Technology
[0002] With increasing public concern about environmental development, more and more people are prioritizing water quality protection. In water quality protection, timely and accurate monitoring of anomalies is crucial, allowing for the rapid detection of changes in water quality. For example, in the event of a sudden pollution incident in a river (such as illegal factory discharges or chemical leaks), a water quality anomaly monitoring system can detect abnormal fluctuations in water quality parameters (such as chemical oxygen demand and heavy metal content) within a short period through continuous monitoring data. This enables relevant departments to take countermeasures in the early stages of pollution spread, reducing the harm to aquatic ecosystems and the drinking water safety of surrounding residents, and is vital for the protection of drinking water sources. Taking urban drinking water reservoirs as an example, real-time water quality anomaly monitoring can promptly detect excessive microorganisms and the intrusion of harmful substances in the water, thereby preventing contaminated water from entering the water supply system and ensuring that residents have access to safe drinking water. However, traditional water quality monitoring methods often rely on on-site sampling and laboratory analysis or rapid on-site testing, which may suffer from reduced accuracy due to manual sampling.
[0003] Therefore, how to provide a method to improve the accuracy of water quality anomaly monitoring has become an urgent problem to be solved in this field. Summary of the Invention
[0004] This application proposes a method for monitoring water quality anomaly data based on deep learning-generated errors, comprising the following steps: acquiring water quality monitoring data; determining the water quality monitoring data class based on the acquired water quality monitoring data; performing a Class I validation on the water quality monitoring data class to determine whether the Class I validation can pass; if the Class I validation fails, performing a Class II validation on the water quality monitoring data class to determine whether the Class II validation can pass; if the Class II validation passes, performing deep learning to determine the deep learning-generated error, and outputting the water quality anomaly detection result based on the generated error.
[0005] As described above, the water quality anomaly data monitoring method based on deep learning generation error will perform deep learning if one type of verification passes, determine the deep learning generation error, and output the water quality anomaly detection result based on the generation error.
[0006] As described above, the water quality anomaly data monitoring method based on deep learning-generated errors will output the water quality anomaly detection result if the second type of verification fails.
[0007] The water quality anomaly data monitoring method based on deep learning-generated errors, as described above, acquires water quality monitoring data by obtaining water quality monitoring data from multiple sensors. The water quality monitoring data includes water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity data. The multiple sensors include a temperature sensor, a pH sensor, a dissolved oxygen sensor, a turbidity sensor, and a conductivity sensor.
[0008] As described above, the water quality anomaly data monitoring method based on deep learning-generated errors determines the water quality monitoring data class according to the acquired water quality monitoring data, including water quality monitoring data of a city obtained from different sensors as a water quality monitoring data class.
[0009] A water quality anomaly data monitoring system based on deep learning-generated error specifically includes: a water quality monitoring data acquisition unit, a water quality monitoring data class determination unit, a first-class verification unit, a second-class verification unit, and a deep learning unit; the water quality monitoring data acquisition unit is used to acquire water quality monitoring data; the water quality monitoring data class determination unit is used to determine the water quality monitoring data class based on the acquired water quality monitoring data; the first-class verification unit is used to perform a first-class verification on the water quality monitoring data class to determine whether the first-class verification can pass; if the first-class verification fails, the second-class verification unit performs a second-class verification on the water quality monitoring data class to determine whether the second-class verification can pass; if the second-class verification passes, the deep learning unit performs deep learning to determine the deep learning generation error, and outputs the water quality anomaly detection result based on the generation error.
[0010] As described above, in the water quality anomaly data monitoring system based on deep learning-generated errors, if one type of verification passes, the deep learning unit performs deep learning to determine the deep learning-generated error, and outputs the water quality anomaly detection result based on the generated error.
[0011] As described above, the water quality anomaly data monitoring system based on deep learning-generated errors will output water quality anomaly detection results if the Type II verification of the Type II verification unit fails.
[0012] As described above, the water quality anomaly data monitoring system based on deep learning-generated errors acquires water quality monitoring data from multiple sensors. The water quality monitoring data includes water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity data. The multiple sensors include a temperature sensor, a pH sensor, a dissolved oxygen sensor, a turbidity sensor, and a conductivity sensor.
[0013] As described above, in the water quality anomaly data monitoring system based on deep learning-generated errors, the water quality monitoring data class determination unit determines the water quality monitoring data class based on the acquired water quality monitoring data, including water quality monitoring data of a city acquired from different sensors as one water quality monitoring data class.
[0014] This application has the following beneficial effects:
[0015] This application proposes a method for performing Class I and Class II verification on water quality data. First, water quality data is monitored to different degrees, and then deep learning is used to further monitor water quality data that does not detect any anomalies. The water quality anomaly monitoring method of this application greatly improves the accuracy and reliability of water quality monitoring. Attached Figure Description
[0016] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this application. For those skilled in the art, other drawings can be obtained based on these drawings.
[0017] Figure 1 This is a flowchart of a water quality anomaly data monitoring method based on deep learning-generated error, according to an embodiment of this application.
[0018] Figure 2 This is a schematic diagram of the internal structure of a water quality anomaly data monitoring system based on deep learning-generated error, according to an embodiment of this application. Detailed Implementation
[0019] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the scope of protection of this application.
[0020] Example 1
[0021] like Figure 1 As shown, this embodiment provides a method for monitoring water quality anomaly data based on deep learning-generated errors, specifically including the following steps:
[0022] Step S110: Obtain water quality monitoring data.
[0023] Specifically, water quality monitoring data is obtained from various sensors. This data includes water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity. The sensors include: a temperature sensor, a pH sensor, a dissolved oxygen sensor, a turbidity sensor, and a conductivity sensor.
[0024] Temperature sensors typically employ technologies such as thermistors, thermocouples, or semiconductor temperature sensors. They determine temperature by measuring changes in the heat conduction or resistance of water. Water temperature has a significant impact on the survival and reproduction of aquatic organisms, the rate of chemical reactions, and the physical properties of water. For example, different species of fish have specific temperature tolerance ranges; excessively high or low temperatures can lead to fish mortality.
[0025] pH sensors use glass electrodes or other types of electrodes to measure the concentration of hydrogen ions in water. The potential generated by the electrode is logarithmically related to the hydrogen ion concentration, and the pH value can be determined through calibration. The pH value reflects the acidity or alkalinity of the water. A suitable pH value is crucial for the health of aquatic life and also affects the solubility and toxicity of chemicals in the water. For example, acidic water can lead to increased dissolution of metal ions, which can be toxic to aquatic organisms.
[0026] Dissolved oxygen sensors determine dissolved oxygen concentration using both electrochemical and optical methods. Electrochemical dissolved oxygen sensors determine concentration by measuring the current between electrodes, while optical dissolved oxygen sensors utilize the principles of fluorescence or optical absorption. Dissolved oxygen is a crucial indicator of water quality. It is essential for the respiration and survival of aquatic organisms and also affects the decomposition of organic matter and the cycling of nutrients in the water. For example, low dissolved oxygen levels can lead to fish suffocation and death, while high dissolved oxygen levels promote the activity of aerobic microorganisms and accelerate the decomposition of organic matter.
[0027] Turbidity sensors determine turbidity by measuring the scattering or absorption of light by suspended particles in water. Common turbidity sensors include scattering-type and transmission-type turbidity sensors. Turbidity reflects the amount of suspended particles in water. High turbidity in water can affect the vision and respiration of aquatic organisms and may also carry pathogens and pollutants. For example, reducing turbidity is an important step in drinking water treatment.
[0028] Conductivity sensors measure conductivity based on the electrical conductivity of water. Conductivity is directly proportional to the concentration of dissolved ions in water. Conductivity reflects the amount of dissolved salts in water. It is important for assessing water hardness, salinity, and the composition of ions in water. For example, water with high conductivity may be unsuitable for certain industrial uses or agricultural irrigation.
[0029] Step S120: Determine the water quality monitoring data type based on the acquired water quality monitoring data.
[0030] Different sensors acquire different water quality monitoring data. Since the acquired water quality monitoring data may come from multiple provinces and cities, if we want to monitor the water quality data of a specific city in a certain province, we need to further classify the acquired water quality data and combine the water quality monitoring data of a city acquired from different sensors into one water quality monitoring data category.
[0031] Water quality data from a city can be categorized into one type of water quality data. For example, water quality monitoring data such as water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity collected from different sensors in City A can be categorized into one water quality monitoring data class, while water quality monitoring data such as water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity collected from different sensors in City B can be categorized into another water quality monitoring data class, and so on. This way, water quality monitoring data such as water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity collected from different cities can be categorized into multiple water quality monitoring data classes.
[0032] Step S130: Perform a Class I verification on the water quality monitoring data to determine whether the Class I verification can pass.
[0033] Performing a Class I validation on multiple water quality monitoring data types includes the following sub-steps:
[0034] Step S1301: Perform a type-one verification on each water quality monitoring data in the acquired water quality monitoring data class to determine the type-one fluctuation value corresponding to each water quality monitoring data.
[0035] Taking a water quality monitoring data class as an example, a first-class verification is performed on each water quality monitoring data in the class. Specifically, the first-class fluctuation value P1 of each water quality monitoring data is determined according to the following formula.
[0036]
[0037] Where t represents the time when the current water quality monitoring data (such as water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity) is obtained, and x t x represents the current water quality monitoring data value acquired at time t, where T represents the entire period for acquiring the current water quality monitoring data, K represents the entire period for acquiring the current water quality monitoring data at a specific historical record, and k represents the time at which the current water quality monitoring data (e.g., one of water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity) was acquired at a specific historical record. k This represents the data value of the current water quality monitoring data acquired at time k.
[0038] Step S1302: Determine whether all fluctuation values corresponding to each water quality monitoring data can pass the verification.
[0039] If the fluctuation value P1 corresponding to each water quality monitoring data does not exceed the specified threshold, then the current water quality monitoring data in the current time period T is considered to be normal, the verification is passed, and step S150 is executed.
[0040] If a fluctuation value P1 exceeds a specified threshold, it is considered that the current water quality monitoring data in the water quality monitoring data class acquired within time T may be abnormal, and step S140 is executed.
[0041] The above method can obtain multiple Class I fluctuation values. Each water quality monitoring data corresponds to a Class I fluctuation value. For example, if the current water quality monitoring data is water temperature data, and its Class I fluctuation value P1 has exceeded the specified threshold, then the water temperature data obtained in the entire cycle may be abnormal. In this case, it is not necessary to confirm the Class I fluctuation values of other water quality monitoring data. Instead, Class II verification can be performed directly. Through Class II verification, it can be directly determined whether there is an abnormality in the water quality.
[0042] Step S140: Perform a second-class verification on the water quality monitoring data to determine whether the second-class verification can pass.
[0043] The current water quality monitoring data that may be abnormal (such as one of the following: water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity) will be subject to a Class II verification.
[0044] The Type II fluctuation value P2 of the current water quality monitoring data (such as water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity) is determined according to the following formula.
[0045] P2 = x t -x t-1 / x t-1
[0046] x t x represents the data value of the current water quality monitoring data acquired at time t. t-1 This represents the data value of the current water quality monitoring data acquired at time t-1.
[0047] Based on the determined Class II fluctuation value P2, if the Class II fluctuation value P2 is greater than the specified threshold, it may indicate that drastic biological or chemical changes have occurred in the water body. In this case, the Class II verification fails, and the monitoring result of water quality anomaly is directly output. If the Class II fluctuation value P2 is less than the specified threshold, it is considered that the current water quality is still in a normal state. In this case, the Class II verification passes, and step S150 is executed.
[0048] By using type II verification, abnormal fluctuations such as the type II fluctuation value P2 of water temperature data can be identified. If the type II fluctuation value P2 is greater than the specified threshold, the monitoring result of water quality abnormality will be directly output.
[0049] The above-mentioned monitoring methods, which use Class I and Class II verification to confirm whether there are any abnormalities in water quality, can first conduct a simple monitoring of water quality, providing further assurance for subsequent water quality monitoring.
[0050] Step S150: Perform deep learning, determine the deep learning generation error, and output the water quality anomaly detection result based on the generation error.
[0051] If no anomalies are detected in either the Type I or Type II verification, deep learning is performed based on the acquired water quality monitoring data. Step S150 specifically includes the following sub-steps:
[0052] Step S1501: Construct a deep learning model.
[0053] The deep learning model constructed in this embodiment is a recurrent neural network (RNN). RNN has a cyclic structure, can process time series data, and can capture the time dependencies in the data.
[0054] Specifically, RNNs can monitor time-series data in water quality monitoring, such as changes in water temperature, dissolved oxygen, and pH over time. They can learn the trends and periodicity of water quality parameter changes, predict future water quality conditions, and promptly detect anomalies. For continuously monitored water quality data, RNNs and their variants can be used for real-time anomaly detection, improving the timeliness and accuracy of monitoring.
[0055] Step S1502: Input multiple water quality monitoring data classes into the deep learning model respectively, and determine the predicted values of multiple water quality monitoring data in each water quality monitoring data class.
[0056] Before determining the predicted values of water quality monitoring data based on the deep learning model, the process also includes training the deep learning model. After training, the water quality monitoring data from each water quality monitoring data class are input into the deep learning model.
[0057] The deep learning model establishes a mapping relationship between input water quality monitoring data and output predicted water quality status by learning from a large amount of normal water quality data. When new water quality monitoring data is input into the trained model, the deep learning model will generate corresponding prediction values based on the input water quality monitoring data.
[0058] Step S1503: Determine the deep learning error based on the predicted values of the water quality monitoring data.
[0059] The difference between the actual water quality monitoring data and the corresponding predicted value output by the model based on that data is the error generated by deep learning. Suppose a deep learning model has been trained on a large amount of normal water quality parameter data, such as water temperature, pH, and dissolved oxygen. When a new set of water quality parameter data is input into the model, it will predict the corresponding water quality state or parameter value. If there is a difference between the actual water quality parameter and the model's predicted value, this difference is the error.
[0060] The errors include mean square error and mean absolute error.
[0061] Mean squared error (MSE) assigns higher weights to larger errors, making it more sensitive to outliers. Therefore, this embodiment uses MSE as the deep learning error, where the deep learning error MSE is denoted as... Where n is the number of data points in the current water quality monitoring data, Y i This represents the actual value of the current water quality monitoring data. This represents the predicted value of the current water quality monitoring data.
[0062] Step S1504: Output the water quality anomaly monitoring results based on the deep learning error.
[0063] By analyzing the magnitude, distribution, and trend of errors, it is possible to determine whether water quality data is abnormal. If the deep learning error exceeds a pre-set threshold range, it indicates an abnormality in water quality, and the water quality anomaly monitoring result is output.
[0064] This application first monitors water quality data to different degrees using the aforementioned Type I and Type II verification methods, and then further monitors water quality data that did not detect any abnormalities using deep learning. The water quality anomaly monitoring method of this application greatly improves the accuracy and reliability of water quality monitoring.
[0065] Example 2
[0066] like Figure 2 As shown, this embodiment provides a water quality anomaly data monitoring system based on deep learning-generated errors, specifically including: a water quality monitoring data acquisition unit 210, a water quality monitoring data class determination unit 220, a first-class verification unit 230, a second-class verification unit 240, and a deep learning unit 250.
[0067] Water quality monitoring data acquisition unit 210 is used to acquire water quality monitoring data.
[0068] Specifically, water quality monitoring data is obtained from various sensors. This data includes water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity. The sensors include: a temperature sensor, a pH sensor, a dissolved oxygen sensor, a turbidity sensor, and a conductivity sensor.
[0069] Temperature sensors typically employ technologies such as thermistors, thermocouples, or semiconductor temperature sensors. They determine temperature by measuring changes in the heat conduction or resistance of water. Water temperature has a significant impact on the survival and reproduction of aquatic organisms, the rate of chemical reactions, and the physical properties of water. For example, different species of fish have specific temperature tolerance ranges; excessively high or low temperatures can lead to fish mortality.
[0070] pH sensors use glass electrodes or other types of electrodes to measure the concentration of hydrogen ions in water. The potential generated by the electrode is logarithmically related to the hydrogen ion concentration, and the pH value can be determined through calibration. The pH value reflects the acidity or alkalinity of the water. A suitable pH value is crucial for the health of aquatic life and also affects the solubility and toxicity of chemicals in the water. For example, acidic water can lead to increased dissolution of metal ions, which can be toxic to aquatic organisms.
[0071] Dissolved oxygen sensors determine dissolved oxygen concentration using both electrochemical and optical methods. Electrochemical dissolved oxygen sensors determine concentration by measuring the current between electrodes, while optical dissolved oxygen sensors utilize the principles of fluorescence or optical absorption. Dissolved oxygen is a crucial indicator of water quality. It is essential for the respiration and survival of aquatic organisms and also affects the decomposition of organic matter and the cycling of nutrients in the water. For example, low dissolved oxygen levels can lead to fish suffocation and death, while high dissolved oxygen levels promote the activity of aerobic microorganisms and accelerate the decomposition of organic matter.
[0072] Turbidity sensors determine turbidity by measuring the scattering or absorption of light by suspended particles in water. Common turbidity sensors include scattering-type and transmission-type turbidity sensors. Turbidity reflects the amount of suspended particles in water. High turbidity in water can affect the vision and respiration of aquatic organisms and may also carry pathogens and pollutants. For example, reducing turbidity is an important step in drinking water treatment.
[0073] Conductivity sensors measure conductivity based on the electrical conductivity of water. Conductivity is directly proportional to the concentration of dissolved ions in water. Conductivity reflects the amount of dissolved salts in water. It is important for assessing water hardness, salinity, and the composition of ions in water. For example, water with high conductivity may be unsuitable for certain industrial uses or agricultural irrigation.
[0074] The water quality monitoring data class determination unit 220 is used to determine the water quality monitoring data class based on the acquired water quality monitoring data.
[0075] Different sensors acquire different water quality monitoring data. Since the acquired water quality monitoring data may come from multiple provinces and cities, if we want to monitor the water quality data of a specific city in a certain province, we need to further classify the acquired water quality data and combine the water quality monitoring data of a city acquired from different sensors into one water quality monitoring data category.
[0076] Water quality data from a city can be categorized into one type of water quality data. For example, water quality monitoring data such as water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity collected from different sensors in City A can be categorized into one water quality monitoring data class, while water quality monitoring data such as water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity collected from different sensors in City B can be categorized into another water quality monitoring data class, and so on. This way, water quality monitoring data such as water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity collected from different cities can be categorized into multiple water quality monitoring data classes.
[0077] The first-class verification unit 230 is used to perform a first-class verification on water quality monitoring data and determine whether the first-class verification can pass.
[0078] The first type of verification unit 230 includes the following sub-modules: fluctuation value determination module and judgment module.
[0079] The fluctuation value determination module performs a type I verification on each water quality monitoring data in the acquired water quality monitoring data class to determine the corresponding type I fluctuation value for each water quality monitoring data. Taking a water quality monitoring data class as an example, a type I verification is performed on each water quality monitoring data in this class, specifically determining the type I fluctuation value P1 for each water quality monitoring data according to the following formula.
[0080]
[0081] Where t represents the time when the current water quality monitoring data (such as water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity) is obtained, and x t x represents the current water quality monitoring data value acquired at time t, where T represents the entire period for acquiring the current water quality monitoring data, K represents the entire period for acquiring the current water quality monitoring data at a specific historical record, and k represents the time at which the current water quality monitoring data (e.g., one of water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity) was acquired at a specific historical record. k This represents the data value of the current water quality monitoring data acquired at time k.
[0082] The judgment module determines whether all fluctuation values corresponding to each water quality monitoring data point can pass the verification.
[0083] If none of the first-class fluctuation values P1 corresponding to each water quality monitoring data do not exceed the specified threshold, then the current water quality monitoring data in the current water quality monitoring data within the current time period T is considered normal, and the verification passes, and deep learning unit 250 is executed. If there is a first-class fluctuation value P1 that exceeds the specified threshold, then the current water quality monitoring data in the water quality monitoring data class acquired within the time period T is considered to be abnormal, and second-class verification unit 240 is executed.
[0084] The above method can obtain multiple Class I fluctuation values. Each water quality monitoring data corresponds to a Class I fluctuation value. For example, if the current water quality monitoring data is water temperature data, and its Class I fluctuation value P1 has exceeded the specified threshold, then the water temperature data obtained in the entire cycle may be abnormal. In this case, it is not necessary to confirm the Class I fluctuation values of other water quality monitoring data. Instead, Class II verification can be performed directly. Through Class II verification, it can be directly determined whether there is an abnormality in the water quality.
[0085] The second-class verification unit 240 is used to perform second-class verification on water quality monitoring data to determine whether the second-class verification can pass.
[0086] Type II verification is performed on potentially abnormal current water quality monitoring data (e.g., one of water temperature, pH, dissolved oxygen concentration, turbidity, and conductivity). The Type II fluctuation value P2 of the current water quality monitoring data (e.g., one of water temperature, pH, dissolved oxygen concentration, turbidity, and conductivity) is determined according to the following formula.
[0087] P2 = x t -x t-1 / x t-1
[0088] x t x represents the data value of the current water quality monitoring data acquired at time t. t-1 This represents the current water quality monitoring data value acquired at time t-1. Based on the determined Type II fluctuation value P2, if P2 is greater than a specified threshold, it may indicate a drastic biological or chemical change in the water body, in which case the Type II check fails, and the monitoring result of water quality anomaly is directly output. If P2 is less than the specified threshold, the current water quality is considered to be in a normal state, the Type II check passes, and deep learning unit 250 is executed.
[0089] By using type II verification, abnormal fluctuations such as the type II fluctuation value P2 of water temperature data can be identified. If the type II fluctuation value P2 is greater than the specified threshold, the monitoring result of water quality abnormality will be directly output.
[0090] The above-mentioned monitoring methods, which use Class I and Class II verification to confirm whether there are any abnormalities in water quality, can first conduct a simple monitoring of water quality, providing further assurance for subsequent water quality monitoring.
[0091] The deep learning unit 250 is used to perform deep learning, determine the deep learning generation error, and output the water quality anomaly detection results based on the generation error.
[0092] If no anomalies are detected in the first and second type of verification, deep learning is performed based on the acquired water quality monitoring data. The deep learning unit 250 includes the following sub-modules: construction module, prediction value determination module, learning error determination module, and monitoring result output module.
[0093] Builder modules are used to build deep learning models.
[0094] The deep learning model constructed in this embodiment is a Recurrent Neural Network (RNN). RNNs, with their recurrent structure, can process time-series data and capture temporal dependencies within the data. Specifically, RNNs can monitor time-series data in water quality monitoring, such as changes in water temperature, dissolved oxygen, and pH over time. They can learn the trends and periodicity of water quality parameter changes, predict future water quality conditions, and promptly detect anomalies. For continuously monitored water quality data, RNNs and their variants can be used for real-time anomaly detection, improving the timeliness and accuracy of monitoring.
[0095] The prediction value determination module is used to input multiple water quality monitoring data classes into a deep learning model to determine the predicted values of multiple water quality monitoring data in each class. Before determining the predicted values of the water quality monitoring data based on the deep learning model, the module also includes training the deep learning model. After training, the water quality monitoring data from each class is input into the deep learning model.
[0096] The deep learning model establishes a mapping relationship between input water quality monitoring data and output predicted water quality status by learning from a large amount of normal water quality data. When new water quality monitoring data is input into the trained model, the deep learning model will generate corresponding prediction values based on the input water quality monitoring data.
[0097] The learning error determination module is used to determine the deep learning error based on the predicted values of water quality monitoring data.
[0098] The difference between the actual water quality monitoring data and the corresponding predicted value output by the model based on that data constitutes the error generated by deep learning. Assume a deep learning model has been trained on a large amount of normal water quality parameter data, such as temperature, pH, and dissolved oxygen. When a new set of water quality parameter data is input into the model, it predicts the corresponding water quality state or parameter value. If there is a difference between the actual water quality parameter and the model's predicted value, this difference is the error. Errors include mean squared error (MSE) and mean absolute error (MAE). MSE gives higher weight to larger errors, making it more sensitive to outliers. Therefore, this embodiment uses MSE as the deep learning error, where the deep learning error MSE is denoted as... Where n is the number of data points in the current water quality monitoring data, Y i This represents the actual value of the current water quality monitoring data. This represents the predicted value of the current water quality monitoring data.
[0099] The monitoring result output module is used to output water quality anomaly monitoring results based on deep learning errors.
[0100] By analyzing the magnitude, distribution, and trend of errors, it is possible to determine whether water quality data is abnormal. If the deep learning error exceeds a pre-set threshold range, it indicates an abnormality in water quality, and the water quality anomaly monitoring result is output.
[0101] This application first monitors water quality data to different degrees using the aforementioned Type I and Type II verification methods, and then further monitors water quality data that did not detect any abnormalities using deep learning. The water quality anomaly monitoring method of this application greatly improves the accuracy and reliability of water quality monitoring.
[0102] This application also provides a computer storage medium storing computer instructions, which, when invoked, are used to execute the water quality anomaly data monitoring method based on deep learning-generated errors.
[0103] The embodiments disclosed in this invention provide a computer-readable storage medium storing computer program instructions. When the computer program instructions are executed on a computer, the computer performs the aforementioned method for monitoring water quality anomaly data based on deep learning-generated errors.
[0104] This invention provides a processor for processing the above-described method for monitoring water quality anomaly data based on deep learning-generated errors.
[0105] In this embodiment of the invention, the processor can be an integrated circuit chip with signal processing capabilities. The processor can be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0106] The various methods, steps, and logic diagrams disclosed in the embodiments of this invention can be implemented or executed. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of this invention can be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software modules can reside in random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. The processor reads information from the storage medium and, in conjunction with its hardware, completes the steps of the above methods.
[0107] The storage medium can be memory, such as volatile memory or non-volatile memory, or may include both volatile and non-volatile memory.
[0108] The non-volatile memory can be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EEPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. The volatile memory can be random access memory (RAM), which is used as an external cache. By way of example, but not limitation, many forms of RAM are available, such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDRSDRAM), Enhanced Synchronous DRAM (ESDRAM), Synchlink DRAM (SLDRAM), and Direct Rambus RAM (DRRAM).
[0109] This application has the following beneficial effects:
[0110] This application proposes a method for performing Class I and Class II verification on water quality data. First, water quality data is monitored to different degrees, and then deep learning is used to further monitor water quality data that does not detect any anomalies. The water quality anomaly monitoring method of this application greatly improves the accuracy and reliability of water quality monitoring.
[0111] Although the examples referenced in this application are described for illustrative purposes only and not for limiting the scope of this application, changes, additions and / or deletions to the implementation may be made without departing from the scope of this application.
[0112] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for monitoring water quality anomaly data based on deep learning-generated error, characterized in that, Includes the following steps: Obtain water quality monitoring data; The water quality monitoring data type is determined based on the acquired water quality monitoring data. A first-class verification is performed on the water quality monitoring data to determine whether the first-class verification can be passed. If the first type of verification fails, the water quality monitoring data will be subjected to a second type of verification to determine whether the second type of verification can pass. If the second type of verification passes, deep learning is performed to determine the deep learning generation error, and the water quality anomaly detection result is output based on the generation error. Performing a Class I validation on water quality monitoring data and determining whether the validation passes includes the following sub-steps: Each water quality monitoring data point in the acquired water quality monitoring data class is subjected to a type of verification to determine the type of fluctuation value corresponding to each water quality monitoring data point. Determine whether all fluctuation values corresponding to each water quality monitoring data point can pass the verification. If all verifications pass, deep learning is performed to determine the deep learning generation error, and the water quality anomaly detection results are output based on the generation error. One type of fluctuation value Represented as: ; t represents the time when the current water quality monitoring data is acquired. This represents the current water quality monitoring data value acquired at time t, where T represents the entire period for acquiring the current water quality monitoring data, K represents the entire period for acquiring the current water quality monitoring data at a specific historical record, and k represents the time when the current water quality monitoring data was acquired at a specific historical record. This represents the current water quality monitoring data value acquired at time k; If each water quality monitoring data corresponds to a type of fluctuation value If all values do not exceed the specified threshold, then the current water quality monitoring data within the current time period T is considered normal, and the verification passes. If the current water quality monitoring data shows a type of fluctuation value If the specified threshold is exceeded, the current water quality monitoring data is considered abnormal, and a second-class verification is performed on the current water quality monitoring data. Type II verification includes identifying Type II fluctuation values in current water quality monitoring data that are abnormal. Specifically, it is expressed as: ; This represents the data value of the current water quality monitoring data acquired at time t. This represents the data value of the current water quality monitoring data acquired at time t-1; If the second type of fluctuation value If the value exceeds the specified threshold, the Class II verification fails, and the monitoring result of water quality anomaly is directly output; if the Class II fluctuation value... If the value is less than the specified threshold, the second-order verification passes, and deep learning is then performed to determine the deep learning generation error. Based on the generation error, the water quality anomaly detection result is output.
2. The water quality anomaly data monitoring method based on deep learning-generated error as described in claim 1, characterized in that, If one type of verification passes, deep learning is then performed to determine the deep learning generation error, and the water quality anomaly detection result is output based on the generation error.
3. The water quality anomaly data monitoring method based on deep learning-generated error as described in claim 1, characterized in that, If the Class II verification fails, the water quality anomaly detection result will be output.
4. The water quality anomaly data monitoring method based on deep learning-generated error as described in claim 1, characterized in that, Acquiring water quality monitoring data includes acquiring water quality monitoring data from multiple sensors; Water quality monitoring data includes water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity data; Multiple sensors include: a temperature sensor, a pH sensor, a dissolved oxygen sensor, a turbidity sensor, and a conductivity sensor.
5. The water quality anomaly data monitoring method based on deep learning-generated error as described in claim 1, characterized in that, The water quality monitoring data class is determined based on the acquired water quality monitoring data, which includes water quality monitoring data of a city obtained from different sensors as one water quality monitoring data class.
6. A water quality anomaly data monitoring system based on deep learning-generated error, characterized in that, Specifically, it includes: The system includes a water quality monitoring data acquisition unit, a water quality monitoring data class determination unit, a first-class verification unit, a second-class verification unit, and a deep learning unit. Water quality monitoring data acquisition unit, used to acquire water quality monitoring data; The water quality monitoring data class determination unit is used to determine the water quality monitoring data class based on the acquired water quality monitoring data. A first-class verification unit is used to perform a first-class verification on water quality monitoring data to determine whether the first-class verification can pass. If the first type of verification fails, the second type of verification will be performed on the water quality monitoring data of the second type of verification unit to determine whether the second type of verification can pass. If the second type of verification passes, the deep learning unit performs deep learning to determine the deep learning generation error and outputs the water quality anomaly detection result based on the generation error. Performing a Class I validation on water quality monitoring data and determining whether the validation passes includes the following sub-steps: Each water quality monitoring data point in the acquired water quality monitoring data class is subjected to a type of verification to determine the type of fluctuation value corresponding to each water quality monitoring data point. Determine whether all fluctuation values corresponding to each water quality monitoring data point can pass the verification. If all verifications pass, deep learning is performed to determine the deep learning generation error, and the water quality anomaly detection results are output based on the generation error. One type of fluctuation value Represented as: ; t represents the time when the current water quality monitoring data is acquired. This represents the current water quality monitoring data value acquired at time t, where T represents the entire period for acquiring the current water quality monitoring data, K represents the entire period for acquiring the current water quality monitoring data at a specific historical record, and k represents the time when the current water quality monitoring data was acquired at a specific historical record. This represents the current water quality monitoring data value acquired at time k; If each water quality monitoring data corresponds to a type of fluctuation value If all values do not exceed the specified threshold, then the current water quality monitoring data within the current time period T is considered normal, and the verification passes. If the current water quality monitoring data shows a type of fluctuation value If the specified threshold is exceeded, the current water quality monitoring data is considered abnormal, and a second-class verification is performed on the current water quality monitoring data. Type II verification includes identifying Type II fluctuation values in current water quality monitoring data that are abnormal. Specifically, it is expressed as: ; This represents the data value of the current water quality monitoring data acquired at time t. This represents the data value of the current water quality monitoring data acquired at time t-1; If the second type of fluctuation value If the value exceeds the specified threshold, the Class II verification fails, and the monitoring result of water quality anomaly is directly output; if the Class II fluctuation value... If the value is less than the specified threshold, the second-order verification passes, and deep learning is then performed to determine the deep learning generation error. Based on the generation error, the water quality anomaly detection result is output.
7. The water quality anomaly data monitoring system based on deep learning-generated error as described in claim 6, characterized in that, If one type of verification passes, the deep learning unit performs deep learning to determine the deep learning generation error, and outputs the water quality anomaly detection result based on the generation error.
8. The water quality anomaly data monitoring system based on deep learning-generated error as described in claim 6, characterized in that, If the Class II verification of the Class II verification unit fails, the water quality anomaly detection result will be output.
9. The water quality anomaly data monitoring system based on deep learning-generated error as described in claim 6, characterized in that, The water quality monitoring data acquisition unit acquires water quality monitoring data by acquiring water quality monitoring data from multiple sensors; Water quality monitoring data includes water temperature, pH value, dissolved oxygen concentration, turbidity, and conductivity data; Multiple sensors include: a temperature sensor, a pH sensor, a dissolved oxygen sensor, a turbidity sensor, and a conductivity sensor.
10. The water quality anomaly data monitoring system based on deep learning-generated error as described in claim 6, characterized in that, The water quality monitoring data class determination unit determines the water quality monitoring data class based on the acquired water quality monitoring data, including water quality monitoring data of a city acquired from different sensors as a water quality monitoring data class.
Citation Information
Patent Citations
Water quality monitoring control method and system
CN118861642A
System and method for detecting anomalous state of motor through two-step ai analysis
WO2024122695A1