Water level prediction method and electronic equipment

Through the dynamic knowledge graph and hybrid expert network model, the hydrological characteristics of the target water level site are extracted and the auxiliary prediction model is determined, which solves the problem of poor adaptability of the existing water level prediction technology and achieves higher water level prediction accuracy.

CN119358658AActive Publication Date: 2025-01-24HANGZHOU HIKVISION DIGITAL TECHNOLOGY CO LTD

Patent Information

Application Number
CN202411957442.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-27
Publication Date
2025-01-24
Estimated Expiration
2044-12-27

AI Technical Summary

Technical Problem

The existing water level prediction technology has poor adaptability to adapt to various water level influencing factors and changes, affecting the accuracy of the prediction.

Method used

Through the pre -constructed dynamic knowledge graph obtain the water level site and/or the hydrological characteristics of the target water level site, the pre -trained door control network is combined with the pre -trained door control network to determine the auxiliary prediction model from the hybrid expert network model to perform the water level prediction.

Benefits of technology

This method can automatically adapt to the influencing factors and changes of a variety of water levels, and improve the accuracy of water level prediction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119358658A_ABST
    Figure CN119358658A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a water level prediction method and electronic equipment, and relates to the technical field of water level prediction. Comprising the following steps: acquiring a water level station and / or a rainfall station directly connected with a target water level station from a pre-constructed dynamic knowledge graph; hydrological characteristics of a target water level station and water level stations and / or precipitation stations directly connected with the target water level station are extracted, and a hydrological characteristic set of the target water level station is obtained; inputting the hydrological feature set into a pre-trained gating network, and determining at least one auxiliary prediction model from a hybrid expert network model; and inputting the hydrological feature set into at least one auxiliary prediction model and a pre-trained target neural network model to obtain a fused first target prediction result. The method can automatically adapt to numerous water level influence factors and continuous changes of the water level influence factors, and the accuracy of water level prediction is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the technical field of water level prediction, and in particular to a method and electronic equipment for water level prediction. Background Art

[0002] Water level forecasting plays a vital role in ensuring people's safety and reducing disasters. Accurate water level forecasting can not only help effectively organize the evacuation of personnel and the transfer of materials, avoid or reduce casualties and property losses caused by floods, but also provide decision-making support for the rational allocation of water resources, scientific planning of infrastructure and environmental protection.

[0003] Water level prediction in related technologies usually uses monitoring data from multiple spatially adjacent water level stations to extract features in the time and space dimensions as training data to train a model, and then uses the model to predict water levels. However, there are many influencing factors for water level stations, and some of these influencing factors may change over time. The adaptability of the technical solutions in related technologies is poor, which in turn affects the accuracy of water level prediction. Summary of the invention

[0004] The purpose of the embodiments of the present disclosure is to provide a method and electronic device for water level prediction.

[0005] To solve the above technical problems, the embodiments of the present disclosure are implemented through the following aspects.

[0006] According to a first aspect of an embodiment of the present disclosure, a method for water level prediction is provided, the method comprising: obtaining water level stations and / or precipitation stations directly connected to the target water level station from a pre-constructed knowledge graph; extracting the target water level station, and the hydrological characteristics of the water level stations and / or precipitation stations directly connected to the target water level station, to obtain a hydrological feature set of the target water level station; inputting the hydrological feature set into a pre-trained gating network to determine at least one auxiliary prediction model from a hybrid expert network model, the hybrid expert network model comprising a plurality of network models pre-trained based on different hydrological training features; inputting the hydrological feature set into the at least one auxiliary prediction model and the pre-trained target neural network model to obtain a fused first target prediction result.

[0007] According to a second aspect of an embodiment of the present disclosure, an electronic device is provided, comprising: a processor; and a memory for storing instructions executable by the processor; wherein the processor is used to execute the steps of the water level prediction method described in the first aspect above.

[0008] One of the above technical solutions has the following advantages or beneficial effects: by determining the water level stations and / or precipitation stations directly connected to the target water level stations in a pre-constructed dynamic knowledge graph, and based on the target water level stations and the water level stations and / or precipitation stations directly connected to the target water level stations, and a set of hydrological features extracted from the target water level stations and the water level stations and / or precipitation stations directly connected to the target water level stations and a pre-trained gating network, at least one auxiliary prediction model is determined from the hybrid expert model network to assist in water level prediction, which can automatically adapt to numerous water level influencing factors and the continuous changes in water level influencing factors, thereby improving the accuracy of water level prediction.

[0009] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure.

[0010] Other features and advantages of the present disclosure will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS

[0011] In order to more clearly illustrate the embodiments of the present disclosure 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 recorded in the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0012] Figure 1 A schematic flow chart showing a method for water level prediction provided by an embodiment of the present disclosure; Figure 2 A schematic diagram showing a knowledge graph provided by an embodiment of the present disclosure is shown; Figure 3 Another schematic flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown; Figure 4 Another schematic flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown; Figure 5 A schematic diagram showing the structure of a water level prediction model provided by an embodiment of the present disclosure; Figure 6 Another schematic flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown; Figure 7 Another schematic flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown; Figure 8 Another schematic flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown; Fig. 9 Another schematic flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown; Fig.10 A schematic diagram of the hardware structure of an electronic device for executing the water level prediction method provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0013] In order to enable those skilled in the art to better understand the technical solutions in the present disclosure, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments of the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present disclosure.

[0014] Figure 1 A flow chart of a method for water level prediction provided by an embodiment of the present disclosure is shown as follows: Figure 1 As shown, the method may include the following steps: In step S101, water level stations and / or precipitation stations directly connected to the target water level station are obtained from a pre-built dynamic knowledge graph.

[0015] A water level station can also be called a water level monitoring station. The hydrological data of the station can be obtained through the corresponding monitoring device / module, such as the water level data at the designated location of the station, the precipitation data of the station, and the forecast precipitation data of the station. In addition, runoff data can also be obtained based on the water level data and precipitation data. It can be understood that precipitation data can be the sum of rainfall data, snowfall data, and other precipitation data in meteorology.

[0016] The meaning of a dynamic knowledge graph is that the knowledge graph can be updated with the updated monitoring data, so that the knowledge graph can adapt to changes in monitoring data and improve the adaptability of the water level prediction method.

[0017] A precipitation site may also be referred to as a precipitation detection site, and the hydrological data of the site, such as the precipitation data of the site and the forecast precipitation data of the site, may be acquired through a corresponding monitoring device / module.

[0018] In some embodiments, the nodes of the knowledge graph are water level sites or precipitation sites, and the edges of the knowledge graph are feature correlations between adjacent nodes.

[0019] Water level stations and precipitation stations are drawn as nodes in the knowledge graph, and nodes with higher correlation can be connected by edges according to the correlation between preset data. The correlation between two nodes can be one of water level and water level correlation, water level and precipitation correlation, precipitation and water level correlation, or precipitation and precipitation correlation. This application focuses on the water level and water level correlation, water level and precipitation correlation, and precipitation and water level correlation related to water level stations. Figure 2 A schematic diagram of a knowledge graph provided by an embodiment of the present disclosure is shown, such as Figure 2 As shown, Figure 2 The circular nodes in the figure represent water level stations, and the rectangular nodes represent precipitation stations. Assume that the correlation between the target water level node A and the precipitation node B is the correlation between water level and precipitation, and the correlation between the target water level node A and the precipitation node B is the correlation between water level and water level, or the correlation between water level and precipitation. Figure 2 The sites directly connected to the target water level site A are obtained from the knowledge graph as C, D and E. As for the water level node B, there is no direct connection with the target water level site A in the knowledge graph. Even if the water level node B is close to the target water level site A in space, the water level node B is not used as a site directly connected to the target water level site A. In step S102, the hydrological features of the target water level site, and the water level sites and / or precipitation sites directly connected to the target water level site are extracted to obtain the hydrological feature set of the target water level site.

[0020] Among them, the hydrological characteristics of the water level station include at least one of water level characteristics, precipitation characteristics, predicted precipitation characteristics, soil characteristics and runoff characteristics, and the hydrological characteristics of the precipitation station include precipitation characteristics and / or predicted precipitation characteristics.

[0021] Figure 3 Another flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown as follows: Figure 3 As shown, step S102 may include the following steps.

[0022] In step S1021, a first hydrological feature corresponding to the target water level station and at least one second hydrological feature corresponding to at least one water level station and / or precipitation station directly connected to the target water level station are extracted.

[0023] For example, the n-dimensional feature vector of the target water level station i at time t can be extracted As the first hydrological feature at time t corresponding to the target water level station, the n-dimensional feature vector of station j directly connected to the target water level station i at time t The second hydrological characteristic at time t corresponding to site j directly connected to the target water level site i.

[0024] It should be noted that the feature vector can be padded so that the dimensions of the hydrological features corresponding to different types of stations (i.e., n in the above formula) remain consistent. For example, if the precipitation station does not include water level features, a preset value (e.g., 0) can be used for padding. The number of stations j directly connected to the target water level station i can be one or more.

[0025] In step S1022, graph convolution is performed on the first hydrological feature and the second hydrological feature to obtain a third hydrological feature.

[0026] For example, the first hydrological feature at time t corresponding to the target water level station and the second hydrological feature at time t of at least one station j directly connected to the target water level station i can be calculated by graph convolution to obtain the third hydrological feature at time t corresponding to the target water level station: .

[0027] In step S1023, the union of the first hydrological feature, the second hydrological feature and the third hydrological feature is taken as a hydrological feature set.

[0028] For example, the union of the first hydrological characteristic corresponding to the target water level station at time t, the second hydrological characteristic of at least one station directly connected to the target water level station i at time t, and the third hydrological characteristic corresponding to the target water level station at time t can be used as the hydrological characteristic set corresponding to the target water level station at time t. .

[0029] It can be understood that, assuming that the number of sites directly connected to the target water level site i is m, the hydrological feature set corresponding to the target water level site at time t is a matrix with n rows and m+2 columns.

[0030] In some embodiments, the hydrological characteristics of the target water level station and the water level stations and / or precipitation stations directly connected to the target water level station can be extracted through a recurrent neural network and a graph convolutional network.

[0031] In some possible implementations, the hydrological feature set can be extracted through recurrent neural networks GRU (Gated Recurrent Unit) and GCN (Graph Convolutional Networks). GRU and GCN can accurately extract graph features of the knowledge graph, such as node features and corresponding connections between nodes, from the knowledge graph, which is conducive to accurate water level prediction.

[0032] In step S103, the hydrological feature set is input into a pre-trained gating network to determine at least one auxiliary prediction model from the hybrid expert network model.

[0033] Among them, the hybrid expert network model includes multiple network models pre-trained based on different hydrological training features.

[0034] It is understandable that the types of sites directly connected to the target water level site may be different. Even if the types of sites directly connected to the target water level site are the same, the factors affecting the target water level site by the sites directly connected to the target water level site may be different. Figure 2 In the figure, the main factor affecting the target water level station A by the station D directly connected to the target water level station may be the precipitation characteristics, while the main factor affecting the target water level station A by the station E directly connected to the target water level station may be the water level characteristics. That is, the precipitation data of the station D directly connected to the target water level station is highly correlated with the water level data of the target water level station A, while the water level data of the station E directly connected to the target water level station is highly correlated with the water level data of the target water level station A.

[0035] In some embodiments, a hybrid expert network model composed of multiple network models can be trained, and at least one auxiliary prediction model can be determined from the trained hybrid expert network model by pre-training a gating network.

[0036] The gating network aims to fuse information from different modes or sources by learning gating mechanisms. It consists of inputs from multiple data domains, each of which focuses on a specific aspect or source of information. By controlling the weight of each data domain's contribution to the final prediction or output, the network is allowed to dynamically emphasize or weaken specific information sources, thereby achieving better representation learning and capturing complex dependencies between inputs.

[0037] In some embodiments, the candidate multiple network models may include at least two of the PatchTST model, the FNN model, and the dynamic graph convolution model. Of course, other network models may also be adaptively used to expand the candidate network model or replace the current model in the candidate multiple network models, and this application does not limit this.

[0038] Figure 4 Another flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown as follows: Figure 4 As shown, step S103 may specifically include the following steps.

[0039] In step S1031, the hydrological feature set is input into the gated network to obtain the probabilities corresponding to the multiple network models.

[0040] In some possible implementations, the input and output of the gating network can be expressed by the following formula 1.

[0041] (Formula 1) in, is the probability of the kth expert network model corresponding to the target water level site i, is an activation function, for example, a sigmoid activation function. is the set of hydrological characteristics of the target water level station i at multiple times, is with Corresponding to the preset weight matrix, is the preset bias matrix. When training the gated network, and The preset default value can be taken first, and then the hydrological feature set of the target water level station i at multiple times is input into the gating network. The deviation between the output water level of the gating network and the actual water level in the hydrological feature set is used as the loss value, and the loss value is back-propagated. and Optimize the parameters and output the corresponding When the preset training termination conditions are met, such as the number of loop iteration training reaches the preset number threshold or the loss value is less than the preset loss value threshold, the training of the gated network is terminated to obtain the probabilities corresponding to the multiple network models.

[0042] In step S1032, at least one network model with a probability greater than or equal to a preset probability threshold is used as an auxiliary prediction model; or at least one network model with the highest probability is used as an auxiliary prediction model. In some embodiments, multiple network models can be sorted from high to low according to their corresponding probabilities, and at least one network model with a probability greater than or equal to a preset probability threshold is used as an auxiliary prediction model, or a preset number of network models with the highest ranking can be used as auxiliary prediction models, and this application does not limit this.

[0043] Through the above-mentioned gated network, the corresponding auxiliary prediction network can be determined for the target water level site based on the hydrological feature set, and personalized water level prediction services can be implemented for each target water level site.

[0044] In step S104, the hydrological feature set is input into at least one auxiliary prediction model and a pre-trained target neural network model to obtain a fused first target prediction result.

[0045] Figure 5 A schematic diagram of the structure of a water level prediction model provided by an embodiment of the present disclosure is shown as follows: Figure 5 As shown, after the hydrological feature set of the target water level site is extracted and at least one auxiliary prediction model corresponding to the target water level site is determined, water level prediction can be assisted by the at least one auxiliary prediction model corresponding to the target water level site.

[0046] Specifically, Figure 6Another flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown as follows: Figure 6 As shown, step S104 may specifically include the following steps.

[0047] In step S1041, the hydrological characteristics of the target water level station are input into a pre-trained target neural network model to obtain a first prediction result.

[0048] The target neural network model focuses on capturing the characteristics of the target site itself, which helps to reduce the noise interference that may be introduced by auxiliary information, so that the stability and accuracy of the prediction can be maintained when the data is sparse or the auxiliary information is insufficient. The target neural network model enhances the generalization ability of the entire system, enabling it to better adapt to new or unseen data and ensure that reasonable prediction results can be provided under various conditions. This application does not restrict the specific choice of the target neural network model, which can be a network model such as CNN (Convolutional Neural Networks) or LSTM (Long Short-Term Memory).

[0049] In step S1042, the hydrological feature set is input into at least one auxiliary prediction model to obtain a second prediction result.

[0050] by Figure 5 Taking the PatchTST model, FNN model and dynamic graph convolution model determined by the gated network as an example, the hydrological features in the hydrological feature set of the target water level station at multiple times can be used to form a water level feature sequence and input into the PatchTST model to obtain the second prediction result corresponding to the PatchTST model. The water level features, precipitation features and soil features in the hydrological feature set of the target water level station are input into the FNN model to obtain the second prediction result corresponding to the FNN model. The hydrological feature set of the target water level station and the corresponding graph structure data (which can be the adjacency matrix of the target water level station in the knowledge graph) are input into the dynamic graph convolution model to obtain the second prediction result corresponding to the dynamic graph convolution model.

[0051] In some embodiments, the average value of the second prediction results obtained by at least one auxiliary prediction model may be used as the final second prediction result, or the weighted sum value of the second prediction results obtained by at least one auxiliary prediction model may be used as the final second prediction result.

[0052] In step S1043, a first target prediction result is obtained according to the first prediction result and the second prediction result.

[0053] In some embodiments, a weighted sum of the first prediction result and the second prediction result may be used as the first target prediction result.

[0054] By adopting the above-mentioned technical solution, the sites directly connected to the target water level sites are determined from the pre-built dynamic knowledge graph, and at least one auxiliary prediction model is determined from the hybrid expert model network to assist in water level prediction. This can automatically adapt to the numerous water level influencing factors and the constant changes in water level influencing factors, thereby improving the accuracy of water level prediction.

[0055] In some embodiments, the knowledge graph may include multiple sub-knowledge graphs corresponding to different precipitation periods, such as a rainy season sub-knowledge graph, a dry season sub-knowledge graph, a plum rain season sub-knowledge graph, etc.

[0056] Accordingly, step S101 may specifically include the following steps: In step S1011, a sub-knowledge graph corresponding to the current precipitation period is obtained from the knowledge graph.

[0057] In step S1012, water level stations and / or precipitation stations directly connected to the target water level station are obtained from the sub-knowledge graph corresponding to the current precipitation period.

[0058] For example, if the current season is the plum rain season, the plum rain season sub-knowledge graph can be obtained from the knowledge graph. The water level station and / or precipitation station directly connected to the target water level station can be obtained from the plum rain season sub-knowledge graph.

[0059] It can be understood that the current precipitation period can be input as a hyperparameter into the hybrid expert network model, so that the corresponding hybrid expert network model can learn the characteristics related to the precipitation period.

[0060] Determining the corresponding sub-knowledge graph based on different precipitation cycles and performing water level prediction based on the corresponding sub-knowledge graph can further improve the accuracy of water level prediction.

[0061] For multiple network models in the hybrid expert network model, targeted training can be performed according to the specific influencing factors (hydrological characteristics) targeted by different models. For example, time series models such as PatchTST can capture the time series characteristics of water level data; feedforward neural networks (FNNs) can handle nonlinear relationships of inputs such as precipitation; dynamic graph models such as dynamic graph convolutional networks (DYNGCNs) can handle complex spatial relationships between sites.

[0062] In some embodiments, the PatchTST model is obtained by inputting multiple water level feature sequences as training data into the PatchTST model to be trained, wherein the water level feature sequence includes multiple water level features of the target water level station arranged in chronological order. The FNN model is obtained by inputting the water level features, precipitation features, and soil features in the hydrological feature training set of the target water level station into the FNN model to be trained. The dynamic graph convolution model is obtained by inputting the hydrological feature training set of the target water level station and the corresponding graph structure data into the dynamic graph convolution model to be trained.

[0063] The above-mentioned technical solution fully utilizes the specialized processing capabilities of the heterogeneous expert network model in water level prediction, and can more accurately capture and predict water level changes. Since the heterogeneous expert network model of this application is adaptively selected through the gating network, the flexibility and scalability of the hybrid expert network model also enable it to quickly adapt to changes in environmental conditions, further improving the adaptability of the water level prediction model.

[0064] Figure 7 Another flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown as follows: Figure 7 As shown, the method may also include the following steps of generating a knowledge graph.

[0065] In step S105, first original data of each water level station and precipitation station at multiple historical moments are obtained.

[0066] The first original data includes water level data and / or precipitation data.

[0067] For example, the first original data of a water level station may include water level data and precipitation data, or may only include water level data, and the first original data of a precipitation station may include precipitation data.

[0068] In step S106, the first correlation of the first original data between any two nodes of the knowledge graph is calculated.

[0069] In some embodiments, the first correlation may be calculated by a statistical method such as the Pearson correlation coefficient shown in the following formula 2.

[0070] (Formula 2) Among them, x and y represent the first original data of the two nodes (water level data or precipitation data), represents the correlation value between two sites within a period, is the covariance between the first raw data of the two nodes, and are the standard deviations of the first raw data of the two nodes respectively.

[0071] In another embodiment, the evaluation may also be performed using a machine learning method, which is not limited in this application.

[0072] In step S107, two nodes whose first correlation is greater than or equal to a first correlation threshold are connected via an undirected edge.

[0073] After two nodes are connected through an undirected edge, the correlation between the two nodes and the type of the corresponding original data can be saved in the knowledge graph as attributes of the undirected edge.

[0074] In some embodiments, a sub-knowledge graph corresponding to the precipitation period can also be constructed according to the precipitation period in the basin. For example, a corresponding rainy season sub-knowledge graph and dry season sub-knowledge graph can be constructed according to the rainy season and the dry season, respectively, and a plum rain season sub-knowledge graph can also be constructed for the plum rain season.

[0075] By adopting the above-mentioned technical scheme, the complex interactions between water level stations and precipitation stations can be captured and reflected in real time, so as to facilitate the accurate acquisition of stations directly connected to the target water level stations and having a strong correlation with the water level of the target water level stations. Moreover, the types of stations directly connected to the target water level stations can be water level stations or precipitation stations. Compared with the technical scheme in the related art that uses water level stations with a close spatial distance as auxiliary prediction stations, it can better adapt to actual hydrological conditions and improve the accuracy of water level prediction.

[0076] Figure 8 Another flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown as follows: Figure 8 As shown, the method may also include the following steps of updating the knowledge graph.

[0077] In step S108, second original data of each water level station and precipitation station at multiple update times are obtained.

[0078] The second original data includes water level data and / or precipitation data, and the update time is later than the historical time. In step S109, the second correlation of the second original data between any two nodes of the knowledge graph is calculated.

[0079] The calculation method of the second correlation may refer to the calculation method of the first correlation in step S106 .

[0080] In step S110, the knowledge graph is updated according to the second relevance.

[0081] In some embodiments, when the second correlation of two nodes without edges in the knowledge graph is greater than or equal to the first correlation threshold, an undirected edge can be added for the two nodes without edges. When the second correlation of two nodes with edges in the knowledge graph is less than the second correlation threshold, the undirected edge between the two nodes with edges in the knowledge graph can be deleted, wherein the second correlation threshold can be less than the first correlation threshold. When the attributes of the edge between two nodes change, the attributes of the edge can also be adjusted accordingly. For example, the correlation threshold between the water level data of water level station A and the water level data of water level station B is changed from greater than the first correlation threshold to less than the second correlation threshold, but the correlation threshold between the water level of water level station A and the precipitation data of water level station B is changed from less than the second correlation threshold to greater than the first correlation threshold, then the attributes of the edge between water level station A and water level station B in the knowledge graph can be modified accordingly. It can be understood that the steps of updating the knowledge graph in steps S108-S110 can be started based on periodicity or event triggering or in response to user operations, and the present application does not limit the order between steps S108-S110 and steps S101-S104.

[0082] In some embodiments, the knowledge graph may be a knowledge graph corresponding to a precipitation period in a watershed, and the multiple update moments may be multiple update moments in the precipitation period. For example, if the knowledge graph is a plum rain season knowledge graph, the plum rain season knowledge graph model may be updated according to the second original data corresponding to the multiple update moments of the plum rain season.

[0083] By adopting the above technical solution, the knowledge graph can be dynamically updated in response to changes in environmental conditions, further improving the adaptability of the prediction model.

[0084] In some embodiments, the first target prediction result may be obtained according to the first prediction result and the second prediction result through the following steps.

[0085] Step 10: Determine the first weight and the second weight corresponding to the target neural network model and the auxiliary prediction model respectively according to the mean square error of the target neural network model and the auxiliary prediction model.

[0086] The weights corresponding to the target neural network model and the auxiliary prediction model can be dynamically determined through the performance of the validation set in the target neural network model and the auxiliary prediction model.

[0087] In some possible implementations, the first weight may be determined by the following formula three, and the second weight may be determined by the following formula four.

[0088] (Formula 3) (Formula 4) in, is the first weight corresponding to the target neural network model, is the second weight corresponding to the auxiliary prediction model, is the mean square error corresponding to the target neural network model, is the mean square error corresponding to the auxiliary prediction model.

[0089] Step 11: taking the weighted sum of the first prediction result and the second prediction result as the first target prediction result.

[0090] Among them, the weighted weight of the first prediction result is the first weight, and the weighted weight of the second prediction result is the second weight.

[0091] In some possible implementations, the first target prediction result may be determined by the following formula 5.

[0092] (Formula 5) in, For the first target prediction result, is the first prediction result, is the second prediction result. is the first weight corresponding to the target neural network model, is the second weight corresponding to the auxiliary prediction model.

[0093] By adopting the above technical solution, the weighted weight of the prediction result can be dynamically determined according to the mean square error of the target neural network model and the auxiliary prediction model. The combination of the target neural network model and the hybrid expert network model can further enhance the flexibility and scalability of the system while improving the accuracy and robustness of the prediction.

[0094] Fig. 9 Another flow chart of the method for water level prediction provided by the embodiment of the present disclosure is shown as follows: Fig. 9 As shown, the method may further include the following steps.

[0095] In step S111, the first target prediction result and the hydrological feature set are input into a pre-trained deep neural network model to obtain the second target prediction results at multiple preset moments in the future.

[0096] Deep neural network models can include multiple hidden layers, which can enable the model to capture complex relationships and patterns in data through nonlinear transformations.

[0097] The first target prediction result and the hydrological feature set can be input into a pre-trained deep neural network model, so as to obtain the second target prediction results for multiple preset moments in the future (for example, the next 12 hours or the next 24 hours) through the deep neural network model.

[0098] By adopting the above technical solution, the second target prediction results for multiple preset time periods in the future can be obtained based on the first target prediction results and the hydrological feature set, further improving the prediction capability of water level prediction.

[0099] Fig.10 A schematic diagram of the hardware structure of an electronic device provided by an embodiment of the present disclosure is shown. Fig.10 As shown, at the hardware level, the electronic device includes at least one processor, and optionally includes an internal bus, a network interface, and a memory. The memory may include a memory, such as a high-speed random access memory (RAM), and may also include a non-volatile memory (non-volatile memory), such as at least one disk storage, etc. Of course, the electronic device may also include hardware required for other services.

[0100] The processor, network interface and memory can be interconnected through an internal bus, which can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one bidirectional arrow is used in the figure, but it does not mean that there is only one bus or one type of bus.

[0101] The memory stores the program. Specifically, the program may include a program code, and the program code includes at least one computer operation instruction. The memory may include a memory and a non-volatile memory, and provides instructions and data to the processor.

[0102] At least one processor reads the corresponding computer program from the non-volatile memory into the memory and then runs it, forming a device for locating the target user at the logical level. At least one processor executes the program stored in the memory and specifically performs: the method disclosed in the embodiment shown in the first aspect and realizes the functions and beneficial effects of each method described in the method embodiment above, which will not be repeated here.

[0103] The method disclosed in the embodiment shown in the first aspect of the present disclosure can be applied to at least one processor or implemented by at least one processor. The processor may be an integrated circuit with signal processing capabilities. In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware or software instructions in at least one processor. The above processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present disclosure can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in conjunction with the embodiments of the present disclosure can be directly embodied as a hardware decoding processor for execution, or can be executed by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium mature in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware.

[0104] The electronic device can also execute the methods described in the foregoing method embodiments, and realize the functions and beneficial effects of the methods described in the foregoing method embodiments, which will not be repeated here.

[0105] Of course, in addition to software implementation, the electronic device disclosed in the present invention does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc., that is to say, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.

[0106] In short, the above is only a preferred embodiment of the present disclosure and does not limit the protection scope of the present disclosure. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present disclosure shall be included in the protection scope of the present disclosure.

[0107] The systems, modules or units described in the above embodiments may be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.

[0108] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.

[0109] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

Claims

1. A method for water level prediction, characterized in that: The method comprises: Obtain water level stations and / or precipitation stations directly connected to the target water level station from a pre-built dynamic knowledge graph; Extracting the hydrological characteristics of the target water level station and the water level stations and / or precipitation stations directly connected to the target water level station to obtain a set of hydrological characteristics of the target water level station; Inputting the hydrological feature set into a pre-trained gating network to determine at least one auxiliary prediction model from a hybrid expert network model, wherein the hybrid expert network model includes a plurality of network models pre-trained based on different hydrological training features; The hydrological feature set is input into the at least one auxiliary prediction model and the pre-trained target neural network model to obtain a fused first target prediction result.

2. The method according to claim 1, characterized in that The step of extracting the hydrological characteristics of the target water level station and the water level stations and / or precipitation stations directly connected to the target water level station includes: Extracting hydrological characteristics of the target water level station and water level stations and / or precipitation stations directly connected to the target water level station through a recurrent neural network and a graph convolutional network; The nodes of the knowledge graph are water level sites or precipitation sites, the edges of the knowledge graph are feature correlations between adjacent nodes, and the method further includes: Acquire first original data of each water level station and precipitation station at multiple historical moments, wherein the first original data includes water level data and / or precipitation data; Calculate the first correlation of the first original data between any two nodes of the knowledge graph; Two nodes whose first correlation is greater than or equal to a first correlation threshold are connected through an undirected edge.

3. The method according to claim 2, characterized in that The knowledge graph includes a plurality of sub-knowledge graphs corresponding to different precipitation periods, and the water level station and / or precipitation station directly connected to the target water level station are obtained from the pre-built dynamic knowledge graph, including: Obtaining a sub-knowledge graph corresponding to the current precipitation period from the knowledge graph; Acquire water level stations and / or precipitation stations directly connected to the target water level station from the sub-knowledge graph corresponding to the current precipitation period; The method further comprises: Acquire second original data of each water level station and precipitation station at multiple update times, the second original data including water level data and / or precipitation data, the update time being later than the historical time; Calculating a second correlation of second original data between any two nodes of the knowledge graph; Update the knowledge graph according to the second relevance.

4. The method according to claim 1, characterized in that: The hydrological characteristics of the water level station include at least one of water level characteristics, precipitation characteristics, predicted precipitation characteristics, soil characteristics and runoff characteristics, and the hydrological characteristics of the precipitation station include precipitation characteristics and / or predicted precipitation characteristics; the step of extracting the hydrological characteristics of the target water level station and the water level station and / or precipitation station directly connected to the target water level station to obtain the hydrological characteristic set of the target water level station includes: Extracting a first hydrological feature corresponding to the target water level station, and at least one second hydrological feature corresponding to at least one water level station and / or precipitation station directly connected to the target water level station; Performing graph convolution calculation on the first hydrological feature and the second hydrological feature to obtain a third hydrological feature; The union of the first hydrological feature, the second hydrological feature and the third hydrological feature is taken as the hydrological feature set.

5. The method according to claim 1, characterized in that The multiple network models include at least two of a PatchTST model, a FNN model, and a dynamic graph convolution model; The PatchTST model is obtained by inputting a plurality of water level feature sequences as training data into the PatchTST model to be trained, wherein the water level feature sequences include a plurality of water level features of target water level stations arranged in chronological order; The FNN model is obtained by inputting the water level characteristics, precipitation characteristics and soil characteristics in the hydrological characteristic training set of the target water level station into the FNN model to be trained; The dynamic graph convolution model is obtained by training the hydrological characteristic training set of the target water level station and the corresponding graph structure data into the dynamic graph convolution model to be trained.

6. The method according to claim 1, characterized in that The step of inputting the hydrological feature set into a pre-trained gating network to determine at least one auxiliary prediction model from a pre-trained hybrid expert network model comprises: Inputting the hydrological feature set into the gated network to obtain probabilities corresponding to the multiple network models respectively; At least one network model whose probability is greater than or equal to a preset probability threshold is used as the auxiliary prediction model; or at least one network model with the highest probability is used as the auxiliary prediction model.

7. The method according to claim 1, characterized in that The step of inputting the hydrological feature set into the at least one auxiliary prediction model and the pre-trained target neural network model to obtain a fused first target prediction result includes: The hydrological characteristics of the target water level station are input into a pre-trained target neural network model to obtain a first prediction result, the hydrological characteristic set is input into the at least one auxiliary prediction model to obtain a second prediction result, and a first target prediction result is obtained based on the first prediction result and the second prediction result.

8. The method according to claim 7, characterized in that The obtaining a first target prediction result according to the first prediction result and the second prediction result includes: Determine a first weight and a second weight corresponding to the target neural network model and the auxiliary prediction model respectively according to a mean square error between the target neural network model and the auxiliary prediction model; Taking the weighted sum of the first prediction result and the second prediction result as the first target prediction result; Among them, the weighted weight of the first prediction result is the first weight, and the weighted weight of the second prediction result is the second weight.

9. The method according to any one of claims 1 to 8, characterized in that The method further comprises: The first target prediction result and the hydrological feature set are input into a pre-trained deep neural network model to obtain the second target prediction results at multiple preset moments in the future.

10. An electronic device, characterized in that: include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the method for water level prediction according to any one of claims 1 to 9.

Citation Information

Patent Citations

  • Underground water level height prediction method and system based on multi-feature map network

    CN114841402A

  • Basin water quality prediction method and system, electronic equipment and storage medium

    CN116187203A

  • Basin flood prediction method based on artificial intelligence hydrological model

    CN116989749A

  • Active real-time water level prediction method integrating water conservancy big data

    CN118503930A

  • Water level prediction method and equipment

    CN118760956A

Cited By

  • Reservoir level prediction method based on neural network and uncertainty perception and medium

    CN120851400A

  • Reservoir water level prediction method and medium based on neural network and uncertainty perception

    CN120851400B