# Deep Learning Entrusted to Fog Nodes (DLEFN) Based Smart Agriculture
## 5 Performance Evaluation
### Results and Discussion  
Figure 9 shows the number of DL applications accepted in the methods mentioned in the previous section. The method supported by cloud only recorded the lowest number of allowed applications, due to insufficient bandwidth caused by the huge volumes of original data. Since this method processed original data without support by fog nodes, the comparison was unfair. Nevertheless, this result shows the necessity of fog computing in modern IoT environments that generate colossal volumes of data. The method of defining fixed layers for all tasks steadily allowed up to 160 applications. However, it could not accommodate any further applications. Despite being a simple algorithm that supports all tasks equally, this method allowed many more applications than processing the applications on the cloud only. In the offline method, all application tasks are arranged in ascending order of incoming average data size before implementing the algorithm. For that reason, the offline method steadily allowed up to around 250. The online algorithm utilizes historic data recorded by executing the offline algorithm in a real-time environment. Although the online algorithm recorded fewer allowed applications than the offline algorithm, the result was relatively higher than the methods supported by cloud only or by fixed layers. In contrast, the proposed DLEFN continuously accommodated applications despite the exhausted resources on all fog nodes, by first considering maximum resource utilization within fog nodes and comparing new applications and allowed applications to decide replacements for better efficiency. At the end, the DLEFN allowed highest number of applications requiring DL.  
Figure 10 shows the change of average available bandwidth and computational capacity of all fog nodes as each method decided whether to accommodate DL applications. As Figure 10a indicates, the final residual bandwidth on the network was significantly different for each algorithm. Nonetheless, the overall resources of all fog nodes were virtually exhausted by the proposed DLEFN, as shown in Figure 10b. In actuality, the proposed method was designed to utilize maximum resources at each fog node, although each node had different available resources. Consequently, fog nodes dealt with the optimal DL layer according to their available resources and tried to reduce the number of intermediate results. Therefore, the DLEFN gave a chance to more applications requiring DL service within given resources, as shown in Figures 9 and 10, since the proposed algorithm saved more available bandwidths than other methods even after allowing the largest number of applications. Accordingly, we can claim that the proposed method successfully minimized intermediate results being delivered to the cloud in an FC-based smart agriculture environment. As a result, decreased network congestion and computational loads on the cloud ensured better QoS.  
Figure 9: Number of allowed DL applications in fog computing (FC) environment.  
Figure 11 shows the average load caused by DL applications in the cloud after each method allowed all possible applications. Since more DL layers were handled at the fog nodes, computational loads per DL application were lowest in the proposed method. Figure 12 shows the influence of the number of allowed DL applications by number of fog nodes. Since an increase of fog nodes means an increase of available resources, the number of allowed applications was proportionally increased according to increasing number of fog nodes in all methods. The proposed method allowed DL service for the largest number of DL applications, regardless of the number of fog nodes.  
Figure 11: The average of load per application in the cloud server.  
Figure 12: Number of allowed DL applications by number of fog nodes.