A spectral image recognition method for laser gas analyzer
By performing band division and wavelet transformation on the gas absorption spectrum image of the laser gas analyzer, the hard threshold is dynamically adjusted, and the problem of weak absorption peak signal being misjudged as noise is solved, improving the accuracy and accuracy of the identification results.
Patent Information
- Application Number
- CN202510775383.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-11
- Publication Date
- 2025-08-15
- Estimated Expiration
- 2045-06-11
AI Technical Summary
In the detection of low-concentration gases in existing laser gas analyzers, weak absorption peak signals are easily misjudged as noise removal, resulting in inaccurate identification results.
By dividing the gas absorption spectrum image into multiple bands, using wavelet transformation to determine the low-frequency layer approximation coefficient and high-frequency layer detail coefficient, calculate the signal score, dynamically adjust the hard threshold, reduce the possibility that weak signals are misjudged as noise, and improve the recognition accuracy.
It effectively reduces noise interference, improves the accuracy of gas absorption spectrum image recognition results, ensures that weak absorption peak signals are not removed by mistake, and improves the accuracy of detection.
Smart Images

Figure CN120298705B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of spectral image data processing, and more particularly to a spectral image recognition method for a laser gas analyzer. Background Art
[0002] Laser gas analyzers are high-precision gas detection devices based on spectral absorption technology. They are primarily used in industrial process monitoring, environmental monitoring, and safety protection, enabling real-time and accurate measurement of various gas concentrations. In industrial and environmental monitoring, complex and variable gas composition and environmental interference often cause deviations in laser gas analyzer measurement data. However, spectral image recognition methods can extract spectral features and, through algorithmic processing and analysis, eliminate environmental interference and rapidly identify subtle spectral changes.
[0003] Currently, laser gas analyzers use differential optical absorption spectroscopy (DOAS) for spectral image recognition. This technology quantitatively analyzes gas concentration by comparing the intensity attenuation at specific wavelengths in the absorption spectrum. The characteristic absorption peaks of gas molecules usually appear as high-frequency fluctuation signals. Before obtaining gas analysis results, denoising is required to improve detection sensitivity. However, in low-concentration detection of spectral image gas recognition, the molar absorptivity of some gases is low. When the gas concentration decreases, its absorption intensity also decreases, resulting in weak absorption peak signals in the collected gas absorption spectrum images. In the wavelet threshold denoising process, these signals will be mistakenly identified as noise and eliminated, resulting in inaccurate results of spectral image recognition by laser gas analyzers.
[0004] Therefore, how to effectively reduce the possibility of weak absorption peak signals being misjudged as noise and eliminated, thereby improving the accuracy of spectral image recognition results used by laser gas analyzers, is an urgent problem to be solved. Summary of the Invention
[0005] To solve the above-mentioned technical problem of how to effectively reduce the possibility of weak absorption peak signals being misjudged as noise and eliminated, thereby improving the accuracy of spectral image recognition results for laser gas analyzers, the present invention proposes a spectral image recognition method for laser gas analyzers, which includes the following steps:
[0006] Obtain a gas absorption spectrum image and divide it into multiple bands. Determine the low-frequency layer approximation coefficient and high-frequency layer detail coefficient of each band through wavelet transform. Calculate the signal score of the band based on the energy variance of the highest-frequency layer detail coefficient and the lowest-frequency layer approximation coefficient. Determine the probability that the band is in the absorption peak region based on the comparison between the signal score of the band and the corresponding score threshold. Calculate the hard threshold of each high-frequency layer in each band:
[0007] ;
[0008] 、 、 Respectively The first band The hard threshold of the high-frequency layer, the global noise standard deviation, the total number of detail coefficients, For the The probability that a band is in the absorption peak area, 、 Respectively The energy variance of the high-frequency layer detail coefficient of the highest layer of the gas absorption spectrum image in each band, is the preset adjustment factor, is the logarithm to base e, is an exponential function with e as the base; in response to the comparison result of the high-frequency layer detail coefficient of each layer in the band and the corresponding hard threshold, the gas absorption spectrum image is denoised to obtain the recognition result of the gas absorption spectrum image.
[0009] The present invention performs spectral image recognition after denoising a gas absorption spectrum image, effectively reducing noise interference and thereby accurately obtaining spectral image recognition results. During the denoising process, the present invention considers that some absorption peaks in the gas absorption spectrum image have relatively weak signals. Conventional wavelet transform denoising may remove these absorption peaks as noise, affecting the accuracy of the denoising effect. Therefore, the present invention analyzes the energy characteristics of each band in the gas absorption spectrum image to determine the probability that it is in the absorption peak region. Based on this, the present invention dynamically adjusts the hard threshold in the wavelet transform denoising process, lowering the hard threshold in the weak signal absorption peak region and improving the denoising accuracy, thereby effectively improving the accuracy of the gas absorption spectrum image recognition results. When calculating the probability of each band being in the absorption peak region, the present invention also determines a signal score based on the signal-to-noise ratio. By comparing the signal score with the score threshold, the probability of the band in the weak absorption peak region being identified as an absorption peak is increased, thereby effectively improving the accuracy of the gas absorption spectrum image recognition results obtained based on this.
[0010] According to a spectral image recognition method for a laser gas analyzer provided by the present invention, the gas absorption spectrum image is obtained and divided into multiple bands, which also includes: collecting the wavelength and absorbance of the gas in the environment, constructing a curve graph with the wavelength of the gas as the horizontal axis and the absorbance of the gas as the vertical axis, and obtaining the gas absorption spectrum image after preprocessing.
[0011] According to a spectral image recognition method for a laser gas analyzer provided by the present invention, the step of acquiring a gas absorption spectrum image and dividing it into multiple bands includes: dividing the gas absorption spectrum image into multiple bands according to a preset wavelength spacing.
[0012] The present invention takes into account that the changing trends of absorption peaks in gas absorption spectrum images are not the same. Therefore, the gas absorption spectrum image is divided into multiple bands, and the absorption peak energy characteristics in each band are used to determine whether it is an absorption peak, effectively avoiding the possibility of global analysis diluting the absorption peak characteristics.
[0013] According to a spectral image recognition method for a laser gas analyzer provided by the present invention, the low-frequency layer approximation coefficient and the high-frequency layer detail coefficient of each band are determined by wavelet transform, including: dividing the band into a preset number of layers by wavelet transform, each layer corresponding to one low-frequency layer approximation coefficient and three high-frequency layer detail coefficients; wherein the first layer is the lowest layer, the last layer is the highest layer, and each low-frequency layer approximation coefficient or high-frequency layer detail coefficient is a coefficient set.
[0014] According to a spectral image recognition method for a laser gas analyzer provided by the present invention, the calculation of the signal score of the band includes: calculating the first Signal score for each band :
[0015] ;
[0016] is the base 10 logarithm, For the The energy variance of the high-frequency layer detail coefficients of the highest layer of each band, For the The energy variance of the low-frequency layer approximation coefficients of the lowest layer of each band.
[0017] According to the present invention, a spectral image recognition method for a laser gas analyzer and a method for obtaining a scoring threshold corresponding to a band include:
[0018] ;
[0019] For the The scoring threshold corresponding to each band, is the preset scoring threshold. 、 Respectively The energy variance of the high-frequency layer detail coefficient of the highest layer of the gas absorption spectrum image in each band, is an exponential function with base e.
[0020] The present invention takes into account the simultaneous existence of strong and weak signals in some bands. In order to avoid the weak absorption peaks in such bands being identified as noise, the threshold is lowered by the energy variance ratio of the high-frequency layer detail coefficients of the band and the highest layer of the gas absorption spectrum image, thereby increasing the possibility that the band containing relatively weak but real absorption peaks is at the absorption peak, thereby improving the accuracy of the threshold adjustment.
[0021] According to a spectral image recognition method for a laser gas analyzer provided by the present invention, the possibility of the band being in the absorption peak region is determined based on the comparison result of the signal score of the band and the scoring threshold corresponding to the band, including: if the signal score of the band is greater than or equal to the scoring threshold corresponding to the band, then the normalized difference between the signal score of the band and the corresponding scoring threshold is used as the possibility that the band is in the absorption peak region; otherwise, the possibility of the band being in the absorption peak region is set to 0.
[0022] The present invention obtains the possibility of the band being in the absorption peak area by comparing the signal score of the band with its corresponding score threshold. It can retain the continuous information of the signal intensity while filtering out noise, thus preparing for subsequent quantitative analysis.
[0023] According to a spectral image recognition method for a laser gas analyzer provided by the present invention, the gas absorption spectrum image is denoised in response to the comparison result of the high-frequency layer detail coefficient of each layer in the band and the corresponding hard threshold, including: if the high-frequency layer detail coefficient of each layer in the band is less than the corresponding hard threshold, the high-frequency layer detail coefficient is set to 0, otherwise it remains unchanged to achieve denoising; the high-frequency layer detail coefficient of each layer in the denoised band is inversely wavelet transformed to obtain the denoised gas absorption spectrum image.
[0024] According to a spectral image recognition method for a laser gas analyzer provided by the present invention, the gas absorption spectrum image is denoised to obtain a recognition result of the gas absorption spectrum image, including: comparing the absorption peak in the denoised gas absorption spectrum image with the standard absorption peak to obtain the recognition result of the denoised gas absorption spectrum image.
[0025] According to a spectral image recognition method for a laser gas analyzer provided by the present invention, the absorption peak in the denoised gas absorption spectrum image is compared with the standard absorption peak through the least square method.
[0026] The present invention takes into account that the gas type in the denoised gas absorption spectrum image is usually not single, so the least squares method is used to fit each absorption peak with the standard absorption peak to accurately identify various types of gases and improve the accuracy of the detection results.
[0027] The present invention has the following beneficial effects:
[0028] Based on the above technical solution, the present invention provides a spectral image recognition method for a laser gas analyzer. When obtaining recognition results, the method effectively reduces noise interference by performing spectral image recognition after denoising the gas absorption spectrum image, thereby accurately obtaining spectral image recognition results. During the denoising process of the gas absorption spectrum image, the present invention considers that the signals of some absorption peaks in the gas absorption spectrum image are relatively weak. Conventional wavelet transform denoising may remove such absorption peaks as noise, affecting the accuracy of the denoising effect. Therefore, the present invention analyzes the energy characteristics of each band in the gas absorption spectrum image to determine the probability of it being in the absorption peak region. Based on this, the hard threshold in the wavelet transform denoising is dynamically adjusted to reduce the hard threshold in the weak signal absorption peak region, improve the accuracy of denoising, and thus effectively improve the accuracy of the gas absorption spectrum image recognition results. When calculating the probability of each band being in the absorption peak region, the present invention also determines a signal score based on the signal-to-noise ratio. By comparing the signal score with the score threshold, the probability of the band in the weak absorption peak region being identified as an absorption peak is increased, thereby effectively improving the accuracy of the gas absorption spectrum image recognition results obtained based on this. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] Figure 1 The present invention provides a flow chart of a spectral image recognition method for a laser gas analyzer. DETAILED DESCRIPTION
[0030] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, but not all of the embodiments.
[0031] An embodiment of the present invention discloses a spectral image recognition method for a laser gas analyzer. By dynamically adjusting the threshold for filtering out noise in each band, the method can avoid removing weak absorption peak signals as noise, thereby improving the accuracy of gas absorption spectrum image recognition results.
[0032] See also Figure 1 , Figure 1 1 is a flow chart of a spectral image recognition method for a laser gas analyzer provided by an embodiment of the present invention, the method comprising the following steps:
[0033] S1: Acquire gas absorption spectrum image.
[0034] Specifically, after the ambient airflow stabilizes, the wavelength, optical path, and gas concentration are collected by a laser analyzer, and the optical path and gas concentration are input into the Lambert-Beer formula to calculate its absorbance. The unit of wavelength can be set to nm.
[0035] For example, in an embodiment of the present invention, obtaining a gas absorption spectrum image includes: collecting the wavelength and absorbance of the gas in the environment, constructing a curve graph with the wavelength of the gas as the horizontal axis and the absorbance of the gas as the vertical axis, and obtaining a gas absorption spectrum image after preprocessing, and there are multiple absorption peaks on the gas absorption spectrum image.
[0036] The preprocessing method may be spectral normalization, etc. The preprocessing method may be specifically set according to actual needs, and the embodiment of the present invention does not impose any excessive restrictions on this.
[0037] Before determining gas identification results based on a gas absorption spectrum image, the gas absorption spectrum image must be denoised. Noise is typically a high-frequency signal, and significant spectral information (such as characteristic absorption signals) is often contained in high-frequency components. Therefore, embodiments of the present invention primarily process high-frequency coefficients. Wavelet transforms are used to decompose the gas absorption spectrum image, extracting a set of wavelet coefficients. Denoising is achieved by performing a threshold comparison on the coefficients to remove small-amplitude high-frequency coefficients. During the threshold comparison process, a hard threshold is applied to zero high-frequency coefficients below the hard threshold, treating them as noise, while retaining those above the hard threshold. This approach suppresses noise while preserving the majority of the signal's features, making it suitable for denoising gas absorption spectrum images.
[0038] However, in the process of denoising gas absorption spectrum images through wavelet transform, weak absorption peaks can easily be mistakenly identified as noise and eliminated, affecting the accuracy of subsequent analysis results based on gas absorption spectrum images.
[0039] In gas absorption spectrum images, the energy of absorption peaks has a concentrated characteristic. Based on this, embodiments of the present invention can divide the gas absorption spectrum image into multiple sub-bands, perform wavelet transforms on each band, obtain the energy corresponding to its high-frequency layer detail coefficients and the energy corresponding to its low-frequency layer approximation coefficients, analyze the energy concentration of the high-frequency layer detail coefficients and the low-frequency layer approximation coefficients, determine the quality of the bands, set the poor-quality bands to 0, and then continue to determine the likelihood that the high-quality bands are in the absorption peak region. Based on the likelihood of each band being in the absorption peak region, the hard threshold of each band layer is dynamically adjusted, thereby effectively reducing the possibility that weak absorption peaks will be judged as noise by the threshold, that is, continuing to perform the following steps.
[0040] S2: The gas absorption spectrum image is divided into multiple bands, and the low-frequency layer approximation coefficient and high-frequency layer detail coefficient of each band are determined by wavelet transform; the signal score of the band is calculated based on the energy variance of the high-frequency layer detail coefficient of the highest layer and the low-frequency layer approximation coefficient of the lowest layer in the band.
[0041] For example, in an embodiment of the present invention, acquiring a gas absorption spectrum image and dividing it into a plurality of bands includes: dividing the gas absorption spectrum image into a plurality of bands according to a preset wavelength spacing.
[0042] The wavelength spacing can be set to 20 nm; the wavelength spacing can be set according to actual needs.
[0043] Specifically, when performing wavelet transform on each band, we can start from the original image corresponding to the band according to the preset number of layers, and first divide the original image into the first layer of low-frequency layer approximation coefficients and the first layer of three high-frequency layer detail coefficients; then continue to layer the low-frequency layer approximation coefficients of the previous layer to obtain the low-frequency layer approximation coefficients and high-frequency layer detail coefficients of the next layer, and so on, until all layers are obtained.
[0044] It should be noted that after processing each band through wavelet transform, we can obtain high-frequency layer detail coefficients that include gas information and noise, as well as low-frequency layer approximation coefficients that represent baseline drift. The low-frequency layer approximation coefficients and high-frequency layer detail coefficients of each layer are not single values, but a series of coefficients. Among them, the first layer is the lowest layer and the last layer is the highest layer. The higher the decomposition level, the smoother the low-frequency approximation layer coefficients and the less noise. Therefore, the first layer retains the most noise, and the last layer has the highest effective signal component.
[0045] Therefore, when the embodiment of the present invention obtains the signal-to-noise ratio score of each band to evaluate its quality, the signal score of the band can be calculated by analyzing the energy variance of the highest-level high-frequency layer detail coefficient and the lowest-level low-frequency layer approximation coefficient. If the proportion of high-frequency signal energy in a band is significantly higher than that in the noise area, the possibility of a real absorption peak appearing at that location is higher.
[0046] For example, in an embodiment of the present invention, the low-frequency layer approximation coefficients and high-frequency layer detail coefficients of each band are determined by wavelet transform, including: dividing the band into a preset number of layers by wavelet transform, each layer corresponding to one low-frequency layer approximation coefficient and three high-frequency layer detail coefficients; wherein each low-frequency layer approximation coefficient or high-frequency layer detail coefficient is a coefficient set.
[0047] The preset number may be 3, and the specific number may be set according to actual needs. It is understood that if the number of layers is 3, the highest layer is the third layer.
[0048] It should be noted that absorption peaks in a band contain more high-frequency information and less noise, while non-absorption peaks contain more noise and less high-frequency information. Therefore, embodiments of the present invention can first determine the quality of each band by obtaining the signal-to-noise ratio in the band. The higher the ratio, the greater the likelihood that the band is at an absorption peak. The effective portion of the signal is concentrated in the high-frequency layer detail coefficients, while the noise is concentrated in the low-frequency layer approximation coefficients. Therefore, embodiments of the present invention obtain the signal score of the band by analyzing the ratio of the energy variance of the highest-level high-frequency layer detail coefficients to the energy variance of the lowest-level low-frequency layer approximation coefficients.
[0049] For example, in an embodiment of the present invention, the calculation The signal score of each band can be found in the following relationship:
[0050] ;
[0051] For the The signal score of each band, is the base 10 logarithm, For the The energy variance of the high-frequency layer detail coefficients of the highest layer of each band, For the The energy variance of the low-frequency layer approximation coefficients of the lowest layer of each band.
[0052] In the above formula, The larger the The higher the unevenness of the energy distribution of the high-frequency layer detail coefficients corresponding to each band, the higher the energy concentration. The smaller it is, the flatter the baseline is and the less significant the trend change is. The higher the probability that the increase is caused by an absorbance peak rather than baseline drift, the higher the quality.
[0053] The signal score of a band is used to characterize the possibility that the band is in a higher energy area. The higher the band energy, The larger it is, the higher the proportion of high-frequency signals and the lower the proportion of low-frequency baseline noise, and the more likely it is to be in the absorption peak area; conversely, the more likely it is to be in the non-absorption peak area.
[0054] Based on the above steps, the signal score of each band in the gas absorption spectrum image can be obtained. When calculating the probability of the band being at the absorption peak based on the signal score of the band, it is necessary to first filter out some bands with low signal scores and poor quality. This can be achieved by setting an acceptable minimum signal quality threshold, thereby accurately obtaining the probability of each band being in the absorption peak area.
[0055] S3: Based on the comparison result of the signal score of the band and the score threshold corresponding to the band, the possibility of the band being in the absorption peak area is determined, and the hard threshold of each high-frequency layer of each band is calculated.
[0056] It should be noted that absorption peaks correspond to local high-frequency signals, and changes in the spectral slope near the absorption peak are captured by the high-frequency layer detail coefficients, causing the coefficient values in this region to fluctuate dramatically and increasing the energy variance. Therefore, the greater the energy variance of the high-frequency layer detail coefficients within a band, the more uneven the energy distribution within that band, the presence of energy concentration, and the possible presence of an absorption peak. The highest-level high-frequency detail coefficients of the entire image primarily reflect the global noise level and the overall spectral fluctuation trend. When setting the scoring threshold for each band, due to the presence of strong and weak absorption peaks in the gas absorption spectrum image, the spectral signal intensities of different bands may vary significantly.
[0057] Therefore, when setting the scoring threshold for each band, the signal intensities of different bands can be converted into relative values based on the ratio of the high-frequency layer detail coefficient of the highest layer in each band to the high-frequency layer detail coefficient of the global highest layer of the gas absorption spectrum image, which is convenient for cross-band comparison.
[0058] Specifically, when setting the scoring threshold for each band, bands with higher energy concentration levels are more likely to be within the absorption peak region and thus receive higher signal scores. Furthermore, by lowering the signal scoring threshold, bands with moderate energy concentration levels can also participate in subsequent threshold processing, improving algorithm robustness while also enhancing the recognition of weak gas absorption peaks. Conversely, bands with lower energy concentration levels are less likely to be within the absorption peak region. In this case, the signal scoring threshold can be simultaneously increased, ensuring that a higher threshold setting can be used when the energy concentration of the band is low. This creates a dual filtering mechanism that improves the discrimination requirements for noisy regions and effectively suppresses random noise interference in low-energy bands.
[0059] The high-frequency layer detail coefficients of the highest layer of the global gas absorption spectrum image can be obtained by wavelet transformation. The specific steps can be implemented by existing technologies and will not be described in detail in the embodiments of the present invention.
[0060] For example, in an embodiment of the present invention, calculating the scoring threshold corresponding to each band includes:
[0061] ;
[0062] For the The scoring threshold corresponding to each band, is the preset scoring threshold. For the The energy variance of the high-frequency layer detail coefficients of the highest layer of each band, is the energy variance of the high-frequency layer detail coefficient of the highest layer of the gas absorption spectrum image, is an exponential function with base e.
[0063] Among them, the scoring basic threshold can be set to 10; the scoring basic threshold can be set according to actual needs.
[0064] In the above formula, The higher the If the energy concentration of a band is higher than the global noise level of the gas absorption spectrum image, the threshold of its signal score needs to be lowered so that the band can be more easily identified as a potential absorption peak area. The smaller it is, the higher the threshold needs to be to reduce noise interference.
[0065] After obtaining the signal score of each band and the corresponding scoring threshold of the band according to the above steps, the possibility of the band being in the absorption peak region can be determined based on the signal score of each band and the corresponding scoring threshold of the band.
[0066] It is understandable that when the signal score of a band is less than the corresponding scoring threshold for that band, it indicates that the energy fluctuation within the band does not significantly exceed the global noise level. The probability of the band being in the absorption peak region can be directly set to 0 to avoid subsequent misjudgments. Conversely, when the signal score of a band is greater than or equal to the corresponding scoring threshold for that band, the greater the difference between the signal score and the threshold, the more significantly the energy distribution unevenness of the band is higher than the noise level, and the higher the probability of the corresponding absorption peak.
[0067] For example, in an embodiment of the present invention, the possibility that the band is in the absorption peak region is determined based on the comparison result of the signal score of the band and the scoring threshold corresponding to the band, including: if the signal score of the band is greater than or equal to the scoring threshold corresponding to the band, then the normalized difference between the signal score of the band and the corresponding scoring threshold is used as the possibility that the band is in the absorption peak region; otherwise, the possibility that the band is in the absorption peak region is set to 0.
[0068] It should be noted that the signal in the absorption peak area changes dramatically and is rich in a large number of high-frequency components that represent key information. A fixed threshold can easily misjudge the high-frequency valid signal as noise and filter it out, causing the loss of key information and weakening the accuracy of the analysis results. The signal in the non-absorption peak area is relatively stable, and background noise interference becomes the main factor affecting the signal quality. Improper threshold setting may lead to insufficient noise suppression or excessive processing, resulting in blurred details, residual noise and other problems.
[0069] Therefore, after obtaining the possibility that each band is in the absorption peak area based on the above steps, the hard threshold of each layer in each band can be dynamically adjusted according to the possibility that the band is in the absorption peak area, so that the threshold is actively lowered in the absorption peak area to ensure that the high-frequency effective signal is fully retained; the threshold is appropriately increased in the non-absorption peak area to enhance the noise filtering capability in a targeted manner.
[0070] For example, in an embodiment of the present invention, the calculation The first band The hard threshold of the high-frequency layer can be found in the following relationship:
[0071] ;
[0072] For the The first band A hard threshold for the high-frequency layer, For the The first band The global noise standard deviation of the high-frequency layer, For the The first band The total number of detail coefficients of the high-frequency layer, For the The probability that a band is in the absorption peak area, For the The energy variance of the high-frequency layer detail coefficients of the highest layer of each band, is the energy variance of the high-frequency layer detail coefficient of the highest layer of the gas absorption spectrum image, is the preset adjustment factor, is the logarithm to base e, is an exponential function with base e.
[0073] The preset adjustment factor may be set to 1.2; the specific adjustment factor may be set according to actual needs.
[0074] In the above formula, It is The first band A basic hard threshold for each high-frequency layer.
[0075] is the adjustment coefficient of the basic hard threshold, The higher and The lower it is, the higher the possibility that the band is in the absorption peak area. At this time, it is necessary to lower the basic hard threshold according to the possibility that it is in the absorption peak area, thereby increasing the possibility that the band is identified as the absorption peak area. is a negative value, through right By weighting the negative exponential value of , the adjustment coefficient of the basic hard threshold can be accurately obtained, thereby accurately adjusting the basic hard threshold.
[0076] It can be understood that the band with a probability of 0 being in the absorption peak area is a noise band. At this time, the basic hard threshold can be directly increased according to the preset adjustment factor to accurately identify the band as a noise band.
[0077] After obtaining the hard threshold of each high-frequency layer in each band according to the above steps, denoising can be performed based on the hard threshold of each high-frequency layer in each band, and the inverse wavelet transform can be performed on the detail coefficients of the denoised high-frequency layer to obtain a complete denoised gas absorption spectrum image. By performing absorption peak discrimination on the signal retained in the denoised gas absorption spectrum image, the recognition result of the gas absorption spectrum image can be accurately obtained.
[0078] S4: In response to the comparison result of the high-frequency layer detail coefficient of each layer in the band and the corresponding hard threshold, the gas absorption spectrum image is denoised to obtain the recognition result of the gas absorption spectrum image.
[0079] For example, in an embodiment of the present invention, in response to the comparison result of the high-frequency layer detail coefficient of each layer in the band and the corresponding hard threshold, the gas absorption spectrum image is denoised, including: if the high-frequency layer detail coefficient of each layer in the band is less than the corresponding hard threshold, the high-frequency layer detail coefficient is set to 0, otherwise it remains unchanged to achieve denoising; the high-frequency layer detail coefficient of each layer in the denoised band is inversely transformed to obtain the denoised gas absorption spectrum image.
[0080] For example, after obtaining the comparison result between the high-frequency layer detail coefficient of each layer in the band and the corresponding hard threshold, the low-frequency layer approximation coefficient can be directly set to 0 to eliminate baseline interference.
[0081] Specifically, when the high-frequency layer detail coefficients of each layer in the denoised band are subjected to inverse wavelet transform to obtain the denoised gas absorption spectrum image, the differential absorption spectrum of the high-frequency layer detail coefficients of each layer in each band can be obtained. After splicing the differential absorption spectra of each band in sequence, a complete denoised gas absorption spectrum image can be obtained.
[0082] For example, in an embodiment of the present invention, the gas absorption spectrum image is denoised to obtain the recognition result of the gas absorption spectrum image, including: comparing the absorption peak in the denoised gas absorption spectrum image with the standard absorption peak to obtain the recognition result of the denoised gas absorption spectrum image.
[0083] Among them, DOAS technology can preliminarily identify the location and approximate shape of possible gas characteristic absorption peaks by analyzing and comparing the light intensity attenuation (i.e., absorbance) at specific wavelengths in the denoised gas absorption spectrum image.
[0084] Specifically, the standard absorption peak is a measure of the ability of gas molecules to absorb light at a specific wavelength. Different gas molecules have different standard absorption peaks. By matching the position and intensity of the absorption peak, the type of gas can be determined.
[0085] It should be noted that there are usually many types of gases in the environment, and their absorption spectra will overlap. Therefore, the absorption spectrum can be fitted by the least squares method, and the measured spectrum can be decomposed into the absorption spectrum of each gas component. Then, by comparing it with the standard absorption peak, the type and concentration of each gas component can be accurately obtained, thereby realizing the fine classification and identification of multi-component gases.
[0086] For example, in an embodiment of the present invention, the comparison between the absorption peak in the denoised gas absorption spectrum image and the standard absorption peak can be achieved by using the least square method.
[0087] The specific steps of comparing the absorption peak in the denoised gas absorption spectrum image with the standard absorption peak by the least square method can be obtained through the existing technology and will not be described in detail in the embodiment of the present invention.
[0088] It can be seen that in the embodiment of the present invention, when obtaining the recognition result of the gas absorption spectrum image, the gas absorption spectrum image can be obtained and divided into multiple bands, and the low-frequency layer approximation coefficient and high-frequency layer detail coefficient of each band are determined by wavelet transform; the signal score of the band is calculated based on the energy variance of the high-frequency layer detail coefficient of the highest layer and the low-frequency layer approximation coefficient of the lowest layer in the band; based on the comparison result of the signal score of the band and the score threshold corresponding to the band, the possibility of the band being in the absorption peak area is determined; and the hard threshold of each high-frequency layer of each band is calculated:
[0089] ;
[0090] 、 、 Respectively The first band The hard threshold of the high-frequency layer, the global noise standard deviation, the total number of detail coefficients, For the The probability that a band is in the absorption peak area, 、 Respectively The energy variance of the high-frequency layer detail coefficient of the highest layer of the gas absorption spectrum image in each band, is the preset adjustment factor, is the logarithm to base e, is an exponential function with e as the base; in response to the comparison result of the high-frequency layer detail coefficient of each layer in the band and the corresponding hard threshold, the gas absorption spectrum image is denoised to obtain the recognition result of the gas absorption spectrum image, which effectively improves the accuracy of the recognition result of the gas absorption spectrum image.
[0091] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A spectral image recognition method for a laser gas analyzer, characterized in that: include: Obtain gas absorption spectrum images and divide them into multiple bands, and determine the low-frequency layer approximation coefficient and high-frequency layer detail coefficient of each band through wavelet transform; Calculate the signal score of the band based on the energy variance of the highest-level high-frequency layer detail coefficient and the lowest-level low-frequency layer approximation coefficient in the band; and determine the likelihood that the band is in the absorption peak region based on the comparison result between the signal score of the band and the score threshold corresponding to the band. Compute the hard threshold for each high-frequency layer in each band: ; 、 、 Respectively The first band The hard threshold of the high-frequency layer, the global noise standard deviation, the total number of detail coefficients, For the The probability that a band is in the absorption peak area, For the The energy variance of the high-frequency layer detail coefficients of the highest layer of each band, is the energy variance of the high-frequency layer detail coefficient of the highest layer of the gas absorption spectrum image, is the preset adjustment factor, is the logarithm to base e, is an exponential function with e as the base; in response to the comparison result of the high-frequency layer detail coefficient of each layer in the band and the corresponding hard threshold, the gas absorption spectrum image is denoised to obtain the recognition result of the gas absorption spectrum image.
2. The spectral image recognition method for a laser gas analyzer according to claim 1, characterized in that: The method of acquiring a gas absorption spectrum image and dividing it into multiple bands further includes: The wavelength and absorbance of the gas in the environment are collected, and a graph is constructed with the wavelength of the gas as the horizontal axis and the absorbance of the gas as the vertical axis. After preprocessing, a gas absorption spectrum image is obtained.
3. The spectral image recognition method for a laser gas analyzer according to claim 1, characterized in that: The gas absorption spectrum image is obtained and divided into multiple bands, including: The gas absorption spectrum image is divided into multiple bands according to the preset wavelength interval.
4. The spectral image recognition method for a laser gas analyzer according to claim 1, characterized in that: The method of determining the low-frequency layer approximation coefficients and high-frequency layer detail coefficients of each band by wavelet transform includes: The band is divided into a preset number of layers through wavelet transform, each layer corresponds to a low-frequency layer approximation coefficient and three high-frequency layer detail coefficients; among them, the first layer is the lowest layer, the last layer is the highest layer, and each low-frequency layer approximation coefficient or high-frequency layer detail coefficient is a coefficient set.
5. The spectral image recognition method for a laser gas analyzer according to claim 1, characterized in that: Calculating the signal score of the band includes: Calculate the Signal score for each band : ; is the base 10 logarithm, For the The energy variance of the high-frequency layer detail coefficients of the highest layer of each band, For the The energy variance of the low-frequency layer approximation coefficients of the lowest layer of each band.
6. The spectral image recognition method for a laser gas analyzer according to claim 1, characterized in that: The method for obtaining the scoring threshold corresponding to the band includes: ; For the The scoring threshold corresponding to each band, is the preset scoring threshold, For the The energy variance of the high-frequency layer detail coefficients of the highest layer of each band, is the energy variance of the high-frequency layer detail coefficient of the highest layer of the gas absorption spectrum image, is an exponential function with base e.
7. The spectral image recognition method for a laser gas analyzer according to claim 1, characterized in that: The comparing result of the signal score based on the wavelength band and the score threshold corresponding to the wavelength band to determine the possibility that the wavelength band is in the absorption peak region includes: If the signal score of the band is greater than or equal to the scoring threshold corresponding to the band, the normalized difference between the signal score of the band and the corresponding scoring threshold is used as the possibility that the band is in the absorption peak area; otherwise, the possibility that the band is in the absorption peak area is set to 0.
8. The spectral image recognition method for a laser gas analyzer according to claim 1, characterized in that: The denoising of the gas absorption spectrum image in response to the comparison result of the high-frequency layer detail coefficient of each layer in the band and the corresponding hard threshold comprises: If the high-frequency layer detail coefficient of each layer in the band is less than the corresponding hard threshold, the high-frequency layer detail coefficient of each layer is set to 0, otherwise it remains unchanged to achieve denoising; the high-frequency layer detail coefficient of each layer in the denoised band is inversely transformed to obtain the denoised gas absorption spectrum image.
9. The spectral image recognition method for a laser gas analyzer according to claim 1, characterized in that: The denoising of the gas absorption spectrum image to obtain the recognition result of the gas absorption spectrum image includes: The absorption peak in the denoised gas absorption spectrum image is compared with the standard absorption peak to obtain the recognition result of the denoised gas absorption spectrum image.
10. The spectral image recognition method for a laser gas analyzer according to claim 9, characterized in that: The absorption peak in the denoised gas absorption spectrum image is compared with the standard absorption peak using the least squares method.
Citation Information
Patent Citations
Improved threshold function-based wavelet transformation image denoising method
CN103854264A
Image denoising method and terminal
CN104639800A