Early warning method and device for water environment anomaly and storage medium
By screening and training candidate time-series features of water environment monitoring data, the problems of large data volume and low prediction efficiency in water environment monitoring have been solved, and faster and more accurate anomaly early warning has been achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-05
- Publication Date
- 2026-03-10
AI Technical Summary
Existing technologies for water environment monitoring suffer from problems such as large data volume, low prediction efficiency, and high latency when inputting artificial intelligence models.
By extracting multiple candidate time-series features, determining dynamic weights based on contribution and information content, selecting target time-series features, and training the anomaly prediction model until the iteration stopping condition is met, anomaly warning for the water environment is achieved.
It reduces the amount of data input to the anomaly prediction model while ensuring the accuracy of the model's predictions, avoiding the problems of low efficiency and high latency in traditional anomaly prediction, and achieving faster and more accurate early warning of water environment anomalies.
Smart Images

Figure CN121071445B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of artificial intelligence technology, and in particular to a method, device and storage medium for early warning of water environment anomalies. Background Technology
[0002] With the development of the Internet of Things (IoT) system, remote online monitoring of the water environment can now be achieved by installing various sensors in the water environment and sending the collected data to processing devices for analysis, thereby improving the efficiency of water environment monitoring. For example, urban drainage networks are an important part of urban lifeline engineering, and their operation is directly related to urban flood control, drainage, and environmental protection. In this case, various sensors can be installed in the urban drainage network to monitor it, such as chemical oxygen demand (COD) and pH.
[0003] In a typical method for early warning of water environment anomalies, a pre-trained artificial intelligence model can be used to predict the time series of parameters collected by sensors in order to determine whether the water environment is abnormal and issue an early warning.
[0004] However, there are many types of time series parameters collected by sensors, and each type of time series includes a large amount of data. Different data information contributes differently to the prediction results, which leads to problems such as a large amount of data input to the artificial intelligence model, low prediction efficiency, and high latency. Summary of the Invention
[0005] In view of this, this disclosure proposes an early warning method, device and storage medium for water environment anomalies; it can solve the problems of large data volume, low prediction efficiency and high latency of input artificial intelligence models.
[0006] According to one aspect of this disclosure, an early warning method for water environment anomalies is provided, the method comprising:
[0007] Extract multiple candidate time-series features from monitoring parameter time-series samples that include at least water quality parameter time-series samples;
[0008] Based on the contribution, information content, first dynamic weight of the contribution, and second dynamic weight of the information content provided by each candidate temporal feature to the anomaly prediction result of the anomaly prediction model to be trained in the kth round, a joint screening score for each candidate temporal feature is determined; the first dynamic weight and the second dynamic weight are determined based on the first feature set obtained by screening using the contribution and the first model performance parameter obtained by the anomaly prediction model to be trained in the kth round, and the second model performance parameter obtained by screening the second feature set obtained by screening using the information content and the anomaly prediction model to be trained in the kth round.
[0009] Based on the current target time-series features selected from the multiple candidate time-series features using the joint screening score, the anomaly prediction model to be trained in the kth round is trained in one round; until the anomaly prediction model to be trained meets the iteration stopping condition, the trained anomaly prediction model is obtained.
[0010] The trained anomaly prediction model is used to provide early warning of anomalies in the target aquatic environment.
[0011] In one possible implementation, before determining the joint screening score for each candidate temporal feature, the method further includes:
[0012] Based on the contribution of each candidate time series feature, feature filtering is performed on the multiple candidate time series features to obtain the first feature set;
[0013] Based on the information content of each candidate time series feature, feature filtering is performed on the multiple candidate time series features to obtain the second feature set;
[0014] Based on the feature values of each candidate time-series feature in the first feature set and the label corresponding to each feature value, the anomaly prediction model to be trained in the kth round is trained and the model is validated to obtain the first model performance parameters of the model obtained in the kth round of training; k is a positive integer;
[0015] Based on the feature value of each candidate time-series feature in the second feature set and the label corresponding to each feature value, the anomaly prediction model to be trained in the kth round is trained and the model is validated to obtain the second model performance parameters of the model obtained in the kth round of training.
[0016] Based on the first model performance parameters and the second model performance parameters, the first dynamic weight and the second dynamic weight corresponding to the anomaly prediction model to be trained in the (k-1)th round are updated to obtain the first dynamic weight and the second dynamic weight corresponding to the anomaly prediction model to be trained in the kth round. When k=1, the first dynamic weight and the second dynamic weight are initialized to preset values.
[0017] In one possible implementation, determining the joint screening score for each candidate temporal feature includes:
[0018] Determine the union of the first feature set and the second feature set;
[0019] The contribution and information content of each candidate time series feature in the union set are normalized to obtain the normalized contribution and information content of each candidate time series feature.
[0020] For each candidate time-series feature in the union set, the joint screening score of the candidate time-series feature is determined based on the first dynamic weight, the normalized contribution of the candidate time-series feature, the second dynamic weight, and the normalized information content of the candidate time-series feature.
[0021] In one possible implementation, the current target time-series feature selected from the plurality of candidate time-series features using the joint screening score includes:
[0022] Based on the joint screening score, feature screening is performed on the multiple candidate time-series features to obtain the screening results;
[0023] Determine whether the candidate time-series features in the screening results meet the similarity condition;
[0024] If the similarity condition is satisfied between at least two candidate time series features, at least one candidate time series feature is selected as the current target time series feature from the at least two candidate time series features that satisfy the similarity condition.
[0025] In one possible implementation, determining whether the candidate time-series features in the screening results satisfy a similarity condition includes:
[0026] Determine the cross-entropy and / or correlation coefficient between different candidate time-series features in the screening results; wherein, the higher the cross-entropy and / or correlation coefficient, the more similar the different candidate time-series features are.
[0027] If the cross-entropy and / or correlation coefficient between the different candidate time series features are greater than a preset threshold, it is determined that the different candidate time series features meet the similarity condition.
[0028] In one possible implementation, the early warning of anomalies in the target aquatic environment based on the trained anomaly prediction model includes:
[0029] Extract the final target time series features used by the trained anomaly prediction model from the time series of monitoring parameters of the target water environment at the monitoring point; wherein, the time series of monitoring parameters includes at least the time series of water quality parameters;
[0030] The feature value matrix of the final target time series features is input into the trained anomaly prediction model to obtain the anomaly probability of the target water environment;
[0031] Based on the current state of the target water environment, determine the dynamic threshold for early warning of the target water environment;
[0032] When the probability of an anomaly is greater than the dynamic threshold, an early warning is issued for the target water environment.
[0033] In one possible implementation, determining the dynamic threshold for early warning of the target water environment based on its current state includes:
[0034] The sensitivity enhancement coefficient and sensitivity inhibition coefficient of the target water environment are obtained;
[0035] The dynamic threshold is determined based on the sensitivity enhancement coefficient, the sensitivity suppression coefficient, and the preset baseline threshold.
[0036] In one possible implementation, obtaining the sensitivity enhancement coefficient and sensitivity inhibition coefficient of the target aquatic environment includes:
[0037] Based on the first target area to which the target water environment currently belongs, determine the regional sensitivity enhancement coefficient of the target water environment;
[0038] Based on the current first-time parameters of the target water environment, determine the time sensitivity enhancement coefficient of the target water environment;
[0039] The pollution duration coefficient of the target water environment is determined based on the duration during which the probability of an anomaly in the target water environment is greater than the preset baseline threshold.
[0040] The sensitivity enhancement coefficient is determined based on the regional sensitivity enhancement coefficient, the time sensitivity enhancement coefficient, and the pollution duration coefficient.
[0041] Based on the second target region to which the target water environment currently belongs, determine the regional sensitivity suppression coefficient of the target water environment;
[0042] Based on the current second time parameter of the target water environment, determine the time sensitivity suppression coefficient of the target water environment;
[0043] Based on the hydrological period corresponding to the current third time parameter of the target water environment, the hydrological sensitivity suppression coefficient of the target water environment is determined.
[0044] The sensitivity suppression coefficient is determined based on the regional sensitivity suppression coefficient, the time sensitivity suppression coefficient, and the hydrological sensitivity suppression coefficient.
[0045] According to another aspect of this disclosure, an early warning device for water environment anomalies is provided, including a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the above-described method.
[0046] According to another aspect of this disclosure, a non-volatile computer-readable storage medium is provided, on which a computer program is stored, which, when executed by a processor, implements the steps of the above-described method.
[0047] The first dynamic weight and the second dynamic weight are determined by using the first feature set obtained through contribution filtering and the first model performance parameters obtained from the anomaly prediction model to be trained in the kth round, and the second feature set obtained through information filtering and the second model performance parameters obtained from the anomaly prediction model to be trained in the kth round. A joint filtering score is determined for each candidate time-series feature based on its contribution, information content, first dynamic weight, and second dynamic weight. The anomaly prediction model to be trained in the kth round is trained once based on the current target time-series feature selected from multiple candidate time-series features using the joint filtering score. This training continues until the anomaly prediction model meets the iteration stopping condition, resulting in a trained anomaly prediction model. Anomalies in the target water environment are then warned based on the trained anomaly prediction model. The time-series features corresponding to the time series of each monitoring parameter can be input into the model. These time-series features are selected from multiple candidate feature sequences, reducing the amount of data input to the trained anomaly prediction model while ensuring the accuracy of the model's predictions, thus avoiding the problems of low efficiency and high latency in traditional anomaly prediction.
[0048] Meanwhile, since the contribution degree can indicate the direction and magnitude of each candidate time series feature's contribution to the prediction result, and the information content can indicate the amount of information each candidate time series feature provides to the prediction result, in this embodiment, by combining the contribution degree and information content of each candidate time series feature to select the target time series feature, the target time series feature that has a significant impact on the model prediction can be identified more comprehensively and reliably, thereby further improving the accuracy of anomaly prediction.
[0049] Other features and aspects of this disclosure will become clear from the following detailed description of exemplary embodiments with reference to the accompanying drawings. Attached Figure Description
[0050] The accompanying drawings, which are included in and form part of this specification, illustrate exemplary embodiments, features, and aspects of this disclosure together with the specification and serve to explain the principles of this disclosure.
[0051] Figure 1 A flowchart illustrating an early warning method for water environment anomalies according to an embodiment of the present disclosure is shown.
[0052] Figure 2 A schematic diagram showing a time series sample of monitoring parameters according to an embodiment of the present disclosure is provided.
[0053] Figure 3 A schematic diagram illustrating the sorting of candidate temporal features according to a joint screening score according to an embodiment of the present disclosure is shown.
[0054] Figure 4 A block diagram of an early warning device for water environment anomalies according to an embodiment of the present disclosure is shown;
[0055] Figure 5 A block diagram of an early warning device for water environment anomalies according to another embodiment of the present disclosure is shown. Detailed Implementation
[0056] Various exemplary embodiments, features, and aspects of this disclosure will now be described in detail with reference to the accompanying drawings. The same reference numerals in the drawings denote elements that have the same or similar functions. Although various aspects of the embodiments are shown in the drawings, they are not necessarily drawn to scale unless specifically indicated otherwise.
[0057] As used herein, the terms “comprising,” “including,” “having,” or variations thereof are open-ended and include one or more of the stated features, integrals, elements, steps, components, or functions, but do not exclude the presence or addition of one or more other features, integrals, elements, steps, components, functions, or groups thereof.
[0058] When an element is referred to as “connected,” “coupled,” “responding,” or a variation thereof relative to another element, it may be directly connected, coupled, or responding to another element, or there may be an intermediate element present.
[0059] Although the terms first, second, third, etc., may be used herein to describe various elements / operations, these elements / operations should not be limited by these terms. These terms are only used to distinguish one element / operation from another. Therefore, without departing from the teachings of the inventive concept, a first element / operation in some embodiments may be referred to as a second element / operation in other embodiments.
[0060] The term “exemplary” as used herein means “serving as an example, embodiment, or illustration.” Any embodiment illustrated herein as “exemplary” is not necessarily to be construed as superior to or better than other embodiments.
[0061] Furthermore, to better illustrate this disclosure, numerous specific details are set forth in the following detailed description. Those skilled in the art will understand that this disclosure can be practiced without certain specific details. In some instances, methods, means, components, and circuits well known to those skilled in the art have not been described in detail in order to highlight the main points of this disclosure.
[0062] Water environment monitoring data carries information on the health status of aquatic ecosystems and possesses a series of distinct and complex characteristics. These data are not isolated but multi-dimensional, encompassing various types of indicators from physical, chemical, and biological perspectives, all interconnected and influencing each other. Simultaneously, the data exhibits strong spatiotemporal correlations, forming a network of multiple monitoring points spatially and displaying a sequence with periodic patterns and continuous trends temporally. Furthermore, with the widespread adoption of automated monitoring technologies, data streams are characterized by high frequency and massive volume, posing a direct challenge to data processing capabilities. Moreover, due to interference from equipment, the environment, and sudden water pollution events, the data often contains noise and uncertainty, and the overall data background exhibits dynamic and non-stationary changes in response to natural evolution and human activities.
[0063] To address the complex characteristics of the aforementioned data, we designed a model training method highly adapted to it. This method can deeply mine the hidden spatiotemporal patterns and anomalies within massive datasets, ultimately training an anomaly early warning model specifically for the water environment field. The core value of this model lies in its ability to effectively address the pain points of traditional early warning methods when faced with large-scale, multi-dimensional input data, such as high computational load, low prediction efficiency, and high early warning delays. Through a deep understanding and modeling of the inherent characteristics of the data, this model can achieve faster and more accurate insight and early warning of abnormal water environment conditions, thereby significantly improving the initiative and timeliness of water environment risk prevention and control.
[0064] Figure 1 A flowchart illustrating an early warning method for water environment anomalies according to an embodiment of this disclosure is provided. This embodiment describes the method using an electronic device with processing capabilities, such as a user terminal or server, as an example. The user terminal includes, but is not limited to, computers, laptops, tablets, mobile phones, wearable devices, etc. This embodiment does not limit the implementation method of the electronic device. Figure 1 As shown, the method includes:
[0065] Step 101: Extract multiple candidate time series features from monitoring parameter time series samples that include at least water quality parameter time series samples.
[0066] The monitoring parameter time series sample is a time series obtained by monitoring the sample water environment, which is the historical water environment of the target water environment to be monitored.
[0067] The monitoring parameter time series samples include at least one type, and include at least one water quality parameter time series sample, wherein the water quality parameter time series sample includes at least one type, and the water quality parameter is a water quality indicator.
[0068] Optionally, the water quality parameters in the time series samples of at least one water quality parameter include, but are not limited to, at least one of the following: chemical oxygen demand, conductivity, ammonia nitrogen, five-day biochemical oxygen demand, total phosphorus, total nitrogen, suspended solids, total dissolved solids, petroleum hydrocarbons, pH, anionic surfactants, cyanide, sulfide, fluoride, chloride, organophosphorus compounds, sulfate, mercury, chromium, cadmium, arsenic, lead, nickel, beryllium, silver, selenium, copper, zinc, manganese, iron, volatile phenols, benzene series compounds, aniline compounds, nitrobenzene, etc.
[0069] Optionally, the number of time series samples for each water quality parameter can be one or more sets. For example, there are 6 sets of time series samples for water quality parameters corresponding to chemical oxygen demand and 10 sets of time series samples for water quality parameters corresponding to conductivity. This embodiment does not limit the type of water quality parameter time series samples or the number of time series samples for each type of water quality parameter.
[0070] refer to Figure 2 The four water quality parameters shown are time series samples, including: pH time series, which represents the change of pH value of the sample water environment over time; Dissolved Oxygen (DO) time series, which represents the change of dissolved oxygen in the sample water environment over time; Chemical Oxygen Demand (COD) time series, which represents the change of COD in the sample water environment over time; and Electrical Conductivity (EC) time series, which represents the change of electrical conductivity in the sample water environment over time.
[0071] Optionally, in addition to water quality parameter time series samples, the monitoring parameter time series samples may also include other types of time series samples, such as flow rate parameter time series samples and / or rainfall parameter time series samples. The flow rate parameter time series samples are used to represent the change of water flow rate in the sample water environment over time, and the rainfall parameter time series samples are used to represent the change of rainfall in the sample water environment over time. This embodiment does not limit the type of monitoring parameter time series samples.
[0072] For example, candidate time-series features include features that can indicate the trend, volatility, periodicity, complexity, and / or time-frequency characteristics of time-series samples for each monitoring parameter. Candidate time-series features include at least two types, with different types of monitoring parameter time-series samples sharing the same type of candidate time-series features.
[0073] For example, the time series samples of monitoring parameters include various types, and the candidate time series characteristics of different monitoring parameter time series samples are the same and include: basic statistical characteristics, trend characteristics, time series characteristics and frequency characteristics.
[0074] The basic statistical characteristics include: the mean, standard deviation, minimum, and maximum values of the data within each sliding window of the time series sample for each monitoring parameter.
[0075] The changing trend characteristics include: the difference value, percentage change, growth rate, and acceleration of the data within each sliding window in the time series sample of each monitoring parameter.
[0076] In one example, the difference is calculated as follows: First, determine the change in the last data point of each sliding window relative to the first data point; that is, subtract the difference between the last and first data points to obtain the difference. Second, perform a linear fit on each data point within the sliding window to obtain the slope of the fitted line; then subtract one from the total number of data points within the sliding window and multiply this slope to obtain the difference. That is, d = s (w - 1), where s represents the sum of w data points (t1, x1), (t2, x2), ..., (t...) within the sliding window. w , x w The slope of a straight line obtained by linear regression fitting using the least squares method represents the change in the monitored parameter per unit time, and w represents the total amount of data within the sliding window. By using the differences between all the data within the sliding window, the changing trend of the monitored parameter can be reflected more accurately, thus improving the accuracy of anomaly monitoring.
[0077] In one example, the percentage change can be calculated using the following formula:
[0078] Percentage change = [(Last data in the sliding window - First data in the sliding window) / First data in the sliding window] 100%.
[0079] In one example, the growth rate (or rate of change, growth speed) is calculated as follows: For each sliding window, determine the rate of change of the last data point relative to the first data point to indicate the speed at which the data is rising or falling. That is, the growth rate can be expressed as: Growth rate ≈ (Last data point in the sliding window - First data point in the sliding window) / (Number of time intervals within the sliding window) (Duration of each time interval).
[0080] In one example, acceleration is the rate of change of the growth rate between two adjacent sliding windows. This indicates whether the trend of pollution worsening or easing is accelerating or decelerating. Acceleration can be expressed as: Acceleration ≈ (Current sliding window growth rate - Previous sliding window growth rate) / Sliding window duration.
[0081] The time-series characteristics include the skewness and kurtosis of the data within each sliding window of the time-series sample for each monitoring parameter. Skewness and kurtosis indicate the distribution shape characteristics of the data within the window; skewness represents the symmetry of the data, and kurtosis represents the degree of centralization. Exemplarily, the calculation methods for skewness include, but are not limited to, overall skewness calculation methods, unbiased estimation methods, and moment estimation methods; the calculation methods for kurtosis include, but are not limited to, overall kurtosis calculation methods, unbiased estimation methods, and moment estimation methods. This embodiment does not limit the calculation methods for skewness and kurtosis.
[0082] Frequency domain features include: performing a fast Fourier transform on the water quality data using a sliding window to obtain the spectrum; and extracting the main frequency components and spectral energy from the spectrum.
[0083] For example, different types of candidate time-series features use the same sliding window during extraction, and the step size of each slide is smaller than the window length to ensure data overlap between adjacent sliding windows. This avoids the loss of key signals; that is, it prevents data indicating contamination from being segmented by non-overlapping sliding windows, which would smooth out the contamination data within a single non-overlapping sliding window, thus maximizing the accuracy of the warning. Furthermore, since overlapping sliding windows are evaluated more frequently, the real-time performance of the warning can be improved, and latency reduced.
[0084] As can be seen from the above extraction process, since each monitoring parameter time series sample includes at least two candidate time series features, and there are multiple types of monitoring parameter time series samples, the feature values of the candidate time series features corresponding to each monitoring parameter time series sample can form a two-dimensional matrix. When each candidate time series feature of each monitoring parameter time series sample is extracted by dividing it into multiple sliding windows, each matrix element in the two-dimensional matrix is a feature value sequence, which includes the feature values corresponding to each sliding window. For example, as shown in Table 1 below, the feature values in the i-th row of the two-dimensional matrix include the feature sequences of various candidate time series features corresponding to the i-th monitoring parameter time series sample, and each feature sequence includes at least one feature value; the feature values in the j-th column of the two-dimensional matrix include the feature sequences of the j-th candidate time series features corresponding to various monitoring parameter time series samples, and each feature sequence includes at least one feature value. i and j are both positive integers.
[0085] Table 1:
[0086]
[0087] Step 102: Determine the joint screening score for each candidate time series feature based on its contribution, information content, first dynamic weight of contribution, and second dynamic weight of information content to the anomaly prediction results of the anomaly prediction model to be trained in the kth round. The first dynamic weight and the second dynamic weight are determined based on the first feature set obtained by using contribution screening and the first model performance parameter obtained by the anomaly prediction model to be trained in the kth round, and the second model performance parameter obtained by using the second feature set obtained by using information screening and the anomaly prediction model to be trained in the kth round.
[0088] Where k is a positive integer that takes values sequentially starting from 1.
[0089] The anomaly prediction model to be trained in the k-th round refers to the anomaly prediction model trained in the (k-1)-th round. When k=1, the model parameters of the anomaly prediction model to be trained are preset values. Optionally, the anomaly prediction model to be trained can be an interpretable machine learning model, such as a random forest model or an optimized gradient boosting tree (XGBoost) model. This embodiment does not limit the specific implementation of the anomaly prediction model to be trained.
[0090] For example, each candidate time series feature in step 102 includes each candidate time series feature in the union of the first feature set and the second feature set.
[0091] Before step 102, it is necessary to obtain in advance the contribution, information content, first dynamic weight of contribution, and second dynamic weight of information content of each candidate temporal feature to the anomaly prediction result of the anomaly prediction model to be trained in the kth round.
[0092] The contribution score measures the magnitude of each candidate temporal feature's contribution to the prediction result. For example, the contribution score can be a Shapley Additive exPlanations (SHAP) value. The core idea behind obtaining the contribution score is to treat the model's prediction as the result of all features working together, then calculate the marginal contribution of each feature under different feature subsets, and finally perform a weighted average based on the contribution score method.
[0093] For example, the contribution of each candidate time-series feature can be expressed by the following formula:
[0094] ;
[0095] in, Let F represent the contribution of the i-th candidate time-series feature; F represents the set of all candidate time-series features; and S represents the subset of candidate time-series features in F that does not include the i-th candidate time-series feature. M represents the size of set F, i.e., the total number of candidate time-series features; |S| represents the size of set S; f(S) represents the prediction result (i.e., the anomaly probability) obtained by inputting the feature values of candidate time-series features in subset S into the anomaly prediction model; f(S∪{i}) represents the prediction result obtained by inputting the feature value of subset S plus the i-th candidate time-series feature into the anomaly prediction model. i is a positive integer.
[0096] Information content measures how much information each candidate temporal feature can provide for the prediction result. For example, information content can be the Information Gain Ratio (IG). A higher IG value indicates a more important candidate temporal feature for classification (e.g., distinguishing between contaminated and normal features). For example, each candidate temporal feature corresponds to at least one feature value (e.g., a feature value in a column of features in the two-dimensional matrix above). Each feature value has a pre-set label indicating contaminated or normal. During one round of training of the anomaly prediction model to be trained in the k-th round, each feature value is input into the model, and the resulting prediction is the anomaly probability. If the anomaly probability is greater than a preset probability threshold (e.g., 0.5), the classification result indicated by the prediction is anomaly; if the anomaly probability is less than or equal to the probability threshold, the classification result indicated by the prediction is normal. Based on the difference between the classification result indicated by the prediction of the feature value and the label corresponding to that feature value, the model parameters are iteratively updated.
[0097] Accordingly, the amount of information obtained for each candidate temporal feature can be expressed by the following formula:
[0098] IG j =[H(y)-H(y|x j )]] / H(x j );
[0099] H(y)=- [p0·log2(p0)+ p1·log2(p1)];
[0100] ;
[0101] H(y|x j = v)= - [p(y=0| x j = v)·log2p(y=0| x j = v)+ p(y=1| x j = v)·log2 p(y=1| x j = v)];
[0102] ;
[0103] Among them, IG j Let H(y) represent the information content of the j-th candidate time series feature; H(y) represent the entropy (i.e., uncertainty) of the label y corresponding to all candidate time series features; p0 represents the proportion of candidate time series features with normal labels, and p1 represents the proportion of candidate time series features with abnormal labels; H(y|x j Let be the conditional entropy, and let x be the eigenvalue of the i-th candidate temporal feature. j Given the uncertainty of the remaining label y; Values(x j p(x) represents all possible feature values of the j-th candidate time series feature. j =v) represents the probability that the feature value of the j-th candidate time series feature is v, where v is the value of Values(x) j Any eigenvalue in H(y|x) j =v) represents x j The information entropy at time v, p(y=0|x) j = v) represents x in the j-th candidate time series feature j = various feature values of v, labels indicating the number of normal feature values and the ratio to the total number of such feature values; p(y=1|x j = v) represents x in the j-th candidate time series feature j = various characteristic values of v, the label indicates the number of contaminated characteristic values and the ratio of that characteristic value to the total number of such characteristic values; H(x j ) represents the eigenvalue x of the j-th candidate temporal feature. j Information entropy.
[0104] Obtaining the first dynamic weight of contribution and the second dynamic weight of information content involves the following steps:
[0105] Step 1: Based on the contribution of each candidate time series feature, perform feature filtering on multiple candidate time series features to obtain the first feature set.
[0106] Optionally, the contribution of various candidate time series features is sorted from largest to smallest, and the first x candidate time series features are selected to obtain the first feature set; or, candidate time series features with a contribution greater than the contribution threshold are selected to obtain the first feature set.
[0107] Step 2: Based on the information content of each candidate time series feature, perform feature filtering on multiple candidate time series features to obtain a second feature set.
[0108] Optionally, step 2 can be performed after step 1 or before step 1. This embodiment does not limit the execution order between steps 1 and 2.
[0109] Optionally, the information content of various candidate time series features is sorted from largest to smallest, and the top z candidate time series features are selected to obtain the second feature set; or, candidate time series features with information content greater than the information content threshold are selected to obtain the second feature set.
[0110] Step 3: Based on the feature values of each candidate time-series feature in the first feature set and the label corresponding to each feature value, train and validate the anomaly prediction model to be trained in the kth round to obtain the first model performance parameters of the model obtained in the kth round of training.
[0111] Step 4: Based on the feature values of each candidate time-series feature in the second feature set and the label corresponding to each feature value, train and validate the anomaly prediction model to be trained in the kth round to obtain the second model performance parameters of the model obtained in the kth round of training.
[0112] The model parameters obtained in the kth round of training in step 4 may be different from those obtained in the kth round of training in step 3.
[0113] The performance parameters of the anomaly prediction model to be trained in the kth round (including the first and second performance parameters mentioned above) can be the F1 score obtained after the anomaly prediction model to be trained in the kth round is validated on the validation set, that is, the harmonic mean of precision and recall; or they can be other parameters that can reflect the performance of the anomaly prediction model. This embodiment does not limit the implementation of the performance parameters.
[0114] Step 5: Update the first dynamic weight and the second dynamic weight corresponding to the anomaly prediction model to be trained in the (k-1)th round based on the first model performance parameters and the second model performance parameters, to obtain the first dynamic weight and the second dynamic weight corresponding to the anomaly prediction model to be trained in the kth round.
[0115] When k=1, the first dynamic weight and the second dynamic weight are initialized to preset values.
[0116] For example, updating the first dynamic weight and the second dynamic weight corresponding to the anomaly prediction model to be trained in the (k-1)th round based on the first model performance parameters and the second model performance parameters to obtain the first dynamic weight and the second dynamic weight corresponding to the anomaly prediction model to be trained in the kth round includes: updating the first dynamic weight based on the first model performance parameters and the second model performance parameters; and subtracting the first dynamic weight from 1 to obtain the second dynamic weight.
[0117] Correspondingly, the first dynamic weight α of the anomaly prediction model to be trained in the kth round new Second dynamic weight β new It can be obtained by updating the following formula:
[0118] α new =α+η×(X SHAP -X IG );
[0119] β new =1-α new .
[0120] Where α represents the first dynamic weight corresponding to the anomaly prediction model to be trained in the (k-1)th round; η represents the learning rate of the model training, which is a fixed value (e.g., η=0.05); X SHAP X represents the first performance parameter. IG This indicates the second performance parameter.
[0121] In actual implementation, the first dynamic weight and the second dynamic weight can be determined in other ways, such as updating the second dynamic weight based on the first model performance parameters and the second model performance parameters, and subtracting the second dynamic weight from 1 to obtain the first dynamic weight. The above update formula can also be other formulas constructed based on the first performance parameters and the second performance parameters. This embodiment does not limit this.
[0122] For example, determining a joint screening score for each candidate time-series feature includes:
[0123] Determine the union of the first feature set and the second feature set; normalize the contribution and information content of each candidate time series feature in the union to obtain the normalized contribution and information content of each candidate time series feature; for each candidate time series feature in the union, determine the joint screening score of the candidate time series feature based on the first dynamic weight, the normalized contribution of the candidate time series feature, the second dynamic weight, and the normalized information content of the candidate time series feature.
[0124] Selecting column features only from the first or second feature set may lead to the loss of important temporal features. In this embodiment, temporal features are selected from the union of the first and second feature sets, which ensures that too many irrelevant features are not introduced and avoids the loss of important temporal features.
[0125] The normalization process for contribution and information content is the same to ensure their comparability. The normalization of the contribution of each candidate time-series feature in the union set can be expressed by the following formula:
[0126] SHAP norm, i=SHAP i / max k∈AllFeatures (SHAP k );
[0127] Among them, SHAP norm, i represents the normalized contribution of the i-th candidate time series feature; SHAP i The max represents the contribution of the i-th candidate time-series feature; k∈AllFeatures (SHAP k ) represents the maximum contribution of all candidate time series features.
[0128] Accordingly, the normalization of the information content of each candidate temporal feature in the union set can be expressed by the following formula:
[0129] IG norm, i=IG i / max k∈AllFeatures (IG k );
[0130] Among them, IG norm, i represents the normalized IG value of the i-th candidate temporal feature; IG i The IG value represents the i-th candidate temporal feature; max k∈AllFeatures (IG k ) represents the maximum value of the IG value of all candidate time series features.
[0131] In other implementations, the normalization method can also be other methods, such as normalization based on the maximum and minimum values, etc. This embodiment does not limit the normalization method.
[0132] For example, the joint screening score of the candidate time-series features is determined based on the first dynamic weight, the normalized contribution of the candidate time-series features, the second dynamic weight, and the normalized information content of the candidate time-series features, including:
[0133] The joint screening score is obtained by summing the product of the first dynamic weight and the normalized contribution, plus the product of the second dynamic weight and the normalized information content.
[0134] Accordingly, the joint screening score can be expressed by the following formula:
[0135] Jj=α×SHAP norm, j+β×IG norm, j;
[0136] Where Jj represents the joint screening score of the j-th candidate temporal feature; α represents the first dynamic weight, SHAP norm, j represents the normalized contribution of the j-th candidate time-series feature; β represents the second dynamic weight, IG norm, j represents the normalized IG value of the j-th candidate temporal feature.
[0137] Step 103: Based on the current target time series features selected from multiple candidate time series features using joint screening scores, train the anomaly prediction model to be trained in the kth round for one round; until the anomaly prediction model to be trained meets the iteration stopping condition, and the trained anomaly prediction model is obtained.
[0138] Before step 103, the method further includes: using joint screening scores to screen the current target time series feature from multiple candidate time series features.
[0139] Optionally, the current target time-series feature selected from multiple candidate time-series features using a joint screening score includes:
[0140] Feature filtering is performed on multiple candidate time series features based on joint screening scores to obtain screening results; it is determined whether the candidate time series features in the screening results meet the similarity condition; if at least two candidate time series features meet the similarity condition, at least one candidate time series feature is selected as the current target time series feature from the at least two candidate time series features that meet the similarity condition.
[0141] For example, determining whether the candidate time-series features in the screening results meet the similarity criteria includes:
[0142] Determine the cross-entropy and / or correlation coefficient between different candidate time-series features in the screening results; if the cross-entropy and / or correlation coefficient between different candidate time-series features are greater than a preset threshold, determine that the different candidate time-series features meet the similarity condition. The higher the cross-entropy and / or correlation coefficient, the more similar the different candidate time-series features are.
[0143] The cross-entropy between different candidate temporal features can be expressed by the following formula:
[0144] ;
[0145] Among them, E jk Let x represent the cross-entropy matrix between the j-th candidate temporal feature and the k-th candidate temporal feature. j Let x represent the various possible feature values of the j-th candidate time series feature. k P(x) represents the various possible feature values of the k-th candidate time series feature. j x k () represents the feature value of the j-th candidate time series feature as x. j And the feature value of the k-th candidate time series feature is x. k The probability, P(x) j () represents the feature value of the j-th candidate time series feature as x. j The probability of P(x) k The eigenvalue of the k-th candidate temporal feature is x. k The probability of.
[0146] The correlation coefficient between different candidate time series features can be calculated using the Pearson correlation coefficient. This embodiment does not limit the calculation method of the correlation coefficient.
[0147] In other embodiments, it is also possible to simultaneously calculate whether at least three candidate time-series features meet the similarity condition. This embodiment does not limit the method for determining whether each candidate time-series feature meets the similarity condition. Alternatively, the candidate time-series features in the screening results can be directly used as the current target time-series feature. This embodiment does not limit the method for determining the current target time-series feature based on the screening results.
[0148] For example, feature filtering of multiple candidate time series features based on joint screening scores includes: sorting the joint screening scores of each candidate time series feature in the union set from largest to smallest, selecting the first s candidate time series features in the sorting set, and obtaining the filtering results; or, selecting candidate time series features whose joint screening scores are greater than the exponential threshold, and obtaining the filtering results.
[0149] For example: the ranking result obtained by sorting the joint screening scores of candidate time-series features in the union set from largest to smallest is as follows: Figure 3As shown, the top 10 candidate time-series features 1 to 10 are selected to obtain the screening results.
[0150] After obtaining the target time series features, the anomaly prediction model to be trained in the kth round is trained based on the current target time series features. This includes: inputting the feature value matrix corresponding to the current target time series features into the anomaly prediction model to be trained in the kth round, and training the anomaly prediction model to be trained in the kth round by combining the label corresponding to each feature value in the feature value matrix, so as to obtain the anomaly prediction model after the kth round of training. The anomaly prediction model after the kth round of training is used as the anomaly prediction model to be trained in the (k+1)th round, until the anomaly prediction model to be trained meets the iteration stopping condition, and the trained anomaly prediction model is obtained.
[0151] Optionally, the iteration stopping conditions include, but are not limited to: the value of k reaches a preset value, or the model performance of the anomaly prediction model after the kth round of training reaches the expected performance, etc. This embodiment does not limit the implementation method of the iteration stopping conditions.
[0152] To better understand the selection process of the current target temporal features, the following example illustrates the selection process starting from the first round of training.
[0153] After determining the contribution and information content of each candidate time series feature among multiple candidate time series features, and determining the first feature set based on the contribution and the second feature set based on the information content,
[0154] Starting from the first round of training, k=1, the first dynamic weight is initialized to a preset value, such as α=0.6, and correspondingly β=1-α=0.4. At this point, based on the feature values of each candidate temporal feature in the first feature set and the label corresponding to each feature value, the anomaly prediction model to be trained in the first round is trained and validated, obtaining the first performance parameters of the model obtained in the first round of training. Based on the feature values of each candidate temporal feature in the second feature set and the label corresponding to each feature value, the anomaly prediction model to be trained in the first round is trained and validated, obtaining the second performance parameters of the model obtained in the first round of training. Based on the first and second performance parameters, the initialized first dynamic weight α is updated to obtain the first dynamic weight used in the first round of training. Based on this first dynamic weight, the second dynamic weight used in the first round of training is determined. Then, based on the first and second dynamic weights used in the first round of training, the joint selection score used in the first round of training can be determined, and based on the joint selection score used in the first round of training, the current target temporal feature used in the first round of training can be selected. Based on the feature values and labels of the current target time series features, the anomaly prediction model to be trained in the first round is trained once to obtain the anomaly prediction model to be trained in the second round.
[0155] For the second round of training, based on the feature values of each candidate temporal feature in the first feature set and the corresponding label, the anomaly prediction model to be trained in the second round is trained and validated, obtaining the first performance parameters of the model obtained in the second round of training. Based on the feature values of each candidate temporal feature in the second feature set and the corresponding label, the anomaly prediction model to be trained in the second round is trained and validated, obtaining the second performance parameters of the model obtained in the second round of training. Based on the first and second performance parameters, the initialized first dynamic weight α is updated to obtain the first dynamic weight used in the second round of training. Based on this first dynamic weight, the second dynamic weight used in the second round of training is determined. Then, based on the first and second dynamic weights used in the second round of training, the joint screening score used in the second round of training can be determined. Based on the joint screening score used in the second round of training, the current target temporal feature used in the second round of training can be selected. Based on the feature values and labels of the current target temporal feature, the anomaly prediction model to be trained in the second round is trained for one round, obtaining the anomaly prediction model to be trained in the third round…
[0156] The process is repeated until the anomaly prediction model after the kth round of training reaches the iteration stopping condition, at which point the training stops. At this point, the trained anomaly prediction model is obtained, and the current target time-series feature used in the last round of training is taken as the final target time-series feature of the trained anomaly prediction model.
[0157] Step 104: Provide early warning of anomalies in the target water environment based on the trained anomaly prediction model.
[0158] In one example, an early warning of anomalies in the target aquatic environment is issued based on a trained anomaly prediction model, including:
[0159] Extract the final target time series features used by the trained anomaly prediction model from the time series of monitoring parameters of the target water environment at the monitoring point; input the feature value matrix of the final target time series features into the trained anomaly prediction model to obtain the anomaly probability of the target water environment; determine the dynamic threshold for early warning of the target water environment based on the current state of the target water environment; and issue an early warning for the target water environment when the anomaly probability is greater than the dynamic threshold.
[0160] Traditional anomaly warning methods mainly rely on fixed threshold methods. For example, an alarm is triggered if the water quality parameters collected by the sensor are greater than the water quality parameter threshold.
[0161] However, fixed thresholds cannot adapt to changes in the state of the water environment being monitored. Using fixed thresholds in such cases may lead to false alarms and missed alarms. For example, factors such as rainfall and seasonal fluctuations affect the dynamic load of the municipal drainage network; fixed thresholds can result in high false alarm rates during heavy rains and high missed alarm rates during droughts. In this embodiment, a dynamic threshold is determined based on the current state of the target water environment for early warning. This allows for adjustment of the threshold according to the actual conditions of the target water environment, ensuring the accuracy of the early warning.
[0162] The monitoring parameter time series includes at least water quality parameter time series. The types of monitoring parameter time series are the same as the types of monitoring parameter time series samples, and a detailed description can be found in step 101 above, which will not be repeated here in this embodiment.
[0163] Optionally, at least one monitoring parameter time series is raw data collected by sensors in the target aquatic environment, or is obtained after data cleaning and / or standardization of the raw data.
[0164] Data cleaning includes, but is not limited to: outlier removal, outlier correction, and / or missing value filling. This embodiment does not limit the method of data cleaning.
[0165] Standardization is used to eliminate the dimensional influence between time series of different types of monitoring parameters. Standardization methods include, but are not limited to, min-max scaling and standard deviation standardization. This embodiment does not limit the standardization method.
[0166] The final target time series feature refers to the current target time series feature used by the trained anomaly prediction model during its final round of training.
[0167] For details on the extraction method of the final target temporal features, please refer to the above content on the candidate target temporal features. This embodiment will not repeat it here.
[0168] In one example, based on the current state of the target water environment, a dynamic threshold for early warning of the target water environment is determined, including:
[0169] Obtain the sensitivity enhancement coefficient and sensitivity inhibition coefficient of the target water environment; determine the dynamic threshold based on the sensitivity enhancement coefficient, sensitivity inhibition coefficient and preset baseline threshold.
[0170] The preset baseline threshold is a fixed value pre-stored in the electronic device, used to initially determine whether there is a possibility of anomalies in the target water environment.
[0171] The sensitivity enhancement coefficient is used to increase the sensitivity of electronic devices to anomalies. The sensitivity enhancement coefficient is negatively correlated with the dynamic threshold, that is, the larger the sensitivity enhancement coefficient, the smaller the dynamic threshold.
[0172] In one example, the sensitivity enhancement coefficient and sensitivity inhibition coefficient of the target aquatic environment are obtained, including:
[0173] Based on the first target area to which the target water environment currently belongs, determine the regional sensitivity enhancement coefficient of the target water environment; based on the first time parameter of the target water environment, determine the time sensitivity enhancement coefficient of the target water environment; based on the duration for which the anomaly probability of the target water environment exceeds a preset baseline threshold, determine the pollution duration coefficient of the target water environment; based on the regional sensitivity enhancement coefficient, time sensitivity enhancement coefficient, and pollution duration coefficient, determine the sensitivity enhancement coefficient; based on the second target area to which the target water environment currently belongs, determine the regional sensitivity suppression coefficient of the target water environment; based on the second time parameter of the target water environment, determine the time sensitivity suppression coefficient of the target water environment; based on the hydrological period corresponding to the third time parameter of the target water environment, determine the hydrological sensitivity suppression coefficient of the target water environment; based on the regional sensitivity suppression coefficient, time sensitivity suppression coefficient, and hydrological sensitivity suppression coefficient, determine the sensitivity suppression coefficient.
[0174] For example, the regional sensitivity enhancement coefficient has a pre-configured correspondence with the first target region. For instance, first target region 1 corresponds to regional sensitivity enhancement coefficient 1, and first target region 2 corresponds to regional sensitivity enhancement coefficient 2. In this case, by looking up this correspondence, the corresponding regional sensitivity enhancement coefficient can be determined based on the first target region to which the target water environment currently belongs.
[0175] For example, the first target area includes key monitoring areas and non-key monitoring areas. Key monitoring areas include the first-level key area assessment section area, areas with dense industrial wastewater discharge, and ordinary monitoring areas. The regional sensitivity enhancement coefficient corresponding to the first-level key area assessment section area is 0.9; the regional sensitivity enhancement coefficient corresponding to the areas with dense industrial wastewater discharge is 0.5; and the regional sensitivity enhancement coefficient for ordinary monitoring areas is 0.1 or 0. If the target water environment currently belongs to a key monitoring area, and is a first-level key area assessment section area within the key monitoring area, then the regional sensitivity enhancement coefficient is 0.9.
[0176] Optionally, determining the first target area to which the target water environment currently belongs includes: obtaining first location information of the target water environment; matching the first location information with second location information of each pre-stored first target area; and determining the first target area corresponding to the second location information that matches the first location information as the first target area to which the target water environment currently belongs. Alternatively, obtaining a first area identifier of the target water environment; matching the first area identifier with second area identifiers of each pre-stored first target area; and determining the first target area corresponding to the second area identifier that matches the first area identifier as the first target area to which the target water environment currently belongs. In other embodiments, the method for determining the first target area to which the target water environment currently belongs can also be other methods, and this embodiment does not limit this.
[0177] For example, the time sensitivity enhancement coefficient has a pre-configured correspondence with time periods, such as time period 1 corresponding to time sensitivity enhancement coefficient 1, and time period 2 corresponding to time sensitivity enhancement coefficient 2. In this case, by looking up this correspondence, the corresponding time sensitivity enhancement coefficient can be determined based on the current first time parameter of the target water environment.
[0178] For example, the time periods include: statutory holidays and nighttime (22:00-6:00 the next day), weekend daytime (i.e., non-nighttime), and weekday daytime. The time sensitivity enhancement coefficient is 0.5 for statutory holidays and nighttime, 0.3 for weekend daytime, and 0.2 or 0 for weekday daytime. If the primary time parameter for the target water environment is the weekend daytime, then the time sensitivity enhancement coefficient is 0.3.
[0179] The pollution duration coefficient is positively correlated with the duration during which the probability of an anomaly in the target water environment exceeds a preset baseline threshold. For example, the pollution duration coefficient Wz = a × t, where a is a preset positive number less than 1, and t represents the duration during which the probability of an anomaly in the target water environment exceeds the preset baseline threshold.
[0180] The sensitivity enhancement coefficient is determined based on the regional sensitivity enhancement coefficient, the time sensitivity enhancement coefficient, and the pollution duration coefficient, including:
[0181] The sensitivity enhancement coefficient is obtained by summing the product of the regional sensitivity enhancement coefficient and the time sensitivity enhancement coefficient, plus the pollution duration coefficient. That is, the sensitivity enhancement coefficient can be expressed by the following formula:
[0182] β = Qz × Sz + Wz;
[0183] Where β represents the sensitivity enhancement coefficient, Qz represents the regional sensitivity enhancement coefficient, Sz represents the time sensitivity enhancement coefficient, and Wz represents the pollution duration coefficient.
[0184] It should be noted that in this embodiment, the regional sensitivity enhancement coefficient, the time sensitivity enhancement coefficient, and the pollution duration coefficient are all coefficients determined using the same dimensions, for example, all of which are values in the range [0,1].
[0185] The sensitivity suppression coefficient is used to reduce the sensitivity of electronic devices to anomalies. The sensitivity suppression coefficient is positively correlated with the dynamic threshold, that is, the larger the sensitivity suppression coefficient, the larger the dynamic threshold.
[0186] For example, the regional sensitivity suppression coefficient has a pre-configured correspondence with the second target region. For instance, second target region 1 corresponds to regional sensitivity suppression coefficient 1, and second target region 2 corresponds to regional sensitivity suppression coefficient 2. In this case, by looking up this correspondence, the corresponding regional sensitivity suppression coefficient can be determined based on the second target region to which the target water environment currently belongs.
[0187] For example, the second target area includes key monitoring areas and non-key monitoring areas. Key monitoring areas include the assessment section area of the first-level key area, areas with dense industrial wastewater discharge, and ordinary monitoring areas. The regional sensitivity suppression coefficient corresponding to the assessment section area of the first-level key area is 0; the regional sensitivity suppression coefficient corresponding to the areas with dense industrial wastewater discharge is 0.1; and the regional sensitivity suppression coefficient for ordinary monitoring areas is 0.5. If the target water environment currently belongs to a key monitoring area within the second target area, and is specifically a assessment section area of the first-level key area within the key monitoring area, then the regional sensitivity suppression coefficient is 0.
[0188] For example, for the same time period, the time sensitivity suppression coefficient and the time sensitivity enhancement coefficient are inversely proportional; that is, the larger the time sensitivity suppression coefficient, the smaller the time sensitivity enhancement coefficient. The time sensitivity suppression coefficient and the time period have a pre-configured correspondence, for example: time period 1 corresponds to time sensitivity suppression coefficient 1, and time period 2 corresponds to time sensitivity suppression coefficient 2. In this case, by looking up this correspondence, the corresponding time sensitivity suppression coefficient can be determined based on the current second time parameter of the target water environment. Optionally, the second time parameter can be the same as the first time parameter, for example: a time consisting of hours, minutes, and seconds.
[0189] For example, the time periods include: statutory holidays and nighttime (22:00-6:00 the next day), weekend daytime (i.e., non-nighttime), and weekday daytime. The time sensitivity suppression coefficient is 0 for statutory holidays and nighttime, 0.1 for weekend daytime, and 0.2 for weekday daytime. If the target water environment's current second time parameter is a weekend daytime period, then the time sensitivity suppression coefficient is 0.1.
[0190] For example, there is a pre-configured correspondence between the hydrological period of the target water environment and the hydrological sensitivity suppression coefficient. For instance, hydrological period 1 of the target water environment corresponds to hydrological sensitivity suppression coefficient 1, and hydrological period 2 of the target water environment corresponds to hydrological sensitivity suppression coefficient 2. In this case, by looking up this correspondence, the corresponding hydrological sensitivity suppression coefficient can be determined based on the hydrological period of the target water environment.
[0191] For example, the hydrological period of the target water environment (i.e., the specific time period during which the hydrological characteristics of rivers, lakes, and other water bodies exhibit regular changes due to the periodic changes in their climatic conditions throughout the year) includes: the dry season, the normal season, and the wet season. The hydrological sensitivity inhibition coefficient is 0 for the dry season, 0.1 for the normal season, and 0.2 for the wet season. If the hydrological period of the target water environment is the dry season, then the hydrological sensitivity inhibition coefficient is determined to be 0.
[0192] Taking the determination of the sensitivity suppression coefficient based on regional sensitivity suppression coefficient, time sensitivity suppression coefficient, and hydrological sensitivity suppression coefficient as an example, the determination of the sensitivity suppression coefficient includes:
[0193] The sensitivity suppression coefficient is obtained by multiplying the regional sensitivity suppression coefficient and the time sensitivity suppression coefficient, and then summing the hydrological sensitivity suppression coefficients. That is, the sensitivity suppression coefficient can be expressed by the following formula:
[0194] α = Q × S + W;
[0195] Where α represents the sensitivity suppression coefficient, Q represents the regional sensitivity suppression coefficient, S represents the time sensitivity suppression coefficient, and W represents the hydrological sensitivity suppression coefficient.
[0196] It should be noted that in this embodiment, the regional sensitivity suppression coefficient, the time sensitivity suppression coefficient, and the hydrological sensitivity suppression coefficient are all coefficients determined using the same dimensions, and have the same dimensions as the regional sensitivity enhancement coefficient, the time sensitivity enhancement coefficient, and the pollution duration coefficient, for example, all of which are values in the range of [0,1].
[0197] In one example, a dynamic threshold is determined based on a sensitivity enhancement coefficient, a sensitivity suppression coefficient, and a preset baseline threshold, including: determining a candidate threshold based on the preset baseline threshold, the sensitivity suppression coefficient, and the sensitivity enhancement coefficient; and determining a dynamic threshold based on the candidate threshold, a preset minimum threshold, and a preset maximum threshold, wherein the preset minimum threshold is less than the preset baseline threshold, and the preset maximum threshold is greater than the preset baseline threshold.
[0198] The candidate threshold is determined based on a preset baseline threshold, a sensitivity suppression coefficient, and a sensitivity enhancement coefficient, including: determining the product coefficient of the preset baseline threshold based on the sensitivity suppression coefficient; and determining the difference between the product of the preset baseline threshold and the product coefficient and the sensitivity enhancement coefficient to obtain the candidate threshold.
[0199] For example, the product coefficient of the preset baseline threshold is the sensitivity suppression coefficient + 1, and correspondingly, the candidate threshold can be expressed by the following formula:
[0200] θ = θ 基线 × (1 + α) -β;
[0201] Where θ represents the candidate threshold, θ 基线 α represents the preset baseline threshold, (1 + α) represents the product coefficient, α represents the sensitivity suppression coefficient, and β represents the sensitivity enhancement coefficient.
[0202] Based on the candidate threshold, the preset minimum threshold, and the preset maximum threshold, a dynamic threshold is determined, including: when the candidate threshold is greater than or equal to the minimum threshold and less than or equal to the maximum threshold, the candidate threshold is determined as the dynamic threshold; when the candidate threshold is less than the minimum threshold, the minimum threshold is determined as the dynamic threshold; when the candidate threshold is greater than the maximum threshold, the maximum threshold is determined as the dynamic threshold.
[0203] For example, the dynamic threshold can be expressed by the following formula:
[0204] θ 动态 = max(θ min min(θ) max ,θ));
[0205] Where, θ min θ represents the minimum threshold. max θ represents the maximum threshold, and θ represents the candidate threshold. 动态 This represents a dynamic threshold; min(·) selects the minimum value, and max(·) selects the maximum value. θ min Less than the preset baseline threshold, θ max Greater than the preset baseline threshold. For example: θ 基线 If θ is 0.5, then θ min It can be 0.2 or 0.3, etc., less than θ.基线 The value of θ max It can be 0.8 or 0.9, etc., greater than θ. 基线 The value of θ. In actual implementation, θ 基线 θ min θ max The value can also be other values, and this embodiment does not limit the value.
[0206] Alternatively, in other embodiments, the minimum and maximum thresholds may not be set, and the candidate threshold may be used directly as the dynamic threshold. This embodiment does not limit the calculation method of the dynamic threshold.
[0207] For example, early warning for the target water environment includes: outputting early warning prompts.
[0208] Early warning alerts are used to indicate abnormalities in the target aquatic environment, such as: Figure 2 If the probability of anomalies in the feature values corresponding to the time series of the monitoring parameters in the shaded area is greater than the dynamic threshold, an early warning is output. In this embodiment, the early warning can be a video signal, image signal, text signal, light signal, vibration signal, and / or audio signal, etc. This embodiment does not limit the form of the early warning.
[0209] Optionally, if the probability of an anomaly is less than or equal to the dynamic threshold, no warning message for the target water environment is output, and step 104 is executed again to continue monitoring the target water environment until the electronic equipment stops operating or a stop monitoring command is received, at which point the process ends.
[0210] In summary, the water environment anomaly early warning method provided in this embodiment determines the first dynamic weight and the second dynamic weight by using a first feature set obtained through contribution screening and the first model performance parameters obtained from the anomaly prediction model to be trained in the kth round, and a second feature set obtained through information screening and the second model performance parameters obtained from the anomaly prediction model to be trained in the kth round. Based on the contribution, information content, first dynamic weight, and second dynamic weight of each candidate time-series feature, a joint screening score for each candidate time-series feature is determined. Based on the current target time-series feature selected from multiple candidate time-series features using the joint screening score, the anomaly prediction model to be trained in the kth round is trained in one round. This continues until the anomaly prediction model to be trained meets the iteration stopping condition, resulting in a trained anomaly prediction model. Anomalies in the target water environment are then warned based on the trained anomaly prediction model. The time-series features of each monitoring parameter's time series can be input into the model, and these time-series features are partial time-series features selected from multiple candidate feature sequences. This reduces the amount of data input to the trained anomaly prediction model while ensuring the accuracy of model prediction, avoiding the problems of low efficiency and high latency in traditional anomaly prediction.
[0211] Meanwhile, since the contribution degree can indicate the direction and magnitude of each candidate time series feature's contribution to the prediction result, and the information content can indicate how much each candidate time series feature provides to the prediction result, in this embodiment, by combining the contribution degree and information content of each candidate time series feature to select the target time series feature, the target time series feature that has a significant impact on the model prediction can be identified more comprehensively and reliably, thereby further improving the accuracy of anomaly prediction.
[0212] Furthermore, by determining the sensitivity enhancement coefficient and sensitivity inhibition coefficient of the target water environment based on its current state, and by determining the dynamic threshold for early warning based on the sensitivity enhancement coefficient, sensitivity inhibition coefficient, and a preset baseline threshold, an early warning for the target water environment is output when the probability of an anomaly exceeds the dynamic threshold. This can solve the problem of false alarms and missed alarms that easily occur when using fixed thresholds for early warning. Since the threshold for early warning can be adaptively adjusted by combining the sensitivity enhancement coefficient and sensitivity inhibition coefficient of the target water environment, the accuracy of early warning can be improved.
[0213] Furthermore, when determining the sensitivity enhancement coefficient and sensitivity inhibition coefficient, the environmental attributes, discharge patterns, and pollution accumulation effects of the target water environment are considered. This ensures that the determination process of the dynamic threshold closely aligns with actual water quality changes, guaranteeing the adaptability of the dynamic threshold to the current state of the target water environment in complex and ever-changing monitoring scenarios. In high-risk scenarios (such as nighttime sewage discharge from water sources or continuous exceedances of standards in industrial areas), by integrating sensitivity enhancement factors such as regional sensitivity enhancement coefficient, time sensitivity enhancement coefficient, and pollution duration coefficient, the warning threshold can be dynamically lowered. This enhances the equipment's ability to detect concealed pollution events and prevents missed reports. For example, when illegal nighttime discharge occurs in key areas, the threshold is lowered, allowing even weak pollution signals to trigger warnings, effectively solving the problem of slow response of traditional methods in high-risk scenarios. In low-risk scenarios (such as daytime drainage in ordinary areas and routine monitoring), by appropriately increasing the warning threshold through the regional sensitivity suppression coefficient, time sensitivity suppression coefficient and hydrological sensitivity suppression coefficient, false alarm signals caused by hydrological fluctuations, equipment noise and other factors can be filtered out, preventing false alarm problems. This reduces the false alarm rate of equipment in non-sensitive areas and alleviates the burden of handling ineffective warnings for regulatory personnel.
[0214] In addition, by setting a maximum threshold to limit the upper limit of the dynamic threshold, false negatives can be prevented. Combined with a minimum threshold to limit the lower limit of the dynamic threshold, basic sensitivity can be guaranteed, thereby ensuring reliable operation even in extreme scenarios.
[0215] Figure 4 A block diagram of an early warning device for water environment anomalies according to an embodiment of the present disclosure is shown. Figure 4As shown, the device includes: a feature extraction module 410, a score determination module 420, a feature filtering module 430, and an anomaly warning module 440.
[0216] Feature extraction module 410 is used to extract multiple candidate time series features from monitoring parameter time series samples that include at least water quality parameter time series samples;
[0217] The score determination module 420 is used to determine the joint screening score of each candidate time series feature based on the contribution, information content, first dynamic weight of the contribution, and second dynamic weight of the information content provided by each candidate time series feature to the anomaly prediction result of the anomaly prediction model to be trained in the kth round; the first dynamic weight and the second dynamic weight are determined based on the first feature set obtained by screening using the contribution and the first model performance parameter obtained by the anomaly prediction model to be trained in the kth round, and the second model performance parameter obtained by screening the second feature set obtained by screening using the information content and the anomaly prediction model to be trained in the kth round.
[0218] The feature selection module 430 is used to train the anomaly prediction model to be trained in the kth round based on the current target time series features selected from the multiple candidate time series features using the joint selection score; until the anomaly prediction model to be trained meets the iteration stopping condition, the trained anomaly prediction model is obtained.
[0219] The anomaly warning module 440 is used to provide early warning of anomalies in the target water environment based on the trained anomaly prediction model.
[0220] Optionally, the device further includes:
[0221] The set determination module is used to perform feature filtering on the multiple candidate time series features based on the contribution of each candidate time series feature before determining the joint screening score of each candidate time series feature, to obtain the first feature set; and to perform feature filtering on the multiple candidate time series features based on the information content of each candidate time series feature, to obtain the second feature set.
[0222] The performance determination module is used to train and validate the anomaly prediction model to be trained in the kth round based on the feature values of each candidate temporal feature in the first feature set and the label corresponding to each feature value, to obtain the first model performance parameters of the model obtained in the kth round of training; and to train and validate the anomaly prediction model to be trained in the kth round based on the feature values of each candidate temporal feature in the second feature set and the label corresponding to each feature value, to obtain the second model performance parameters of the model obtained in the kth round of training; k is a positive integer;
[0223] The dynamic update module is used to update the first dynamic weight and the second dynamic weight corresponding to the anomaly prediction model to be trained in the (k-1)th round based on the first model performance parameters and the second model performance parameters, so as to obtain the first dynamic weight and the second dynamic weight corresponding to the anomaly prediction model to be trained in the kth round. When k=1, the first dynamic weight and the second dynamic weight are initialized to preset values.
[0224] Optionally, the score determination module 420 is used for:
[0225] Determine the union of the first feature set and the second feature set;
[0226] The contribution and information content of each candidate time series feature in the union set are normalized to obtain the normalized contribution and information content of each candidate time series feature.
[0227] For each candidate time-series feature in the union set, the joint screening score of the candidate time-series feature is determined based on the first dynamic weight, the normalized contribution of the candidate time-series feature, the second dynamic weight, and the normalized information content of the candidate time-series feature.
[0228] Optionally, the feature filtering module 430 is used for:
[0229] Based on the joint screening score, feature screening is performed on the multiple candidate time-series features to obtain the screening results;
[0230] Determine whether the candidate time-series features in the screening results meet the similarity condition;
[0231] If the similarity condition is satisfied between at least two candidate time series features, at least one candidate time series feature is selected as the current target time series feature from the at least two candidate time series features that satisfy the similarity condition.
[0232] Optionally, the feature filtering module 430 is specifically used for:
[0233] Determine the cross-entropy and / or correlation coefficient between different candidate time-series features in the screening results; wherein, the higher the cross-entropy and / or correlation coefficient, the more similar the different candidate time-series features are.
[0234] If the cross-entropy and / or correlation coefficient between the different candidate time series features are greater than a preset threshold, it is determined that the different candidate time series features meet the similarity condition.
[0235] Optionally, the anomaly warning module 440 is used for:
[0236] Extract the final target time series features used by the trained anomaly prediction model from the time series of monitoring parameters of the target water environment at the monitoring point; wherein, the time series of monitoring parameters includes at least the time series of water quality parameters;
[0237] The feature value matrix of the final target time series features is input into the trained anomaly prediction model to obtain the anomaly probability of the target water environment;
[0238] Based on the current state of the target water environment, determine the dynamic threshold for early warning of the target water environment;
[0239] When the probability of an anomaly is greater than the dynamic threshold, an early warning is issued for the target water environment.
[0240] Optionally, the anomaly warning module 440 is specifically used for:
[0241] The sensitivity enhancement coefficient and sensitivity inhibition coefficient of the target water environment are obtained;
[0242] The dynamic threshold is determined based on the sensitivity enhancement coefficient, the sensitivity suppression coefficient, and the preset baseline threshold.
[0243] Optionally, the anomaly warning module 440 is specifically used for:
[0244] Based on the first target area to which the target water environment currently belongs, determine the regional sensitivity enhancement coefficient of the target water environment;
[0245] Based on the current first-time parameters of the target water environment, determine the time sensitivity enhancement coefficient of the target water environment;
[0246] The pollution duration coefficient of the target water environment is determined based on the duration during which the probability of an anomaly in the target water environment is greater than the preset baseline threshold.
[0247] The sensitivity enhancement coefficient is determined based on the regional sensitivity enhancement coefficient, the time sensitivity enhancement coefficient, and the pollution duration coefficient.
[0248] Based on the second target region to which the target water environment currently belongs, determine the regional sensitivity suppression coefficient of the target water environment;
[0249] Based on the current second time parameter of the target water environment, determine the time sensitivity suppression coefficient of the target water environment;
[0250] Based on the hydrological period corresponding to the current third time parameter of the target water environment, the hydrological sensitivity suppression coefficient of the target water environment is determined.
[0251] The sensitivity suppression coefficient is determined based on the regional sensitivity suppression coefficient, the time sensitivity suppression coefficient, and the hydrological sensitivity suppression coefficient.
[0252] Optionally, the anomaly warning module 440 is specifically used for:
[0253] Candidate thresholds are determined based on the preset baseline threshold, the sensitivity suppression coefficient, and the sensitivity enhancement coefficient;
[0254] The dynamic threshold is determined based on the candidate threshold, the preset minimum threshold, and the preset maximum threshold, wherein the preset minimum threshold is less than the preset baseline threshold, and the preset maximum threshold is greater than the preset baseline threshold.
[0255] For details, please refer to the above method implementation examples.
[0256] In some embodiments, the functions or modules of the apparatus provided in this disclosure can be used to perform the methods described in the above method embodiments. The specific implementation can be referred to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.
[0257] This disclosure also provides an early warning device for water environment anomalies, including a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the above method.
[0258] This disclosure also provides a non-volatile computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the above-described method.
[0259] This disclosure also provides a computer program product, including a computer program or a non-volatile computer-readable storage medium carrying the computer program, wherein the computer program, when executed by a processor, implements the steps of the above method.
[0260] Figure 5 This is a block diagram illustrating an early warning device 1900 for water environment anomalies according to an exemplary embodiment. For example, device 1900 can be provided as a server or terminal device. (Refer to...) Figure 5 The apparatus 1900 includes a processing component 1922, which further includes one or more processors, and memory resources represented by memory 1932 for storing instructions, such as application programs, that can be executed by the processing component 1922. The application programs stored in memory 1932 may include one or more modules, each corresponding to a set of instructions. Furthermore, the processing component 1922 is configured to execute instructions to perform the methods described above.
[0261] Device 1900 may also include a power supply component 1926 configured to perform power management of device 1900, a wired or wireless network interface 1950 configured to connect device 1900 to a network, and an input / output interface 1958 (I / O interface). Device 1900 can operate on an operating system, such as Windows Server, stored in memory 1932. TM macOS X TM Unix TM Linux TM FreeBSD TM Or similar.
[0262] In an exemplary embodiment, a non-volatile computer-readable storage medium is also provided, such as a memory 1932 including computer program instructions that can be executed by a processing component 1922 of the device 1900 to perform the above-described method.
[0263] Computer-readable storage media can be tangible devices capable of holding and storing programs / instructions used by instruction execution devices. Computer-readable storage media can be, for example—but not limited to—electrical storage devices, magnetic storage devices, optical storage devices, electromagnetic storage devices, semiconductor storage devices, or any suitable combination of the foregoing. More specific examples (a non-exhaustive list) of computer-readable storage media include: portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), static random access memory (SRAM), portable compact disc read-only memory (CD-ROM), digital multifunction disc (DVD), memory sticks, floppy disks, mechanical encoding devices, such as punch cards or recessed protrusions storing instructions thereon, and any suitable combination of the foregoing. The computer-readable storage media used herein are not to be construed as transient signals themselves, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through waveguides or other transmission media (e.g., light pulses through fiber optic cables), or electrical signals transmitted through wires.
[0264] The computer program (or computer-readable program instructions) described herein can be downloaded from a computer-readable storage medium to various computing / processing devices, or downloaded via a network, such as the Internet, local area network, wide area network, and / or wireless network, to an external computer or external storage device. The network may include copper transmission cables, fiber optic transmission, wireless transmission, routers, firewalls, switches, gateway computers, and / or edge servers. A network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards them to the computer-readable storage medium in the respective computing / processing device.
[0265] The computer program (or computer program instructions) used to perform the operations of this disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages such as Smalltalk, C++, etc., and conventional procedural programming languages such as the "C" language or similar programming languages. The computer-readable program instructions may execute entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or may be connected to an external computer (e.g., via the Internet using an Internet service provider). In some embodiments, electronic circuitry, such as programmable logic circuitry, field-programmable gate arrays (FPGAs), or programmable logic arrays (PLAs), is personalized by utilizing state information from the computer-readable program instructions to implement various aspects of this disclosure.
[0266] Various aspects of this disclosure are described herein with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this disclosure. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer-readable program instructions.
[0267] These computer-readable program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing apparatus to produce a machine such that, when executed by the processor of the computer or other programmable data processing apparatus, they create means for implementing the functions / actions specified in one or more blocks of the flowchart and / or block diagram. These computer-readable program instructions can also be stored in a computer-readable storage medium that causes a computer, programmable data processing apparatus, and / or other device to operate in a particular manner; thus, the computer-readable medium storing the instructions comprises an article of manufacture that includes instructions for implementing aspects of the functions / actions specified in one or more blocks of the flowchart and / or block diagram.
[0268] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device to cause a series of operational steps to be performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to perform the functions / actions specified in one or more boxes of a flowchart and / or block diagram.
[0269] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of the present disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of an instruction containing one or more executable instructions for implementing a specified logical function. In some alternative implementations, the functions marked in the blocks may occur in a different order than those shown in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, may be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.
[0270] The various embodiments of this disclosure have been described above. These descriptions are exemplary and not exhaustive, nor are they limited to the disclosed embodiments. Many modifications and variations will be apparent to those skilled in the art without departing from the scope and spirit of the described embodiments. The terminology used herein is chosen to best explain the principles, practical application, or technical improvements to the embodiments in the market, or to enable others skilled in the art to understand the embodiments disclosed herein.
Claims
1. A method of early warning of abnormality in a water environment, characterized by, The method comprises: extracting a plurality of candidate time sequence features from monitored parameter time sequence samples including at least water quality parameter time sequence samples; determining a joint screening score of each candidate time sequence feature based on a contribution degree of each candidate time sequence feature to an anomaly prediction result of the kth round of trained anomaly prediction model, an information amount, a first dynamic weight of the contribution degree, and a second dynamic weight of the information amount; the first dynamic weight and the second dynamic weight are determined based on a first feature set screened using the contribution degree, a first model performance parameter of the kth round of trained anomaly prediction model, and a second feature set screened using the information amount, a second model performance parameter of the kth round of trained anomaly prediction model; training the kth round of trained anomaly prediction model based on a current target time sequence feature screened from the plurality of candidate time sequence features using the joint screening score; until the trained anomaly prediction model meets an iteration stop condition, obtaining a trained anomaly prediction model; warning an anomaly of a target water environment based on the trained anomaly prediction model; before determining the joint screening score of each candidate time sequence feature, further comprising: screening the plurality of candidate time sequence features based on the contribution degree of each candidate time sequence feature, to obtain the first feature set; screening the plurality of candidate time sequence features based on the information amount of each candidate time sequence feature, to obtain the second feature set; training the kth round of trained anomaly prediction model based on the feature value of each candidate time sequence feature in the first feature set and the label corresponding to each feature value, and performing model verification, to obtain a first model performance parameter of the kth round of trained model; k is a positive integer; training the kth round of trained anomaly prediction model based on the feature value of each candidate time sequence feature in the second feature set and the label corresponding to each feature value, and performing model verification, to obtain a second model performance parameter of the kth round of trained model; updating the first dynamic weight and the second dynamic weight corresponding to the k-1th round of trained anomaly prediction model based on the first model performance parameter and the second model performance parameter, to obtain the first dynamic weight and the second dynamic weight corresponding to the kth round of trained anomaly prediction model; when k=1, the first dynamic weight and the second dynamic weight are initialized as a preset value.
2. The method of claim 1, wherein, The determination of the joint screening score of each candidate time sequence feature comprises: determining a union set of the first feature set and the second feature set; normalizing the contribution degree and the information amount of each candidate time sequence feature in the union set, to obtain a normalized contribution degree and a normalized information amount of each candidate time sequence feature; for each candidate time sequence feature in the union set, determining a joint screening score of the candidate time sequence feature based on the first dynamic weight, the normalized contribution degree of the candidate time sequence feature, the second dynamic weight, and the normalized information amount of the candidate time sequence feature.
3. The method of claim 1, wherein, The current target time series feature is selected from the plurality of candidate time series features based on the joint screening score. The plurality of candidate time series features are screened based on the joint screening score to obtain a screening result. It is determined whether the similarity condition is met between each candidate time series feature in the screening result. In the case that the similarity condition is met between at least two candidate time series features, at least one candidate time series feature is selected from the at least two candidate time series features that meet the similarity condition as the current target time series feature.
4. The method of claim 3, wherein, The determination of whether the similarity condition is met between each candidate time series feature in the screening result comprises: The cross-entropy and / or correlation coefficient between different candidate time series features in the screening result is determined. In the case that the cross-entropy and / or correlation coefficient between the different candidate time series features is greater than a preset threshold, it is determined that the similarity condition is met between the different candidate time series features.
5. The method of claim 1, wherein, The abnormality of the target water environment is predicted based on the trained abnormality prediction model, comprising: The final target time series feature used by the trained abnormality prediction model is extracted from a monitoring parameter time series of the target water environment at a to-be-monitored point; wherein the monitoring parameter time series at least includes a water quality parameter time series; The feature value matrix corresponding to the final target time series feature is input into the trained abnormality prediction model to obtain an abnormal probability of the target water environment; Based on the current state of the target water environment, a dynamic threshold of the warning prompt of the target water environment is determined; In the case that the abnormal probability is greater than the dynamic threshold, the target water environment is warned.
6. The method of claim 5, wherein, The determination of the dynamic threshold of the warning prompt of the target water environment based on the current state of the target water environment comprises: The sensitivity enhancement coefficient and the sensitivity inhibition coefficient of the target water environment are obtained; Based on the sensitivity enhancement coefficient, the sensitivity inhibition coefficient and a preset baseline threshold, the dynamic threshold is determined.
7. The method of claim 6, wherein, The sensitivity enhancement coefficient and the sensitivity inhibition coefficient of the target water environment are obtained, comprising: Based on a first target region to which the target water environment currently belongs, a regional sensitivity enhancement coefficient of the target water environment is determined; Based on a first time parameter of the target water environment at present, a time sensitivity enhancement coefficient of the target water environment is determined; Based on a duration of the abnormal probability of the target water environment being greater than the preset baseline threshold, a pollution duration coefficient of the target water environment is determined; Based on the regional sensitivity enhancement coefficient, the time sensitivity enhancement coefficient and the pollution duration coefficient, the sensitivity enhancement coefficient is determined; Based on a second target region to which the target water environment currently belongs, a regional sensitivity inhibition coefficient of the target water environment is determined; Based on a second time parameter of the target water environment at present, a time sensitivity inhibition coefficient of the target water environment is determined; Based on a hydrological period corresponding to a third time parameter of the target water environment at present, a hydrological sensitivity inhibition coefficient of the target water environment is determined; determining the sensitivity suppression coefficient based on the area sensitivity suppression coefficient, the time sensitivity suppression coefficient, and the hydrology sensitivity suppression coefficient.
8. An abnormality early warning device for a water environment, comprising a memory, a processor, and a computer program stored on the memory, characterized by, The processor executes the computer program to implement the steps of the method of any one of claims 1 to 7.
9. A non-transitory computer readable storage medium having stored thereon a computer program, characterized in that, The computer program, when executed by the processor, implements the steps of the method of any one of claims 1 to 7.
Citation Information
Patent Citations
Equipment telemetry data fault analysis method and system based on machine learning
CN120337010A