3.2.3. GA-PLS Prediction Model of Apple Spoilage

The main parameters of GA were set as follows: the number of initial chromosomes was 30, the deletion group was 5, the mutation rate was 0.01, the crossover probability was 0.5 and the maximum number of iterations was set to 100. The cumulative frequency of the variables screened by the GA algorithm is shown in Figure 5c, and 32 variables were screened out. The PLS quantitative prediction model corresponding to the apple spoilage area was established through the screened characteristic variables. The specific scatter diagram of the model is shown in Figure 6c.

#### 3.2.4. SA-PLS Prediction Model of Apple Spoilage

The main parameters of SA in this study were set as follows: the initial temperature was 10, the end temperature was 1, the Markov chain length was 10, the temperature cooling coefficient was 0.95, the window starting width was 10 and the window ending width was 20 and increasing. The step size was 1, the number of wavenumber points exchanged each time the Markov chain was 2 and the maximum number of principal components for modeling was 12. Figure 5d shows the results of variable screening of sensor data through SA, and 20 characteristic variables were screened out. The results of the established SA-PLS model are shown in Figure 6d.
