A water tank water age monitoring and early warning method and system based on the Internet of Things

By collecting multimodal data through an IoT sensor node cluster, a dynamic water age decay model and neural network are constructed to identify abnormal residence areas in the water tank, solving the problem of monitoring blind spots in hydraulic dead zones within the water tank and achieving accurate early warning and handling of water quality safety.

CN122264983APending Publication Date: 2026-06-23杭州浩水科技有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
杭州浩水科技有限公司
Filing Date
2026-03-25
Publication Date
2026-06-23

AI Technical Summary

Technical Problem

Existing technologies cannot effectively monitor localized abnormal water retention caused by hydraulic dead zones or short-circuit flows within water tanks. This results in areas of abnormal water retention becoming monitoring blind spots, making it impossible to accurately distinguish the causes of water age increases. Consequently, the accuracy of early warnings is low, with both false alarms and missed alarms occurring.

Method used

By deploying an IoT sensor node cluster to collect multimodal time-series data, a dynamic water age decay model is constructed to identify abnormal water body areas, calculate spectral offset distance, activate an adaptive sampling strategy, train a water age mutation prediction neural network, and generate graded early warning instructions.

Benefits of technology

It enables precise monitoring of water age changes in water tanks, timely detection of abnormal areas, quantification of the degree of abnormality, dynamic adjustment of sampling frequency, early prediction of sudden changes in water age, improvement of early warning accuracy, and protection of water quality safety.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122264983A_ABST
    Figure CN122264983A_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of secondary water supply control, and particularly relates to a water tank water age monitoring and early warning method and system based on the Internet of Things, which can comprehensively acquire water tank water quality and user water consumption information through multi-modal data acquisition and fusion; can master water tank water age changes in real time, discover potential problem areas in time, and guarantee water tank water quality safety by constructing a dynamic model and identifying abnormal areas; can provide a benchmark for comparative analysis of abnormal conditions by determining normal flow areas, so that early warning processing is more targeted; can accurately evaluate the severity of abnormalities by quantifying the spectral shift distance of the coupling oscillation mode of abnormal and normal areas; can start adaptive sampling according to the spectral shift distance, dynamically improve the monitoring accuracy of abnormal areas, capture details of water age changes in time, and provide reliable data for prediction and early warning; and can predict water age mutations and generate graded early warning instructions by training a neural network, so as to facilitate relevant personnel to respond in time and reduce water tank water quality risks.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of secondary water supply control technology, and in particular to a method and system for monitoring and early warning of water age in water tanks based on the Internet of Things. Background Technology

[0002] In secondary water supply systems and large building water storage facilities, maintaining the freshness of the water in the tank is a key factor in ensuring the safety and taste of drinking water. Excessive water age (i.e., the time water has remained in the tank after entering it) directly leads to accelerated residual chlorine decay, increased risk of microbial regeneration, and decreased chemical stability of the water.

[0003] Currently, IoT-based water tank water quality monitoring technology is widely used. However, existing solutions have significant drawbacks when facing complex and non-uniform actual water tank flow field environments. Due to the irregularities in the internal structure of the water tank, the location of the inlet and outlet, and the user's water usage patterns, hydraulic dead zones or short-circuit flows are easily formed, leading to abnormal local water retention, i.e., spatial water age heterogeneity. Existing monitoring modes based on fixed-point, low-spatial-resolution sensors, as well as simple water age estimation models that treat the water tank as a completely mixed reactor, cannot effectively sense and quantify such local water bodies. The monitoring results of water tank age monitoring in spatially loitering states reflect only a few monitoring points or the overall average, making high-risk areas with abnormal loitering blind spots. Existing methods lack in-depth exploration of the coupling relationship between multi-dimensional water quality parameters and hydraulic dynamics. Water aging is a dynamic process affected by the nonlinear coupling of multiple factors such as water temperature, dissolved oxygen, and water flow velocity. Therefore, it is impossible to distinguish between the temporary increase in water age caused by normal water use intervals and the accelerated aging risk caused by abnormal loitering, accompanied by synergistic changes in specific water quality parameters, resulting in low early warning accuracy and a coexistence of false alarms and missed alarms. To address this, this invention proposes a water tank age monitoring and early warning method and system based on the Internet of Things (IoT). Summary of the Invention

[0004] The purpose of this invention is to solve the problems in the background art, and to propose a water tank water age monitoring and early warning method and system based on the Internet of Things.

[0005] To achieve the above objectives, the present invention adopts the following technical solution: The first aspect of this invention provides a water tank water age monitoring and early warning method based on the Internet of Things, comprising: S1. Collect multimodal time-series water quality data from multiple monitoring points in the water tank, simultaneously acquire time-series logs of user water usage behavior, and fuse them to generate a multimodal fusion time-series dataset; S2. Construct a dynamic water age decay model based on multimodal fusion time series dataset, calculate the real-time water age estimate of each monitoring point, and identify abnormal water body areas; S3. Based on the time-series logs of user water usage behavior, determine the normal flowing water area corresponding to the abnormal water body area; S4. Extract the coupled oscillation modes of the abnormally stagnant water body region and calculate its spectral shift distance from the normal flowing water body region. S5. Based on the calculated spectral offset distance, make a judgment and analysis, and start the adaptive sampling strategy; S6. Based on the adaptive sampling strategy, train a pre-set water age mutation prediction neural network and output the prediction results; generate graded early warning instructions based on the prediction results.

[0006] Furthermore, S1 specifically includes: By deploying a cluster of IoT sensor nodes at multiple preset spatial coordinates inside the water tank, the raw time-series signals of water temperature, dissolved oxygen, pH value, and water flow velocity are synchronously collected at a first sampling frequency; among them, water temperature, dissolved oxygen, pH value, and water flow velocity constitute multimodal time-series data of water quality. Denoising processing based on wavelet transform was performed on each type of original time series signal, and pulse outliers in the signal were removed by the interquartile range method to obtain denoised water quality multimodal time series data. Extract the time-series log of user water usage behavior from the smart water terminal log of the water tank; The denoised water quality multimodal time series data and user water use behavior time series logs are aligned based on a unified time reference axis; the aligned data are then correlated and spliced ​​along the time dimension to generate a multimodal fusion time series dataset with behavior labels.

[0007] Furthermore, S2 specifically includes: From the multimodal fusion time series dataset, extract the single-dimensional water quality time series of each monitoring point within the current time window, including water temperature time series, dissolved oxygen time series, pH value time series and water flow velocity time series; A dynamic water age decay model was established, and the instantaneous water age decay rate at each monitoring point was calculated in real time using the extracted water temperature time series, dissolved oxygen time series, and pH value time series. Obtain the time series of water flow velocity at the same monitoring point, and construct a spatial correction factor for the instantaneous water age decay rate. Multiply the instantaneous water age decay rate by the spatial correction factor to obtain the corrected local water age decay rate. By integrating the corrected local water age decay rate over time, the real-time water age estimate of each monitoring point since the last complete water body update is calculated, and a water age spatial distribution map is formed. By combining time-series logs of user water usage behavior, abnormal water bodies in the spatial distribution map of water age can be identified.

[0008] Furthermore, S3 specifically includes: Obtain the spatial extent of the marked abnormal water body area and the identification of all monitoring points within it; Outside of abnormally stagnant water bodies, a set of monitoring points whose mean or median water flow velocity time series consistently exceeds a preset active threshold is selected, and the continuous spatial area covered by the monitoring point set is defined as a normally flowing water body area.

[0009] Furthermore, S4 specifically includes: An abnormal region data subset corresponding to an abnormal water body region and a normal region data comparison subset corresponding to a normal flowing water body region are constructed respectively. Empirical mode decomposition was performed on the one-dimensional water quality time series in the abnormal region data subset and the normal region data control subset to obtain a set of intrinsic mode functions for each. Calculate the cross-correlation coefficients of the corresponding intrinsic mode functions of abnormal stagnant water bodies and normal flowing water bodies in the same water quality dimension within a preset dominant frequency band, and construct a multidimensional coupled oscillation cross-correlation coefficient matrix; Expanding the upper triangular elements of the coupled oscillation cross-correlation coefficient matrix into an eigenvector yields vector A, representing the coupled oscillation mode in the anomalous stagnant water region, and vector B, representing the coupled oscillation mode in the normal flowing water region.

[0010] Furthermore, a subset of data from abnormal regions and a comparative subset of data from normal regions are constructed, including: From the multimodal fusion time series dataset, all monitoring points in the abnormal water body area and all monitoring points in the normal flowing water body area as a control are extracted, and all time-aligned data entries are extracted within the same preset historical analysis period. Data extracted from areas of abnormally stagnant water bodies constitute an abnormal region data subset, while data extracted from areas of normally flowing water bodies constitute a normal region data control subset.

[0011] Furthermore, S4 also includes: Calculate the Euclidean distance between vector A and vector B, and normalize the Euclidean distance by dividing it by the product of the magnitudes of the two vectors. The final output is the spectral offset distance used to quantify the degree of anomaly.

[0012] Furthermore, S5 specifically includes: A first coupling oscillation threshold is preset, and the calculated spectral shift distance is compared with the first coupling oscillation threshold. When the spectral offset distance is greater than the first coupled oscillation threshold, it is determined that there is a risk of accelerated water age decay in the abnormal water body area, triggering an early warning signal for accelerated water age decay. Based on the magnitude of the spectral offset distance, the sampling frequency of the IoT sensor node cluster in the corresponding abnormal water body area is dynamically adjusted; The boundary monitoring point sensors adjacent to the abnormal water body area are activated synchronously to perform collaborative sampling, thereby forming an adaptive sampling network that provides high spatiotemporal resolution surrounding monitoring of the abnormal water body area.

[0013] Furthermore, S6 specifically includes: We collected enhanced multimodal fusion time-series datasets generated by the anomalous water body region and its surrounding area during multiple consecutive warning periods while the adaptive sampling network was in effect. A water age mutation prediction neural network is constructed. The input layer of the network receives a preprocessed enhanced multimodal fusion time series dataset fragment. Its network structure includes a one-dimensional convolutional layer for extracting local features, a long short-term memory network layer for capturing long-term temporal dependencies, and a fully connected layer for integration and output prediction. The abrupt events of water age values ​​in anomalous water bodies in the spatial distribution map of water age are used as supervision labels to supervise the training of the water age mutation prediction neural network. The latest enhanced multimodal fusion time series dataset obtained through the adaptive sampling network within the current time window is input into the trained water age mutation prediction neural network; The water age mutation prediction neural network outputs prediction results in two dimensions: a sequence of predicted probability values. Based on the shape of the predicted probability value sequence, the earliest possible prediction time point of water age mutation is determined and output.

[0014] A second aspect of the present invention provides a water tank water age monitoring and early warning system based on the Internet of Things, comprising: Multimodal data fusion module: Collects multimodal time-series water quality data from multiple monitoring points in the water tank, synchronously acquires time-series logs of user water usage behavior, and merges them to generate a multimodal fused time-series dataset; Water age modeling and identification module: Based on a multimodal fusion time series dataset, a dynamic water age decay model is constructed to calculate the real-time water age estimate for each monitoring point and identify abnormal water body areas; Normal flow area determination module: Based on the time-series logs of user water usage behavior, determine the normal flow water area corresponding to the abnormal water body area; Spectral offset distance calculation module: Extracts the coupled oscillation modes of the abnormally stagnant water body region and calculates their spectral offset distance from the normal flowing water body region; Early warning sampling trigger module: It performs judgment and analysis based on the calculated spectral offset distance and starts the adaptive sampling strategy; Early warning prediction push module: Based on an adaptive sampling strategy, a pre-set water age mutation prediction neural network is trained and the prediction results are output; based on the prediction results, a graded early warning instruction is generated.

[0015] Compared with existing technologies, the present invention provides a water tank water age monitoring and early warning method and system based on the Internet of Things, the advantages of which are: 1) By acquiring and fusing multimodal time-series data, comprehensive information on water quality in the water tank and user water usage behavior data can be obtained, providing a rich and accurate data foundation for subsequent analysis. This can reflect the state of the water in the tank from multiple dimensions, thereby more accurately monitoring water age-related information. By calculating the estimated water age of each monitoring point in real time and forming a distribution map, combined with user water usage behavior to identify abnormal water retention areas, the changes in water age in the tank can be dynamically monitored, and areas with potential problems can be identified in a timely manner, providing a basis for subsequent targeted treatment and ensuring the safety of water quality in the tank. 2) By identifying the areas of abnormal water bodies and combining data such as water flow velocity, the areas of normal flowing water bodies are determined, providing a benchmark for comparative analysis of abnormal and normal areas. This allows for a deeper understanding of the water flow characteristics within the tank, clarifies the scope and characteristics of abnormal situations, and makes early warning and handling more targeted. By extracting the coupled oscillation modes of abnormal and normal areas and calculating the spectral shift distance, the degree of abnormality is quantified, providing a standard for judging the severity of the abnormality. This facilitates accurate risk assessment and provides a basis for whether to trigger an early warning and what measures to take. 3) By judging based on the spectral offset distance and activating the adaptive sampling strategy, the sampling frequency and collaborative sampling are dynamically adjusted to improve the monitoring accuracy of abnormal areas, capture details of water age changes in a timely manner, and provide more reliable data support for subsequent accurate prediction and early warning; by training the water age mutation prediction neural network and outputting the prediction results, a graded early warning instruction is generated, realizing the early prediction of water age mutations, and pushing early warnings according to different risk levels, so that relevant personnel can take timely measures to reduce the risk of water quality in the water tank and ensure water safety. Attached Figure Description

[0016] Figure 1 This is a flowchart of a water tank water age monitoring and early warning method based on the Internet of Things proposed in this invention.

[0017] Figure 2 This is a block diagram of a water tank water age monitoring and early warning system based on the Internet of Things proposed in this invention. Detailed Implementation

[0018] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0019] Please see Figure 1 This invention provides a water tank water age monitoring and early warning method based on the Internet of Things, comprising: S1. Collect multimodal time-series water quality data from multiple monitoring points in the water tank, simultaneously acquire time-series logs of user water usage behavior, and fuse them to generate a multimodal fusion time-series dataset; S2. Construct a dynamic water age decay model based on multimodal fusion time series dataset, calculate the real-time water age estimate of each monitoring point, and identify abnormal water body areas; S3. Based on the time-series logs of user water usage behavior, determine the normal flowing water area corresponding to the abnormal water body area; S4. Extract the coupled oscillation modes of the abnormally stagnant water body region and calculate its spectral shift distance from the normal flowing water body region. S5. Based on the calculated spectral offset distance, make judgments and analyses, and start the adaptive sampling strategy to increase the data acquisition frequency in the abnormal water body area; S6. Based on the adaptive sampling strategy, train a pre-set water age mutation prediction neural network and output the prediction results; generate graded early warning instructions based on the prediction results and push them to the IoT management platform and related user terminals.

[0020] In this embodiment of the invention, the detailed implementation steps of S1, which involves collecting multimodal time-series water quality data from multiple monitoring points within the water tank, simultaneously acquiring time-series logs of user water usage behavior, and fusing them to generate a multimodal fusion time-series dataset, include: By deploying a cluster of IoT sensor nodes at multiple preset spatial coordinates inside the water tank, the raw time-series signals of water temperature, dissolved oxygen, pH value, and water flow velocity are synchronously collected at a first sampling frequency; among them, water temperature, dissolved oxygen, pH value, and water flow velocity constitute multimodal time-series data of water quality. Denoising processing based on wavelet transform was performed on each type of original time series signal, and pulse outliers in the signal were removed by the interquartile range method to obtain denoised water quality multimodal time series data. Extract the time-series log of user water usage behavior from the smart water terminal log of the water tank; The denoised water quality multimodal time series data and user water use behavior time series logs are aligned based on a unified time reference axis; the aligned data are then correlated and spliced ​​along the time dimension to generate a multimodal fusion time series dataset with behavior labels. Specifically, based on the three-dimensional structure of the water tank, multiple spatial coordinate points are preset at key internal locations. These spatial coordinate points should cover various typical areas of the water tank, such as the vicinity of the inlet, the vicinity of the outlet, the central area, and the corner areas. An integrated IoT sensor node is installed at each spatial coordinate point. This node has a built-in water temperature sensor, dissolved oxygen sensor, pH sensor, and ultrasonic or electromagnetic water flow rate sensor. All sensor nodes form a cluster and are coordinated by a central data acquisition unit to synchronously acquire the raw electrical signals of water temperature, dissolved oxygen concentration, pH value, and water flow rate at a unified first sampling frequency, generating four sets of parallel raw time-series signals. By selecting appropriate wavelet basis functions and decomposition levels, the original time series signal is decomposed into approximation coefficients and detail coefficients at different scales. An adaptive threshold (used for processing and analysis in wavelet denoising) is set to process the high-frequency detail coefficients representing noise, followed by wavelet reconstruction to obtain a smooth signal with high-frequency noise removed. Outlier removal is performed on the denoised original time series signal using the statistical interquartile range method: the upper quartile, lower quartile, and interquartile range of the original time series signal sequence are calculated. Data points exceeding 1.5 times the upper quartile range or falling below 1.5 times the lower quartile range are considered impulse outliers and replaced with linear interpolation of adjacent points or directly removed. Finally, high-quality, denoised time series data for water temperature, dissolved oxygen, pH, and water flow velocity are obtained. Information is extracted from the log database of the smart water terminal connected to the water tank, with water usage events as the unit. Each water usage event log contains three key fields: the timestamp when water usage begins, the timestamp when water usage ends, and the cumulative water flow measured by the water meter during that time period. All water usage events are arranged in chronological order to form a time-series log of user water usage behavior. A time baseline is set; the denoised multimodal water quality time-series data and user water use behavior time-series logs are aligned and resampled using this preset time baseline to ensure that all data points have a unified time index; after time alignment, at the data storage level, the water quality data (water temperature, dissolved oxygen, pH, flow rate) at each time point is associated and spliced ​​with the active water use behavior tags (such as water in use or still) within that time period; for example, at a certain time point, in addition to recording the four-dimensional water quality data, a field is added to record the current instantaneous water flow or the cumulative water use in the past M seconds. This field data comes from the real-time parsing of the water use behavior logs; finally, a multimodal fusion time-series dataset with time-series behavior tags is generated, laying the data foundation for subsequent analysis.

[0021] In this embodiment of the invention, the detailed implementation steps of S2, which constructs a dynamic water age decay model based on a multimodal fusion time-series dataset, calculates the real-time water age estimate for each monitoring point, and identifies abnormal water body areas, include: From the multimodal fusion time series dataset, extract the single-dimensional water quality time series of each monitoring point within the current time window, including water temperature time series, dissolved oxygen time series, pH value time series and water flow velocity time series; A dynamic water age decay model was established, and the instantaneous water age decay rate at each monitoring point was calculated in real time using the extracted water temperature time series, dissolved oxygen time series, and pH value time series. Obtain the time series of water flow velocity at the same monitoring point, and construct a spatial correction factor for the instantaneous water age decay rate. Multiply the instantaneous water age decay rate by the spatial correction factor to obtain the corrected local water age decay rate. By integrating the corrected local water age decay rate over time, the real-time water age estimate of each monitoring point since the last complete water body update is calculated, and a water age spatial distribution map is formed. By combining time-series logs of user water usage behavior, abnormal water bodies in the spatial distribution map of water age can be identified. Specifically, for each monitoring point in the multimodal fusion time series dataset, slide the current time window and extract each single-dimensional water quality time series from the time window, including water temperature time series, dissolved oxygen time series, pH value time series and water flow velocity time series; A dynamic water age decay model was constructed, which is a nonlinear function model of the water age decay rate. The dynamic water age decay model expresses the instantaneous water age decay rate as a function of water temperature, dissolved oxygen concentration, and pH value. The dynamic water age decay model assumes that the water age decay rate is positively correlated with water temperature (the higher the water temperature, the more active the microbial activity or chemical reaction may be, and the faster the water body aging), negatively correlated with dissolved oxygen concentration within a certain range (sufficient dissolved oxygen may delay some anaerobic deterioration processes), and has an optimal range with pH value. Deviating from this optimal range will lead to an accelerated decay rate. Using the water temperature, dissolved oxygen, and pH value extracted from the current time window, the model function is instantiated to calculate the instantaneous water age decay rate corresponding to the monitoring point in real time. Understandably, the dynamic water age decay model can be expressed as the product of functions of various influencing factors, such as the instantaneous water age decay rate. In the formula, T is the water temperature, DO is the dissolved oxygen concentration, and pH is the acidity or alkalinity. The positive correlation function characterizing the effect of water temperature; A negative correlation function characterizing the effect of dissolved oxygen, such as a function that decreases with increasing DO within a safe concentration range; The function characterizes the effect of pH, and it takes the minimum value within the optimal pH range. The function value increases when it deviates to both sides. The specific function form and parameters in the model are determined by water age decay experimental data under controlled laboratory conditions, or by nonlinear regression fitting of historical multimodal fusion time series datasets of long-term system operation. The applicable conditions of this model are that the water temperature, dissolved oxygen and pH value are within the typical range specified by the drinking water quality standards. Since the theoretical decay rate does not take into account the fluidity of the water body, the aging rate of stagnant water is much higher than that of flowing water; therefore, a spatial correction factor needs to be introduced. Simultaneously, the time series of the water flow velocity at the monitoring point should be obtained. A spatial correction factor function with water flow velocity as the independent variable should be constructed. This function outputs a very small value, such as 0.1, when the water flow velocity is zero, indicating that the decay is almost unsuppressed. As the water flow velocity increases, the spatial correction factor value monotonically increases and tends to 1, indicating that the renewal effect brought about by the flow completely suppresses the local aging effect. The calculated instantaneous water age decay rate is multiplied by the spatial correction factor corresponding to the current water flow velocity at the monitoring point to obtain the corrected local water age decay rate. The water age estimate is obtained by integrating the decay rate. The moment when each monitoring point was last confirmed to be completely updated is recorded as the starting point of integration. For example, if the water flow velocity at this point is extremely high and exceeds the scouring threshold, the scouring threshold is set to be significantly higher than the level of background noise and weak flow, and is taken as 2-3 times the preset active threshold, to determine whether the water body has been completely updated. From this starting point to the present, the corrected local water age decay rate that changes over time is numerically integrated. The integration result is the real-time water age estimate of the monitoring point since the last complete update. This calculation is performed on all monitoring points, and the results are mapped to their spatial coordinates to generate a water age spatial distribution map reflecting the water age distribution inside the tank. Identifying abnormal water retention areas by combining user water usage behavior time-series logs includes: analyzing the spatial distribution map of water age to find areas where the real-time water age estimate is higher than the overall average water age of the water tank, i.e., high water age areas; simultaneously, reviewing user water usage behavior logs to check whether monitoring points in high water age areas have not been effectively covered or flushed by water flow paths generated by any recorded water usage events within a preset time period; the preset time period is set based on the typical time when water quality may begin to deteriorate significantly, such as 2 hours, to determine abnormal retention; continuous spatial areas that simultaneously meet the two conditions of continuously high water age and no effective water flow updates for a long time are marked as abnormal water retention areas, which are potential water quality deterioration risk areas.

[0022] In this embodiment of the invention, the detailed implementation steps of S3, which combines user water usage behavior time-series logs to determine the normal flowing water area corresponding to the abnormal water body area, include: Obtain the spatial extent of the marked abnormal water body area and the identification of all monitoring points within it; Outside of abnormally stagnant water bodies, a set of monitoring points whose mean or median water flow velocity time series is consistently higher than a preset active threshold is selected, and the continuous spatial area covered by the set of monitoring points is defined as a normally flowing water body area. Specifically, information on marked anomalous water bodies is obtained, including their spatial boundaries, such as the smallest convex polygon enclosed by the coordinates of all monitoring points constituting the area, and a list of unique identifiers for all monitoring points contained within the area. Retrieve user water usage behavior time-series logs and water flow velocity time-series sequences from all monitoring points; filter among all remaining monitoring points outside of the abnormal water body area; the screening criteria are: the mean or median of the water flow velocity time-series sequence of the monitoring point has been consistently higher than the preset active threshold during the most recent statistical period. The active threshold is obtained by statistical analysis of the water flow velocity of all monitoring points in the water tank during peak water usage periods, and is used to distinguish between effective flow and basic stillness. The selected monitoring points have been in a state of good water flow for a long time, and their water is fresh and the water age value should be low. Through screening, a set of monitoring points that meet the conditions of continuous active flow is obtained; the spatial distribution of all monitoring points is analyzed; the spatial location of the monitoring points is clustered, or the continuous spatial area covered by the monitoring points is identified directly based on the continuity of their coordinates, and this area is determined as the normal flowing water body area; it is understood that the normal flowing water body area serves as a health benchmark for the hydraulic conditions and renewal status within the water tank, and its water quality dynamic pattern will be used to compare with the abnormal area in order to diagnose the unique risk patterns of the abnormal area.

[0023] In this embodiment of the invention, the detailed implementation steps of S4—extracting the coupled oscillation modes of the anomalously stagnant water region and calculating its spectral shift distance with that of the normally flowing water region—include: An abnormal region data subset corresponding to an abnormally stagnant water body area and a normal region data control subset corresponding to a normally flowing water body area are constructed. Specifically, from the multimodal fusion time series dataset, all time-aligned data entries within the same preset historical analysis period are extracted from all monitoring points in the abnormally stagnant water body area and all monitoring points in the normal flowing water body area (as a control). The data extracted from the abnormally stagnant water body area constitutes the abnormal region data subset, and the data extracted from the normal flowing water body area constitutes the normal region data control subset. Empirical mode decomposition was performed on the one-dimensional water quality time series in the abnormal region data subset and the normal region data control subset to obtain a set of intrinsic mode functions for each. Calculate the cross-correlation coefficients of the corresponding intrinsic mode functions of abnormal stagnant water bodies and normal flowing water bodies in the same water quality dimension within a preset dominant frequency band, and construct a multidimensional coupled oscillation cross-correlation coefficient matrix; Expand the upper triangular elements of the coupled oscillation cross-correlation coefficient matrix into an eigenvector to obtain vector A representing the coupled oscillation mode of the abnormal stagnant water body region and vector B representing the coupled oscillation mode of the normal flowing water body region. Calculate the Euclidean distance between vector A and vector B, and normalize the Euclidean distance by dividing it by the product of the magnitudes of the two vectors. The final output is the spectral offset distance used to quantify the degree of anomaly. Specifically, from the multimodal fusion time-series dataset, all time-aligned data entries are extracted from all monitoring points within the same preset historical analysis period, such as the past 4 hours, belonging to both the abnormal stagnant water body area and the normal flowing water body area. Each data entry contains four single-dimensional water quality time-series data values ​​for water temperature, dissolved oxygen, pH, and water flow velocity at the corresponding time point, as well as associated user water use behavior tag information. Data from the abnormal stagnant water body area is packaged to form an abnormal area data subset; simultaneously, data from the normal flowing water body area is packaged to form a normal area data comparison subset. The two subsets are fully aligned in the time dimension to ensure the fairness of the comparison. Empirical mode decomposition (EMD) was performed independently on the one-dimensional water quality time series of each monitoring point in the two data subsets, namely, the water temperature time series, dissolved oxygen time series, pH value time series, and water flow velocity time series. EMD is an adaptive signal decomposition method that decomposes complex signals into a series of intrinsic mode functions arranged from high frequency to low frequency and a residual trend term. After performing EMD on the one-dimensional water quality time series, a set of intrinsic mode function components was obtained. For any set of intrinsic mode functions (IMFs), calculate the variance of each IMF component and its proportion of the total variance; starting from the lowest frequency (i.e., the first-order IMF), accumulate the variance contribution rates of each IMF; define the frequency range corresponding to the continuous low-order IMFs included when the cumulative variance contribution rate exceeds a preset contribution threshold as the dominant frequency band of the one-dimensional water quality time series; where the contribution threshold is used to determine the dominant frequency band in empirical mode decomposition; the dominant frequency band contains the most important energy and oscillation information of the signal; The coupling relationship between two regions in the same water quality dimension is calculated. For the same-dimensional water quality time series, intrinsic mode function (EMF) components located in their respective dominant frequency bands are extracted from multiple monitoring points in the anomalous stagnant water body region and the normal flowing water body region. The cross-correlation coefficient between the EMFs in the dominant frequency band of the anomalous stagnant water body region and the corresponding EMFs in the dominant frequency band of the normal flowing water body region is calculated. The cross-correlation coefficient reflects the synchronicity or similarity of the main oscillation modes of the two regions in this water quality dimension. The above calculation is performed on the single-dimensional water quality time series to obtain a four-dimensional correlation coefficient set. The correlation coefficient set is organized into a symmetric matrix form, i.e., a multi-dimensional coupled oscillation cross-correlation coefficient matrix is ​​constructed. Each element of this matrix quantifies the correlation strength of the core oscillation modes of the anomalous stagnant water body region and the normal flowing water body region in a specific water quality dimension. All elements of the upper triangular part of the coupled oscillation cross-correlation coefficient matrix are extracted and arranged in a fixed order to form a one-dimensional feature vector; thus, vector A representing the coupled oscillation mode in the abnormal region and vector B representing the coupled oscillation mode in the normal region are obtained. These two vectors are the basis for subsequent calculation of spectral offset distance. Calculating the Euclidean distance between vectors A and B involves: subtracting each element of vector A from the corresponding element of vector B to find the difference; squaring all differences, summing them, and then taking the square root of the sum of the squares of the differences between corresponding elements; the calculated Euclidean distance directly reflects the linear interval between the two pattern vectors in multidimensional space; and dividing the calculated Euclidean distance by the product of the magnitudes of vector A and vector B; the magnitude of vector A is the square root of the sum of the squares of its elements, representing the length or strength of vector A itself; the same applies to the magnitude of vector B. When vectors A and B are identical, the distance is 0; as the difference between the two increases, the distance value approaches 1 or greater; the normalized spectral offset distance is used as the core diagnostic indicator to quantify the degree of dynamic pattern abnormality in the abnormal resident water area; the larger the value, the greater the difference between the water quality oscillation behavior in the area and the healthy flow area, suggesting that a physicochemical process that accelerates water aging may be taking place inside.

[0024] In this embodiment of the invention, the detailed implementation steps of S5, which involves making a judgment and analysis based on the calculated spectral offset distance and initiating an adaptive sampling strategy, include: A first coupling oscillation threshold is preset, and the calculated spectral shift distance is compared with the first coupling oscillation threshold; wherein, the first coupling oscillation threshold is an empirical value obtained by statistical analysis of historical normal data and slightly abnormal data, representing the upper limit of the allowable mode difference. When the spectral offset distance is greater than the first coupled oscillation threshold, it is determined that there is a risk of accelerated water age decay in the abnormal water body area, triggering an early warning signal for accelerated water age decay. Based on the magnitude of the spectral offset distance, the sampling frequency of the IoT sensor node cluster in the corresponding abnormal water body area is dynamically adjusted; The sensors at the boundary monitoring points adjacent to the anomalous water body area are simultaneously activated, enabling them to perform collaborative sampling at an enhanced frequency. This forms an adaptive sampling network that provides high spatiotemporal resolution coverage of the anomalous water body area. The data generated by the adaptive sampling network has a much higher temporal and spatial density than conventional monitoring, providing high-quality data support for more accurate risk prediction in the future. Understandably, after the warning is triggered, the monitoring intensity of the abnormally lingering water area is increased, i.e., an adaptive sampling strategy is activated. The goal of the adaptive sampling strategy is to dynamically adjust the sampling frequency based on the spectral offset distance value. The linkage rule is set: for every fixed percentage that the spectral offset distance exceeds the first coupling oscillation threshold, for example, every 10%, the sampling frequency of all IoT sensor nodes in the corresponding abnormally lingering water area is increased by a fixed factor based on the original first sampling frequency, for example, by 0.5 times; the maximum increase is N times the first sampling frequency, where N is an integer greater than 2. For example, if the spectral offset distance exceeds the first coupling oscillation threshold by 20%, the sampling frequency is increased by 1 time (becoming twice the first sampling frequency); if it exceeds the first coupling oscillation threshold by 40%, the sampling frequency is increased by 2 times (becoming three times the first sampling frequency), and so on until the upper limit.

[0025] In this embodiment of the invention, step S6 trains a pre-set water age mutation prediction neural network based on an adaptive sampling strategy and outputs the prediction result; the detailed implementation steps for generating graded early warning instructions based on the prediction result include: Under the adaptive sampling strategy, sensors in the abnormal water body area and its surrounding area sample at an enhanced frequency, resulting in time series data with higher temporal resolution and denser data points. This data is then fused with synchronously updated user water use behavior logs to form a new dataset, which is the enhanced multimodal fusion time series dataset. We collected enhanced multimodal fusion time-series datasets generated by the anomalous water body region and its surrounding area during multiple consecutive warning periods while the adaptive sampling network was in effect. A water age mutation prediction neural network is constructed. The input layer of the network receives a preprocessed enhanced multimodal fusion time series dataset fragment. Its network structure includes a one-dimensional convolutional layer for extracting local features, a long short-term memory network layer for capturing long-term temporal dependencies, and a fully connected layer for integration and output prediction. Using abrupt changes in water age values ​​in anomalous water bodies within a spatial distribution map of water age as supervisory labels, a supervised training method is used to train a neural network for predicting water age mutations. This allows the network to learn the complex mapping relationship between the input multimodal time-series data patterns and the risk of water age mutations. A mutation event is defined as a rapid increase in water age values ​​exceeding a set mutation threshold within a short period of time. The mutation threshold is determined by statistically analyzing the normal fluctuation range of historical water age data and is used to define water age mutation events. The latest enhanced multimodal fusion time series dataset obtained through the adaptive sampling network within the current time window is input into the trained water age mutation prediction neural network; The water age mutation prediction neural network outputs prediction results in two dimensions: a sequence of predicted probability values. Based on the shape of the predicted probability value sequence, the earliest possible prediction time point of water age mutation is determined and output. Specifically, a water age mutation prediction neural network is constructed. The input layer of this network is set to receive preprocessed enhanced multimodal fusion time-series data segments. Its network structure adopts a hybrid architecture: the first layer is a one-dimensional convolutional layer with its convolution kernel sliding in the time dimension to automatically extract local correlation features and short-term fluctuation patterns between different water quality parameters in the input data segments; after the convolutional layer, a long short-term memory network layer is connected to capture the long-term dependence and dynamic evolution trend of local correlation features in the time series; the end of the network is a fully connected layer, which is responsible for integrating and nonlinearly mapping the high-level abstract features output by the long short-term memory network layer, and finally outputting the prediction results. During the period when the adaptive sampling strategy is in effect, enhanced multimodal fusion time-series datasets are continuously collected from abnormally resident water areas and their surrounding adjacent areas over multiple consecutive complete warning cycles. This high spatiotemporal resolution data collected from similar risk events in history is combined with the label of the final determination result of whether a water age mutation actually occurred, forming a training sample set for the water age mutation prediction neural network. The determination process for whether a water age mutation actually occurred involves whether the water age value increased sharply within a short period of time, exceeding a set mutation threshold. Using this training sample set, a pre-built water age mutation prediction neural network is subjected to supervised training. The internal parameters of the water age mutation prediction neural network are adjusted through optimization algorithms, enabling it to learn to identify precursor features of water age mutations from complex multimodal time-series data patterns, completing a complex nonlinear mapping learning from data to risk prediction. After training, the water age mutation prediction neural network is deployed online for real-time prediction tasks. During the prediction phase, the latest enhanced multimodal fusion time-series dataset obtained through the adaptive sampling network within the current time window, such as the last 30 minutes, is input into the trained water age mutation prediction neural network. This network outputs prediction results in two dimensions: 1) an output prediction probability value sequence, which represents the predicted probability value of a water age mutation event occurring within multiple consecutive preset time windows (e.g., the next 1st, 2nd, and 3rd hours), where each prediction probability value corresponds to a preset time window, and each value is between 0 and 1; 2) based on the shape of the prediction probability value sequence, the earliest possible prediction time point of the water age mutation is determined and output. It should be noted that the method for determining the prediction time point is as follows: scan the output prediction probability value sequence, identify the first prediction probability value in the sequence that exceeds the preset probability threshold, and output the start time or center time of the preset time window corresponding to the prediction probability value as the earliest possible prediction time point of the water age mutation. The preset probability threshold is used to convert continuous prediction probability values ​​into a binary judgment criterion for whether a water age mutation is about to occur. Based on the prediction results, the maximum value in the sequence of predicted probability values ​​for water age mutations is obtained, and the risk level is determined by combining it with a predefined risk range; the risk range includes low risk range, medium risk range and high risk range. If the maximum value is in the low-risk range, a general reminder message is generated, including the location of the abnormal area and the recommended inspection time; if the maximum value is in the medium-risk range, a warning message is generated, including a suggestion to start a local water circulation command; if the maximum value is in the high-risk range, an emergency warning message is generated, and an emergency water replacement procedure is automatically initiated. This emergency water replacement procedure includes: F1, the IoT management platform analyzes the coordinates of the abnormal water body area in the emergency warning message and calculates the nearest inlet and outlet control valves to the abnormal water body area based on a preset water tank and pipeline topology map; F2, a linkage control command is sent to the inlet and outlet control valves to open the inlet valve and adjust it to the preset emergency flow rate, while simultaneously opening the outlet valve to form a directional water exchange channel flowing through the abnormal water body area; the purpose of setting the emergency flow rate is to ensure the efficiency and effectiveness of the emergency water replacement, based on the abnormal water body... The estimated volume of the area and the expected replacement completion time are used to calculate the emergency flow rate through a fluid dynamics model. The emergency flow rate ensures that the aging water in the abnormal area can be effectively diluted and replaced through the formed directional flow channel within the target time. F3: The multimodal fusion time series dataset monitored by the adaptive sampling network during the water replacement process is acquired in real time, and the real-time water age estimate of the abnormal water body area is calculated accordingly. F4: When the real-time water age estimate drops below the safety threshold and remains stable for more than the preset time, the drain valve and inlet valve are closed sequentially to complete the emergency water replacement and send a disposal completion signal to the platform. The safety threshold is used to determine whether the water body has returned to a safe state during emergency replacement or routine management. This threshold is determined based on the relevant guidance value of the maximum allowable residence time of water in the pipe network (i.e., the maximum allowable water age) in the national or industry drinking water hygiene standards, combined with the historical safe operation data of this water tank system. The system queries historical warning logs stored in the database and analyzes the response rate of target user terminals to past medium and low risk warnings. If the response rate is lower than the preset activity threshold, an enhanced push strategy is matched for the user terminal, which includes attaching a higher level of risk warning in subsequent warnings. The graded warning instructions and their matching push strategies are packaged and sent to the IoT management platform, and then pushed to the relevant user terminals.

[0026] Please see Figure 2 This invention provides a water tank water age monitoring and early warning system based on the Internet of Things, comprising: Multimodal data fusion module: Collects multimodal time-series water quality data from multiple monitoring points in the water tank, synchronously acquires time-series logs of user water usage behavior, and merges them to generate a multimodal fused time-series dataset; Water age modeling and identification module: Based on a multimodal fusion time series dataset, a dynamic water age decay model is constructed to calculate the real-time water age estimate for each monitoring point and identify abnormal water body areas; Normal flow area determination module: Based on the time-series logs of user water usage behavior, determine the normal flow water area corresponding to the abnormal water body area; Spectral offset distance calculation module: Extracts the coupled oscillation modes of the abnormally stagnant water body region and calculates their spectral offset distance from the normal flowing water body region; Early warning sampling trigger module: Based on the calculated spectral offset distance, it makes judgments and analyses, and starts an adaptive sampling strategy to increase the data acquisition frequency in areas of abnormal water retention; Early warning prediction and push module: Based on an adaptive sampling strategy, a pre-set water age mutation prediction neural network is trained and the prediction results are output; based on the prediction results, a graded early warning instruction is generated and pushed to the IoT management platform and related user terminals.

[0027] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to interchangeably. The focus of each embodiment is on its differences from other embodiments. In particular, the apparatus embodiments are described simply because they are fundamentally based on the method embodiments; relevant details can be found in the descriptions of the method embodiments.

[0028] For ease of description, the above devices are described separately by function as various units. Of course, in implementing this application, the functions of each unit can be implemented in one or more software and / or hardware.

[0029] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0030] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, as well as combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0031] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0032] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0033] Secondly: The accompanying drawings of the embodiments disclosed in this invention only involve the structures involved in the embodiments disclosed in this invention. Other structures can refer to the general design. In the absence of conflict, the same embodiment and different embodiments of this invention can be combined with each other. In conclusion, the above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.

Claims

1. A water tank water age monitoring and early warning method based on Internet of Things, characterized in that, include: S1. Collect multimodal time-series water quality data from multiple monitoring points in the water tank, simultaneously acquire time-series logs of user water usage behavior, and fuse them to generate a multimodal fusion time-series dataset; S2. Construct a dynamic water age decay model based on multimodal fusion time series dataset, calculate the real-time water age estimate of each monitoring point, and identify abnormal water body areas; S3. Based on the time-series logs of user water usage behavior, determine the normal flowing water area corresponding to the abnormal water body area; S4. Extract the coupled oscillation modes of the abnormally stagnant water body region and calculate its spectral shift distance from the normal flowing water body region. S5. Based on the calculated spectral offset distance, make a judgment and analysis, and start the adaptive sampling strategy; S6. Based on the adaptive sampling strategy, train a pre-set water age mutation prediction neural network and output the prediction results; generate graded early warning instructions based on the prediction results.

2. The water tank water age monitoring and early warning method based on the Internet of Things according to claim 1, characterized in that, S1 includes: By deploying a cluster of IoT sensor nodes at multiple preset spatial coordinates inside the water tank, the raw time-series signals of water temperature, dissolved oxygen, pH value, and water flow velocity are synchronously collected at a first sampling frequency; among them, water temperature, dissolved oxygen, pH value, and water flow velocity constitute multimodal time-series data of water quality. Denoising processing based on wavelet transform was performed on each type of original time series signal, and pulse outliers in the signal were removed by the interquartile range method to obtain denoised water quality multimodal time series data. Extract the time-series log of user water usage behavior from the smart water terminal log of the water tank; The denoised water quality multimodal time series data and user water use behavior time series logs are aligned based on a unified time reference axis; the aligned data are then correlated and spliced ​​along the time dimension to generate a multimodal fusion time series dataset with behavior labels.

3. The method for monitoring and early warning of water age in a water tank based on the Internet of Things according to claim 2, characterized in that, S2 includes: From the multimodal fusion time series dataset, extract the single-dimensional water quality time series of each monitoring point within the current time window, including water temperature time series, dissolved oxygen time series, pH value time series and water flow velocity time series; A dynamic water age decay model was established, and the instantaneous water age decay rate at each monitoring point was calculated in real time using the extracted water temperature time series, dissolved oxygen time series, and pH value time series. Obtain the time series of water flow velocity at the same monitoring point, and construct a spatial correction factor for the instantaneous water age decay rate. Multiply the instantaneous water age decay rate by the spatial correction factor to obtain the corrected local water age decay rate. By integrating the corrected local water age decay rate over time, the real-time water age estimate of each monitoring point since the last complete water body update is calculated, and a water age spatial distribution map is formed. By combining time-series logs of user water usage behavior, abnormal water bodies in the spatial distribution map of water age can be identified.

4. The method for monitoring and early warning of water age in a water tank based on the Internet of Things according to claim 3, characterized in that, S3 includes: Obtain the spatial extent of the marked abnormal water body area and the identification of all monitoring points within it; Outside of abnormally stagnant water bodies, a set of monitoring points whose mean or median water flow velocity time series consistently exceeds a preset active threshold is selected, and the continuous spatial area covered by the monitoring point set is defined as a normally flowing water body area.

5. The method for monitoring and early warning of water age in a water tank based on the Internet of Things according to claim 3, characterized in that, S4 includes: An abnormal region data subset corresponding to an abnormal water body region and a normal region data comparison subset corresponding to a normal flowing water body region are constructed respectively. Empirical mode decomposition was performed on the one-dimensional water quality time series in the abnormal region data subset and the normal region data control subset to obtain a set of intrinsic mode functions for each. Calculate the cross-correlation coefficients of the corresponding intrinsic mode functions of abnormal stagnant water bodies and normal flowing water bodies in the same water quality dimension within a preset dominant frequency band, and construct a multidimensional coupled oscillation cross-correlation coefficient matrix; Expanding the upper triangular elements of the coupled oscillation cross-correlation coefficient matrix into an eigenvector yields vector A, representing the coupled oscillation mode in the anomalous stagnant water region, and vector B, representing the coupled oscillation mode in the normal flowing water region.

6. The method for monitoring and early warning of water age in a water tank based on the Internet of Things according to claim 5, characterized in that, Construct a subset of data from abnormal regions and a comparison subset of data from normal regions, including: From the multimodal fusion time series dataset, all monitoring points in the abnormal water body area and all monitoring points in the normal flowing water body area as a control are extracted, and all time-aligned data entries are extracted within the same preset historical analysis period. Data extracted from areas of abnormally stagnant water bodies constitute an abnormal region data subset, while data extracted from areas of normally flowing water bodies constitute a normal region data control subset.

7. The method for monitoring and early warning of water age in a water tank based on the Internet of Things according to claim 5, characterized in that, S4 further includes: Calculate the Euclidean distance between vector A and vector B, and normalize the Euclidean distance by dividing it by the product of the magnitudes of the two vectors. The final output is the spectral offset distance used to quantify the degree of anomaly.

8. The method for monitoring and early warning of water age in a water tank based on the Internet of Things according to claim 7, characterized in that, S5 includes: A first coupling oscillation threshold is preset, and the calculated spectral shift distance is compared with the first coupling oscillation threshold. When the spectral offset distance is greater than the first coupled oscillation threshold, it is determined that there is a risk of accelerated water age decay in the abnormal water body area, triggering an early warning signal for accelerated water age decay. Based on the magnitude of the spectral offset distance, the sampling frequency of the IoT sensor node cluster in the corresponding abnormal water body area is dynamically adjusted; The boundary monitoring point sensors adjacent to the abnormal water body area are activated synchronously to perform collaborative sampling, thereby forming an adaptive sampling network that provides high spatiotemporal resolution surrounding monitoring of the abnormal water body area.

9. A water tank water age monitoring and early warning method based on the Internet of Things according to claim 8, characterized in that, S6 includes: We collected enhanced multimodal fusion time-series datasets generated by the anomalous water body region and its surrounding area during multiple consecutive warning periods while the adaptive sampling network was in effect. A water age mutation prediction neural network is constructed. The input layer of the network receives a preprocessed enhanced multimodal fusion time series dataset fragment. Its network structure includes a one-dimensional convolutional layer for extracting local features, a long short-term memory network layer for capturing long-term temporal dependencies, and a fully connected layer for integration and output prediction. The abrupt events of water age values ​​in anomalous water bodies in the spatial distribution map of water age are used as supervision labels to supervise the training of the water age mutation prediction neural network. The latest enhanced multimodal fusion time series dataset obtained through the adaptive sampling network within the current time window is input into the trained water age mutation prediction neural network; The water age mutation prediction neural network outputs prediction results in two dimensions: a sequence of predicted probability values. Based on the shape of the predicted probability value sequence, the earliest possible prediction time point of water age mutation is determined and output.

10. A water tank water age monitoring and early warning system based on the Internet of Things, characterized in that, The system, which is applied to the IoT-based water tank age monitoring and early warning method as described in any one of claims 1-9, comprises: Multimodal data fusion module: Collects multimodal time-series water quality data from multiple monitoring points in the water tank, synchronously acquires time-series logs of user water usage behavior, and merges them to generate a multimodal fused time-series dataset; Water age modeling and identification module: Based on a multimodal fusion time series dataset, a dynamic water age decay model is constructed to calculate the real-time water age estimate for each monitoring point and identify abnormal water body areas; Normal flow area determination module: Based on the time-series logs of user water usage behavior, determine the normal flow water area corresponding to the abnormal water body area; Spectral offset distance calculation module: Extracts the coupled oscillation modes of the abnormally stagnant water body region and calculates their spectral offset distance from the normal flowing water body region; Early warning sampling trigger module: It performs judgment and analysis based on the calculated spectral offset distance and starts the adaptive sampling strategy; Early warning prediction push module: Based on an adaptive sampling strategy, a pre-set water age mutation prediction neural network is trained and the prediction results are output; based on the prediction results, a graded early warning instruction is generated.