Method for UAV spraying pattern measurement with PLS model based spectrum analysis

Unmanned aerial vehicle (UAV) chemical application is widely used for crop protection, and spraying pattern is one of the most important factors that influence the chemical control efficacy. A method for UAV spraying pattern measurement with partial least squares (PLS) model based spectrum analysis was proposed in this study to measure the UAV spraying pattern more accurately. The method involved the steps of fluorescent tracer solution spray and its droplets collection, the spectrum on paper strip acquiring, spectrum processing and analysis, PLS modeling. In order to verify the applicability of the method and obtain the parameters of the PLS model, UAV spraying experiments were performed in the field. Then Fluorescent tracer solution was sprayed and its droplets are collected by paper strip, and the original spectrum on paper strip obtained by a spectrometer was processed by the Savitzky-Golay and standard normalized variable (SNV) method. The prediction model of coverage rate selected as the droplet deposition parameter to measure the UAV spraying pattern, was established by using PLS method. To verify the superiority of the PLS model, a traditional linear regression (LR) model of coverage rate was established simultaneously. The results demonstrate that the method with PLS model based spectrum analysis can measure the UAV spraying pattern effectively, and PLS model has a better performance of RV=0.94 and RMSEP=0.9446 than that of the LR model.


Introduction
Unmanned aerial vehicle (UAV) is typically low cost, light weight and low airspeed aircraft that is developing rapidly and using worldwide in the plant protection. And UAV chemical application is beneficial to improve the utilization of agricultural resources and achieve the goal of precision aerial application [1,2] . Flight height of the UAV and complex downwash flow field of its rotors will directly influence the movement and pattern of the spraying droplets [3,4] . Therefore, the accurate measurement of spraying pattern has an important significance for improving the control efficacy of UAV chemical application [5] .
Many studies of equipment and technology have been conducted to measure spraying deposition and spraying pattern. One of the most common methods is using water sensitive paper and digital image analysis technology [6,7] . Cheng et al. [8] selected a Ponceau 2R solution with a mass fraction of 5% to simulate the spraying deposition of a growth regulator. And the parameters results of droplet deposition in the target areas and non-target areas were analyzed by image processing software DepositScan. Another accurate method is the evaluation of fluorescent tracer by using spectrophotometers, and spraying pattern was inverted by the calculation of the tracer content [9][10][11] . Xue et al. [12] measured the droplet deposition on rice within the spray swath and the droplet drift volume sampled by polyester cards and polyester fibers. The Rhodamine-B (aqueous) tracer was mixed and sprayed from airplane. The Rhodamine-B on each film collector was eluted by deionized water, and the deposition of Rhodamine-B in the eluent was calculated according to the "concentration-fluorescence" standard curve of the Rhodamine-B standard. But there are still some limitations, such as high costs, complex operation, and the collected data maybe damaged before analysis. Computational fluid dynamics (CFD) model was gradually concentrated due to its intuition and accuracy [13,14] . Yuan et al. [15] studied the droplet deposition model of an air delivered fog sprayer in a greenhouse using CFD simulation technique. However, the results should be verified by experiments. Currently, some scholars exploited sensors to detect droplets [16] . Droplet deposition detection system was developed by Zhang et al. [17] using a variable dielectric capacitor. With this system, the droplet deposit volume could be rapidly measured in aerial spray application. However, the sensor was effective for detection of rough spray, and the details need to be improved. There also have been several recent developments to measure spray application and droplet distribution using other methods [18][19][20][21][22][23][24] , remote sensing, infrared thermography, etc.
As mentioned above, researchers have carried out many studies to achieve the spraying pattern measurement more efficient and accurate. In this study, a method for UAV spraying pattern measurement with partial least squares (PLS) model based spectrum analysis was proposed, and field experiments were conducted to verify the applicability of the method.

Experimental design
Field experiments were conducted at National Precision Agriculture Research Station (40°10ʹ57ʹʹN, 116°27ʹ27ʹʹE) in China on June 30, 2017. As shown in Figure 1, an 8-rotor UAV used in this experiment and the specifications of the UAV are shown in Table 1.  Average flight speed/ m·s -1 1.5 The spraying system of the UAV is consisted of water-pump, spraying boom, nozzles and other components. The system uses the PLD-1206 type diaphragm pump operated at DC 12V and produced flow rates of up to 4.0 L/min, which support the maximum spraying pressure is 1.0 MPa. The spray boom length was 2.4 m, and six LU120-02 type nozzles (Lechler GmbH, Germany) with 128.3 μm volume median diameter (VMD) under pressure 0.3 MPa [25] were equidistantly mounted on it with a spacing of 0.48 m.
Fluorescent brightener RQT-C-3 was used as a fluorescent tracer for the spraying experiment, with a strong fluorescent signal and water solubility, and mixed with water to a final mass concentration of 1.0%. Two tests were performed with the same performance parameters. A ordinary Kraft paper strip with 19.3 mm width and 0.3 mm thickness was adopted as droplet collector. The paper strip is commercial, contains no fluorescent compounds itself, exhibits a degree of water absorbability and is easy to collect and store for the field test.
The sampling layout is shown in Figure 2. Paper strip was mounted on the shelf at a height of 1 m above the ground. To quantify the spraying pattern, water sensitive paper (WSP) cards (Syngenta Crop Protection AG, Switzerland) with the size of 26 mm×76 mm were placed near the paper strip. The sample length of the paper strip was 5 m, which covers the effective spraying swath. 26 WSP cards evenly spaced 0.2 m apart were placed along with the paper strip and the sampling positions were labeled 1-26. Paper strips and WSP cards were collected in sealed bags once dry.

Acquiring of the spectrum on paper strip
Fluorescent tracer sprayed on the paper strip was excited by ultraviolet light and emitted fluorescence which can be measured by a spectrometer. To improving the spectrum acquisition efficiency, a device was designed. Overall structure of the device is shown in Figure 3, which included ultraviolet light, spectrometer, sampling reel, stepper motor, and a box.
The ultraviolet light with a wavelength range of 300-400 nm was applied to excite fluorescent tracer RQT-C-3, and a spectrometer (FLAME-S-VIS-NIR, Ocean Optics, USA) in the spectral scanning range of 340 nm to 1014 nm contains 2048 wavelengths which covering the emission wavelengths of the fluorescent tracer was adopted to acquire the spectral intensity values of the paper strip in this study. The paper strip was wound onto the sample reel with 80-mm-diameter, and a two-phase hybrid stepper motor with a rotating speed of 30 r min -1 was used to drive the shafts of the sample reel. The revolutions of the stepping motor could be converted to a linear distance L (m) of sample reel using Equation (1).
L=40πt+0.15t 2 (1) where, t (s) is the sampling time. The sealed structure of the box with the size of 44 cm (length) × 32 cm (width) × 35 cm (height) was was designed to avoid the influence of ambient light.
With an integral time of the spectrometer and sampling time of 100 ms, the spectrum of paper strips was acquired and saved as a CSV file by PC software of the spectrometer. 379 and 376 sets of spectrum were collected in test 1 and test 2 respectively. The spectrum of three sampling points were selected on the paper strip near each corresponding WSP card, spectral average intensity values of the three sampling points were calculated and taken as the original spectrum of samples in each sampling position, and samples were denoted as Sample 1 to Sample 26 in the test 1 or Sample 27 to Sample 52 in the test 2.

WSP cards analysis
As shown in Figure 4, WSP cards were scanned with a high pixel resolution of 1200 dpi into digital images using a portable scanner. From these WSP images, the coverage rate was calculated via iDAS Pro software [26] . Coverage rate was the ratio of the stained area covered by droplets to the sampled area on WSP cards, which was selected as the droplet deposition parameter to characterize the spraying pattern in this study. And the coverage rate result of the WSP in test 1 and test 2 is shown in Figure 5

Spectrum processing and analysis
As shown in Figure 6a, the original spectrum of 52 samples in the band range of 400-600 nm on the paper strip was selected to demonstrate the effect of the spectrum processing method.
The spectrum contains not only the information of the sampling point but also other interference components, such as instrument noise and stray light. The Savitzky-Golay method was employed in this study to reduce the random noise of spectrum, this method smooth a signal locally with a low-degree polynomial based on the linear least squares method to a sliding window of data [27] . The degree of the polynomial and the length of the sliding window are respectively set to 2 and 15 to improve the reliability of the smoothed spectrum. As shown in Figure 6b, it can be seen that original spectrum and smoothed spectrum have the same trends, and several apparent absorption peaks emerged in the 400-600 nm region. It was indicated that the Savitzky-Golay method can effectively remove the noise and the burr of the spectrum, and the useful information of the spectrum was remained.
The standard normalized variable (SNV) method is a common method for eliminating baseline translation and shift caused by light scattering [28] , and the principle of SNV is that the absorbance values of each wavelength point in the spectrum satisfy a certain normal distribution. The standard normalized spectral Z i of raw spectral x i was calculated using Equation (2).
where, μ and σ are the mean and the standard deviation of the spectrum, as shown in Figure 6c. After processed by Savitzky-Golay and SNV method, the whole spectrum of 52 samples is shown in Figure 6d. Ultraviolet light information was inevitably collected by the spectrometer during the spectrum acquisition, and it can be observed that the normalized intensity was saturated in the wavelength range of 340-400 nm. Therefore, the spectrum in the wavelength range of 400-1014 nm was extracted for subsequent analysis.  Figure 6c, the spectrum in the wavelength range of 400-600 nm shows a significant fluorescence effect between the 52 samples. The correlation analysis was analyzed between the coverage rate of WSP and the normalized intensity of paper strip in the range of 400-600 nm contains 562 wavelengths. The results of the treatment were shown in Figure 7. It is known from the diagram that the correlation coefficients of the 352 wavelengths in the wavelength range of 414-540 nm are significant and greater than 0.90, therefore normalized intensity in the wavelength range of 414-540 nm of 52 samples were selected as the inputs variables for PLS model. Meanwhile, the wavelength range of 485-495 nm was selected and noted as C 485-495 for the LR model [24] .

Figure 7 Results of correlation coefficient analysis 3.2 PLS modeling for UAV spraying pattern measurement
The establishment of PLS modeling followed the steps of outlier detection, variable selection, and PLS modeling.

Outlier detection
Outliers arise due to mechanical faults, changes in system behavior, fraudulent behavior, human error, instrument error or simply through natural deviations in populations [29] .
When incorporated into PLS model, outliers may lead to erroneous results with respect to statistical analysis, and reduce the performance of the model significantly. So the detection of outliers is one of the most important steps during the PLS model. Monte Carlo sampling approach was selected as the method for outlier detection and elimination, which was proposed to obtain the distribution of prediction error of each sample [30,31] . The main procedures of this method are as follows: a. Determine the number of latent variables, calibration samples and test samples.
b. Select calibration and test sets randomly from the whole dataset, which was used to build a prediction model and obtain the prediction errors for samples in the test set.
c. Pretreat calibration data. d. Implement PLS regression using the non-linear iterative partial least squares (NIPALS) algorithm.
e. Predict the test samples. f. The mean (MEAN) and standard deviation (STD) of the prediction errors of each sample were employed to diagnose outliers.
The number of Monte-Carlo sampling and sampling ratio is set to 1000 and 0.7, respectively. The result of MEAN and STD of prediction errors of 52 samples is shown in Figure 8, Sample 14, Sample 15, and Sample 41 with the MEAN greater than 4 and the STD greater than 2 were determined to be outliers and removed before modeling. 49 normal samples were retained for further modeling. 33 samples are selected as modeling sets, and 16 samples are selected as validation sets.

Variable selection using Random Frog algorithm
To simplify the model and improve the accuracy of a predictive model greatly, Random Frog (RF) algorithm was implemented for characteristic variable selection as a general strategy [32] . And PLS is used as a modeling method in RF algorithm. The steps of RF algorithm are as follows: a′. A subset of variables V 0 consisting of the number of variables Q was initialized randomly. b′. A candidate variable subset V* was proposed based on the original subset of variables, and its variables number is a random number Q*.
PLS model is established. The regression coefficient of each variable in this PLS model is recorded. Afterwards, the Q* variables which have the largest absolute regression coefficients in PLS model are retained and collected as a candidate subset V*. V* was accepted as V 1 with a certain probability. Then V 0 was replaced using V 1 . These iterations are repeated until N loops have finished.
c′. Finally a selection probability of each variable is computed which can be used as the measurement of variable importance. The variable is more likely selected with a large value of probability.
The operation of selecting characteristic variable was conducted on the modeling set. As shown in Figure 9, the normalized intensity of 12 wavelengths with the probability greater than 0.

Modeling using PLS regression algorithm
Unlike LR, PLS regression provides an approach based on principal components analysis (PCA) to analyze data with strongly collinear correlated, noisy, and even incomplete variables in both X and Y [33] . In which, the precision of the model parameters is improved along with the increasing number of relevant variables and observations. And the matrix of predictor variables X and the matrix of response variables Y was pretreated firstly. A PLS model was established by the PLS regression NIPALS algorithm, and the regression coefficients that link X and Y were get.
To determine the number of principal components of the PLS model and avoid the impact of redundant information on the model, 10-fold cross validation algorithm was applied. As shown in Figure 10, the tendency of root mean square error of cross validation (RMSECV) was obtained. RMSECV has the minimum value of 0.7870 when the number of latent variables is 7. So that PLS model was established with 7 numbers of latent variables. The value of coverage rate was the outputs of the PLS model. As shown in Figure 11, the modeling determination coefficient R C 2 reached to 0.98, the root mean square error of modeling (RMSEC) was 0.5098. The validation determination coefficient R V 2 reached to 0.94, the root mean square error of validation (RMSEP) was 0.9446.

Comparison between the result of PLS and LR model
In order to compare and validate the performance of PLS model, a traditional LR model for UAV spraying pattern measurement was established. Based on the average spectral intensity value C 485-495 and coverage rate of the WSP, 34 sets of data selected from 52 samples were used to establish the LR model. The remaining 18 sets of data were used to validate the models. The value of coverage rate was represented as y, and C 485-495 was represented as x. The LR model expressed as Equation (3): y = -5.1975+12.5694x (3) As shown in Figure 12, the R C 2 reached to 0.88 and the  Figure 13 Comparison results between WSP, LR model and PLS model

Conclusions
In this study, a method with PLS model based spectrum analysis was proposed to measure the UAV spraying pattern more accurately, and spraying experiments were conducted in the field to verify the effectiveness of the method. The main conclusions are as follows: (1) The method involved the steps of fluorescent tracer solution spray and its droplets collection, the spectrum on paper strip acquiring, spectrum processing and analysis, PLS modeling. And the method can measure the UAV spraying pattern effectively.
(2) Due to the influence of the instrument instability and the interference of scatter, the original spectrum contains random noise and baseline translation. Therefore, Savitzky-Golay method was chosen for reducing the noise of the original spectrum. And SNV method was chosen for eliminating the scattering effects caused by the overlap of droplets and paper strips background. Spectrum processing was benefited for the futher spectrum analysis and PLS modeling.
(3) PLS model was established based on the normalized intensity of 12 sensitive wavelengths, and LR model was established based on the average spectral intensity value of 485-495 nm. The result indicates that the PLS model for UAV spraying pattern measurement has more accuracy than that of the LR model with a better performance of R V 2 =0.94, RMSEP=0.9446. (4) The method with PLS model based spectrum analysis provides a new way for the measurement of UAV spray pattern. However, only some preliminary researches for this method were conducted in this study and the accuracy of UAV spraying pattern measurement could be affected by many factors, such as the fluorescent tracer solution concentration, the influences of sprayed chemicals on the excitation and emission wavelengths of the fluorescent tracer, and the integral time of the spectrometer. In future work, further experiments are required to study as many influencing factors as possible to optimize the model for UAV spraying pattern measurement, so that the measurement model can satisfy the evaluation requirements for the high robustness and detection accuracy in different complex conditions.