A Machine Learning-Based Optimization Method and System for Water Flow Management
Through multi-convolution neural network and frequency domain analysis combined with physical constraints, the complex flow state and signal interference problems in water flow metering and distribution are solved, and efficient and precise management of water flow is achieved.
Patent Information
- Application Number
- CN202510398728.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-01
- Publication Date
- 2025-07-29
- Estimated Expiration
- 2045-04-01
AI Technical Summary
The existing water flow metering methods have complex flow states and severe signal interference in open channels and rivers, resulting in unstable flow velocity measurement and large data fluctuations. It is difficult for traditional algorithms to accurately extract the characteristics and flow direction of water flow, and lack physical constraints in water flow allocation and poor dynamic adaptability.
Multi-convolution integration improved one-dimensional convolution neural network is used to optimize water flow characteristics, combine the improved timing prediction network of Doppler effect analysis and frequency domain analysis for flow direction modeling, and combine the reinforcement learning of physical constraints and hydraulic equations for water flow allocation optimization.
It improves the stability and intelligence of water flow metering, improves the prediction effect of flow direction modeling, and realizes accurate adjustment and dynamic adaptability of flow distribution.
Smart Images

Figure CN119918752B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of water flow measurement and management, and specifically refers to an optimization method and system for water flow management based on machine learning. Background Art
[0002] The optimization method and system for water flow management based on machine learning aims to optimize the allocation and regulation of water resources through intelligent algorithms and models. This method uses classical algorithms or machine learning techniques to automatically analyze and predict the changing trends of water flow by real-time monitoring data such as water flow rate, velocity, and direction, and conducts optimized scheduling according to demands. Its main functions are to improve the utilization efficiency of water resources, reduce waste, avoid resource shortages or surpluses caused by uneven water flow, and achieve dynamic regulation to ensure that under different environmental conditions, the water flow allocation can quickly adapt to changes and guarantee the continuous and stable supply of water resources. This intelligent optimization method can be widely applied to fields such as agricultural irrigation, urban water supply, and river management to help achieve more scientific and efficient water flow management.
[0003] However, in the existing water flow measurement and management process, there are technical problems in the existing water flow measurement methods. Due to complex flow patterns and signal interference in open channels and rivers, it is very difficult to stably and accurately measure the flow velocity. And in the flow measurement by conventional flowmeter methods, there are problems of large data fluctuations and unstable signal quality.
[0004] In the existing intelligent extraction methods for water flow characteristics, there are traditional classical algorithms, namely digital filtering algorithms and curve fitting algorithms. In actual measurement, since the channel may be narrow, the electromagnetic waves emitted by the radar may hit the shore, and there may be a large number of floating objects on the water surface, resulting in continuous changes in the signal amplitude. Factors such as relatively rapid water flow and poor flow patterns can all lead to incorrect Doppler frequency shift identification, thus unable to correctly measure the surface flow velocity. The most intuitive manifestation is that the measured flow velocity data will fluctuate widely. Due to the complex and diverse on-site conditions of water flow measurement and management, there will be situations where filtering cannot be completed.
[0005] In the existing water flow frequency shift and flow direction modeling and prediction methods, there are technical problems of large noise interference in water flow frequency shift signals, complex flow direction changes, and difficulty in comprehensively capturing spatio-temporal characteristics. In the existing intelligent water flow management process, there are technical problems that the water flow allocation scheme lacks physical constraints, making it difficult to achieve precise regulation of flow allocation and poor dynamic adaptability. Summary of the Invention
[0006] In view of the above situation, to overcome the defects of the prior art, the present invention provides an optimization method and system for water flow management based on machine learning. In the existing water flow measurement and management process, there are problems in the existing water flow measurement methods. Due to the complex flow patterns and signal interference in open channels and rivers, it is difficult to measure the flow velocity stably and accurately. In the conventional flowmeter method, there are problems of large data fluctuations and unstable signal quality in flow measurement. This solution creatively adopts an overall intelligent algorithm process that combines feature optimization, flow direction modeling, and optimization management. By feature optimization and flow direction modeling, qualitative and quantitative information of water flow is obtained, and in accordance with the intelligent process of optimization management, the quality and intelligence of water flow measurement to management are improved, and the overall usability is also improved. In the existing intelligent extraction method of water flow characteristics, there are traditional classical algorithms, namely digital filtering algorithms and curve fitting algorithms. In actual measurement, due to the narrowness of the channel, the electromagnetic waves emitted by the radar may hit the shore, and there may be a large number of floating objects on the water surface, resulting in continuous changes in the signal amplitude. The water flow may be relatively rapid and the flow pattern may be poor. All these factors may lead to incorrect Doppler frequency shift identification, thus unable to correctly measure the surface flow velocity. The most intuitive manifestation is that the measured flow velocity data will fluctuate widely. Due to the complexity and diversity of the site of water flow measurement and management, there may be situations where filtering cannot be completed. This solution creatively adopts a one-dimensional convolutional neural network improved by multi-convolution integration to optimize water flow characteristics. By adaptively improving and designing the structure of the one-dimensional convolutional network, the intelligence and efficiency of water flow feature extraction are improved. While solving the problem that a single Doppler frequency shift method is prone to identification errors, the stability and reliability of the method as a whole are also improved. In the existing water flow frequency shift and flow direction modeling prediction method, there are technical problems of large noise interference in water flow frequency shift signals, complex flow direction changes, and difficulty in comprehensively capturing spatio-temporal characteristics. This solution creatively adopts an improved time series prediction network that combines Doppler effect analysis and frequency domain analysis. By combining two classical modeling analysis methods and spatio-temporal characteristics for combined prediction, the modeling prediction effect of water flow frequency shift and flow direction is generally improved. In the existing intelligent water flow management process, there are technical problems that the water flow distribution scheme lacks physical constraints, it is difficult to achieve precise adjustment of flow distribution, and the dynamic adaptability is poor. This solution creatively adopts a reinforcement learning dynamic water flow distribution adjustment method that combines physical constraints and hydraulic equations to optimize the comprehensive management of water flow. By combining the physical constraint model, the physical characteristics of the water flow management results are optimized. At the same time, through the improvement of the reward function and the integration of frequency shift and flow direction information, the flexibility and accuracy of water flow management are generally improved.
[0007] The technical solution adopted by the present invention is as follows: An optimization method for water flow management based on machine learning provided by the present invention, the method comprising the following steps:
[0008] Step S1: Data management;
[0009] Step S2: Optimization of water flow characteristics;
[0010] Step S3: Modeling of frequency shift flow direction;
[0011] Step S4: Optimization of water flow management.
[0012] Further, in step S1, the data management is used to collect, store, and preprocess the original data set required for water flow management. Specifically, the original data for water flow management is obtained through multi-source sensing data acquisition, and the optimized water flow management data is obtained through data preprocessing;
[0013] The original data for water flow management includes water flow data, water level data, environmental support data, signal evaluation data, water flow pattern data, and spatio-temporal data;
[0014] The data preprocessing includes data denoising, anomaly handling, data normalization, and data smoothing operations;
[0015] The optimized water flow management data includes optimized water flow data, optimized water level data, optimized environmental support data, optimized signal evaluation data, optimized water flow pattern data, and optimized spatio-temporal data.
[0016] Further, in step S2, the optimization of water flow characteristics is used to extract and optimize the spatio-temporal characteristics of water flow. Specifically, based on the optimized water flow management data, a one-dimensional convolutional neural network improved by multi-convolution integration is used to optimize the water flow characteristics to obtain water flow spatio-temporal characteristic data, including the following steps:
[0017] Step S21: Construct a water flow input layer, specifically by using the optimized water flow management data as input data samples to construct the water flow input layer;
[0018] Step S22: Construct a one-dimensional convolutional layer improved by multi-convolution integration, specifically by integrating a depthwise separable convolutional layer, a hybrid dilated convolutional layer, and an adaptive frequency domain pooling layer in sequence to obtain a one-dimensional convolutional layer improved by multi-convolution integration;
[0019] The depthwise separable convolutional layer specifically uses a depthwise separable convolution with a dilation factor of 2 and sets the number of channels to 64;
[0020] The hybrid dilated convolutional layer is specifically constructed by building a dilated convolution module with alternating dilation factors of [1, 3, 5] and introducing channel attention after each dilated convolution module to construct the hybrid dilated convolutional layer;
[0021] The adaptive frequency-domain pooling layer specifically replaces the fully connected layer in the standard one-dimensional convolution module with an adaptive frequency-domain pooling layer to retain the time-series frequency information;
[0022] Step S23: Construct a branch output layer, specifically by constructing a regression branch and a classification branch to predict the Doppler shift value and the flow direction category;
[0023] The regression branch is used to output the Doppler frequency shift value and represent the water flow time characteristics;
[0024] The classification branch is used to output the flow direction category, including forward, reverse, interference, and turbulence, and represent the water flow spatial characteristics;
[0025] Step S24: Construct an optimized loss function, specifically by constructing a mean square error loss and a cross-entropy loss, performing weighted summation, and constructing the optimized loss function;
[0026] Step S25: Train the water flow feature optimization model, specifically by using the water flow input layer, the improved one-dimensional convolution layer with multi-convolution integration, the branch output layer, and the optimized loss function to train the water flow feature optimization model and obtain the water flow feature optimization model Model FLNX ;
[0027] Step S26: Optimize the water flow features, specifically by using the optimized water flow management data and the water flow feature optimization model Model FLNX , to optimize the water flow features and obtain the water flow spatio-temporal feature data.
[0028] Furthermore, in step S3, the frequency shift and flow direction modeling is used to establish a flow direction prediction model based on the water flow frequency shift to identify the change trend and flow direction of the water flow. Specifically, according to the water flow spatio-temporal feature data, an improved time-series prediction network combining Doppler effect analysis and frequency-domain analysis is used for frequency-domain flow direction modeling to obtain the frequency shift and flow direction change prediction data, including the following steps:
[0029] Step S31: Construct a water flow spatio-temporal feature input layer, specifically by using the water flow spatio-temporal feature data as the original data input for frequency shift and flow direction modeling to construct the water flow spatio-temporal feature input layer;
[0030] Step S32: Doppler effect analysis, specifically by performing frequency shift value spectrum analysis and modeling on the original data input for frequency shift and flow direction modeling according to the Doppler effect to obtain the Doppler frequency shift analysis data;
[0031] Step S33: Frequency-domain feature analysis, specifically by performing frequency-domain feature extraction and analysis on the original data input for frequency shift and flow direction modeling through fast Fourier transform to obtain the frequency-domain feature data;
[0032] Step S34: Construct an improved time series prediction network. Specifically, based on the Doppler frequency shift analysis data and the frequency domain feature data, through frequency domain attention optimization, multi-scale time series modeling, construction of a frequency domain long short-term memory network, and construction of a modeling layer, the improved time series prediction network is obtained;
[0033] Step S35: Model the frequency shift flow direction. Specifically, through the water flow rate spatio-temporal feature input layer, the Doppler effect analysis, the frequency domain feature analysis, and the improved time series prediction network, model training and data prediction for the frequency shift flow direction modeling are performed to obtain frequency shift flow direction change prediction data.
[0034] Further, in Step S4, the water flow rate management optimization is used to comprehensively manage the allocation and regulation of the water flow rate. Specifically, by combining the water flow rate spatio-temporal feature data and the frequency shift flow direction change prediction data, a reinforcement learning dynamic water flow rate allocation adjustment method that combines physical constraints and hydraulic equations is adopted to perform comprehensive management optimization of the water flow rate, and water flow rate management allocation reference data is obtained, including the following steps:
[0035] Step S41: Model the water flow rate management problem to define the management objective of the water flow rate. Specifically, minimizing the flow rate fluctuation and optimizing the water flow distribution are used as the basic objective model of the water flow rate management problem to obtain the water flow rate management objective model;
[0036] Step S42: Model the physical constraints. Specifically, construct the mass conservation equation and the hydraulic equation as the physical constraint model of the model;
[0037] Step S43: Reinforcement learning for dynamic water flow rate allocation. Specifically, based on the water flow rate management objective model, construct a standard reinforcement learning parameter set and improve the design of the reward function to obtain a dynamic water flow rate allocation reinforcement learning architecture;
[0038] The improvement design of the reward function specifically refers to weighting according to the smoothness of the water flow rate adjustment and the smoothness of the flow rate frequency shift to obtain a dynamic water flow rate allocation reward function, and performing reinforcement learning training based on the dynamic water flow rate allocation reward function;
[0039] Step S44: Iterative training for water flow rate management optimization. Specifically, adopt the deep Q-value learning method to perform iterative optimization of the water flow rate allocation and Q-value update to obtain the optimal model for water flow rate management optimization;
[0040] Step S45: Water flow rate management. Specifically, based on the optimal model for water flow rate management optimization, perform water flow rate management to obtain water flow rate management allocation reference data;
[0041] The reference data for water flow management and distribution specifically includes regional water flow distribution suggestions, flow adjustment strategies, and comprehensive prediction reference data for flow direction and flow rate.
[0042] An optimization system for water flow management based on machine learning provided by the present invention includes a data management module, a feature processing module, a prediction and optimization module, and an output management module.
[0043] The data management module is used for data management. Through data management, optimized water flow management data is obtained and sent to the feature processing module.
[0044] The feature processing module is used for optimizing water flow features. Through optimizing water flow features, spatio-temporal feature data of water flow is obtained and sent to the prediction and optimization module.
[0045] The prediction and optimization module is used for modeling frequency shift and flow direction. Through modeling frequency shift and flow direction, prediction data of frequency shift and flow direction change is obtained and sent to the output management module.
[0046] The output management module is used for optimizing water flow management. Through optimizing water flow management, reference data for water flow management and distribution is obtained.
[0047] The beneficial effects achieved by the present invention with the above scheme are as follows:
[0048] (1) Aiming at the technical problems existing in the existing water flow measurement and management process, that is, in the existing water flow measurement methods, due to the complex flow states in open channels and rivers and problems such as signal interference, it is very difficult to stably and accurately measure the flow velocity, and in the flow measurement by the conventional flowmeter method, there are problems of large data fluctuations and unstable signal quality. This scheme creatively adopts an overall intelligent algorithm process combining feature optimization, flow direction modeling, and optimization management. Qualitative and quantitative information of water flow is obtained through feature optimization and flow direction modeling, and in accordance with the intelligent process of optimization management, the quality and intelligence of water flow measurement to management are improved, and the overall usability is also improved.
[0049] (2) In the existing intelligent extraction methods for water flow characteristics, there are traditional classical algorithms, namely digital filtering algorithms and curve fitting algorithms. In actual measurement, due to the possible narrowness of the channel, the electromagnetic waves emitted by the radar may hit the shore. At the same time, there may be a large number of floating objects on the water surface, resulting in continuous changes in the signal amplitude. The water flow may be relatively turbulent and the flow pattern may be poor. These factors can all lead to incorrect identification of the Doppler frequency shift, thus making it impossible to correctly measure the surface velocity. The most intuitive manifestation is that the measured velocity data will fluctuate widely. Due to the complex and diverse on-site conditions of water flow measurement and management, there will be situations where filtering cannot be completed. This solution creatively uses a one-dimensional convolutional neural network improved by multi-convolution integration to optimize water flow characteristics. By adaptively improving and designing the structure of the one-dimensional convolutional network, the intelligence and efficiency of water flow characteristic extraction are improved. While solving the problem that a single Doppler frequency shift method is prone to identification errors, the overall stability and reliability of the method are also enhanced;
[0050] (3) In the existing water flow frequency shift and flow direction modeling and prediction methods, there are technical problems such as large noise interference in water flow frequency shift signals, complex flow direction changes, and difficulty in comprehensively capturing spatio-temporal characteristics. This solution creatively uses an improved time series prediction network that combines Doppler effect analysis and frequency domain analysis. By combining two classical modeling analysis methods and spatio-temporal characteristics for combined prediction, the modeling and prediction effects of water flow frequency shift and flow direction are improved as a whole;
[0051] (4) In the existing intelligent water flow management process, there are technical problems such as the lack of physical constraints in the water flow distribution scheme, difficulty in achieving precise adjustment of flow distribution, and poor dynamic adaptability. This solution creatively uses a reinforcement learning dynamic water flow distribution adjustment method that combines physical constraints and hydraulic equations to optimize comprehensive water flow management. By combining physical constraint models, the physical characteristics of water flow management results are optimized. At the same time, through the improvement of the reward function and the incorporation of frequency shift and flow direction information, the flexibility and accuracy of water flow management are improved as a whole. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] Figure 1 It is a schematic flow chart of a water flow management optimization method based on machine learning provided by the present invention;
[0053] Figure 2 It is a schematic diagram of a water flow management optimization system based on machine learning provided by the present invention;
[0054] Figure 3 It is a schematic flow chart of the water flow characteristic optimization in step S2;
[0055] Figure 4 It is a schematic flow chart of the frequency shift and flow direction modeling in step S3;
[0056] Figure 5 It is a schematic flow diagram for the optimization of water flow rate management in step S4.
[0057] The accompanying drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the present invention and do not constitute a limitation to the present invention. Detailed implementation manners
[0058] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments; based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the scope of protection of the present invention.
[0059] In the description of the present invention, it should be understood that the terms "upper", "lower", "front", "rear", "left", "right", "top", "bottom", "inner", "outer", etc. indicating the orientation or position relationship are based on the orientation or position relationship shown in the accompanying drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and thus should not be construed as a limitation to the present invention.
[0060] Example 1, refer to Figure 1 , A method for optimizing water flow rate management based on machine learning provided by the present invention, the method includes the following steps:
[0061] Step S1: Data management;
[0062] Step S2: Optimization of water flow rate characteristics;
[0063] Step S3: Modeling of frequency shift flow direction;
[0064] Step S4: Optimization of water flow rate management.
[0065] By performing the above operations, aiming at the technical problems existing in the existing water flow rate measurement and management process, that is, in the existing water flow rate measurement method, due to the complex flow state and signal interference in open channels and rivers, it is difficult to measure the flow velocity stably and accurately, and the conventional flowmeter method has large data fluctuations and unstable signal quality problems in flow measurement. This solution creatively adopts an overall intelligent algorithm process combining feature optimization, flow direction modeling and optimization management. Through feature optimization and flow direction modeling, qualitative and quantitative information of water flow rate is obtained, and in accordance with the intelligent process of optimization management, the quality and intelligence of water flow rate measurement to management are improved, and the overall usability is also improved.
[0066] Example 2, refer toFigure 1 and Figure 2 In step S1, the data management is used to collect, store, and preprocess the original data set required for water flow management. Specifically, through multi-source sensing data acquisition, the original water flow management data is obtained, and through data preprocessing, the optimized water flow management data is obtained;
[0067] The original water flow management data includes water flow data, water level data, environmental support data, signal evaluation data, water flow pattern data, and spatio-temporal data;
[0068] The water flow data includes the flow velocity and flow rate values measured by a radar flowmeter;
[0069] The environmental support data includes meteorological condition data and hydrological condition data; the meteorological condition data specifically includes temperature, humidity, and wind speed data, and the hydrological condition data specifically includes precipitation and river channel slope data;
[0070] The signal evaluation data includes signal strength, signal-to-noise ratio, and echo signal quality data generated by a radar flowmeter;
[0071] The water flow pattern data includes water flow direction data, turbulence intensity data, and flow velocity change data;
[0072] The spatio-temporal data includes timestamp and geographical location reference information data;
[0073] The data preprocessing includes data denoising, anomaly processing, data standardization, and data smoothing operations;
[0074] The data denoising includes signal filtering and wavelet transform denoising operations;
[0075] For the anomaly processing, standard deviation statistics is specifically used to identify outliers, and linear interpolation is used to fill in outliers and missing values;
[0076] For the data standardization, the maximum-minimum standardization method is specifically used to standardize the range of numerical data;
[0077] For the data smoothing operation, the exponential smoothing method is specifically used to smooth and optimize the time series data;
[0078] The optimized water flow management data includes optimized water flow data, optimized water level data, optimized environmental support data, optimized signal evaluation data, optimized water flow pattern data, and optimized spatio-temporal data.
[0079] Example 3, refer to Figure 1 、 Figure 2 and Figure 3, based on the above embodiment, in step S2, the water flow rate feature optimization is used to extract and optimize the spatio-temporal features of the water flow rate. Specifically, according to the optimized water flow rate management data, a one-dimensional convolutional neural network improved by multi-convolution integration is used to optimize the water flow rate features, and spatio-temporal feature data of the water flow rate is obtained, including the following steps:
[0080] Step S21: Construct a water flow rate input layer. Specifically, the optimized water flow rate management data is used as the input data sample to construct the water flow rate input layer;
[0081] Step S22: Construct a one-dimensional convolutional layer improved by multi-convolution integration. Specifically, a depthwise separable convolutional layer, a hybrid dilated convolutional layer, and an adaptive frequency domain pooling layer are integrated in sequence to obtain a one-dimensional convolutional layer improved by multi-convolution integration;
[0082] For the depthwise separable convolutional layer, a depthwise separable convolution with a dilation factor of 2 is specifically used, and the number of channels is set to 64. The calculation formula is:
[0083] ;
[0084] In the formula, y1 is the output of the depthwise separable convolutional layer, Conv 1D (·) is a one-dimensional convolution operation function, x is the input data sample, filters is the number of convolution kernels, which is used to represent the number of channels, kernel_size is the kernel size, and dilation is the dilation factor;
[0085] For the hybrid dilated convolutional layer, a dilated convolution module with alternating dilation factors of [1, 3, 5] is specifically constructed, and channel attention is introduced after each dilated convolution module to construct the hybrid dilated convolutional layer. The calculation formula is:
[0086] ;
[0087] In the formula, y att is the output of the hybrid dilated convolutional layer, a L is the channel attention weight of the L-th layer of the hybrid dilated convolutional layer, L is the index of the hybrid dilated convolutional layer, DConv 1D (·) is a dilated convolution operation function, y L-1 is the output of the (L-1)-th layer of the convolutional layer, filters is the number of convolution kernels, which is used to represent the number of channels, kernel_size is the kernel size, and dilation is the dilation factor;
[0088] For the adaptive frequency domain pooling layer, an adaptive frequency domain pooling layer is specifically used to replace the fully connected layer in the standard one-dimensional convolution module to retain the time series frequency information. The calculation formula is:
[0089] ;
[0090] Wherein, y freq is the output feature of adaptive frequency-domain pooling, AFPool(·) is the operation function of adaptive frequency-domain pooling, and y att is the output of the hybrid dilated convolutional layer;
[0091] Step S23: Construct a branch output layer, specifically construct a regression branch and a classification branch to predict the Doppler shift value and the flow direction category;
[0092] The regression branch is used to output the Doppler frequency shift value and represent the water flow time feature, and the calculation formula is:
[0093] ;
[0094] Wherein, y reg is the output of the regression branch, used to output the water flow time feature, Dense(·) is the operation function of the fully connected layer, and y freq is the output feature of adaptive frequency-domain pooling, and units is the number of output units;
[0095] The classification branch is used to output the flow direction category, including forward, reverse, interference, and turbulence, and represent the water flow spatial feature, and the calculation formula is:
[0096] ;
[0097] Wherein, y class is the output of the classification branch, used to output the flow direction category, Dense(·) is the operation function of the fully connected layer, and y freq is the output feature of adaptive frequency-domain pooling, units is the number of output units, activation is the activation type, and softmax is the identifier of the softmax classifier function;
[0098] Step S24: Construct an optimized loss function, specifically construct a mean squared error loss and a cross-entropy loss, perform weighted summation to construct the optimized loss function, and the calculation formula is:
[0099] L total =b1L reg +b2L class ;
[0100] Wherein, L total is the optimized loss function, b1 is the regression loss weight, b2 is the classification loss weight, and L reg is the regression loss function, specifically using the mean squared error function, and L class is the classification loss function, specifically using the cross-entropy loss function;
[0101] Step S25: Training the water flow feature optimization model, specifically, training the water flow feature optimization model through the water flow input layer, the improved one-dimensional convolutional layer with multi-convolution integration, the branch output layer, and the optimization loss function to obtain the water flow feature optimization model Model FLNX ;
[0102] Table 1 is the reference parameter table of the water flow feature optimization model. As shown in the table, preferably, the value of the regression loss weight b1 is 0.7, and the value of the classification loss weight b2 is 0.3;
[0103] Table 1 Reference Parameter Table of Water Flow Feature Optimization Model
[0104]
[0105] Step S26: Optimizing the water flow features, specifically, based on the optimized water flow management data, using the water flow feature optimization model Model FLNX , to optimize the water flow features and obtain the spatio-temporal feature data of the water flow.
[0106] By performing the above operations, in the existing intelligent extraction method of water flow features, there are traditional classical algorithms, namely digital filtering algorithm and curve fitting algorithm. In actual measurement, due to the possible narrowness of the channel, the electromagnetic wave emitted by the radar may hit the shore, and there may be a large number of floating objects on the water surface, resulting in continuous changes in the signal amplitude. The water flow may be relatively rapid and the flow pattern may be poor. All these factors may lead to incorrect identification of the Doppler frequency shift, thus unable to correctly measure the surface velocity. The most intuitive manifestation is that the measured velocity data will fluctuate greatly. Due to the complex and diverse on-site conditions of water flow measurement and management, there may be situations where filtering cannot be completed. This solution creatively uses an improved one-dimensional convolutional neural network with multi-convolution integration to optimize the water flow features. By adaptively improving and designing the structure of the one-dimensional convolutional network, the intelligence and efficiency of water flow feature extraction are improved. While solving the problem that a single Doppler frequency shift method is prone to identification errors, the overall stability and reliability of the method are also enhanced.
[0107] Example 4, refer to Figure 1 、 Figure 2 and Figure 4 , based on the above example, in step S3, the frequency shift flow direction modeling is used to establish a flow direction prediction model based on the water flow frequency shift to identify the change trend and flow direction of the water flow. Specifically, based on the spatio-temporal feature data of the water flow, an improved time series prediction network combining Doppler effect analysis and frequency domain analysis is used to perform frequency domain flow direction modeling to obtain the predicted data of frequency shift flow direction change, including the following steps:
[0108] Step S31: Construct a spatio-temporal feature input layer of water flow rate. Specifically, use the spatio-temporal feature data of water flow rate as the original data input for frequency shift flow direction modeling to construct the spatio-temporal feature input layer of water flow rate;
[0109] Step S32: Doppler effect analysis. Specifically, according to the Doppler effect, perform frequency shift value spectrum analysis modeling on the original data input of frequency shift flow direction modeling to obtain Doppler frequency shift analysis data. The calculation formula is:
[0110] ;
[0111] In the formula, f shift is the Doppler frequency shift analysis data, v flow is the water flow velocity, c is the sound wave propagation velocity, and f ref is the reference frequency value, specifically the output of the regression branch in the spatio-temporal feature data of water flow rate;
[0112] Step S33: Frequency domain feature analysis. Specifically, through fast Fourier transform, perform frequency domain feature extraction and analysis on the original data input of frequency shift flow direction modeling to obtain frequency domain feature data. The calculation formula is:
[0113] ;
[0114] In the formula, X freq is the frequency domain feature data, FTT(·) is the fast Fourier transform function, and X S / T is the spatio-temporal feature data of water flow rate converted into frequency domain features;
[0115] Step S34: Construct an improved time series prediction network. Specifically, based on the Doppler frequency shift analysis data and the frequency domain feature data, through frequency domain attention optimization, multi-scale time series modeling, frequency domain long short-term memory network construction, and modeling layer construction, obtain the improved time series prediction network;
[0116] The frequency domain attention optimization is used to learn the weights of frequency domain features to enhance the model's processing ability for frequency domain features. Specifically, through the frequency domain feature attention mechanism, perform frequency domain attention optimization. The calculation formula is:
[0117] ;
[0118] In the formula, A freq is the frequency domain attention weight, sig(·) is the S-shaped activation function, W freq is the frequency domain weight matrix, and X freq is the frequency domain feature data;
[0119] The multi-scale time series modeling is used to model the change in the flow trend of water flow. Specifically, by constructing a multi-scale convolutional layer and splicing frequency-domain features, the calculation formula is as follows:
[0120] ;
[0121] In the formula, Y M / S is the output of the multi-scale time series modeling feature, Conv(·) is the convolution operation function, and X S / T is the spatio-temporal feature data of water flow converted into frequency-domain features. k1 is the convolution kernel size of the first layer of multi-scale convolution, and m is the total number of convolutional layers of multi-scale convolution;
[0122] The construction of the frequency-domain long short-term memory network is used to add frequency-domain features on the basis of the standard long short-term memory network. Specifically, a standard long short-term memory neural network is constructed, and frequency-domain feature fusion is performed on the hidden state to construct the frequency-domain long short-term memory network;
[0123] The construction of the modeling layer is used to output the frequency shift flow direction change category of the water flow. Specifically, the cross-entropy loss is constructed and a multi-task learning branch is constructed to perform the construction of the modeling layer;
[0124] Step S35: Frequency shift flow direction modeling. Specifically, through the spatio-temporal feature input layer of the water flow, the Doppler effect analysis, the frequency-domain feature analysis, and the improved time series prediction network, model training and data prediction of the frequency shift flow direction modeling are carried out to obtain the predicted data of the frequency shift flow direction change.
[0125] By performing the above operations, in the existing water flow frequency shift flow direction modeling and prediction method, there are technical problems such as large noise interference in the water flow frequency shift signal, complex flow direction changes, and difficulty in comprehensively capturing spatio-temporal features. This solution creatively adopts an improved time series prediction network that combines Doppler effect analysis and frequency-domain analysis, and performs combined prediction by combining two classic modeling analysis methods and spatio-temporal features, which overall improves the modeling and prediction effect of the water flow frequency shift and flow direction.
[0126] Example Five, refer to Figure 1 、 Figure 2 and Figure 5 Based on the above example, in step S4, the water flow management optimization is used to comprehensively manage the allocation and regulation of the water flow. Specifically, by combining the spatio-temporal feature data of the water flow and the predicted data of the frequency shift flow direction change, a reinforcement learning dynamic water flow allocation adjustment method that combines physical constraints and hydraulics equations is adopted to perform comprehensive management and optimization of the water flow to obtain the reference data for water flow management allocation, including the following steps:
[0127] Step S41: Model the water flow management problem to define the management objectives of water flow. Specifically, the basic objective model for water flow management is to minimize flow fluctuations and optimize water flow distribution, obtaining the water flow management objective model. The calculation formula is as follows:
[0128] ;
[0129] In the formula, minJ is the minimization optimization objective function, n is the total number of water flow regions, i is the water flow region index, Q i (t) is the actual water flow of the i-th region at time t, Q target,i (t) is the optimized target water flow; f shift,i (t) is the actual frequency shift value of the i-th region at time t, f shift,i (t - 1) is the actual frequency shift value of the i-th region at time t - 1;
[0130] Step S42: Model the physical constraints. Specifically, construct the mass conservation equation and the hydraulics equation as the physical constraint model of the model;
[0131] Step S43: Reinforcement learning for dynamic water flow distribution. Specifically, based on the water flow management objective model, construct a standard reinforcement learning parameter group and improve the design of the reward function to obtain a dynamic water flow distribution reinforcement learning architecture;
[0132] The improvement design of the reward function specifically refers to weighting according to the smoothness of water flow regulation and the smoothness of flow frequency shift to obtain a dynamic water flow distribution reward function, and performing reinforcement learning training based on the dynamic water flow distribution reward function;
[0133] The calculation formula of the dynamic water flow distribution reward function is as follows:
[0134] ;
[0135] In the formula, R(t) is the dynamic water flow distribution reward function, is the water flow reward weight, n is the total number of water flow regions, i is the water flow region index, Q i (t) is the actual water flow of the i-th region at time t, Q target,i (t) is the optimized target water flow, is the frequency shift value reward weight, f shift,i (t) is the actual frequency shift value of the i-th region at time t, f shift,i (t - 1) is the actual frequency shift value of the i-th region at time t - 1;
[0136] Step S44: Optimize and iteratively train water flow management. Specifically, use the deep Q - value learning method to perform iterative optimization of water flow allocation and Q - value update, and obtain the optimal model for water flow management optimization;
[0137] Step S45: Manage water flow. Specifically, based on the optimal model for water flow management optimization, perform water flow management to obtain reference data for water flow management allocation;
[0138] The reference data for water flow management allocation specifically includes regional water flow allocation suggestions, flow adjustment strategies, and comprehensive prediction reference data for flow direction and flow rate.
[0139] By performing the above operations, in the existing intelligent water flow management process, there are technical problems such as the lack of physical constraints in the water flow allocation scheme, making it difficult to achieve precise adjustment of flow allocation and poor dynamic adaptability. This solution creatively adopts a reinforcement learning - based dynamic water flow allocation adjustment method that combines physical constraints and hydraulic equations to optimize the comprehensive management of water flow. By integrating the physical constraint model, the physical characteristics of the water flow management results are optimized. At the same time, through the improvement of the reward function and the incorporation of frequency - shifted flow direction information, the flexibility and accuracy of water flow management are overall improved.
[0140] Example 6, refer to Figure 1 and Figure 2 , based on the above - mentioned example, an optimization system for water flow management based on machine learning provided by the present invention includes a data management module, a feature processing module, a prediction optimization module, and an output management module;
[0141] The data management module is used for data management. Through data management, optimized water flow management data is obtained, and the optimized water flow management data is sent to the feature processing module;
[0142] The feature processing module is used for optimizing water flow features. Through optimizing water flow features, spatio - temporal feature data of water flow is obtained, and the spatio - temporal feature data of water flow is sent to the prediction optimization module;
[0143] The prediction optimization module is used for modeling frequency - shifted flow directions. Through modeling frequency - shifted flow directions, prediction data on frequency - shifted flow direction changes is obtained, and the prediction data on frequency - shifted flow direction changes is sent to the output management module;
[0144] The output management module is used for optimizing water flow management. Through optimizing water flow management, reference data for water flow management allocation is obtained.
[0145] It should be noted that, in this text, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the term "comprising", "including" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements not only includes those elements, but also includes other elements not expressly listed, or further includes elements inherent to such process, method, article or device.
[0146] Although the embodiments of the present invention have been shown and described, those of ordinary skill in the art can understand that various changes, modifications, substitutions and variations can be made to these embodiments without departing from the principles and spirit of the present invention.
[0147] The above description of the present invention and its embodiments is not restrictive. What is shown in the drawings is only one of the embodiments of the present invention, and the actual structure is not limited thereto. In general, if those of ordinary skill in the art are inspired by it and design similar structural modes and embodiments without creative efforts without departing from the purpose of the present invention, they shall fall within the protection scope of the present invention.
Claims
1. An optimization method for water flow management based on machine learning, characterized in that: The method includes the following steps: Step S1: Data management to obtain optimized water flow management data; Step S2: Optimization of water flow characteristics. An improved one-dimensional convolutional neural network with multi-convolution integration is used to optimize water flow characteristics, obtaining water flow spatio-temporal characteristic data; In the improved one-dimensional convolutional layer with multi-convolution integration, the depthwise separable convolutional layer, the hybrid dilated convolutional layer, and the adaptive frequency domain pooling layer are sequentially integrated to obtain the improved one-dimensional convolutional layer with multi-convolution integration; In the depthwise separable convolutional layer, a depthwise separable convolution with a dilation factor of 2 is used, and the number of channels is set to 64; in the hybrid dilated convolutional layer, a dilated convolution module with alternating dilation factors of [1, 3, 5] is constructed, and channel attention is introduced after each dilated convolution module to construct the hybrid dilated convolutional layer; in the adaptive frequency domain pooling layer, the adaptive frequency domain pooling layer is used to replace the fully connected layer in the standard one-dimensional convolutional module to retain the time-series frequency information; Step S3: Modeling of frequency shift and flow direction. An improved time-series prediction network combining Doppler effect analysis and frequency domain analysis is used to model the frequency shift and flow direction, obtaining predicted data on frequency shift and flow direction changes, including the following steps: Step S31: Construct an input layer for water flow spatio-temporal characteristics; Step S32: Doppler effect analysis; Step S33: Frequency domain feature analysis; Step S34: Construct an improved time-series prediction network; Step S35: Modeling of frequency shift and flow direction; Step S4: Optimization of water flow management, which is used to comprehensively manage the allocation and regulation of water flow. Specifically, by combining the water flow spatio-temporal characteristic data and the predicted data on frequency shift and flow direction changes, a reinforcement learning dynamic water flow allocation adjustment method combining physical constraints and hydraulic equations is used to optimize the comprehensive management of water flow, obtaining reference data for water flow management allocation, including the following steps: Step S41: Modeling of the water flow management problem, which is used to define the management objective of water flow. Specifically, minimizing flow fluctuations and optimizing water flow allocation is used as the basic objective model of the water flow management problem to obtain the water flow management objective model; Step S42: Modeling of physical constraints. Specifically, a mass conservation equation and a hydraulic equation are constructed as the physical constraint model of the model; Step S43: Reinforcement learning for dynamic water flow allocation; Step S44: Iterative training for optimization of water flow management; Step S45: Water flow management.
2. The optimization method for water flow management based on machine learning according to claim 1, characterized in that: In Step S1, the data management is used to collect, store, and preprocess the original data set required for water flow management. Specifically, the original data for water flow management is obtained through multi-source sensing data acquisition, and the optimized water flow management data is obtained through data preprocessing; The original data for water flow management includes water flow data, water level data, environmental support data, signal evaluation data, water flow pattern data, and spatio-temporal data; The data preprocessing includes data denoising, anomaly processing, data normalization, and data smoothing operations.
3. The optimization method for water flow management based on machine learning according to claim 2, characterized in that: In step S2, the water flow rate feature optimization is used to extract and optimize the spatio-temporal features of the water flow rate. Specifically, based on the optimized water flow rate management data, a one-dimensional convolutional neural network improved by multi-convolution integration is adopted to optimize the water flow rate features, and spatio-temporal feature data of the water flow rate is obtained, including the following steps: Step S21: Construct a water flow rate input layer. Specifically, the optimized water flow rate management data is used as the input data sample to construct the water flow rate input layer; Step S22: Construct a one-dimensional convolutional layer improved by multi-convolution integration. Specifically, a depthwise separable convolutional layer, a hybrid dilated convolutional layer, and an adaptive frequency domain pooling layer are integrated in sequence to obtain a one-dimensional convolutional layer improved by multi-convolution integration; For the depthwise separable convolutional layer, a depthwise separable convolution with a dilation factor of 2 is specifically used, and the number of channels is set to 64; For the hybrid dilated convolutional layer, a dilated convolution module with alternating dilation factors of [1, 3, 5] is specifically constructed, and channel attention is introduced after each dilated convolution module to construct the hybrid dilated convolutional layer; For the adaptive frequency domain pooling layer, an adaptive frequency domain pooling layer is specifically used to replace the fully connected layer in the standard one-dimensional convolutional module to retain the time series frequency information; Step S23: Construct a branch output layer. Specifically, a regression branch and a classification branch are constructed to predict the Doppler shift value and the flow direction category; The regression branch is used to output the Doppler frequency shift value and represent the time characteristics of the water flow; The classification branch is used to output the flow direction categories, including forward, reverse, interference, and turbulence, and represent the spatial characteristics of the water flow; Step S24: Construct an optimized loss function. Specifically, a mean square error loss and a cross-entropy loss are constructed and weighted and summed to construct the optimized loss function; Step S25: Training the water flow feature optimization model, specifically, training the water flow feature optimization model through the water flow input layer, the improved one-dimensional convolutional layer with multi-convolution integration, the branch output layer, and the optimization loss function to obtain the water flow feature optimization model Model FLNX ; Step S26: Optimize the water flow characteristics. Specifically, based on the optimized water flow management data, use the water flow characteristic optimization model Model FLNX , to optimize the water flow characteristics and obtain the spatio-temporal characteristic data of the water flow.
4. The optimization method for water flow management based on machine learning according to claim 3, characterized in that: In step S3, the frequency shift flow direction modeling is used to establish a flow direction prediction model based on the water flow frequency shift to identify the change trend and flow direction of the water flow. Specifically, based on the spatio-temporal feature data of the water flow rate, an improved time series prediction network combining Doppler effect analysis and frequency domain analysis is adopted to perform frequency shift flow direction modeling, and frequency shift flow direction change prediction data is obtained, including the following steps: Step S31: Construct a spatio-temporal feature input layer of the water flow rate. Specifically, the spatio-temporal feature data of the water flow rate is used as the original data input for frequency shift flow direction modeling to construct the spatio-temporal feature input layer of the water flow rate; Step S32: Doppler effect analysis. Specifically, according to the Doppler effect, frequency shift value spectrum analysis modeling is performed on the original data input for frequency shift flow direction modeling to obtain Doppler frequency shift analysis data; Step S33: Frequency domain feature analysis. Specifically, through fast Fourier transform, frequency domain feature extraction and analysis are performed on the original data input for frequency shift flow direction modeling to obtain frequency domain feature data; Step S34: Construct an improved time series prediction network. Specifically, based on the Doppler frequency shift analysis data and the frequency domain feature data, the improved time series prediction network is obtained through frequency domain attention optimization, multi-scale time series modeling, frequency domain long short-term memory network construction, and modeling layer construction; Step S35: Modeling of frequency shift flow direction. Specifically, through the water flow spatio-temporal feature input layer, the Doppler effect analysis, the frequency domain feature analysis, and the improved time series prediction network, model training and data prediction of the frequency shift flow direction modeling are carried out to obtain the predicted data of the frequency shift flow direction change.
5. The optimization method for water flow management based on machine learning according to claim 4, characterized in that: In step S4, the optimization of water flow management includes the following steps: Step S41: Modeling of water flow management problems; Step S42: Modeling of physical constraints; Step S43: Reinforcement learning for dynamic water flow allocation. Specifically, according to the water flow management target model, a standard reinforcement learning parameter group is constructed, and the reward function is improved and designed to obtain a reinforcement learning architecture for dynamic water flow allocation; The improvement and design of the reward function specifically refers to weighting according to the smoothness of water flow regulation and the smoothness of flow frequency shift to obtain a reward function for dynamic water flow allocation, and performing reinforcement learning training according to the reward function for dynamic water flow allocation; The calculation formula of the reward function for dynamic water flow allocation is: where \(R(t)\) is the dynamic water flow distribution reward function, \(\alpha\) i is the water flow reward weight, \(n\) is the total number of water flow regions, \(i\) is the water flow region index, \(Q\) i (t) is the actual water flow in the \(i\)-th region at time \(t\), \(Q\) target,i (t) is the optimized target water flow, \(\beta\) i is the frequency shift value reward weight, \(f\) shift,i (t) is the actual frequency shift value in the \(i\)-th region at time \(t\), \(f\) shift,i (t - 1) is the actual frequency shift value in the \(i\)-th region at time \(t - 1\); Step S44: Iterative training for water flow management optimization. Specifically, the deep Q-value learning method is used to perform iterative optimization of water flow allocation and Q-value update to obtain the optimal model for water flow management optimization; Step S45: Water flow management. Specifically, according to the optimal model for water flow management optimization, water flow management is carried out to obtain the reference data for water flow management allocation.
6. The optimization method for water flow management based on machine learning according to claim 5, characterized in that: In step S45, the reference data for water flow management allocation specifically includes regional water flow allocation suggestions, flow adjustment strategies, and comprehensive prediction reference data for flow direction and flow rate.
7. A machine learning-based water flow management optimization system for implementing a machine learning-based water flow management optimization method as described in any one of claims 1-6, characterized in that: It includes a data management module, a feature processing module, a prediction optimization module, and an output management module.
8. The water flow management optimization system based on machine learning according to claim 7, characterized in that: The data management module is used for data management. Through data management, optimized water flow management data is obtained and sent to the feature processing module; The feature processing module is used for optimizing water flow features. Through optimizing water flow features, water flow spatio-temporal feature data is obtained and sent to the prediction optimization module; The prediction optimization module is used for modeling the frequency shift flow direction. Through modeling the frequency shift flow direction, predicted data of the frequency shift flow direction change is obtained and sent to the output management module; The output management module is used for optimizing water flow management. Through optimizing water flow management, reference data for water flow management allocation is obtained.
Citation Information
Patent Citations
Dynamic generation method for hydrological time series prediction model
CN114819260A
Remote sensing image change detection method based on DCT perception
CN119107562A