Sewage treatment method, system, device and medium based on neural network model

Through the sewage treatment method based on the neural network model, water quality parameters are monitored in real time, treatment plans are generated, and the minimum dosage is predicted, which solves the problems of drug waste and excessive effluent in traditional methods and achieves cost-optimized sewage treatment.

CN120247207BActive Publication Date: 2025-09-05EAST CHINA ENGINEERING SCIENCE AND TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510741380.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-06-05
Publication Date
2025-09-05
Estimated Expiration
2045-06-05

AI Technical Summary

Technical Problem

The dosage of chemicals in traditional sewage treatment methods is difficult to adapt to the dynamic fluctuations of water quality, resulting in waste of chemicals or excessive TP concentration in the effluent. It is also difficult to achieve real-time regulation and control, and the sewage treatment cost is not taken into consideration.

Method used

A sewage treatment method based on a neural network model is used to obtain water quality parameters in real time, generate a combination of dissolved air volume and hydraulic retention time, predict the minimum dosage through the trained neural network model, conduct a cost assessment, and select the lowest-cost treatment plan.

Benefits of technology

Accurate prediction and real-time control of the dosage of chemical additives are achieved, ensuring that the total phosphorus concentration in the effluent meets the requirements while reducing the cost of sewage treatment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120247207B_ABST
    Figure CN120247207B_ABST
Patent Text Reader

Abstract

The present application discloses a sewage treatment method, system, device and medium based on a neural network model, which relates to the field of sewage treatment technology. By real-time monitoring of water quality parameters such as the total phosphorus concentration of the influent, the preset neural network model input data always reflects the current actual working conditions, rather than making predictions based on outdated or fixed data, thereby ensuring the timeliness and accuracy of the dosage prediction and eliminating the lag of traditional offline detection to achieve real-time regulation. By generating different combinations of dissolved air volume and hydraulic retention time, several treatment schemes are obtained, each of which corresponds to a different minimum dosage. Under the premise of ensuring that the sewage treatment effect meets the effluent total phosphorus concentration limit, the treatment scheme corresponding to the lowest sewage treatment cost is used as the target scheme. This decision-making method based on cost optimization can select the most economical operating scheme among many feasible schemes, thereby effectively reducing the sewage treatment cost under the premise of meeting the effluent total phosphorus concentration requirement.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of sewage treatment, and in particular to a sewage treatment method, system, device and medium based on a neural network model. Background Art

[0002] At present, drugs (coagulants or flocculants) are mainly added to the coagulation tank. The coagulated water meets the dissolved air water, and the bubbles collide and adhere with the insoluble phosphate suspended matter in the water to form bubble suspension clusters. The density of the bubble suspension clusters is lower than that of water and they will float to the water surface, thereby achieving solid-liquid separation and removing insoluble phosphorus in the water.

[0003] In traditional sewage treatment methods, the dosing method adopts a fixed-ratio dosing method, that is, the dosing coefficient is set based on experience. The dosing coefficient set by experience is based on past fixed conditions and operating experience, and cannot adapt to dynamic fluctuations in water quality (such as surges in flow during the rainy season or industrial wastewater impact), which can easily lead to the risk of reagent waste or excessive TP concentration in the effluent. In addition, the dosing adjustment relies on offline detection of the effluent TP concentration, which has significant adjustment delays and is difficult to meet real-time control. In addition, the traditional sewage treatment method aims to ensure that the effluent TP concentration meets the requirements, and does not consider the cost of sewage treatment.

[0004] How to achieve accurate prediction and real-time regulation of the dosage of the reagents, and how to reduce the cost of sewage treatment while ensuring that the total phosphorus concentration in the effluent meets the requirements are problems that technical personnel in this field need to solve. Summary of the Invention

[0005] The purpose of this application is to provide a sewage treatment method, system, device and medium based on a neural network model, which is used to solve the problems that traditional sewage treatment is prone to cause the risk of reagent waste or excessive TP concentration in the effluent, is difficult to meet real-time control, and does not consider the cost of sewage treatment.

[0006] To solve the above technical problems, the present application provides a sewage treatment method based on a neural network model, comprising:

[0007] Obtaining the current sewage water quality parameters in real time, wherein the water quality parameters include at least the inlet total phosphorus concentration and the outlet total phosphorus concentration limit;

[0008] Generate different combinations of dissolved air volume and hydraulic retention time to obtain several treatment schemes;

[0009] Input the water quality parameters and each treatment scheme into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment scheme;

[0010] The sewage treatment cost of each treatment scheme is calculated based on each treatment scheme and the minimum dosage corresponding to each treatment scheme, and the treatment scheme corresponding to the minimum sewage treatment cost is used as the target scheme, so as to apply the target dissolved air volume, target hydraulic retention time and target minimum dosage corresponding to the target scheme to carry out sewage treatment.

[0011] In a feasible embodiment, before inputting the water quality parameters and each treatment scheme into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment scheme, the method further includes:

[0012] Obtaining historical data; wherein the historical data includes historical effluent total phosphorus concentration, and historical influent total phosphorus concentration, historical dissolved air volume, historical hydraulic retention time, and historical dosage corresponding to the historical effluent total phosphorus concentration; wherein the historical effluent total phosphorus concentration is less than or equal to the effluent total phosphorus concentration limit;

[0013] Calculating a total phosphorus concentration removal rate based on the historical influent total phosphorus concentration and the historical effluent total phosphorus concentration;

[0014] Constructing a five-dimensional input vector including the total phosphorus concentration removal rate, the historical influent total phosphorus concentration, the historical dissolved air volume, the historical hydraulic retention time, and the historical dosage;

[0015] The five-dimensional input vector is input into a neural network architecture for training to obtain the preset neural network model.

[0016] In a feasible embodiment, before calculating the total phosphorus concentration removal rate according to the historical influent total phosphorus concentration and the historical effluent total phosphorus concentration, the method further includes:

[0017] Separating the historical data to obtain characteristic data and a target variable; wherein the characteristic data includes the historical influent total phosphorus concentration, the historical effluent total phosphorus concentration, the historical dissolved air volume, and the historical hydraulic retention time, and the target variable is the historical dosage;

[0018] Each of the characteristic data is standardized so that the mean value of each of the characteristic data is 0 and the standard deviation is 1.

[0019] In a feasible embodiment, before inputting the five-dimensional input vector into the neural network architecture for training, the method further includes:

[0020] A two-layer fully connected network is created, an activation function is used as ReLU and an output layer is used as a linear node, and L2 regularization and Dropout technology are integrated to construct the neural network architecture; wherein the loss function of the neural network architecture adopts Huber loss.

[0021] In a feasible embodiment, after inputting the five-dimensional input vector into a neural network architecture for training to obtain the preset neural network model, the method further includes:

[0022] Adding hard coding corresponding to dosage limit in the preset neural network model;

[0023] Accordingly, after inputting the water quality parameters and each treatment scheme into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment scheme, the method further includes:

[0024] If the minimum dosage does not meet the dosage limit;

[0025] The input vector corresponding to the minimum dosage is re-input into the preset neural network model for learning until the minimum dosage meets the dosage limit.

[0026] In a feasible embodiment, the sewage treatment cost of each treatment scheme is calculated based on each treatment scheme and the minimum dosage of each treatment scheme, including:

[0027] Determine the amount of dissolved air corresponding to each of the treatment options;

[0028] Determine the power corresponding to the dissolved gas amount according to a power model including the relationship between dissolved gas amount and power;

[0029] Calculate the electricity cost corresponding to each treatment plan based on the power, treatment time, unit price of electricity and the total amount of treated sewage corresponding to the treatment time;

[0030] Calculate the cost of the drug based on the minimum dosage corresponding to each treatment plan;

[0031] The sewage treatment cost corresponding to each treatment plan is calculated based on the electricity cost and the chemical cost.

[0032] The present application also provides a sewage treatment system, which is applied to the sewage treatment method based on the neural network model, comprising: a dosing pump, a first TP sensor, a second TP sensor, a coagulation tank, a flotation tank, a water storage tank, a micro-nano flotation device and a control device;

[0033] The dosing pump is connected to the water inlet of the coagulation tank, the water outlet of the coagulation tank is connected to the water inlet of the flotation tank, the water outlet of the flotation tank is connected to the water reservoir, the micro-nano flotation device is connected to the flotation tank and the water reservoir, respectively, the first TP sensor is arranged on the water inlet pipe of the coagulation tank, the second TP sensor is arranged on the water outlet pipe of the water reservoir, the control device is connected to the dosing pump, the first TP sensor, the second TP sensor and the micro-nano flotation device, respectively, and the first TP sensor is used to obtain the total phosphorus concentration of the inlet water in real time.

[0034] The present application also provides a sewage treatment device based on a neural network model, comprising:

[0035] An acquisition module is used to obtain the water quality parameters of the current sewage in real time, wherein the water quality parameters include at least the inlet total phosphorus concentration and the outlet total phosphorus concentration limit;

[0036] A generation module, used for generating different combinations of dissolved air volume and hydraulic retention time to obtain several treatment plans;

[0037] A prediction module, configured to input the water quality parameters and each treatment scheme into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment scheme;

[0038] A calculation module is used to calculate the sewage treatment cost of each treatment scheme based on each treatment scheme and the minimum dosage corresponding to each treatment scheme, and to take the treatment scheme corresponding to the minimum sewage treatment cost as the target scheme, so as to apply the target dissolved air volume, target hydraulic retention time and target minimum dosage corresponding to the target scheme to carry out sewage treatment.

[0039] The present application also provides a sewage treatment device based on a neural network model, comprising a memory for storing a computer program;

[0040] A processor is used to implement the steps of the sewage treatment method based on the neural network model when executing the computer program.

[0041] The present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the sewage treatment method based on the neural network model are implemented.

[0042] The present application provides a sewage treatment method based on a neural network model. By real-time monitoring of water quality parameters such as the total phosphorus concentration of the influent, the latest information of the sewage can be obtained in a timely manner. This means that the preset neural network model input data always reflects the current actual working conditions, rather than being predicted based on outdated or fixed data, thereby ensuring the timeliness and accuracy of the dosage prediction. Moreover, the preset neural network model is used to predict the dosage, eliminating the lag of the traditional offline detection of the total phosphorus concentration of the effluent and then adjusting the dosage, and achieving real-time regulation. By generating different combinations of dissolved air volume and hydraulic retention time, several treatment schemes are obtained, each of which corresponds to a different minimum dosage. Cost evaluation and comparison are performed under multiple possible operating conditions. Under the premise of ensuring that the sewage treatment effect meets the effluent total phosphorus concentration limit, the treatment scheme corresponding to the lowest sewage treatment cost is used as the target scheme. This decision-making method based on cost optimization can select the most economical operating scheme among many feasible schemes, thereby effectively reducing the sewage treatment cost under the premise of ensuring that the effluent total phosphorus concentration meets the requirements.

[0043] The beneficial effects of the sewage treatment system, the sewage treatment device based on the neural network model and the medium provided in this application correspond to the method, and the effects are as described above. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] In order to more clearly illustrate the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0045] Figure 1 A flowchart of a sewage treatment method based on a neural network model provided in an embodiment of the present application;

[0046] Figure 2 A structural diagram of a sewage treatment system provided in an embodiment of the present application;

[0047] Figure 3 A structural diagram of a sewage treatment device based on a neural network model provided in an embodiment of the present application;

[0048] Figure 4 A structural diagram of another sewage treatment device based on a neural network model provided in an embodiment of the present application. DETAILED DESCRIPTION

[0049] The following will be combined with the accompanying drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0050] The core of this application is to provide a sewage treatment method, system, device and medium based on a neural network model, which is used to achieve accurate prediction and real-time regulation of the dosage of the reagent, and how to reduce the sewage treatment cost while ensuring that the total phosphorus concentration of the effluent meets the requirements.

[0051] In order to enable those skilled in the art to better understand the present application, the present application is further described in detail below with reference to the accompanying drawings and specific implementation methods.

[0052] Figure 1 A flowchart of a sewage treatment method based on a neural network model is provided in an embodiment of the present application, such as Figure 1 As shown in FIG, the sewage treatment method based on the neural network model includes:

[0053] S10: Acquire the water quality parameters of the current sewage in real time, where the water quality parameters at least include the inlet total phosphorus concentration and the outlet total phosphorus concentration limit.

[0054] S11: Generate different combinations of dissolved air volume and hydraulic retention time to obtain several treatment solutions.

[0055] S12: Input the water quality parameters and various treatment plans into the trained preset neural network model to obtain the minimum dosage corresponding to each treatment plan.

[0056] S13: Calculate the sewage treatment cost of each treatment scheme based on each treatment scheme and the minimum dosage corresponding to each treatment scheme, and use the treatment scheme corresponding to the minimum sewage treatment cost as the target scheme so as to apply the target dissolved air volume, target hydraulic retention time and target minimum dosage corresponding to the target scheme to perform sewage treatment.

[0057] For ease of understanding, the sewage treatment system used in the above sewage treatment method is introduced below. Figure 2 A structural diagram of a sewage treatment system provided in an embodiment of the present application is shown in FIG. Figure 2As shown, the sewage treatment system includes: a dosing pump 1, a first TP sensor, a second TP sensor, a coagulation tank 2, a flotation tank 3, a water reservoir 4, a micro-nano flotation device 5 and a control device 6; the dosing pump 1 is connected to the water inlet of the coagulation tank 2, the water outlet of the coagulation tank 2 is connected to the water inlet of the flotation tank 3, the water outlet of the flotation tank 3 is connected to the water reservoir 4, the micro-nano flotation device 5 is respectively connected to the flotation tank 3 and the water reservoir 4, the first TP sensor is arranged on the water inlet pipe of the coagulation tank 2, the second TP sensor is arranged on the water outlet pipe of the water reservoir 4, the control device 6 is respectively connected to the dosing pump 1, the first TP sensor, the second TP sensor and the micro-nano flotation device 5, and the first TP sensor is used to obtain the total phosphorus concentration of the inlet water in real time.

[0058] In the embodiment of the present application, the dosing pump 1 is connected to the water inlet of the coagulation tank 2 and is responsible for adding coagulants or flocculants to the sewage. The first TP sensor is installed on the water inlet pipe of the coagulation tank 2 for real-time monitoring of the total phosphorus concentration of the inlet water. The second TP sensor is installed on the outlet pipe of the water reservoir 4 for real-time monitoring of the total phosphorus concentration of the treated effluent to ensure that the TP of the effluent meets the standard. The coagulation tank 2 uses mechanical stirring to achieve full mixing of sewage and chemicals, completes the coagulant floc growth process, and prepares for subsequent flotation separation. The flotation tank 3 uses micro-nano bubbles to adhere to the flocs, forming a "bubble-floc" complex that floats quickly to achieve efficient separation of mud and water. The water reservoir 4 stores the treated clean water and provides raw water for the micro-nano flotation device 5. The micro-nano flotation device 5 produces ultrafine bubbles, which significantly improves the efficiency of pollutant capture. It is connected to the flotation tank 3 and the water reservoir 4 to assist in completing the mud and water separation process. The control device 6 is used to execute the steps of the above-mentioned sewage treatment method based on the neural network model. Furthermore, a first flow meter can be set in the water inlet pipeline of the coagulation tank 2, and the first flow meter is used to obtain the water inlet flow in real time; a second flow meter is set in the pipeline connecting the water reservoir 4 and the micro-nano flotation device 5, and the second flow meter is used to obtain the backflow in real time. The appropriate backflow can maintain the hydraulic balance in the flotation tank 3 and prevent the water flow from being too fast or too slow and having an adverse effect on the flotation effect. The backflow can also help stabilize the operation of the system and avoid excessive impact on the flotation effect due to fluctuations in the water quality or flow of the inlet water. A human-computer interaction device connected to the control device 6 can also be provided. The human-computer interaction device supports parameter setting, trend analysis and alarm management, reducing the complexity of operation and maintenance.

[0059] In step S10, the inlet total phosphorus concentration fed back by the first TP sensor provided on the inlet pipe of the coagulation tank is obtained in real time; the outlet total phosphorus concentration limit may be less than or equal to 0.05 mg / L, which may be adjusted according to actual conditions.

[0060] In step S11, the hydraulic retention time (HRT) includes the HRT of the water reservoir and the HRT of the flotation tank. The HRT of the water reservoir = reservoir volume / wastewater flow rate, and the HRT of the flotation tank = flotation tank volume / wastewater flow rate. The dissolved air volume is equal to 10% to 50% of the influent flow rate. After obtaining the current influent flow rate, multiple dissolved air volumes are generated based on the dissolved air volume being equal to 10% to 50% of the influent flow rate. Each dissolved air volume and HRT combination constitutes a treatment plan.

[0061] In step S12, the inlet total phosphorus concentration and effluent total phosphorus concentration limits, as well as the dissolved air volume and hydraulic retention time in each treatment scheme are input into a preset neural network model. Under the condition that the effluent total phosphorus concentration limit is met, multiple dosages will be output. In order to reduce the cost of the agent, the minimum dosage corresponding to each treatment scheme is determined.

[0062] In step S12, the sewage treatment cost may include electricity costs and chemical costs. The electricity cost is related to the dissolved air volume, and the chemical cost is related to the dosage. Therefore, the electricity cost is calculated for each treatment plan, and the chemical cost is calculated based on the minimum dosage corresponding to each treatment plan. The sewage treatment cost of each treatment plan is calculated based on the electricity cost and chemical cost. The target dissolved air volume, target hydraulic retention time, and target minimum dosage corresponding to the minimum sewage treatment cost are used to treat the sewage.

[0063] The embodiment of the present application provides a sewage treatment method based on a neural network model. By real-time monitoring of water quality parameters such as the total phosphorus concentration of the influent, the latest information of the sewage can be obtained in a timely manner. This means that the input data of the preset neural network model always reflects the current actual working conditions, rather than being predicted based on outdated or fixed data, thereby ensuring the timeliness and accuracy of the dosage prediction. Moreover, the use of the preset neural network model to predict the dosage eliminates the lag of the traditional offline detection of the total phosphorus concentration of the effluent and then adjusting the dosage, and can achieve real-time regulation. By generating different combinations of dissolved air volume and hydraulic retention time, several treatment schemes are obtained, each of which corresponds to a different minimum dosage. Cost evaluation and comparison are performed under multiple possible operating conditions. On the premise of ensuring that the sewage treatment effect meets the effluent total phosphorus concentration limit, the treatment scheme corresponding to the lowest sewage treatment cost is used as the target scheme. This decision-making method based on cost optimization can select the most economical operating scheme among many feasible schemes, thereby effectively reducing the sewage treatment cost on the premise of ensuring that the effluent total phosphorus concentration meets the requirements.

[0064] Based on the above embodiments, the embodiment of the present application inputs water quality parameters and various treatment schemes into a trained preset neural network model, and before obtaining the minimum dosage corresponding to each treatment scheme, it also includes: obtaining historical data; wherein the historical data includes the historical effluent total phosphorus concentration, and the historical influent total phosphorus concentration, historical dissolved air volume, historical hydraulic retention time and historical dosage corresponding to the historical effluent total phosphorus concentration; wherein the historical effluent total phosphorus concentration is less than or equal to the effluent total phosphorus concentration limit; calculating the total phosphorus concentration removal rate based on the historical influent total phosphorus concentration and the historical effluent total phosphorus concentration; constructing a five-dimensional input vector including the total phosphorus concentration removal rate, historical influent total phosphorus concentration, historical dissolved air volume, historical hydraulic retention time and historical dosage; inputting the five-dimensional input vector into the neural network architecture for training to obtain a preset neural network model.

[0065] The embodiment of the present application mainly introduces the use of some historical data with required effluent total phosphorus concentration to perform model training in order to obtain a preset neural network model. The historical data include the historical effluent total phosphorus concentration, and the corresponding historical influent total phosphorus concentration, historical dissolved air volume, historical hydraulic retention time and historical dosage. These data record the operation status and effect of the sewage treatment system under different working conditions in the past. The key point is that the historical effluent total phosphorus concentration must be less than or equal to the effluent total phosphorus concentration limit to ensure the validity and reliability of the training data. Total phosphorus concentration removal rate = (historical influent total phosphorus concentration - historical effluent total phosphorus concentration) / historical influent total phosphorus concentration, construct a five-dimensional input vector including total phosphorus concentration removal rate, historical influent total phosphorus concentration, historical dissolved air volume, historical hydraulic retention time and historical dosage. Before the five-dimensional input vector is input into the neural network, it is usually necessary to standardize the input vector. The purpose of standardization is to enable data of different dimensions and orders of magnitude to be compared and learned on a unified scale, thereby improving the training efficiency and prediction accuracy of the neural network. The total phosphorus removal rate directly reflects the efficiency of the flotation process in removing total phosphorus and is a core indicator for evaluating wastewater treatment effectiveness. Using it as an input feature enables the neural network to directly learn the relationship between "treatment efficiency" and "drug dosage." Total phosphorus concentrations in the influent vary significantly between wastewater treatment plants. Simply relying on influent total phosphorus concentrations can lead to overfitting the model to high-concentration samples. The total phosphorus removal rate is normalized to unify the performance representation across different concentration ranges.

[0066] In the embodiment of the present application, the five-dimensional input vector covers multiple key parameters such as total phosphorus concentration removal rate, influent total phosphorus concentration, dissolved air content, hydraulic retention time and dosage. These parameters are interrelated and jointly affect the sewage treatment effect. By comprehensively considering these parameters, the neural network model captures the complex relationship between water quality parameters and dosage through a nonlinear mapping relationship, thereby improving the accuracy and reliability of the prediction, adapting to the dynamic fluctuations of water quality, and eliminating the lag of traditional offline detection.

[0067] Based on the above embodiment, before calculating the total phosphorus removal rate based on the historical influent total phosphorus concentration and the historical effluent total phosphorus concentration, the present embodiment further includes: separating the historical data to obtain feature data and a target variable; wherein the feature data includes the historical influent total phosphorus concentration, the historical effluent total phosphorus concentration, the historical dissolved air volume, and the historical hydraulic retention time, and the target variable is the historical dosage; and normalizing each feature data to ensure that the mean of each feature data is 0 and the standard deviation is 1. The present embodiment uses StandardScaler (StandardScaler is a tool provided in the machine learning library) to standardize the feature data, which helps improve the model's training efficiency and prediction accuracy.

[0068] Based on the above embodiment, before the five-dimensional input vector is input into the neural network architecture for training, the embodiment of the present application also includes: creating a two-layer fully connected network, using ReLU as the activation function and linear nodes as the output layer, and integrating L2 regularization (also known as ridge regression, which is a regularization method widely used in machine learning and statistics) and Dropout technology to construct a neural network architecture; wherein, the loss function of the neural network architecture adopts Huber loss.

[0069] The neural network architecture of this application utilizes a two-layer fully connected network (64-32 nodes) with a Rectified Linear Unit (ReLU) activation function and a linear output layer. L2 regularization (λ=0.01) and Dropout (p=0.2) techniques are integrated to mitigate overfitting, and the Huber loss (δ=1.0) is used as the loss function. In this embodiment, the two-layer fully connected network (64-32 nodes) consists of two fully connected layers, with the first layer having 64 nodes and the second layer having 32 nodes. This structure is complex enough to learn and model complex nonlinear relationships between input features and output. The input layer receives an input vector (including inlet total phosphorus concentration, outlet total phosphorus concentration, dissolved air volume, and hydraulic retention time). After processing through two fully connected layers, the output layer predicts the minimum dosage rate. The Rectified Linear Unit (ReLU) activation function is used in the hidden layers to introduce nonlinearity, enabling the network to learn complex patterns. The output layer uses a linear activation function to directly output the predicted minimum dosage rate. This linear activation function ensures that the output is unconstrained and accommodates all possible numerical ranges. L2 regularization adds the L2 norm of the weights to the loss function to limit their excessive growth, thereby reducing model complexity and preventing overfitting. The parameter λ = 0.01 indicates the strength of the regularization, balancing the need for the model to fit the data well while preventing overfitting. Dropout (p = 0.2) randomly discards some neuron outputs during training to prevent the network from becoming overly reliant on specific neurons. Here, p = 0.2 means that 20% of the neurons are randomly discarded at each iteration during training, increasing the robustness of the model and improving its generalization ability. The Huber loss (a commonly used loss function in machine learning and statistics) combines the advantages of the mean squared error (MSE) and the mean absolute error (MAE), using a squared loss for small residuals and an absolute value loss for large residuals. This makes the model more robust to outliers. The parameter δ = 1.0 defines the residual threshold; the absolute value loss is used for residuals above the threshold, while the squared loss is used for residuals below or equal to the threshold.

[0070] Nonlinear neural network modeling replaces linear models. A two-layer, fully connected neural network leverages the nonlinear mapping capabilities of the ReLU activation function to automatically learn the nonlinear relationship between dosage and total phosphorus removal efficiency under varying influent and effluent total phosphorus concentrations, breaking through linear limitations. Compared to traditional proportional-integral-derivative (PID) control or linear feedforward models, which can only handle fixed operating conditions, the neural network can autonomously learn the dynamic relationship between dosage and total phosphorus removal efficiency under varying dissolved air content and hydraulic retention time, adapting to continuously changing water quality parameters.

[0071] Based on the above embodiment, the embodiment of the present application inputs a five-dimensional input vector into a neural network architecture for training. After obtaining a preset neural network model, it also includes: adding a hard code corresponding to the dosage limit in the preset neural network model; accordingly, the water quality parameters and various treatment schemes are input into the trained preset neural network model. After obtaining the minimum dosage corresponding to each treatment scheme, it also includes: if the minimum dosage does not meet the dosage limit; the input vector corresponding to the minimum dosage (influent total phosphorus concentration, effluent total phosphorus concentration limit, dissolved air volume and hydraulic retention time) is re-input into the preset neural network model for learning until the minimum dosage meets the dosage limit.

[0072] The embodiment of the present application is to ensure that the predicted dosage meets the constraints in actual operation. Through this mechanism, the system can continuously learn and adjust to ensure that the predicted dosage is both accurate and practical. This iterative optimization method can effectively balance the accuracy of the model and the feasibility of practical application, ensuring that the system can operate stably under various operating conditions. This mechanism ensures that the dosage is always within a reasonable range during actual operation of the system, preventing the dosage from being too large or too small due to model prediction errors or sudden changes in operating conditions.

[0073] Based on the above embodiments, the embodiments of the present application calculate the sewage treatment cost of each treatment scheme based on each treatment scheme and the minimum dosage corresponding to each treatment scheme, including: determining the dissolved air volume corresponding to each treatment scheme; determining the power corresponding to the dissolved air volume according to a power model including the relationship between dissolved air volume and power; calculating the electricity cost corresponding to each treatment scheme according to the power, treatment time, unit price of electricity and the total amount of treated sewage corresponding to the treatment time; calculating the chemical cost according to the minimum dosage corresponding to each treatment scheme; and calculating the sewage treatment cost corresponding to each treatment scheme based on the electricity cost and the chemical cost.

[0074] In the embodiments of the present application, each treatment scheme has a specific amount of dissolved air, and the amount of dissolved air directly affects the efficiency of the flotation process and the required power consumption. The power model of the relationship between dissolved air and power is obtained by fitting the experimental data. The power model can usually be established by using the quadratic polynomial regression method. The dissolved air amount in the treatment scheme is substituted into the power model to calculate the corresponding power. Electricity cost = power × treatment time × electricity unit price / total amount of sewage treated. This formula calculates the electricity cost required to treat a unit volume of sewage under a specific power and treatment time. Chemical cost = dosage × chemical unit price. The total sewage treatment cost is obtained by adding the electricity cost and the chemical cost. By comparing the sewage treatment costs of different treatment schemes, the scheme with the lowest sewage treatment cost is selected as the final sewage treatment scheme, thereby minimizing the sewage treatment cost while ensuring the quality of the effluent.

[0075] Of course, a cost model can also be constructed. The cost model calculates the reagent cost + electricity cost corresponding to different treatment schemes, and outputs the target dissolved air volume, target hydraulic retention time and target minimum dosage when the sewage treatment cost is minimized.

[0076] To demonstrate the advantages of the sewage treatment method of the present application, an example is given below.

[0077] Deep phosphorus removal from tail water of a 50,000 ton / day sewage treatment plant.

[0078] Equipment configuration: An electromagnetic flowmeter and an online TP analyzer are installed at the water inlet of the flotation tank. The dosing pump adopts frequency conversion control, and the PLC controller is equipped with the algorithm of the sewage treatment method applied in this application.

[0079] Model training: Historical data (3 months, sampling interval 5 minutes) was collected to train the neural network. The mean square error (MSE) of the test set was 0.002, and the prediction deviation rate was <5%.

[0080] Operation effect: After the system was put into operation, the TP concentration of the effluent was stabilized at 0.03-0.05 mg / L, and the treatment cost per ton of water was 0.3719 yuan / ton of water. Compared with the operating cost of the traditional flotation deep phosphorus removal method of about 0.5 yuan to 1.8 yuan, the operating cost was reduced by 25.62%-78.89% year-on-year.

[0081] In the above embodiments, a sewage treatment method based on a neural network model is described in detail. This application also provides corresponding embodiments of a sewage treatment device based on a neural network model. It should be noted that this application describes the embodiments of the device from two perspectives: one from the perspective of functional modules and the other from the perspective of hardware.

[0082] Figure 3 A structural diagram of a sewage treatment device based on a neural network model provided in an embodiment of the present application is shown in FIG. Figure 3 As shown, the sewage treatment device based on the neural network model includes:

[0083] The first acquisition module 10 is used to obtain the water quality parameters of the current sewage in real time. The water quality parameters at least include the inlet total phosphorus concentration and the outlet total phosphorus concentration limit.

[0084] The generation module 11 is used to generate different combinations of dissolved air volume and hydraulic retention time to obtain several treatment solutions.

[0085] The prediction module 12 is used to input water quality parameters and various treatment solutions into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment solution.

[0086] The first calculation module 13 is used to calculate the sewage treatment cost of each treatment scheme based on each treatment scheme and the minimum dosage corresponding to each treatment scheme, and take the treatment scheme corresponding to the minimum sewage treatment cost as the target scheme, so as to apply the target dissolved air volume, target hydraulic retention time and target minimum dosage corresponding to the target scheme to perform sewage treatment.

[0087] Based on the above embodiment, in a feasible embodiment, the present invention further includes:

[0088] The second acquisition module is used to obtain historical data; wherein the historical data includes historical effluent total phosphorus concentration, and historical influent total phosphorus concentration, historical dissolved air volume, historical hydraulic retention time, and historical dosage corresponding to the historical effluent total phosphorus concentration; wherein the historical effluent total phosphorus concentration is less than or equal to the effluent total phosphorus concentration limit;

[0089] The second calculation module is used to calculate the total phosphorus concentration removal rate based on the historical influent total phosphorus concentration and the historical effluent total phosphorus concentration;

[0090] A construction module is used to construct a five-dimensional input vector including total phosphorus concentration removal rate, historical influent total phosphorus concentration, historical dissolved air content, historical hydraulic retention time and historical dosage;

[0091] The training module is used to input the five-dimensional input vector into the neural network architecture for training to obtain a preset neural network model.

[0092] Based on the above embodiment, in a feasible embodiment, the present invention further includes:

[0093] A separation module is used to separate historical data to obtain characteristic data and target variables; wherein the characteristic data includes historical influent total phosphorus concentration, historical effluent total phosphorus concentration, historical dissolved air volume and historical hydraulic retention time, and the target variable is historical dosage;

[0094] The processing module is used to perform standardization on each feature data so that the mean value of each feature data is 0 and the standard deviation is 1.

[0095] Based on the above embodiment, in a feasible embodiment, the present invention further includes:

[0096] Create a module for creating a two-layer fully connected network with ReLU activation function and linear nodes in the output layer. It also integrates L2 regularization and Dropout techniques to build a neural network architecture. The loss function of the neural network architecture is Huber loss.

[0097] Based on the above embodiment, in a feasible embodiment, the present invention further includes:

[0098] Added a module for adding hard-coded dosage limits to the preset neural network model;

[0099] Correspondingly, it also includes:

[0100] A comparison module, used for checking if the minimum dosage does not meet the dosage limit;

[0101] The learning module is used to re-input the input vector corresponding to the minimum dosage into the preset neural network model for learning until the minimum dosage meets the dosage limit.

[0102] Based on the above embodiment, the first calculation module includes:

[0103] The first determining unit is used to determine the dissolved gas volume corresponding to each treatment plan;

[0104] a second determining unit, configured to determine the power corresponding to the dissolved air volume according to a power model including a relationship between the dissolved air volume and the power;

[0105] The first calculation unit is used to calculate the electricity cost corresponding to each treatment plan based on the power, treatment time, electricity price and the total amount of treated sewage corresponding to the treatment time;

[0106] The second calculation unit is used to calculate the drug cost according to the minimum dosage corresponding to each treatment plan;

[0107] The third calculation unit is used to calculate the sewage treatment cost corresponding to each treatment plan based on the electricity cost and the chemical cost.

[0108] Since the embodiments of the apparatus part correspond to the embodiments of the method part, please refer to the description of the embodiments of the method part for the embodiments of the apparatus part, and they will not be repeated here.

[0109] Figure 4 This is a structural diagram of another sewage treatment device based on a neural network model provided in an embodiment of the present application, such as Figure 4 As shown, the sewage treatment device based on the neural network model includes: a memory 20 for storing a computer program;

[0110] The processor 21 is used to implement the steps of the sewage treatment method based on the neural network model in the above embodiment when executing the computer program.

[0111] The sewage treatment device based on the neural network model provided in this embodiment may include but is not limited to a smart phone, a tablet computer, a laptop computer or a desktop computer.

[0112] The processor 21 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 21 may be implemented in at least one hardware form of a digital signal processor (DSP), a field-programmable gate array (FPGA), or a programmable logic array (PLA). The processor 21 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a central processing unit (CPU); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 21 may be integrated with a graphics processing unit (GPU), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 21 may also include an artificial intelligence (AI) processor, which is used to process computing operations related to machine learning.

[0113] The memory 20 may include one or more computer-readable storage media, which may be non-transitory. The memory 20 may also include a high-speed random access memory, and a non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In this embodiment, the memory 20 is at least used to store the following computer program 201, wherein, after the computer program is loaded and executed by the processor 21, it can implement the relevant steps of the sewage treatment method based on the neural network model disclosed in any of the aforementioned embodiments. In addition, the resources stored in the memory 20 may also include an operating system 202 and data 203, etc., and the storage method may be temporary storage or permanent storage. Among them, the operating system 202 may include Windows, Unix, Linux, etc. The data 203 may include but is not limited to water quality parameters, etc.

[0114] In some embodiments, the sewage treatment device based on the neural network model may further include a display screen 22 , an input and output interface 23 , a communication interface 24 , a power supply 25 and a communication bus 26 .

[0115] Those skilled in the art will understand that Figure 4 The structure shown in does not constitute a limitation on the sewage treatment device based on the neural network model, and may include more or fewer components than shown in the figure.

[0116] A sewage treatment device based on a neural network model provided in an embodiment of the present application includes a memory and a processor. When the processor executes a program stored in the memory, it can implement the following method: obtaining water quality parameters of current sewage in real time, the water quality parameters at least including inlet total phosphorus concentration and outlet total phosphorus concentration limit; generating different combinations of dissolved air volume and hydraulic retention time to obtain several treatment schemes; inputting the water quality parameters and various treatment schemes into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment scheme; calculating the sewage treatment cost of each treatment scheme based on each treatment scheme and the minimum dosage corresponding to each treatment scheme, and using the treatment scheme corresponding to the minimum sewage treatment cost as the target scheme, so as to apply the target dissolved air volume, target hydraulic retention time and target minimum dosage corresponding to the target scheme to perform sewage treatment.

[0117] Finally, the present application also provides an embodiment corresponding to a computer-readable storage medium. The computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps described in the above-mentioned method embodiment of the sewage treatment method based on a neural network model.

[0118] It is understandable that if the method in the above embodiment is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium and executes all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, and other media that can store program code.

[0119] The above is a detailed introduction to the sewage treatment method, system, device and medium based on the neural network model provided by the present application. The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same and similar parts between the various embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description. It should be pointed out that for ordinary technicians in this technical field, without departing from the principles of this application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the scope of protection of the claims of this application.

[0120] It should also be noted that, in this specification, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variants thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of additional identical elements in the process, method, article, or apparatus comprising the element.

Claims

1. A sewage treatment method based on a neural network model, characterized in that: include: Obtaining the current sewage water quality parameters in real time, wherein the water quality parameters include at least the inlet total phosphorus concentration and the outlet total phosphorus concentration limit; Generate different combinations of dissolved air volume and hydraulic retention time to obtain several treatment schemes; Input the water quality parameters and each treatment scheme into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment scheme; Calculate the sewage treatment cost of each treatment scheme based on each treatment scheme and the minimum dosage of each treatment scheme, and use the treatment scheme corresponding to the minimum sewage treatment cost as the target scheme, so as to apply the target dissolved air volume, target hydraulic retention time and target minimum dosage of the target scheme to treat the sewage; Before inputting the water quality parameters and each treatment scheme into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment scheme, the method further includes: Obtaining historical data; wherein the historical data includes historical effluent total phosphorus concentration, and historical influent total phosphorus concentration, historical dissolved air volume, historical hydraulic retention time, and historical dosage corresponding to the historical effluent total phosphorus concentration; wherein the historical effluent total phosphorus concentration is less than or equal to the effluent total phosphorus concentration limit; Calculating a total phosphorus concentration removal rate based on the historical influent total phosphorus concentration and the historical effluent total phosphorus concentration; Constructing a five-dimensional input vector including the total phosphorus concentration removal rate, the historical influent total phosphorus concentration, the historical dissolved air volume, the historical hydraulic retention time, and the historical dosage; The five-dimensional input vector is input into a neural network architecture for training to obtain the preset neural network model.

2. The sewage treatment method based on the neural network model according to claim 1, characterized in that: Before calculating the total phosphorus concentration removal rate based on the historical influent total phosphorus concentration and the historical effluent total phosphorus concentration, the method further includes: Separating the historical data to obtain characteristic data and a target variable; wherein the characteristic data includes the historical influent total phosphorus concentration, the historical effluent total phosphorus concentration, the historical dissolved air volume, and the historical hydraulic retention time, and the target variable is the historical dosage; Each of the characteristic data is standardized so that the mean value of each of the characteristic data is 0 and the standard deviation is 1.

3. The sewage treatment method based on the neural network model according to claim 1, characterized in that: Before inputting the five-dimensional input vector into the neural network architecture for training, the following steps are also included: A two-layer fully connected network is created, an activation function is used as ReLU and an output layer is used as a linear node, and L2 regularization and Dropout technology are integrated to construct the neural network architecture; wherein the loss function of the neural network architecture adopts Huber loss.

4. The sewage treatment method based on the neural network model according to claim 1, characterized in that: After inputting the five-dimensional input vector into the neural network architecture for training to obtain the preset neural network model, the method further includes: Adding hard coding corresponding to dosage limit in the preset neural network model; Accordingly, after inputting the water quality parameters and each treatment scheme into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment scheme, the method further includes: If the minimum dosage does not meet the dosage limit; The input vector corresponding to the minimum dosage is re-input into the preset neural network model for learning until the minimum dosage meets the dosage limit.

5. The sewage treatment method based on the neural network model according to claim 1, characterized in that: The sewage treatment cost of each treatment scheme is calculated based on each treatment scheme and the minimum dosage of each treatment scheme, including: Determine the amount of dissolved air corresponding to each of the treatment options; Determine the power corresponding to the dissolved gas amount according to a power model including the relationship between dissolved gas amount and power; Calculate the electricity cost corresponding to each treatment plan based on the power, treatment time, unit price of electricity and the total amount of treated sewage corresponding to the treatment time; Calculate the cost of the drug based on the minimum dosage corresponding to each treatment plan; The sewage treatment cost corresponding to each treatment plan is calculated based on the electricity cost and the chemical cost.

6. A sewage treatment system, characterized in that: The sewage treatment method based on the neural network model as claimed in any one of claims 1 to 5 comprises: a dosing pump, a first TP sensor, a second TP sensor, a coagulation tank, a flotation tank, a water storage tank, a micro-nano flotation device and a control device; The dosing pump is connected to the water inlet of the coagulation tank, the water outlet of the coagulation tank is connected to the water inlet of the flotation tank, the water outlet of the flotation tank is connected to the water reservoir, the micro-nano flotation device is connected to the flotation tank and the water reservoir, respectively, the first TP sensor is arranged on the water inlet pipe of the coagulation tank, the second TP sensor is arranged on the water outlet pipe of the water reservoir, the control device is connected to the dosing pump, the first TP sensor, the second TP sensor and the micro-nano flotation device, respectively, and the first TP sensor is used to obtain the total phosphorus concentration of the inlet water in real time.

7. A sewage treatment device based on a neural network model, characterized in that: include: A first acquisition module is used to obtain the water quality parameters of the current sewage in real time, wherein the water quality parameters at least include the inlet total phosphorus concentration and the outlet total phosphorus concentration limit; A generation module, used for generating different combinations of dissolved air volume and hydraulic retention time to obtain several treatment plans; A prediction module, configured to input the water quality parameters and each treatment scheme into a trained preset neural network model to obtain the minimum dosage corresponding to each treatment scheme; a first calculation module for calculating the sewage treatment cost of each treatment scheme based on each treatment scheme and the minimum dosage of chemicals corresponding to each treatment scheme, and taking the treatment scheme corresponding to the minimum sewage treatment cost as the target scheme, so as to apply the target dissolved air volume, target hydraulic retention time and target minimum dosage of chemicals corresponding to the target scheme to perform sewage treatment; The second acquisition module is used to obtain historical data; wherein the historical data includes historical effluent total phosphorus concentration, and historical influent total phosphorus concentration, historical dissolved air volume, historical hydraulic retention time, and historical dosage corresponding to the historical effluent total phosphorus concentration; wherein the historical effluent total phosphorus concentration is less than or equal to the effluent total phosphorus concentration limit; The second calculation module is used to calculate the total phosphorus concentration removal rate based on the historical influent total phosphorus concentration and the historical effluent total phosphorus concentration; A construction module is used to construct a five-dimensional input vector including total phosphorus concentration removal rate, historical influent total phosphorus concentration, historical dissolved air content, historical hydraulic retention time and historical dosage; The training module is used to input the five-dimensional input vector into the neural network architecture for training to obtain a preset neural network model.

8. A sewage treatment device based on a neural network model, characterized in that: including a memory for storing a computer program; A processor is used to implement the steps of the sewage treatment method based on the neural network model as described in any one of claims 1 to 5 when executing the computer program.

9. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of the sewage treatment method based on a neural network model as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Chemical feed control device, water treatment system, chemical feed control method, and program

    CN110709354A

  • Sewage treatment method and device, electronic equipment and program product

    CN119294573A