Full-automatic Raman spectrum baseline correction method and system

By combining the ResUnet architecture and a multi-index evaluation strategy, the dynamic iterative weighted algorithm solves the problem of parameter adjustment in Raman spectroscopy baseline correction, realizes automated and rapid baseline correction, adapts to complex spectra, and improves the reliability of analysis.

CN122024892APending Publication Date: 2026-05-12XIAMEN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
XIAMEN UNIV
Filing Date
2026-01-20
Publication Date
2026-05-12

AI Technical Summary

Technical Problem

Existing Raman spectroscopy baseline correction methods require manual parameter adjustment, making it difficult to balance preserving peak intensity information with removing noise interference. They are also slow to process and difficult to adapt to complex spectra.

Method used

A deep learning network based on the ResUnet architecture is used to identify spectral peak regions. A multi-index evaluation strategy is combined to adaptively optimize smoothing parameters, and an improved dynamic iterative weighting algorithm is introduced to perform baseline correction using penalized least squares.

Benefits of technology

It achieves efficient, accurate, and automated correction of Raman spectral baselines, adapts to complex spectra, and improves processing efficiency and the reliability of qualitative and quantitative analysis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122024892A_ABST
    Figure CN122024892A_ABST
Patent Text Reader

Abstract

The invention discloses a full-automatic Raman spectrum baseline correction method and system, and the method comprises the steps: introducing a deep learning algorithm on the basis of chemometrics, recognizing peak and background regions in a spectrogram through a weight output model based on deep learning, and outputting an initial weight vector; and then adaptively optimizing a smoothness parameter based on a multi-index evaluation strategy, finally performing dynamic weighted iteration by adopting a more robust dynamic iteration reweighted penalty least square method algorithm to fit a background curve, and outputting a final corrected baseline. The method can solve the problems that in an existing Raman spectrum baseline correction method, parameters need to be manually adjusted, balance between peak intensity information reserving and noise interference removing is difficult to obtain, the processing speed is low and the like, baseline correction of the Raman spectrum is achieved on the premise that the reliable peak position and intensity of the Raman spectrum peak are obtained, and the method is suitable for large-scale popularization and application. The method has a supporting effect on qualitative and quantitative analysis of Raman spectrum, is high in operation speed, and can be used for processing large-scale data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of Raman spectroscopy post-processing technology, and in particular to a fully automated Raman spectroscopy baseline correction method and system. Background Technology

[0002] Raman spectroscopy, especially surface-enhanced Raman spectroscopy, has become an important spectroscopic technique for molecular structure analysis due to its high-resolution fingerprinting and high sensitivity at the single-molecule level. Raman spectroscopy-based structural relationship analysis has been widely applied in many fields, including surface science, life sciences, food safety, and environmental monitoring.

[0003] During Raman spectroscopy, due to limitations in filter transmittance and bandwidth, some unfiltered Rayleigh scattering remains in the low wavenumber region of the Raman spectrum, exhibiting a background similar to exponential decay. Furthermore, fluorescence signals originating from the sample itself or impurities appear as broad peaks or continuous baselines in the Raman spectrum; photoluminescence originating from the SERS substrate appears as a spike across the entire spectral measurement range. Therefore, baseline correction must be performed on the spectra before spectral-structural analysis.

[0004] Currently, baseline correction methods for Raman spectroscopy data are mainly divided into two categories. One category is based on polynomial fitting algorithms: the background is treated as a curve composed of a polynomial function of a certain order, and the polynomial background is fitted using the least squares method. The core idea is to iteratively eliminate "peak points" higher than the fitted curve, retaining only "background points" for the next fitting, until the termination condition is met. While this method is intuitive, it is extremely sensitive to the choice of polynomial order. Too low an order cannot fit complex, curved backgrounds, while too high an order will cause spurious fluctuations in the baseline in peakless regions. The other category is based on penalized least squares: the baseline is fitted by minimizing an objective function containing a "fidelity term" and a "roughness penalty term." It does not rely on local windows but performs global optimization across the entire spectrum, preserving the spectral contour while using the penalty term to force the baseline to remain smooth. For example, the Adaptive Iterative Weighted Least Squares Baseline Correction (airPLS) algorithm introduces an adaptive iterative weighting strategy, estimating the baseline and adaptively adjusting the weights under the penalty smoothness constraint to achieve spectral baseline correction. While such methods are more robust than polynomial methods, their effectiveness is highly dependent on the settings of the smoothness parameter and asymmetric weights. Therefore, this work attempts to develop a novel algorithm capable of adapting to baseline correction processing of complex spectra. Summary of the Invention

[0005] The purpose of this invention is to overcome the shortcomings of existing technologies, namely, the need for manual parameter adjustment, the difficulty in balancing peak intensity information preservation with noise removal, and slow processing speed in existing Raman spectral baseline correction methods. This invention proposes a fully automated Raman spectral baseline correction method and system. By constructing a deep learning network ResUnet containing residual connections and a U-symmetric structure to intelligently identify spectral peak regions, combining a multi-index evaluation strategy to adaptively optimize smoothing parameters, and introducing an improved dynamic iterative weighting algorithm, this invention achieves efficient, accurate, and automated Raman spectral baseline correction, capable of handling baseline correction of complex spectra.

[0006] The technical solution adopted by this invention to solve its technical problem is:

[0007] On the one hand, a fully automated Raman spectral baseline correction method includes:

[0008] Obtain raw Raman spectral data; the raw Raman spectral data includes constructed simulated Raman spectral data or real experimental data;

[0009] The original Raman spectral data is input into the trained weighted output model, which outputs a binarized initial weight vector to identify the peak region and the background region. The weighted output model is built on the ResUnet architecture, and its training samples consist of a simulated Raman spectral dataset labeled with the peak region and the background region.

[0010] Based on the initial weight vector, the penalized least squares (PLS) method is used to traverse and search within the preset smoothness parameter range, and an initial baseline is obtained by fitting each candidate smoothness parameter. Then, the correction quality of each initial baseline is quantitatively evaluated through a multi-index comprehensive evaluation strategy, and the optimal smoothness parameter is adaptively selected.

[0011] The original Raman spectral data, initial weight vector, and optimal smoothness parameters are used as inputs and substituted into the more robust adaptive iterative weighted least squares baseline correction algorithm Dr-airPLS for iterative correction. During the iteration process, the weight vector is dynamically optimized according to the baseline fitting situation until the preset conditions are met, and the final corrected baseline is output.

[0012] Preferably, the process of constructing the simulated Raman spectroscopy dataset includes:

[0013] Using Gaussian, Lorentz, and Voigt functions as basic line shapes, Raman spectral peaks with different peak shapes are simulated and combined to obtain Raman spectra containing a preset number of Raman peaks. Gaussian noise with an intensity within a preset range is then added. Subsequently, randomly generated exponential and polynomial curves are added to simulate fluorescence background and Rayleigh scattering background, respectively, to establish a simulated Raman spectral dataset containing diverse backgrounds.

[0014] Preferably, the construction and training process of the weighted output model includes:

[0015] A weighted output model combining residual connections and U-Net structure was constructed using the ResUnet framework. The weighted output model was trained using the simulated Raman spectroscopy dataset. During training, the AdamW optimizer was used, and the learning rate was automatically adjusted using the cosine annealing algorithm. The optimization objective was to minimize the binary cross-entropy loss (BCE Loss) between the predicted weights and labels until the weighted output model converged.

[0016] Preferably, the multiple indicators include the smoothness of the fitted initial baseline, the proportion of negative points in the corrected spectrum, the average value of the negative region in the corrected spectrum, and the kurtosis of the corrected spectrum.

[0017] Preferably, a multi-index comprehensive evaluation strategy is used to quantitatively evaluate the correction quality of each initial baseline, and the optimal smoothness parameter is adaptively selected, specifically including:

[0018] The scores for the smoothness of the fitted initial baseline, the proportion of negative points in the corrected spectrum, the average value of the negative region in the corrected spectrum, and the kurtosis of the corrected spectrum are normalized to the [0,1] interval and then summed to obtain the comprehensive evaluation index. ;

[0019] Select the comprehensive evaluation indicator with the lowest score The corresponding smoothness parameter is taken as the optimal smoothness parameter.

[0020] Preferably, the comprehensive evaluation index It is expressed as follows:

[0021] ;

[0022] in, This indicates the smoothness of the initial baseline after Min-Max normalization; This represents the proportion of negative points after Min-Max normalization. This represents the average value of the negative value region after Min-Max normalization. This represents the kurtosis after Min-Max normalization.

[0023] The preferred dynamically optimized weight vector is represented as follows:

[0024] ;

[0025] in, For the number of data points, For the number of iterations, This represents the intensity vector of the original Raman spectrum. This represents the initial weight vector output by the weighted output model. Indicates using The intensity vector of the initial baseline obtained by fitting with the optimal smoothness parameters. Indicates the first The weights of the corresponding data points after each iteration Indicates the first The weight of the corresponding data point after -1 iterations Indicates the first The intensity vector corresponding to the baseline after the next iteration. Indicates the first The intensity vector corresponding to the baseline after -1 iterations.

[0026] Preferably, the preset conditions include preset convergence conditions or preset number of iterations.

[0027] Preferably, the preset convergence condition is that the absolute value of the sum of the deviations between the baseline and the original Raman spectrum is less than a preset threshold.

[0028] On the other hand, a fully automated Raman spectral baseline correction system includes:

[0029] A Raman spectroscopy data acquisition module is used to acquire raw Raman spectroscopy data; the raw Raman spectroscopy data includes constructed simulated Raman spectroscopy data or real experimental data;

[0030] The initial weight vector identification module is used to input the original Raman spectral data into the trained weight output model and output a binarized initial weight vector to identify the peak region and the background region. The weight output model is built based on the ResUnet architecture, and its training samples consist of a simulated Raman spectral dataset labeled with the peak region and the background region.

[0031] The optimal smoothness parameter selection module is used to perform a traversal search within a preset smoothness parameter range based on the initial weight vector using the penalized least squares (PLS) method, and fit an initial baseline for each candidate smoothness parameter; then, the correction quality of each initial baseline is quantitatively evaluated through a multi-index comprehensive evaluation strategy, and the optimal smoothness parameter is adaptively selected.

[0032] The baseline correction output module is used to take the original Raman spectral data, initial weight vector and optimal smoothness parameters as input, and substitute them into the more robust adaptive iterative weighted least squares baseline correction algorithm Dr-airPLS for iterative correction. During the iteration process, the weight vector is dynamically optimized according to the baseline fitting situation until the preset conditions are met, and the final corrected baseline is output.

[0033] As can be seen from the above description of the present invention, compared with the prior art, the present invention has the following beneficial effects:

[0034] (1) This invention accurately identifies peak and background regions through the ResUnet architecture and combines a multi-index evaluation strategy to avoid the local optima problem caused by a single objective function in traditional methods, and effectively solves the problems of baseline distortion and underfitting.

[0035] (2) The Dr-airPLS algorithm proposed in this invention uses a dynamic weight update strategy to perform cumulative correction based on the baseline oversubtraction region, so that while removing complex fluorescence background, the algorithm can retain the peak intensity information of weak peaks and overlapping peaks to the greatest extent, thereby improving the reliability of subsequent qualitative and quantitative analysis.

[0036] (3) This invention combines the feature extraction capability of deep learning, the optimization capability of the penalized least squares (PLS) algorithm, and the weight update capability of the Dr-airPLS algorithm. It can automatically complete the entire process from weight identification to parameter optimization without manual adjustment of parameters or preset thresholds, which greatly improves the processing efficiency of large-scale Raman spectral data and is applicable to baseline correction processing of complex spectra. Attached Figure Description

[0037] Figure 1 This is a flowchart of a fully automated Raman spectroscopy baseline correction method according to an embodiment of the present invention;

[0038] Figure 2 This is a schematic diagram of the structure of the fully automatic weight output model according to an embodiment of the present invention;

[0039] Figure 3 This is a flowchart of the Dr-airPLS iteration process according to an embodiment of the present invention;

[0040] Figure 4 The background curve (A) predicted on the simulated spectrum and the background curve (B) predicted on the fishmeal experimental spectrum are examples of the embodiments of the present invention.

[0041] Figure 5 This is a block diagram of the fully automated Raman spectroscopy baseline correction system according to an embodiment of the present invention. Detailed Implementation

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

[0043] In the description of this invention, it should be noted that the terms "comprising," "including," or any other variations thereof are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0044] like Figure 1 As shown in the figure, this embodiment presents a fully automated Raman spectral baseline correction method, which includes the following steps.

[0045] S101, Obtain raw Raman spectral data; the raw Raman spectral data includes constructed simulated Raman spectral data or real experimental data.

[0046] Specifically, the simulated Raman spectral data refers to the data in the constructed simulated Raman spectral dataset.

[0047] The specific construction process of the simulated Raman spectrum dataset is as follows: the Gaussian function, Lorentz function and Voigt function are used to simulate Raman spectral peaks with different peak shapes, and the combinations are used to obtain a Raman spectrum containing n Raman spectral peaks, where n∈[10,20]; Gaussian noise with intensity m is added, where m∈[0.001,0.02]; then randomly generated exponential and polynomial curves are added to simulate fluorescence background and Rayleigh scattering background respectively, and a Raman spectrum training dataset containing diverse backgrounds is established.

[0048] S102, the original Raman spectral data is input into the trained weight output model, and the initial weight vector for identifying the peak region and background region is output; the weight output model is built based on the ResUnet architecture, and its training samples consist of a simulated Raman spectral dataset labeled with the peak region and background region.

[0049] Specifically, the construction and training process of the weight output model is as follows: the weight output model is built using the ResUnet architecture, which combines residual connections and U-Net structure; the model is trained using the Raman spectroscopy training dataset, and the AdamW optimizer is used during the training process, combined with the cosine annealing algorithm to automatically adjust the learning rate. The optimization objective is to minimize the binary cross-entropy loss (BCE Loss) between the predicted weights and labels until the model converges.

[0050] S103, based on the initial weight vector, uses the penalized least squares (PLS) method to traverse and search within the preset smoothness parameter range, and fits an initial baseline for each candidate smoothness parameter; then, a multi-index comprehensive evaluation strategy is used to quantitatively evaluate the correction quality of each initial baseline, and adaptively selects the optimal smoothness parameter.

[0051] Specifically, the multiple indicators include the smoothness of the fitted initial baseline, the proportion of negative points in the corrected spectrum, the average value of the negative region in the corrected spectrum, and the kurtosis of the corrected spectrum.

[0052] The correction quality of each initial baseline is quantitatively evaluated using a multi-index comprehensive evaluation strategy, and the optimal smoothness parameter is adaptively selected, specifically including:

[0053] Smoothness of the fitted initial baseline The proportion of negative points in the corrected spectrum The average value of the negative region of the corrected spectrum and the peak size of the corrected spectrum The scores were normalized to the [0,1] interval and then summed to obtain the comprehensive evaluation index. ;

[0054] Select the comprehensive evaluation indicator with the lowest score The corresponding smoothness parameter is taken as the optimal smoothness parameter.

[0055] Furthermore, the calculation formulas for each indicator are as follows.

[0056] Smoothness of the fitted baseline: ;

[0057] The proportion of negative points in the corrected spectrum: ;

[0058] Average value of the negative region of the corrected spectrum: ;

[0059] Peak size of the corrected spectrum: ;

[0060] ;

[0061] in, This is the spectrum vector after initial baseline correction. The fitted background curve vector, where n is the number of data points. This represents the points where y < 0, and m represents the number of data points with negative values ​​in the baseline-corrected spectrum. Indicates sample The value, For the sample The corresponding average value, For the sample The fourth central moment, For the sample The square of the variance. The smoothness of the overall baseline is evaluated based on the second derivative of the fitted baseline; The overall baseline was assessed by calculating the proportion of negative points in the corrected spectral intensity; The severity of local distortion regions is assessed by calculating the average absolute value of the negative regions in the corrected spectral intensity. The kurtosis of the corrected spectrum is used to assess whether the local baseline is undersubtracted.

[0062] The scores of each sub-indicator are normalized to the [0,1] interval using Min-Max and then summed to obtain the result. Select the lowest The corresponding smoothness parameter is used as the optimal smoothness parameter. The comprehensive evaluation indicators It is expressed as follows:

[0063] ;

[0064] in, Indicates to Smoothness of the initial baseline after Min-Max normalization; Indicates to The proportion of negative points after Min-Max normalization; Indicates to The average value in the negative region after Min-Max normalization; Indicates to Kuness after Min-Max normalization.

[0065] S104, the original Raman spectral data, initial weight vector and optimal smoothness parameter are taken as input and substituted into the more robust adaptive iterative weighted least squares baseline correction algorithm Dr-airPLS for iterative correction. During the iteration process, the weight vector is dynamically optimized according to the baseline fitting situation until the preset conditions are met, and the final corrected baseline is output.

[0066] Specifically, the Dr-airPLS algorithm introduces a cumulative correction strategy based on historical weights, dynamically optimizing the weights during the iteration process according to the baseline fitting. The weight update formula is as follows:

[0067] ;

[0068] in, For the number of data points, For the number of iterations, This represents the intensity vector of the original Raman spectrum. This represents the initial weight vector output by the weighted output model. Indicates using The intensity vector of the initial baseline obtained by fitting with the optimal smoothness parameters. Indicates the first The weights of the corresponding data points after each iteration Indicates the first The weight of the corresponding data point after -1 iterations Indicates the first The intensity vector corresponding to the baseline after the next iteration. Indicates the first The intensity vector corresponding to the baseline after -1 iterations.

[0069] As can be seen from the above, the Dr-airPLS algorithm strategy is effective in the baseline over-subtraction region (i.e., > A coefficient positively correlated with the degree of deviation is introduced to ensure that points with greater deviations have a larger weight amplification in the next iteration, while the original weights of the model output are retained in other regions.

[0070] Furthermore, the preset conditions include preset convergence conditions or preset number of iterations.

[0071] The preset convergence condition is that the absolute value of the sum of the deviations between the baseline and the original Raman spectrum is less than a preset threshold.

[0072] The following will illustrate this with a practical application example.

[0073] In order to train a highly robust deep learning-based weighted output model, this embodiment does not directly use limited real experimental data, but instead constructs a large-scale simulated dataset containing 400,000 spectra for training.

[0074] Specifically, Gaussian, Lorentz, and Voigt functions are used as basic line shapes, and random combinations are used to generate background-free spectra containing 10 to 20 Raman peaks. Based on these spectra, Gaussian noise with intensities ranging from 0.001 to 0.02 is superimposed to simulate different signal-to-noise ratio environments. Simultaneously, linear combinations of randomly generated exponential and polynomial curves are used to simulate common fluorescence and Rayleigh scattering backgrounds encountered in actual tests, thus proposing a Raman spectral training dataset containing diverse backgrounds.

[0075] like Figure 2 As shown, the weight output model in this embodiment is built on the ResUnet architecture.

[0076] Specifically, during training, the hardware environment used was an NVIDIA GeForce GTX 1070 Ti GPU. The input data was the simulated spectrum mentioned above, with labels representing the corresponding ideal binary weights (0 for peak regions and 1 for background regions). The model optimizer used was AdamW, with an initial learning rate set to 0.001. Cosine annealing was introduced to dynamically adjust the learning rate to avoid the model getting trapped in local minima and to accelerate convergence.

[0077] Specifically, the algorithm pre-defines a series of candidate... Values ​​(e.g., in the range

[10] ) 1 , 10 11 Within this framework, candidate smoothness parameters (incrementing by multiples of 10) are substituted into the fitted background to obtain the corresponding initial baselines. For each fitted background, sub-index scores are calculated from four dimensions: smoothness of the fitted initial baseline, proportion of negative points in the corrected spectrum, average value of the negative region in the corrected spectrum, and kurtosis of the corrected spectrum. To eliminate the influence of different index units, a sub-index is used when calculating the total score. First, each sub-indicator is normalized using Min-Max, mapping it to the [0,1] interval. Finally, the index with the lowest total score is selected. The value is used as a fixed smoothing parameter for this spectrum in the subsequent Dr-airPLS algorithm. This process is fully automated and requires no manual intervention.

[0078] like Figure 3 As shown, the original spectrum, the initial weights predicted by the model, and the optimal... Substitute the values ​​into the Dr-airPLS algorithm.

[0079] Specifically, during the iteration process, the algorithm is based on the positional relationship between the background and the original spectrum. For "over-subtracted regions" where the intensity of the fitted background curve is higher than that of the original spectrum, the algorithm uses the weight update strategy described in the aforementioned invention to calculate a correction coefficient that is positively correlated with the degree of deviation. This coefficient causes points with greater deviations to be penalized more severely in the next iteration (weights increase), thus forcing them back to the normal baseline position; while for normal background regions, the initial weights of the model output are maintained. The convergence threshold is set to 10. -6 After each iteration, the cumulative sum of the deviations between the current fitted baseline and the original spectrum across all "oversubtraction regions" is calculated. When this cumulative sum is less than the threshold, it indicates that the baseline has effectively eliminated oversubtraction and closely follows the background; at this point, the iteration is stopped and the results are output.

[0080] To verify the effectiveness of the method in this embodiment, it was applied to simulated spectral data and experimental spectral data, and compared with the classic airPLS algorithm.

[0081] like Figure 4 As shown, in this embodiment, when processing complex spectra containing overlapping peaks and weak signals, thanks to ResUnet's accurate identification of peak regions and Dr-airPLS's dynamic correction, the fitted background curve ( Figure 4 (As shown by the red line) It can pass close to the bottom of the fluorescent background and maintain the complete peak height in the sharp peak area.

[0082] like Figure 5 As shown, this embodiment also discloses a fully automated Raman spectroscopy baseline correction system, including:

[0083] The Raman spectroscopy data acquisition module 501 is used to acquire raw Raman spectroscopy data; the raw Raman spectroscopy data includes constructed simulated Raman spectroscopy data or real experimental data;

[0084] The initial weight vector identification module 502 is used to input the original Raman spectral data into the trained weight output model and output a binarized initial weight vector for identifying peak regions and background regions. The weight output model is built based on the ResUnet architecture, and its training samples consist of a simulated Raman spectral dataset labeled with peak regions and background regions.

[0085] The optimal smoothness parameter selection module 503 is used to perform a traversal search within a preset smoothness parameter range based on the initial weight vector using the penalized least squares (PLS) method, and to fit an initial baseline for each candidate smoothness parameter. Then, the correction quality of each initial baseline is quantitatively evaluated through a multi-index comprehensive evaluation strategy, and the optimal smoothness parameter is adaptively selected.

[0086] The baseline correction output module 504 is used to take the original Raman spectral data, the initial weight vector and the optimal smoothness parameter as input, and substitute them into the more robust adaptive iterative weighted least squares baseline correction algorithm Dr-airPLS for iterative correction. During the iteration process, the weight vector is dynamically optimized according to the baseline fitting situation until the preset conditions are met, and the final corrected baseline is output.

[0087] The specific implementation process of a fully automated Raman spectroscopy baseline correction system is basically the same as that of the above-described method embodiments, and will not be repeated here. It should be noted that each functional module in the system corresponds to a specific step in the method embodiments, and those skilled in the art can understand the specific implementation of the system based on the method flow.

[0088] The above embodiments illustrate the basic principles and implementation methods of the present invention, aiming to help understand the core concept and key steps of the invention. It should be understood that these embodiments are merely examples and do not limit the scope of application of the present invention. Those skilled in the art, based on their understanding of the concept of the present invention, can make various equivalent improvements to specific steps, parameter configurations, or system structures. These improvements also fall within the protection scope of the present invention, as defined in the appended claims.

Claims

1. A fully automated Raman spectral baseline correction method, characterized in that, Includes the following steps: Obtain raw Raman spectral data; the raw Raman spectral data includes constructed simulated Raman spectral data or real experimental data; The original Raman spectral data is input into the trained weighted output model, which outputs a binarized initial weight vector to identify the peak region and the background region. The weighted output model is built on the ResUnet architecture, and its training samples consist of a simulated Raman spectral dataset labeled with the peak region and the background region. Based on the initial weight vector, the penalized least squares (PLS) method is used to traverse and search within the preset smoothness parameter range, and an initial baseline is obtained by fitting each candidate smoothness parameter. Subsequently, a multi-index comprehensive evaluation strategy was used to quantitatively evaluate the correction quality of each initial baseline, and the optimal smoothness parameter was adaptively selected. The original Raman spectral data, initial weight vector, and optimal smoothness parameters are used as inputs and substituted into the more robust adaptive iterative weighted least squares baseline correction algorithm Dr-airPLS for iterative correction. During the iteration process, the weight vector is dynamically optimized according to the baseline fitting situation until the preset conditions are met, and the final corrected baseline is output.

2. The fully automated Raman spectral baseline correction method according to claim 1, characterized in that, The process of constructing the simulated Raman spectroscopy dataset includes: Using Gaussian, Lorentz, and Voigt functions as basic line shapes, Raman spectral peaks with different peak shapes are simulated and combined to obtain Raman spectra containing a preset number of Raman peaks. Gaussian noise with an intensity within a preset range is then added. Subsequently, randomly generated exponential and polynomial curves are added to simulate Rayleigh scattering and fluorescence backgrounds, respectively, to establish a simulated Raman spectral dataset containing diverse backgrounds.

3. The fully automated Raman spectral baseline correction method according to claim 1, characterized in that, The construction and training process of the weighted output model includes: A weighted output model combining residual connections and U-Net structure was constructed using the ResUnet framework. The weighted output model was trained using the simulated Raman spectroscopy dataset. During training, the AdamW optimizer was used, and the learning rate was automatically adjusted using the cosine annealing algorithm. The optimization objective was to minimize the binary cross-entropy loss (BCE Loss) between the predicted weights and labels until the weighted output model converged.

4. The fully automated Raman spectral baseline correction method according to claim 1, characterized in that, The multiple metrics include the smoothness of the fitted initial baseline, the proportion of negative points in the corrected spectrum, the average value of the negative region in the corrected spectrum, and the kurtosis of the corrected spectrum.

5. The fully automated Raman spectral baseline correction method according to claim 4, characterized in that, The correction quality of each initial baseline is quantitatively evaluated using a multi-index comprehensive evaluation strategy, and the optimal smoothness parameter is adaptively selected, specifically including: The scores for the smoothness of the fitted initial baseline, the proportion of negative points in the corrected spectrum, the average value of the negative region in the corrected spectrum, and the kurtosis of the corrected spectrum are normalized to the [0,1] interval and then summed to obtain the comprehensive evaluation index. ; Select the comprehensive evaluation indicator with the lowest score The corresponding smoothness parameter is taken as the optimal smoothness parameter.

6. The fully automated Raman spectral baseline correction method according to claim 5, characterized in that, The comprehensive evaluation indicators It is expressed as follows: ; in, This indicates the smoothness of the initial baseline after Min-Max normalization; This represents the proportion of negative points after Min-Max normalization. This represents the average value of the negative value region after Min-Max normalization. This represents the kurtosis after Min-Max normalization.

7. The fully automated Raman spectral baseline correction method according to claim 1, characterized in that, The dynamically optimized weight vector is represented as follows: ; in, For the number of data points, For the number of iterations, This represents the intensity vector of the original Raman spectrum. This represents the initial weight vector output by the weighted output model. Indicates using The intensity vector of the initial baseline obtained by fitting with the optimal smoothness parameters. Indicates the first The weights of the corresponding data points after each iteration Indicates the first The weight of the corresponding data point after -1 iterations Indicates the first The intensity vector corresponding to the baseline after the next iteration. Indicates the first The intensity vector corresponding to the baseline after -1 iterations.

8. The fully automated Raman spectral baseline correction method according to claim 1, characterized in that, The preset conditions include preset convergence conditions or preset number of iterations.

9. The fully automated Raman spectral baseline correction method according to claim 8, characterized in that, The preset convergence condition is that the absolute value of the sum of the deviations between the baseline and the original Raman spectrum is less than a preset threshold.

10. A fully automated Raman spectroscopy baseline correction system, characterized in that, include: A Raman spectroscopy data acquisition module is used to acquire raw Raman spectroscopy data; the raw Raman spectroscopy data includes constructed simulated Raman spectroscopy data or real experimental data; The initial weight vector identification module is used to input the original Raman spectral data into the trained weight output model and output a binarized initial weight vector to identify the peak region and the background region. The weight output model is built based on the ResUnet architecture, and its training samples consist of a simulated Raman spectral dataset labeled with the peak region and the background region. The optimal smoothness parameter selection module is used to perform a traversal search within a preset smoothness parameter range based on the initial weight vector using the penalized least squares (PLS) method, and to fit an initial baseline for each candidate smoothness parameter. Subsequently, a multi-index comprehensive evaluation strategy was used to quantitatively evaluate the correction quality of each initial baseline, and the optimal smoothness parameter was adaptively selected. The baseline correction output module is used to take the original Raman spectral data, initial weight vector and optimal smoothness parameters as input, and substitute them into the more robust adaptive iterative weighted least squares baseline correction algorithm Dr-airPLS for iterative correction. During the iteration process, the weight vector is dynamically optimized according to the baseline fitting situation until the preset conditions are met, and the final corrected baseline is output.