Intelligent water affair sewage monitoring and processing method
By collecting wastewater treatment data in real time through sensor networks and machine learning algorithms, and dynamically adjusting process parameters, the problem of decision lag in existing systems is solved, achieving rapid response and stability in wastewater treatment, and reducing the risk of environmental pollution.
Patent Information
- Application Number
- CN202510876862.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-27
- Publication Date
- 2025-10-28
Smart Images

Figure CN120850141A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of wastewater treatment technology, and in particular to a smart water management wastewater monitoring and treatment method. Background Technology
[0002] With the continuous development of sensor technology, the Internet of Things and big data analytics, big data analytics and decision support systems have been widely used in the field of wastewater monitoring and treatment. The aim is to achieve precise control and scientific decision-making in the wastewater treatment process through the analysis of massive amounts of monitoring data.
[0003] However, existing big data analytics and decision support systems face technical challenges in practical applications, including ensuring real-time processing and analysis of the latest monitoring data to promptly adjust decisions in response to sudden water quality changes and anomalies during treatment. On one hand, wastewater monitoring generates large volumes of water quality data and equipment operation data collected in real time by sensors, with high update frequencies. Traditional data processing and analysis methods often struggle to effectively process and deeply analyze this real-time data within a short period, preventing decision support systems from obtaining accurate analysis results in a timely manner, thus affecting the timeliness and effectiveness of decisions. On the other hand, wastewater treatment is complex, and water quality changes can be influenced by various factors, such as sudden discharges of industrial wastewater or cross-contamination caused by heavy rain. These emergencies require decision support systems to quickly identify abnormal data and adjust treatment strategies in real time based on the latest monitoring data. However, existing systems, due to data processing delays and insufficient adaptability of analytical models, struggle to achieve rapid and accurate decision adjustments when dealing with emergencies, potentially leading to decreased wastewater treatment effectiveness or even environmental pollution risks. Summary of the Invention
[0004] In view of this, the present invention proposes a smart water management wastewater monitoring and treatment method, which can process and analyze the latest monitoring data in real time, make timely decision adjustments, and respond to sudden changes in water quality and abnormal situations in the treatment process, thereby improving the wastewater treatment effect.
[0005] The technical solution of this invention is implemented as follows:
[0006] A smart water management wastewater monitoring and treatment method includes the following steps:
[0007] Step S1: Collect water quality parameter data, equipment operation status data, and environmental data in real time through a sensor network deployed in the wastewater treatment facility;
[0008] Step S2: Perform data preprocessing and feature extraction on the water quality parameter data, the equipment operating status data, and the environmental data to generate a preprocessed dataset and key features;
[0009] Step S3: Using the preprocessed dataset and key features, a machine learning model is used to identify water quality anomalies and equipment malfunctions, and an early warning signal is generated.
[0010] Step S4: Based on the warning signal and the historical processing strategy library, dynamically adjust the wastewater treatment process parameters through reinforcement learning algorithm, generate control commands and send them to the execution equipment;
[0011] Step S5: Based on the execution feedback data corresponding to the control command and the expert knowledge base, optimize the parameters in the machine learning model, the historical processing strategy library, and the reinforcement learning algorithm.
[0012] Optionally, the sensor network deployed in step S1 includes multiple distributed multimodal sensor nodes and edge computing units;
[0013] The distributed multimodal sensor node integrates environmental detection sensors, electrochemical sensors, optical sensors, and biological sensors to synchronously collect data on equipment operating status parameters, environmental parameters, water quality parameters, including chemical oxygen demand (COD), biochemical oxygen demand (BOD), total phosphorus (TP), total nitrogen (TN), and microbial community structure.
[0014] The edge computing unit is deployed locally on the distributed multimodal sensor node to execute data dimensionality reduction algorithms in real time, compressing the original parameters into feature vectors to generate water quality parameter data, equipment operating status data, and environmental data.
[0015] Optionally, the environmental data collected by the sensor network in step S1 includes meteorological data, geographic information data, and social environmental analysis data;
[0016] The meteorological data is generated by acquiring real-time data on rainfall, temperature, wind speed, and atmospheric humidity through miniature weather stations deployed around the sewage treatment plant.
[0017] The spatial topology and water level change data of the sewage pipe network are obtained through the positioning module to generate geographic information data.
[0018] The social environmental analysis data is generated by real-time analysis of relevant information in social media and environmental department announcements using natural language processing algorithms.
[0019] Optionally, the specific steps of step S2 are as follows:
[0020] Step S21: Perform nanosecond-level synchronous calibration on the water quality parameter data, the equipment operating status data, and the environmental data to generate water quality calibration data, equipment operating status calibration data, and environmental calibration data;
[0021] Step S22: Use the Kalman filter algorithm to smooth the abrupt values in the water quality calibration data to generate water quality cleaning data;
[0022] Step S23: Decompose the high-frequency noise components in the equipment operation status calibration data by wavelet transform to generate equipment operation status cleaning data;
[0023] Step S24: Construct a preprocessed dataset using the environmental calibration data, the water quality cleaning data, and the equipment operating status cleaning data;
[0024] Step S25: Use a graph neural network to extract features from the preprocessed dataset and generate key features.
[0025] Optionally, the specific steps of step S24 are as follows:
[0026] Step S241: Map the water quality cleaning data, equipment operation status cleaning data, and environmental calibration data to the three-dimensional spatial grid corresponding to the sensor network to generate the target three-dimensional spatial grid;
[0027] Step S242: Employ a spatiotemporal attention mechanism to assign dynamic weights to different types of data within the same grid in the target 3D spatial grid, generating multiple spatiotemporal fusion feature vectors;
[0028] Step S243: Extract the temporal features from the spatiotemporal fusion feature vector using a sliding window and construct a matrix to generate an initial temporal feature matrix;
[0029] Step S244: Add the preset lag features to the initial time series feature matrix to generate the target time series feature matrix;
[0030] Step S245: Identify water quality anomalies in the target time-series feature matrix according to the water quality thresholds in the expert knowledge base, and generate potential anomaly data;
[0031] Step S246: Use the Isolation Forest algorithm to perform secondary detection on the potential abnormal data, identify outliers in the data, and generate a preprocessed dataset containing normal data and abnormal markers.
[0032] Optionally, the specific steps of step S3 are as follows:
[0033] Step S31: Use the random forest algorithm to perform preliminary classification of water quality anomalies and equipment failures on the preprocessed dataset to generate initial identification data;
[0034] Step S32: Use a gradient boosting machine to iteratively correct the classification error of the preliminary identification data to generate target identification data;
[0035] Step S33: Construct an early warning signal corresponding to the target recognition data according to the feature importance weights in the expert knowledge base.
[0036] Optionally, the specific steps of step S33 are as follows:
[0037] Step S331: Weight the feature values in the target recognition data with the corresponding feature importance weights in the expert knowledge base to obtain a comprehensive score;
[0038] Step S332: Map the comprehensive score to different levels of early warning signals according to the preset risk level threshold range;
[0039] Step S333: When the target identification data has multiple abnormal features, the weighted abnormality degree is calculated by using the weight of each abnormal feature, and combined with the corresponding early warning signal to construct a composite early warning signal.
[0040] Optionally, the specific steps of step S4 are as follows:
[0041] Step S41: Use the warning signal and the state-action pairs in the historical processing strategy library as input to construct the environment state space for reinforcement learning;
[0042] Step S42: Explore strategies in the environmental state space using a deep Q-network model to generate process parameter adjustment data;
[0043] Step S43: Adjust the data and corresponding real-time feedback data according to the process parameters, update the Q-value function of the deep Q-network model, generate control commands and send them to the execution device.
[0044] Optionally, the specific steps of step S43 are as follows:
[0045] Step S431: According to the urgency level of the warning signal, a multi-level priority scheduling algorithm is used to allocate the process parameter adjustment weights corresponding to the process parameter adjustment data;
[0046] Step S432: Map the process parameter adjustment weights to specific process parameter values using a fuzzy logic controller;
[0047] Step S433: Encapsulate the process parameter values into standardized control commands and send them to the execution device via the Industrial Internet of Things protocol.
[0048] Optionally, the specific steps of step S5 are as follows:
[0049] Step S51: According to the execution feedback data corresponding to the control command, the machine learning model is incrementally trained using an online learning algorithm to generate an optimized machine learning model;
[0050] Step S52: Adjust the process parameters according to the effect in the execution feedback data, and dynamically optimize the hyperparameters in the reinforcement learning algorithm using a genetic algorithm to generate an optimized reinforcement learning algorithm;
[0051] Step S53: Combine the historical optimization records in the expert knowledge base, perform similarity matching on the strategies in the historical processing strategy library, and generate an updated historical processing strategy library.
[0052] Compared with the prior art, the beneficial effects of the present invention are:
[0053] This invention utilizes a sensor network deployed in wastewater treatment facilities to achieve millisecond-level real-time acquisition of water quality parameters, equipment operating status, and environmental data. This avoids the data lag problems caused by traditional manual inspections or timed sampling, laying a data foundation for rapid response to emergencies. The water quality parameter data, equipment operating status data, and environmental data are preprocessed and feature extracted to generate a preprocessed dataset and key features, transforming redundant data into high-value decision-making information. A machine learning model uses the preprocessed dataset and key features to identify water quality anomalies and equipment malfunctions, generating early warning signals. Compared to traditional threshold alarm methods, the machine learning model can learn complex association rules from historical data, reducing false alarm rates and providing early warnings of potential risks. Based on the early warning signals and a historical treatment strategy library, a reinforcement learning algorithm dynamically adjusts wastewater treatment process parameters, generating control commands and issuing them to the execution equipment. Based on feedback data from the execution equipment and an expert knowledge base, closed-loop optimization is performed on the machine learning model parameters, the historical treatment strategy library, and the reinforcement learning algorithm hyperparameters. This invention achieves a short latency throughout the entire process from data acquisition to decision execution, avoiding decision lag caused by traditional manual analysis or fixed models. This not only ensures the stability of wastewater treatment results, but also enables rapid response in emergencies, reducing the risk of environmental pollution. Attached Figure Description
[0054] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only preferred embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0055] Figure 1 This is a flowchart of a smart water management wastewater monitoring and treatment method according to the present invention;
[0056] Figure 2 This is a flowchart of step S2 of a smart water wastewater monitoring and treatment method according to the present invention;
[0057] Figure 3 This is a flowchart of step S3 of a smart water wastewater monitoring and treatment method according to the present invention;
[0058] Figure 4 This is a flowchart of step S4 of a smart water wastewater monitoring and treatment method according to the present invention;
[0059] Figure 5 This is a flowchart of step S5 of a smart water wastewater monitoring and treatment method according to the present invention. Detailed Implementation
[0060] To better understand the technical content of this invention, a specific embodiment is provided below, and the invention will be further described in conjunction with the accompanying drawings.
[0061] like Figure 1 The diagram shows a process flow diagram of an energy storage method for gas production.
[0062] In this embodiment of the invention, a sensor network deployed in a wastewater treatment facility collects water quality parameter data, equipment operating status data, and environmental data in real time. The sensor network includes multiple distributed multimodal sensor nodes (integrating environmental monitoring, electrochemical, optical, and biological sensors) and edge computing units.
[0063] By aligning water quality parameter data, equipment operating status data, and environmental data using nanosecond-level timestamps, calibrated data (such as water quality calibration data, equipment operating status calibration data, and environmental calibration data) is generated. Kalman filtering is used to smooth abrupt changes (such as sudden COD spikes) to generate water quality cleaning data. Wavelet transform is used to decompose high-frequency noise (such as pump pressure fluctuations) in the equipment operating status calibration data to generate equipment operating status cleaning data. The water quality cleaning data, equipment operating status cleaning data, and environmental calibration data are mapped to a 3D spatial grid (such as a pipeline topology) to generate a target 3D spatial grid. A spatiotemporal attention mechanism is used to assign dynamic weights to data within the same grid (e.g., higher weight for environmental data) to generate a spatiotemporal fusion feature vector. Temporal features of the spatiotemporal fusion feature vector are extracted using a sliding window to construct an initial temporal feature matrix. Preset lag features (such as historical COD values) are added to generate the target temporal feature matrix. Potentially abnormal data is identified by combining water quality thresholds from an expert knowledge base (e.g., COD > 100 mg / L is considered abnormal). An isolated forest algorithm is used for secondary outlier detection to generate a preprocessed dataset containing both normal data and outlier markers. A graph neural network is then used to extract features from the preprocessed dataset, generating key features.
[0064] The preprocessed dataset is classified using a random forest algorithm to generate initial identification data (e.g., COD anomaly markers, pump failure markers). A gradient boosting machine (e.g., XGBoost) iteratively corrects the initial classification error to generate target identification data (e.g., high-confidence anomaly markers). The feature values in the target identification data are weighted and summed with the feature importance weights in the expert knowledge base (e.g., COD weight 0.6, TP weight 0.3) to obtain a comprehensive score. Based on a preset risk level threshold (e.g., a comprehensive score > 80 indicates a red alert), different levels of warning signals (e.g., green, yellow, red) are mapped. When multiple anomalous features exist (e.g., COD and TP are both anomalous), a weighted anomaly score (e.g., 0.6 × COD anomaly score + 0.3 × TP anomaly score) is calculated to generate a composite warning signal.
[0065] The environment state space for reinforcement learning is constructed by using the early warning signal and state-action pairs (e.g., increasing aeration when COD>100) from the historical processing strategy library as input. A deep Q-network (DQN) is used to explore strategies within the environment state space, generating process parameter adjustment data (e.g., aeration increment, reflux ratio adjustment). Based on the urgency level of the early warning signal (e.g., red warning priority), a multi-level priority scheduling algorithm is used to allocate process parameter adjustment weights. A fuzzy logic controller maps the adjustment weights to specific process parameter values (e.g., increasing aeration from 2m³ / h). 3 / s adjusted to 3m 3 / s). The parameter values are encapsulated into standardized control commands (such as JSON format) and sent to the execution devices (such as aerators and return pumps) via industrial IoT protocols (such as Modbus TCP / IP).
[0066] Incremental training of machine learning models is performed using online learning algorithms (such as online random forests) to generate optimized machine learning models (such as more accurate COD prediction models). Hyperparameters of reinforcement learning algorithms (such as the learning rate and discount factor in DQN) are dynamically tuned using genetic algorithms to generate optimized reinforcement learning algorithms. Historical optimization records from an expert knowledge base are combined with similarity matching of strategies in a historical policy library (e.g., similarity between new and old strategies > 80%) to generate an updated historical policy library.
[0067] Preferably, the sensor network deployed in step S1 includes multiple distributed multimodal sensor nodes and edge computing units;
[0068] Distributed multimodal sensor nodes integrate environmental monitoring sensors, electrochemical sensors, optical sensors, and biological sensors to synchronously collect data on equipment operating status parameters, environmental parameters, water quality parameters, including chemical oxygen demand (COD), biochemical oxygen demand (BOD), total phosphorus (TP), total nitrogen (TN), and microbial community structure.
[0069] Edge computing units are deployed locally on distributed multimodal sensor nodes to execute data dimensionality reduction algorithms in real time, compressing raw parameters into feature vectors to generate water quality parameter data, equipment operating status data, and environmental data.
[0070] In this embodiment of the invention, the sensor network includes multiple distributed multimodal sensor nodes and an edge computing unit. The distributed multimodal sensor nodes integrate environmental monitoring sensors, electrochemical sensors, optical sensors, and biosensors. The environmental monitoring sensors detect environmental data such as water level and meteorological conditions corresponding to the wastewater treatment facility. The electrochemical sensors detect water quality parameters such as chemical oxygen demand (COD), biochemical oxygen demand (BOD), total phosphorus (TP), and total nitrogen (TN). The optical sensors monitor optical properties such as turbidity and dissolved oxygen (DO). The biosensors analyze the microbial community structure (e.g., the abundance of bacteria in activated sludge). The edge computing unit is deployed locally on the sensor nodes and executes data dimensionality reduction algorithms (e.g., principal component analysis (PCA)) to compress the raw data into feature vectors, generating standardized water quality parameter data, equipment operating status data (e.g., pump pressure, aeration rate), and environmental data (e.g., water level, meteorological conditions).
[0071] Edge computing units are deployed locally on sensor nodes to execute data dimensionality reduction algorithms, generating standardized datasets. These algorithms employ Principal Component Analysis (PCA) or wavelet transform to compress raw parameters (such as multi-channel sensor data) into feature vectors. For example, raw time-series data for COD, BOD, TP, and TN are reduced to low-dimensional feature vectors (such as mean, variance, and trend slope). These dimensionality-reduced feature vectors are then mapped to water quality parameter data, equipment operating status data, and environmental data in a unified format. For instance, raw data output from different sensors (such as voltage values from electrochemical sensors and light intensity values from optical sensors) are converted to standardized units (such as mg / L, m). 3 / s).
[0072] Preferably, the environmental data collected by the sensor network in step S1 includes meteorological data, geographic information data, and social environmental analysis data;
[0073] By deploying miniature weather stations around the sewage treatment plant, real-time data on rainfall, temperature, wind speed, and atmospheric humidity are obtained to generate meteorological data.
[0074] The spatial topology and water level change data of the sewage pipe network are obtained through the positioning module to generate geographic information data.
[0075] The system uses natural language processing algorithms to analyze relevant information from social media and environmental department announcements in real time, generating social environmental analysis data.
[0076] In this embodiment of the invention, the environmental data collected by the sensor network includes meteorological data, geographic information data, and social environmental analysis data. Meteorological data includes rainfall, temperature, wind speed, and atmospheric humidity. Geographic information data includes the spatial topology of the sewage pipe network and water level change data. Social environmental analysis data is generated by parsing relevant information from social media and environmental department announcements using natural language processing algorithms. Rainfall (mm / h), temperature (°C), wind speed (m / s), and atmospheric humidity (%RH) are acquired in real time using micro-weather stations deployed around the sewage treatment plant to generate meteorological data. The spatial topology of the sewage pipe network (e.g., pipe node coordinates, pipe diameter) and water level change data (m) are acquired using positioning modules (e.g., GPS sensors, GIS systems) to generate geographic information data. Relevant information from social media and environmental department announcements is parsed in real time using natural language processing (NLP) algorithms (e.g., sentiment analysis, entity recognition) to generate social environmental analysis data. The processing flow involves capturing text data (e.g., "Heavy rain in a certain area caused sewage overflow"), extracting keywords (e.g., "heavy rain" and "sewage overflow"), and generating social environmental analysis data.
[0077] Preferred, such as Figure 2 The flowchart shown is a step S2 of an energy storage method for gas production.
[0078] In this embodiment of the invention, water quality parameter data, equipment operating status data, and environmental data are timestamped to eliminate time offsets in multi-source data. Specifically, nanosecond-level timestamps (such as GPS timing or the IEEE 1588 protocol) are used to align the three types of data (water quality, equipment status, and environment) collected by the sensor network, generating water quality calibration data (such as real-time concentration values of COD and BOD), equipment operating status calibration data (such as real-time values of pump pressure and aeration rate), and environmental calibration data (such as real-time values of water level and pipe network topology).
[0079] A Kalman filter algorithm, based on the state-space model of a dynamic system, is used to recursively estimate time-series data, removing abrupt changes (such as transient sensor interference) from water quality calibration data to generate water cleaning data. Wavelet transform is then employed to separate high-frequency noise components in the signal through multi-scale analysis, eliminating high-frequency noise (such as motor vibration interference) from equipment operation status calibration data to generate equipment operation status cleaning data. The water cleaning data, equipment operation status cleaning data, and environmental calibration data are aligned by timestamps to form a multi-dimensional time-series matrix, generating a preprocessed dataset in a unified format. A graph neural network (GNN) is used to model the spatial correlations of the sensor network (such as the topological relationships between nodes in the pipeline network), and then feature extraction is performed on the preprocessed dataset to generate key features.
[0080] Preferably, the specific steps of step S24 are as follows:
[0081] Step S241: Map the water quality cleaning data, equipment operation status cleaning data, and environmental calibration data to the three-dimensional spatial grid corresponding to the sensor network to generate the target three-dimensional spatial grid;
[0082] Step S242: Employ a spatiotemporal attention mechanism to assign dynamic weights to different types of data within the same grid in the target 3D spatial grid, generating multiple spatiotemporal fusion feature vectors;
[0083] Step S243: Extract the temporal features from the spatiotemporal fusion feature vector using a sliding window and construct the matrix to generate the initial temporal feature matrix;
[0084] Step S244: Add the preset lag features to the initial time series feature matrix to generate the target time series feature matrix;
[0085] Step S245: Identify water quality anomalies in the target time-series feature matrix according to the water quality thresholds in the expert knowledge base, and generate potential anomaly data;
[0086] Step S246: Use the Isolation Forest algorithm to perform secondary detection on potential outlier data, identify outliers in the data, and generate a preprocessed dataset containing normal data and outlier labels.
[0087] In this embodiment of the invention, water quality cleaning data (such as smoothed COD and BOD values), equipment operation status cleaning data (such as denoised pump pressure and aeration rate), and environmental calibration data (such as calibrated water level, pipeline topology, and meteorological data) are mapped onto a unified three-dimensional spatial grid based on the spatial distribution of sensor nodes, forming a spatially correlated data structure and obtaining the target three-dimensional spatial grid. For example, if the sensor nodes are distributed in the XYZ coordinate system of the sewage pipeline network, each grid cell stores the COD value, pump pressure value, and water level value at that location. A spatiotemporal attention mechanism is adopted, and dynamic weights for different data types are calculated through a self-attention mechanism. Dynamic weights are assigned to different types of monitoring data within the same grid, and spatial and temporal features are fused to generate multiple spatiotemporal fusion feature vectors (such as weighted COD-water level coupling features).
[0088] A sliding window (e.g., window length of 1 hour, step size of 10 minutes) is used to matrix-encode the spatiotemporal fusion feature vector at each time step (e.g., the covariance matrix of the time series), generating an initial time-series feature matrix (e.g., a three-dimensional tensor of time-space-feature). Preset lag features are historical lag features defined based on an expert knowledge base (e.g., COD values lag behind aeration rate adjustments within a time window). For example, if COD changes lag behind aeration rate adjustments by 1 hour, the preset lag feature is "aeration rate value in the previous hour." The preset lag features are concatenated to the initial time-series feature matrix to generate the target time-series feature matrix (e.g., an extended matrix containing both real-time and historical features). Water quality thresholds are preset thresholds for water quality indicators extracted from the expert knowledge base (e.g., a COD upper limit of 100 mg / L). Each indicator in the target time-series feature matrix is compared with the water quality threshold, and data exceeding the range are marked as potentially abnormal data (e.g., times when COD > 100 mg / L). The Isolation Forest algorithm is used to quickly identify outliers in potential abnormal data by randomly partitioning the feature space, and generate a preprocessed dataset containing normal data and anomaly labels (such as COD data points labeled "abnormal").
[0089] Preferred, such as Figure 3 The flowchart shown is a step S3 of an energy storage method for gas production.
[0090] In this embodiment of the invention, a random forest algorithm is used to perform preliminary classification of the preprocessed dataset by integrating multiple decision trees, identifying water quality anomalies and equipment malfunctions, and generating initial identification data. This initial identification data includes feature vectors of the preliminary classification results (such as "abnormal" or "normal" labels and their probability values). For example, if the COD value exceeds the threshold, the classification result is "water quality abnormal," with a probability value of 0.85.
[0091] Gradient Boosting Machine (GBM) is used to optimize the classification error of the random forest. The classification error is iteratively corrected to generate target recognition data, thereby improving the recognition accuracy. This target recognition data includes the corrected classification results and optimized probability values (e.g., the probability value for "abnormal water quality" is adjusted to 0.92).
[0092] The feature importance weights in the expert knowledge base are preset feature weights (e.g., COD weight 0.4, pump pressure weight 0.3, water level weight 0.3). Based on the target identification data and the feature weights in the expert knowledge base, a graded early warning signal is generated, resulting in an early warning signal corresponding to the target identification data. The specific construction process is as follows: the feature values in the target identification data are multiplied by the preset weights and then summed to generate a comprehensive score. According to the preset threshold range (above 0.85 is "high risk", 0.7-0.85 is "medium risk", and below 0.7 is "low risk"), the comprehensive score is mapped to an early warning signal. If multiple abnormal features exist (e.g., both COD and pump pressure are abnormal), the weighted abnormality degree is calculated (e.g., 0.92×0.4+0.85×0.3=0.668), and combined with the corresponding early warning signal to generate a composite early warning signal (e.g., "high risk (COD+pump pressure)").
[0093] Preferably, the specific steps of step S33 are as follows:
[0094] Step S331: Weight the sum of each feature value in the target recognition data and the corresponding feature importance weight in the expert knowledge base to obtain the comprehensive score;
[0095] Step S332: Map the comprehensive score to different levels of early warning signals according to the preset risk level threshold range;
[0096] Step S333: When the target identification data has multiple abnormal features, the weighted abnormality degree is calculated by using the weight of each abnormal feature, and combined with the corresponding early warning signal to construct a composite early warning signal.
[0097] In this embodiment of the invention, a comprehensive score quantifying the degree of risk is generated by combining the feature values in the target identification data with the feature importance weights in the expert knowledge base through weighted summation. Specifically, the optimized classification results and probability values generated in step S32 (e.g., COD anomaly probability 0.92, pump pressure anomaly probability 0.85) are weighted and summed with the corresponding feature importance weights in the expert knowledge base (e.g., COD weight 0.4, pump pressure weight 0.3, water level weight 0.3) to obtain a comprehensive score (e.g., COD = 0.92 × 0.4 + pump pressure = 0.85 × 0.3 + water level = 0.78 × 0.3 = 0.86).
[0098] The comprehensive score is mapped to a preset risk level range to generate different levels of early warning signals. The mapping logic is as follows: if the comprehensive score is ≥ 0.85, a "high-risk" early warning signal is generated; if 0.7 ≤ comprehensive score < 0.85, a "medium-risk" early warning signal is generated; and if the comprehensive score < 0.7, a "low-risk" early warning signal is generated. For scenarios with multiple anomalies, a composite early warning signal containing multiple anomalies is generated. The weights of multiple anomalies are summed to generate a weighted anomaly score (e.g., COD = 0.4 + pump pressure = 0.3 = 0.7). The weighted anomaly score is combined with the corresponding early warning signal to generate a composite early warning signal (e.g., "high-risk (COD + pump pressure)").
[0099] Preferred, such as Figure 4 The flowchart shown is a step S4 of an energy storage method for gas production.
[0100] In this embodiment of the invention, the historical treatment strategy library is a database that stores preset state-action pairs, such as "COD abnormality → increase aeration" and "pump pressure abnormality → reduce influent flow". The warning signal and the state-action pairs in the historical treatment strategy library are used as inputs to construct the environmental state space for reinforcement learning. The construction logic is as follows: (1) State space design: The warning signal is encoded as a state variable (e.g., "high risk = 1, medium risk = 0.5, low risk = 0"). Combined with the state-action pairs in the historical treatment strategy library, the environmental state space is defined (e.g., state = current water quality index + equipment operating parameters, action = adjust aeration, influent flow, etc.). (2) Action space definition: According to the wastewater treatment process requirements, the executable actions are defined (e.g., "increase aeration by 10%" and "reduce influent flow by 5%"). The resulting environmental state space is the input space required by the reinforcement learning algorithm (e.g., state = water quality index + equipment parameters, action = process adjustment options).
[0101] Based on the environmental state space, a deep Q-network (DQN) model is used to generate process parameter adjustment data. Specifically, the state-action space output from step S41 (e.g., current water quality COD = 120 mg / L, aeration rate = 50%) is input into a deep Q-network structure. The input layer of the deep Q-network structure receives the environmental state vector; the hidden layers of the deep Q-network structure use a multi-layer fully connected neural network (e.g., 3 layers of ReLU activation functions) to explore strategies in the environmental state space; and the output layer of the deep Q-network structure outputs the Q-values corresponding to each action (e.g., "increase aeration rate" Q-value = 0.8, "reduce influent flow rate" Q-value = 0.6). Recommended process parameter adjustment schemes (e.g., "increase aeration rate by 10%" "reduce influent flow rate by 5%) are obtained, i.e., the process parameter adjustment data. Furthermore, the strategy exploration mechanism adopted in this invention is as follows: an ε-greedy strategy is used to balance exploration and utilization (e.g., when ε = 0.1, there is a 10% probability of randomly selecting an action and a 90% probability of selecting the action with the highest Q value); historical state-action-reward data is stored through an experience replay buffer to improve the model's generalization ability.
[0102] Based on process parameter adjustment data and real-time feedback data, the Q-value function of the deep Q-network model is updated, and control commands are generated. The specific command generation process is as follows: Calculate the reward value based on the feedback data (e.g., COD compliance reward +1, energy consumption exceedance penalty -0.5), and update the Q-value function.
[0103]
[0104] Here, Q(s, a) is the Q-value function, representing the expected reward of taking action a in state s. It is used to evaluate the value of performing an action in a specific state and guide the model in selecting the optimal policy. α is the learning rate, controlling the degree to which new information influences old information. Its value is typically 0 < α ≤ 1. r is the immediate reward, the immediate feedback obtained after performing action a. γ is the discount factor, measuring the importance of future rewards. Let be the maximum Q-value of all possible actions a' in the next state s'. s' is the next state, the new state of the environment after executing action a. a' is the set of actions available in state s'. s is the current state, describing the real-time state of the environment. a is the current action, the operation performed in state s.
[0105] The optimal action (such as "increase aeration by 10%) is selected based on the updated Q-value function, encapsulated as a control command, and then sent to the execution device.
[0106] Preferably, the specific steps of step S43 are as follows:
[0107] Step S431: According to the urgency level of the early warning signal, use a multi-level priority scheduling algorithm to allocate the process parameter adjustment weights corresponding to the process parameter adjustment data;
[0108] Step S432: Map the process parameter adjustment weights to specific process parameter values using a fuzzy logic controller;
[0109] Step S433: Encapsulate the process parameter values into standardized control commands and send them to the execution equipment via the Industrial Internet of Things protocol.
[0110] In this embodiment of the invention, based on the type of process parameter adjustment data (such as aeration rate, influent flow rate, and reflux ratio) and the urgency level of the warning signal, weights are dynamically allocated (e.g., "high risk → aeration rate weight = 0.8, influent flow rate weight = 0.2") to obtain the corresponding process parameter adjustment weights for the process parameter adjustment data. A fuzzy logic controller is a nonlinear control method based on fuzzy set theory and fuzzy logic reasoning, used to handle complex, uncertain, or difficult-to-describe systems with precise mathematical models. It achieves control objectives by simulating human-language decision-making (such as fuzzy rules like "if...then..."), and is particularly suitable for multi-input multi-output (MIMO) nonlinear systems. The process parameter adjustment weights are input, and the fuzzy logic controller calculates the corresponding parameter adjustment magnitude to obtain the process parameter values.
[0111] The commands are encapsulated into standardized control instructions (such as JSON format) according to a preset format and then sent to the execution devices (such as aerators and water pumps) via industrial IoT protocols (such as MQTT and OPC UA).
[0112] Preferred, such as Figure 5 The flowchart shown is a step S5 of an energy storage method for gas production.
[0113] In this embodiment of the invention, online learning algorithms (such as online incremental training of random forests and incremental learning of gradient boosting machines) are used to gradually integrate the execution feedback data corresponding to the control commands into the model, avoiding retraining the full dataset and generating an optimized machine learning model. Based on the adjustment effect of process parameters after the execution of control commands (such as whether the adjustment of aeration volume leads to a reduction in energy consumption), the hyperparameters of the reinforcement learning algorithm are optimized. The genetic algorithm process is as follows: (1) Population initialization: randomly generate a set of hyperparameter combinations; (2) Fitness evaluation: calculate the fitness value according to the process adjustment effect (such as the reduction in energy consumption); (3) Selection-crossover-mutation: retain individuals with high fitness, crossover to generate new combinations, and randomly mutate. The optimal hyperparameter combination is updated to the deep Q-network model through the genetic algorithm to generate an optimized reinforcement learning algorithm. The historical optimization records in the expert knowledge base are a rule base containing past optimization strategies. The current optimization strategy is matched with the historical records using a rule matching algorithm (such as rule-based similarity calculation) or a machine learning model (such as clustering algorithm). If the matching degree is higher than the threshold (e.g., 90%), the current strategy is merged into the historical strategy library; if the matching degree is lower than the threshold, a new strategy is added to the library, thus obtaining an updated historical processing strategy library.
[0114] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A smart water management wastewater monitoring and treatment method, characterized in that, Includes the following steps: Step S1: Collect water quality parameter data, equipment operation status data, and environmental data in real time through a sensor network deployed in the wastewater treatment facility; Step S2: Perform data preprocessing and feature extraction on the water quality parameter data, the equipment operating status data, and the environmental data to generate a preprocessed dataset and key features; Step S3: Using the preprocessed dataset and key features, a machine learning model is used to identify water quality anomalies and equipment malfunctions, and an early warning signal is generated. Step S4: Based on the warning signal and the historical processing strategy library, dynamically adjust the wastewater treatment process parameters through reinforcement learning algorithm, generate control commands and send them to the execution equipment; Step S5: Based on the execution feedback data corresponding to the control command and the expert knowledge base, optimize the parameters in the machine learning model, the historical processing strategy library, and the reinforcement learning algorithm.
2. The intelligent water management wastewater monitoring and treatment method according to claim 1, characterized in that, The sensor network deployed in step S1 includes multiple distributed multimodal sensor nodes and edge computing units; The distributed multimodal sensor node integrates environmental detection sensors, electrochemical sensors, optical sensors, and biological sensors to synchronously collect data on equipment operating status parameters, environmental parameters, water quality parameters, including chemical oxygen demand (COD), biochemical oxygen demand (BOD), total phosphorus (TP), total nitrogen (TN), and microbial community structure. The edge computing unit is deployed locally on the distributed multimodal sensor node to execute data dimensionality reduction algorithms in real time, compressing the original parameters into feature vectors to generate water quality parameter data, equipment operating status data, and environmental data.
3. The intelligent water management wastewater monitoring and treatment method according to claim 1, characterized in that, The environmental data collected by the sensor network in step S1 includes meteorological data, geographic information data, and social environmental analysis data. The meteorological data is generated by acquiring real-time data on rainfall, temperature, wind speed, and atmospheric humidity through miniature weather stations deployed around the sewage treatment plant. The spatial topology and water level change data of the sewage pipe network are obtained through the positioning module to generate geographic information data. The social environmental analysis data is generated by real-time analysis of relevant information in social media and environmental department announcements using natural language processing algorithms.
4. The intelligent water management wastewater monitoring and treatment method according to claim 1, characterized in that, The specific steps of step S2 are as follows: Step S21: Perform nanosecond-level synchronous calibration on the water quality parameter data, the equipment operating status data, and the environmental data to generate water quality calibration data, equipment operating status calibration data, and environmental calibration data; Step S22: Use the Kalman filter algorithm to smooth the abrupt values in the water quality calibration data to generate water quality cleaning data; Step S23: Decompose the high-frequency noise components in the equipment operation status calibration data by wavelet transform to generate equipment operation status cleaning data; Step S24: Construct a preprocessed dataset using the environmental calibration data, the water quality cleaning data, and the equipment operating status cleaning data; Step S25: Use a graph neural network to extract features from the preprocessed dataset and generate key features.
5. The intelligent water management wastewater monitoring and treatment method according to claim 4, characterized in that, The specific steps of step S24 are as follows: Step S241: Map the water quality cleaning data, equipment operation status cleaning data, and environmental calibration data to the three-dimensional spatial grid corresponding to the sensor network to generate the target three-dimensional spatial grid; Step S242: Employ a spatiotemporal attention mechanism to assign dynamic weights to different types of data within the same grid in the target 3D spatial grid, generating multiple spatiotemporal fusion feature vectors; Step S243: Extract the temporal features from the spatiotemporal fusion feature vector using a sliding window and construct a matrix to generate an initial temporal feature matrix; Step S244: Add the preset lag features to the initial time series feature matrix to generate the target time series feature matrix; Step S245: Identify water quality anomalies in the target time-series feature matrix according to the water quality thresholds in the expert knowledge base, and generate potential anomaly data; Step S246: Use the Isolation Forest algorithm to perform secondary detection on the potential abnormal data, identify outliers in the data, and generate a preprocessed dataset containing normal data and abnormal markers.
6. The intelligent water management wastewater monitoring and treatment method according to claim 1, characterized in that, The specific steps of step S3 are as follows: Step S31: Use the random forest algorithm to perform preliminary classification of water quality anomalies and equipment failures on the preprocessed dataset to generate initial identification data; Step S32: Use a gradient boosting machine to iteratively correct the classification error of the preliminary identification data to generate target identification data; Step S33: Construct an early warning signal corresponding to the target recognition data according to the feature importance weights in the expert knowledge base.
7. The intelligent water management wastewater monitoring and treatment method according to claim 6, characterized in that, The specific steps of step S33 are as follows: Step S331: Weight the feature values in the target recognition data with the corresponding feature importance weights in the expert knowledge base to obtain a comprehensive score; Step S332: Map the comprehensive score to different levels of early warning signals according to the preset risk level threshold range; Step S333: When the target identification data has multiple abnormal features, the weighted abnormality degree is calculated by using the weight of each abnormal feature, and combined with the corresponding early warning signal to construct a composite early warning signal.
8. The intelligent water management wastewater monitoring and treatment method according to claim 1, characterized in that, The specific steps of step S4 are as follows: Step S41: Use the warning signal and the state-action pairs in the historical processing strategy library as input to construct the environment state space for reinforcement learning; Step S42: Explore strategies in the environmental state space using a deep Q-network model to generate process parameter adjustment data; Step S43: Adjust the data and corresponding real-time feedback data according to the process parameters, update the Q-value function of the deep Q-network model, generate control commands and send them to the execution device.
9. The intelligent water management wastewater monitoring and treatment method according to claim 8, characterized in that, The specific steps of step S43 are as follows: Step S431: According to the urgency level of the warning signal, a multi-level priority scheduling algorithm is used to allocate the process parameter adjustment weights corresponding to the process parameter adjustment data; Step S432: Map the process parameter adjustment weights to specific process parameter values using a fuzzy logic controller; Step S433: Encapsulate the process parameter values into standardized control commands and send them to the execution device via the Industrial Internet of Things protocol.
10. A smart water management wastewater monitoring and treatment method according to claim 1, characterized in that, The specific steps of step S5 are as follows: Step S51: According to the execution feedback data corresponding to the control command, the machine learning model is incrementally trained using an online learning algorithm to generate an optimized machine learning model; Step S52: Adjust the process parameters according to the effect in the execution feedback data, and dynamically optimize the hyperparameters in the reinforcement learning algorithm using a genetic algorithm to generate an optimized reinforcement learning algorithm; Step S53: Combine the historical optimization records in the expert knowledge base, perform similarity matching on the strategies in the historical processing strategy library, and generate an updated historical processing strategy library.
Citation Information
Cited By
Pollution source monitoring-oriented multi-source data integration treatment method and system
CN121786714A