# Automated Detection and Classification of Returnable Packaging Based on YOLOV4 Algorithm
## 3 Results and Discussion
### Results
The Average loss did not change a lot and it was between 1.18 and 1.26. Charts of Average loss are presented in Appendix A.2. In the third part of the first cycle for the Mish activation function, the following results peak values are the following: mAP value of 94.25%, F1 score of 0.86, Average IoU 61.52%, Precision 0.81, Recall 0.93 and Average loss in the amount of 1.2489. As in the previous two parts, average loss charts can be seen in Appendix A.3. \begin{table}
\begin{tabular}{l c c c c c c c c c} \hline \hline
**Max Batches** & \multicolumn{8}{c}{**10,000**} \\ \hline
**Activation Function** & \multicolumn{2}{c}{**Linear**} & \multicolumn{3}{c}{**ReLu**} & \multicolumn{3}{c}{**Mish**} \\ \hline
**Train/test ratio** & 70/30 & 75/25 & 80/20 & 70/30 & 75/25 & 80/20 & 70/30 & 75/25 & 80/20 \\ \hline
**mAP** & / & / & / & 99.90\% & 99.90\% & 99.77\% & 99.84\% & 99.83\% & 99.81\% \\ \hline
**F1 score** & / & / & / & 0.99 & 0.99 & 0.98 & 0.99 & 0.99 & 0.99 \\ \hline
**Average IoU** & / & / & / & 84.14\% & 84.59\% & 83.41\% & 83.44\% & 83.59\% & 83.33\% \\ \hline
**Precision** & / & / & / & 0.98 & 0.99 & 0.98 & 0.99 & 0.99 & 0.98 \\ \hline
**Recall** & / & / & / & 1.00 & 1.00 & 1.00 & 1.00 & 0.99 & 1.00 \\ \hline
**Average Loss** & / & / & / & 0.6320 & 0.6951 & 0.6862 & 0.6945 & 0.6809 & 0.6500 \\ \hline
**Max Batches** & \multicolumn{8}{c}{**20,000**} \\ \hline
**Activation Function** & \multicolumn{2}{c}{**Linear**} & \multicolumn{3}{c}{**ReLu**} & \multicolumn{3}{c}{**Mish**} \\ \hline
**Train/test ratio** & 70/30 & 75/25 & 80/20 & 70/30 & 75/25 & 80/20 & 70/30 & 75/25 & 80/20 \\ \hline
**mAP** & / & / & / & 88.33\% & 88.60\% & 89.08\% & 89.92\% & 99.96\% & 99.94\% \\ \hline
**F1 score** & / & / & / & 0.86 & 0.86 & 0.87 & 0.87 & 1.00 & 1.00 \\ \hline
**Average IoU** & / & / & / & 84.41\% & 86.68\% & 83.90\% & 82.73\% & 91.13\% & 91.06\% \\ \hline
**Precision** & / & / & / & 0.95 & 0.96 & 0.94 & 0.93 & 1.00 & 1.00 \\ \hline
**Recall** & / & / & / & 0.75 & 0.79 & 0.80 & 0.81 & 1.00 & 1.00 \\ \hline
**Average Loss** & / & / & / & 0.9219 & 0.8496 & 0.7914 & 0.8598 & 0.3643 & 0.3400 \\ \hline \hline \end{tabular}
\end{table} 
Table 5: Overall overview of the results obtained through this research for the third and fourth training cycle. For the fourth and fifth, parts of the second training cycle, the results of the obtained models are slightly better than in the first three parts. The maximum mAP value is 99.77% in favor of the ReLU activation function, while the minimum value is 91.27% in favor of the Linear activation function. The maximum value of the F1 score was on several occasions 0.97 for the ReLU and Mish activation functions, which was also the peak value, while the minimum value was 0.59 for the Linear activation function. Charts of the training process can be seen in Appendix C in Appendix C and C.2. The results of the third and fourth training cycles, i.e., 10,000 and 20,000 max batch size are given in Table 5. The Linear activation function is eliminated because of poor performance from the previous investigation. As in the last case, each training cycle of this research was conducted using the previous three train/test ratios. In the last training cycle, it is evident that the lowest average loss results were obtained compared to other training cycles. The results of mAP vary between 88.33% and 99.96%, the highest F1 score was 1.00 while the lowest was 0.86. Both Precision and Recall ranged between 0.79 and 1. The highest score achieved for the Average IoU was 91.13%. The whole training process and average loss curve for the last two training cycles can be seen in Appendix D. The training process for the Relu activation function is shown in Appendix D and for Mish in Appendix D.2.