Spectral Correction Method of MultiChannels Near-Infrared Spectrometer and Applications

Near-infrared (NIR) spectrometer based on semiconductor lasers can combine light source and splitter into one, which is an important direction for development of miniature instruments. In order to avoid random interference caused by inconsistency between light sources, the novel evaluation indicators for global stability of multi-channels spectral system were proposed based on the correlation between dynamic deviation spectra of any two channels. The NIR analysis of moisture for corn powder samples based on the partial least squares combined with Savitzky-Golay (SG) smoothing was taken as an example, and a spectral correction method for enhancing prediction performance of multi-channels spectral system was further provided using above evaluation indicators. The experiment results showed that the global stability evaluation indicators significantly increased after SG smoothing correction. Meanwhile, the root-mean-square errors of prediction for corn moisture reduced from 0.373 to 0.283 (%), and the correlation coefficient between predicted and actual values was improved from 0.702 to 0.855. The above results indicated that by improving global stability indicators, the prediction ability of multi-channels spectral system can be improved. The proposed method provided a valuable reference for designing multi-channels diminutive spectrometer with high prediction performance, which had significance for large-scale application of NIR technology.


Introduction
It is well known, near-infrared (NIR) spectroscopy as a simple and quick tool T. Pan et al. has been effectively utilized in various fields for quantitative and qualitative analysis, such as agriculture [1] [2] [3] [4] [5], food [6] [7], environment [8] [9], biomedicine [10]- [15], medicine [16] [17], and so on [1] [18].However, the used NIR equipment is mainly indoor general-purpose equipment, which is bulky, costly, and cannot meet the needs of large-scale applications, especially for the applications in the agricultural field.Thus, developing diminutive, dedicated, and low-cost NIR instruments has wide application prospects.
The NIR spectrometer based on semiconductor lasers adopts multiple semiconductor lasers with discrete wavelength as a light source, where the light source and splitter are combined to one.Owing to the merits of strong spectra monochromaticity, stable light source, small volume and low price, it is an important direction for the development of miniature NIR instruments in current.
Because each semiconductor laser is a separate light source, in order to avoid random interference caused by inconsistency between light sources, the spectral correction is necessary for NIR instrument of semiconductor lasers.Traditionally, NIR instruments usually use a single light source, after the splitter system, the consistency between each monochromatic light is good due to the same light source; the wavelength signal-noise ratio (SNR) can be used as an evaluation index for instrument stability.However, the independent SNR of each light source is difficult to evaluate the global stability for the NIR system with multiple light sources, since the consistency between each monochromatic light is poor.As far as we know, the evaluation method of the stability of multi-light system has not been reported.In view of this, aiming at the NIR spectrometer based on semiconductor lasers with discrete wavelengths, an appropriate evaluation indicator for global stability and detection performance was proposed in the present study.
Being a very important food and feed, corn is one of the most common crops in the world.Moisture is an important parameter for the quality of raw material in the feed industry.It has been proved that near-infrared spectroscopy can be used to determine components of corn rapidly [1] [18] [19] [20].In the present study, the NIR analysis of moisture of corn powder samples was taken as an example, a method for improving the prediction performance of spectrometer with multiple light sources was further proposed on the basis of the above evaluation indicators.
Being an effective spectral quantitative analysis method, partial least squares (PLS) [1] [18] regression can synthetically screening the spectral data, extract the information variables and overcome the collinearity of the spectra.Furthermore, the NIR diffuse reflectance spectroscopy of samples inevitably contains many kinds of physical and chemical noise interference.Therefore, it is necessary to use appropriate pretreatment method to eliminate the baseline drift, tilt and other noises.The Savitzky-Golay (SG) smoothing is an efficient spectral pretreatment method with a wide range of application [3] [7] [11] [21].In the present study, the PLS method combined with SG smoothing was applied to the NIR analysis of corn moisture.
T. Pan et al.

Experimental Materials, Instruments, and Measurement Methods
The number of collected corn kernels samples was 268 in all.All samples were ground and sifted by a 1.0 mm aperture sieve, and they did not through drying process for maintaining the water content of samples.Each sample was prepared in triplicate.One was used for moisture determination by the conventional methods, another was used for spectroscopic measurement, and the third one was used as a spare sample.The moisture measured values were obtained by the direct drying method.The gained values were regarded as the reference values in the calibration and prediction of spectroscopic analysis.The range of the measured value for 268 samples were 9.99 to 12.62 (%), and the mean value and standard deviation were respectively 11.28 and 0.51 (%).
The spectral measurement was performed simultaneously by using an NLD-D1 Near-Infrared Spectrometer with semiconductor lasers (Guangzhou SonDon Network & Technology Co., Ltd., China) equipped with the detector which is InGaAs.The instrument adopted eleven semiconductor lasers ( which corresponding discrete wavelengths are 1270, 1310, 1350, 1410, 1450, 1470, 1490, 1530, 1550, 1570 and 1610 nm, respectively.The sample cup is a black circular cup and the number of scanning is 30.Each sample was measured thrice, and the mean value of the measurements was used for calibration and prediction.The spectra were obtained at 25˚C ± 1˚C and in 45% ± 1% RH.In addition, in order to test the dynamic stability of the system, a sample was randomly selected for repeatability experiment, which was repeatedly measured spectroscopy for 20 times.

Evaluation Indicators for Global Stability of Multi-Channels Spectral System
NIR spectrometer based on semiconductor lasers can combine the light source and splitter into one.Each semiconductor laser corresponds to a monochromatic wavelength, and that forms a separate detection channel.Thus, such instruments are also known as multi-channels spectroscopy system.In the present study, the dynamic deviation spectra of each channel were analyzed firstly.On the basis of this, the novel indicators for objectively evaluating the global stability of the multi-channels spectral system were further proposed.The specific steps are as follows: Step 1 Experiment on repeated determination of NIR Spectra: Suppose that there are m semiconductor lasers with corresponding discrete wavelengths, that is to say there are m detection channels.A sample was randomly selected to measure its spectrum for n times, the obtained dynamic absorbance matrix was the follows: ( ) , , 1, 2, , , 1, 2, , .
Step 2 Dynamic deviation spectra of each discrete wavelength: First, the aver-age absorbance of each discrete wavelength was calculated as the follows: , 1 , 1, 2, , .
Then, the dynamic deviation spectra of each discrete wavelength were calculated as the follows: , .
Step 3 Global stability evaluation indicators of multi-channels spectral system: Firstly, the correlation coefficient between the dynamic deviation spectra of any two discrete wavelengths was calculated.The corresponding coefficient matrix was written as the follows: ( ) , . where denoted the correlation coefficient between the dynamic deviation spectra of the p th and q th wavelengths.There been m − correlation coefficients between the k th wavelength and the remaining 1 m − wavelengths.Their mean and standard deviation were denoted as tively.The consistent comprehensive evaluation indicator of each channel (wavelength) with respect to the other channels were as the follows: ,Ave ,SD , 1, 2, , .
Further, the evaluation indicators for global stability of the multi-channels spectral system were written as the follows: ( ) If all k R  reached higher values, that indicated the stronger consistency of all channels, that is, the multi-channels spectral system had better global stability.
In the latter embodiment based on the PLS regression combined with SG smoothing, a spectral correction method for enhancing prediction performance of the multi-channels spectral system was also provided by using the above evaluation indicators.

Calibration and Prediction Process
In chronological order, all samples were divided into the calibration (140 samples) and prediction (128 samples) sets.The root-mean-square errors and correlation coefficients for prediction (SEP, R P ) were then calculated and denoted as follows: ( ) T. Pan et al.
where N was the sample size of prediction set; ，respectively.The SEP and R P were used for prediction accuracy evaluating of a PLS model.A smaller SEP value represented a higher prediction accuracy, and a larger R P value represented a higher prediction correlation.The model parameter (number of PLS factors, F) selection was performed to achieve the minimum SEP.

Global Stability Indicators and Prediction Effect without Spectral Correction
The original spectra of 268 corn powder samples for eleven discrete NIR wavelengths are shown in Figure 1.As can be observed in Figure 1, the baseline-drift of the spectra of different samples was obvious.Next, the global stability evaluation indicators of multi-channels spectral system mentioned in section 2.2 were calculated.
A sample was randomly selected and subjected to continuous spectroscopic measurements 20 times, the obtained dynamic absorbance spectra for eleven channels as shown in Figure 2(a).The dynamic deviation spectra for eleven channels were calculated as shown in Figure 2(b).It can be seen that the correlation among the dynamic deviation spectra of each channel was low.
According to Step 3 in the section 2.2, the global stability evaluation indicators were further calculated, as shown in Table 1.It can be seen that for each channel, the ,Ave k R value was smaller, the ,SD k R value was large, and the k R  value was small.The results indicated that global stability of the multi-channels system without spectral correction was poor.In fact, poor consistency between each monochromatic light leads to lack global stability.
The PLS calibration and prediction models for corn moisture were also established.The optimal number of PLS factors (F) was 3, the corresponding SEP and R P values were 0.373% and 0.702, respectively.The relationship between the predicted and actual corn moisture values of the prediction samples are shown in

Global Stability Indicators and Prediction Effect with SG Smoothing
In order to eliminate the spectral noise, we next carried on the pretreatment to the spectra.The SG method takes an odd number of successive wavelengths as a smooth window, and the spectral data at the window were fitted by using a polynomial function.Then the smoothing value and each order derivative value at   .Since the spectrometer system only has eleven wavelengths, in order to make the correction window as much as possible, the number of smoothing points was set to the minimum value of 5 ( 5 s = ), to eliminate baseline-drift and tilt, the second-order derivative was used ( 2 d = ) and to avoid 2 nd derivative data into artificial linearization, the degree of polynomials should be greater than or equal to 4. So, the SG parameters of d = 2, p = 4 and s = 5 were used and applied for the spectral correction here.
The SG derivative spectra for the eleven discrete wavelengths are shown in Figure 4.The results showed that the baseline-drift of the spectrum is significantly improved.
Next, the 2 nd derivative spectra with SG smoothing for eleven channels were shown in Figure 5(a).The dynamic deviation spectra for eleven channels were also calculated as shown in Figure 5(b).It can be seen that the correlation among the dynamic deviation spectra of each channel was high.
According to Step 3 in the section 2.2, the global stability evaluation indicators with SG smoothing correction were further calculated, as shown in Table 2.It can be seen that for each channel, the ,Ave k R value was increased by a large margin, the ,SD k R value was significantly decreased and the k R  value also had a substantial increase, which indicated that the global stability of the spectral system was observably better.
The PLS calibration and prediction models with SG smoothing for corn moisture were also established.The optimal number of PLS factors (F) was 2, the corresponding SEP and R P values were 0.283% and 0.855, respectively.The relationship between the predicted and actual corn moisture values of the prediction samples are shown in Figure 6.The results showed that the prediction accuracy was obviously better than that without SG smoothing.
By comparing the results of Table 1 and Table 2, Figure 3 and Figure 6, it can be seen that the global stability evaluation indicators k R  significantly increased after SG smoothing correction.Meanwhile, the corresponding SEP value of the quantitative analysis model was significantly reduced, and the R P value between the predicted value and the actual value was also obviously improved.The above results indicated that by improving the global stability indicators, the prediction ability of multi-channels spectral system can be improved.
In fact, after SG smoothing, the absorbance of center wavelength is corrected by the absorbance of all wavelengths in the smoothing window, thereby establishing a correlation between the channels (wavelengths), so that the correlation  of the dynamic deviation spectra between the channels can be effectively enhanced.
There are also several methods that use multiple wavelengths to correct single wavelength, such as multiplicative scatter correction (MSC), etc.In future studies, these methods can be used for spectral correction to improve the global stability of the multi-channels system.

Conclusions
The development of diminutive and low-cost instruments is very valuable for the large-scale application of NIR spectroscopy.The NIR spectrometer based on se-  Since the consistency between each monochromatic light is poor, the independent SNR of each light source is difficult to evaluate the global stability for the NIR system with multiple light sources.As far as we know, the evaluation method of the stability of multi-light system has not been reported.In order to avoid random interference caused by inconsistency between light sources, the novel indicators for objectively evaluating the global stability of the multi-channels spectral system were proposed on the basis of the correlation between the dynamic deviation spectra of any two channels.Through the NIR analysis of corn moisture based on the PLS regression combined with SG smoothing, a spectral correction method for enhancing prediction performance of the multi-channels spectral system was further provided using the above evaluation indicators.
The experiment results indicated that by improving the global stability indicators, the prediction ability of multi-channels spectral system can be improved.
The proposed method provided a new standard for designing multi-channels diminutive spectrometer with high prediction performance, which had significance for the large-scale application of NIR technology.
mean actual and predicted values in the prediction set were written as Ave Ave , C C 

Figure 1 .
Figure 1.Original spectra of 268 corn powder samples for eleven discrete NIR wavelengths.

Figure 2 .
Figure 2. Original spectra of repeat measurement experiment for (a) dynamic absorbance and (b) dynamic deviation.

Figure 3 .
Figure 3.It can be seen from the results that prediction accuracy of the PLS model was lower.

Figure 3 .
Figure 3. Relationship between the predicted and actual corn moisture values based on the original spectra.

Figure 4 .
Figure 4. Second-order derivative spectra with SG smoothing of 268 corn powder samples for eleven discrete NIR wavelengths.

Figure 5 .
Figure 5. Second-order derivative spectra with SG smoothing of repeat measurement experiment for (a) dynamic absorbance and (b) dynamic deviation.

Figure 6 .
Figure 6.Relationship between the predicted and actual corn moisture values based on the SG correction spectra.

Table 1 .
Evaluation indicators for global stability without spectral correction.

Table 2 .
Evaluation indicators for global stability with SG smoothing correction.