A Comparative Study of Various Machine Learning Algorithms in Fog Computing
A Comparative Study of Various Machine Learning Algorithms in Fog Computing
2611
Urooj Yousuf Khan et al., International Journal of Advanced Trends in Computer Science and Engineering, 10(3), May - June 2021, 2611– 2622
is a proposed system for detecting anomalies in the system Table 2: Differences between Cloud and Fog [20]
using Machine learning. This model also deploys Random Feature Description
Forest technique for anomaly detection. The paper also Heterogeneity Located at the edge of the network with
suggests enhancements such as deploying Conventional rich, heterogenous end-user support
Neural Networks (CNN) to control traffic activities in the Capability Supports a wide range of industrial
city. This effective algorithm gains the highest classification applications deo to instant response
accuracy of 99.34% with lowest false positive rate[14]. capability
Another interesting case study for deploying machine Storage and Has its own computing, storage and
learning algorithms is found in BEMS [15]. In this paper, the Services networking services
authors propose a self-learning algorithm using Neural Operation Areas Operates locally single hop from a device
Networks. The smart buildings automatically control the to a fog node)
temperature, air quality and the humidity within the Platform Has a highly virtualized platform
premises. Deploying an effective machine learning
algorithm such as Neural Network has enabled examination Additional Portable deployment in terms of hardware
and higher accuracy rate.it has also led to reduced energy Features and software
consumption and increase of comfort level for the residents
[15]. Table 3: Computational aspects for Cloud and Fog[20]
An application of task offloading in Fog Networks using Aspects Fog Computing vs Cloud Computing
classification and regression tree algorithm is also found in Resources Relatively fewer computing resources in
literature[16]. This study suggests that usage of classification Fog
algorithm has reduced power consumption of CPU, RAM Capability Both can process data generated from a
and Wi-Fi by 44%,71% and 55% respectively[16] . Usage of diverse set of resources
machine learning in vehicular computing and connected Distribution Based on geographical location, both
vehicles is another significant paradigm [17]. The effective Strategies can distribute data densely or sparsely
usage of machine learning methods aims at improving the Connectivity Both support machine-to-machine
mobility and connectivity. The loss of connectivity when communication and wireless
transitioning from one fog node to the other can be connectivity
minimized using recurrent neural networks (RNN)[17] . The Flexibility Fog can be installed on low
selection of optimal node and its effective cost were specification devices such as switches
calculated given the time and location. This optimal node and Internet protocol cameras
minimized the handover cost associated with loss of Usability One of the primary uses is currently for
connectivity [17]. It is expected that more than 9 billion mobile and portable devices
people will live on the planet by 2050 and about two thirds of
them will live in cities [18]. An important implementation of Table 3 above provides a clear picture for different
the Fog computing lies in Smart cities. Fog computing computational aspects of Cloud and Fog. There is a separate
enables huge data generated by the nodes to be processed paradigm for Fog devices. These Fog devices can be further
locally. Incorporating machine intelligence in the system classified as mission-critical, real-time, interactive,
comes with challenges such as the capability to handle such conversational, streaming, CPU-bound and Best effort[21].
diverse data resources and physical constraints imposed by Each class clearly specifies the significance of Fog
device limitations [19]. computing in its own terms[21].
Table 4 below signifies the architectural differences between
2.3 Fog Architecture Cloud and Fog.
The precise location and platform selection of the Fog nodes Table 4: Differences between Fog and Cloud [5]
depend on the application scenario and required number of Features Cloud Fog Computing
hosts. There are key differences between Cloud and Fog. The Computing
major difference lies in utilization of resources. Fog is a Architecture Centralized Decentralized
resource-constrained environment with stringent time Access Fixed and Wireless Mainly Wireless
requirement. Cloud, on the other hand, virtually has Latency High Very Low
unlimited storage and processing capability. Moreover, Mobility Limited Support Supported
peer-to-peer communication is much faster in Cloud due to Operation Operated by large Often operated by
high-speed connectivity. It does not happen in Fog where the companies small companies
networks vary quickly and communication is majorly Server Nodes Few Very Large
wireless. Vertical communication, however, takes another Number
form. In Cloud, this communication is slower while Server nodes The Internet The local network
accessing remote devices. Cloud computing is a stable, location
market-oriented paradigm while Fog is still an emerging Size Very large data Large number of
concept [1]. centers small fog nodes
Table 2 below identifies the key differences between Cloud Scalability Average High
and Fog. Vulnerability High probability Very low probability
2613
Urooj Yousuf Khan et al., International Journal of Advanced Trends in Computer Science and Engineering, 10(3), May - June 2021, 2611– 2622
Figure 1 below shows the Fog architecture and its different Figure 2 further explains Cloud-to-Fog continuum. The Fog
classes. Evident from the figure is the placement and nodes, placed in user proximity provide continuity along the
application of the Fog nodes. The end devices could be any Things-to-Cloud. Optimal placement of nodes in the Fog
user-defined input scheme. The Fog layers 1 and 2 provide the network also promotes job scheduling and deploys digital
layered implementation for varied types of requirements. resources at the Edge of the network. It provides a local pool
of resources for immediate and optimal utilization[24].
Figure 3 below clearly depicts the placement of Fog Nodes
and their functionality. A typical Fog network is identified
by a large number of heterogeneous nodes, placed in close
proximity to the user or test case. These nodes vary largely
from each other in terms of data streams, protocols and
networking capabilities. These may include PCs, routers,
switches, proxy servers, mobile devices or source inhibited
System on Chip (SoC). These heterogeneous nodes
communicate with each other via Ethernet or Wi-Fi based
networks. These are resource stringent nodes that provide
more options for wireless communications. In other words,
the great diversity among nodes requires flexible and elastic
framework, with real time response. All thesefeatures are
intrinsic to Fog. Thus, Fog is becoming a pivotal point in
future networks [25].
and different physical objects interact and communicate with are capable to represent complex relationships among the
each other using a common communication platform. elements of the input set [2]. Another variation of the ANN is
Initially the concept was to utilize the IPV4 addressing. in multilayer perceptron (MLP) that deploys nonparametric
However, later it was upgraded to IPV6, thereby making it estimator. Convolutional Neural Networks (CNN) works on
possible for every device in the planet to be uniquely the principal of translational invariance. It implies that the
identifiable[2]. value of the output function is unchanged as the input function
The scope of Fog is not only limited to resolving the translates. In other words, if the input translates, the CNN will
bottlenecks faced by Cloud. This paradigm extends far still be able to detect which class the input belongs. CNN
beyond that. It can form core component in emerging IoT, majorly comprises of two parts: feature extractor and a
embedded AI and 5G among many others. A considerable trainable classifier such as SVM. The feature extractor reads
advantage of Fog Computing also lies in the fact that it and extracts the features and characteristics from the raw data.
possesses pool of resources that can be utilized as per the It comprises of multiple similar stages and layers.
user requirements. Moreover, being near to the end users Classification is performed by the second part: classifier.
promotes greater cognition and swift data analysis. All these Another popular class of ANN is Recurrent Neural Networks
features enhance efficiency. Additionally, bandwidth (RNN). These neural networks have additionally employed
conservation is ensured, as data does not travel to a central the quality of recurrence due to which they are especially
node or server[3] . important in data analytics and streaming. Deep neural
On a detailed note, the Fog architecture is denser and more networks take a step ahead. They utilize stacks of multi-layer
versatile compared to Cloud. Fog computing embeds IoT neurons to efficiently represent complex relationships among
and business insights gathered from nodes in real-time. It data elements [2]. Swift, parallel and distributed computations
provides distributed and embedded intelligence. This results are key features of Neural Networks [22].
in scalability and heterogeneity in Fog[10]. Fog servers are Figure 4 below captures the neural networks briefly.
dense collection of sensors and are geographically located at
closest proximity to the users. These features enhance lower
latency, higher mobility and lower deployment cost.
2615
Urooj Yousuf Khan et al., International Journal of Advanced Trends in Computer Science and Engineering, 10(3), May - June 2021, 2611– 2622
The input from the edge devices moves to the data centers for 3.4 Optimization
immediate storage and capturing. The core of data analysis
relies heavily on Machine learning and its numerous Enabling intelligence in nodes can be beneficial in reducing
algorithms. To embed thinking into a machine points to the design complexity of a given scenario. Optimal Resource
traditional and modern approaches of machine learning. utilization prevents conflicts. It provides an acceptable
These may include brute force and greedy K-nearest tradeoff between accuracy and time complexity [12],[28].
neighbor, neural networks, support vector machines or
nature-inspired genetic algorithms. Moreover, advanced 4. APPLICATIONS OF M ACHINE LEARNING ALGORITHMS IN
hardware such as GPU or embedded platforms can locally FOG COMPUTING
perform data-analytics. Cloud is then specialized for specific
tasks such as data training for huge datasets[20]. Few major areas where highest impact is expected are as
follows:
Advantages: 4.1 Health
A considerable point here to understand many potential
benefits that come along this architecture. Efficient energy The impact of machine learning and fog computing is huge
consumption is one such benefit. Fog devices are in the health sector. Various applications are being proposed
resource-constrained and applications such as image and in this regard. One such application is IoTPulse. This project
voice processing are energy intensive. Catering the predicts the probability of a person being a drug addict. It
requirements of these devices over the edge of the network utilizes machine-learning algorithms deployed in Fog
could mean task offloading, thereby conserving the precious Networks [22].
bandwidth. Scheduling job sequence in this scenario is still a Another study revolves around the detection of a cardiac
challenge. arrest using the wearable sensors[4]. The introduction of an
Notable advantages are given below[28]: efficient machine learning algorithm namely ROC analysis
has helped in identifying most significant clinical parameters
3.1 Reduced Latency to get cardiac arrest [4].
Introducing Fog devices concludes that traffic on the 4.2 Smart Grid
network would be entertained locally. Some IoT devices
such as real-time health monitoring system are time and An application of Fog computing and machine learning lies
resource intensive. If these Fog nodes are embedded with in smart grids and energy management. A grid is an
intelligent decision-making systems the capability of the arrangement of various networks ranging from micro grids to
system and performance could increase many folds[28]. international levels. Its applications include power
generation and distribution systems, control systems for
3.2 Bandwidth Conservation balancing and energy production. Due to highly dynamic and
volatile nature of this application, an efficient fault tolerant
With localized preprocessing and storage of data near the mechanism is also needed. The inclusion of self-learning in
edge of the network, huge volume of data can be addressed this arrangement would enhance the error-detection and
locally. This essentially frees up the constrained bandwidth correction capabilities of the system[2].
since the amount of user data has increased exponentially
over the years. Smart machine learning algorithms can 4.3 Security
provide the much-needed solution[28].
Offloading the computational tasks adds another strength to The Cloud services come with the issues of latency and
the Network. It provides means for preserving the battery life connectivity. Moreover, due to performance requirements,
in pervasive devices. Specific machine learning algorithm the real-time implementation of effective security policy is
namely Neuro-fuzzy logic using Neural networks are highly difficult to achieve. In this perspective, the Fog devices can
applicable in this perspective[5]. play a major role in offloading the traffic, conserving
bandwidth and enforcing security. The Fog architecture,
3.3 Improved Network Availability boasting horizontal connectivity has dual effects: it reduces
storage space and latency issues. Fog nodes are efficient at
Whenever a device moves from one region to another in Fog handling widespread and massive information. The detection
or Cloud environment, it experiences disruption and of attacks can be further controlled using the Machine
connectivity glitch. Intelligent machine learning algorithms learning algorithms. Moreover, the highly parallel nature of
should enable self-organization and co-operation to ensure the Fog eases the mathematical modelling and
smooth and uninterrupted services. calculations[3],[13].
Security and Privacy: Self-organizing and learning also
provides robust protection against malicious attacks. It is 4.4 Data Aggregation
because network is able to identify and analyze data locally
before propagating it to the network. The synthesis, analysis and study of data aggregation
produced an array of innovative benefits. But the issues
related to data piracy and privacy associated with sensitive,
2617
Urooj Yousuf Khan et al., International Journal of Advanced Trends in Computer Science and Engineering, 10(3), May - June 2021, 2611– 2622
unhandled user data is a key concern[6].Intrusion Detection operations[27].The tables 5-11 below signify the application
systems using Fog nodes are widely under development and of each machine learning algorithm.
research. Intrusion detection systems form the keystone of
security systems. The resource constrained features of the Table 5: Random Forest[2]
Fog require specialized machine learning algorithms[7].
Domain Functional Category Task
4.5 CPU Job Scheduling
Smart Grid Forecasting/Prediction/Regre demand side
Efficient scheduling of the jobs that need to be catered by the
ssion load
Fog environment is a research question. An experiment
forecasting/Pri
conducted showed that machine learning algorithms enhance
ce forecasting
CPU scheduling problem. This is an ideal requirement in the
Anomaly/Fault Detection Power record
Fog networks. It enhances the operational capacity of the
faults
network and upgrades its performance. A significant
algorithm here is Bee swarm algorithm that captures the Transport Pattern Behavior/Even
essence of Bees life. This particular algorithm finds the Recognition/Clustering t Recognition
optimal tradeoff between CPU execution time and allocated Manufacturing Anomaly/Fault Detection Tooling wear/
memory. An enhanced version of this algorithm can be Errors
utilized in network optimization [5]. detection
.
4.6 Smart Cities
Table 6:ANN[2]
Smart city is also termed as “sustainable city” or
self-dependent city. It implies a real-world scenario of Smart Grid Forecasting/Prediction/ Electrical Power
enabling a city to be smart enough to identify its own needs. Regression prediction, load
Geo-distribution is a major characteristic for the big data forecasting
generated by smart cities. This huge data can only be handled Transport Pattern Recognition/ Behavior/Event
using a massive collection of nodes such as in Fog. The data Clustering Recognition
analysis for such varied and diverse data can be achieved Forecasting/Prediction/ traffic flow features
affectively by using an effective machine learning Regression road side CO and
algorithm[18]. NO2
concentrations
4.7 Connected Vehicles estimation
travel time prediction
Fog computing along with machine learning is also Classification obstacle detection and
incorporated in the smart vehicles. Efficient and effective recognition
machine learning algorithms to minimize handover Image Processing
optimization is possible [17]. Vehicular Fog simulator and Manufacturing Forecasting/Prediction/ Energy Consumption/
Recurrent neural network can be used to minimize the Regression/ Process
latency and handover delay [17]. optimization parameters
optimization
4.8 Network Connectivity and Detection
2618
Urooj Yousuf Khan et al., International Journal of Advanced Trends in Computer Science and Engineering, 10(3), May - June 2021, 2611– 2622
2620
Urooj Yousuf Khan et al., International Journal of Advanced Trends in Computer Science and Engineering, 10(3), May - June 2021, 2611– 2622
"In-network Self-Learning Algorithms for BEMS Amani Al-Ghraibah et al., International Journal of
Through a Collaborative Fog Platform," in IEEE 32nd Advanced Trends in Computer Science and Engineering,
International Conference on Advanced Information vol. 10, no. 3, pp. 1494-1500, 12 6 2021.
Networking and Applications (AINA),, Krakow, 2018. 27. T. . E. Bogale, X. Wang and L. B. Le, "Machine
16. . D. Rahbari and . M. Nickray, "Task offloading in Intelligence Techniques for Next-Generation
mobile fog computing by classification and regression Context-Aware Wireless Networks," ITU Special Issue
tree.," Peer-to-Peer Networking and Applications, vol. N.1 The impact of Artificial Intelligence (AI) on
13, p. 104–122, 2019. communication networks and services, 12 Jan 2018.
17. S. Memon and M. Maheswaran, "Using machine 28. Q. . D. La, M. V. Ngo, T. Q. Dinh, T. Q.S. Quek and H.
learning for handover optimization in vehicular fog Shin, "Enabling intelligence in fog computing to
computing," in Proceedings of the 34th ACM/SIGAPP achieve energy and latency reduction," Digital
Symposium on Applied Computing, Limassol Cyprus, Communications and Networks, Vols. Volume 5, Issue 1,
April 2019. no. Volume 5, Issue 1, pp. 3-9, 2019.
18. B. Tang , Z. Chen, G. Hefferman, P. Shuyi , T. Wei, H. He 29. S. Zhou, . S. Y, Z. Jiang and Z. Niu, ""Exploiting Moving
and Q. Yang, "Incorporating Intelligence in Fog Intelligence: Delay-Optimized Computation
Computing for Big Data Analysis in Smart Cities," Offloading in Vehicular Fog Networks," IEEE
IEEE Transactions on Industrial Informatics, Vols. vol. Communications Magazine, Vols. vol. 57, no. 5, no. vol.
13, no. 5, no. vol. 13, no. 5, pp. pp. 2140-2150, Oct. 2017. 57, no. 5, pp. pp. 49-55, May 2019.
19. Y. Tu, Y. Ruan, S. Wagle, C. G. Brinton and C. 30. N. C. Luong, Y. Jiao, P. Wang, D. Niyato, D. I. Kim and
Joe-Wong, "Network-Aware Optimization of Z. Han, "A Machine-Learning-Based Auction for
Distributed Learning for Fog Computing," in IEEE Resource Trading in Fog Computing," IEEE
INFOCOM 2020 - IEEE Conference on Computer Communications Magazine, Vols. vol. 58, no. 3, no. vol.
Communications, Toronto, ON, Canada, 2020. 58, no. 3, pp. pp. 82-88, March 2020.
20. K. H. Abdulkareem, . M. . A. Mohammed, S. 31. George-Eduard Zaharia, T.-A.-I. Şoşea, R.-I. Ciobanu and
Gunasekaran, A. Mutlag, . A. M. Salama and N. Salih Ali, C. Dobre, "Machine learning-Based traffic offloading
""A Review of Fog Computing and Machine Learning: in fog networks," Simulation Modelling Practice and
Concepts, Applications, Challenges, and Open Theory,, vol. Volume 101, 2020,.
Issues,," IEEE Access, vol. vol. 7, no. vol. 7, pp. pp. 32. W. Shafik, , . s. M. Matinkhah and S. Mamman,
153123-153140, 2019. "Network Resource Management Drives Machine
21. J. C. Guevara, R. . d. S. Torres and N. L. d. Fonseca, "On Learning: A Survey and Future Research Direction,"
the classification of fog computing applications: A Journal of Communications Technology, Electronics and
machine learning perspective," Journal of Network and Computer Science, vol. Issue 30, no. Issue 30, 2020.
Computer Applications, vol. Volume 159, no. Volume 33 A. S. M. Kayes, R. Kalaria, I. H. S. Sarker, I. H. Sarker,
159, pp. 1-10, 2020. M. S. Islam and P. A. Watters, "A Survey of
22. A. Dhillon, A. Singh, H. Vohra, C. Ellis, B. Varghese and Context-Aware Access Control Mechanisms for Cloud
S. Gil, "IoTPulse: machine learning-based enterprise and Fog Networks: Taxonomy and Open Research
health information system to predict alcohol addiction Issues," Sensors, vol. vol. 20, no. 9, p. 2464, Apr. 2020.
in Punjab (India) using IoT and fog computing," 34. J. Baek, G. Kaddoum, S. Garg, K. Kaur and V. Gravel,
Enterprise Information Systems, pp. 1-34, 21 Sep 2020. "Managing Fog Networks using Reinforcement
23. E. Balevi, and . R. Gitlin, "Unsupervised machine Learning Based Load Balancing Algorithm," in 2019
learning in 5G networks for low latency IEEE Wireless Communications and Networking
communications," in 2017 IEEE 36th International Conference (WCNC), Marrakesh, Morocco, 2019.
Performance Computing and Communications 35. RIYA, . G. NITIN and Q. XIN, Data Caching at Fog
Conference (IPCCC), University of South Florida, 2017. Nodes Under IoTNetworks: Review of Machine
24. A. MelloukImag, S. Batim and S. Zeadally, "Fog Learning, techrxiv.org, 2020.
computing job scheduling optimization based on bees 36. J. Moura and D. Hutchison, "Fog Computing Systems:
swarm," Enterprise Information Systems, Vols. Volume State of the Art, Research Issues and Future Trends,"
12, 2018, no. Volume 12, 2018, 10 Apr 2017. Journal of Network and Computer Applications, vol.
25. A. Abeshu and N. Chilamkurti, "Deep Learning: The Volume 169, no. Volume 169, 2020.
Frontier for Distributed Attack Detection in 37. R. Z. Naeem, S. Bashir, M. . F. Amjad, H. Abbas and H.
Fog-to-Things Computing," IEEE Communications Afzal , "Fog computing in internet of things:Practical
Magazine, Vols. vol. 56, no. 2, no. vol. 56, no. 2, pp. pp. applications and future directions," Peer-to-Peer
169-175, Feb. 2018. Networking and Applications, vol. 12, no. 12, p.
26. A. Al-Ghraibah, M. Algharibeh, W. AlMohtasib and M. 1236–1262, 13 September 2019.
Altayeb, "Classification of Long Bone X-ray Images 38. M. Ghobaei-Arani, A. Souri, F. Safara and N. Monire ,
using New features and Support Vector Machine," "An efficient task scheduling approach using
2621
Urooj Yousuf Khan et al., International Journal of Advanced Trends in Computer Science and Engineering, 10(3), May - June 2021, 2611– 2622
2622