144
J. Eur. Opt. Society-Rapid Publ. 21, 13( 2025)
original linearly correlated variables in the spectrum are converted to new linearly independent variables to achieve separation of the datasets. n new variables from the matrix Y are expressed as follows:
Y ¼ E X; ð3Þ
where E is the coefficient matrix. New variables Y 1, Y 2,... Y n are represented as the 1st to nth principal components, respectively, each Y i are independent of each other, and each principal component contains information from a different component in the original spectrum; thus, this process effectively decomposes the spectral information.
Y i ¼ ~ e i1 x 1 þ ~ e i2 x 2 þ...~ e in x n;
where ~ e i1; ~ e i2;...~ e in are the eigenvectors of the i-th principal component and represent the proportion of each original variable on the component. The projection size of the variables contained in the original data on the different principal components can be obtained from the value of the eigenvector. The eigenvalue of each principal component can be obtained via formula( 5), and the eigenvalue represents the amount of information contained in each principal component.
� k i ¼ var ~ e T i x
: ð5Þ
ð4Þ
To more visually express the percentage of the information contained in each principal component in the total spectral information, the contribution rate l i of the i-th principal component can be calculated via formula( 6):
l i ¼ k i
P n
1 k i
: ð6Þ
The Non-Local Means Filtering approach relies on the intrinsic redundancy of signals, employing a patch-matching strategy to assess the correlation among various components of the signal and, consequently, determining the weighting coefficients within the filter. This methodology does not necessitate reliance on external information; rather, it achieves noise reduction solely through the integration of internally similar features within the signal, while simultaneously preserving the integrity of edge features to a certain extent.
Given a discrete two-dimensional noisy signal v = { v( i)| i 2 I }, where I represents the entire signal domain, the NLM estimate NL [ v ]( i) for any point i within v can be derived by computing a weighted average of all points in the two-dimensional signal. This is mathematically formulated as [ 22 – 24 ]:
NL ½ vŠðÞ¼ i X i2I wi ð; jÞvðjÞ; ð7Þ
wherein, the computation of the weights { w( i, j)} j depends on the similarity between points i and j, and satisfies conditions 0 w( i, j) j 1and P jw( i, j)= 1.
The similarity between two points i and j is measured based on the similarity between vectors v( N i) andv( N j) within their respective fixed-size square neighborhoods centered at point p. This similarity is determined by � calculating the weighted Euclidean distance jjvðN i Þ�vN j jj
2 2; a between the two neighborhood vectors, where the weights in the weighted Euclidean distance are given by a Gaussian kernel with a standard deviation of a( a > 0).
� 2 jjvðN i Þ�vN j jj ¼ X G
2; a a ðkÞjviþ ð kÞ�vjþ ð kÞj 2: k2Q ð8Þ
Here, a region Q centered at the coordinates( 0, 0) is defined, with its size consistent with the previously mentioned square neighborhood. Additionally, a two-dimensional Gaussian kernel G a with a standard deviation of a is introduced. The calculation of weights is performed according to the following formula [ 22 – 24 ]:
wi ð; jÞ ¼ 1 jjvðN i Þ�vðN j Þ jj2 2; a
ZðiÞ e� h 2; ð9Þ wherein, Zi ðÞ¼ P j jjvðNi Þ�v N j e � ð Þ jj2
2; a h 2, h are filter coefficients.
This paper proposes an algorithm that integrates PCA with NLM filtering. The primary steps involve firstly separating the target signal from background noise using the PCA method. Subsequently, the extracted feature signal, which may still be affected by noise, undergoes further optimization of the parameter configuration of the Non-Local Means filtering method to achieve optimal denoising effects, thereby obtaining a clear and effective feature signal.
To validate the effectiveness of the PCA-NLM algorithm, simulation experiments were conducted in this paper. Firstly, potassium lamp signals were simulated, with characteristic peaks located at 766.49 nm and 769.89 nm, as shown in Figure 2a. Subsequently, to simulate the impact of environmental disturbances, noise was added to this ideal potassium lamp signal, generating a noisy potassium lamp signal as depicted in Figure 2b. The corresponding interferogram obtained through the simulated spatial heterodyne spectrometer is presented in Figure 2c. By applying Fourier transform, potassium lamp spectral information was extracted from the noisy signal, but at this point, the spectral information was significantly affected by noise, as shown in Figure 2d. Subsequently, Principal Component Analysis was employed to process the spectral information, with the extracted results displayed in Figure 2e. While the PCA effectively attenuates the influence of noise to some degree, residual noise that is challenging to remove still persists in the spectra. Therefore, the NLM denoising algorithm was further applied. Ultimately, the spectral information shown in Figure 2f was obtained. To quantitatively evaluate the denoising performance of the proposed method, we calculated the peak signal-to-noise ratio( PSNR) of the spectra processed by the PCA-NLM method and by PCA alone. The results were 22.20 dB and 17.35 dB, respectively. This comparison further validates the effectiveness of the proposed PCA-NLM algorithm. Additionally, the full width at half maximum( FWHM) of the peaks in Figures 2e and 2f were calculated to be 0.176 nm and 0.0586 nm, respectively. These results indicate that the PCA-NLM algorithm enhances the quality of the signal.