Water quality tracing method, apparatus, device, and storage medium

By plotting water quality parameter data into charts and analyzing them using graph neural networks, the problem of low computational efficiency for water quality tracing under large data volumes is solved, achieving fast and accurate water quality tracing, which is suitable for portable water quality equipment.

CN116894173BActive Publication Date: 2026-05-01SHENZHEN ALL SENSING TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SHENZHEN ALL SENSING TECH CO LTD
Filing Date
2023-06-16
Publication Date
2026-05-01

AI Technical Summary

Technical Problem

Existing water quality tracing algorithms take too long to compute when the data volume is too large, which cannot meet the timeliness requirements of water environment monitoring. Furthermore, portable water quality equipment has insufficient computing power and cannot be used with existing water quality tracing algorithms.

Method used

By plotting water quality parameter data into charts and graphs, and using graph neural networks for feature detection and analysis, the amount of data is reduced and computational efficiency is improved.

Benefits of technology

It enables rapid and accurate water quality traceability on low-computing-power devices, meeting the timeliness requirements of water environment testing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116894173B_ABST
    Figure CN116894173B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide a water quality tracing method, device, equipment and storage medium, and relate to the technical field of artificial intelligence. The method comprises: obtaining at least one water quality parameter of each discharge position to form a water quality parameter sample, then generating a parameter graph sample of the water quality parameter sample, training a water quality tracing model by using the parameter graph sample to obtain type prediction data corresponding to the parameter graph sample; and then obtaining a trained water quality tracing model; obtaining water quality parameter data to be detected, and inputting the water quality parameter data to be detected into the trained water quality tracing model for water quality tracing to obtain a target discharge position. The collected water quality parameter data is drawn in a chart form, and various water quality parameters are represented by using chart characteristics, and then the chart characteristics are detected and analyzed by using a graph neural network, so that the data amount can be reduced, the calculation efficiency of water quality tracing analysis can be improved, and the timeliness requirement of water environment detection can be met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence technology, and in particular to water quality tracing methods, apparatus, equipment, and storage media. Background Technology

[0002] Water conservancy is an integral part of the ecological environment improvement system and has a significant impact on achieving high-quality economic and social development. Pollutant source tracing is a crucial link in water environment protection. Currently, most pollutant source tracing methods utilize sensors to detect water quality and transmit data to laboratories for analysis to identify the source of pollutants.

[0003] In related technologies, traditional sensor-based methods for water quality tracing are inefficient. Therefore, artificial intelligence algorithms are used to accurately and quickly analyze water quality parameters for tracing. However, existing water quality tracing algorithms become slow and computationally intensive when dealing with large amounts of data, failing to meet the timeliness requirements of water environment monitoring. Summary of the Invention

[0004] The main objective of this application is to propose a water quality tracing method, apparatus, equipment, and storage medium to improve the computational efficiency of water quality tracing algorithms.

[0005] To achieve the above objectives, a first aspect of this application proposes a water quality tracing method, comprising: acquiring at least one water quality parameter for each discharge location, and forming a water quality parameter sample corresponding to the discharge location;

[0006] Generate parameter map samples of the water quality parameter samples, and construct a graph dataset based on at least one parameter map sample and its corresponding type label, wherein the type label of the parameter map sample corresponds to the discharge location;

[0007] Inputting the graph dataset into the water quality tracing model yields type prediction data corresponding to the parameter graph samples;

[0008] The model weights are adjusted using the type prediction data and the type labels to obtain the trained water quality source tracing model;

[0009] The water quality parameters to be tested are acquired and then input into the trained water quality tracing model to trace the source of water quality and obtain the target discharge location.

[0010] In some embodiments, generating the parameter map sample of the water quality parameter sample includes:

[0011] Obtain the parameter value of each water quality parameter in the water quality parameter sample;

[0012] A water quality parameter bar chart is generated based on the parameter value of each water quality parameter, and saved as an image sample. The water quality parameter bar chart includes a bar for each water quality parameter and the height information of the bar, wherein the height information is the parameter value of the water quality parameter.

[0013] In some embodiments, the water quality tracing model includes: a feature extraction network and a graph prediction model; the step of inputting the graph dataset into the water quality tracing model to obtain type prediction data corresponding to the parameter graph samples includes:

[0014] The parameter map sample is input into the feature extraction network to extract parameter features, thereby obtaining the water quality feature parameter vector of the parameter map sample;

[0015] The water quality characteristic parameter vector is input into the graph prediction model for prediction, and the type prediction data of the parameter graph sample is obtained.

[0016] In some embodiments, the feature extraction network includes convolutional layers and a first fully connected layer; the kernel length of the convolutional layer is the same as the pixel value of the width of the graph bar; the step of inputting the parameter map sample into the feature extraction network for parameter feature extraction to obtain the water quality feature parameter vector of the parameter map sample includes:

[0017] The water quality parameter bar chart is divided into sub-charts corresponding to the number of bars, and each sub-chart contains a bar for one of the water quality parameters.

[0018] Obtain the pixel information of the sub-image, and generate a pixel matrix based on the pixel information;

[0019] The convolutional layer is used to extract features from the pixel matrix to obtain image features;

[0020] The image features are transformed using the first fully connected layer to obtain the height value of the pillar;

[0021] The height value corresponding to each sub-graph is obtained one by one, and the water quality feature parameter vector is generated based on the height value.

[0022] In some embodiments, before inputting the water quality characteristic parameter vector into the graph prediction model for water quality source tracing to obtain the type prediction data of the parameter graph sample, the method further includes:

[0023] At least one first water quality node is generated based on the discharge location, and each first water quality node corresponds to one discharge location; the discharge location includes one or more of the following: domestic sewage discharge location, industrial wastewater discharge location, commercial wastewater discharge location, or surface runoff discharge location.

[0024] At least one second water quality node is generated based on the water quality parameters. Each second water quality node corresponds to one of the water quality parameters. The water quality parameters include one or more of the following: chemical oxygen demand parameter, ammonia nitrogen content parameter, turbidity parameter, or temperature parameter.

[0025] Generate parameter edges between the first water quality node and each of the second water quality nodes one by one; the parameter edges are used to characterize the value of the second water quality node under the first water quality node;

[0026] A water quality traceability graph network is constructed based on the first water quality node, the second water quality node, and the parameter edges.

[0027] In some embodiments, inputting the water quality characteristic parameter vector into the graph prediction model for water quality source tracing to obtain type prediction data for the parameter graph sample includes:

[0028] The height value corresponding to each water quality parameter in the parameter map sample is obtained based on the water quality feature parameter vector.

[0029] Based on the discharge location of the parameter map sample, obtain the parameter threshold range of the water quality parameter at the discharge location;

[0030] The height value is compared with the corresponding parameter threshold range, and the parameter edge corresponding to the height value that is within the parameter threshold range is retained in the water quality traceability map network;

[0031] The first water quality node and the second water quality node connected by the retained parameter edges are obtained as adjacent nodes, and the graph adjacency matrix corresponding to the parameter graph sample is obtained based on the adjacent nodes.

[0032] The weight matrix of the graph prediction model is trained using the graph adjacency matrix to obtain the type of prediction data.

[0033] In some embodiments, the graph prediction model includes: at least one graph convolutional layer and a second fully connected layer; training the weight matrix of the graph prediction model using the graph adjacency matrix to obtain the type of prediction data includes:

[0034] Obtain the feature matrix of the parameter graph sample, and use the feature matrix and the graph adjacency matrix as input vectors to input the graph prediction model for prediction;

[0035] The prediction vector is obtained by sequentially passing through the graph convolutional layer. The prediction vector is then input into the second fully connected layer to obtain the type prediction data, which is one of the first water quality nodes.

[0036] In some embodiments, before generating the parameter map sample of the water quality parameter sample, the method further includes:

[0037] Obtain the sequence value of each of the water quality parameters, wherein the sequence value is composed of the parameter value of the water quality parameter in each water quality parameter sample;

[0038] The water quality parameters in each water quality parameter sample are normalized using the sequence values ​​to obtain updated parameter values.

[0039] To achieve the above objectives, a second aspect of this application provides a water quality traceability device, comprising:

[0040] Water quality parameter acquisition module: used to acquire at least one water quality parameter for each discharge location, forming a water quality parameter sample corresponding to the discharge location;

[0041] Sample generation module: used to generate parameter map samples of the water quality parameter samples, and to construct a map dataset based on at least one parameter map sample and its corresponding type label, wherein the type label of the parameter map sample corresponds to the discharge location;

[0042] Model training module: used to input the graph dataset into the water quality tracing model to obtain type prediction data corresponding to the parameter graph samples;

[0043] Weight adjustment module: used to adjust the model weights using the type prediction data and the type label to obtain the trained water quality tracing model;

[0044] Water quality tracing module: used to acquire water quality parameter data to be tested, and input the water quality parameter data to be tested into the trained water quality tracing model to trace the water quality source and obtain the target discharge location.

[0045] To achieve the above objectives, a third aspect of this application provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the method described in the first aspect.

[0046] To achieve the above objectives, a fourth aspect of the present application provides a storage medium, which is a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method described in the first aspect.

[0047] The water quality tracing method, apparatus, equipment, and storage medium proposed in this application acquire at least one water quality parameter for each discharge location, forming a water quality parameter sample corresponding to the discharge location. Then, a parameter map sample of the water quality parameter sample is generated, and a graph dataset is constructed based on at least one parameter map sample and its corresponding type label. The graph dataset is used to train a water quality tracing model to obtain type prediction data corresponding to the parameter map sample. The model weights are adjusted using the type prediction data and type labels to obtain the trained water quality tracing model. Finally, the water quality parameter data to be detected is acquired and input into the trained water quality tracing model for water quality tracing to obtain the target discharge location. This embodiment plots the collected water quality parameter data in a graph format, representing multiple water quality parameters using graph features. Then, a graph neural network is used to detect and analyze the graph features, which can reduce the amount of data, improve the computational efficiency of water quality tracing analysis, and meet the timeliness requirements of water environment monitoring. Attached Figure Description

[0048] Figure 1 This is a flowchart of the water quality traceability method provided in the embodiments of the present invention.

[0049] Figure 2 yes Figure 1 The flowchart of step S120.

[0050] Figure 3 This is a flowchart of the pretreatment process of a water quality tracing method provided in another embodiment of the present invention.

[0051] Figure 4 This is a schematic diagram of water quality parameters in a bar chart of a water quality traceability method provided in another embodiment of the present invention.

[0052] Figure 5 This is a schematic diagram of a water quality traceability model provided in another embodiment of the water quality traceability method of the present invention.

[0053] Figure 6 yes Figure 1 The flowchart of step S130.

[0054] Figure 7 yes Figure 6 The flowchart of step S131.

[0055] Figure 8 This is a flowchart of the water quality traceability network generation method provided in another embodiment of the present invention.

[0056] Figure 9 This is a schematic diagram of a water quality traceability network provided in another embodiment of the water quality traceability method of the present invention.

[0057] Figure 10This is a schematic diagram of the parameter edges in the water quality traceability graph network of the water quality traceability method provided in another embodiment of the present invention.

[0058] Figure 11 yes Figure 6 The flowchart for step S132 in the process.

[0059] Figure 12 yes Figure 11 The flowchart for step S1325.

[0060] Figure 13 This is a structural block diagram of a water quality traceability device provided in another embodiment of the present invention.

[0061] Figure 14 This is a schematic diagram of the hardware structure of the electronic device provided in an embodiment of the present invention. Detailed Implementation

[0062] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.

[0063] It should be noted that although functional modules are divided in the device schematic diagram and the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart.

[0064] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. The terminology used herein is for the purpose of describing embodiments of the invention only and is not intended to limit the invention.

[0065] First, let's clarify some of the terms used in this invention:

[0066] Artificial intelligence (AI) is a new branch of computer science that studies, develops, and applies theories, methods, technologies, and systems to simulate, extend, and expand human intelligence. It aims to understand the essence of intelligence and produce intelligent machines that can react in a way similar to human intelligence. Research in this field includes robotics, speech recognition, image recognition, natural language processing, and expert systems. AI can simulate the information processes of human consciousness and thought. Furthermore, AI utilizes digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceiving the environment, acquiring knowledge, and using that knowledge to achieve optimal results.

[0067] Graph Neural Networks (GNNs) are deep learning models capable of processing graph data structures. The main idea is to learn features and representations of the entire graph by passing information between nodes and edges. Specifically, GNNs generate feature representations for each node by message passing, aggregation, and updating each node and its surrounding neighbors. These node feature vectors can be used to perform various tasks, such as node classification, graph classification, node clustering, and community detection.

[0068] Water conservancy is an integral part of the ecological environment improvement system and has a significant impact on achieving high-quality economic and social development. Pollutant source tracing is a crucial link in water environment protection. Currently, most pollutant source tracing methods utilize sensors to detect water quality and transmit data to laboratories for analysis to identify the source of pollutants.

[0069] In related technologies, traditional sensor-based water quality tracing is inefficient. Therefore, artificial intelligence algorithms are used to accurately and quickly analyze water quality parameters for tracing. However, existing water quality tracing algorithms become slow and computationally intensive when dealing with large amounts of data, failing to meet the timeliness requirements of water environment monitoring. Furthermore, an increasing number of water environment scenarios utilize portable, real-time water quality monitoring devices. These devices lack powerful computing capabilities and have limited functionality, making them unsuitable for the water quality tracing algorithms presented in these technologies.

[0070] Based on this, embodiments of the present invention provide a water quality tracing method, apparatus, device, and storage medium. By plotting the collected water quality parameter data into a chart format, multiple water quality parameters are represented using chart features. Then, a graph neural network is used to detect and analyze the chart features, which can reduce the amount of data, improve the computational efficiency of water quality tracing analysis, and meet the timeliness requirements of water environment monitoring. At the same time, since the number of parameters to be processed is relatively small, it can be applied to water quality treatment equipment with low computing power.

[0071] The present invention provides a water quality traceability method, apparatus, equipment, and storage medium, which are specifically described through the following embodiments. First, the water quality traceability method in the embodiments of the present invention is described.

[0072] This invention can acquire and process relevant data based on artificial intelligence (AI) technology. AI is the theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use that knowledge to obtain optimal results. In other words, AI is a comprehensive technology within computer science that attempts to understand the essence of intelligence and produce a new type of intelligent machine that can react in a way similar to human intelligence. AI studies the design principles and implementation methods of various intelligent machines, enabling them to possess perception, reasoning, and decision-making capabilities.

[0073] Artificial intelligence (AI) is a comprehensive discipline encompassing a wide range of fields, including both hardware and software technologies. Fundamental AI technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing, operating / interactive systems, and mechatronics. AI software technologies primarily include computer vision, speech processing, natural language processing, and machine learning / deep learning.

[0074] The water quality tracing method provided in this invention relates to the field of artificial intelligence technology, and particularly to the field of data mining technology. The water quality tracing method provided in this invention can be applied to a terminal, a server, or a computer program running on either a terminal or a server. For example, the computer program can be a native program or software module in an operating system; it can be a native application (APP), i.e., a program that needs to be installed in the operating system to run, such as a client supporting water quality tracing; it can also be a mini-program, i.e., a program that only needs to be downloaded to a browser environment to run; or it can be a mini-program that can be embedded in any APP. In short, the above-mentioned computer program can be any form of application, module, or plugin. The terminal communicates with the server via a network. The water quality tracing method can be executed by the terminal or the server, or by the terminal and the server working together.

[0075] In some embodiments, the terminal can be a smartphone, tablet, laptop, desktop computer, or smartwatch, etc. The server can be a standalone server, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms; it can also be a service node in a blockchain system, where the service nodes form a peer-to-peer (P2P) network. The P2P protocol is an application layer protocol running on top of the Transmission Control Protocol (TCP). The server can have the server-side software for the water quality traceability system installed, allowing interaction with the terminal. This could be software that implements water quality traceability methods, but is not limited to these forms. The terminal and server can connect via Bluetooth, USB (Universal Serial Bus), or a network, etc., and this embodiment does not impose any limitations on these connections.

[0076] This invention can be used in a wide variety of general-purpose or special-purpose computer system environments or configurations. Examples include: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices. This invention can be described in the general context of computer-executable instructions, such as program modules, that are executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform specific tasks or implement specific abstract data types. This invention can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.

[0077] The water quality tracing method in the embodiments of the present invention is described below.

[0078] Figure 1 This is an optional flowchart of the water quality tracing method provided in the embodiments of the present invention. Figure 1 The method may include, but is not limited to, steps S110 to S150. It is also understood that this embodiment... Figure 1The order of steps S110 to S150 is not specifically limited, and the order of steps can be adjusted or some steps can be reduced or added according to actual needs.

[0079] Step S110: Obtain at least one water quality parameter for each discharge location to form a water quality parameter sample corresponding to the discharge location.

[0080] In one embodiment, the discharge location can be one or more of the following: domestic sewage discharge location, industrial wastewater discharge location, commercial wastewater discharge location, or surface runoff discharge location. Industrial wastewater can be further subdivided into different locations such as chemical plants, power plants, paper mills, and steel mills; similarly, domestic sewage can be classified according to granularity such as streets, communities, and grids; surface runoff can be distinguished according to runoff names, etc. This embodiment does not specifically limit the discharge location and can be set according to actual source tracing needs.

[0081] In one embodiment, the water quality parameters include one or more of the following: chemical oxygen demand (COD), ammonia nitrogen content, turbidity, or temperature. COD is an indicator of the concentration of organic matter in wastewater and natural water bodies; it is a method for determining the amount of oxidant required to oxidize organic matter in a sample using chemical methods. Ammonia nitrogen content represents the total concentration of ammonia gas and ammonium ions (NH3 and NH4+) present in water or wastewater; ammonia nitrogen is one of the important indicators for measuring the degree of putrefaction and pollution in water bodies. Turbidity reflects the concentration and size of visible impurities or particulate matter in water bodies, expressed in NTU (Nephelometric Turbidity Unit). Turbidity mainly comes from suspended particles, colloids, and other impurities in the water, and is also related to factors such as biomass, organic matter such as humic acid, water temperature, and flow rate. Temperature is one of the important indicators for measuring the thermal state of water bodies, usually expressed in degrees Celsius or Fahrenheit. Water temperature changes are influenced by a variety of factors, including geographical location, climate conditions, seasonal changes, solar radiation, and precipitation patterns.

[0082] In one embodiment, water quality parameter data are collected at different measurement points at different times for different discharge locations, forming multiple water quality parameter samples corresponding to the discharge locations. For example, the water quality parameter samples are represented as: [Chemical Plant Measurement Point 1, Chemical Oxygen Demand Parameter 1, Ammonia Nitrogen Content Parameter 1, Turbidity Parameter 1, Temperature Parameter 1], [Chemical Plant Measurement Point 2, Chemical Oxygen Demand Parameter 2, Ammonia Nitrogen Content Parameter 2, Turbidity Parameter 2, Temperature Parameter 2], [Street A Measurement Point 5, Chemical Oxygen Demand Parameter 3, Ammonia Nitrogen Content Parameter 3, Turbidity Parameter 3, Temperature Parameter 3] or [Runoff B Measurement Point 3, Chemical Oxygen Demand Parameter 4, Ammonia Nitrogen Content Parameter 4, Turbidity Parameter 4, Temperature Parameter 4], etc.

[0083] Step S120: Generate parameter map samples of water quality parameters, and construct a graph dataset based on at least one parameter map sample and its corresponding type label.

[0084] In one embodiment, each water quality parameter sample is converted into a parameter map sample, and a graph dataset is constructed based on the parameter map samples and their corresponding type labels, wherein the type labels of the parameter map samples correspond to the discharge location.

[0085] In one embodiment, reference is made to Figure 2 The generation of the parameter map sample for water quality parameters in step S120 includes the following steps S121 to S122:

[0086] Step S121: Obtain the parameter value of each water quality parameter in the water quality parameter sample.

[0087] In one embodiment, the water quality parameter values ​​are preprocessed, referring to... Figure 3 The preprocessing process includes the following steps:

[0088] Step S1211: Obtain the sequence value of each water quality parameter.

[0089] In this embodiment, the sequence value is composed of the parameter values ​​of the water quality parameters in each water quality parameter sample. For example, there are 10 water quality parameter samples, each containing 4 water quality parameters: chemical oxygen demand (COD), ammonia nitrogen content, turbidity, and temperature. Based on the parameter values ​​of the water quality parameters in the 10 water quality parameter samples, 4 sequence values ​​corresponding to the 4 water quality parameters are obtained. For example, sequence value 1 = [COD parameter 1, COD parameter 2, ..., COD parameter 10], sequence value 2 = [ammonia nitrogen content parameter 1, ammonia nitrogen content parameter 2, ..., ammonia nitrogen content parameter 10], sequence value 3 = [turbidity parameter 1, turbidity parameter 2, ..., turbidity parameter 10], and sequence value 4 = [temperature parameter 1, temperature parameter 2, ..., temperature parameter 10].

[0090] Step S1212: Standardize the water quality parameters in each water quality parameter sample using the sequence values ​​to obtain updated parameter values.

[0091] Based on the sequence values ​​described in the above embodiment, the parameter values ​​of the 10 water quality parameter samples are standardized using the sequence values. Standardization ensures that the heights of the water quality parameters in the bar chart are not too disparate. The standardization process is described below using sequence value 3 as an example:

[0092] First, add the elements in sequence value 3 to obtain the total turbidity parameter value: total turbidity parameter value = turbidity parameter 1 + turbidity parameter 2 + ... + turbidity parameter 10.

[0093] Then, the total turbidity parameter value is used to normalize each turbidity parameter to obtain the updated turbidity parameters, expressed as:

[0094] Updated value of turbidity parameter 1: Turbidity parameter 1 / Total value of turbidity parameters;

[0095] Updated value of turbidity parameter 2: Turbidity parameter 2 / Total turbidity parameter value;

[0096]

[0097] Updated value of turbidity parameter 10: Turbidity parameter 10 / Total turbidity parameter value;

[0098] Step S122: Generate a water quality parameter bar chart based on the parameter value of each water quality parameter, and save it as a parameter chart sample in the form of an image.

[0099] In one embodiment, the parameter values ​​here are the normalized parameter values ​​described above, and the parameter chart sample is a water quality parameter bar chart. This water quality parameter bar chart includes bars and bar height information, where the bars represent water quality parameters, and the height information is the parameter value of the water quality parameter. It is understood that the water quality parameter bar chart can be drawn using office software or manually; this embodiment does not specifically limit the drawing method.

[0100] Reference Figure 4 Assuming a water quality parameter sample is represented as: [Street A, Measurement Point 5, Chemical Oxygen Demand (COD) = 0.5, Ammonia Nitrogen Content = 0.4, Turbidity = 0.2, Temperature = 0.6], it can be seen that... Figure 4 The water quality parameter bar chart contains four bars: chemical oxygen demand (COD), ammonia nitrogen content, turbidity, and temperature. The height of each bar represents the updated parameter value for each water quality parameter.

[0101] In the above embodiments, the parameter map sample includes a water quality parameter bar chart and corresponding type labels, where the type labels indicate the discharge location of the water quality parameter sample. For example... Figure 4 The type label for the parametric graph sample is Street A. It is understood that the width of the bars can be set according to requirements, and the bar width is the same in each parametric graph sample.

[0102] The above process yields multiple parameter map samples for training the water quality source tracing model. The training process of the water quality source tracing model is described below.

[0103] Step S130: Input the graph dataset into the water quality tracing model to obtain type prediction data corresponding to the parameter graph samples.

[0104] In one embodiment, reference is made to Figure 5The water quality tracing model 10 includes a feature extraction network 110 and a graph prediction model 120. The output of the feature extraction network 110 serves as the input to the graph prediction model 120, and the output of the graph prediction model 120 is the output of the water quality tracing model. The feature extraction network 110 includes at least one sequentially connected convolutional layer and a first fully connected layer. The graph prediction model 120 includes at least one graph convolutional layer and a second fully connected layer. Both the graph convolutional layer and the graph prediction model 120 perform convolutional operations. The number of convolutional layers in the feature extraction network 110 and the number of graph convolutional layers in the graph prediction model 120 can be set according to actual conditions.

[0105] In one embodiment, reference is made to Figure 6 Step S130 includes steps S131 to S132:

[0106] Step S131: Input the parameter map sample into the feature extraction network to extract parameter features and obtain the water quality feature parameter vector of the parameter map sample.

[0107] In one embodiment, the feature extraction network is a convolutional neural network model, where the kernel length of the convolutional layer in the convolutional neural network model is the same as the pixel value of the width of the bars in the parameter map sample. (Refer to...) Figure 7 Step S131 includes steps S1311 to S1315:

[0108] Step S1311: Divide the water quality parameter bar chart to obtain sub-charts corresponding to the number of bars, each sub-chart containing a bar for one water quality parameter.

[0109] In one embodiment, the purpose of this segmentation step is to represent each bar in the water quality parameter bar chart independently, referring to... Figure 4 The graph was split into four subgraphs, among which the subgraphs were... Figure 1 Corresponding bar charts and sub-charts for chemical oxygen demand parameters Figure 2 The corresponding bars and sub-bars for ammonia nitrogen content parameters Figure 3 Corresponding bars and sub-charts for turbidity parameters Figure 4 The corresponding temperature parameters are represented by bars. Next, the height value of each bar is identified for each sub-plot.

[0110] Step S1312: Obtain the pixel information of the sub-image and generate a pixel matrix based on the pixel information.

[0111] Step S1313: Use convolutional layers to extract features from the pixel matrix to obtain image features.

[0112] Step S1314: Use the first fully connected layer to transform the image features to obtain the height value of the pillar.

[0113] In one embodiment, pixel information of each sub-image is acquired, and then a pixel matrix is ​​generated based on the pixel information. This pixel matrix is ​​an N*M matrix, where N is the pixel width of the sub-image and M is the pixel height of the sub-image. The pixel matrix is ​​then input into a convolutional layer for feature extraction to obtain image features. These image features are then input into a first fully connected layer for transformation to obtain the height values ​​of the pillars.

[0114] Step S1315: Obtain the height value corresponding to each sub-image, and generate a water quality feature parameter vector based on the height value.

[0115] In one embodiment, a feature extraction network is used to extract the height value of each sub-image one by one to obtain the height value of each water quality parameter corresponding to each parameter image sample. The height values ​​of all water quality parameters of the corresponding sample are arranged in sequence to construct a water quality feature parameter vector.

[0116] Before using the water quality parameter feature vector input graph prediction model for water quality source tracing, embodiments of this application further include generating a water quality source tracing graph network. In one embodiment, referring to... Figure 8 Generating a water quality source tracing map network includes the following steps S810 to S840:

[0117] Step S810: Generate at least one first water quality node based on the discharge location, with each first water quality node corresponding to a discharge location.

[0118] Step S820: Generate at least one second water quality node based on the water quality parameters, with each second water quality node corresponding to a water quality parameter.

[0119] Step S830: Generate parameter edges between the first water quality node and each second water quality node one by one.

[0120] Step S840: Construct a water quality source tracing graph network based on the first water quality node, the second water quality node, and the parameter edges.

[0121] In one embodiment, the parameter edge is used to characterize the value of the second water quality node under the first water quality node. (Refer to...) Figure 9This diagram illustrates the generation of a water quality source tracing network using multiple parameter map samples. The first water quality node represents the discharge location, such as domestic sewage 1, domestic sewage 2, commercial sewage 1, paper mill 1, steel mill 3, surface runoff 1, etc. The second water quality node represents water quality parameters, such as chemical oxygen demand (COD), ammonia nitrogen content, turbidity, and temperature. For each parameter map sample, a water quality feature parameter vector can be extracted. Based on this feature parameter vector, parameter edges are generated between the first and second water quality nodes. The feature value of each parameter edge is the value of the second water quality node under the first water quality node. The values ​​of the parameter edges differ for different parameter map samples. The dashed line in the diagram represents a parameter map sample corresponding to domestic sewage 2 in the water quality source tracing network. (Refer to...) Figure 10 The parameter edges are obtained from the water quality feature parameter vector extracted by the feature extraction network.

[0122] Step S132: Input the water quality characteristic parameter vector into the graph prediction model for prediction to obtain the type prediction data of the parameter graph sample.

[0123] In one embodiment, reference is made to Figure 11 When using a graph prediction model for prediction, it is necessary to obtain the adjacency matrix corresponding to each parameter graph sample, and use the adjacency matrix to obtain type prediction data. Step S132 includes the following steps S1321 to S1325:

[0124] Step S1321: Obtain the height value corresponding to each water quality parameter in the parameter map sample based on the water quality characteristic parameter vector.

[0125] Step S1322: Obtain the parameter threshold range of water quality parameters at the discharge location based on the discharge location of the parameter map sample.

[0126] In one embodiment, the threshold ranges of water quality parameters are different at different discharge locations, so each parameter map sample can correspond to a set of parameter threshold ranges.

[0127] Step S1323: Compare the height value with the corresponding parameter threshold range, and retain the parameter edge corresponding to the height value within the parameter threshold range in the water quality source tracing map network.

[0128] In one embodiment, for each parameter graph sample, the height value of each water quality parameter is compared with the corresponding parameter threshold range. If the height value of a certain water quality parameter is within the corresponding parameter threshold range, the parameter edge corresponding to that parameter value in the water quality traceability graph network is retained. Water quality parameters are compared one by one to obtain at least one retained parameter edge for each parameter graph sample.

[0129] Step S1324: Obtain the first and second water quality nodes connected by the preserved parameter edges as adjacent nodes, and obtain the graph adjacency matrix corresponding to the parameter graph sample based on the adjacent nodes.

[0130] In one embodiment, each parameter edge connects a first water quality node and a second water quality node. The first and second water quality nodes connected by the retained parameter edges are designated as adjacent nodes. Then, the graph adjacency matrix corresponding to the parameter graph sample is obtained based on the feature values ​​of the parameter edges of each adjacent node. For example, the size of the graph adjacency matrix C is A*B, where A is the number of first water quality nodes, B is the number of second water quality nodes, and Cij represents the parameter edge of the j-th second water quality node under the i-th first water quality node. If the parameter edge is retained, Cij = 1; otherwise, Cij = 0. By establishing the relationship between different nodes through the adjacency matrix, the structural information in the water quality source tracing graph network can be better utilized.

[0131] Step S1325: Train the weight matrix of the graph prediction model using the graph adjacency matrix to obtain type prediction data.

[0132] In one embodiment, after obtaining the graph adjacency matrix, the weight matrix of the graph prediction model is trained using the graph adjacency matrix to obtain type prediction data, which is then referred to... Figure 12 Step S1325 includes the following steps: S1210 to S1220:

[0133] Step S1210: Obtain the feature matrix of the parameter graph sample, and use the feature matrix and graph adjacency matrix as input vectors to input the graph prediction model for prediction.

[0134] Step S1220: The prediction vector is obtained by passing the graph convolutional layer sequentially, and the prediction vector is input into the second fully connected layer to obtain the type prediction data.

[0135] In one embodiment, the feature matrix of the parameter graph sample is composed of the feature vectors of all nodes of the parameter graph sample in the water quality source tracing graph network. The feature vectors are obtained from the values ​​of the parameter edges corresponding to the parameter graph sample. It can be seen that the feature matrix can characterize the water quality parameter information of the parameter graph sample. In this embodiment, the dimension of the feature vector can be one-dimensional. Then, the feature vector and the adjacency matrix corresponding to the parameter graph sample are used as input vectors and simultaneously input into the graph prediction model for prediction. The model is then processed by graph convolutional layers. The purpose of convolution is to perform weighted aggregation of features of adjacent nodes of a graph node, and finally obtain the prediction vector. The prediction vector is input into the second fully connected layer to obtain type prediction data, where the type prediction data is one of the first water quality nodes. That is to say, the output of the graph prediction model is the predicted discharge location of the parameter graph sample.

[0136] Step S140: Adjust the model weights using type prediction data and type labels to obtain the trained water quality source tracing model.

[0137] In one embodiment, the predicted emission locations and corresponding type labels are used to adjust the weights of the hidden layer, and the model is trained using gradient descent. During training, the activation function is the ReLU function, and the weight parameters of the water quality tracing model are optimized and adjusted until the loss function value converges. After the above training process, the trained water quality tracing model is obtained.

[0138] Step S150: Obtain the water quality parameter data to be tested, and input the water quality parameter data to be tested into the trained water quality tracing model to trace the water quality source and obtain the target discharge location.

[0139] In one embodiment, after training the water quality traceability model, the model is installed on the water quality equipment. After the sensor collects the water quality parameters, the water quality equipment, other terminals, or the server generate a bar chart based on the water quality parameters. The bar chart is then input into the water quality traceability model for water quality traceability. This eliminates the need to identify a large number of water quality parameters; only the graphical data needs to be identified. The number of parameters is small, making it suitable for water quality equipment with low computing power and meeting the real-time requirements of water quality traceability.

[0140] The technical solution provided by this invention involves acquiring at least one water quality parameter for each discharge location to form a water quality parameter sample corresponding to the discharge location. Then, a parameter map sample of the water quality parameter sample is generated, and a graph dataset is constructed based on at least one parameter map sample and its corresponding type label. The graph dataset is used to train a water quality tracing model to obtain type prediction data corresponding to the parameter map sample. The model weights are adjusted using the type prediction data and type labels to obtain the trained water quality tracing model. Finally, the water quality parameter data to be detected is acquired and input into the trained water quality tracing model for water quality tracing to obtain the target discharge location. This embodiment plots the collected water quality parameter data in a graph format, representing multiple water quality parameters using graph features. Then, a graph neural network is used to detect and analyze the graph features, which reduces the amount of data, improves the computational efficiency of water quality tracing analysis, and meets the timeliness requirements of water environment monitoring.

[0141] This invention also provides a water quality traceability device that can implement the above-described water quality traceability method, as described above. Figure 13 The device includes:

[0142] Water quality parameter acquisition module 1310: used to acquire at least one water quality parameter for each discharge location, forming a water quality parameter sample corresponding to the discharge location.

[0143] Sample generation module 1320: Used to generate parameter map samples of water quality parameters, and to construct a graph dataset based on at least one parameter map sample and its corresponding type label, wherein the type label of the parameter map sample corresponds to the discharge location.

[0144] Model training module 1330: Used to train a water quality tracing model using a graph dataset to obtain type prediction data corresponding to the parameter graph samples.

[0145] Weight adjustment module 1340: Used to adjust the model weights using type prediction data and type labels to obtain the trained water quality traceability model.

[0146] Water quality traceability module 1350: Used to acquire water quality parameter data to be tested, and input the water quality parameter data to be tested into the trained water quality traceability model to trace the water quality source and obtain the target discharge location.

[0147] The specific implementation method of the water quality traceability device in this embodiment is basically the same as the specific implementation method of the water quality traceability method described above, and will not be repeated here.

[0148] This invention also provides an electronic device, comprising:

[0149] At least one memory;

[0150] At least one processor;

[0151] At least one program;

[0152] The program is stored in a memory, and the processor executes the at least one program to implement the water quality tracing method described above in this invention. The electronic device can be any smart terminal, including mobile phones, tablets, personal digital assistants (PDAs), and in-vehicle computers.

[0153] Please see Figure 14 , Figure 14 The hardware structure of an electronic device according to another embodiment is illustrated. The electronic device includes:

[0154] The processor 1401 can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present invention.

[0155] The memory 1402 can be implemented in the form of ROM (Read-Only Memory), static storage device, dynamic storage device, or RAM (Random Access Memory). The memory 1402 can store the operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 1402 and is called and executed by the processor 1401 to execute the water quality traceability method of the embodiments of this invention.

[0156] The input / output interface 1403 is used to implement information input and output;

[0157] Communication interface 1404 is used to enable communication and interaction between this device and other devices. Communication can be achieved via wired means (e.g., USB, Ethernet cable) or wireless means (e.g., mobile network, Wi-Fi, Bluetooth).

[0158] Bus 1405 transmits information between various components of the device (e.g., processor 1401, memory 1402, input / output interface 1403, and communication interface 1404);

[0159] The processor 1401, memory 1402, input / output interface 1403 and communication interface 1404 are connected to each other within the device via bus 1405.

[0160] This application embodiment also provides a storage medium, which is a computer-readable storage medium, storing a computer program that, when executed by a processor, implements the above-described water quality traceability method.

[0161] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory may optionally include memory remotely located relative to the processor, and these remote memories can be connected to the processor via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.

[0162] The water quality tracing method, device, electronic equipment, and storage medium proposed in this invention acquire at least one water quality parameter at each discharge location, forming a water quality parameter sample corresponding to the discharge location. Then, a parameter map sample of the water quality parameter sample is generated, and a graph dataset is constructed based on at least one parameter map sample and its corresponding type label. The graph dataset is used to train a water quality tracing model to obtain type prediction data corresponding to the parameter map sample. The model weights are adjusted using the type prediction data and type labels to obtain the trained water quality tracing model. Finally, the water quality parameter data to be detected is acquired and input into the trained water quality tracing model for water quality tracing to obtain the target discharge location. This embodiment plots the collected water quality parameter data in a graph format, representing multiple water quality parameters using graph features. Then, a graph neural network is used to detect and analyze the graph features, which can reduce the amount of data, improve the computational efficiency of water quality tracing analysis, and meet the timeliness requirements of water environment monitoring.

[0163] The embodiments described in this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided by the embodiments of this application. As those skilled in the art will know, with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of this application are also applicable to similar technical problems.

[0164] Those skilled in the art will understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of this application, and may include more or fewer steps than shown, or combine certain steps, or different steps.

[0165] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0166] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.

[0167] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0168] It should be understood that in this application, "at least one (item)" means one or more, and "more than" means two or more. "And / or" is used to describe the relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: only A exists, only B exists, and both A and B exist simultaneously, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one (item) of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one (item) of a, b, or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.

[0169] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of the units described above is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0170] The units described above as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0171] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0172] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes multiple instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing programs, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0173] The preferred embodiments of the present application have been described above with reference to the accompanying drawings, but this does not limit the scope of the claims of the present application. Any modifications, equivalent substitutions, and improvements made by those skilled in the art without departing from the scope and substance of the embodiments of the present application shall be within the scope of the claims of the present application.

Claims

1. A method for tracing water quality sources, characterized in that, include: At least one water quality parameter is obtained for each discharge location to form a water quality parameter sample corresponding to the discharge location; Obtain the parameter value of each water quality parameter in the water quality parameter sample, generate a water quality parameter bar chart based on the parameter value of each water quality parameter, and save it as a parameter chart sample in the form of an image; the water quality parameter bar chart includes a bar for each water quality parameter and the height information of the bar, the height information being the parameter value of the water quality parameter, and construct a graph dataset based on at least one parameter chart sample and a corresponding type label, the type label of the parameter chart sample corresponding to the discharge location; The parameter map sample is input into the feature extraction network of the water quality tracing model for parameter feature extraction. The feature extraction network includes a convolutional layer and a first fully connected layer. The kernel length of the convolutional layer is the same as the pixel value of the width of the bar. The water quality parameter bar chart is segmented to obtain sub-maps corresponding to the number of bars. Each sub-map contains a bar for one water quality parameter. The pixel information of the sub-map is obtained, and a pixel matrix is ​​generated based on the pixel information. The convolutional layer is used to extract features from the pixel matrix to obtain image features. The first fully connected layer is used to transform the image features to obtain the height value of the bar. The height value corresponding to each sub-map is obtained one by one, and a water quality feature parameter vector is generated based on the height value. The water quality feature parameter vector is input into the graph prediction model of the water quality tracing model for prediction to obtain the type prediction data of the parameter map sample. The model weights are adjusted using the type prediction data and the type labels to obtain the trained water quality source tracing model; The water quality parameters to be tested are acquired and then input into the trained water quality tracing model to trace the source of water quality and obtain the target discharge location.

2. The water quality traceability method according to claim 1, characterized in that, Before inputting the water quality characteristic parameter vector into the graph prediction model for water quality source tracing to obtain the type prediction data of the parameter graph sample, the method further includes: At least one first water quality node is generated based on the discharge location, and each first water quality node corresponds to one discharge location; the discharge location includes one or more of the following: domestic sewage discharge location, industrial wastewater discharge location, commercial wastewater discharge location, or surface runoff discharge location. At least one second water quality node is generated based on the water quality parameters. Each second water quality node corresponds to one of the water quality parameters. The water quality parameters include one or more of the following: chemical oxygen demand parameter, ammonia nitrogen content parameter, turbidity parameter, or temperature parameter. Generate parameter edges between the first water quality node and each of the second water quality nodes one by one; the parameter edges are used to characterize the value of the second water quality node under the first water quality node; A water quality traceability graph network is constructed based on the first water quality node, the second water quality node, and the parameter edges.

3. The water quality traceability method according to claim 2, characterized in that, The step of inputting the water quality characteristic parameter vector into the graph prediction model for water quality source tracing to obtain type prediction data for the parameter graph sample includes: The height value corresponding to each water quality parameter in the parameter map sample is obtained based on the water quality feature parameter vector. Based on the discharge location of the parameter map sample, obtain the parameter threshold range of the water quality parameter at the discharge location; The height value is compared with the corresponding parameter threshold range, and the parameter edge corresponding to the height value that is within the parameter threshold range is retained in the water quality traceability map network; The first water quality node and the second water quality node connected by the retained parameter edges are obtained as adjacent nodes, and the graph adjacency matrix corresponding to the parameter graph sample is obtained based on the adjacent nodes. The weight matrix of the graph prediction model is trained using the graph adjacency matrix to obtain the type of prediction data.

4. The water quality traceability method according to claim 3, characterized in that, The graph prediction model includes: at least one graph convolutional layer and a second fully connected layer; the step of training the weight matrix of the graph prediction model using the graph adjacency matrix to obtain the type of prediction data includes: Obtain the feature matrix of the parameter graph sample, and use the feature matrix and the graph adjacency matrix as input vectors to input the graph prediction model for prediction; The prediction vector is obtained by sequentially passing through the graph convolutional layer. The prediction vector is then input into the second fully connected layer to obtain the type prediction data, which is one of the first water quality nodes.

5. The water quality traceability method according to any one of claims 1 to 4, characterized in that, Before generating the parameter map sample of the water quality parameter sample, the method further includes: Obtain the sequence value of each of the water quality parameters, wherein the sequence value is composed of the parameter value of the water quality parameter in each water quality parameter sample; The water quality parameters in each water quality parameter sample are normalized using the sequence values ​​to obtain updated parameter values.

6. A water quality traceability device, characterized in that, include: Water quality parameter acquisition module: used to acquire at least one water quality parameter for each discharge location, forming a water quality parameter sample corresponding to the discharge location; Sample generation module: used to obtain the parameter value of each water quality parameter in the water quality parameter sample, generate a water quality parameter bar chart based on the parameter value of each water quality parameter, and save it as a parameter chart sample in the form of an image; the water quality parameter bar chart includes a bar for each water quality parameter and the height information of the bar, the height information being the parameter value of the water quality parameter, and constructs a graph dataset based on at least one parameter chart sample and a corresponding type label, the type label of the parameter chart sample corresponding to the discharge location; Model training module: This module is used to input the parameter map samples into the feature extraction network of the water quality tracing model for parameter feature extraction. The feature extraction network includes a convolutional layer and a first fully connected layer. The kernel length of the convolutional layer is the same as the pixel value of the width of the bar. The water quality parameter bar chart is segmented to obtain sub-maps corresponding to the number of bars. Each sub-map contains a bar for one water quality parameter. The pixel information of the sub-map is obtained, and a pixel matrix is ​​generated based on the pixel information. The convolutional layer is used to extract features from the pixel matrix to obtain image features. The first fully connected layer is used to transform the image features to obtain the height value of the bar. The height value corresponding to each sub-map is obtained one by one, and a water quality feature parameter vector is generated based on the height value. The water quality feature parameter vector is input into the graph prediction model of the water quality tracing model for prediction to obtain type prediction data for the parameter map samples. Weight adjustment module: used to adjust the model weights using the type prediction data and the type label to obtain the trained water quality tracing model; Water quality tracing module: used to acquire water quality parameter data to be tested, and input the water quality parameter data to be tested into the trained water quality tracing model to trace the water quality source and obtain the target discharge location.

7. An electronic device, characterized in that, The electronic device includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the water quality traceability method according to any one of claims 1 to 5.

8. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the water quality tracing method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • Surface water quality parameter prediction method and system, computer equipment and storage medium

    CN114267422A