摘要
Purpose-The intelligence in the Internet of Things(IoT)can be embedded by analyzing the huge volumes of data generated by it in an ultralow latency environment.The computational latency incurred by the cloud-only solution can be significantly brought down by the fog computing layer,which offers a computing infrastructure to minimize the latency in service delivery and execution.For this purpose,a task scheduling policy based on reinforcement learning(RL)is developed that can achieve the optimal resource utilization as well as minimum time to execute tasks and significantly reduce the communication costs during distributed execution.Design/methodology/approach-To realize this,the authors proposed a two-level neural network(NN)-based task scheduling system,where the first-level NN(feed-forward neural network/convolutional neural network[FFNN/CNN])determines whether the data stream could be analyzed(executed)in the resourceconstrained environment(edge/fog)or be directly forwarded to the cloud.The second-level NN(RL module)schedules all the tasks sent by level 1 NN to fog layer,among the available fog devices.This real-time task assignment policy is used to minimize the total computational latency(makespan)as well as communication costs.Findings-Experimental results indicated that the RL technique works better than the computationally infeasible greedy approach for task scheduling and the combination of RL and task clustering algorithm reduces the communication costs significantly.Originality/value-The proposed algorithm fundamentally solves the problem of task scheduling in realtime fog-based IoT with best resource utilization,minimum makespan and minimum communication cost between the tasks.