A water dissolved oxygen concentration remote sensing inversion method based on an XGBoost-2DCNN model
By combining the XGBoost and 2DCNN models, satellite images and water quality data are used to indirectly estimate the dissolved oxygen concentration in water bodies, which solves the insufficient spatial and temporal coverage of traditional methods and achieves high-precision dissolved oxygen monitoring in water bodies.
Patent Information
- Application Number
- CN202411857424.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-17
- Publication Date
- 2025-10-17
- Estimated Expiration
- 2044-12-17
AI Technical Summary
Traditional dissolved oxygen monitoring methods have problems such as limited temporal and spatial coverage, high cost, and unsuitability for large-scale dynamic monitoring. Existing remote sensing technology makes it difficult to directly invert the dissolved oxygen concentration in water bodies through spectral characteristics.
Combining the XGBoost model and two-dimensional convolutional neural network (2DCNN), a fusion model was constructed using satellite image data and multi-source water quality data to perform high-precision estimation of dissolved oxygen concentration using indirect information such as chlorophyll-a and water temperature.
It achieves high-precision, spatiotemporal dynamic estimation of dissolved oxygen concentration, breaks through the spatial and temporal limitations of traditional methods, and provides a scientific basis for large-scale dynamic monitoring of water environments.
Smart Images

Figure CN119760045B_ABST
Abstract
Description
(I) Field of the Art
[0001] The present application relates to a water dissolved oxygen concentration remote sensing inversion method based on an XGBoost-2DCNN model, belonging to the field of water color remote sensing, and having important significance in water ecosystem research and water quality monitoring applications. (II) BACKGROUND
[0002] Water dissolved oxygen (Dissolved Oxygen) concentration is one of the important parameters for measuring water quality, and is closely related to the health of the aquatic ecosystem and environmental monitoring. Abnormal fluctuations in dissolved oxygen concentration can cause water eutrophication, fish death and other ecological problems, so efficient and accurate monitoring of dissolved oxygen is of great significance. Traditional dissolved oxygen monitoring methods mainly rely on ground sampling and laboratory analysis, which has high accuracy, but has limitations such as limited time and spatial coverage, high cost and unsuitability for large-scale dynamic monitoring.
[0003] With the development of remote sensing technology, using satellite image data to invert water quality parameters has become an efficient and economical solution. However, the optical properties of water bodies are complex and variable, and dissolved oxygen concentration is difficult to directly invert through spectral characteristics. Therefore, how to use indirect information such as optically active substances (such as chlorophyll-a, suspended solids, etc.) and water temperature in water bodies to achieve high-precision estimation of dissolved oxygen through remote sensing images combined with advanced mathematical and physical modeling methods has become a key and difficult point of current research.
[0004] In recent years, machine learning and deep learning technologies have shown significant advantages in the field of remote sensing water quality inversion. Among them, the XGBoost model can efficiently handle non-linear and multi-dimensional features, while the two-dimensional convolutional neural network (2DCNN) has outstanding ability in mining the spatio-temporal features and high-dimensional correlations of data. Based on this, a joint model combining XGBoost and 2DCNN is constructed by combining remote sensing image data and multi-source water quality data, which can make full use of the advantages of remote sensing data while achieving high-precision and spatio-temporal dynamic estimation of dissolved oxygen concentration. The development and promotion of this technology has important scientific value and practical significance for water environment monitoring and eutrophication prevention and control. (III) SUMMARY
[0005] 1. A water dissolved oxygen concentration remote sensing inversion method based on an XGBoost-2DCNN model, characterized in that it comprises the following steps:
[0006] (1) Collect, process and standardize data for the water dissolved oxygen DO concentration model training;
[0007] (2) Build water chlorophyll-a concentration and water temperature prediction models based on the XGBoost machine learning model;
[0008] (3) Develop a two-dimensional convolutional neural network model 2DCNN to predict the dissolved oxygen concentration;
[0009] (4) Precision verification of the dissolved oxygen concentration prediction model.
[0010] The specific method for collecting, processing and standardizing data for the prediction model training is as follows:
[0011] (1) Collect and collect long time series of in-situ water quality measurement data from the study area, including various optical active and non-active water quality parameters, as well as metadata information such as geographic coordinates of water quality monitoring stations, data quality and collection date; Extract necessary data from the collected data set, including water quality control area, monitoring station code, monitoring station geographic coordinates, sampling date, chlorophyll a, water temperature, dissolved oxygen DO; Prepare the area of interest AOI polygon vector file of the study area; Establish a spatio-temporal matching data set containing in-situ water quality parameter measurement and corresponding satellite multispectral image water surface reflectance value; Use Google Earth Engine GEE to extract water surface reflectance of each water quality monitoring station and sample collection date;
[0012] (2) Incorporate the seasonal variation trend of water quality parameters into the modeling of dissolved oxygen concentration prediction; Use time information-month as an input parameter for modeling, and use sine and cosine transformation to encode months as periodic variables, as follows:
[0013]
[0014] Where x represents the month; This conversion ensures the correct position of all months on the circular scale, and accurately represents its periodic pattern by capturing the periodic angle and amplitude; The converted month feature is represented as Month sin and Month cos , will be used as input features for the dissolved oxygen prediction model;
[0015] (3) Extract data records of the study period from the prepared data set to prepare two training data sets; One of the training data sets contains input features: including spectral reflectance data and converted month features and output features: including chlorophyll a and water temperature, used to train machine learning algorithms for predicting chlorophyll a and water temperature; Taking optical remote sensing image Sentinel-2 as an example, this data set can be represented as:
[0016] Training_Dataset Chla_Temperature ={B1,B2,…,B8,B 8A ,B9,B 11 ,B 12 ,Month sin ,Month cos ,Chla,Temperature}
[0017] Another training dataset contains input features including chlorophyll-a, water temperature and converted month features, and labeled dissolved oxygen output features, for training the convolutional neural network model for dissolved oxygen univariate prediction; this dataset is denoted as
[0018] Training_Dataset DO = {Chla, Temperature, Month sin , Month cos , DO}
[0019] (4) Extract data records of the study period from the prepared dataset to prepare the test dataset, which contains input features including reflectance data and converted month features, the first stage is used to predict chlorophyll-a and water temperature, and then predict dissolved oxygen using the prediction; this dataset is denoted as
[0020] Test_dataset = {B1, B2, …, B8, B 8A , B9, B 11 , B 12 , Month sin , Month cos}
[0021] The specific implementation method of constructing water body chlorophyll-a concentration and water temperature prediction model based on XGBoost machine learning model is as follows:
[0022] Based on the machine learning algorithm eXtreme Gradient Boosting (XGBoost), the complex relationship between water quality parameters and satellite optical characteristics is captured for water quality monitoring; using the Training_Dataset Chla_Temperature dataset, the XGBoost model is trained using the optimal hyperparameters to estimate chlorophyll-a and water temperature; for each target variable, the training dataset is divided into input features and target output, as follows:
[0023] X Chla_Temperature = Training_Dataset Chla_Temperature {Chla, Temperature}
[0024] Y Chla = Training_Dtaset Chla_Temperature [′Chla′]
[0025] Y Temperature = Training_Dataset Chla_Temperature [′Temperature′]
[0026] For each parametric model, the XGBoost algorithm is used for training, whose objective function is to minimize the prediction error, which is expressed as follows:
[0027] f XGBOOST,Chla (X Chla_Temperature )=arg min∑ i (Y Chla,i -f(X Chla_Temperature,i )) 2
[0028]
[0029] Where i represents the ith sample value, f(X) represents the function that the model predicts chlorophyll a or water temperature according to the input features, and the objective is to minimize the sum of squared errors between the predicted value and the actual value.
[0030] The specific implementation method of developing a two-dimensional convolutional neural network model 2DCNN for predicting the dissolved oxygen concentration is as follows:
[0031] A two-dimensional convolutional neural network (2DCNN) model is developed and trained using input parameters such as chlorophyll a, water temperature, and conversion month features to estimate the dissolved oxygen concentration; the best hyperparameters are used to train the 2DCNN model to minimize the training and validation loss; the steps for training and developing the 2DCNN model are as follows:
[0032] (1) The training data set Training_Dataset DO is divided into input features and target output:
[0033] X DO =Training_Dataset DO \{DO}
[0034] Y DO =Training_Dataset DO [′DO′]
[0035] (2) The input feature vector X DO ∈R 4×1 represents a one-dimensional data composed of 4 features: Chla, Temperature, Month sin , Month cos , each feature has a value:
[0036] X′ DO ∈R 4×1×1
[0037] (3) 13 layers are defined with different hyperparameters for performing convolution, pooling, and batch normalization on the input features to generate the desired output, and the definitions of these layers are as follows:
[0038] Layer 1 = > Conv2D: 32 convolutional filters W1 with a size of 4x1, with "same" padding and a hyperbolic tangent activation function, applied to the input features defined as follows:
[0039] Z1 = Conv2D(X', W1) + b1 DO
[0040] A1 = tanh(Z1)
[0041] Layer 2 = > Batch Normalization: Normalizing the output of the activation function A1 to improve the stability of training, defined as follows
[0042]
[0043] where μ1 and σ1 represent the mean and variance of A1, respectively, γ1 and β1 represent the learnable scaling and shifting parameters, ∈ is a very small number to avoid the denominator being zero, and b1 is the model bias value, and the meanings of similar parameters in other layers are similar, and can be inferred by analogy;
[0044] Layer 3 = > MaxPooling2D: Applying maximum pooling to the batch normalization output, with a pooling window of 4x1 and a step of 1, represented as
[0045]
[0046] Layer 4 = > Conv2D: 64 convolutional filters W2 with a size of 3x1, with "same" padding and a hyperbolic tangent activation function, defined as follows:
[0047] Z2 = Conv2D(P1, W2) + b2
[0048] A2 = tanh(Z2)
[0049] Layer 5 = > Batch Normalization: Normalizing the output of the activation function A2 to improve the stability of training, defined as follows
[0050]
[0051] Layer 6 = > MaxPooling2D: Applying maximum pooling to the batch normalization output, with a pooling window of 2x1 and a step of 1, represented as
[0052]
[0053] Layer 7 => Conv2D: 128 2x1 convolutional filters W3 with "same" padding and tanh activation function defined as
[0054] Z3 = Conv2D(P2, W3) + b3
[0055] A3 = tanh(Z3)
[0056] Layer 8 => Batch Normalization: Normalization of the activation function output A3 to improve the stability of training, defined as
[0057]
[0058] Layer 9 => MaxPooling2D: Max-pooling applied to the batch normalization output with a 2x1 pooling window and a stride of 1, denoted as
[0059]
[0060] Layer 10 => Conv2D: 256 1x1 convolutional filters W4 with "same" padding and tanh activation function defined as
[0061] Z4 = Conv2D(P3, W4) + b4
[0062] A4 = tanh(Z4)
[0063] Layer 11 => Batch Normalization: Normalization of the activation function output A4 to improve the stability of training, defined as
[0064]
[0065] Layer 12 => Dropout: Dropout is applied to the output of Layer 11 with a dropout rate of 0.3 to reduce overfitting;
[0066]
[0067] Layer 13 => Flatten: The 4D tensor D4 received after the dropout operation is flattened into a 1D vector, denoted as
[0068] F = Flatten(D4)
[0069] (4) The output layer is defined as a fully connected layer with one unit, and the linear activation of the regression output is denoted as
[0070]
[0071] where W o is the weight vector and bo is a dot product operation;
[0072] (5) The model integrated with each layer is composed of a loss function and an Adam optimizer, the loss function is defined by a mean square error (MSE) loss for calculating the difference between the predicted output and the actual value y; the Adam optimizer updates the model parameters (W, b) by using the gradient of the loss function, and the initial learning rate (lr) is 0.0001; the definitions of the loss function and the optimization are as follows:
[0073]
[0074] wherein, W (t) ,b (t) represent the weight and bias term in the current iteration state, respectively, W (t+1) ,b (t+1) represent the weight and bias term updated for the next iteration calculation process, respectively, the gradient of the loss function; lr represents the learning rate; t represents the serial number of the iteration calculation.
[0075] (6) The model is trained by setting the training configuration, including defining the minimum batch size (B=32), the EPOCHS (E=500) of iterating the entire data set 500 times, the validation data set, and the early stopping criterion based on restoring the best weight when the validation performance stops improving, the model saving function f 2DCNN is available.
[0076] The specific implementation method of the dissolved oxygen concentration prediction model precision verification is as follows:
[0077] The dissolved oxygen concentration prediction model is verified by the test data set; first, the input features (B1, B2, …, B8, B 8A , B9, B 11 , B 12 , Month sin , Month cos ) in the test data set Test_Dataset are used to predict the chlorophyll a and water temperature values, which are defined as follows:
[0078]
[0079]
[0080] wherein, represents the predicted chlorophyll a concentration value, represents the predicted water temperature value; these predicted parameters are combined with the time features Month sin , Month cosConnect, prepare input data set for 2DCNN model to predict dissolved oxygen, as follows:
[0081]
[0082] The data set is used as f 2DCNN The input of the model is used to predict the dissolved oxygen value;
[0083]
[0084] Wherein, The predicted dissolved oxygen value is represented;
[0085] 2Finally, the accuracy evaluation of the model uses regression accuracy indicators, including Pearson correlation coefficient r, root mean square error RMSE, mean absolute error MAE, mean absolute percentage error MAPE and unbiased mean absolute percentage error UMAPE, etc. The predicted dissolved oxygen value And the actual dissolved oxygen value y DO Comparison.
[0086] The advantages of the present application compared with the prior art are:
[0087] (1) High precision and multi-dimensional feature fusion
[0088] The present application combines the nonlinear feature processing capability of XGBoost model and the spatio-temporal feature mining capability of 2DCNN model, indirectly estimates the dissolved oxygen concentration of water body through remote sensing reflectivity, which can effectively improve the estimation accuracy of the model, and overcome the error accumulation problem caused by single variable inversion in traditional methods.
[0089] (2) Wide spatio-temporal applicability
[0090] The present application uses satellite multispectral image data, combines chlorophyll-a, temperature and periodic characteristics, realizes short-term and long-term spatio-temporal dynamic analysis of dissolved oxygen concentration, breaks through the limitations of time continuity and spatial coverage range of the prior art, and provides a scientific basis for large-scale water environment dynamic monitoring. (Four) Description of Drawings
[0091] Figure 1 The technical process of the present application.
[0092] Figure 2 Chlorophyll a, water temperature and dissolved oxygen time series features.
[0093] Figure 3 The spatio-temporal distribution map of the dissolved oxygen concentration of the water body in Hong Kong predicted by the method of the present application. (Five) Specific Embodiment
[0094] In order to better illustrate the water dissolved oxygen concentration remote sensing inversion method based on XGBoost-2DCNN model involved in the present application, the present application is used to test and simulate the selected research area, and good effect is obtained, and the specific implementation method is as follows:
[0095] The present application relates to the collection of water quality data of 94 monitoring stations along the coast of Hong Kong for five years (2019-2023), and the extraction of the corresponding surface reflectivity of Sentinel-2 satellite. A machine learning model based on XGBoost algorithm is developed, and the surface reflectivity and periodic month features encoded by sine and cosine functions are used for training to predict Chl-a and temperature. Then a two-dimensional convolutional neural network (2DCNN) model is developed, and a training dataset (2019-2022) composed of Chl-a, temperature and encoded periodic month features (2019-2022) is used for training to estimate dissolved oxygen. The present application introduces the XGBoost-2DCNN inversion method for estimating dissolved oxygen from satellite remote sensing reflectivity, which can be used for short-term and long-term spatio-temporal analysis.
[0096] Step 1: Extracting water surface reflectivity and preparing training and test datasets
[0097] (1) Taking the European Space Agency Sentinel-2 satellite as an example, the Level-2A image of the COPERNICUS / S2_SR dataset is obtained from the GEE platform, which contains the surface reflectivity value of each pixel of the Sentinel-2 satellite image after preprocessing and atmospheric correction and auxiliary information. In order to extract the Level-2A image according to the area of interest (AOI) and the specific date, it is necessary to define the spatial polygon / bounding box and the date range to filter the image set. The definition of the area of interest is as follows:
[0098] AOI={(x,y)∈R 2 ∣x∈[x min ,x max ],y∈[y min ,y max ]}
[0099] Where (x,y) is the coordinate in the defined spatial reference system, x min ,x max ,y min ,y max respectively represent the AOI bounding box limits expressed in minimum and maximum longitude and latitude.
[0100] For each target date D, create a date range D range centered at D, spanning from D-5 days to D+5 days:
[0101] D range= {D - 5, D - 4, D - 3,..., D,..., D + 3, D + 4, D + 5}
[0102] The collected images according to AOI and D range The screening is performed to obtain a set of Sentinel-2 images I in the specified time and spatial range as shown below:
[0103]
[0104] where I j represents each image in the filtered set; Sentinel-2 SR represents the Sentinel-2 Level-2A surface reflectance image dataset; D i represents the date of the target image, which is within the range of D range . represents that the image I j intersects with the specified AOI.
[0105] (2) Extract the surface reflectance values and auxiliary information from each image in the image dataset I and compare them with each monitoring station, which is specifically defined as follows.
[0106] P = {P i | P i ∈ (x i , y i )}
[0107] where P i is the i-th point in the monitoring station vector file, (x i , y i ) represents the latitude and longitude coordinates of P i .
[0108] Each P i is a sampling point, from which the surface reflectance values of B1 to B 12 bands (excluding B 10 band) and the scene classification layer (SCL) band (which can divide pixels into clear land, water, cloud, etc. categories) of each image I j can be extracted. The reflectance of band B k at pixel coordinates (x i , y i ) can be represented by B k (I j ), where k ∈ {1, 2,..., 8, 8A, 9, 11, 12}. For each pixel position (x i , y i ) in I j , the reflectance data of each band is extracted and divided by a scale factor of 10,000, and the extracted reflectance data includes the following information;
[0109]
[0110] Likewise, I j Each pixel position (x i ,y i )’s SCL classification is annotated using the following category types and formula (6);
[0111]
[0112] is_cloud: When When is the cloud covered pixel;
[0113] is_cloud_shadow:When When , it is a pixel in the cloud shadow;
[0114] is_cirrus: When When , it is cirrus cloud pixel;
[0115] is_snow_ice: When When , it is a pixel covered by snow or ice;
[0116] is_clear: When When , it is a clear pixel.
[0117] I j Medium P i Each data record is accompanied by a Date(I j ) represents the image acquisition date and reference target date. The final output of each point includes the reflectance value of each band in each image, the category type obtained by SCL classification, the image acquisition date and the target reference date. Its mathematical expression is as follows;
[0118]
[0119] Records with a scene classification type of "is_clear" and duplicate records were removed, while retaining records where the difference between the satellite image acquisition date and the target reference date (sample collection date) was smaller than the number of days. Furthermore, the extracted in situ water quality data were linked to these records based on the monitoring station code and the target reference date. The dataset retained the necessary fields, including water control area, monitoring station code, monitoring station geographic coordinates, band reflectance value, sample collection date, Chl-a, temperature, and dissolved oxygen.
[0120] (3) Extract the records from 2019 to 2022 from the final dataset to prepare two training datasets. One training dataset contains input features (including reflectance data and converted month features) and output features (including Chl-a and temperature) for training the machine learning algorithm for univariate prediction of Chl-a and temperature. The dataset is represented as
[0121] Training_Dataset Chla_Temperature =
[0122] {B1,B2,…,B8,B 8A ,B9,B 11 ,B 12 ,Month sin ,Month cos ,Chl-a,Temperature}
[0123] The other training datasets contain input features, including Chl-a, temperature, and conversion month features, as well as labeled dissolved oxygen output features, which are used to train the convolutional neural network model for dissolved oxygen univariate prediction. This dataset is represented as
[0124] Training_Dataset DO ={Chl-a,Temperature,Month sin ,Month cos ,DO}
[0125] (4) The records of 2023 are extracted from the final dataset to prepare the test dataset. The dataset contains input features, including reflectance data and converted monthly features. The first stage is used to predict Chl-a and temperature, and then the predicted parameters are used to predict dissolved oxygen. The dataset is represented as
[0126] Test_Dataset={B1,B2,…,B8,B8A,B9,B11,B12,Month sin ,Month cos}
[0127] Step 2: Chl-a and Temperature Modeling
[0128] Based on the machine learning algorithm eXtreme Gradient Boosting (XGBoost), the complex relationship between water quality parameters and satellite optical characteristics is captured for water quality monitoring; using Training_Dataset Chla_TemperatureThe dataset is used to train the XGBoost model with optimal hyperparameters to estimate chlorophyll-a and water temperature; for each target variable, the training dataset is divided into input features and target outputs. For each parametric model, the XGBoost algorithm is used for training, with the objective function being to minimize the prediction error.
[0129] Step 3: Dissolved oxygen concentration prediction modeling
[0130] A two-dimensional convolutional neural network (2DCNN) model is developed and trained using input parameters such as chlorophyll-a, water temperature, and conversion month features to estimate dissolved oxygen; the 2DCNN model is trained using optimal hyperparameters to minimize training and validation loss; the steps to train and develop the 2DCNN model are as follows:
[0131] (1) The training dataset Training_Dataset DO is divided into input features and target outputs:
[0132] X DO = Training_Dataset DO \{DO}
[0133] Y DO = Training_Dataset DO [′DO′]
[0134] (2) The input feature vector X DO ∈R 4×1 represents a one-dimensional data composed of 4 features: Chla, Temperature, Month sin , Month cos , each with a value:
[0135] X′ DO ∈R 4×1×1
[0136] (3) 13 layers are defined with different hyperparameters to perform convolution, pooling, and batch normalization operations on the input features to generate the required output.
[0137] Step 4: Precision verification of dissolved oxygen concentration prediction model
[0138] The dissolved oxygen concentration prediction model is verified by the test dataset; first, the input features (B1, B2, …, B8, B 8A , B9, B 11 , B 12 , Month sin , Month cos) Predicted chlorophyll-a and water temperature values, defined as follows:
[0139]
[0140] wherein, represents the predicted chlorophyll-a concentration value, represents the predicted water temperature value; these predicted parameters are connected with the time feature Month sin , Month cos to prepare the input data set for the 2DCNN model to predict the dissolved oxygen, as follows:
[0141]
[0142] This data set is used as the input of the f 2DCNN model to predict the dissolved oxygen value;
[0143]
[0144] wherein, represents the predicted dissolved oxygen value;
[0145] Finally, the accuracy evaluation of the model uses the regression accuracy indicators, including r, RMSE, MAE, MAPE and UMAPE, etc. to compare the predicted dissolved oxygen value with the actual dissolved oxygen value y DO .
[0146] Finally, it should be noted that the above is only the preferred embodiment of the present application and the technical principles applied. Those skilled in the art will understand that the present application is not limited to the specific embodiments described herein, and those skilled in the art can make various obvious changes, re-adjustments and substitutions without departing from the scope of the present application. Therefore, although the present application has been described in more detail through the above embodiments, the present application is not limited to the above embodiments, and can include more other equivalent embodiments without departing from the concept of the present application, and the scope of the present application is determined by the scope of the appended claims.
Claims
1. A remote sensing inversion method for dissolved oxygen concentration in water based on the XGBoost-2DCNN model, characterized in that The following steps are involved: (1) Collect, process, and standardize data for training the water body dissolved oxygen (DO) concentration prediction model. The specific method is as follows: 1) Collect and collect long-term in situ water quality measurement data from the study area, including various optically active and inactive water quality parameters, as well as metadata such as the geographical coordinates of the water quality monitoring stations, data quality, and acquisition date; Extract necessary data from the collected datasets, including water quality control areas, monitoring station codes, monitoring station geographic coordinates, sampling dates, chlorophyll a, water temperature, and dissolved oxygen (DO); compile polygon vector files of the area of interest (AOI) for the study area; and establish a spatiotemporal matching dataset containing in situ water quality parameter measurements and corresponding satellite multispectral imagery water surface reflectance values. Google Earth Engine (GEE) was used to extract water surface reflectance spectra for each water quality monitoring station and sample collection date; 2) Incorporate the seasonal variation trend of water quality parameter concentrations into the modeling of dissolved oxygen concentration prediction; use the time information - month as the input parameter of the modeling, and encode the month into a periodic variable through sine and cosine transformations, as shown below: Where x represents the month; This conversion ensures that all months are correctly positioned on the circular scale and accurately represents their periodic patterns by capturing both the period angle and amplitude; the converted month feature is denoted as Month sin and Month cos , which will be used as input features for the dissolved oxygen prediction model; 3) Extract data records from the study period from the prepared dataset to prepare two training datasets. One training dataset contains input features: spectral reflectance data and converted monthly features; output features include chlorophyll a and water temperature, which are used to train a machine learning algorithm for univariate prediction of chlorophyll a and water temperature. Taking the optical remote sensing image Sentinel-2 as an example, the dataset is represented as: Training_Dataset Chla_Temperature ={B1,B2,…,B8,B 8A ,B9,B 11 ,B 12 ,Month sin ,Month cos ,Chla,Temperature} Another training dataset contains input features including chlorophyll a, water temperature, and transition month features, as well as labeled dissolved oxygen output features, which are used to train a convolutional neural network model for single-variable prediction of dissolved oxygen. This dataset is represented as Training_Dataset DO ={Chla,Temperature,Month sin ,Month cos ,DO} 4) Extract the data records of the study period from the prepared dataset to prepare the test dataset. The dataset contains input features including reflectance data and converted monthly features. The first stage is used to predict chlorophyll a and water temperature, and then the prediction is used to predict dissolved oxygen. The dataset is represented as Test_dataset={B1,B2,…,B8,B 8A ,B9,B 11 ,B 12 ,Month sin ,Month cos } (2) Construct a water chlorophyll a concentration and water temperature prediction model based on the XGBoost machine learning model; (3) Develop a two-dimensional convolutional neural network model (2DCNN) to predict dissolved oxygen concentration. The specific method is to develop a two-dimensional convolutional neural network (2DCNN) model and train it using chlorophyll a, water temperature, and transition month feature input parameters to predict dissolved oxygen concentration. The steps for training and developing the 2DCNN model are as follows: 1) The training data set Training_Dataset DO Divided into input features and target output: X DO =Training_Dataset DO \{DO} Y DO =Training_Dataset DO [′DO′] 2) Input feature vector X DO ∈R 4×1 It is represented by 4 features: Chla, Temperature, Month sin ,Month cos ), each feature has a value: X′ DO ∈R 4×1×1 3) 13 layers are defined with different hyperparameters to perform operations such as convolution, pooling, and batch normalization on the input features to generate the desired output. The definitions of these layers are as follows: Layer 1 => Conv2D: 32 convolutional filters W1 of size 4×1 with “same” padding and hyperbolic tangent activation function, applied to the input features defined as follows: Z1=Conv2D(X′ DO ,W1)+b1 A1=tanh(Z1) Layer 2 => Batch Normalization: Normalize the activation function output A1 to improve the stability of model training. It is defined as follows Among them, μ1 and denote the mean and variance of A1, γ1 and β1 denote the learnable scaling and shifting parameters, respectively; ∈ is a very small number to avoid the denominator of the formula being 0; b1 is the model bias value, and the meanings of similar parameters in subsequent layers are similar. Layer 3 => MaxPooling2D: applies max pooling to the batch normalized output with a pooling window of 4×1 and a stride of 1, expressed as Layer 4 => Conv2D: 64 convolutional filters W2 of size 3×1, with “same” padding and hyperbolic tangent activation function as follows: Z2=Conv2D(P1,W2)+b2 A2=tanh(Z2) Layer 5 => Batch Normalization: Normalize the activation function output A2 to improve the stability of training. It is defined as follows Layer 6 => MaxPooling2D: applies max pooling to the batch normalized output with a pooling window of 2×1 and a stride of 1, expressed as Layer 7 => Conv2D: 128 convolutional filters W3 of size 2×1 with “same” padding and hyperbolic tangent activation function as follows: Z3=Conv2D(P2,W3)+b3 A3=tanh(Z3) Layer 8 => Batch Normalization: Normalize the activation function output A3 to improve the stability of training. It is defined as follows Layer 9 => MaxPooling2D: applies max pooling to the batch normalized output with a pooling window of 2×1 and a stride of 1, expressed as Layer 10 => Conv2D: 256 convolutional filters of size 1×1 W4 with “same” padding and hyperbolic tangent activation function as follows: Z4=Conv2D(P3,W4)+b4 A4=tanh(Z4) Layer 11 => Batch Normalization: Normalize the activation function output A4 to improve the stability of model training. It is defined as follows Layer 12 => Dropout: A dropout rate of 0.3 is used to drop out to reduce model overfitting; Layer 13 => Flatten: Flattens the 4D tensor D4 after the Dropout operation into a 1D vector, which is represented by F = Flatten(D4) 4) The output layer is defined as a fully connected layer with one unit, and the linear activation of the regression output is expressed as Among them, W o is the weight vector, b o is the bias term, · represents the dot product operation; 5) The model integrated with the above layers consists of a loss function and an Adam optimizer. The loss function is defined by the mean square error (MSE) loss and is used to calculate the predicted output. The difference between the actual value y and the original value y; the Adam optimizer updates the model parameters (W, b) using the gradient of the loss function, with an initial learning rate (lr) of 0.0001; the loss function and optimization are defined as follows; Among them, W (t) ,b (t) Represent the weight and bias terms in the current iteration state, W (t+1) ,b (t+1) Represent the weight and bias terms updated in the next iterative calculation process, The gradient of the loss function; lr represents the learning rate; t represents the sequence number of iterative calculation; 6) Train the model by setting the training configuration, including defining the minimum batch size (B=32), EPOCHS (E=500) of 500 iterations over the entire dataset, the validation dataset, and the early stopping criterion based on restoring the best weights when the validation performance stops improving. The available function f after the model is saved 2DCNN express; (4) Verification of the accuracy of the dissolved oxygen concentration prediction model.
2. The method for remote sensing inversion of dissolved oxygen concentration in water based on the XGBoost-2DCNN model according to claim 1, characterized in that: The specific method of "building a water chlorophyll a concentration and water temperature prediction model based on the XGBoost machine learning model" described in step (1) is as follows: Based on the machine learning algorithm eXtreme Gradient Boosting (XGBoost), the complex relationship between water quality parameters and satellite optical characteristics is captured to predict water quality concentration; using Training_Dataset Chla_Temperature The dataset was used to train the XGBoost model using the optimal hyperparameters to estimate chlorophyll a and water temperature. For each target variable, the training dataset was split into input features and target output as follows: X Chla_Temperature =Training_Dataset Chla_Temperature \{Chla,Temperature} Y Chla =Training_Dataset Chla_Temperature [Chla] Y Temperature =Training_Dataset Chla_Temperature [′Temperature′] For each parameter model, the XGBoost algorithm is used for training, and its objective function is to minimize the prediction error, which is specifically expressed as follows: f XGBOOST,Chla (X Chla_Temperature )=argmin∑ i (Y Chla,i -f(X Chla_Temperature,i )) 2 Where i represents the i-th sample value, f(X) represents the function of the model to predict chlorophyll a or water temperature based on the input features, and the goal is to minimize the sum of the squared errors between the predicted value and the actual value.
3. The method for remote sensing inversion of dissolved oxygen concentration in water based on the XGBoost-2DCNN model according to claim 1, characterized in that: The specific method for "dissolved oxygen concentration prediction model accuracy verification" described in step (1) is as follows: The dissolved oxygen concentration prediction model is verified by the test data set. First, the input features (B1, B2, ..., B8, B 8A ,B9,B 11 ,B 12 ,Month sin ,Month cos ) predicts chlorophyll a and water temperature values, defined as follows: in, represents the predicted chlorophyll a concentration value, Represents the predicted water temperature value; these prediction parameters are combined with the time characteristic Month sin ,Month cos Connect them and prepare the input dataset for the 2DCNN model to predict dissolved oxygen as follows: The dataset is f 2DCNN Input to the model, used to predict dissolved oxygen values; in, represents the predicted dissolved oxygen value; Finally, the accuracy of the model was evaluated using regression accuracy indicators, including Pearson correlation coefficient r, root mean square error RMSE, mean absolute error MAE, mean absolute percentage error MAPE and unbiased mean absolute percentage error UMAPE to predict dissolved oxygen values. and the actual dissolved oxygen value y DO Make a comparison.
Citation Information
Patent Citations
Two-stage fine-grained network intrusion detection model based on LightGBM algorithm and convolutional neural network
CN114710306A
Chlorophyll concentration remote sensing inversion method for sparse site data
CN115661661A