Intelligent water quality monitoring and evaluating system based on image recognition

By combining image recognition technology with Kalman filtering and polarization feature tensor decomposition, high-definition water surface images are generated and three-dimensional pollution distribution is identified, which solves the problems of three-dimensional reconstruction errors and inaccurate quantification of pollution diffusion characteristics in water quality monitoring under complex environments, and achieves high-precision water quality assessment.

CN120741358AInactive Publication Date: 2025-10-03CHANGSHA XIAOSHUI ENVIRONMENTAL PROTECTION TECH CO LTD

Patent Information

Application Number
CN202511140769.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-15
Publication Date
2025-10-03
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Existing water quality monitoring technologies have insufficient anti-interference capabilities in complex environments, large three-dimensional reconstruction errors, and inaccurate quantification of pollution diffusion characteristics. Traditional methods are difficult to adapt to changes in reflection noise and wave disturbances under different lighting conditions, and ignore the uneven spatial distribution of pollutants.

Method used

An intelligent water quality monitoring and assessment system based on image recognition is adopted. The Kalman filter algorithm is used to predict the water surface reflection angle. The polarizer array rotation and polarization characteristic tensor decomposition method are combined to generate high-definition water surface images. The DLP projection method is used to obtain three-dimensional depth maps. The dynamic structural element opening and closing algorithm is used to identify the spatial distribution of pollutants. The gradient field analysis algorithm is used to trace the pollution diffusion path. A water quality monitoring report is generated through the three-dimensional pollution entropy scoring method.

Benefits of technology

It achieves high-precision optical measurement in complex environments, significantly enhances the identifiability of pollutant characteristics, accurately quantifies pollution diffusion characteristics, and generates high-resolution three-dimensional pollution distribution maps and water quality assessment reports.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120741358A_ABST
    Figure CN120741358A_ABST
Patent Text Reader

Abstract

The invention discloses an intelligent water quality monitoring and evaluating system based on image recognition, which relates to the technical field of environment monitoring, and comprises a fusion module for controlling a polarizer array to rotate based on an environment parameter set, capturing water surface optical images in different polarization directions, and performing image reconstruction through a polarization characteristic tensor decomposition method, generating a high-definition water surface image after reflection suppression; the three-dimensional diagram generation module is used for acquiring a morphology stripe image of the water surface through a DLP projection method, and generating a three-dimensional depth diagram in combination with the high-definition water surface image; the pollution identification module is used for correcting the three-dimensional depth map based on the real-time water temperature data, identifying spatial distribution of pollutants through a dynamic structure element opening and closing algorithm and generating a three-dimensional pollution distribution map; according to the method, mirror reflection noise is suppressed through multi-angle polarization image fusion, and the distinguishability of pollutant characteristics is remarkably enhanced while the image resolution is kept.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of environmental monitoring, and in particular to an intelligent water quality monitoring and evaluation system based on image recognition. Background Art

[0002] Water quality monitoring technology has made significant progress in the fields of optical sensing and image processing in recent years. Traditional methods rely primarily on fixed-point sampling and laboratory analysis. Although they are highly accurate, they suffer from limitations such as low spatiotemporal resolution and poor real-time performance. With the development of multispectral imaging, polarization sensing, and three-dimensional reconstruction technologies, optical-based water quality monitoring solutions have gradually matured, such as using hyperspectral cameras to obtain water reflectance characteristics or measuring water surface morphology through structured light projection. Existing technologies can already achieve semi-quantitative inversion of parameters such as turbidity and chlorophyll, but their anti-interference capabilities and pollution source tracing accuracy in complex environments are still insufficient.

[0003] Existing technologies have significant deficiencies in suppressing water surface reflections and compensating for dynamic environments. Conventional polarization imaging methods often use fixed-angle filtering, which makes it difficult to adapt to changes in reflection noise under different lighting conditions. Three-dimensional reconstruction of the water surface based on monocular vision is susceptible to wave disturbances, leading to errors in topography measurement. Particularly in dynamic water environments, existing systems lack real-time compensation mechanisms for interfering factors such as wind speed and light, limiting the accuracy of pollutant identification. Furthermore, traditional water quality assessment methods often ignore the uneven spatial distribution of pollutants and only conduct overall evaluations based on single-point sampling data, making it difficult to reflect the true characteristics of pollution diffusion. Summary of the Invention

[0004] In view of the above existing problems, the present invention is proposed.

[0005] Therefore, the present invention provides an intelligent water quality monitoring and assessment system based on image recognition to solve the problems of large three-dimensional reconstruction errors and inaccurate quantification of pollution diffusion characteristics.

[0006] In order to solve the above technical problems, the present invention provides the following technical solutions: The present invention provides an intelligent water quality monitoring and assessment system based on image recognition, which includes: a data acquisition module, which collects environmental data, and predicts the water surface reflection angle through a Kalman filter algorithm to generate an environmental parameter set; a fusion module, which controls the rotation of a polarizer array based on the environmental parameter set, captures water surface optical images in different polarization directions, and reconstructs the image through a polarization characteristic tensor decomposition method to generate a high-definition water surface image after reflection suppression; a three-dimensional image generation module, which obtains a morphological stripe image of the water surface through a DLP projection method, and generates a three-dimensional depth map in combination with the high-definition water surface image; a pollution identification module, which corrects the three-dimensional depth map based on real-time water temperature data, and identifies the spatial distribution of pollutants through a dynamic structural element opening and closing algorithm to generate a three-dimensional pollution distribution map; a pollution tracing module, which identifies the three-dimensional distribution gradient of pollutants through a gradient field analysis algorithm based on the three-dimensional pollution distribution map, and traces the pollution diffusion path; and a report generation module, which predicts the water quality score of the current water area based on the pollution diffusion path using a three-dimensional pollution entropy value scoring method, and generates a water quality monitoring report.

[0007] As a preferred solution of the water quality intelligent monitoring and assessment system based on image recognition described in the present invention, the polarizer array rotation is controlled by defining the rotation range and scanning angle change step of the polarizer array to control the rotation of the polarizer array to capture optical images of the water surface in different polarization directions.

[0008] As a preferred solution of the water quality intelligent monitoring and assessment system based on image recognition of the present invention, wherein: the fusion is performed by polarization characteristic tensor decomposition method to generate a high-definition water surface image after reflection suppression, the steps are as follows: The NTF is used to construct polarization tensors based on the three dimensions of polarization direction, spatial coordinates, and spectral channels for optical images of water surfaces with different polarization directions. Based on the polarization tensor, principal component analysis is used to extract the positive and negative characteristic components of the pollutants, and the Stokes parameter analysis method is used to separate the specular reflection noise component to generate a low-rank characteristic matrix. Based on the low-rank feature matrix, image reconstruction is performed using the Laplace pyramid fusion algorithm to generate a high-definition water surface image with reflection suppressed.

[0009] As a preferred solution of the water quality intelligent monitoring and assessment system based on image recognition described in the present invention, the method of obtaining the topographic stripe image of the water surface by the DLP projection method refers to projecting a Gray code-sinusoidal composite stripe pattern onto the water surface by the DLP projection method according to dynamic projection parameters and the optimal projection wavelength, and receiving the topographic stripe image reflected by the water surface.

[0010] As a preferred solution of the water quality intelligent monitoring and assessment system based on image recognition described in the present invention, the three-dimensional depth map is generated by obtaining a wrapped phase map through a four-step phase shift method, and using Gray code decoding for phase unfolding to generate the relative height of each point on the water surface relative to the still water surface. At the same time, a three-dimensional depth map is generated through a Poisson surface reconstruction algorithm.

[0011] As a preferred solution of the water quality intelligent monitoring and assessment system based on image recognition described in the present invention, the correction of the three-dimensional depth map refers to performing Snell correction on the relative height of each water surface point in the three-dimensional depth map relative to the still water surface, and correcting the refraction path.

[0012] As a preferred solution of the water quality intelligent monitoring and assessment system based on image recognition of the present invention, wherein: the spatial distribution of pollutants is identified by the dynamic structural element opening and closing algorithm to generate a three-dimensional pollution distribution map, the steps are as follows: Extract the gradient amplitude characteristics, reflectance spectrum anomaly characteristics and polarization characteristics of water surface pollutants; Based on the gradient amplitude characteristics, reflectance spectrum anomaly characteristics and polarization characteristics of pollutants, the dynamic structural element opening and closing algorithm is used to identify and mark the distribution area of ​​pollutants in three-dimensional space; According to the distribution areas of pollutants in three-dimensional space, the connected domain analysis combined with the density clustering algorithm is used to aggregate and classify the polluted areas to generate a three-dimensional pollution distribution map.

[0013] As a preferred solution of the water quality intelligent monitoring and assessment system based on image recognition of the present invention, the steps of identifying the three-dimensional distribution gradient of pollutants and tracing the pollution diffusion path by using the gradient field analysis algorithm are as follows: Use the three-dimensional Sobel operator to perform convolution operation on the pollution distribution map to obtain the three-dimensional gradient vector of the pollutant in the three-dimensional pollution distribution map; Based on the pollutant concentration gradient vector, the central difference method is used to calculate the discrete divergence of the pollutant concentration gradient field, and the streamline tracing algorithm is combined to gradually update the coordinates of the pollution diffusion path points along the gradient direction. At the same time, the pollution diffusion path is traced through principal component analysis.

[0014] As a preferred solution of the water quality intelligent monitoring and evaluation system based on image recognition described in the present invention, the three-dimensional pollution entropy scoring method is used to predict the water quality score of the current water area and generate a water quality monitoring report. The steps are as follows: The pollution entropy value of each pollution diffusion path is calculated using the Shannon entropy pollution diffusion evaluation method; The mean curvature of the pollution diffusion path is identified by using the B-spline curve differential geometry analytical method; Based on the pollution entropy value of each diffusion path and the average curvature of the pollution diffusion path, the three-dimensional pollution entropy scoring method is used to calculate the water quality score of the current water area; Generate a water quality monitoring report based on the three-dimensional pollution distribution map, pollution diffusion path and water quality score.

[0015] As a preferred solution of the water quality intelligent monitoring and assessment system based on image recognition of the present invention, wherein: the environmental parameters include light intensity, water temperature, wind speed, water refractive index, air refractive index and light incident angle; Based on the water refractive index, air refractive index and light incident angle, the water surface reflection angle is predicted using the Kalman filter algorithm.

[0016] The beneficial effects of the present invention are as follows: the water surface reflection angle is predicted through the Kalman filter algorithm, the dynamic coupling of environmental parameters and optical measurement is realized, and the reflection model is corrected in real time using multi-source data such as wind speed and water temperature, which effectively improves the optical measurement accuracy in complex environments; combined with the polarization characteristic tensor decomposition method, the mirror reflection noise is suppressed through multi-angle polarization image fusion, which significantly enhances the recognizability of pollutant characteristics while maintaining image resolution. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0018] Figure 1 Schematic diagram of the water quality intelligent monitoring and assessment system based on image recognition in Example 1.

[0019] Figure 2 This is a flow chart of polarization image fusion in Example 1.

[0020] Figure 3 This is a flow chart for pollution distribution identification in Example 1.

[0021] Figure 4 This is a flow chart of tracing the pollution diffusion path in Example 1. DETAILED DESCRIPTION

[0022] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the specific embodiments of the present invention are described in detail below with reference to the accompanying drawings.

[0023] In the following description, many specific details are set forth to facilitate a full understanding of the present invention. However, the present invention may also be implemented in other ways different from those described herein. Those skilled in the art may make similar generalizations without violating the connotation of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed below.

[0024] Secondly, the term "one embodiment" or "embodiment" herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in one embodiment" appearing in various places throughout this specification does not necessarily refer to the same embodiment, nor does it refer to a separate or selective embodiment that is mutually exclusive of other embodiments.

[0025] Example 1, with reference to Figures 1 to 4 This embodiment provides a water quality intelligent monitoring and assessment system based on image recognition, comprising the following steps: The data acquisition module collects environmental data and predicts the water surface reflection angle through the Kalman filter algorithm to generate an environmental parameter set; Environmental data include light intensity, water temperature, wind speed, water refractive index, air refractive index, and light incident angle; It should be noted that light intensity is measured using a light intensity sensor with a range of 0 to 120,000 Lux. For example, a silicon photodiode coupled with a logarithmic amplifier is used to achieve high dynamic range measurement. Water temperature is measured using a high-precision temperature sensor with a measurement accuracy of ±0.1°C. A PT1000 platinum resistor is used in conjunction with a four-wire measurement circuit to eliminate the effects of wire resistance. Wind speed is measured using an ultrasonic anemometer with a range of 0 to 20 meters per second. For example, the time difference method is used to measure three-dimensional wind speed components. The water refractive index is dynamically calculated from water temperature data. For example, the water refractive index at 25°C is 1.332. The air refractive index is fixed at 1.0003, which is the refractive index of dry air under standard conditions.

[0026] Based on environmental data, the Kalman filter algorithm is used to predict the water surface reflection angle, and the expression is: ; in, for The reflection angle at the moment, is the refractive index of air, is the refractive index of water, is the angle of incidence of light, is the ripple disturbance angle caused by wind speed, is the rate of change of reflection angle, the initial value is 0, is the time step of the prediction process; It should be noted that the specific calculation process for predicting the water surface reflection angle is as follows: and water refractive index and the incident angle of light Calculate the basic optical reflection component , which reflects the refraction characteristics of light at the water-air interface; the ripple disturbance angle is calculated by real-time wind speed data , which reflects the influence of wind and waves on the microscopic morphology of the water surface; the reflection angle change rate is obtained by iterative calculation based on the historical reflection angle data through the Kalman filter algorithm , reflecting the dynamic change trend of the reflection angle. Finally, the basic optical reflection component, the ripple disturbance component and the dynamic adjustment component are Perform linear superposition and get Predicted reflection angle at time .

[0027] Generate an environmental parameter set based on environmental data and water surface reflection angle.

[0028] The fusion module controls the rotation of the polarizer array based on the environmental parameter set, captures optical images of the water surface in different polarization directions, and reconstructs the images using the polarization eigentensor decomposition method to generate high-definition water surface images with reflection suppression. Based on the environmental parameter set, the rotation range of the polarizer array and the scanning angle change step size are defined; It should be noted that the process of defining the rotation range and scanning angle change step of the polarizer array is determined based on the light intensity, wind speed and water refractive index data in the environmental parameter set. The light intensity data is used to set the basic rotation range. When the light intensity exceeds 10,000 lux, the rotation range is defined as 0 degrees to 180 degrees, and when it is lower than this value, it is defined as 30 degrees to 150 degrees. The wind speed data is used to adjust the rotation range boundary, for example, the range boundary is extended by 15 degrees under a wind speed of 10 m / s. The water refractive index data determines the scanning angle change step. The step size is set to 5 degrees when the water refractive index is in the range of 1.33 to 1.34, and the step size is set to 3 degrees when the water refractive index is in the range of 1.34 to 1.35. The final rotation range and scanning angle change step size ensure that the polarization direction of the light reflected from the water surface can be fully covered, while ensuring that the polarization characteristics between adjacent scanning positions are significantly different.

[0029] The polarizer array rotates according to the rotation range and the scanning angle change step size to capture optical images of the water surface in different polarization directions; Furthermore, the polarizer array is rotated step by step according to the predefined rotation range and scanning angle change step, starting from the starting angle and gradually rotating to the ending angle with a fixed step length. At each stop position, the polarizer array remains stationary and synchronously triggers the optical camera to capture the water surface optical image of the current polarization direction. For example, when the rotation range is 30 degrees to 150 degrees and the step length is 5 degrees, the polarizer array will capture images at 24 discrete angle positions. The angle control accuracy of each rotation position reaches 0.1 degrees, and the image acquisition interval time matches the polarizer rotation speed to ensure that the exposure is completed in a stable state of the array. Finally, a group of water surface optical images with different polarization directions are obtained, and the number of images is determined by the rotation range span and the step length value.

[0030] The NTF is used to construct polarization tensors based on the three dimensions of polarization direction, spatial coordinates, and spectral channels for optical images of water surfaces with different polarization directions. Furthermore, the collected water surface optical images of different polarization directions are organized into a three-dimensional array based on polarization angle, pixel coordinates, and RGB spectral channels. NTF decomposition decomposes the water surface optical images of different polarization directions into the product of polarization characteristic components, spatial structure components, and spectral characteristic components. The polarization characteristic dimension corresponds to the rotation angle of different polarizers, the spatial structure dimension maintains the original image resolution, and the spectral dimension contains the RGB three-channel information. The decomposition process is solved iteratively using the alternating least squares method.

[0031] Based on the polarization tensor, principal component analysis is used to extract the positive and negative characteristic components of the pollutants, and the Stokes parameter analysis method is used to separate the specular reflection noise component to generate a low-rank characteristic matrix. Furthermore, the low-rank feature matrix generation process first performs principal component analysis on the polarization tensor, retaining the first three principal components to extract the polarization characteristics of the main pollutants. Stokes parameter analysis is used to calculate the degree of polarization (DoP) and angle of polarization (AoP) for each pixel. A specular reflection noise template is established based on the Fresnel reflection law, and the noise component is subtracted from the principal components. The resulting low-rank feature matrix contains denoised polarization intensity, degree of polarization, angle of polarization, and spectral signature information.

[0032] Based on the low-rank feature matrix, image reconstruction is performed using the Laplace pyramid fusion algorithm to generate a high-definition water surface image with reflection suppressed.

[0033] Furthermore, the polarization intensity components in the low-rank feature matrix are first decomposed at multiple scales using Gaussian filtering, constructing a five-layer Gaussian pyramid. At each pyramid level, a weight map is calculated based on the polarization intensity component. For example, regions with a polarization intensity greater than 0.6 are assigned a fusion weight of 0.9, while regions with a polarization intensity less than 0.3 are assigned a weight of 0.1. Weights are also adjusted based on the degree of spectral difference. For example, pixels with a difference greater than 0.5 are given an additional weight of 0.2. The weighted fusion results of each layer are then reconstructed layer by layer using Laplacian pyramid backprojection, ultimately generating a high-definition, reflection-suppressed water surface image with the original resolution maintained.

[0034] It should be noted that the polarization intensity component is obtained by collecting optical images in multiple polarization directions, then using Stokes recognition to identify the intensity variation characteristics of each pixel under different polarization states, and finally extracting the component representing the intensity of the polarization characteristic. This polarization intensity component can effectively distinguish between specular reflections and true reflections from the object surface. Its significance lies in providing a key polarization characteristic basis for suppressing water surface reflections. By quantifying the difference in polarization characteristic intensity, it can accurately identify and separate the water surface specular reflection noise, thereby significantly improving the visualization of underwater targets.

[0035] The 3D image generation module uses the DLP projection method to obtain the fringe image of the water surface and combines it with the high-definition water surface image to generate a 3D depth map. Based on the historical environmental parameter set, the projection parameters are initialized, and the optical flow method is used based on the real-time wind speed data to dynamically adjust the projection angle and fringe frequency to generate dynamic projection parameters; Furthermore, optical flow analysis is used based on real-time wind speed data to analyze water surface motion characteristics. The surface fluctuation state is determined by calculating the displacement vectors of feature points between consecutive image frames. The results of the optical flow analysis are directly mapped to projection parameter adjustments. As the surface fluctuation velocity increases, the projection angle compensation value is increased accordingly, while the fringe frequency is adjusted proportionally to the fluctuation amplitude. The dynamic projection parameter generation process is continuously iteratively updated. The projection angle adjustment range is positively correlated with wind speed changes, while the fringe frequency changes maintain an inverse relationship with the spatial frequency of the water surface ripples, ensuring stable imaging of the structured light pattern on the water surface.

[0036] It should be noted that the fringe frequency refers to the number of cycles of alternating light and dark stripes per unit length in the structured light pattern projected by the DLP projector.

[0037] Based on high-definition water surface images, the spectral angle mapping algorithm is used to extract the transmittance curve characteristics of the current water area, and the optimal projection wavelength is predicted by the minimum transmission loss criterion. The expression is: ; in, is the optimal projection wavelength, For light at wavelength The penetration, is the wavelength variable, is a differential operator, Dirac The function calculates the extreme point indicator factor, which is a binary indicator value (1 indicates that the current wavelength is a transmittance extreme point, and 0 indicates a non-extreme point).

[0038] It should be noted that the spectral angle mapping algorithm first extracts the multispectral reflectance data of each pixel from the high-definition water surface image and constructs a wavelength-reflectance curve. After the curve is smoothed by Savitzky-Golay filtering, its first-order derivative is calculated. , the position of the transmittance extreme value is determined by finding the intersection point where the derivative is zero. The Dirac delta function marks all extreme points and generates a binary indicator sequence. The optimal transmission wavelength The solution process traverses all candidate wavelengths and selects the wavelengths that meet the transmittance Largest and = 1 is used as the output result. The calculation process uses the golden section search algorithm to optimize the search efficiency and ensure the rapid positioning of the optimal projection wavelength within the visible light band.

[0039] It should be noted that the minimum transmission loss criterion determines the optimal projection wavelength by analyzing the spectral transmission curve of water. This method first measures the water's transmittance for light of different wavelengths and plots a complete transmittance curve. By identifying the wavelength region in the curve with the highest transmittance and the most gradual change, the optimal projection wavelength is determined to minimize energy loss when the optical signal propagates through water. The calculation considers both the absolute value and the variation of the transmittance, selecting the wavelength that maintains both high transmittance and stability as the optimal projection wavelength.

[0040] According to the dynamic projection parameters and the optimal projection wavelength, the DLP projection method is used to project the Gray code-sine composite fringe pattern onto the water surface, and the morphological fringe image reflected by the water surface is received; Furthermore, the mechanical rotating platform is first adjusted to ensure that the projection optical axis forms a preset angle with the water surface normal, simultaneously generating a Gray code-sinusoidal composite fringe pattern with a specific spatial frequency. The projection sequence is strictly controlled within 100 milliseconds, sequentially projecting four sinusoidal fringe patterns with a phase difference of π / 2 and a Gray code pattern. The number of sinusoidal fringe periods precisely corresponds to the spatial frequency, and the Gray code encoding width is an integer multiple of the fringe period. Under the optimal projection wavelength, a synchronously triggered high-speed industrial camera captures the fringe images reflected from the water surface.

[0041] Based on the fringe image of the water surface reflection, the wrapped phase image is obtained by the four-step phase shift method, and the phase is unwrapped using Gray code decoding to generate the relative height of each point on the water surface relative to the still water surface. Furthermore, the four captured sinusoidal fringe images are subjected to a four-step phase shifting method, and the inverse tangent function is used to calculate the wrapped phase map. The Gray code decoding process analyzes the Gray code pattern image, converts the pixel grayscale values ​​into binary codewords, and establishes a mapping relationship between pixel coordinates and fringe order. The phase unwrapping algorithm combines the wrapped phase map and Gray code order information to calculate the absolute phase value of each pixel, which is converted into the relative height of each point on the water surface relative to the still water surface.

[0042] According to the relative height of each point on the water surface relative to the still water surface and the high-definition water surface image, a three-dimensional depth map is generated through the Poisson surface reconstruction algorithm.

[0043] Furthermore, the relative height data of the water surface is aligned with the spatial coordinates of the high-definition water surface image. The Poisson surface reconstruction algorithm constructs a continuous water surface height field by solving the Poisson equation. The Poisson surface reconstruction algorithm first calculates the gradient field of the height data, then establishes a sparse linear system of equations to solve the 3D surface of the water surface that satisfies the gradient constraints, ultimately generating a 3D depth map that contains both geometric shape and texture information.

[0044] The pollution identification module modifies the 3D depth map based on real-time water temperature data and identifies the spatial distribution of pollutants through a dynamic structural element opening and closing algorithm to generate a 3D pollution distribution map. Based on the real-time water temperature, the Snell correction is performed on the relative height of each water surface point relative to the still water surface in the three-dimensional depth map. The expression is: ; in, is the corrected coordinate The relative height relative to the still water surface, is the coordinate before correction The relative height relative to the still water surface, At the current water temperature Real-time refractive index under is the dynamic height offset caused by water flow disturbance, It is the current water temperature data.

[0045] Furthermore, first obtain each coordinate point in the three-dimensional depth map The original relative height , and calculate the current water refractive index based on the current water temperature data The correction process performs two calculation steps: the first step is to calculate the refraction effect correction term ,in Represents the inverse of the refractive index of light from water to air; the second step is to superimpose the dynamic height offset caused by water flow disturbance The offset is obtained by analyzing the spatial gradient characteristics of the 3D depth map of consecutive frames. The final correction result That is the coordinate The calculation process ensures that the correction of each coordinate point is performed independently, and the corrected height value maintains the same spatial resolution and coordinate system as the original depth map.

[0046] In the stratified water temperature region, the temperature gradient compensation is performed on the corrected relative height relative to the still water surface based on FEM, and the refraction path is corrected.

[0047] Furthermore, a three-dimensional finite element mesh of the water body is first established, using the vertical distribution data collected by the temperature sensors as node parameters. The calculation process begins at the water surface measurement point and gradually solves the light propagation path in the variable refractive index medium along the depth direction. Within each finite element, the refractive index distribution is calculated based on the local temperature gradient, and the actual deflection angle is determined by iteratively solving the ray differential equation. The refractive path between adjacent finite element elements is maintained in a continuous transition, and the refractive path correction is ultimately completed by accumulating the refractive effects of each layer.

[0048] It should be noted that stratified water temperature zones refer to vertically layered structures formed by temperature differences within a body of water. These zones are typically divided into a surface warm water zone, a thermocline, and a bottom cold water zone. This division is based on the gradient of the vertical water temperature profile curve, with the thermocline boundary being determined when the temperature difference between adjacent depths exceeds 1°C per meter. For example, in a lake in summer, the surface layer 0-3 meters is a warm water zone at 28°C. The water temperature between 3-8 meters drops sharply from 28°C to 12°C, forming a thermocline. Below 8 meters, the water zone remains a stable cold water zone at 10°C.

[0049] Based on the corrected 3D depth map, the gradient amplitude characteristics of water surface pollutants are extracted using the Sobel operator. The process of extracting the gradient amplitude characteristics of water surface pollutants based on the corrected 3D depth map is as follows: First, the 3D depth map is preprocessed with a Gaussian filter to eliminate measurement noise and small ripple interference. The Sobel operator is used to calculate spatial gradients in the horizontal and vertical directions. A 3×3 gradient operator is used for convolution, and the gradient amplitude is calculated for each pixel. The result is normalized to obtain the gradient amplitude characteristics at each location on the water surface.

[0050] Using SAM to identify abnormal reflectance spectrum features of pollutants from the RGB-NIR channels of high-definition water surface images; Furthermore, the image data is first converted into reflectance data through radiation correction to eliminate differences in lighting conditions. Subsequently, the reflectance values ​​of each pixel in the four bands of R, G, B and NIR are extracted to construct a complete spectral feature vector. By calculating the degree of difference between the spectral feature vector and the reference spectrum of clean water, the spectral anomaly characteristics of each pixel are quantified. Due to the special material composition of water surface pollutants, they exhibit reflectance anomalies in specific bands. These anomaly characteristics are accurately extracted through spectral analysis methods. The final output result is the abnormal reflectance spectrum characteristics of the pollutant, which clearly shows the spectral response characteristics of the water surface pollution area.

[0051] It should be noted that the Clean Water Reference Spectrum is a benchmark spectral database constructed through long-term field sampling and laboratory analysis. Specifically, multiple sampling points are set up in typical clean waters, and water surface reflectance spectral data is collected simultaneously using a hyperspectral radiometer. Water samples are also collected for laboratory physical and chemical analysis to ensure that water quality parameters meet clean water standards. The Clean Water Reference Spectrum is established by statistically analyzing multi-temporal and multi-regional measurement data, removing outliers, and taking the median or mean reflectance of each band.

[0052] Based on the low-rank polarization feature matrix, the polarization characteristics of pollutants are extracted through component analysis combined with Stokes parameter analysis. Furthermore, the polarization data is first denoised to eliminate ambient light interference. The light intensity response in different polarization directions is analyzed using the Stokes parameter analysis method, and a complete polarization feature distribution is established to quantify the light intensity response characteristics in different polarization directions, laying the foundation for the extraction of pollutant polarization characteristics. Due to differences in surface properties and material composition, water surface pollutants exhibit unique characteristics in polarization response. The polarization response of each pixel point is compared and analyzed with the reference characteristics of clean water bodies to identify areas with different characteristics, and the polluted areas are distinguished from normal water bodies based on the light intensity response characteristics in different polarization directions. The final output result clearly shows the polarization characteristics of each position on the water surface.

[0053] Based on the gradient amplitude characteristics, reflectance spectrum anomaly characteristics and polarization characteristics of the pollutants, the dynamic structural element opening and closing algorithm is used to identify and mark the distribution area of ​​the pollutants in three-dimensional space; Furthermore, the dynamic structuring element opening and closing algorithm first dynamically adjusts the structuring element size based on the real-time wind speed and wave frequency in the environmental parameter set. For example, when the wind speed is 10 meters per second, the structuring element uses an elliptical kernel with a major axis of 8 mm and a minor axis of 5 mm. When the wave frequency is 2 Hz, the elliptical kernel is rotated 15 degrees. Multi-feature fusion is then performed on the 3D gradient amplitude feature map, the reflectance spectrum anomaly feature map, and the polarization feature map to generate initial contaminated candidate regions. In the opening phase, the dynamic structuring element is used to erode the candidate regions, removing isolated noise points and small artifacts. For example, debris smaller than 5 cubic millimeters is eliminated. In the closing phase, the same structuring element is used to dilate the eroded regions to fill holes caused by wave interference. For example, broken regions with spacing less than 3 mm are connected into continuous contaminated clusters. Finally, a 3D spatial neighborhood traversal is performed to generate labeled contaminant distribution areas. The output is binary 3D mask data, where voxels with a mask value of 1 represent contaminated areas, and voxels with a mask value of 0 represent clean water areas.

[0054] It should be noted that the wave frequency is obtained by Fourier spectrum analysis of the water surface fringe image sequence. The specific method is to extract the main frequency component after performing time-frequency conversion on the dynamic changes of water surface ripples obtained by the DLP projection method.

[0055] According to the distribution areas of pollutants in three-dimensional space, the connected domain analysis combined with the density clustering algorithm is used to aggregate and classify the polluted areas to generate a three-dimensional pollution distribution map.

[0056] Furthermore, the connected domain analysis traverses the pollutant distribution mask based on the three-dimensional 26-neighborhood connectivity rule and independently marks the spatially continuous pollution clusters. For example, an area containing at least 20 connected voxels and a volume greater than 15 cubic millimeters is marked as a valid pollution cluster. The density clustering algorithm uses the DBSCAN algorithm to spatially aggregate neighboring pollution clusters. For example, the neighborhood search radius is set to 5 mm and the minimum number of samples is set to 10, and multiple clusters with a centroid distance of less than 5 mm and a polarization difference of less than 0.1 are merged into a single pollution area. The classification process sets the judgment threshold based on the gradient amplitude mean, spectral angle difference mean and polarization mean of the pollution cluster. For example, the area with a gradient amplitude mean greater than 60 grayscale values ​​and a polarization mean greater than 0.3 is classified as an oil film type pollutant, and the area with a spectral angle difference mean less than 0.6 and a gradient amplitude mean less than 50 grayscale values ​​is classified as a suspended particle type pollutant. The final three-dimensional pollution distribution map is stored in PLY format. Each pollution area contains the center of mass coordinates, volume, surface area, maximum height difference and classification label. For example, the measurement accuracy of the center coordinates of oil film pollutants is ±0.1 mm, and the calculation error of suspended particle volume is ±3 cubic millimeters.

[0057] The pollution source tracing module uses a gradient field analysis algorithm to identify the three-dimensional distribution gradient of pollutants based on the three-dimensional pollution distribution map and trace the pollution diffusion path; Use the three-dimensional Sobel operator to perform convolution operation on the pollution distribution map to obtain the three-dimensional gradient vector of the pollutant in the three-dimensional pollution distribution map. The expression is: ; in, Represents the coordinates in the three-dimensional pollution distribution map The pollutant concentration gradient vector at is the gradient operator of the pollutant concentration vector, yes Directional convolution kernel, yes Directional convolution kernel, yes Directional convolution kernel, represents the 3D convolution operator, The pollutant concentration in rate of change of direction, The pollutant concentration in rate of change of direction, The pollutant concentration in rate of change of direction; Furthermore, the measured pollutant concentration data are calculated according to the spatial coordinates. Perform three-dimensional grid interpolation processing, where each grid point stores the corresponding pollutant concentration value. 、 、 The three directions define the three-dimensional Sobel convolution kernel respectively, where Directional nuclear detection before and after the plane concentration difference, Directional nuclei detect the difference in concentration between the left and right planes, Directional kernels detect the concentration difference between the upper and lower planes. The convolution kernels of these three directions are sequentially convolved with the pollution distribution map to obtain 、 and Three partial derivative components. The three components are combined into the pollutant concentration gradient vector through vector synthesis operation .

[0058] It should be noted that the gradient operator of the pollutant concentration vector Specifically, it represents the rate of change of the pollutant concentration field in different directions in three-dimensional space. It is obtained by convolving the pollution distribution map with a 3D Sobel operator. A 5×5×5 convolution kernel is used, and the kernel weights are set according to a Gaussian distribution with a standard deviation of 1.5. The calculation process obtains the partial derivatives of the concentration in the X, Y, and Z directions, and finally synthesizes the gradient vector, which has a value range of [0, 1].

[0059] Based on the pollutant concentration gradient vector, the central difference method is used to calculate the discrete divergence of the pollutant concentration gradient field, and the streamline tracing algorithm is combined to gradually update the coordinates of the path points along the gradient direction. At the same time, the pollution diffusion path is traced through principal component analysis.

[0060] Furthermore, the discrete divergence of the pollutant concentration gradient field is expressed as: ; in, is the discrete divergence of the pollutant concentration gradient field, yes The change in the directional pollutant concentration gradient, is spatial sampling in The distance interval of the direction, yes The change in the directional pollutant concentration gradient, yes The change in the directional pollutant concentration gradient, is spatial sampling in The distance interval of the direction, is spatial sampling in The distance interval of the direction.

[0061] Update the path point coordinates, the expression is: ; in, Indicates the current space advancement The streamline position coordinates, Indicates the next space advancement The streamline position coordinates, is the spatial propulsion, Indicates location The pollutant concentration gradient vector at .

[0062] It should be noted that the pollutant concentration gradient vector is first processed by the central difference method to calculate the discrete divergence field. Negative areas in the divergence field correspond to pollutant convergence points, and areas with values ​​below a specific threshold for multiple consecutive frames are determined to be potential pollution sources. Subsequently, starting from the pollution source, streamline tracing is performed along the normalized gradient direction to gradually generate diffusion trajectories. Finally, principal component analysis is performed on the set of gradient vectors on the pollution source migration trajectory to extract the dominant diffusion direction. These three links are interconnected: the divergence field locates potential pollution sources, streamline tracing generates diffusion paths, and principal component analysis determines the dominant diffusion direction. The accuracy of the divergence field directly affects the location of pollution sources, the accuracy of streamline tracing determines the degree of path restoration, and principal component analysis grasps the diffusion trend from a macro perspective. By combining the results of these three links, the diffusion path of pollutants can be fully identified: the specific migration trajectory starting from the pollution source and extending along the main diffusion direction.

[0063] The specific threshold refers to the critical value of the divergence field used to identify potential pollution sources. Its value range is typically -0.05 to -0.1 (dimensionless). The specific threshold is determined through statistical analysis of historical pollution event data. First, data on the correspondence between the divergence field and actual pollution sources under typical pollution scenarios is collected. Receiver-operating characteristic (ROC) curve analysis is then used to determine and define the threshold, achieving an optimal balance between true positive rate and false positive rate. Specifically, when the divergence value in a certain area is below -0.07 for more than three consecutive frames, it is determined to be a reliable pollution source signal. Under conditions of strong water flow disturbance (flow velocity > 0.5 m / s), the threshold is relaxed to -0.05 to improve detection sensitivity. The threshold value must take into account both sensor accuracy (±0.02) and environmental noise levels, and is dynamically calibrated using field measurement data.

[0064] The report generation module uses the three-dimensional pollution entropy scoring method to predict the water quality score of the current water area based on the pollution diffusion path and generates a water quality monitoring report.

[0065] The pollution entropy value of each pollution diffusion path is calculated by the Shannon entropy pollution diffusion evaluation method. The expression is: ; in, It is The pollution entropy value of the pollution diffusion path, It is The first pollution diffusion path The pollution density of each sampling point, It is The total pollution load of the pollution diffusion path, is the index variable of the sampling point, is the index variable of the pollution diffusion path, It is The total number of sampling points along the pollution diffusion path; Furthermore, we first determine the distribution of sampling points on each pollution diffusion path and record the pollution density of each sampling point. Calculate the The total pollution load of the pollution diffusion path , obtained by accumulating the pollution density of all sampling points on the current diffusion path. Calculate the relative pollution density for each sampling point , to ensure that the probability distribution conditions are met. Calculate item by item according to the Shannon entropy formula , and for All sampling points on the path are summed up. Finally, the negative value is taken to get the The pollution entropy value of the pollution diffusion path , which quantifies the uneven distribution of pollutants along the diffusion path.

[0066] The mean curvature of the diffusion path is identified by the B-spline curve differential geometry analytical method; Furthermore, the pollution diffusion path is discretized into an ordered set of points, and a parameterized curve representation is obtained using B-spline curve fitting. The calculation process obtains the tangent vector field by taking the first-order derivative of the B-spline curve, and the normal vector field by taking the second-order derivative. The radius of curvature is then obtained through a vector cross product. The mean curvature is determined by the ratio of the normal vector modulus to the tangent vector modulus. The mean curvature of the entire path is obtained by numerically integrating it along the curve's parameter domain and dividing it by the arc length.

[0067] Based on the pollution entropy value of each diffusion path and the average curvature of the pollution diffusion path, the three-dimensional pollution entropy scoring method is used to calculate the water quality score of the current water area. The expression is: ; in, is the water quality score of the current water area, is the total number of pollution diffusion paths, represents the average curvature of all pollution diffusion paths, Indicates the The angular change rate of the pollution diffusion path, is the normalization calibration factor, and its value range is (0, +∞); Furthermore, first obtain the pollution entropy values ​​of all pollution diffusion paths and the average curvature of all pollution diffusion paths , and calculate the angle change rate of each path . The diffusion path of each and the corresponding Multiply them together to get the composite pollution index of the path. The arithmetic mean of the composite pollution index of the diffusion path is calculated and the result is divided by the normalized calibration factor Perform standardization. Substitute the standardized results into the exponential decay function to calculate the pollution degree coefficient. Final water quality score Obtained by linearly mapping the contamination degree coefficient to a range of 0-100 by multiplying by 100. The calculation process ensures that the contribution weight of each diffusion path is equal, and the normalized calibration factor Used to adjust the score's sensitivity to pollution indicators. The water quality score comprehensively reflects the spatial distribution characteristics of pollutants and the geometric characteristics of their diffusion paths. Lower scores indicate more severe water pollution.

[0068] Generate a water quality monitoring report based on the three-dimensional pollution distribution map, pollution diffusion path and water quality score.

[0069] In summary, the present invention achieves dynamic coupling of environmental parameters and optical measurements through: predicting the water surface reflection angle using the Kalman filter algorithm, and using multi-source data such as wind speed and water temperature to correct the reflection model in real time, effectively improving the accuracy of optical measurements in complex environments; combined with the polarization characteristic tensor decomposition method, mirror reflection noise is suppressed through multi-angle polarization image fusion, significantly enhancing the recognizability of pollutant features while maintaining image resolution.

[0070] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solutions of the present invention may be modified or replaced by equivalents without departing from the spirit and scope of the technical solutions of the present invention, which should all be included in the scope of the claims of the present invention.

Claims

1. An intelligent water quality monitoring and assessment system based on image recognition, characterized by: include, The data acquisition module collects environmental data and predicts the water surface reflection angle through the Kalman filter algorithm to generate an environmental parameter set; The fusion module controls the rotation of the polarizer array based on the environmental parameter set, captures optical images of the water surface in different polarization directions, and reconstructs the images using the polarization eigentensor decomposition method to generate high-definition water surface images with reflection suppression. The 3D image generation module uses the DLP projection method to obtain the fringe image of the water surface and combines it with the high-definition water surface image to generate a 3D depth map. The pollution identification module modifies the 3D depth map based on real-time water temperature data and identifies the spatial distribution of pollutants through a dynamic structural element opening and closing algorithm to generate a 3D pollution distribution map. The pollution source tracing module uses a gradient field analysis algorithm to identify the three-dimensional distribution gradient of pollutants based on the three-dimensional pollution distribution map and trace the pollution diffusion path; The report generation module uses the three-dimensional pollution entropy scoring method to predict the water quality score of the current water area based on the pollution diffusion path and generates a water quality monitoring report.

2. The water quality intelligent monitoring and assessment system based on image recognition according to claim 1, characterized in that: The polarizer array rotation is controlled by defining a rotation range and a scanning angle change step of the polarizer array, thereby controlling the polarizer array to rotate and capturing optical images of the water surface in different polarization directions.

3. The water quality intelligent monitoring and assessment system based on image recognition according to claim 2, characterized in that: The steps of reconstructing the image by polarization eigentensor decomposition to generate a high-definition water surface image after reflection suppression are as follows: The NTF is used to construct polarization tensors based on the three dimensions of polarization direction, spatial coordinates, and spectral channels for optical images of water surfaces with different polarization directions. Based on the polarization tensor, principal component analysis is used to extract the positive and negative characteristic components of the pollutants, and the Stokes parameter analysis method is used to separate the specular reflection noise component to generate a low-rank characteristic matrix. Based on the low-rank feature matrix, image reconstruction is performed using the Laplace pyramid fusion algorithm to generate a high-definition water surface image with reflection suppressed.

4. The water quality intelligent monitoring and assessment system based on image recognition according to claim 1, characterized in that: The acquisition of the topographic fringe image of the water surface by the DLP projection method refers to projecting a Gray code-sine composite fringe pattern onto the water surface by the DLP projection method according to dynamic projection parameters and an optimal projection wavelength, and receiving the topographic fringe image reflected by the water surface.

5. The water quality intelligent monitoring and assessment system based on image recognition according to claim 4, characterized in that: The three-dimensional depth map is generated by obtaining a wrapped phase image through a four-step phase shift method, and using Gray code decoding for phase unfolding to generate the relative height of each point on the water surface relative to the still water surface. At the same time, a Poisson surface reconstruction algorithm is used to generate a three-dimensional depth map.

6. The water quality intelligent monitoring and assessment system based on image recognition according to claim 5, characterized in that: The correction of the three-dimensional depth map refers to performing Snell correction on the relative height of each water surface point relative to the still water surface in the three-dimensional depth map, and correcting the refraction path.

7. The water quality intelligent monitoring and assessment system based on image recognition according to claim 6, characterized in that: The spatial distribution of pollutants is identified by the dynamic structural element opening and closing algorithm to generate a three-dimensional pollution distribution map. The steps are as follows: Extract the gradient amplitude characteristics, reflectance spectrum anomaly characteristics and polarization characteristics of water surface pollutants; Based on the gradient amplitude characteristics, reflectance spectrum anomaly characteristics and polarization characteristics of pollutants, the dynamic structural element opening and closing algorithm is used to identify and mark the distribution area of ​​pollutants in three-dimensional space; According to the distribution areas of pollutants in three-dimensional space, the connected domain analysis combined with the density clustering algorithm is used to aggregate and classify the polluted areas to generate a three-dimensional pollution distribution map.

8. The water quality intelligent monitoring and assessment system based on image recognition according to claim 1, characterized in that: The steps of identifying the three-dimensional distribution gradient of pollutants and tracing the pollution diffusion path through the gradient field analysis algorithm are as follows: Use the three-dimensional Sobel operator to perform convolution operation on the pollution distribution map to obtain the three-dimensional gradient vector of the pollutant in the three-dimensional pollution distribution map; Based on the pollutant concentration gradient vector, the central difference method is used to calculate the discrete divergence of the pollutant concentration gradient field, and the streamline tracing algorithm is combined to gradually update the coordinates of the pollution diffusion path points along the gradient direction. At the same time, the pollution diffusion path is traced through principal component analysis.

9. The water quality intelligent monitoring and assessment system based on image recognition according to claim 1, characterized in that: The three-dimensional pollution entropy scoring method is used to predict the water quality score of the current water area and generate a water quality monitoring report. The steps are as follows: The pollution entropy value of each pollution diffusion path is calculated using the Shannon entropy pollution diffusion evaluation method; The mean curvature of the pollution diffusion path is identified by using the B-spline curve differential geometry analytical method; Based on the pollution entropy value of each diffusion path and the average curvature of the pollution diffusion path, the three-dimensional pollution entropy scoring method is used to calculate the water quality score of the current water area; Generate a water quality monitoring report based on the three-dimensional pollution distribution map, pollution diffusion path and water quality score.

10. The water quality intelligent monitoring and assessment system based on image recognition according to claim 1, characterized in that: The environmental parameters include light intensity, water temperature, wind speed, water refractive index, air refractive index and light incident angle; Based on the water refractive index, air refractive index and light incident angle, the water surface reflection angle is predicted using the Kalman filter algorithm.

Citation Information

Patent Citations

  • Dynamic monitoring and early warning system for sewage treatment

    CN119735250A

  • Water quality pollution traceability analysis method and system based on intelligent unmanned ship

    CN120233053A

  • Three-dimensional fluorescence coupling artificial intelligence water quality real-time monitoring and early warning system

    CN120352405A

Cited By

  • Aquaculture environment analysis method based on image analysis

    CN121030137A

  • Reservoir spillway water passing monitoring method and system based on image recognition

    CN121191306A

  • Precise water pollutant identification system based on multispectral image fusion

    CN121236607A

  • Cordyceps militaris fermented beverage quality monitoring method and system based on image recognition

    CN121298604A