# Automatic Fruits Freshness Classification Using CNN and Transfer Learning
## 4 Simulation Results
### Discussion  
The points discussed above give good insight about the fruit freshness classification performance of our developed method. However, the discussion below sheds more light on the performance of our developed algorithm.  
* Our study indicates that different networks achieve diverse accuracy outcomes on different algorithms. The MobileNetV2 trained by [20] on Dataset 2 achieves 97.14% classification accuracy. Whereas VGG16 and InceptionV3 achieve 96.10% and 97.10% classification accuracy, respectively. On Dataset 2, the ResNet50 achieved the lowest classification accuracy of 73.26%.  
\begin{table}
\begin{tabular}{c c c c c} \hline \hline \multicolumn{2}{c}{**Method**} & \multicolumn{4}{c}{**Datasets**} \\ \cline{3-5}  & **Dataset 1** & **Dataset 2** & **Dataset 3** \\ \hline
[5] & Improved YOLO & 97\% & – & – \\ \hline
[19] & Trained CNN & – & 97.14\% & – \\ \hline
[20] & MobileNetV2 & – & 88.62\% & – \\ \cline{2-5}  & ResNet50 & – & 73.26\% & – \\ \cline{2-5}  & VGG16 & – & 96.10\% & – \\ \cline{2-5}  & InceptionV3 & – & 97.10\% & – \\ \hline
**Mean** & & & **88.77\%** & \\
**Accuracy**[20] & & & & \\ \hline
[23] &
\begin{tabular}{c} Compare different feature \\ extraction techniques \\ classification through SVM \\ \end{tabular} – & 97.61\% & – \\ \hline
[24] &
\begin{tabular}{c} Freshness classification \\ using RESNET50 \\ \end{tabular} – & – & 98.89\% & – \\ \hline
[25] & CNN + ResNet50 & – & – &
\begin{tabular}{c} Pioneered to \\ introduce this \\ dataset. \\ \end{tabular} \\ \hline
**Proposed Method** & **98.2\%** & **99.8\%** & **99.3\%** \\ \hline \hline \end{tabular}
\end{table}
Table 3: Mean accuracy (%) comparison.  
Our method in general performs well on all the three datasets and achieves at least 98% classification accuracy as reported on Dataset 2 and also shown in Table 3. We believe that for Dataset 2, our proposed method has almost solved the fruit freshness classification problem by achieving the 99.8% accuracy.
* In general, all the compared methods perform well to handle the fruits freshness classification challenge and achieve at least 88% accuracy. One of the reasons for our developed method's superior performance is employment of data augmentation in pre-processing stage, which significantly mitigates overfitting on small datasets. Similarly, while using the pre-trained CNN architecture model and replacing the last layer with required targeted class also are reasons for our model's superior classification performance.
* Our method achieves high accuracy and outperforms several recently published works [5; 19; 20; 23; 24; 25] due to intelligent selection of the AlexNet architecture. Our study indicates that the training time of AlexNet architecture is five times faster as compared to others deeper architecture speed. Moreover, the AlexNet is computationally efficient and does not require high performance workstation [26]. Similarly, in presence of other functions, for instance, _tanh, logistic, arctan, or Sigmoid_ as activation functions, the AlexNet uses the ReLU activation function that drastically reduces likelihood of vanishing gradient problem.
* The layers in the AlexNet architecture contains more filters and each convolution layer is followed by a pooling layer. Such characteristics motivated us to utilize the AlexNet to address the fruits classification problem. Similarly, rotation and augmentation procedure as described in Section 3 increases the fruits images that ultimately resulted in good training of the AlexNet architecture, which later yields high accuracy.
* Recently published works, for instance, refs. [26; 27; 28; 29; 30; 31] could also be investigated to develop a more robust fruits freshness classification method. Similarly, few of the [32; 33] could also be investigated and optimized to develop a more robust and accurate algorithm that can detect and classify large species of several fruits.