A method and device for predicting water volume in mixed flow pipe network
The water volume data of the drainage pipeline network is preprocessed and analyzed through the multi-layer perceptron model, which solves the problem of low water volume prediction accuracy in the mixed drainage system, realizes accurate prediction with high time resolution, and optimizes the operation of the sewage treatment unit.
Patent Information
- Application Number
- CN202110630103.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-06-07
- Publication Date
- 2024-11-26
- Estimated Expiration
- 2041-06-07
AI Technical Summary
The prior art is difficult to accurately predict the pipe network water volume of mixed flow drainage systems, especially when considering rainfall factors, resulting in low prediction accuracy.
The multi-layer perceptron model is used to preprocess, data mining and analysis and training the water volume monitoring data of the drainage pipeline network, and the water volume monitoring data item is constructed, and the multi-layer perceptron model is used to predict water volume with high time resolution.
It improves the accuracy and time resolution of the pipeline water volume prediction, enhances the practicality of prediction, and can more effectively adjust the operating parameters of the sewage treatment unit and improves the treatment efficiency.
Smart Images

Figure CN113361772B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of pipe network water volume prediction, and in particular to a method and device for predicting the water volume of a mixed flow pipe network. Background Art
[0002] In the urban drainage system, the drainage network collects urban rainwater and sewage and transports them to the treatment unit, playing an important role in connecting the upper and lower parts. In reality, the water volume of the drainage network is usually fluctuating, which will cause impact loads on the sewage treatment unit, increase energy consumption, or cause overflow, thereby increasing the difficulty of sewage treatment unit operation. Therefore, by simulating and predicting the water volume of the drainage network, the operation status of the sewage treatment unit can be adjusted in advance, the operation parameters can be optimized, and the operation of the sewage treatment unit can be more efficient. In my country, there are a large number of combined sewer networks, and there are also mixed and wrong connections in the diversion network. Therefore, in addition to being affected by the production and living water use rules, seasons, date types (working days, weekends) and other factors, the inflow and infiltration caused by rainfall also has a great impact on the water volume of the drainage network. The above factors are complex and have a certain degree of randomness. It is difficult to use a mechanism model to predict the water volume of the network, and it is suitable to use a machine learning algorithm.
[0003] At present, there are two ways to predict the water volume of drainage pipe networks: using artificial fish swarm neural networks and exponential smoothing models to predict the water volume of sewage treatment plants with high time accuracy, but the consideration of rainfall factors is relatively simple and is not suitable for mixed flow pipe networks; there is also the use of ELMAN neural networks to predict sewage volume. This method takes into account factors such as domestic water use, rainfall, and continuous sunny and rainy weather, but the prediction time is on a daily scale and the accuracy is low. Therefore, high-time accuracy prediction for mixed flow drainage systems still needs to be broken through. Summary of the invention
[0004] In view of this, the purpose of the present invention is to overcome the deficiencies of the prior art and provide a method and device for predicting the water volume of a mixed flow pipe network, thereby solving the problem of low accuracy in current prediction of water volume in a pipe network.
[0005] To achieve the above objectives, the present invention adopts the following technical solutions:
[0006] A method for predicting water volume in a mixed flow pipe network, comprising:
[0007] Acquire water volume monitoring data of the drainage network sent by a preset water volume monitoring device, and pre-process the water volume monitoring data; the pre-processing includes: cleaning invalid data and optimizing the time resolution of the water volume monitoring data;
[0008] Performing data mining and analysis on the pre-processed water volume monitoring data to construct water volume monitoring data items;
[0009] Training the water volume monitoring data items to construct a multi-layer perceptron model;
[0010] The multi-layer perceptron model is used to predict the water volume in the pipe network.
[0011] Optionally, the water volume monitoring data includes: minute-by-minute monitoring data of water volume, minute-by-minute monitoring data of instantaneous rainfall, minute-by-minute monitoring data of temperature, minute-by-minute monitoring data of humidity and the time of monitoring data collection;
[0012] The step of obtaining water volume monitoring data of the drainage network sent by a preset water volume monitoring device includes:
[0013] Receiving the minute-by-minute monitoring data of the water volume monitored by a water meter installed on the drainage network;
[0014] Receive the minute-by-minute monitoring data of the instantaneous rainfall monitored by a rain gauge set in the catchment area of the drainage network, the minute-by-minute monitoring data of the temperature monitored by a thermometer, and the minute-by-minute monitoring data of the humidity monitored by a hygrometer;
[0015] The specific collection time of the water volume minute-by-minute monitoring data, the instantaneous rainfall minute-by-minute monitoring data, the temperature minute-by-minute monitoring data and the humidity minute-by-minute monitoring data are extracted as the respective monitoring data collection moments, and the date type corresponding to the collection time is determined.
[0016] Optionally, the preprocessing of the water volume monitoring data includes:
[0017] Performing data cleaning on missing values, abnormal values and erroneous values in the water volume monitoring data;
[0018] The water volume monitoring data after data cleaning is reconstructed in terms of resolution, and the data time accuracy of the water volume monitoring data is adjusted from minute-level accuracy to hour-level accuracy; the water volume monitoring data per minute is adjusted to water volume monitoring data per hour, the instantaneous rainfall monitoring data per minute is adjusted to instantaneous rainfall monitoring data per hour, the temperature monitoring data per minute is adjusted to temperature monitoring data per hour, and the humidity monitoring data per minute is adjusted to humidity monitoring data per hour.
[0019] Optionally, the water volume monitoring data items include: numerical data items and categorical data items;
[0020] The step of performing data mining and analysis on the pre-processed water volume monitoring data to construct water volume monitoring data items includes:
[0021] Calculate the single-field cumulative rainfall and determine the rainfall impact stage based on the instantaneous rainfall hourly monitoring data;
[0022] The numerical data item is constructed from the water volume hourly monitoring data, the instantaneous rainfall hourly monitoring data, the temperature hourly monitoring data, the humidity hourly monitoring data, the single-field cumulative rainfall and the monitoring data collection time;
[0023] The categorical data item is constructed by the rainfall impact stage and the date type.
[0024] Optionally, the calculating of the single-field cumulative rainfall according to the instantaneous rainfall hourly monitoring data includes:
[0025] Calculate the coefficient of variation of the actual rainfall interval under different preset minimum rainfall time intervals based on the instantaneous rainfall hourly monitoring data and the hourly rainfall historical data of the same pipe network catchment area acquired in advance;
[0026] According to the trial calculation results, the minimum rainfall time interval when the coefficient of variation is 1 is selected;
[0027] Divide the rainfall events according to the minimum rainfall time interval;
[0028] The single-event cumulative rainfall is calculated based on the hourly monitoring data of the rainfall events and the instantaneous rainfall.
[0029] Optionally, determining the rainfall impact stage includes:
[0030] The instantaneous rainfall monitoring data is screened according to the set standard, the drought water volume data is selected, and the drought water volume data is divided into the date types; the date types include: working days and non-working days;
[0031] Performing statistical analysis on the drought water volume data to obtain the hourly average water volume of the drought pipe network for 24 hours;
[0032] Obtaining the basic water volume of the dry weather pipe network on working days and the basic water volume of the dry weather pipe network on non-working days according to the hourly average water volume of the dry weather pipe network and the date type;
[0033] The rainfall impact stage is determined based on the rainfall events, the basic water volume of the pipeline network on dry days on working days, and the basic water volume of the pipeline network on dry days on non-working days.
[0034] Optionally, the training of the water volume monitoring data items to construct a multi-layer perceptron model includes:
[0035] Constructing data features based on the water volume monitoring data items;
[0036] The data features are screened using a grid search method to obtain the optimal parameters for model trial calculation;
[0037] Dividing the water volume monitoring data items into a training set and a validation set;
[0038] The training set is used to train an initial multilayer perceptron model based on the optimal parameters calculated according to the model, and the prediction result of the initial multilayer perceptron model is judged using the validation set to determine the initial multilayer perceptron model whose prediction result error meets the preset conditions as the multilayer perceptron model.
[0039] Optionally, the instantaneous rainfall hourly monitoring data is screened according to a set standard to select drought water volume data, including:
[0040] Determine whether there is rainfall on the date corresponding to the monitoring data collection time of the instantaneous rainfall hourly monitoring data according to the instantaneous rainfall hourly monitoring data;
[0041] If there is rainfall, the date is determined to be a rainy day;
[0042] The instantaneous rainfall hourly monitoring data corresponding to the date and the instantaneous rainfall hourly monitoring data corresponding to the set number of days before and after the date are eliminated, and the remaining instantaneous rainfall hourly monitoring data are used as the drought water volume data.
[0043] Optionally, the rainfall impact stages include: a pre-rain stage, a mid-rain stage and a post-rain stage; the mid-rain stage is the stage from the start of a single rainfall to the stop of the rain; the post-rain stage is the stage from the end of the mid-rain stage to the recovery of the water volume in the pipeline network to the daily basic water volume of the pipeline network; the pre-rain stage is from the post-rain stage to the next mid-rain stage.
[0044] A device for predicting water volume in a mixed flow pipe network, comprising:
[0045] A monitoring data acquisition module, used to acquire water volume monitoring data of the drainage network sent by a preset water volume monitoring device, and pre-process the water volume monitoring data;
[0046] A data item construction module, used to perform data mining and analysis on the pre-processed water volume monitoring data to construct water volume monitoring data items;
[0047] A model building module, used to train the water volume monitoring data items and build a multi-layer perceptron model;
[0048] The water volume prediction module is used to predict the water volume of the pipe network using the multi-layer perceptron model.
[0049] The technical solution provided by this application may have the following beneficial effects:
[0050] The present application discloses a method for predicting the water volume of a mixed flow pipe network, comprising: first obtaining water volume monitoring data of a drainage pipe network, and preprocessing the water volume monitoring data; the water volume monitoring data here is detected by a water volume monitoring device set in the drainage pipe network. Then the preprocessed water volume monitoring data is subjected to data mining and analysis to construct water volume monitoring data items; the water volume monitoring data items are trained to construct a multi-layer perceptron model; and the multi-layer perceptron model is used to predict the water volume of the pipe network. In the above method, invalid data in the water volume monitoring data of the drainage pipe network monitored in real time is first cleaned, and the time resolution of the data is improved, and then the preprocessed water volume monitoring data is mined to construct water volume monitoring data items, and then a multi-layer perceptron model is constructed based on the water volume monitoring data items, and the water volume of the pipe network is predicted using the model. In the above method, the water volume monitoring data items are cleaned and the resolution is reconstructed to select high-quality data in the water volume monitoring data, and then the model constructed by the high-quality water volume monitoring data items is used to predict the water volume, thereby improving the prediction accuracy of the multi-layer perceptron model. At the same time, due to the high temporal resolution of water volume monitoring data, the temporal resolution of the prediction results is also high, which greatly improves the practicality of water volume prediction using the multi-layer perceptron model. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0052] Figure 1 is a flow chart of a method for predicting water volume in a mixed flow pipe network provided by an embodiment of the present invention;
[0053] Figure 2 is a flow chart of a method for constructing water volume monitoring data items provided by an embodiment of the present invention;
[0054] Figure 3 is a flow chart of a method for constructing a multi-layer perceptron model provided by an embodiment of the present invention;
[0055] Figure 4 It is a structural diagram of a device for predicting water volume in a mixed flow pipe network provided by an embodiment of the present invention;
[0056] Figure 5 This is a schematic diagram of basic water volume of a pipe network on a dry day under working days and non-working days provided by an embodiment of the present invention;
[0057] Figure 6 is a schematic diagram of a rainfall impact stage provided by an embodiment of the present invention;
[0058] Figure 7 It is a schematic diagram for comparing the model fitting value and the measured value provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0059] To make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be described in detail below. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other implementation methods obtained by ordinary technicians in this field without creative work belong to the scope of protection of the present invention.
[0060] Figure 1 1 is a flow chart of a method for predicting water volume in a mixed flow pipe network provided by an embodiment of the present invention. Figure 1 , a method for predicting water volume in a mixed flow pipe network, comprising:
[0061] Step 101: Acquire water volume monitoring data of the drainage network sent by a preset water volume monitoring device, and pre-process the water volume monitoring data; the pre-processing includes: cleaning invalid data and optimizing the time resolution of the water volume monitoring data.
[0062] In this embodiment, when predicting the water volume of the drainage network, it is first necessary to obtain the relevant water volume monitoring data of the drainage network, such as: water volume minute-by-minute monitoring data, instantaneous rainfall minute-by-minute monitoring data, temperature minute-by-minute monitoring data, humidity minute-by-minute monitoring data and monitoring data collection time. Among them, the water volume minute-by-minute monitoring data is obtained by monitoring the water meter set on the drainage network, the instantaneous rainfall minute-by-minute monitoring data is obtained by monitoring the rain gauge set in the drainage network catchment area, the temperature minute-by-minute monitoring data is obtained by monitoring the thermometer set in the drainage network catchment area, and the humidity minute-by-minute monitoring data is obtained by monitoring the thermometer. At the same time, the specific time of the above-mentioned monitoring data collection is extracted into year, month, day, and time as the respective monitoring data collection time; and then divided into working days and non-working days according to the date type of the monitoring data sampling. It should be noted that in this embodiment, the drainage network can be a branch pipe, a trunk pipe or a main trunk pipe, and the selection of the specific drainage network is not fixed, and can be determined according to the actual situation, as long as the above-mentioned data required for water volume prediction can be monitored.
[0063] After obtaining the water volume monitoring data of the drainage network, the water volume monitoring data must be preprocessed. Specifically, the missing data, abnormal data and erroneous data in the water volume monitoring data must be cleaned first. Among them, the processing of missing data specifically includes: if the rainfall data, temperature data or humidity data is missing, the data node with missing data is directly discarded; if the water volume monitoring data of the drainage network is missing, the missing data is filled by the naive Bayes algorithm. Regarding the processing of erroneous data, it is specifically: the data that has no practical significance and exceeds the range of the monitoring equipment is eliminated, and then the data is discarded or filled according to the missing data processing. Regarding the processing of abnormal data, it is specifically: the data distribution is described by mathematical and statistical methods to obtain the overall distribution characteristics of the data, and then specific data is mined to find abnormal data, and finally professional judgment is made based on domain knowledge to decide whether the abnormal values should be eliminated or retained.
[0064] Then, the time accuracy of the water volume monitoring data after data cleaning is adjusted from minute-level accuracy to hour-level accuracy, and stored in hourly time sequence.
[0065] Step 102: Perform data mining and analysis on the pre-processed water volume monitoring data to construct water volume monitoring data items.
[0066] Step 103: Train the water volume monitoring data items and build a multi-layer perceptron model.
[0067] Step 104: Use the multi-layer perceptron model to predict the water volume of the pipe network.
[0068] Among them, the specific process of step 102, i.e., performing data mining and analysis on the pre-processed water volume monitoring data and constructing water volume monitoring data items is as follows:
[0069] Figure 2 is a flow chart of a method for constructing water volume monitoring data items provided by an embodiment of the present invention. Figure 2 , construct water volume monitoring data items including:
[0070] Step 201: Calculate the single-field cumulative rainfall and determine the rainfall impact stage based on the instantaneous rainfall hourly monitoring data.
[0071] The calculation of the accumulated rainfall in a single session includes:
[0072] First, the coefficient of variation of the actual rainfall interval under different preset minimum rainfall time intervals is calculated based on the instantaneous rainfall hourly monitoring data and the hourly rainfall historical data; the coefficient of variation here is the ratio of the standard deviation to the mean value, and then the minimum rainfall time interval with a coefficient of variation of 1 during the trial calculation is selected. The preset minimum rainfall time interval during the trial calculation here can be determined by personnel according to actual conditions. This step requires multiple trial calculations to set multiple different preset minimum rainfall time intervals to ensure that the coefficient of variation can be 1. At the same time, in this embodiment, in order to improve the accuracy of the coefficient of variation, the data used in the trial calculation not only includes the instantaneous rainfall hourly monitoring data, but also the hourly rainfall historical data in the same catchment area as the instantaneous rainfall hourly monitoring data.
[0073] Then, the rainfall sessions are divided according to the minimum rainfall time interval. In the same rainfall session, the sum of all instantaneous rainfall monitoring data before the current moment is taken as the single-session cumulative rainfall.
[0074] At the same time, the rainfall impact stages are determined to include:
[0075] First, the instantaneous rainfall hourly monitoring data is screened, and the drought water volume data is selected. During the screening, as long as there is rainfall on the day, it is classified as a rainy day, and the rest are dry days; the drought water volume data of the rainy day and the set number of days before and after the rainy day are eliminated, and the date type of the remaining drought water volume data is divided into two categories: working days and non-working days; the pipe network water volume of the remaining drought water volume data is statistically analyzed to obtain the hourly average water volume of the drought pipe network for 24 hours, and then the basic water volume of the drought pipe network on working days and the basic water volume of the drought pipe network on non-working days is obtained; finally, the rainfall impact stage is determined by combining the rainfall events, the basic water volume of the drought pipe network on working days and the basic water volume of the drought pipe network on non-working days. Among them, the selection of the specific days of the set days in this embodiment is not fixed, and can be determined according to the region and city where the pipe network is located.
[0076] Specifically, the rainfall impact stages include: pre-rain stage, mid-rain stage and post-rain stage. The mid-rain stage is the stage from the beginning of a single rainfall to the end of the rain, during which the water volume and water level of the pipe network are affected by the rainfall; the period from the end of the mid-rain stage to the recovery of the water volume of the pipe network to the daily basic water volume of the pipe network is defined as the post-rain stage; the period from the post-rain stage to the next mid-rain stage is defined as the pre-rain stage.
[0077] Step 202: construct a numerical data item from the hourly monitoring data of water volume, hourly monitoring data of instantaneous rainfall, hourly monitoring data of temperature, hourly monitoring data of humidity, single-field cumulative rainfall and the time of monitoring data collection.
[0078] Step 203: Construct categorical data items based on rainfall impact phase and date type.
[0079] In more detail, the specific implementation process of step 103, i.e., training the water volume monitoring data items and constructing the multi-layer perceptron model is as follows:
[0080] Figure 3 is a flow chart of a method for constructing a multi-layer perceptron model provided by an embodiment of the present invention. Figure 3 , training the water volume monitoring data items and constructing a multi-layer perceptron model, including:
[0081] Step 301: Construct data features based on water volume monitoring data items. Use the data features as input data for the multi-layer perceptron model. Among them, numerical data items are directly used as data features, and categorical data items are vector-encoded as data features. Then the data is standardized so that the data format meets the model requirements.
[0082] Step 302: Filter the data features using the grid search method to obtain the optimal parameters for model calculation, wherein the parameters include: the number of input data nodes, the prediction step length, the number of layers of the multi-layer perceptron and the number of nodes in each layer, the activation function and the number of iterations, etc.
[0083] In the process of calculating the optimal parameters, the user first sets a variety of parameter combinations, for example: there are five options for setting the number of data nodes: 8, 12, 16, 20, and 24; there are three options for the prediction step size: 2, 3, and 4; there are three options for the number of layers of the multilayer perceptron: 1, 2, and 3; there are four options for the number of nodes in each layer: 8, 16, 24, and 32; there are three options for the activation function: sigmod, tanh, and ReLU; there are four options for the number of iterations: 100, 200, 300, and 400, for a total of 2160 options, and each option is substituted into the model for calculation. Finally, the optimal parameters for the model calculation are obtained.
[0084] Step 303: Divide the water volume monitoring data items into a training set and a validation set.
[0085] The optimal parameters obtained in the above steps are divided into non-rainfall stage data nodes and rainfall stage data nodes, and then the data nodes are randomly selected to divide the training set and the validation set, so that the data ratio of the non-rainfall stage (pre-rainfall stage) and the rainfall stage (during rain stage and after rain stage) is balanced.
[0086] Step 304: train an initial multilayer perceptron model using the training set according to the optimal parameters calculated by the model, and judge the prediction results of the initial multilayer perceptron model using the validation set, and determine that the initial multilayer perceptron model whose prediction result error meets the preset conditions is the multilayer perceptron model.
[0087] After obtaining the initial model through the training set, the initial multi-layer perceptron model is used for prediction using the validation set. Then, based on the prediction results of the validation set data, the relative mean absolute error (RMAE) is used to judge the quality of the prediction results. The model is continuously iterated and optimized to improve the accuracy of the model. Finally, the initial model with the best prediction results is used as the multi-layer perceptron model.
[0088] In the above embodiments, the accuracy of prediction is improved by taking high-quality data as the basis; semi-automatic preprocessing of monitoring data is realized to improve the quality of data, thereby improving the accuracy of prediction. At the same time, in the water volume monitoring data in the above embodiments, the impact of rainfall on the water volume of the pipe network is deeply considered, and the prediction is more reasonable; based on the actual monitoring data of the drainage pipe network and rainfall, the impact of rainfall on the water volume of the pipe network is deeply analyzed, which fully reflects the actual situation of reality, and the calculation results are more reliable.
[0089] At the same time, in this application, the time resolution of the monitoring data is optimized from minutes to hours, which reduces the randomness and volatility of the data without basically sacrificing the timeliness of the prediction, is closer to the actual situation, and improves the practical application value of the data; furthermore, the prediction results in this application reach hourly accuracy, which can guide the operation of the drainage system: adjust the operating status of the treatment unit in advance, optimize the operating parameters of the treatment unit, and make the operation of the treatment unit more efficient.
[0090] The multi-layer perceptron model trained in this application is highly robust; combining monitoring data analysis and grid search methods for parameter selection, the overall process is simple, convenient, and easy to promote. In addition, the pre-stored method in this application is applicable to pipe networks at different levels and has strong universality. Considering the differences in the water flow patterns of branch pipes, trunk pipes, and main trunk pipes, models are constructed and parameters are selected for prediction, which has strong universality and a wide range of applications.
[0091] In order to more clearly introduce the water volume prediction method in this application, an example is given below:
[0092] The following scenario is introduced with the water source of the sewage treatment plant being a diversion drainage system in a northern river basin, where there are a small number of mixed connections and some combined sewer areas. The specific implementation process is as follows:
[0093] 1. Monitoring data collection, preprocessing and storage
[0094] For this drainage system, a water meter is arranged on the main pipe to obtain minute-by-minute monitoring data of the water volume in the main pipe; a rain gauge with temperature and humidity functions is arranged in the catchment area of the drainage system to obtain minute-by-minute monitoring data of rainfall, temperature and humidity.
[0095] Preprocess the collected monitoring data to exclude erroneous values and abnormal values;
[0096] The temporal resolution of the preprocessed monitoring data is reconstructed into hourly level. Each data node contains numerical data items (instantaneous rainfall, pipe network water volume, temperature, humidity, specific time) and categorical data items (date type, rainfall stage). The date type is divided into working days and non-working days, and the specific time is divided according to the 24-hour system, from 0 to 23:00.
[0097] 2. Monitoring data analysis and information mining
[0098] Analyze the fluctuation pattern of daily water volume in the pipe network and obtain the basic water volume of the pipe network on dry days, such as Figure 5 The following are the basic water volume of the network in dry days under the conditions of working days and non-working days respectively;
[0099] Combining rainfall monitoring data and rainfall duration data, it is found that when the coefficient of variation of rainfall interval is 1, the rainfall interval is 13h, and this is used as the basis for dividing rainfall events;
[0100] According to the division of rainfall events, the cumulative rainfall of a single event is obtained and added to the data items of the data node as a numerical data item;
[0101] Combined with the classification of rainfall events and the basic water volume of the pipe network on dry days, the rainfall impact stage (such as Figure 6 ): The mid-rain stage refers to the period from the start of a single rainfall to the stop of rain; the period from the end of the mid-rain stage to the recovery of the water volume in the pipeline network to the daily basic water volume in the pipeline network is defined as the post-rain stage; the period from the post-rain stage to the next mid-rain stage is defined as the pre-rain stage.
[0102] 3. Build a multi-layer perceptron model to predict the water volume of the pipe network
[0103] For categorical data in data nodes, unique hot encoding is used to construct data features; for numerical data in data nodes, they are directly used as data features;
[0104] Standardize the data. X ′ = ( X -Xstd) / Xmean ,in: X ′ is the input value after standardization. X is the original input value, Xstd and Xmean is the standard deviation and mean;
[0105] The grid search method was used to determine the parameters of the multilayer perceptron model, including: the input time series data step size is 8, the prediction step size of the trunk is 2, the number of multilayer perceptron layers is 3, the number of nodes per layer is 16, the activation function is ReLU, and the number of iterations is 300;
[0106] The data were randomly sampled, with 80% of the samples used as training sets and 20% used as validation sets. The data ratio of the non-raining stage (pre-raining stage) and the raining stage (during and after raining stage) was ensured to be 1:1 during sampling.
[0107] The comparison between the model fitting value and the measured value is as follows Figure 7 , the current relative average error of the validation set is 10%. With the accumulation of data, the model is continuously iterated and optimized to continuously improve the accuracy of the model.
[0108] Corresponding to a method for predicting the water volume of a mixed flow pipe network provided in an embodiment of the present invention, an embodiment of the present invention further provides a device for predicting the water volume of a mixed flow pipe network. Please refer to the following embodiments.
[0109] Figure 4 is a structural diagram of a device for predicting water volume in a mixed flow pipe network provided by an embodiment of the present invention. Figure 4 , a mixed flow pipe network water volume prediction device, comprising:
[0110] The monitoring data acquisition module 401 is used to acquire the water volume monitoring data of the drainage network sent by the preset water volume monitoring equipment, and pre-process the water volume monitoring data.
[0111] The data item construction module 402 is used to perform data mining and analysis on the pre-processed water volume monitoring data to construct water volume monitoring data items.
[0112] The model building module 403 is used to train the water volume monitoring data items and build a multi-layer perceptron model.
[0113] The water volume prediction module 404 is used to predict the water volume of the pipe network using the multi-layer perceptron model.
[0114] Among them, the data item construction module 402 is specifically used to: calculate the single-field cumulative rainfall and determine the rainfall impact stage based on the instantaneous rainfall hourly monitoring data; construct the numerical data item by the water volume hourly monitoring data, the instantaneous rainfall hourly monitoring data, the temperature hourly monitoring data, the humidity hourly monitoring data, the single-field cumulative rainfall and the monitoring data collection time; construct the categorical data item by the rainfall impact stage and the date type.
[0115] The model building module 403 is specifically used to: construct data features based on the water volume monitoring data items; use the grid search method to screen the data features to obtain the optimal parameters for model trial calculation; divide the water volume monitoring data items into training sets and verification sets; use the training set to train the initial multi-layer perceptron model based on the optimal parameters for the model trial calculation, and use the verification set to judge the prediction results of the initial multi-layer perceptron model, and determine that the initial multi-layer perceptron model whose prediction result error meets the preset conditions is the multi-layer perceptron model.
[0116] The above-mentioned device constructs a multi-layer perceptron model by monitoring the water volume monitoring data of the drainage network. The device is based on high-quality data to improve the accuracy of the prediction, and deeply considers the impact of rainfall on the water volume of the network. The prediction is more reasonable. At the same time, the prediction time resolution is high and the practical application value is high.
[0117] In order to more clearly introduce the hardware system for implementing the embodiment of the present invention, corresponding to the method for predicting the water volume of a mixed flow pipe network provided by the embodiment of the present invention, the embodiment of the present invention also provides a device for predicting the water volume of a mixed flow pipe network. Please refer to the following embodiments.
[0118] A mixed flow pipe network water volume prediction device, comprising:
[0119] A processor, and a memory connected to the processor;
[0120] The memory is used to store a computer program, and the computer program is used at least to execute the above-mentioned method for predicting the water volume of a mixed flow pipe network; the processor is used to call and execute the computer program in the memory.
[0121] It can be understood that the same or similar parts of the above embodiments can be referenced to each other, and the contents not described in detail in some embodiments can refer to the same or similar contents in other embodiments.
[0122] It should be noted that, in the description of the present invention, the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. In addition, in the description of the present invention, unless otherwise specified, the meaning of "plurality" refers to at least two.
[0123] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, segment or portion of code that includes one or more executable instructions for implementing the steps of a specific logical function or process, and the scope of the preferred embodiments of the present invention includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by those skilled in the art to which the embodiments of the present invention belong.
[0124] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0125] A person skilled in the art may understand that all or part of the steps in the method for implementing the above-mentioned embodiment may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiment.
[0126] In addition, each functional unit in each embodiment of the present invention may be integrated into a processing module, or each unit may exist physically separately, or two or more units may be integrated into one module. The above-mentioned integrated module may be implemented in the form of hardware or in the form of a software functional module. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.
[0127] The storage medium mentioned above can be a read-only memory, a magnetic disk or an optical disk, etc.
[0128] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.
[0129] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.
Claims
1. A method for predicting water volume in a mixed flow pipe network, characterized in that: include: Acquire water volume monitoring data of the drainage network sent by a preset water volume monitoring device, and pre-process the water volume monitoring data; The preprocessing includes: cleaning invalid data and optimizing the time resolution of the water volume monitoring data; Performing data mining and analysis on the pre-processed water volume monitoring data to construct water volume monitoring data items; Training the water volume monitoring data items to construct a multi-layer perceptron model; Predicting the water volume of the pipe network using the multi-layer perceptron model; The water volume monitoring data includes: minute-by-minute water volume monitoring data, minute-by-minute instantaneous rainfall monitoring data, minute-by-minute temperature monitoring data, minute-by-minute humidity monitoring data and monitoring data collection time; The step of obtaining water volume monitoring data of the drainage network sent by a preset water volume monitoring device includes: Receiving the minute-by-minute monitoring data of the water volume monitored by a water meter installed on the drainage network; Receive the minute-by-minute monitoring data of the instantaneous rainfall monitored by a rain gauge set in the catchment area of the drainage network, the minute-by-minute monitoring data of the temperature monitored by a thermometer, and the minute-by-minute monitoring data of the humidity monitored by a hygrometer; Extracting specific collection times of the water volume minute-by-minute monitoring data, the instantaneous rainfall minute-by-minute monitoring data, the temperature minute-by-minute monitoring data, and the humidity minute-by-minute monitoring data as respective monitoring data collection moments, and determining the date type corresponding to the collection time; The preprocessing of the water volume monitoring data comprises: Performing data cleaning on missing values, abnormal values and erroneous values in the water volume monitoring data; Reconstruct the resolution of the water volume monitoring data after data cleaning, and adjust the data time accuracy of the water volume monitoring data from minute-level accuracy to hour-level accuracy; adjust the water volume monitoring data by minute to water volume monitoring data by hour, adjust the instantaneous rainfall monitoring data by minute to instantaneous rainfall monitoring data by hour, adjust the temperature monitoring data by minute to temperature monitoring data by hour, and adjust the humidity monitoring data by minute to humidity monitoring data by hour; The water volume monitoring data items include: numerical data items and categorical data items; The step of performing data mining and analysis on the pre-processed water volume monitoring data to construct water volume monitoring data items includes: Calculate the single-field cumulative rainfall and determine the rainfall impact stage based on the instantaneous rainfall hourly monitoring data; The numerical data item is constructed from the water volume hourly monitoring data, the instantaneous rainfall hourly monitoring data, the temperature hourly monitoring data, the humidity hourly monitoring data, the single-field cumulative rainfall and the monitoring data collection time; Constructing the categorical data item by the rainfall impact stage and the date type; The training of the water volume monitoring data items to construct a multi-layer perceptron model includes: Constructing data features based on the water volume monitoring data items; The data features are screened using a grid search method to obtain the optimal parameters for model trial calculation; Dividing the water volume monitoring data items into a training set and a validation set; The training set is used to train the initial multilayer perceptron model according to the optimal parameters calculated by the model, and the prediction result of the initial multilayer perceptron model is judged using the validation set to determine the initial multilayer perceptron model whose prediction result error meets the preset conditions as the multilayer perceptron model.
2. The method according to claim 1, characterized in that The method of calculating the single-field cumulative rainfall according to the instantaneous rainfall hourly monitoring data comprises: Calculate the coefficient of variation of the actual rainfall interval under different preset minimum rainfall time intervals based on the instantaneous rainfall hourly monitoring data and the hourly rainfall historical data of the same pipe network catchment area acquired in advance; According to the trial calculation results, the minimum rainfall time interval when the coefficient of variation is 1 is selected; Divide the rainfall events according to the minimum rainfall time interval; The single-event cumulative rainfall is calculated based on the hourly monitoring data of the rainfall events and the instantaneous rainfall.
3. The method according to claim 2, characterized in that The determination of rainfall impact stages includes: The instantaneous rainfall monitoring data is screened according to the set standard, the drought water volume data is selected, and the drought water volume data is divided into the date types; the date types include: working days and non-working days; Performing statistical analysis on the drought water volume data to obtain the hourly average water volume of the drought pipe network for 24 hours; Obtaining the basic water volume of the dry weather pipe network on working days and the basic water volume of the dry weather pipe network on non-working days according to the hourly average water volume of the dry weather pipe network and the date type; The rainfall impact stage is determined based on the rainfall events, the basic water volume of the pipeline network on dry days on working days, and the basic water volume of the pipeline network on dry days on non-working days.
4. The method according to claim 3, characterized in that The instantaneous rainfall monitoring data is screened according to set standards to select dry day water volume data, including: Determine whether there is rainfall on the date corresponding to the monitoring data collection time of the instantaneous rainfall hourly monitoring data according to the instantaneous rainfall hourly monitoring data; If there is rainfall, the date is determined to be a rainy day; The instantaneous rainfall hourly monitoring data corresponding to the date and the instantaneous rainfall hourly monitoring data corresponding to the set number of days before and after the date are eliminated, and the remaining instantaneous rainfall hourly monitoring data are used as the drought water volume data.
5. The method according to claim 4, characterized in that The rainfall impact stages include: pre-rain stage, mid-rain stage and post-rain stage; The rain stage is the stage from the start of a single rainfall to the stop of rain; the post-rain stage is the stage from the end of the rain stage to the recovery of the water volume in the pipeline network to the daily basic water volume of the pipeline network; the pre-rain stage is from the post-rain stage to the next rain stage.
6. A device for predicting water volume in a mixed flow pipe network, characterized in that: include: A monitoring data acquisition module, used to acquire water volume monitoring data of the drainage network sent by a preset water volume monitoring device, and pre-process the water volume monitoring data; The water volume monitoring data includes: minute-by-minute water volume monitoring data, minute-by-minute instantaneous rainfall monitoring data, minute-by-minute temperature monitoring data, minute-by-minute humidity monitoring data and monitoring data collection time; The step of obtaining water volume monitoring data of the drainage network sent by a preset water volume monitoring device includes: Receiving the minute-by-minute monitoring data of the water volume monitored by a water meter installed on the drainage network; Receive the minute-by-minute monitoring data of the instantaneous rainfall monitored by a rain gauge set in the catchment area of the drainage network, the minute-by-minute monitoring data of the temperature monitored by a thermometer, and the minute-by-minute monitoring data of the humidity monitored by a hygrometer; Extracting specific collection times of the water volume minute-by-minute monitoring data, the instantaneous rainfall minute-by-minute monitoring data, the temperature minute-by-minute monitoring data, and the humidity minute-by-minute monitoring data as respective monitoring data collection moments, and determining the date type corresponding to the collection time; The preprocessing of the water volume monitoring data comprises: Performing data cleaning on missing values, abnormal values and erroneous values in the water volume monitoring data; Reconstruct the resolution of the water volume monitoring data after data cleaning, and adjust the data time accuracy of the water volume monitoring data from minute-level accuracy to hour-level accuracy; adjust the water volume monitoring data by minute to water volume monitoring data by hour, adjust the instantaneous rainfall monitoring data by minute to instantaneous rainfall monitoring data by hour, adjust the temperature monitoring data by minute to temperature monitoring data by hour, and adjust the humidity monitoring data by minute to humidity monitoring data by hour; A data item construction module, used to perform data mining and analysis on the pre-processed water volume monitoring data to construct water volume monitoring data items; The water volume monitoring data items include: numerical data items and categorical data items; The step of performing data mining and analysis on the pre-processed water volume monitoring data to construct water volume monitoring data items includes: Calculate the single-field cumulative rainfall and determine the rainfall impact stage based on the instantaneous rainfall hourly monitoring data; The numerical data item is constructed from the water volume hourly monitoring data, the instantaneous rainfall hourly monitoring data, the temperature hourly monitoring data, the humidity hourly monitoring data, the single-field cumulative rainfall and the monitoring data collection time; Constructing the categorical data item by the rainfall impact stage and the date type; A model building module, used to train the water volume monitoring data items and build a multi-layer perceptron model; The training of the water volume monitoring data items to construct a multi-layer perceptron model includes: Constructing data features based on the water volume monitoring data items; The data features are screened using a grid search method to obtain the optimal parameters for model trial calculation; Dividing the water volume monitoring data items into a training set and a validation set; The initial multilayer perceptron model is trained using the training set according to the optimal parameters of the model trial calculation, and the prediction results of the initial multilayer perceptron model are judged using the verification set, and the initial multilayer perceptron model whose prediction result error meets the preset conditions is determined as the multilayer perceptron model The water volume prediction module is used to predict the water volume of the pipe network using the multi-layer perceptron model.
Citation Information
Patent Citations
Method and system for evaluating inflow and infiltration of drainage pipe network
CN108376318A
Daily sewage amount prediction method based on ELMAN neural network
CN110110890A
Urban drainage monitoring and early warning method and system
CN110646867A
Daily water consumption prediction method based on big data
CN111210093A
Pipe network regulation and storage coupling water plant high-load processing system, method, device and equipment
CN112408524A
