Double-parameter HP filtering denoising algorithm and process for infrared spectrum signal processing
By setting the upper and lower limits of the parameters Lamda_1 and Lamda_2 of the two-parameter HP filtering algorithm, a new HP filtering expression is constructed and optimized, which solves the problem that the high-frequency noise denoising scale is difficult to control due to parameter uncertainty in HP filtering, and achieves better denoising effect.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- NORTHEAST NORMAL UNIVERSITY
- Filing Date
- 2022-12-13
- Publication Date
- 2026-04-28
AI Technical Summary
The uncertainty in parameter selection during HP filtering denoising makes it difficult to control the denoising scale of high-frequency noise.
A two-parameter HP filtering algorithm is adopted. By setting the upper and lower limits of parameters Lamda_1 and Lamda_2, HP filtering is performed separately, and a new comprehensive HP filtering expression is constructed. The optimal parameter Lamda_u is obtained within the parameter range to achieve better noise scale estimation.
It achieves better high-frequency noise denoising effect, solves the problem of uncertain parameter selection, and obtains more balanced denoising results.
Smart Images

Figure QLYQS_1 
Figure QLYQS_2 
Figure QLYQS_6
Abstract
Description
Technical Field
[0001] This invention belongs to the field of signal processing, specifically relating to a two-parameter HP filtering denoising algorithm and process for infrared spectral signal processing. Background Technology
[0002] The HP filtering method was first proposed by Hodrick and Prescott in 1980 when analyzing the post-war economic climate in the United States. This method has been widely used in the analysis of macroeconomic trends. HP filtering is an analysis method for time series in state space, equivalent to minimizing the variance of fluctuations. HP filtering can be viewed as an approximate high-pass filter; its goal is to separate the higher-frequency components from all the different frequency components, thus it is also suitable for denoising high-frequency signals.
[0003] Then, the implementation of HP filtering relies on a manually set parameter Lamda. Different values of Lamda can represent different high-frequency noise scale estimates. However, for unknown signals, it is generally impossible to give an accurate estimate of their noise scale. Summary of the Invention
[0004] To address the problem that the uncertain selection of parameters in the HP filtering denoising process makes it difficult to control the denoising scale for high-frequency noise, this invention provides a two-parameter HP filtering denoising algorithm and process for infrared spectral signal processing.
[0005] A two-parameter HP filtering denoising algorithm for infrared spectral signal processing includes:
[0006] 1) Input the signal to be denoised;
[0007] 2) Initial parameter setting: Provide the estimated upper and lower limits of the parameters, Lamda_1 and Lamda_2;
[0008] 3) Perform HP filtering denoising using parameters Lamda_1 and Lamda_2 respectively; the denoising results under these two parameters are then obtained:
[0009] ;
[0010] This represents the signal to be processed. and These represent the denoised signal and the removed noise signal, respectively.
[0011] 4) Combining the upper and lower limit parameter filtering results, construct a comprehensive optimization function expression:
[0012]
[0013] Lamda takes values within the interval [Lamda_1, Lamda_2].
[0014] 5) Within [Lamda_1, Lamda_2], perform HP filtering by iterating through the parameters with a step size dh to find the Lamda_u that minimizes the optimized function expression, and obtain the filtering and denoising result under Lamda_u. .
[0015] 6) Output the denoised signal and noise;
[0016] In step 2), Lamda_1 and Lamda_2 can be given by experience first. When the parameter Lamda_u obtained by the final optimization is close to the upper and lower limits, it can be re-extended and set along the closer direction.
[0017] In step 2), Lamda_1 is less than 1, and Lamda_2 is greater than 20;
[0018] The step size dh mentioned in step 5) is preset.
[0019] The expression for HP filtering and denoising in step 2) is as follows:
[0020]
[0021] The optimized function expression for HP filtering and denoising is:
[0022] ;
[0023] The signal is a near-infrared spectral signal.
[0024] This invention provides a two-parameter HP filtering denoising algorithm and process for infrared spectral signal processing. By pre-defining upper and lower bounds (Lamda_1 and Lamda_2) for parameter scale estimation, traditional HP filtering is performed to obtain filtered signals. These two filtered signals are then combined to construct a new HP filtering expression. HP filtering is performed under this newly reconstructed expression, and the parameter values that minimize the expression are obtained within the range [Lamda_1, Lamda_2] and used as the output. Local extrema are searched within the two parameter estimation ranges, and HP filtering is then performed under the new expression. Because this invention constructs an HP filtering expression with combined upper and lower bounds and performs optimization within these bounds, it achieves better scale estimation of signal noise. This solves the problem of uncertain parameter selection during HP filtering denoising, which makes it difficult to control the denoising scale for high-frequency noise, resulting in better denoising performance.
[0025] This algorithm first gives the upper and lower bounds of the HP filtering parameter Lamda, namely Lamda_1 and Lamda_2 (Lamda_1 < Lamda_2). By comprehensively reconstructing the HP filtering results through these two bounds to form a new HP filtering expression, better noise scale estimation can be achieved. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] Figure 1 is the algorithm flowchart of the present invention.
[0027] Figure 2 is the schematic diagram of parameter acquisition when finding the minimum value under the comprehensive HP filtering expression adopted by the present invention.
[0028] Figure 3 is the schematic diagram for testing the signal denoising effect of the present invention. Among them, (a) is the original signal to be processed, (b) is the denoising result when the parameter lower limit Lamda_1 = 0.3 is adopted, (c) is the denoising result when the parameter upper limit Lamda_2 = 30 is adopted, and (d) is the denoising result introduced by the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0029] Embodiment 1 A two-parameter HP filtering denoising algorithm for infrared spectrum signal processing
[0030] In order to achieve better estimation of the HP filtering parameter value scale, the present invention constructs a two-parameter HP filtering algorithm. By pre-giving the upper and lower bounds Lamda_1 and Lamda_2 of the parameter scale estimation, after respectively performing traditional HP filtering to obtain the filtered signals, these two filtered signals are introduced to comprehensively construct a new HP filtering expression. HP filtering is performed under the newly comprehensively reconstructed HP filtering expression, and the parameter values when the expression takes the minimum value are found by optimizing within the range [Lamda_1, Lamda_2] as the output result. The specific algorithm process is as Figure 1 shown.
[0031] The basic idea of the present invention is: a re-optimized comprehensive HP filtering algorithm with two parameters, which specifically includes the following steps: First step, give the upper and lower bounds of the parameter estimation, namely Lamda_1 and Lamda_2, and perform HP filtering respectively under these two parameters; Second step, on the basis of the first step, comprehensively combine the two denoised signals to reconstruct the HP filtering expression to prepare for the new HP filtering; Third step, perform HP filtering under the new expression, calculate multiple times within the range [Lamda_1, Lamda_2], find the local optimal parameter Lamda_u (Lamda_u is within [Lamda_1, Lamda_2]) when the expression takes the minimum value within the parameter range, and finally output the denoising result when the parameter takes Lamda_u.
[0032] The first step of this invention is based on the traditional HP filter. Let N be the number of signal samples to be processed. The expression for the traditional HP filter is as follows:
[0033]
[0034] in This represents a signal to be processed. and Let represent the denoised signal and the removed noise signal, respectively. The optimized function expression for traditional HP filtering is:
[0035]
[0036] Where Lamda is a free parameter, given the estimated upper and lower bounds Lamda_1 and Lamda_2, respectively, traditional HP filtering is performed for denoising to obtain the filtering and denoising results for these two parameters:
[0037] and
[0038] The second step of this invention is to reconstruct a new HP filtering expression based on the results of the first step. Specifically, this involves synthesizing the upper and lower bound parameter filtering results to construct a comprehensive optimized function expression, specifically:
[0039]
[0040] Lambda takes values within the interval [Lamda_1, Lambda_2]. The new optimization function expression can be viewed as a synthesis of the filtering channels with upper and lower limits.
[0041] The third step of this invention is to optimize the value of parameter Lamda based on the second step. Specifically, it involves sorting the optimization function expressions with a step size precision of dh within the interval [Lamda_1, Lamda_2], and finding the parameter value Lamda_u that minimizes the optimization function. It is considered that the HP filtering under this new expression is a reasonable estimate of parameter Lamda. A schematic diagram of this process is shown below. Figure 2 As shown, the final output is the filtering and denoising result under the new expression when taking Lamda_u:
[0042]
[0043] in and These represent the denoised signal and the noise signal obtained by this invention, respectively.
[0044] Example 2: Near-infrared transmission spectroscopy treatment of single rice seeds
[0045] according to Figure 1 The flowchart shown illustrates the implementation of this invention. It mainly includes signal input, initial parameter setting, reconstruction of the comprehensive HP optimization function expression, parameter optimization, and result output.
[0046] 1) Input the signal to be denoised;
[0047] 2) Initial parameter settings. Generally, Lambda_1 is set to be less than 1, and Lambda_2 to be greater than 20.
[0048] 3) Begin performing traditional HP filtering according to the values in 2), and obtain the filtered results;
[0049] 4) Construct an optimized function expression based on the filtering results in step 3), as described in Example 1;
[0050] 5) Within [Lamda_1, Lamda_2], perform HP filtering by iterating through the parameters with a step size dh to find the Lamda_u that minimizes the optimized function expression, and obtain the filtering and denoising result under Lamda_u. ;
[0051] 6) Output the denoised signal and noise, then end.
[0052] We are Figure 3 The test results of this invention are compared, using a near-infrared spectral signal as an example. The signal originates from the near-infrared transmission spectrum of a single rice seed, with a spectral range of 900-2500 nm. (a) shows the original signal to be processed, (b) shows the denoising result using the lower parameter limit Lamda_1=0.3, (c) shows the denoising result using the upper parameter limit Lamda_2=30, and (d) shows the denoising result after incorporating the invention. It can be seen that after incorporating the comprehensive optimization expression constructed in this invention, a more satisfactory denoising result can be obtained. Compared to parameter values that are too small or too large, this invention achieves a more balanced high-frequency noise removal effect.
[0053] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any transformations or substitutions that can be conceived by those skilled in the art within the scope of the model disclosed in the present invention are all covered within the scope of the present invention.
Claims
1. A two-parameter HP filtering denoising algorithm for infrared spectral signal processing, characterized in that, Includes the following steps: 1) Input the signal to be denoised; 2) Initial parameter setting: Provide the estimated upper and lower limits of parameter Lamda, Lamda_1 and Lamda_2; 3) Perform HP filtering denoising according to parameters Lamda_1 and Lamda_2 respectively, and obtain the filtering denoising results under the two parameters: and ; in The infrared spectral signal to be processed. and These represent the denoised signal and the removed noise signal, respectively. 4) Combining the upper and lower limit parameter filtering results, construct a comprehensive optimization function expression: ; Lamda takes values within the interval [Lamda_1, Lamda_2]; 5) Within [Lamda_1, Lamda_2], perform HP filtering by iterating through the parameter Lamda with a step size dh to find the Lamda_u that minimizes the optimized function expression and obtain the filtering and denoising result under Lamda_u. 6) Output the filtered signal and removed noise under Lamda_u.
2. The dual-parameter HP filtering denoising algorithm for infrared spectral signal processing according to claim 1, characterized in that: The Lamda_1 and Lamda_2 mentioned in step 2) are first given by experience.
3. The dual-parameter HP filtering denoising algorithm for infrared spectral signal processing according to claim 2, characterized in that: In step 2, Lamda_1 is less than 1, and Lamda_2 is greater than 20.
4. A two-parameter HP filtering denoising algorithm for infrared spectral signal processing according to claim 1, 2, or 3, characterized in that: The step size dh mentioned in step 5) is preset.
5. The dual-parameter HP filtering denoising algorithm for infrared spectral signal processing according to claim 4, characterized in that: The expression for HP filtering denoising in step 3) is as follows: ; The optimized function expression for HP filtering and denoising is: 。 6. The dual-parameter HP filtering denoising algorithm for infrared spectral signal processing according to claim 5, characterized in that: The signal is a near-infrared spectral signal.
Citation Information
Patent Citations
Near-infrared soil spectrum denoising method based on self-adapting filtering
CN102721663A
A near infrared spectrum signal denoising method based on a Hodard-Presscott filter
CN109670531A