## 4 Parameters Optimization
\begin{table}
\begin{tabular}{c c c c} \hline \hline
**Gamma** & **C** & **F value** & **Accuracy** \\ \hline \(\mathbf{10^{-1}}\) & \(\mathbf{10^{1}}\) & 97.9\% & 98.6\% \\ \(\mathbf{10^{-1}}\) & \(\mathbf{10^{3}}\) & 97.9\% & 98.6\% \\ \(\mathbf{10^{-4}}\) & \(\mathbf{10^{7}}\) & 97.7\% & 98.5\% \\ \(\mathbf{10^{-1}}\) & \(\mathbf{10^{7}}\) & 97.7\% & 98.5\% \\ \(\mathbf{10^{-4}}\) & \(\mathbf{10^{9}}\) & 97.7\% & 98.5\% \\ \(\mathbf{10^{-4}}\) & \(\mathbf{10^{10}}\) & 97.7\% & 98.5\% \\ \(\mathbf{10^{-3}}\) & \(\mathbf{10^{5}}\) & 97.7\% & 98.5\% \\ \(\mathbf{10^{-2}}\) & \(\mathbf{10^{4}}\) & 97.7\% & 98.5\% \\ \(\mathbf{10^{-2}}\) & \(\mathbf{10^{5}}\) & 97.5\% & 98.4\% \\ \(\mathbf{10^{-2}}\) & \(\mathbf{10^{7}}\) & 97.5\% & 98.4\% \\ \(\mathbf{10^{-2}}\) & \(\mathbf{10^{8}}\) & 97.5\% & 98.4\% \\ \(\mathbf{10^{-1}}\) & \(\mathbf{10^{5}}\) & 97.5\% & 98.4\% \\ \(\mathbf{10^{-1}}\) & \(\mathbf{10^{6}}\) & 97.5\% & 98.4\% \\ \(\mathbf{10^{-3}}\) & \(\mathbf{10^{6}}\) & 97.3\% & 98.3\% \\ \(\mathbf{10^{-2}}\) & \(\mathbf{10^{6}}\) & 97.3\% & 98.3\% \\ \(\mathbf{10^{-3}}\) & \(\mathbf{10^{9}}\) & 97.1\% & 98.2\% \\ \(\mathbf{10^{-3}}\) & \(\mathbf{10^{7}}\) & 96.9\% & 98.0\% \\ \(\mathbf{10^{-4}}\) & \(\mathbf{10^{6}}\) & 96.9\% & 98.0\% \\ \(\mathbf{10^{-2}}\) & \(\mathbf{10^{3}}\) & 96.9\% & 98.0\% \\ \(\mathbf{10^{-1}}\) & \(\mathbf{10^{2}}\) & 96.9\% & 98.0\% \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Metrics of Different Parameter Combination Models for the Validation Set. Figure 6: Variation curve of metrics with C at gamma = 0.1. (The red curve represents accuracy while the blue curve represents the F value). the proportion of negative samples in the data set. Through verification of the actual value, it is found that when the penalty factor is small, the model will predict all of the samples in the validation set as negative, so the initial accuracy will be maintained at 70%. This also proves that the algorithm has no fault tolerance rate because there is little penalty for the error term in the beginning, i.e., no error is allowed in the training set so that the hyperplane spacing of SVM is very small, resulting in the algorithm prediction results being negative. With the increasing effect of penalty factors, the penalty of error samples increases. By adjusting the proportion of penalty factors to each feature of the model, the prediction accuracy increases. Finally, when the penalty is large enough to blindly pursue the generalization ability, the fault tolerance rate in the training set will be very high and the hyperplane spacing will be very large, so that the validation set will be more prone to error classification, which will lead to a slight decrease in the metrics. When C = 10, the variation of the metrics with gamma is shown in Figure 7. As can be seen, with the increase in gamma, the metrics also show a tendency to increase first and then decrease. When gamma is very small, the value of the Gaussian kernel function is equal to about 0. Now, SVM has a kernel function whose value is constant zero. The SVM algorithm gives negative prediction results for all of the data, so the initial F value is zero; accuracy is 70% (about equal to the proportion of negative values in the data set). With the increase in gamma, the Gaussian kernel function starts to play a role, which is equivalent to mapping the original data into an infinite dimensional space. However, when the metric increases to a certain value, there will be a reduction. This can be mainly attributed to the over-fitting phenomenon, as the gamma value becomes too large. The phenomenon has a good effect on the training set, but is difficult to generalize to the validation set. Therefore, the metrics increase first and then decrease. Finally, the parameters of the classifier model are determined as follows: gamma = 0.1, C = 10.