Sewage detection and traceability system based on multi-source data fusion
The wastewater detection and tracing system, which integrates multi-source data, utilizes multi-modal sensors from drones to collect data and processes it in real time at the edge. Combined with cloud-based deep learning, it achieves pollution area identification, concentration quantification, and discharge outlet location, solving the efficiency and accuracy problems of wastewater detection in complex terrain and supporting precise and efficient environmental supervision.
Patent Information
- Application Number
- CN202511975573.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-25
- Publication Date
- 2026-03-17
AI Technical Summary
Existing wastewater testing technologies are inefficient and inaccurate in complex terrain, and cannot achieve closed-loop optimization of the entire process, making it difficult to meet the precision requirements of environmental supervision.
The wastewater detection and tracing system adopts multi-source data fusion, including a drone data acquisition module, an edge preprocessing module, a cloud data fusion and modeling module, and a tracing decision module. Through multi-modal sensor data acquisition, real-time edge processing, and cloud deep learning, it can achieve pollution area identification, concentration quantification, sewage outlet location, and tracing of the source path.
It enables high-precision wastewater detection and source tracing in complex terrains, improving detection efficiency and response speed, and supporting precise and efficient environmental supervision.
Smart Images

Figure CN121678960A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of water environment monitoring technology, specifically to a wastewater detection and source tracing system based on multi-source data fusion. It is applicable to decentralized wastewater discharge detection, pollutant concentration quantification, discharge outlet location, and pollution diffusion path tracing in complex terrains (such as mountains, forests, and watersheds). It can be widely used in environmental supervision, watershed management, and emergency pollution disposal scenarios. Background Technology
[0002] With rapid socio-economic development, the water environment faces increasingly severe pollution pressures. Decentralized sewage discharge (such as direct discharge of domestic sewage from farmers, illegal discharge from small-scale farms, and pollution from agricultural runoff) has become a key factor affecting water quality. Currently, water environment management is developing towards precision and efficiency, and traditional sewage detection methods are no longer sufficient to meet the monitoring needs in complex scenarios.
[0003] Currently, mainstream wastewater testing technologies are mainly divided into three categories: The first category is manual on-site sampling and testing. This method requires personnel to travel to the polluted area to collect samples and then bring them back to the laboratory for analysis. It has significant drawbacks: low efficiency, with a testing time of ≥2 hours per square kilometer; limited testing range, unable to cover mountainous areas, forests, and other areas difficult for personnel to access, resulting in large-scale blind spots; and delayed test results, failing to support timely pollution control decisions. The second category is fixed water quality monitoring stations, which achieve continuous monitoring by installing monitoring equipment at fixed locations. However, this technology is costly to build, with a single station costing ≥500,000 yuan, making large-scale deployment difficult; it can only achieve fixed-point monitoring and cannot meet the needs of large-area, mobile, and decentralized wastewater monitoring, with almost zero ability to identify concealed discharge outlets. The third category is drone-borne single-sensor detection. Existing technologies mostly use hyperspectral or infrared sensors for single-modal data acquisition, identifying polluted areas through simple spectral matching, which has three major drawbacks:
[0004] The data has a single dimension and low detection accuracy: relying on only a single modal data (such as hyperspectral data) cannot capture the multidimensional features of sewage discharge (such as abnormal temperature at the discharge outlet and topographical relationship), resulting in a recognition rate of ≤60% for hidden discharge outlets (such as underground pipes) and a pollutant concentration inversion error of ≥20%, which makes it difficult to meet the precision requirements of environmental protection supervision.
[0005] The data fusion methods are simple but lack complementarity: Existing multi-source data fusion methods mostly adopt the approach of "parallel feature extraction + direct stitching," ignoring the inherent correlation between different modalities such as hyperspectral, thermal infrared, and LiDAR data, and failing to achieve deep feature interaction. In complex environments such as cloudy days or vegetation obstruction, the detection reliability drops significantly, and the cross-scene generalization accuracy is ≤75%.
[0006] Lack of real-time source tracing and closed-loop optimization capabilities: It can only achieve qualitative judgment of "polluted area identification" and cannot complete the entire closed-loop process of "concentration quantification - discharge outlet location - source tracing path prediction". Moreover, the parameters are fixed after model training, which cannot adapt to the differences in pollution characteristics in different regions, and its adaptability to complex scenarios such as low-concentration pollution and hidden discharge is insufficient.
[0007] Delayed response and low efficiency: All detection data must be transmitted back to the cloud before processing, with inference time per square kilometer exceeding 10 seconds, and there is no mechanism for dynamically adjusting data collection strategies. Low-confidence detection results cannot be corrected in a timely manner, resulting in a pollution response time of ≥24 hours, missing the optimal treatment window. Summary of the Invention
[0008] Purpose of the invention
[0009] The purpose of this invention is to overcome the shortcomings of existing technologies and provide a wastewater detection and source tracing system based on multi-source data fusion. By constructing a full-process architecture of "multi-source data panoramic acquisition - cross-modal dynamic fusion - deep learning precise modeling - edge real-time decision-making - cloud closed-loop optimization", it achieves accurate identification of polluted areas, quantification of pollutant concentrations, high-precision positioning of sewage outlets, and dynamic tracing of pollution diffusion paths. This comprehensively improves the efficiency, accuracy, and response speed of wastewater detection in complex terrains, providing technical support for precise water environment supervision and efficient governance.
[0010] Technical solution
[0011] To achieve the above objectives, the present invention adopts the following technical solution:
[0012] A wastewater detection and source tracing system based on multi-source data fusion includes a UAV data acquisition module, an edge preprocessing module, a cloud data fusion and modeling module, a source tracing decision module, and a closed-loop optimization module. The modules work together to achieve full automation of the wastewater detection and source tracing process.
[0013] (a) Unmanned Aerial Vehicle (UAV) Data Acquisition Module.
[0014] The UAV data acquisition module is mounted on a hexacopter industrial-grade UAV and features strong payload capacity, long endurance, and good environmental adaptability, enabling stable operation in complex terrains (mountains, forests, watersheds, etc.). This module includes a multi-source sensor integration unit, a flight control unit, and a data transmission unit, used to achieve panoramic acquisition of multimodal data.
[0015] 1. Multi-source sensor integrated unit.
[0016] This unit integrates hyperspectral sensors, thermal infrared sensors, LiDAR sensors, and meteorological auxiliary sensors to collect wastewater and surrounding environmental data from four dimensions: spectrum, temperature, space, and environment, achieving full coverage of multi-dimensional features.
[0017] Hyperspectral sensor: spectral range 400-2500nm, number of bands ≥1000, spectral resolution ≤2nm, spatial resolution 1m×1m. This sensor can accurately capture the characteristic spectra of various pollutants in wastewater, such as COD, ammonia nitrogen, total nitrogen, total phosphorus, and heavy metals, providing core data support for pollutant type identification and concentration inversion.
[0018] Thermal infrared sensor: Detection wavelength 8-14μm, temperature measurement range -20℃~60℃, measurement accuracy ±0.1℃. Due to the temperature difference between wastewater discharged from sewage outlets and surrounding natural water bodies (especially industrial wastewater and aquaculture wastewater), this sensor can accurately identify concealed sewage outlets (such as underground pipes and underwater outlets) by detecting areas of temperature anomalies, thus compensating for the shortcomings of hyperspectral sensors in identifying concealed pollution.
[0019] LiDAR sensor: laser wavelength 1550nm, point cloud density ≥50 points / ㎡, ranging accuracy ±2cm. It can quickly construct a 3D terrain model of the monitoring area, accurately extracting spatial topological information such as water body boundaries, ditch connectivity, and water flow direction, providing a spatial basis for pollution source tracing path analysis.
[0020] Meteorological auxiliary sensors include light intensity sensors and rainfall sensors. The light intensity sensor has a measurement range of 0-100,000 lx and an accuracy of ±1%, used to collect real-time lighting conditions and provide environmental parameters for atmospheric correction of hyperspectral data. The rainfall sensor has a measurement range of 0-50 mm / h and an accuracy of ±0.1 mm, used to record rainfall during the monitoring period and provide data support for analyzing the impact of rainwater on pollutant dispersion.
[0021] 2. Flight control unit.
[0022] This unit is responsible for the UAV's flight attitude control, flight path planning, and obstacle avoidance, ensuring the accuracy and security of data collection.
[0023] GPS positioning module: Adopting high-precision GPS positioning technology, with a positioning accuracy of ±0.1m, it can record the spatial coordinates of sensor-collected data in real time, providing a guarantee for the spatial alignment of multi-source data and the accurate positioning of sewage outlets.
[0024] Automatic obstacle avoidance module: Integrating visual obstacle avoidance and LiDAR obstacle avoidance technology, it can identify obstacles (such as trees, mountains, and buildings) in the flight path in real time and automatically plan detour routes to avoid drone collisions and ensure flight safety.
[0025] The intelligent flight path planning module supports "monitoring area boundary import + automatic grid flight path generation." Users can import monitoring area boundary files in shapefile format, and the system automatically generates uniform grid flight paths. The flight altitude can be adaptively adjusted within the range of 50-150m according to the terrain elevation, ensuring stable spatial resolution even in complex terrain. For key pollution areas such as around villages, near farms, and downstream of industrial wastewater outlets, the system automatically generates denser flight paths (flight path spacing ≤ 20m) to increase data collection density and improve detection accuracy in these areas.
[0026] Multi-drone collaborative flight: Supports ≥3 drones to collect data in different areas at the same time. Each drone is responsible for data collection tasks in different sub-areas. The collected data is aggregated to the cloud in real time through the data transmission unit, which greatly improves the monitoring efficiency of large areas and cross-regional watersheds and is suitable for large-scale monitoring scenarios of ≥100 square kilometers.
[0027] 3. Data transmission unit.
[0028] The "edge preprocessing + 5G / satellite dual-mode transmission" model solves the problems of high latency, large data volume, and poor signal in remote areas in traditional data transmission.
[0029] Edge preprocessing: The multi-source raw data collected is initially compressed at the UAV onboard terminal. By retaining key bands (such as the characteristic spectral bands of pollutants) and feature points (such as temperature anomalies and water boundary points), the data compression ratio is ≥10:1, which greatly reduces the amount of data transmission.
[0030] Dual-mode transmission: In areas with 5G network coverage, 5G transmission technology is used, with a transmission latency of ≤10 seconds, ensuring fast data return. In mountainous areas, remote watersheds, and other areas without 5G network coverage, it automatically switches to satellite transmission mode, with a transmission latency of ≤15 seconds, ensuring continuous data transmission. It also supports breakpoint resume functionality; when transmission is interrupted, it can resume transmission from the point of interruption when the connection is restored, avoiding data loss.
[0031] (ii) Edge preprocessing module.
[0032] The edge preprocessing module is used to clean, correct, align, and perform lightweight inference on multi-source data, and to calculate detection confidence in real time. Specifically, the edge preprocessing module is deployed on an airborne edge computing terminal of an unmanned aerial vehicle (UAV) with a computing power of ≥10 TOPS. It is used to clean, correct, align, and extract features from the raw data collected by multi-source sensors, providing high-quality input data for cloud-based fusion modeling, while realizing real-time lightweight inference and confidence assessment.
[0033] 1. Preprocessing units for each modal data
[0034] We designed a dedicated preprocessing workflow to address the characteristics of data from different sensors, ensuring data quality.
[0035] Hyperspectral data preprocessing unit:
[0036] Radiometric correction: Based on the sensor response function, it eliminates systematic errors caused by differences in the sensor's own response, ensuring the accuracy of spectral data.
[0037] Atmospheric correction: The MODTRAN model is used to remove the interference of atmospheric components such as water vapor and aerosols on the spectral signal and restore the true spectral characteristics of the wastewater.
[0038] Band selection: Due to the large number of bands and the large amount of redundant information in hyperspectral data, SPA (continuous projection algorithm) combined with a pollutant characteristic wavelength library was used to select 200 key bands that are highly correlated with pollutant concentrations, and redundant bands were removed to improve the efficiency of subsequent modeling.
[0039] Spectral smoothing: SG (Savitzky-Golay) filtering with a window size of 5 is used to remove random noise from the spectral data, enhance the smoothness of the spectral curve, and improve the reliability of feature extraction.
[0040] Thermal infrared data preprocessing unit:
[0041] Temperature calibration: The thermal infrared sensor is calibrated using a blackbody radiation source to eliminate the sensor's own temperature measurement error and ensure the accuracy of the temperature data.
[0042] Background subtraction: A dynamic threshold method is adopted to adjust the background temperature threshold according to real-time terrain elevation data, subtract the influence of environmental background temperature, and highlight the abnormal temperature signal of the sewage outlet.
[0043] Spatial downsampling: By using bilinear interpolation, the spatial resolution of thermal infrared data is adjusted to be consistent with that of hyperspectral data (1m×1m), laying the foundation for spatial alignment of multi-source data.
[0044] LiDAR data preprocessing unit:
[0045] Point cloud denoising: A statistical filtering algorithm is used, with a neighboring point count of ≥10, to remove isolated noise points in the point cloud (such as points generated by birds or dust reflections) and purify the point cloud data.
[0046] Ground point extraction: A progressive morphological filtering algorithm is used to separate ground points from the point cloud and generate a digital elevation model (DEM) to provide a basis for terrain analysis.
[0047] Water body extraction: Based on elevation threshold (≤0.5m) and reflection intensity threshold (≥0.3), water body areas are extracted from point clouds to accurately identify the boundaries and ranges of water bodies such as ditches, ponds, and rivers.
[0048] Water connectivity analysis: Based on graph theory, a connected component extraction algorithm is used to analyze the connectivity relationships between different water body regions, construct a water body connectivity network, and provide support for pollution diffusion path analysis.
[0049] Calculation of terrain slope and water flow direction: The D8 algorithm is used to calculate the terrain slope and water flow direction based on the digital elevation model (DEM) to clarify the possible diffusion direction of pollutants.
[0050] Meteorological data preprocessing unit: Using the 3σ criterion, outliers (such as abnormal measurements under extreme weather conditions) in light intensity and rainfall data are removed, and standardized environmental correction parameters are output to provide a reference for the preprocessing of other modal data.
[0051] 2. Data alignment unit.
[0052] Because there are slight differences in the acquisition time and spatial location of multi-source sensors, data alignment processing is required to ensure that multi-source data at the same spatiotemporal point correspond one-to-one:
[0053] Spatial alignment: A dual calibration method of "GPS timestamp + SIFT feature point matching" is adopted. First, the multi-source data are initially matched to the same spatial grid by using GPS timestamps; then, the SIFT feature point matching algorithm is used to identify common feature points in the multi-source data (such as water body boundary points and terrain feature points) to correct spatial offset and control the spatial error within ±0.5 meters.
[0054] Time alignment: Based on the acquisition time of hyperspectral data, and considering the slight delay (≤0.1 seconds) in the acquisition of thermal infrared and LiDAR sensors, a linear interpolation algorithm is used to correct the time of the delayed data to ensure that the multi-source data acquired at the same time correspond to the same spatiotemporal scene.
[0055] 3. Lightweight inference unit at the edge.
[0056] Deploy a lightweight deep learning model optimized based on the MobileNet architecture, with ≤3 million model parameters, to ensure fast inference on edge devices with limited computing power:
[0057] Inference function: Only the functions of pollution area identification and sewage outlet coarse location are retained. The inference time is ≤0.5 seconds / frame. It can output the preliminary identification results of the pollution area and the approximate location of the sewage outlet in real time (coarse location accuracy ≤3m).
[0058] Confidence Calculation: The confidence level of the detection results is calculated in real time. When the confidence level is less than 0.7, a data re-acquisition command is automatically triggered to control the drone to reduce its flight altitude (from 100 meters to 50 meters) and increase the data acquisition density to ensure the reliability of the detection results.
[0059] (III) Cloud-based data fusion and modeling module.
[0060] The cloud-based data fusion and modeling module employs a cross-modal attention fusion network (CM-AFN) to achieve dynamic fusion of multimodal features. It uses deep learning sub-models to identify polluted areas, retrieve pollutant concentrations, and predict pollution source tracing paths. Specifically, this module is deployed on a cloud server cluster (including GPU acceleration nodes with a computing power ≥100 TOPS), possessing powerful parallel computing capabilities. It enables deep fusion of multimodal features, accurate detection of pollutants, and concentration quantification, serving as the core computing unit of the system. This module includes a multi-source data fusion unit, a deep learning modeling unit, and a model training and optimization unit.
[0061] 1. Multi-source data fusion unit.
[0062] Employing an innovative Cross-Modal Attention Fusion Network (CM-AFN), this approach breaks through the traditional "simple splicing" fusion method, achieving dynamic interactive fusion of hyperspectral, thermal infrared, and LiDAR multimodal features. It adaptively adjusts the weights of each modality based on data quality and environmental conditions, enhancing feature representation capabilities in complex environments. The specific architecture includes:
[0063] Modal feature extraction layer: Dedicated feature extraction branches are designed to address the characteristics of different modal data, ensuring the effective extraction of core features for each modality.
[0064] Hyperspectral branch: A 3-layer CNN (3×3 kernel size, stride 1, padding=1) is used, with output channels of 64, 128 and 256 respectively. Combined with the SENet channel attention mechanism, the spectral features related to pollutants are adaptively enhanced and irrelevant noise is suppressed. Finally, a spectral feature vector Fs with a dimension of 512 is extracted.
[0065] Thermal infrared branch: A 2-layer CNN (3×3 kernel size, stride 1, padding=1) is used, with 64 and 128 output channels respectively. Combined with global average pooling, global features that can reflect temperature anomalies are extracted, and finally a temperature feature vector Ft with dimension 256 is obtained.
[0066] The LiDAR branch first extracts global features of the point cloud through PointNet, then captures the spatial correlation features between water nodes through two layers of graph convolution (GCN), and finally outputs a spatial feature vector Fsp with a dimension of 256.
[0067] Cross-modal interaction layer: Enables deep interaction and dynamic weighted fusion of features from different modalities.
[0068] Attention weight calculation: Concatenate spectral features Fs, temperature features Ft, and spatial features Fsp. The input is processed by a three-layer multilayer perceptron (MLP) for nonlinear mapping. The hidden layer dimensions of the MLP are 512, 256, and 3, respectively. The output is then processed by the Softmax activation function to obtain a dynamic weight vector. Where Ws, Wt, and Wsp are the weights of spectral features, temperature features, and spatial features, respectively, satisfying the following conditions: This weight can be dynamically adjusted based on data quality. For example, when there is insufficient light on a cloudy day, the quality of hyperspectral data decreases, and the system will automatically reduce Ws and increase the weights of Wt (thermal infrared data) and Wsp (LiDAR data) to ensure the effectiveness of the fused features.
[0069] Feature weighted fusion: Based on the dynamic weight vector, the features of each modality are weighted and summed to obtain the fused feature vector F. fuse The calculation formula is: Fusion feature F fuse With 1024 dimensions, it integrates the core information of each modality and has stronger discrimination capabilities.
[0070] Feature Enhancement Layer: Residual connections and BatchNorm normalization are used to alleviate the vanishing gradient problem during deep network training. Simultaneously, feature maps of three different scales (16×16, 32×32, and 64×64) are fused to improve the model's ability to capture details of polluted regions of different sizes and concentrations, ultimately outputting a high-quality fused feature F. fuse This provides strong feature support for subsequent modeling.
[0071] 2. Deep learning modeling unit.
[0072] For the three core tasks of "polluted area identification, pollutant concentration inversion, and pollution source tracing prediction", a dedicated sub-model is constructed to achieve accurate output throughout the entire process:
[0073] Contaminated area identification sub-model: Bidirectional Attention U-Net (BA-U-Net), which solves the problem of fuzzy boundary recognition of contaminated areas in traditional U-Net and achieves pixel-level accurate recognition.
[0074] Encoder: ResNet50 is used as the backbone network, which has powerful feature extraction capabilities and can extract multi-scale contamination features. After the output feature map of each layer of the encoder, an attention gate is added. By learning the importance weights of different regions, effective information related to contamination is filtered out, and interference from background noise is suppressed.
[0075] Decoder: Upsamples the low-resolution feature map output by the encoder using transposed convolutions (2×2 kernel size, stride 2) to restore the spatial resolution of the feature map. Simultaneously, skip connections are used to fuse the feature maps from each layer of the encoder with the corresponding feature maps from the decoder, preserving detailed information in shallow features (such as the boundaries of contaminated areas). To further improve boundary recognition accuracy, a boundary refinement module is added. This module consists of a 3×3 convolution layer and Sobel edge detection, capable of accurately capturing the boundary contours of contaminated areas.
[0076] Loss Function: Since the contaminated area accounts for a very small proportion of the entire monitoring area (usually <5%), there is a serious sample imbalance problem. A weighted fusion of Dice loss and cross-entropy loss in a 7:3 ratio is used as the loss function. Dice loss effectively mitigates the impact of sample imbalance, while cross-entropy loss improves the model's classification accuracy. The combination of the two ensures the model's accurate identification of contaminated areas.
[0077] Output results: Binary map of the polluted area (pixel-level accuracy) and recognition confidence level. The pixel-level recognition accuracy reaches 97%, and the boundary positioning error is ≤0.5 meters.
[0078] Pollutant concentration inversion sub-model: Attention-enhanced CNN-LSTM hybrid model, achieving "pollution type adaptive" concentration inversion, significantly improving concentration prediction accuracy:
[0079] CNN branch: Input fused feature map, extract the spatial distribution features of pollutants (such as concentration gradient and spatial aggregation pattern) through 3 layers of convolution (convolution kernel size 3×3, stride 1, padding=1), and then reduce the feature dimension through 1 layer of max pooling (pooling kernel size 2×2) to retain key spatial information.
[0080] LSTM branch: The 200 key bands selected by the hyperspectral sensor are arranged into a 200-dimensional sequence according to wavelength, and input into a 2-layer LSTM network (hidden layer dimension 256). The LSTM network can effectively capture the temporal dependence of the spectral curve (i.e. the correlation features between different bands) and mine the deep information related to pollutant concentration in the spectral data.
[0081] The fusion prediction layer fuses the spatial features extracted by the CNN branch and the temporal features extracted by the LSTM branch through a fully connected layer, employing a "multi-level output" strategy: first, a softmax classifier predicts the pollution type (domestic sewage / livestock wastewater / agricultural runoff / industrial wastewater), and then, based on the pollution type, it calls the corresponding concentration inversion sub-model (built based on the fully connected layer) to accurately output the concentration values of pollutants such as COD, ammonia nitrogen, total nitrogen, and total phosphorus. To prevent model overfitting, Dropout (dropoutrate=0.3) and L2 regularization (λ=0.001) are used for regularization.
[0082] Output results: Pollutant type and corresponding concentration value, concentration inversion error ≤5%, accuracy ±1mg / L.
[0083] Pollution source tracing path prediction sub-model: A graph neural network + fluid dynamics coupled model to achieve accurate prediction of pollution source tracing paths and dynamic simulation of pollution diffusion range.
[0084] Water body topology graph construction: Using water body nodes extracted by LiDAR (intersections of ditches, ponds, potential sewage outlets, etc.) as vertices and water flow direction as edges, an undirected graph G=(V,E) is constructed. Vertex attributes include the pollution concentration and terrain slope of the node, while edge attributes include water flow velocity and distance between nodes.
[0085] Graph Neural Network (GNN): Employs a 2-layer Graph Attention Network (GAT). GAT can learn the propagation probability of pollutants between different water body nodes by calculating the attention coefficients between nodes, focusing on the key paths of pollution propagation.
[0086] Fluid dynamics constraints: incorporating simplified Saint-Venant equations: The propagation probability learned by GNN is corrected to make the source tracing path conform to the actual water flow movement law, thus avoiding the problem of pure data-driven model being out of touch with the actual physical scene.
[0087] In the above Saint-Venant equation, h: water depth (unit: m), refers to the actual water depth at a certain spatial location x at time t, which is calculated by combining the terrain data collected by the LiDAR sensor with the water extraction algorithm. It is the core geometric parameter describing the movement of water flow.
[0088] t: Time (unit: s), refers to a specific moment in the process of water flow, used to characterize the dynamic changes of water depth and water flow speed over time;
[0089] u: Water flow velocity (unit: m / s), refers to the actual flow velocity of water at time t and location x, which is obtained through water body connectivity analysis and terrain slope calculation, and reflects the intensity of water flow.
[0090] x: Spatial position (unit: m), refers to the one-dimensional spatial coordinates along the direction of water flow, used to locate the specific position of water flow;
[0091] uh: Unit width flow rate (unit: m) 2 The volumetric flow rate ( / s), which is the volumetric flow rate per unit width, is a direct representation of the intensity of water flow and is obtained by multiplying the water flow velocity u by the water depth h.
[0092] ∂h / ∂t: The partial derivative of water depth with respect to time, which represents the rate of change of water depth over time. A positive value indicates that the water depth at that location increases with time, while a negative value indicates that the water depth decreases with time.
[0093] ∂(uh) / ∂x: The partial derivative of unit width flow rate with respect to spatial location, which characterizes the rate of change of unit width flow rate along the direction of water flow and reflects the convergence or dispersion of water flow in space;
[0094] q: Source / sink term (unit: m / s), used to characterize the intensity of water supply or discharge. A positive value indicates that there is water supply at the location (such as rainfall, tributary inflow), and a negative value indicates that there is water discharge at the location (such as sewage discharge from a sewage outlet, tributary outflow). It is a key parameter for determining the location of sewage outlets in pollution source tracing.
[0095] Output results: 1-3 most likely sewage outlets (including confidence level), pollution source tracing path map (including propagation direction, key nodes, and confidence level), and pollution spread range prediction map for the next 12 hours.
[0096] 3. Model training optimization unit.
[0097] Employing a dynamic adaptive training mechanism improves the model's generalization ability and training efficiency while reducing local deployment costs.
[0098] Multi-Scenario Sample Library: A large-scale sample library covering 5 typical terrain types (mountainous areas, plains, wetlands, watersheds, and suburban areas), 4 pollution types (domestic sewage, aquaculture wastewater, agricultural runoff, and industrial wastewater), and 3 environmental conditions (sunny / cloudy / rainy days) across the country is constructed, with a sample size of ≥100,000 sets. Each sample set includes multi-source sensor data (hyperspectral, thermal infrared, LiDAR, and meteorological data), measured water quality data (COD, ammonia nitrogen, total nitrogen, and total phosphorus concentrations, etc.), and terrain parameters (slope, water flow direction, etc.) to ensure the diversity and representativeness of the samples.
[0099] Sample augmentation: To further expand sample diversity and improve model robustness, three sets of formulas are used in synergy to achieve sample augmentation:
[0100] Spectral perturbation: Gaussian noise is added to simulate spectral changes under different lighting conditions. The formula is as follows: S disturbed S is the perturbed spectral vector. rawLet N(0,σ) be the original spectral vector, ϵ∈[0,0.05] be the noise intensity coefficient, and N(0,σ) be the noise intensity coefficient. 2 () is a variable with a mean of 0 and a variance of σ. 2 =0.01 Gaussian noise.
[0101] Spatial deformation: This simulates the spatial resolution differences caused by variations in the drone's flight altitude through random scaling, as shown in the formula: , where k∈[0.8,1.2] is the scaling factor.
[0102] In the above formula, x and y are the original pixel coordinates, which correspond to the original position coordinates of a feature point on the two-dimensional image plane in the data collected by multi-source sensors (such as hyperspectral and LiDAR sensors). They are the initial coordinate data without scale adjustment.
[0103] x' and y' are the pixel coordinates after deformation, which refer to the new position coordinates of the feature point on the two-dimensional image plane after scaling transformation. They are used to simulate the spatial resolution difference caused by the change of drone flight altitude and ensure that the sample covers the feature performance at different scales.
[0104] k: Scaling factor, with a value range of [0.8, 1.2]. When k < 1, it means that the original image is reduced in size, and when k > 1, it means that the original image is enlarged. This factor enables dynamic adjustment of the spatial scale, expands the spatial diversity of the samples, and improves the model's ability to adapt to data at different flight altitudes.
[0105] Temperature simulation: Temperature changes at different times and for different sewage discharge types are simulated by adding a temperature offset. The formula is as follows: T simulated The simulated temperature value, T raw The original temperature value is ΔT, where ΔT∈[0.5,2] is the temperature offset.
[0106] Online Hard Sample Mining (OHEM): During model training, difficult-to-classify samples (such as low-concentration pollution areas, hidden sewage outlets, and pollution areas hidden by vegetation) are automatically screened. The criterion for judging difficult-to-classify samples is a prediction confidence score < 0.5. The training weight of difficult-to-classify samples is set to 3 times that of ordinary samples, so that the model focuses on complex scenarios during training and improves its adaptability to complex situations.
[0107] Incremental learning: After model deployment, as monitoring data accumulates, the system automatically triggers incremental training every 1000 new samples collected. Incremental training only updates the parameters of the fully connected layers and attention layers of the model, without retraining the entire model. Training time is ≤1 hour, ensuring that the model can quickly adapt to new contamination features.
[0108] Transfer learning: The pre-trained model is trained on a nationally recognized sample database, giving it strong adaptability. When deployed locally, only 500 local samples are needed to fine-tune the pre-trained model, with fine-tuning taking ≤12 hours. This allows the model to adapt to local pollution types and terrain features, significantly reducing the cost of local sample collection and deployment time.
[0109] (iv) Source tracing decision module.
[0110] The source tracing decision-making module is used to generate visualized reports, automatically dispatch accountability work orders, and interface with the blockchain platform and environmental big data platform. Specifically, the source tracing decision-making module is responsible for transforming the results of cloud-based modeling into actionable regulatory decisions, realizing the visualized presentation of test results, the automatic generation of accountability work orders, and the synchronization of data across multiple platforms. It serves as a bridge connecting technical monitoring and actual supervision. This module includes a result visualization unit, a work order generation unit, and a data synchronization unit.
[0111] 1. Results visualization unit.
[0112] Generates intuitive and detailed 3D visualization reports, supporting access from different terminals, allowing regulatory personnel to quickly grasp the pollution situation:
[0113] 3D visualization content:
[0114] 3D map of polluted areas: Based on the 3D terrain model, a thermal layer of pollutant concentration is overlaid, and the area is divided into four levels according to COD concentration (green ≤50mg / L, yellow 50-80mg / L, orange 80-150mg / L, red ≥150mg / L), which intuitively shows the distribution range and severity of pollution in the polluted area.
[0115] Sewage outlet location marking: The location of sewage outlets is accurately marked on a 3D map. The marking information includes the coordinates of the sewage outlet (accuracy ±1.5m), pollution type (domestic sewage / livestock wastewater / agricultural runoff / industrial wastewater), confidence level, temperature anomalies and other key information.
[0116] Pollution source tracing path map: It shows the direction of pollutant spread in the form of arrows, marks the key nodes in the spread path (such as the intersection of ditches and ponds) and the confidence level of each node, and clearly presents the trajectory of pollution spread.
[0117] Pollution diffusion early warning map: Based on the output of the pollution source tracing path prediction sub-model, it shows the diffusion range of pollutants in the next 12 hours, providing early warning for emergency response.
[0118] Terminal support: Supports real-time viewing on mobile devices (phones / tablets) and PCs. The visual report has zoom in, zoom out, and pan functions. Users can click on any point to view detailed data, such as the spectral curve, pollutant concentration value, terrain parameters, temperature data, etc. of that point.
[0119] 2. Work order generation unit.
[0120] Based on pollutant concentration data, tiered accountability work orders are automatically generated to ensure precise implementation of regulatory responsibilities.
[0121] Work order classification:
[0122] Level 1 Warning Work Order: When COD ≥ 150 mg / L, ammonia nitrogen ≥ 10 mg / L, total nitrogen ≥ 15 mg / L, or total phosphorus ≥ 2 mg / L, a Level 1 warning is triggered, and the corresponding work order requires the responsible party to complete the rectification within 24 hours.
[0123] Level 2 warning work order: When COD∈[80,150)mg / L or ammonia nitrogen∈[5,10)mg / L or total nitrogen∈[8,15)mg / L or total phosphorus∈[1,2)mg / L, a Level 2 warning is triggered, and the corresponding work order requires the responsible party to complete the rectification within 72 hours.
[0124] Work order content: The work order includes the coordinates of the sewage outlet (accuracy ±1.5m), pollution type, detailed concentration data, rectification technical requirements (such as installing sewage pretreatment equipment, connecting to the sewage pipe network, etc.), grid member contact information, etc., to ensure that the responsible party clearly understands the rectification direction.
[0125] Work order flow: Work orders are automatically pushed to the mobile APP of the local environmental grid member, supporting a closed-loop record of the entire process of work order reception, rectification process photo upload, rectification result feedback, and grid member review, ensuring that the rectification work is implemented effectively.
[0126] 3. Data synchronization unit.
[0127] Achieve seamless integration with multiple regulatory and responsible entity platforms to build a full-chain regulatory system:
[0128] Connecting with the blockchain accountability platform: Key information such as the coordinates of the sewage outlet, pollution detection data, work order records, and rectification results are uploaded to the consortium blockchain. By leveraging the immutability of blockchain technology, the authenticity and integrity of the data are ensured, enabling traceability of pollution responsibility and providing solid data support for subsequent accountability.
[0129] Connect with the environmental protection supervision big data platform: Output test results in the standard format prescribed by the environmental protection department, incorporate the data into the regional water environment quality assessment system, and provide data support for environmental policy formulation and regional water environment governance planning.
[0130] Connect with the farmer's mini-program: Push pollution alerts, rectification guidance videos, and similar compliance cases to the responsible parties with excessive emissions (such as farmers and small-scale breeders) to help them quickly master rectification methods and improve rectification efficiency; at the same time, support the responsible parties to consult on rectification technical issues online, forming a positive interaction of "monitoring-reminder-guidance-rectification".
[0131] (v) Closed-loop optimization module.
[0132] The closed-loop optimization module dynamically adjusts the data acquisition strategy and model parameters based on the confidence assessment results, achieving real-time closed-loop optimization. Specifically, this module is crucial for ensuring the system's detection accuracy and reliability. By dynamically adjusting the data acquisition strategy and model parameters in real time based on the confidence level of the detection results, it achieves real-time closed-loop optimization of "data acquisition - model inference - result feedback - data re-acquisition". This module includes a confidence assessment unit and a dynamic adjustment unit.
[0133] 1. Confidence assessment unit.
[0134] Real-time calculation of prediction confidence for the three core tasks (pollution area identification, pollutant concentration retrieval, and pollution source tracing prediction) provides a basis for judgment in closed-loop optimization:
[0135] Polluted area identification confidence level: calculated based on the predicted probability distribution output by the model, with a threshold of 0.7. When the confidence level is ≥0.7, the polluted area identification result is considered reliable; when the confidence level is <0.7, it indicates that the pollution characteristics of the area are unclear and further data collection is needed.
[0136] Pollutant concentration inversion confidence level: calculated based on the variance of the model prediction, with a threshold of 0.8. The smaller the variance, the less uncertainty the model has in predicting concentration, and the higher the confidence level; when the confidence level is <0.8, it indicates that the reliability of the concentration prediction results is insufficient.
[0137] Source tracing path confidence: Calculated based on the maximum propagation probability output by the graph neural network (GNN), with a threshold of 0.85. The higher the maximum propagation probability, the stronger the certainty of the source tracing path; when the confidence level is <0.85, it indicates that there is significant uncertainty in the source tracing path.
[0138] 2. Dynamic adjustment unit.
[0139] When the confidence level of any core task falls below the corresponding threshold, the following adjustment strategy is automatically triggered to ensure the reliability of the detection results:
[0140] Data reacquisition: Commands are sent to the UAV data acquisition module to adjust flight parameters: the flight altitude is reduced from 100 meters to 50 meters to improve the spatial resolution of the data; the flight path spacing is reduced from 50 meters to 20 meters to increase the data acquisition density. The UAV reacquires multi-source data for the area according to the adjusted parameters, providing richer and more accurate input for the model.
[0141] Model parameter fine-tuning: The attention weight coefficients of the lightweight model are fine-tuned in real time at the edge. For example, for areas covered by vegetation, the weights of thermal infrared and LiDAR features are appropriately increased to improve the detection accuracy of local areas.
[0142] Manual intervention prompt: If the confidence level is still lower than the corresponding threshold after data re-collection, it indicates that the pollution situation in the area is complex (such as the existence of multiple hidden sewage outlets, extremely low pollutant concentrations, etc.). The system will automatically push a manual verification prompt to the mobile APP of the local environmental grid member, attaching detailed location information and preliminary test results of the area, so that the grid member can conduct on-site verification to ensure that the test results are complete and without deviation.
[0143] Beneficial effects
[0144] Compared with the prior art, the present invention has the following significant advantages:
[0145] This invention achieves comprehensive detection dimensions, overcoming the limitations of single-modal methods. It integrates multi-source data from hyperspectral, thermal infrared, LiDAR, and meteorological sources to capture four-dimensional information on wastewater: spectral characteristics, temperature anomalies, spatial topology, and environmental impact. This completely solves the problem of traditional single sensors being unable to identify concealed sewage outlets. By using thermal infrared sensors to detect temperature anomalies and LiDAR sensors to construct spatial topology, the identification rate of concealed sewage outlets is improved compared to existing technologies. The addition of water connectivity analysis and 3D terrain modeling provides a solid spatial foundation for pollution source tracing, enabling precise reverse tracking "from the polluted area to the sewage outlet," and improving the matching accuracy of the source tracing path.
[0146] Deepening data fusion enhances adaptability to complex environments. An innovative Cross-Modal Attention Fusion Network (CM-AFN) is proposed, achieving deep interaction of multimodal features through dynamic weight allocation, rather than the traditional simple splicing. This fusion mechanism can adaptively adjust the weights of each modality based on data quality and environmental conditions (e.g., increasing hyperspectral weights on sunny days and thermal infrared and LiDAR weights on cloudy days). This ensures that the system maintains a high level of detection accuracy even in complex environments such as cloudy days and vegetation obstruction, far exceeding traditional methods. Improved cross-scene generalization accuracy allows it to adapt to monitoring needs across different terrains and pollution types.
[0147] Quantifying detection accuracy and achieving precise output throughout the entire process: Pollution area identification adopts a bidirectional attention U-Net (BA-U-Net), which achieves extremely high pixel-level recognition accuracy and small boundary positioning error through attention gating and boundary refinement modules, an improvement over traditional U-Net; Pollutant concentration inversion adopts a "type adaptive" strategy, combining the advantages of CNN and LSTM, reducing concentration inversion error from existing technologies, and can accurately output specific values of key indicators such as COD, ammonia nitrogen, total nitrogen, and total phosphorus; Discharge outlet positioning integrates multi-source features (spectral, temperature, spatial), improving positioning accuracy and fully meeting the "precise accountability" requirements of environmental protection supervision.
[0148] Real-time decision-making and response shorten the handling cycle. The collaborative architecture of "lightweight inference at the edge + deep modeling in the cloud" enables the edge to quickly complete the coarse identification of polluted areas and realize real-time early warning; the cloud quickly completes concentration inversion and source tracing, and the inference efficiency is improved compared with traditional methods; the closed-loop optimization module realizes real-time adjustment of "data collection-inference-feedback-re-collection", ensuring that low confidence results are corrected in a timely manner, shortening the pollution handling response time, enabling rapid response to emergency pollution events, and reducing the risk of pollution spread.
[0149] Intelligent training optimization reduces deployment costs by employing a dynamic adaptive training mechanism that integrates multi-scenario sample libraries, online hard sample mining, incremental learning, and transfer learning technologies. For local deployment, there's no need to collect massive amounts of local samples; only a small number of local samples are required for fine-tuning to adapt the model to the local environment, reducing sample collection costs. Lightweighting the model compresses parameters, improving inference speed and enabling it to adapt to the limited computing power of drone-borne edge terminals without requiring additional hardware upgrades, significantly reducing system deployment and maintenance costs.
[0150] With a wide range of applications and adaptability to diverse regulatory needs, this invention can cover complex terrains such as mountains, plains, wetlands, and watersheds. It is suitable for diverse scenarios such as decentralized sewage monitoring, watershed management, black and odorous water body investigation, and emergency pollution disposal. It supports multi-machine collaborative detection and can meet the monitoring needs of cross-regional watersheds with an area of more than 100 square kilometers. It can be seamlessly connected with blockchain accountability platforms, environmental big data platforms, and farmer-end mini-programs to form a full-chain regulatory system of "detection-source tracing-accountability-rectification". It provides comprehensive technical support for different users such as environmental regulatory departments, watershed management agencies, and grassroots grid workers, and has broad application prospects. Attached Figure Description
[0151] To more clearly illustrate the technical solution of the present invention, the following description is provided in conjunction with the accompanying drawings:
[0152] Figure 1 This is a diagram of the overall system architecture of the present invention;
[0153] Figure 2 A flowchart for predicting pollution source tracing pathways;
[0154] Figure 3 This is a flowchart of the system operation of the present invention. Detailed Implementation
[0155] To make the technical solution of the present invention clearer and easier to understand, the present invention will be described in detail below with reference to specific embodiments:
[0156] (a) Implementation scenarios.
[0157] This embodiment selects a mountainous watershed as the monitoring target. The watershed covers an area of 50 square kilometers and includes complex terrain such as woodlands, slopes, and scattered villages. Problems exist in the area, including direct discharge of domestic sewage from farmers and illegal discharge from small-scale farms. Traditional manual detection suffers from large blind spots due to the complex terrain, making comprehensive monitoring impossible. Therefore, a precise and efficient sewage detection and source tracing solution is urgently needed.
[0158] (ii) System deployment and parameter configuration.
[0159] 1. Deployment of UAV data acquisition module.
[0160] Drone selection: Hexacopter industrial-grade drone with a payload of 3.5kg and a flight time of 65 minutes. It has strong load capacity and endurance, and can meet the single monitoring needs of a 50 square kilometer watershed.
[0161] Sensor parameter configuration:
[0162] Hyperspectral sensor: spectral range 400-2500nm, 1200 bands, spectral resolution 1.8nm, spatial resolution 1m×1m;
[0163] Thermal infrared sensor: detection band 8-14μm, temperature measurement range -20℃~60℃, accuracy ±0.1℃;
[0164] LiDAR sensor: laser wavelength 1550nm, point cloud density 60 points / ㎡, ranging accuracy ±2cm;
[0165] Meteorological auxiliary sensors: light intensity sensor (measurement range 0-100000lx, accuracy ±1%), rainfall sensor (measurement range 0-50mm / h, accuracy ±0.1mm).
[0166] Flight planning: Upload the boundary file of the mountainous watershed in shp format. The system will automatically generate a grid flight path with a flight altitude of 100 meters and a flight path spacing of 50 meters. At the same time, it will preset dense flight paths for key areas (around villages and near farms) with a flight path spacing of 20 meters.
[0167] 2. Edge and cloud module deployment.
[0168] Edge computing terminal: UAV-borne edge computing terminal with a computing power of 12 TOPS, deploying a lightweight model based on MobileNet architecture optimization, with a confidence threshold set to 0.7.
[0169] Cloud-based: A cloud server cluster with 4 GPU acceleration nodes and a total computing power of 120 TOPS, deploying a cross-modal attention fusion network (CM-AFN), a bidirectional attention U-Net (BA-U-Net), an attention-enhanced CNN-LSTM hybrid model, and a graph neural network + fluid dynamics coupled model.
[0170] Data transmission: 5G transmission is used in areas within the basin with 5G network coverage, with a transmission delay of 8 seconds; remote mountainous areas without 5G network coverage automatically switch to satellite transmission, with a transmission delay of 15 seconds, and support for resume transmission.
[0171] 3. Configuration of the source tracing decision and closed-loop optimization module.
[0172] Visualization platform: Supports access from PC (used by environmental regulatory departments) and mobile (used by grid workers and responsible entities), with 3D maps overlaid with concentration thermal layers, sewage outlet markers, source tracing paths, and diffusion early warning maps.
[0173] Work order classification: Level 1 warning (COD≥150mg / L or ammonia nitrogen≥10mg / L or total nitrogen≥15mg / L or total phosphorus≥2mg / L), Level 2 warning (COD80-150mg / L or ammonia nitrogen5-10mg / L or total nitrogen8-15mg / L or total phosphorus1-2mg / L).
[0174] Closed-loop optimization thresholds: 0.7 confidence level for pollution area identification, 0.8 confidence level for concentration inversion, and 0.85 confidence level for source tracing.
[0175] (III) Implementation steps.
[0176] 1. Data collection phase.
[0177] The drone takes off along a preset route, and multiple sensors simultaneously collect hyperspectral, thermal infrared, LiDAR, and meteorological data. During flight, the automatic obstacle avoidance module identifies obstacles such as mountains and trees in real time and automatically plans detour routes to ensure flight safety.
[0178] The edge preprocessing module performs real-time preprocessing on the raw data: hyperspectral data undergoes radiometric correction, atmospheric correction, band selection (screening 200 key bands), and spectral smoothing; thermal infrared data undergoes temperature calibration, background subtraction, and spatial downsampling (aligned to 1m×1m); LiDAR data undergoes point cloud denoising, ground point extraction, water body extraction, water connectivity analysis, and topographic slope and water flow direction calculation; meteorological data undergoes outlier removal. The preprocessed data compression ratio is 15:1, and core data is transmitted back to the cloud in real time.
[0179] The lightweight edge model performs real-time inference and detects pollution in the ditch area on the east side of the village with a confidence level of 0.65 (below the threshold of 0.7), automatically triggering a data re-collection command. After receiving the command, the drone lowers its flight altitude to 50 meters and re-collects multi-source data for the area using a denser flight path with 20-meter intervals.
[0180] 2. Cloud-based integration and modeling stage.
[0181] The cloud receives multi-source data (including initial and re-collected data) from the edge devices and performs feature fusion through a cross-modal attention fusion network (CM-AFN).
[0182] The modal feature extraction layer extracts spectral features Fs (dimension 512), temperature features Ft (dimension 256), and spatial features Fsp (dimension 256), respectively.
[0183] Cross-modal interaction layer for splicing features Perform a nonlinear mapping to calculate the dynamic weights. (Due to vegetation obstruction in the area, the quality of hyperspectral data was affected, so the system automatically increased the weights of thermal infrared and LiDAR features.)
[0184] According to the formula The fusion feature F was calculated. fuse (Dimension 1024), after processing by the feature enhancement layer, high-quality fused features are output.
[0185] The pollution area identification sub-model (BA-U-Net) processes the fused features and outputs a binary map of the pollution area with an accuracy of 97.5% and a boundary error of 0.3 meters, clearly outlining the pollution range of the ditch on the east side of the village.
[0186] The pollutant concentration inversion sub-model first uses a softmax classifier to determine the pollution type as "mixed pollution of domestic sewage and aquaculture wastewater," then calls the corresponding concentration inversion sub-model, outputting COD concentration of 162 mg / L, ammonia nitrogen concentration of 11.3 mg / L, and total phosphorus concentration of 3.8 mg / L. Subsequent field sampling verification showed that the concentration inversion error was 4.2%, meeting the accuracy requirements.
[0187] The pollution source tracing path prediction sub-model constructs a water body topology map based on water body nodes extracted by LiDAR, incorporates the simplified Saint-Venant equation (measured water depth h=0.8m, water flow velocity u=0.3m / s, source-sink term q=-0.02m / s, negative indicates sewage discharge) to correct the propagation probability, outputs 3 most likely sewage outlets with confidence levels of 0.92, 0.88 and 0.81, and predicts that the pollution will spread downstream along the ditch for about 2 kilometers in the next 12 hours.
[0188] 3. Source tracing decision-making and closed-loop stage.
[0189] The results visualization unit generates a 3D visualization report, which accurately marks the coordinates (118°XX′XX.XX″E, 32°XX′XX.XX″N), pollution type (mixed pollution of domestic sewage and aquaculture wastewater), concentration data and source tracing path of the three sewage outlets on the 3D map. It also overlays a concentration thermal layer (the COD concentration in this area is 162mg / L, which is displayed in red) and a pollution diffusion early warning map for the next 12 hours.
[0190] The work order generation unit automatically generates a Level 1 early warning work order based on the concentration data (COD ≥ 150 mg / L, ammonia nitrogen ≥ 10 mg / L). The work order includes the coordinates of the discharge outlet, pollution type, concentration data, rectification requirements (rectification to be completed within 24 hours), and contact information of the grid member, and is automatically pushed to the mobile APP of the local environmental grid member.
[0191] After receiving the work order, the grid worker arrived at the site within 2 hours to verify the information. They confirmed that the three sewage outlets were two direct discharge outlets for domestic sewage from two farmers and one illegal discharge outlet from a small farm. They took photos of the current situation and uploaded them to the blockchain platform to ensure that the verification data could not be tampered with.
[0192] After receiving pollution alerts, rectification guidance videos, and compliance case studies pushed by the farmers' mobile app, the responsible parties must complete the rectification within 24 hours: installing mini sewage pretreatment boxes to connect domestic sewage and livestock wastewater to the village's sewage network. After verification by grid workers, water samples were collected, and test results showed that COD concentration decreased to 48 mg / L, ammonia nitrogen concentration decreased to 3.2 mg / L, and total phosphorus concentration decreased to 0.8 mg / L, all meeting standards and forming a closed loop.
[0193] The data synchronization unit synchronizes the detection data, work order records, and rectification results to the environmental protection supervision big data platform, providing data support for the water environment quality assessment of the region; at the same time, it permanently stores the relevant information on the blockchain accountability platform to achieve traceability of responsibility.
[0194] (iv) Example of implementation effect verification.
[0195] To verify the effectiveness of this invention, the system of this invention was compared with traditional detection methods. The verification indicators and results are shown in the table below:
[0196] Validation metrics Traditional methods Effects of this invention Increase Time required for detection per square kilometer ≥2 hours ≤30 minutes 75% Hidden sewage outlet identification rate ≤60% 92% 53.3% Pollutant concentration inversion error ≥20% 4.2% 79% Source tracing path matching degree 70% 92% 31.4% Pollution response time ≥24 hours 3 hours 87.5%
[0197] As shown in the table above, the system of the present invention has significantly improved the detection efficiency, detection accuracy and response speed compared with traditional methods, and can effectively solve the technical problems of decentralized sewage detection and source tracing in complex terrain.
[0198] Compared with existing technologies, the advantages and effects of this invention are as follows:
[0199] Innovation in cross-modal dynamic fusion mechanism: A cross-modal attention fusion network (CM-AFN) is proposed, which uses a dynamic weight calculation formula... and feature fusion formula It enables deep interaction and dynamic weighted fusion of multimodal features, solving the problems of poor fusion effect and weak adaptability to complex environments in traditional "simple splicing" methods, and improving detection accuracy in complex environments.
[0200] Deep learning sub-model structure innovation: Dedicated sub-models are designed for the three core tasks - Bidirectional attention U-Net (BA-U-Net) solves the problem of blurred boundaries of polluted areas, attention-enhanced CNN-LSTM hybrid model realizes "type-adaptive" concentration inversion, graph neural network + fluid dynamics coupled model improves the accuracy of source tracing path, reduces concentration inversion error and improves the accuracy of sewage outlet positioning.
[0201] Innovative Sample Augmentation Strategies: A collaborative sample augmentation strategy including spectral perturbation, spatial deformation, and temperature simulation is proposed, especially the temperature simulation formula. By simulating temperature changes across the entire scene with a controllable temperature offset of 0.5-2℃, the model's adaptability to temperature changes can be improved without the need for a large number of real temperature samples, thus improving the detection accuracy under temperature interference.
[0202] Edge-cloud collaboration and closed-loop optimization innovation: Construct a collaborative architecture of "lightweight inference at the edge + deep modeling in the cloud", enabling rapid inference at the edge and rapid and accurate modeling in the cloud; Combine confidence assessment and dynamic adjustment strategies to achieve a real-time closed loop of "data collection-inference-feedback-recollection", shortening the response time for pollution treatment.
[0203] Innovative training optimization mechanism: A dynamic adaptive training scheme is proposed, which combines multi-scenario sample library, online hard sample mining, incremental learning, and transfer learning. Local deployment only requires 300-600 sets of local samples for fine-tuning, reducing sample collection costs and improving cross-scenario generalization accuracy.
[0204] Multi-platform collaboration and application expansion innovation: Achieve seamless integration with blockchain accountability platforms, environmental supervision big data platforms, and farmer-end mini-programs to form a full-chain supervision system of "detection-source tracing-accountability-rectification", adapt to diverse environmental supervision needs under complex terrain, and provide comprehensive technical support for precise water environment management.
[0205] Through the above-mentioned innovations, this invention breaks through the bottlenecks of traditional wastewater detection technology, which is characterized by "single dimension, low accuracy, slow response, and poor generalization". It provides a brand-new technical solution for the precise monitoring of water environment in complex terrain, and has significant technological progress and broad application prospects.
[0206] The embodiments described above are merely examples of several implementations of the present invention, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the present invention, and these modifications and improvements all fall within the scope of protection of the present invention.
Claims
1. A sewage detection and tracing system based on multi-source data fusion, characterized in that, The unmanned aerial vehicle data acquisition module, the edge end preprocessing module, the cloud data fusion and modeling module, the traceability decision module and the closed-loop optimization module are included, and each module cooperates to realize the automatic detection and traceability of sewage. The unmanned aerial vehicle data acquisition module is equipped with a multi-source sensor integration unit, a flight control unit and a data transmission unit. The edge end preprocessing module is used for cleaning, correcting, aligning and lightweight reasoning of multi-source data, and real-time calculation of detection confidence. The cloud data fusion and modeling module adopts a cross-modal attention fusion network CM-AFN to realize dynamic fusion of multi-modal features, and completes pollution area identification, pollutant concentration inversion and pollution traceability path prediction through a deep learning submodel. The traceability decision module is used for generating a visual report, automatically dispatching a responsibility work order, and interfacing with a blockchain platform and an environmental protection big data platform. The closed-loop optimization module dynamically adjusts data acquisition strategies and model parameters according to confidence evaluation results, and realizes real-time closed-loop optimization. The model training optimization unit of the cloud data fusion and modeling module adopts a sample augmentation strategy, which includes a temperature simulation formula, as follows: In the formula, T simulated The simulated temperature value, T raw The original temperature value is given, and ΔT is the temperature offset, where ΔT ∈ [0.5, 2].
2. The sewage detection and tracing system based on multi-source data fusion according to claim 1, characterized in that, The edge end preprocessing module includes a hyperspectral data preprocessing unit, a thermal infrared data preprocessing unit and a LiDAR data preprocessing unit. The hyperspectral data preprocessing unit sequentially performs radiation correction, atmospheric correction, band selection and spectral smoothing. The thermal infrared data preprocessing unit sequentially performs temperature calibration, background subtraction and spatial downsampling. The LiDAR data preprocessing unit sequentially performs point cloud denoising, ground point extraction, water body extraction, water body connectivity analysis and terrain slope and water flow direction calculation.
3. The sewage detection and tracing system based on multi-source data fusion according to claim 2, characterized in that, The cross-modal attention fusion network CM-AFN includes a modal feature extraction layer, a cross-modal interaction layer and a feature enhancement layer. In the modal feature extraction layer, the hyperspectral branch adopts a 3-layer CNN with a convolution kernel size of 3×3, a step of 1 and padding=1, and the output channel numbers are 64, 128 and 256, respectively. The cross-modal interaction layer adopts a cross-modal attention mechanism to realize the interaction between different modal features. The feature enhancement layer adopts a 2-layer CNN with a convolution kernel size of 3×3, a step of 1 and padding=1, and the output channel numbers are 128 and 256, respectively. The thermal infrared branch adopts a 2-layer CNN, the convolution kernel size is 3*3, the step is 1, padding=1, the output channel number is 64 and 128 respectively, and a global average pooling is combined to extract a temperature feature Ft with a dimension of 256; The LiDAR branch adopts a PointNet to extract a global feature of a point cloud and then combines a 2-layer GCN to extract a spatial feature Fsp with a dimension of 256; The cross-modal interaction layer performs nonlinear mapping on the spliced features Fs⊕Ft⊕Fsp by a 3-layer MLP, the hidden layer dimensions of the MLP are 512, 256 and 3 respectively, and the dynamic weight is output by a Softmax activation function , and the feature weighted fusion is realized according to the following formula: , and satisfies ; The feature enhancement layer adopts residual connection to alleviate gradient disappearance, combines BatchNorm normalization processing, and realizes multi-scale feature fusion by fusing 16x16, 32x32 and 64x64 scale feature maps, and outputs a fusion feature F with a dimension of 1024 fuse .
4. The sewage detection and tracing system based on multi-source data fusion according to claim 3, characterized in that, The spectral range of the hyperspectral sensor is 400-2500nm, the number of wavebands is greater than or equal to 1000, the spectral resolution is less than or equal to 2nm, and the spatial resolution is 1m*1m; The detection waveband of the thermal infrared sensor is 8-14um, the temperature measurement range is -20℃-60℃, and the accuracy is ±0.1℃; The laser wavelength of the LiDAR sensor is 1550nm, the point cloud density is greater than or equal to 50 points / m2, and the ranging accuracy is ±2cm; The meteorological auxiliary sensor includes an illumination intensity sensor and a rainfall sensor, the measurement range of the illumination intensity sensor is 0-100000lx, and the accuracy is ±1%, the measurement range of the rainfall sensor is 0-50mm / h, and the accuracy is ±0.1mm.
5. The sewage detection and tracing system based on multi-source data fusion according to claim 3, characterized in that, The deep learning modeling unit of the cloud data fusion and modeling module includes a pollution area identification sub-model, a pollutant concentration inversion sub-model and a pollution tracing path prediction sub-model: The pollution area identification sub-model is a bidirectional attention U-Net BA-U-Net, the encoder adopts ResNet50 as the backbone network, each layer of output feature map is screened for effective information through attention gating, the decoder is up-sampled through transposed convolution and is connected with the encoder feature map through jump connection, the convolution kernel size of the transposed convolution is 2*2, the step is 2, the decoder adds a boundary refinement module composed of 1 layer of 3*3 convolution and Sobel operator edge detection, and the loss function adopts Dice loss and cross entropy loss weighted fusion in a weight ratio of 7:3; The pollutant concentration inversion sub-model is an attention enhanced CNN-LSTM hybrid model, the CNN branch includes 3 layers of convolution and 1 layer of maximum pooling, the convolution kernel size is 3*3, the step is 1, padding=1, the pooling kernel size is 2*2, and the spatial distribution feature is extracted; the LSTM branch arranges 200 hyperspectral key wavebands in sequence according to the wavelength, captures the spectral time sequence dependence through 2 layers of LSTM, the hidden layer dimension of the LSTM is 256, and the dropout rate is 0.3; the fusion prediction layer fuses the CNN and LSTM outputs through a fully connected layer, first predicts the pollution type through a softmax classifier, then calls the concentration inversion sub-model of the corresponding type to output the COD, ammonia nitrogen, total nitrogen and total phosphorus concentration values, and the model adopts L2 regularization with lambda=0.001 to prevent overfitting; The traceability path prediction sub-model is a graph neural network and fluid mechanics coupling model, a water body topology graph G=(V,E) is constructed with water body nodes extracted by LiDAR as vertices and water flow directions as edges, vertex attributes include pollution concentration and terrain slope, and edge attributes include water flow velocity and distance; a 2-layer GAT is used to learn the pollution propagation probability, and the simplified Saint-Venant equation is used to correct the propagation probability, and the simplified Saint-Venant equation is: , and 1-3 most possible pollution outlets and corresponding confidence and future 12-hour pollution diffusion range are output.
6. The sewage detection and tracing system based on multi-source data fusion according to claim 3, characterized in that, The closed-loop optimization module includes a confidence evaluation unit and a dynamic adjustment unit: The confidence evaluation unit calculates the confidence of pollution area identification, pollutant concentration inversion, and pollution source tracking path prediction, respectively. The confidence of pollution area identification is calculated based on the maximum value of the prediction probability distribution, and the threshold is set to 0.
7. The confidence of concentration inversion is calculated based on the model prediction variance, and the threshold is set to 0.
8. The confidence of source tracking path is calculated based on the maximum value of GNN propagation probability, and the threshold is set to 0.
85. The dynamic adjustment unit triggers the following adjustment strategy when any task confidence is lower than the corresponding threshold: sending data reacquisition instructions to the unmanned aerial vehicle, reducing the flight height from 100m to 50m, and shortening the flight line spacing from 50m to 20m. The attention weight coefficients of the lightweight model are fine-tuned in real time at the edge. If the confidence is still lower than the threshold after reacquisition, an artificial verification prompt is pushed to the grid worker mobile APP.
7. The sewage detection and tracing system based on multi-source data fusion according to claim 3, characterized in that, The data transmission unit adopts the "edge preprocessing + 5G / satellite dual-mode transmission" mode. Edge preprocessing compresses multi-source raw data, with a compression ratio of ≥10:1 and key band and feature point data retained. The 5G network coverage area uses 5G transmission with a transmission delay of ≤10 seconds. No 5G network area automatically switches to satellite transmission with a transmission delay of ≤15 seconds, supporting breakpoint resume function.
8. The sewage detection and tracing system based on multi-source data fusion according to claim 3, characterized in that, The model training optimization unit adopts a dynamic adaptive training mechanism, including: A multi-scenario sample library is constructed, covering 5 typical terrains, 4 pollution types, and 3 environmental conditions, with a sample size of ≥100,000 groups. Each group of samples includes multi-source sensor data, measured water quality data, and terrain parameters. Three sets of formulas are used to realize sample enhancement, including spectral disturbance formula, spatial deformation formula, and temperature simulation formula. The spectral perturbation formula is: ; The spatial deformation formula is: ; The temperature simulation formula is: ; In the formulae, ; Online hard sample mining (OHEM) is used. During training, difficult samples with a confidence of <0.5 are selected, and their training weight is set to 3 times that of normal samples. Incremental learning is used. After model deployment, incremental training is automatically triggered every 1000 new samples collected, only updating the fully connected layer and attention layer parameters, and the training time is ≤1 hour. Transfer learning is used. The pre-trained model is trained based on the national general sample library. Local deployment only requires 500 local samples for fine-tuning, and the fine-tuning time is ≤12 hours.
9. The sewage detection and tracing system based on multi-source data fusion according to any one of claims 3-8, characterized in that, The work order generation unit of the source tracking decision module generates pre-warning work orders according to the pollution level: The first-level warning condition is COD≥150mg / L or ammonia nitrogen≥10mg / L or total nitrogen≥15mg / L or total phosphorus≥2mg / L, corresponding to the first-level warning work order, which requires the responsible subject to complete the rectification within 24 hours. The second-level warning condition is COD∈[80,150)mg / L or ammonia nitrogen∈[5,10)mg / L or total nitrogen∈[8,15)mg / L or total phosphorus∈[1,2)mg / L, corresponding to the second-level warning work order, which requires the responsible subject to complete the rectification within 72 hours. The work order includes the coordinates of the pollution outlet, the pollution type, the concentration detection data, the rectification technical requirements, and the contact information of the grid worker. The accuracy of the pollution outlet coordinates is ±1.5m, and the work order is automatically pushed to the mobile APP of the local environmental protection grid worker, supporting the whole process of work order receiving, rectification photo uploading, and review result input.
10. The sewage detection and tracing system based on multi-source data fusion according to claim 9, characterized in that, The flight control unit supports intelligent flight path planning and multi-machine cooperative flight: Intelligent flight path planning supports importing shp format monitoring area boundary, automatically generating grid flight path, and adaptively adjusting flight height in the range of 50-150m according to terrain elevation. The encrypted flight path with a spacing of ≤20m is automatically generated around villages, near breeding farms, and downstream of industrial enterprise sewage outlets, and the like. Multi-machine cooperative flight supports ≥3 unmanned aerial vehicles simultaneously collecting data in different areas, and real-time collection to the cloud through a data transmission unit, which is suitable for ≥100 square kilometers of cross-regional watershed monitoring scenarios, and the spatial alignment error of multi-machine data is ≤0.5m.
Citation Information
Cited By
Sludge organic nutrient soil production detection method and system
CN121994723A
Online monitoring system based on AI analysis
CN122021950A
An online monitoring system based on AI analysis
CN122021950B