## 5 Experimental Results
### Software Results  
In this research, we first use the dish dataset to train the YOLOv3 model under darknet. During the training process, we save the model every 1000 epochs, and we also save the model with the largest mean average precision (mAP) for subsequent research. Figure 6 shows the results of the trained model from 1000 epochs to 30,000 epochs. Generally speaking, in object detection, mAP is a comprehensive indicator for evaluating the detection ability of a model. Therefore, in this research, we call the model with the largest mAP in a certain training process as the best model of the training process.  
The evaluation indicators and related definitions in Figure 6 are as follows [44; 45]:  
\(TP\): True Positive means that the samples are classified as positive samples and assigned correctly;  
\(TN\): True Negative means that the samples are classified as negative samples and assigned correctly;  
\(FP\): False Positive means that the samples are classified as positive but wrongly assigned;  
\(FN\): False Negative means that the samples are classified as negative samples but wrongly assigned;  
\(P\): Precision means the proportion of the number of correctly assigned positive samples to the total number of all assigned positive samples. The formula is (1);  
\(R\): Recall means the proportion of the number of correctly assigned positive samples to the total number of real positive samples, and the formula is (2).  
\(F1\): F1 score is the harmonic mean of precision and recall. It is an evaluation indicator that integrates Precision and Recall. It avoids the single maximum value of Precision or Recall and is used to comprehensively reflect the overall indicator. The formula is (3):  
\[Precision=\frac{TP}{TP+FP} \tag{1}\]  
\[Recall=\frac{TP}{TP+FN} \tag{2}\]  
\[F1=2\times\frac{Precision\times Recall}{Precision+Recall} \tag{3}\]  
The Precision-Recall curve can measure the quality of the object detection model, but it is not convenient for comparing the models. On the basis of the precision-recall (P-R) curve, by calculating the average value of the precision value corresponding to each recall value, an evaluation indicator is obtained: average precision (AP), which is used to measure the detection capability of trained model on the class of interest. Before calculating AP, in order to smooth the P-R curve and reduce the influence of curve jitter, the P-R curve is first  
Figure 6: Detection results under darknet.  
interpolated. Given a Recall value R, the Pinterp used for interpolation is the maximum Precision value between the current R value and the next Recall value R'. AP calculation can be defined as the area of the interpolated precision-recall curve and the \(x\)-axis, as shown in Formula (4), where \(R_{1}\), \(R_{2}\),..., \(R_{n}\) is the Recall value corresponding to the first interpolation of the Precision interpolation segment in ascending order. The average value of each category of AP is denoted as mAP. Suppose there are K detection types in total and the formula is shown in (5), and mAP measures the detection ability of the trained model on all types:  
\[AP=sum_{i=1}^{n-1}(R_{i+1}-R_{i})Pinterp(R_{i+1}) \tag{4}\]  
\[mAP=\frac{sum_{i=1}^{K}AP_{i}}{K} \tag{5}\]  
For the best model with the largest mAP, we also recorded the specific detection results of each dishes, as shown in Table 1. At the same time, we use this best model as the base model for subsequent pruning process and deployment to FPGA.