A method, storage medium and system for detecting chlorophyll a concentration in water
By constructing a mixed density neural network model, optimizing hyperparameters and establishing a loss function, the problem of low detection accuracy of chlorophyll a concentration in water bodies in the existing technology has been solved, and high-precision detection and good generalization capabilities for complex water bodies have been achieved.
Patent Information
- Application Number
- CN202410874927.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-02
- Publication Date
- 2024-10-11
- Estimated Expiration
- 2044-07-02
AI Technical Summary
The existing technology has problems such as poor accuracy, weak model generalization ability, and insufficient extrapolation ability when detecting chlorophyll a concentration in water bodies, especially when dealing with complex natural water bodies and multiple types of water bodies.
Filter out interference items through data sorting, cluster analysis and classify water body spectra, build a mixed density neural network model, optimize hyperparameters, establish a loss function, train the model to calculate the mathematical expectation and standard deviation of chlorophyll a concentration, and realize the chlorophyll a concentration in water bodies. detection.
It significantly improves the inversion accuracy of different types of water bodies and the extrapolation and generalization capabilities of the model, and can more accurately detect chlorophyll a concentrations in various types of water bodies.
Smart Images

Figure CN118427669B_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of spectral component analysis and discloses a method, a storage medium and a system for detecting the concentration of chlorophyll a in water. Background Art
[0002] Chlorophyll a is the most important plant pigment, and its concentration is the core parameter for evaluating the nutrient status of water bodies, directly reflecting the biomass of phytoplankton in water bodies and the eutrophication evolution state. The absorption peaks of chlorophyll a are near 440nm and 670nm. 440nm is also strongly absorbed by yellow substances and suspended particles, so the reflectivity of Class II water bodies in the blue and purple bands is usually low. There is also a fluorescence peak of chlorophyll a near 683nm, and the position of the fluorescence peak will gradually move toward the long-wave direction as the concentration of chlorophyll a increases. Near 700nm, because the sum of the absorption coefficients of chlorophyll a and other components reaches a minimum, that is, the absorption effect is minimum, the remote sensing reflectance of the water body shows a reflection peak. The concentration of chlorophyll a can affect the absorption coefficient and backscattering coefficient of chlorophyll a, thereby affecting the remote sensing reflectance of the water body, so the concentration of chlorophyll a can be inferred by the remote sensing reflectance of the water body.
[0003] Statistical methods are used to establish a model between the apparent optical quantities measured by the sensor (commonly reflectance and remote sensing reflectance) and the water quality parameters measured simultaneously. In the early stages of the development of water quality remote sensing, the physical mechanism of the interaction between water quality components and light beams in water has yet to be developed. Some linear regression methods are widely used, such as multiple linear regression, multiple linear regression with logarithmic transformation, linear mixed model, principal component analysis fused with multiple linear regression, and stepwise regression. The spectral features used are usually band values, band combinations, or first-order difference band values. The spectrum obtained by the sensor calculates the spectral features band by band, linear regression, and evaluates the optimal statistical model. This method is relatively simple and convenient to implement, and can also obtain relatively ideal inversion performance for specific water bodies. However, there is a complex, nonlinear bio-optical model between remote sensing reflectance and chlorophyll a concentration, which causes the chlorophyll a concentration solved by linear regression to have a non-negligible deviation. In order to better characterize this complex relationship, the academic community has adopted a variety of nonlinear statistical methods, such as support vector machine regression, particle swarm optimization, feature fusion and ensemble learning, and convolutional neural networks. These nonlinear modeling methods can better characterize the complex physical relationship between chlorophyll a concentration and apparent optical quantity, and have a good model fit. However, the water environment of natural water bodies is extremely complex, and the components contained in the water bodies are complex and changeable. Even for the same lake, it contains water bodies composed of multiple types of components. Using a unified algorithm to establish a model to invert the chlorophyll a concentration of water bodies can often only cope with a single type of water body. When applied to other types of water bodies, there will be problems such as poor accuracy, weak model generalization ability, and insufficient extrapolation ability. Summary of the invention
[0004] In view of the above problems, the present invention provides a method for detecting the concentration of chlorophyll a in water, and the specific scheme comprises the following steps:
[0005] S1. By filtering out interference items in water remote sensing data through data sorting, samples of water spectra directly related to the conditional distribution of chlorophyll a concentration are obtained;
[0006] S2. Classify water spectra by cluster analysis according to spectral morphology;
[0007] S3. A mixed density neural network model is constructed with the water spectrum as input and the conditional distribution of chlorophyll a concentration of a given spectral observation as output;
[0008] S4. Obtain water spectral samples for training and perform hyper-parameter optimization on the mixed density neural network model;
[0009] S5. Label the water spectral samples according to the classification, construct the loss function, and perform model training;
[0010] S6. Use the trained mixed density neural network model to obtain the conditional distribution, calculate the mathematical expectation and standard deviation of the chlorophyll a concentration, and complete the detection of the chlorophyll a concentration in the water body.
[0011] Preferably, the interference items in step S1 include: interfering pixels of non-river and lake water bodies in the image, distortion caused by the medium through which the light reflection path passes, and interference of the photographed object itself and the surrounding environment on the light path.
[0012] Preferably, the classification in step S2 includes first using 13 types of water body spectra obtained historically through K-means clustering as reference spectra, normalizing them with the water body spectrum samples respectively, and then calculating the spectral angles between the water body spectrum samples and the 13 types of reference spectra one by one. The type of reference spectrum corresponding to the minimum spectral angle is the water body category to which the water body spectrum sample belongs.
[0013] Preferably, in step S3, the water spectrum is a standardized water spectrum, the chlorophyll a concentration is the chlorophyll a concentration after power conversion, and the probability model of the conditional distribution is any one of Gaussian distribution, Laplace distribution, logarithmic Gaussian distribution and gamma distribution.
[0014] Preferably, the hyper-parameter optimization in step S4 includes searching for water body categories in which suspended particulate matter is the main optically active component affecting the water body spectrum, and establishing model one separately, and establishing model two for other water body categories; using a grid search method to search for the optimal hyper-parameters one by one; for model one, the optimal hyper-parameters are: the probability model is a Gaussian distribution, the hidden layer is two layers, each layer has 25 neurons, the input layer has 15 neurons, the activation function is CreLU, the learning rate is 0.001, and the batch size is 100; for model two, the optimal hyper-parameters are: the probability model is a Gaussian distribution, the hidden layer is three layers, each layer has 20 neurons, the input layer has 15 neurons, the activation function is CreLU, the learning rate is 0.001, and the batch size is 100.
[0015] Preferably, the loss function establishment method in step S5 is: assigning a water body category label to each input water body spectrum through classification, using the upper and lower limits of the chlorophyll a concentration distribution corresponding to each label as a discriminant factor, and integrating it with the negative log-likelihood function to form the overall loss function of the model.
[0016] Another embodiment of the present invention is to provide a readable storage medium for storing one or more programs containing multiple instructions. When the programs are run, the processor will execute the above-mentioned method for detecting the concentration of chlorophyll a in water.
[0017] Another embodiment of the present invention is to provide a system for detecting the concentration of chlorophyll a in water, comprising a processing circuit and a memory electrically coupled thereto, wherein the memory is configured to store at least one program, wherein the program includes a plurality of instructions, and the processing circuit runs the program to execute the above-mentioned method for detecting the concentration of chlorophyll a in water.
[0018] Compared with the prior art, the present invention produces the following beneficial effects:
[0019] The present invention establishes a neural network and constructs an inversion model by utilizing the physical mechanism of the interaction between water quality components and light beams in water, taking into account the linear and nonlinear characteristics of the physical mechanism, and significantly improving the inversion accuracy of the model for different types of water bodies; the loss function is established by classification and the optimal parameters of the model are obtained through training, so that the model has good extrapolation and generalization capabilities. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 This is a schematic diagram of a process for detecting chlorophyll a concentration in water according to an embodiment of the present invention;
[0021] Figure 2 Schematic diagram of the top of atmosphere image processing process in an embodiment of the present invention;
[0022] Figure 3 It is a schematic diagram of normalized spectra of different types of water bodies in an embodiment of the present invention. DETAILED DESCRIPTION
[0023] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be described below in conjunction with the drawings in the embodiments of the present invention. The described embodiments are part of the embodiments of the present invention, but not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making innovative efforts are within the scope of protection of the present invention.
[0024] The present invention is further described in detail below with reference to the accompanying drawings and embodiments.
[0025] like Figure 1 As shown, a method for detecting the concentration of chlorophyll a in water comprises the following steps:
[0026] Step 1: Sentinel-3OLCI top-of-atmosphere image processing. This solution uses Sentinel-3OLCI top-of-atmosphere imagery (TOA image). The Sentinel-3 satellite carries four sensors, namely: Ocean and Land Color Imaging Spectrometer (OLCI), Synthetic Aperture Radar Altimeter, Ocean and Land Surface Temperature Radiometer and Microwave Radiometer. The Ocean and Land Color Imaging Spectrometer (OLCI) sensor is a medium-resolution linear array push-broom imaging spectrometer, which is shot by 5 identical imaging spectrometers side by side, so the width reaches 1300km and the field of view is 68.5°. The spatial resolution of the OLCI top-of-atmosphere image over the coast and land is 300m, and it contains 21 spectral bands from 400nm to 1025nm. Sentinel-3OLCI top-of-atmosphere image can be used to monitor inland lakes and reservoirs with large water areas.
[0027] This solution uses Sentinel-3OLCI Level-1B images, i.e., top-of-atmosphere images. The processing flow is as follows: Figure 2As shown. In the first step, images are screened according to the proportion of bright pixels and seawater pixels. Images with a mask ratio greater than 60% will be directly removed. For bright pixel masks, bright pixels are usually interfered by the high surface reflectance in the visible light band such as cloud dance, ice and snow, so mask processing is required. The Sentine-3OLCI Level-1B image contains a quality control label band, which contains the label information of bright pixels. The second step is to perform atmospheric correction based on the 6S model. The 6S model requires input of atmospheric parameters, observation geometry, spectral response function of the sensor, and water body altitude. Among them, atmospheric parameters are the key to 6S simulation, including aerosol model, 550nm aerosol optical thickness, ozone concentration and water vapor content. The ozone concentration uses the TOMS / OMI total columnar ozone concentration product provided by GESDISC. The water vapor content uses the NCEP / NCAR global reanalysis product, and the aerosol optical thickness and aerosol model use the MERRA-2 aerosol product. In the 6S model, the aerosol model can use predefined aerosol models or be defined by the user. Predefined aerosol models include Continental aerosol, Urban aerosol, Maritime aerosol, etc. There are four basic categories of aerosols, including water-soluble aerosols, smoke aerosols, sand aerosols, and marine aerosols. Users need to define the proportions of these four categories when defining their own aerosol models. The MERRA-2 aerosol product has a high temporal resolution for model simulation results and satellite observations, and can provide hourly aerosol products with a spatial resolution of 70km. The MERRA-2 aerosol product includes the total columnar concentrations, 550nm AOT, and Angstrom coefficients of basic aerosol components such as dust, black carbon, SO2, SO4, sand and PM2.5. The monitored aerosol components roughly cover these four basic aerosol categories. According to the MERRA-2 aerosol product, water-soluble aerosols include SO2 and SO4; dust aerosols are mainly dust particles; smoke aerosols mainly include black carbon; marine aerosols include sea salt and dimethyl sulfide. The total columnar mass density of each aerosol particle can be used to calculate the proportion of these four aerosol types, thereby defining the aerosol model. The third step is proximity effect correction. The proximity effect is related to aerosol scattering and the type of land objects around the water body. This scheme reduces the impact of the proximity effect on the water body by reducing the pixel-background contrast within the kernel window. In the kernel window Calculate the average reflectance of pixels around the water body. The diffuse transmittance and direct transmittance can reflect the proportion of scattered radiation. Therefore, the proximity effect correction formula can be expressed as:
[0028]
[0029] Among them, τ dif , τ diris the diffuse transmittance and direct transmittance of the ground to the sensor, represents the number of pixels in the kernel window, is the remote sensing reflectance after proximity effect correction. τ dif , τ dir It can be obtained through the 6S model. The fourth step is to calculate the water body index MNDWI, determine the threshold of MNDWI by the Ostu bimodal threshold method, and determine the boundary range of the water body. In addition, in order to avoid the interference of mixed pixels at the junction of water and land, the water body boundary erodes the range of one pixel inward (about 300m). The fifth step is to mask the clouds, algal blooms, aquatic plants, and negative bands in the 400nm-753nm band on the water body.
[0030] Step 2: Data cleaning and conversion. Data cleaning mainly involves quality control of the satellite spectra at the sampling point to ensure the quality of the input spectra. The central wavelength of the Sentinel-3OLCI spectrum ranges from 400nm to 1025nm. Considering the spectral characteristics of chlorophyll a and the absorption peak of O2 in the near-infrared band, R with a central wavelength between 412nm and 708nm is selected. rs As the input band. First, between 412nm and 708nm, R rs <0 or R rs Spectra with values greater than 0.2 were directly removed. Secondly, the water color index of each spectrum was calculated, and all water color indices in a lake were taken as a set. The elliptic envelope anomaly detection algorithm was used to remove outliers in the set, and the outlier ratio was set to 10%.
[0031] Data conversion is the R rs The water spectrum is converted using the following formula:
[0032]
[0033] nR rs(λ) Normalized remote sensing reflectance. After standardization, the absolute amplitude differences between different spectra are eliminated, and the relative changes within the spectrum are amplified. The distribution of chlorophyll a observation samples is uneven, showing a log-normal distribution, and a large number of samples are concentrated in a smaller range. The 10% and 90% quantiles of the measured chlorophyll a concentration are 1μg / L and 26μg / L, respectively, while the minimum and maximum values are 0.1μg / L and 73μg / L, respectively. This imbalance in distribution makes training difficult, and the model tends to favor the majority class in the training data, reducing the generalization ability of the model. This problem is also widely present in remote sensing image interpretation and target recognition, and is called the long-tail class imbalance problem. In order to alleviate the imbalance in the distribution of observed data, this scheme uses the Yeo-Johnson power transformation to transform the measured chlorophyll a concentration, as shown in the following formula:
[0034]
[0035] in, represents the data before and after the transformation, and γ is the conversion factor, which is determined by the maximum likelihood method. After the transformation, the 10% and 90% quantiles of the measured values are 0.70 and 3.63, respectively. After the transformation, the samples far from the mathematical expectation of the data become relatively close, and the distance between samples with small differences in chlorophyll a concentration becomes closer, which increases the overall weight of samples with higher chlorophyll a concentrations and helps to improve the extrapolation and generalization capabilities of the model.
[0036] Step 3: Classification of water body spectra. This scheme classifies water body spectra according to spectral morphology in order to determine the optimal inversion model based on the characteristics of each type of water body. Evangelos Spyrakos and others collected 4035 water surface hyperspectral images from around the world, including 250 inland lakes and rivers, as well as ocean water data collected during 14 voyages. Water body spectra are widely used and representative. Through k-means clustering, inland water bodies are divided into 13 categories, and their normalized remote sensing reflectance, such as Figure 3 As shown in Figure 1, each category has specific water quality characteristics and optical properties. For example, in Category 5 water bodies, suspended sediment is the dominant optically active substance affecting the water spectrum ( Figure 3 (a) purple solid line), Category 13 water bodies ( Figure 3 (b) The brown solid line) is a particularly clean blue water body, such as a clean lake on the plateau.
[0037] This scheme uses the spectra of these 13 types of water bodies as reference spectra to perform water optical classification on the studied water spectra. The similarity between the studied spectrum and the reference spectrum is measured by the spectral angle, and the smallest spectral angle indicates that the two spectra are most similar. The similarity clustering of the studied spectra is mainly divided into the following steps:
[0038] The spectrum was cropped between 400 nm and 800 nm, and the reference spectrum, the measured water surface hyperspectrum, and the spectral response function of Sentinel-3 OLCI were convolved.
[0039] For satellite spectra, in order to avoid the interference of the oxygen absorption peak near 767nm, the values of bands 12 and 13 were deleted and the R values of bands 11 and 14 were used. rs Linear interpolation is used instead. This step is not necessary for the measured water surface hyperspectral.
[0040] Formula (2) is used to normalize the research spectrum and the reference spectrum. The spectral angles between the research spectrum and the 13 reference spectra are calculated one by one. When the spectral angle is the smallest, the research spectrum belongs to the water body category at this time.
[0041] Based on the above method, the measured water surface hyperspectral and satellite spectra used in this study are divided into 13 categories for subsequent quantitative analysis and model construction.
[0042] Step 4: Construct a neural network. Mixture density network (MDN) is a probabilistic deep learning method that combines a feedforward neural network with a mixed probability model. Suppose the input spectrum x = [x1, x2, ..., x n ], input spectrum length is n, input data set There are m observations in total. The data set of chlorophyll a concentration after power transformation is y = [y1, y2, ..., y m The mixed density network uses a mixed probability model to distribute the conditional probability Describe, and infer the model parameters in the mixed probability model through the forward feedback neural network. The mixed probability model can be expressed as a linear combination of a single probability density function:
[0043]
[0044] in, represents the kth component of the mixed probability model, represents the kth component mixing coefficient. The components of the mixed probability model can be any probability density function, such as Gaussian distribution, Laplace distribution, Bernoulli distribution, etc. After selecting the conditional probability distribution used to describe the input data and output data, the forward neural network is used to infer the parameters in the distribution, and the negative log likelihood function (NLL) is constructed as the loss function, which is expressed as:
[0045]
[0046] The construction of the mixed density network is mainly divided into the following three steps: first, select a suitable probability model to describe the conditional probability distribution of input data and output data; second, establish a neural network and design the network according to the parameter characteristics of the selected probability model. The number of network output nodes is the same as the number of probability model parameters; finally, derive the negative log-likelihood function based on the probability model, construct the loss function, and train the model. The input data of this scheme is nR rs (λ), the output data is the chlorophyll a concentration after power conversion. Suitable probability models mainly include Gaussian distribution, Laplace distribution, log-Gaussian distribution and gamma distribution. The optimal probability model can be determined by hyperparameter optimization. The forward feedback neural network is briefly divided into input layer, hidden layer and output layer. Hyperparameters such as the number of neurons in the input layer and hidden layer, the number of hidden layers, and the type of activation function can be determined by hyperparameter optimization. The output layer needs to be specially designed. The mixing parameters need to meet the following constraints:
[0047]
[0048] In order to meet this constraint, the activation function of the output node corresponding to the mixing parameter needs to use the softmax function. The ADAM (adaptive moment estimation) optimizer is selected to optimize the model, restore the output distribution from the output mixed probability model parameters, and calculate the optimal estimate.
[0049] This scheme divides inland water bodies into 13 categories based on spectral morphology. The category of water body spectrum itself contains prior information about the distribution of chlorophyll a concentration, that is, observation experience. With the increase of observation experience, when we see a water body spectrum, we can usually roughly determine the rough range of chlorophyll a concentration corresponding to this water body spectrum. For example, the 13th category of water body ( Figure 3 (b) The brown solid line) is the spectrum of clean oligotrophic water, where the chlorophyll a concentration is usually very low; the spectrum of Class 7 water ( Figure 3 (a) The pink solid line) has a significant absorption peak at 670nm and a significant reflection peak near 708nm. The chlorophyll a concentration of this type of water body must be high. This observation experience can be combined with the negative log-likelihood function to construct a loss function that integrates observation experience. Each input water body spectrum will be assigned a water body category label through water body optical classification. Each category of water body corresponds to an upper and lower limit of the chlorophyll a concentration distribution. For predicted samples that exceed the limit, the loss function will increase, otherwise it will decrease. Determine the prediction results of each round of iteration Whether the water exceeds the upper and lower limits of the water category is expressed as:
[0050]
[0051] The loss function when the prediction result exceeds the limit can be expressed as the last term of formula (8). Adding the negative log-likelihood function and the observed empirical loss function together, the overall loss function of the model can be expressed as:
[0052]
[0053] By using formula (8) as the loss function, we can use the observation experience in the training of the model simultaneously. The upper and lower bounds of chlorophyll a in each type of water body also need to be transformed by Yeo-Johnson power, that is, formula (3). In order to avoid the abnormal increase of the loss function caused by the wrong optical category, the optical classification results of the water body spectra used for training will be manually visually checked one by one to ensure the correct category.
[0054] Step 5: Hyperparameter search and model training. Based on the classification results of water body optics, the chlorophyll a concentration inversion model is divided into two sub-models for construction and training. Class 4 and Class 5 water bodies show that in these two types of water bodies, suspended particles are the main optically active components that affect the water spectrum ( Figure 3 (a) in the figure). The 4th and 5th water bodies are jointly modeled and trained, referred to as Model 2. The samples of the remaining 11 types of water bodies are used to build another inversion model, referred to as Model 1. Since the collected water surface hyperspectral data are mainly distributed abroad, and the research area of this scheme is mainly domestic. Therefore, the spectral data used for model construction and verification are mainly satellite spectra matched by satellite and ground, supplemented by a small amount of water surface hyperspectral data. In the satellite spectra after satellite and ground matching, there are a total of 338 data, of which 238 are used for the construction of Model 1 and 100 are used for the construction of Model 2. Considering that the data used for Model 2 is relatively small, additional observation samples of water bodies close to the water bodies are obtained, and samples of Class 4 and Class 5 are selected from them for training and verification of Model 2. Therefore, Model 2 has a total of 154 data. These data are divided into training set, validation set and test set, with a ratio of 70%, 15%, and 15%.
[0055] The hyperparameters that need to be determined include model structure and training parameters. The model structure parameters include probability model, number of hidden layers, number of neurons in each layer, and activation function. The training parameters include learning rate and batch size. The number of components of the mixed probability model (Formula (4)) is determined by self-optimization during model training. The grid search method is used to search for the optimal model parameters and training parameters one by one. The training performances corresponding to different activation functions are significantly different, among which CReLU has the best training performance. For model 1, the optimal model structure parameters are: probability model is Gaussian distribution, hidden layer is two layers, each layer has 25 neurons, input layer has 15 neurons, and activation function is CReLU. In terms of training parameters, the learning rate is 0.001 and the batch size is 100. For model 2, the optimal model structure parameters are: probability model is Gaussian distribution, hidden layer is three layers, each layer has 20 neurons, and input layer has 15 neurons. The training parameters are consistent with model 1.
[0056] The output of the model is the model parameters and mixing coefficient of the mixed probability model. Through hyperparameter search, the optimal probability model selected by this solution is Gaussian distribution, and the output is the mathematical expectation, standard deviation and mixing coefficient of each component. The optimal estimate is the mathematical expectation of the component corresponding to the maximum mixing coefficient. After training optimization, model 1 contains two distributions, while model 2 only needs one distribution. In other words, model 2 does not need to use a mixed probability model, and its mixing coefficient is always 1.
[0057] The sixth step is to obtain the optimal estimate and its uncertainty for the conditional distribution of chlorophyll a concentration under given spectral conditions output by the model. The model outputs the parameters describing the distribution, which are restored by equation (4), and then 500 samples are taken from the distribution to obtain the chlorophyll a concentration value, standard deviation, and mixing coefficient before conversion. The sampling result is the inversion value of the chlorophyll a concentration after the Yeo-Johnson power conversion, which is then inversely transformed using equation (3) to obtain the inversion value of the chlorophyll a concentration. Using the mixing coefficient as the weight, the weighted average and weighted standard deviation of the 500 samples are calculated to obtain the optimal estimate of the chlorophyll a concentration and its standard deviation.
[0058] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computers, available storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer usable program codes.
[0059] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0060] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0061] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0062] Compiling the above method steps into a program and then storing it on a hard disk or other non-transitory storage medium, and electrically connecting it to a processor constitutes the technical solution of "a readable storage medium" of the present invention; and electrically connecting the readable storage medium to a data acquisition device, which can complete the detection of chlorophyll a concentration in water bodies through data processing, constitutes the technical solution of "a system for detecting chlorophyll a concentration in water bodies" of the present invention.
[0063] Finally, it should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art can still modify the technical solutions described in the aforementioned embodiments or replace some of the technical features therein by equivalents. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A method for detecting chlorophyll a concentration in water, characterized in that The following steps are involved: S1. By filtering out interference items in water remote sensing data through data sorting, samples of water spectra directly related to the conditional distribution of chlorophyll a concentration are obtained; S2. Classify water spectra by cluster analysis according to spectral morphology; S3. A mixed density neural network model is constructed with the water spectrum as input and the conditional distribution of chlorophyll a concentration of a given spectral observation as output; S4. Obtain water spectral samples for training and perform hyper-parameter optimization on the mixed density neural network model; S5. Label the water spectral samples according to the classification, construct the loss function, and perform model training; The method of constructing the loss function includes: Let the input spectrum x = [x1, x2, ..., x n ], the input spectrum length is n, and the input data set x has a total of m observations, The data set of chlorophyll a concentration after power transformation is: y = [y1, y2, ..., y m ], Determine the prediction results of each iteration Whether it exceeds the upper and lower limits of the water category: The loss function expression is: in, represents the kth component of the mixed probability model, Represents the kth component mixing coefficient; S6. Use the trained mixed density neural network model to obtain the conditional distribution, calculate the mathematical expectation and standard deviation of the chlorophyll a concentration, and complete the detection of the chlorophyll a concentration in the water body.
2. A method for detecting chlorophyll a concentration in water according to claim 1, characterized in that: The interference items in step S1 include: interference pixels of non-river and lake water bodies in the image, distortion caused by the medium through which the light reflection path passes, and interference of the photographed object itself and the surrounding environment on the light path.
3. A method for detecting chlorophyll a concentration in water according to claim 2, characterized in that: The classification described in step S2 includes first using the 13 types of water body spectra obtained historically through K-means clustering as reference spectra, normalizing them with the water body spectrum samples respectively, and then calculating the spectral angles between the water body spectrum samples and the 13 types of reference spectra one by one. The type of reference spectrum corresponding to the minimum spectral angle is the water body category to which the water body spectrum sample belongs.
4. A method for detecting chlorophyll a concentration in water according to claim 3, characterized in that: In step S3, the water spectrum is the standardized water spectrum, and the chlorophyll a concentration is the chlorophyll a concentration after square transformation; the probability model of the conditional distribution is any one of Gaussian distribution, Laplace distribution, logarithmic Gaussian distribution and gamma distribution.
5. A method for detecting chlorophyll a concentration in water according to claim 4, characterized in that: In step S4, the hyperparameter optimization includes searching for the water body category in which suspended particulate matter is the main optically active component affecting the water body spectrum to establish model one separately, and establishing model two for other water body categories; the grid search method is used to search for the optimal hyperparameters one by one; for model one, the optimal hyperparameters are: the probability model is Gaussian distribution, the hidden layer is two layers, each layer has 25 neurons, the input layer has 15 neurons, the activation function is CreLU, the learning rate is 0.001, and the batch size is 100; for model two, the optimal hyperparameters are: the probability model is Gaussian distribution, the hidden layer is three layers, each layer has 20 neurons, the input layer has 15 neurons, the activation function is CreLU, the learning rate is 0.001, and the batch size is 100.
6. A non-transitory readable storage medium for storing one or more programs comprising a plurality of instructions, characterized in that: When the instruction is executed, the processor will be caused to execute a method for detecting the concentration of chlorophyll a in water according to any one of claims 1 to 5.
7. A system for detecting chlorophyll a concentration in water, comprising a processing circuit and a memory electrically coupled thereto, characterized in that: The memory configuration stores at least one program, the program includes a plurality of instructions, and the processing circuit runs the program to execute a method for detecting chlorophyll a concentration in water according to any one of claims 1-5.
