A scalable industrial vision task offloading method and scheduling device based on energy consumption awareness
By using a fine-grained hierarchical energy consumption model and deep reinforcement learning to optimize task offloading decisions, the problem of task offloading methods in the Industrial Internet of Things failing to balance reliability, latency, and energy consumption is solved. This enables flexible adjustment and optimization of system energy consumption, improving equipment endurance and environmental friendliness.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- JIANGSU UNIV OF TECH
- Filing Date
- 2026-03-23
- Publication Date
- 2026-06-26
AI Technical Summary
Existing task offloading methods fail to effectively balance reliability, latency, and energy consumption in the Industrial Internet of Things (IIoT), and lack flexible energy consumption adjustment strategies, resulting in insufficient device battery life and environmental friendliness.
A scalable industrial vision task offloading method based on energy consumption awareness is adopted. By combining a fine-grained hierarchical energy consumption model and configurable weight adjustment with deep reinforcement learning, the task offloading decision is optimized, thereby achieving joint optimization of system energy consumption.
While balancing task reliability and latency, it achieves a flexible trade-off between energy consumption of devices and servers, supports multi-mode energy consumption optimization from prioritizing terminal battery life to global green computing, and improves the long-term average utility of the system.
Smart Images

Figure CN122285111A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of task scheduling and resource management technology, and relates to an energy consumption sensing offloading method and offloading scheduling device for scalable vision tasks. Background Technology
[0002] With the advancement of "Industry 4.0", a large number of visual sensors have been deployed in the Industrial Internet of Things (IIoT) for applications such as fault detection, autonomous driving, and remote control. These applications typically generate large amounts of visual data (images or videos), which require high computing power and have strict requirements on latency and reliability.
[0003] Existing research proposes a task offloading architecture based on scalable video coding (SVC). This architecture utilizes SVC to divide the video stream into a base layer and an enhancement layer, and balances reliability and latency by adjusting the number of offloaded layers.
[0004] However, existing research still has some shortcomings:
[0005] 1. Existing research solutions mostly focus on the trade-off between latency and reliability, often neglecting the battery life issue of industrial field equipment. In industrial IoT scenarios, many terminal devices are battery-powered, and performing excessive computing tasks locally can lead to a significant reduction in battery life;
[0006] 2. In practical applications, users may have different concerns at different times. For example, when a local device's battery is low, users may be more concerned about saving power on that device; while at other times, they may be more concerned about overall energy conservation and environmental protection, and reducing carbon emissions.
[0007] 3. When estimating transmission energy consumption, if the estimation is based solely on instantaneous channel conditions, the actual energy consumption may far exceed expectations due to severe channel fluctuations, leading to task failure or severe power loss of the equipment.
[0008] Therefore, there is an urgent need for a task offloading method that can simultaneously take into account reliability, latency, and energy consumption, and flexibly adjust energy consumption strategies. Summary of the Invention
[0009] This invention aims to address the problems of current task unloading methods, which cannot simultaneously consider reliability, latency, and energy consumption, and cannot flexibly adjust latency and energy consumption.
[0010] A scalable industrial vision task offloading method based on energy consumption awareness, comprising:
[0011] In each scheduling time slot The local node generates a vision task with a total data size of Divide the total data into The layer's scalable data flow; tasks on nodes When executing a task, the scheduling time slot will be... The resulting visual task is at the node The system completes algorithm processing / inference calculations and outputs results in time slots. Selected node The system adopts an equal resource allocation rule to share resources among concurrent tasks, determines the effective uplink transmission rate allocated to tasks based on the nodes, and calculates the total system energy consumption, including transmission energy consumption and computing energy consumption. It performs state transitions and queue updates according to the task progress, and solves the problem using deep reinforcement learning based on MDP.
[0012] The process of state transition and queue update includes: in time slots At the start time, tasks that have been generated and entered the scheduling set up to that time are executed according to the decision's execution node. Add to the corresponding node queue; in the time slot Newly generated tasks during the duration will be temporarily stored and will be available in time slots. The scheduling process begins at the start of the time slot. For tasks currently being served in the queues of each node, the task transmission or computation progress is advanced according to the effective transmission / computing resources allocated in this time slot. If a task completes its current stage at the end of this time slot, its stage status is updated at the time slot boundary, and it participates in the corresponding resource allocation at the start of the next time slot. If the task is completed entirely, it is removed and resources are released; otherwise, the remaining workload is retained to continue service in subsequent time slots. The concurrent task count for each node in the next time slot is updated accordingly. and Queue length and queuing delay estimation for the next time slot By combining the changes in channel state and computing resource state in the next time slot, the next state is obtained. ;in For nodes In the time slot The number of tasks in the transmission phase that share uplink transmission resources. For nodes In the time slot The number of tasks that are in the computation phase and share computing resources;
[0013] The process of solving deep reinforcement learning problems based on MDP includes: abstracting the scheduling system as... ;in: For state space, Indicates scheduling time slot The system status includes task parameters, queue status, channel and computing power status, and energy consumption parameters; For the action space, Indicates time slot The joint scheduling action is selected by the execution location. Selection of Unloading Layers Joint decision, Indicates time slot The number of unloading / processing layers selected in the internal decision-making process; The state transition probability is used to characterize the state transition probability in a given context. Reaching the next state under certain conditions The transfer relationship is jointly determined by task arrival, queue update, channel state change, and computing power occupation / release; The reward function is based on the immediate utility of each scheduling slot. As a reward signal; The discount factor is used; based on MDP, the system observes the current state in each time slot, and the agent selects a scheduling action accordingly. The system then evolves to the next state based on the state transition and queue update mechanism, generating immediate feedback corresponding to the current decision. During the iterative update process based on the reinforcement learning strategy, the overall optimization objective is to maximize the long-term average utility, i.e. ,in, Represents the total number of scheduling slots used to calculate long-run average utility, the th The immediate utility of each scheduling slot , The execution utility function is determined based on total latency, reliability performance, and total system energy consumption; while satisfying the total latency... Delay threshold Under the premise of deep reinforcement learning, learning strategies To maximize long-term average utility.
[0014] Furthermore, total latency Includes the waiting latency of tasks in the queue. Transmission latency of task unloading to compute nodes And the processing latency of tasks on computing nodes. .
[0015] Furthermore, the utility function is as follows:
[0016]
[0017] in, , and These are reliability, delay factor, and energy consumption factor, respectively. ; Indicates the reliability performance of task execution; Total delay; This represents the total energy consumption of the system. This is the baseline value for energy consumption.
[0018] Furthermore, the total energy consumption of the system is as follows:
[0019]
[0020] in, To adjust the parameters; This represents the set of local nodes, the set of edge nodes, and the set of cloud nodes; This represents the energy consumption per computation cycle during local computation. This indicates the actual number of layers received in the unloading data; The total number of layers for scalable data streams; The computing resources required per unit of data; This represents the total data size corresponding to the task. Indicates the device's wireless transmission power. Indicates the current uplink transmission rate; This represents the energy consumption per computation cycle during edge node computation; Indicates the device's wireless transmission power. Indicates the current uplink transmission rate; This indicates the energy consumption per computing cycle during cloud computing.
[0021] Furthermore, the energy consumption benchmark value ,in This represents the unit transmission energy consumption under the worst-case effective channel transmission condition.
[0022] Furthermore, the reliability performance is determined based on the reliability model. Any model that meets the following two conditions can be used as a reliability model:
[0023] 1) The maximum reliability of any computing node for the task should be within the range Inside;
[0024] 2) Reliability performance should vary with the amount of input data. The increase in follows an increasing functional relationship.
[0025] Furthermore, the reliability performance ,in This indicates the reliability performance when all data is transmitted to the compute nodes. ; This indicates the number of layers actually received in the unloading data. .
[0026] Furthermore, the channel and computing power status in the system state includes the total uplink transmission rate of each candidate node in the current time slot. and the available computing speed of each node The available computational speed of the nodes ,in For nodes In the time slot Total available computing speed, For nodes In the time slot The number of tasks that are in the computation phase and share computing resources.
[0027] Furthermore, the energy consumption parameters in the system state include the wireless transmission power sent to each node. and the unit energy consumption of each node Unit energy consumption Depending on the selected execution node type, the corresponding energy consumption model , , .
[0028] A scalable industrial vision task offloading and scheduling device based on energy consumption awareness, the device including a processor and a memory, the memory storing at least one instruction, the at least one instruction being loaded and executed by the processor to implement the scalable industrial vision task offloading method based on energy consumption awareness.
[0029] Beneficial effects:
[0030] This invention targets the execution of vision tasks in the Industrial Internet of Things (IIoT). While balancing task reliability and execution latency, this invention introduces and optimizes a third key dimension—system energy consumption. By establishing a fine-grained hierarchical energy consumption model and a configurable weight adjustment mechanism, it achieves joint optimization and flexible trade-offs in energy consumption between devices and servers. Thus, under a unified scheduling framework, it can flexibly achieve multi-mode energy consumption optimization goals, from prioritizing terminal battery life to global green computing, and can effectively balance reliability, latency, and energy consumption. Attached Figure Description
[0031] Figure 1 A flowchart illustrating the offloading process for scalable industrial vision tasks based on energy consumption awareness;
[0032] Figure 2 The effect of c_c on the average utility of the four strategies for edge nodes. Detailed Implementation
[0033] This invention belongs to the field of task scheduling and resource management technology in industrial IoT and mobile edge computing. Specifically, it relates to an energy consumption awareness offloading method for scalable vision tasks in industrial vision application scenarios (such as fault detection and remote control), and a scheduling system integrating deep reinforcement learning. The purpose of this invention is to introduce a fine-grained energy consumption model and configurable energy consumption weights into a three-layer computing architecture, and to transform the offloading scheduling problem into an MDP problem. It utilizes deep reinforcement learning to learn end-to-end scheduling strategies to maximize long-term average utility while satisfying latency constraints.
[0034] The following detailed description is provided in conjunction with specific implementation methods.
[0035] Specific implementation method one: Combining Figure 1 This implementation method is described below.
[0036] This embodiment provides a scalable industrial vision task offloading method based on energy consumption awareness, including the following:
[0037] S1. Data Stratification:
[0038] Under normal circumstances, tasks can be generated at any time within a time slot, but they are only scheduled and the transmission / computation of tasks begins at the beginning of the time slot.
[0039] In each scheduling time slot The local device generates a vision task with a total data size of (For ease of description, when specific time slots are not emphasized, the total data size corresponding to the task is denoted as...) ;No. The tasks generated by each scheduling slot correspond to ),correspond A layered scalable data stream; "Scalable data stream" here refers to a layered bitstream generated from industrial vision task data (such as video sequences / image sequences) using scalable encoding. It consists of a base layer bitstream and one or more enhancement layer bitstreams. The base layer bitstream contains the core information required to complete minimum usable quality inference / decoding, while the enhancement layer bitstream contains incremental information above the base layer used to improve task quality (such as sharpness, resolution, frame rate, or reconstruction accuracy). The system can record / package and transmit data layer by layer, or set layer identifiers for different layers within a unified bitstream, thereby supporting the selection of the amount of data to be transmitted and processed layer by layer during offloading and computation. Therefore, when deciding to process up to the [layer name missing]... When processing a layer, it indicates that at least the base layer will be processed, and further processing will proceed up to the next layer. The corresponding enhancement layer data. The computational resources required per unit data size are... ( (When the specific time slot is not emphasized, the computing resources required per unit of data are denoted as...) ;No. Each scheduling time slot corresponds to Unit data refers to the amount of data per unit (e.g., ...). The unit is size, not time slot. The unit here is... ).
[0040] It should be noted that: in this embodiment, the scalable encoding corresponding to the scalable data stream can adopt commonly used scalable video / image encoding methods (such as SVC), but in fact, this invention includes, but is not limited to, such scalable encoding.
[0041] Tasks can be executed locally or offloaded to edge / cloud nodes, and only some layers can be offloaded.
[0042] In this invention, local nodes, edge nodes, and cloud nodes capable of performing task computation and processing are collectively referred to as computing nodes (also known as execution nodes); the "node" "All refer to computing nodes, that is..." , This represents the set of local nodes, the set of edge nodes, and the set of cloud nodes.
[0043] S2. Delay Model Construction:
[0044] Schedule time slots The resulting visual task (selected layer data) is at the node The process of completing algorithmic processing / inference calculations and outputting results is called task execution. Node This is the execution location of this task, that is, the computing node. This node may be a local node, an edge node, or a cloud node.
[0045] In this invention, "tasks are on nodes" "Execution" refers to scheduling time slots The resulting visual task (selected layer data) is at the node The algorithm completes processing / inference calculations and outputs the results. The corresponding total end-to-end latency is... Includes the waiting latency of tasks in the queue. Transmission latency of task unloading to compute nodes And the processing latency of tasks on computing nodes. .
[0046]
[0047] in, and These represent the provided transmission capacity (data rate) and computing capacity (computing rate), respectively.
[0048] It should be noted that the transmission and computation of a task are sequential phases. A task does not occupy computational resources until the transmission phase is complete. Once the transmission phase is determined to be complete at the end of a certain time slot, the task enters the computation-ready state and participates in computational resource allocation and advances the computation phase from the start of the next time slot. Therefore, phase switching and resource reallocation only occur at time slot boundaries.
[0049] If the total end-to-end latency of the vision task after transmission, queuing, and computation processing on the selected execution node exceeds a preset latency threshold. If the visual task fails to meet the service standards in this time slot, it will be treated as a failure in the utility / reward function, for example, by setting the utility / reward of this time slot to 0. In simulation / training implementation, this value can be equivalently set to a preset non-positive penalty constant, such as -10, to facilitate training stability adjustment.
[0050] Because when the total latency experienced by the task exceeds the latency threshold If this happens, the task will be considered a failure and a penalty will be triggered, thus ensuring that... And utility function .
[0051] S3. Reliability Model Construction:
[0052] use To represent the reliability performance of task execution:
[0053]
[0054] in, This means when all data ( Reliability performance when all layers are transmitted to the computing node. ;and This indicates the number of layers actually received in the unloading data. .
[0055] The above formula describes the relationship between reliability performance and input data volume. The functional relationship between the two is not fixed. Any model that satisfies the following two conditions can be used as a reliability model: 1) The maximum reliability of any computing node for the task should be within the interval [range]. 1) The reliability performance should increase as the amount of input data increases. The model and analysis process proposed in this invention can be extended to any other reliability model with only minor modifications.
[0056] S4. Resource allocation and determination of effective rate:
[0057] set up For time slots The selected execution location, the system in the time slot Selected node The system employs an equal resource allocation rule to share resources among concurrent tasks and determines the effective rate.
[0058] In the time slot Start time, definition For nodes In the time slot The number of tasks in the transmission phase that share uplink transmission resources; definition For nodes In the time slot Number of tasks in the computation phase and sharing computing resources:
[0059] (1) When Time: Assume the edge side is in the time slot The total uplink transmission rate is (Depending on the channel), the effective uplink transmission rate allocated to this task is:
[0060]
[0061] in This is a set of edge nodes.
[0062] (2) When Time: Assume the cloud is in a time slot The total uplink transmission rate is (Depending on the channel), the effective uplink transmission rate allocated to this task is:
[0063]
[0064] in A collection of nodes in the cloud.
[0065] (3) When At this time: Locally, uplink transmission rate allocation is not involved; the available computing rate for this task is determined only according to the equal distribution rule. Let the node... In the time slot The total available computing speed is The available computing speed allocated to this task is
[0066]
[0067] in This is a set of local nodes.
[0068] S5. Energy Consumption Model Construction:
[0069] Based on local node set Edge node set Cloud node collection Depending on the location of the task execution, the total system energy consumption is divided into two parts: transmission energy consumption and computing energy consumption, and both of them will change accordingly with the change of the task deployment location.
[0070] Comprehensive formula for transmission energy consumption (unit: ):
[0071]
[0072] in Energy consumption per megabit of data transmission (unit: );
[0073] Comprehensive formula for calculating energy consumption (unit: ):
[0074]
[0075] in Energy consumption per calculation cycle (unit: );
[0076] Further subdivision:
[0077] ① When executed locally, transmission power consumption Computational energy consumption :
[0078]
[0079]
[0080] in This represents the energy consumption per computation cycle during local computation (unit: ).
[0081] ② Transmission energy consumption when unloading at the edge :
[0082]
[0083] in Indicates the device's wireless transmission power. Indicates the current uplink transmission rate ( (depending on the channel);
[0084] Calculate energy consumption:
[0085]
[0086] in This represents the energy consumption per computation cycle during edge node computation (unit: ).
[0087] ③ When unloading in the cloud, transmission energy consumption :
[0088]
[0089] in Indicates the device's wireless transmission power. Indicates the current uplink transmission rate ( (depending on the channel);
[0090] Calculate energy consumption:
[0091]
[0092] in This represents the energy consumption per computing cycle during cloud computing (unit: ).
[0093] ④ In summary, total energy consumption :
[0094]
[0095] in, To adjust parameters, as a weighting factor for energy consumption, At this time, only local devices are considered (pure battery life optimization); Pay attention to the energy consumption of the entire system (green computing / environmental protection perspective); In hybrid mode, we are slightly concerned about server power consumption, but we care more about local battery usage.
[0096] S6. Utility Function Design:
[0097] ① Energy consumption benchmark value Setting:
[0098]
[0099] in This represents the unit transmission energy consumption under the worst-case effective channel transmission condition (unit: ).
[0100] ② Define the task execution utility function :
[0101]
[0102]
[0103] in, , and These are reliability, latency coefficient, and energy consumption coefficient, respectively. Here, 1 can be understood as the baseline utility or the basic reward for task completion, ensuring that even... lower and It is relatively high; as long as the task is completed, the utility remains positive, and its value is within an acceptable range.
[0104] S7. State Transition and Queue Update:
[0105] (1) In time slot At the start time, tasks that have been generated and entered the scheduling set up to that time are executed according to the decision's execution node. Add to the corresponding node queue; in the time slot Newly generated tasks during the duration are temporarily stored and will be scheduled at the start of time slot t+1.
[0106] (2) For tasks in service in each node queue, the transmission or computation progress of the task is advanced according to the effective transmission / computation resources allocated in this time slot (determined by the current stage of the task); if the task completes its current stage at the end of this time slot, its stage status is updated at the time slot boundary (e.g., from transmission stage to computation ready), and it participates in the corresponding resource allocation at the beginning of the next time slot; if the task is completed as a whole, the resources are removed and released, otherwise the remaining business volume is reserved to wait for subsequent time slots to continue service.
[0107] (3) Update the number of concurrent tasks for each node in the next time slot accordingly. and Queue length and queuing delay estimation for the next time slot The next state is obtained by combining the channel state of the next time slot with the state of the current computing resources (i.e., the current task attributes). .
[0108] The status of computing resources is monitored by the system, that is, the current task attributes collected by the system. , , , ); in time slots At the beginning, the system collects state variables again and combines them with the queue update results. In this process, the new task enqueueing, the on-service task advancement / removal, etc., are processed according to the steps (1) and (2) of the "state transition and queue update" to obtain the queue-related quantities for the next time slot, for example... Queue length Then proceed to the next time slot. Then, the system collects the channel and computing resource status of that time slot again; based on the obtained information, along with task parameters and energy consumption weights, it forms a complete system. .
[0109] S8. MDP Modeling and Deep Reinforcement Learning Solution:
[0110] Abstract the scheduling system as .in:
[0111] (1) For state space, Indicates scheduling time slot The system status includes at least task attribute parameters ( , , , Queue status (queue length, queuing delay estimation), channel and computing power status (total uplink transmission rate of each candidate node in the current time slot). Available computing speed of each candidate computing node), energy consumption parameters, and weight parameters. , , , )wait;
[0112] It should be noted that the actual total uplink transmission rate is affected by channel quality and available bandwidth. In this embodiment, the channel state is based on the total uplink transmission rate of each candidate node in the current time slot. In practice, the channel quality / available bandwidth of each candidate computing node can also be used as the channel state.
[0113] (2) For the action space, Indicates time slot The joint scheduling action is selected by the execution location. Selection of Unloading Layers Jointly decided, and ,in, Indicates time slot The number of unloading / processing layers selected in the internal decision-making process (to which the intended transmission and processing should be carried out) (data volume of the layer), when This indicates that the task will not unload the enhancement layer at the selected node, but only the base layer.
[0114] (3) The state transition probability is used to characterize the state transition probability in a given context. Reaching the next state under certain conditions The transfer relationship is determined by task arrival, queue update, channel state change, and computing power occupation / release.
[0115] (4) As the reward function, this invention uses the immediate utility of each scheduling slot. As a reward signal;
[0116] (5) Discount factor ( This is used to reflect the level of importance attached to future rewards.
[0117] Based on the aforementioned MDP abstraction, the scheduling system operates in a closed-loop manner within discrete time slots, following the sequence of "state observation—action selection—system evolution—feedback generation": In each time slot, the system observes the current state, the agent selects a scheduling action accordingly, and the system then evolves to the next state based on state transitions and queue updates, generating immediate feedback corresponding to the current decision. This interactive process can form a sample sequence during the training phase, which can be used for iterative updates of subsequent deep reinforcement learning strategies.
[0118] The deep reinforcement learning algorithm is any one of the following: value function-based deep Q-network (DQN), dual DQN, dual DQN, or actor-critic-based PPO / A2C / SAC; wherein it is for discrete action sets. Based on action Cartesian product and using or Output the joint decision. Before executing the policy output, the computing nodes are pre-screened based on latency feasibility and resource lower bound estimation to obtain a candidate node set. and for those who do not meet the requirements Actions are masked to ensure that online decision-making meets latency constraints.
[0119] To balance reliability, latency, and energy consumption during long-term operation, this invention considers the immediate utility of each scheduling time slot. As a reward signal, among For the first The immediate utility of a scheduling slot For system status, This is a joint scheduling action. The overall optimization objective of this invention is to maximize the long-term average utility, wherein, This represents the total number of scheduling slots (or decision steps, runtime slots) used to calculate long-term average utility. This represents the average utility of the system under long-term operating conditions, i.e.
[0120]
[0121] Under the condition of satisfying the time delay constraint Under the premise of deep reinforcement learning strategy This maximizes the long-term average utility. Proceed to the next time slot. Afterwards, the system collects the channel and computing resource status of that time slot again.
[0122] To reduce the size of the joint action space and ensure the feasibility of time delay constraints, this invention first constructs a candidate node set in each time slot. Specifically, for each candidate node Calculate its minimum unloading layer Predicted total latency (e.g., only transporting the base layer) ,like Then the node is removed from the candidate set; where Used to provide a feasible lower bound estimate of the node's delay.
[0123] During the training phase, the agent follows the policy. Interact with the environment, in the first The system state is observed through each scheduling time slot. Choose joint action Receive an instant reward after execution. And proceed to the next state. to form a sample The training module iteratively updates the parameters of the policy network and value network based on interactive samples, gradually increasing the average utility over long-term operation. For the implementation of the discrete joint action space, a DQN-type algorithm based on the value function can be used to learn the action value function. and adopting during the training and exploration process - Randomized policy selection of actions, combined with experience replay and target network to improve training stability; for implementations with multiple discrete actions or large action spaces, Actor-Critic algorithms such as PPO can be used to optimize the policy. Perform direct optimization.
[0124] The following is an example of a decision-making process: The system in each scheduling cycle (time slot) Perform the following steps:
[0125] 1. A local node generates a visual task with a total data size of [data missing]. The required computing capacity per unit of data is This task is encoded using scalable video coding (SVC) as... The layer is an extensible data flow, consisting of a base layer and several enhancement layers.
[0126] 2. The system collects the attributes of the current task ( , , , and network status, specifically including:
[0127] Task attribute parameters: , , , ;
[0128] Task queue length and queuing delay estimation for each computing node ;
[0129] Total uplink transmission rate of each candidate node in the current time slot When candidate execution node At that time, here That is, the edge node in the time slot Total uplink transmission rate When candidate execution node At that time, here That is, the cloud node in the time slot Total uplink transmission rate When candidate execution node In this case, the local system does not involve uplink transmission rate allocation, and this amount can be ignored. The transmission rate can be generated / estimated by the channel model in the simulation, and can be obtained by the communication protocol stack / wireless side measurement and scheduling information in the actual system.
[0130] Available computing speed of each node ;
[0131] Wireless transmission power sent to each node ;
[0132] Unit computational energy consumption of each node In the corresponding energy consumption model , , (Depending on the selected execution node type); These are node-side energy consumption characteristic parameters, which can be obtained through hardware power consumption models or offline calibration / measurement; in simulation, they can be used as known constant inputs.
[0133] Energy consumption as a key factor And weighting coefficients for reliability, latency, and energy consumption. , , .
[0134] Energy consumption concern weight The meaning is:
[0135] when At this time, the optimization target only considers the power consumption of the local device, which corresponds to the pure terminal battery life optimization mode;
[0136] when At the same time, the optimization objective considers the energy consumption of local devices and servers simultaneously but not equally, which corresponds to the hybrid optimization mode;
[0137] when When the optimization objective equally considers the energy consumption of the entire system, it corresponds to the green computing optimization mode.
[0138] 3. Based on the current channel and computing resource status, estimate the total latency that each node may incur when executing tasks. If the estimated latency of a node exceeds a threshold... Then remove it from the candidate node set. Excluded from the list.
[0139] 4. The trained deep reinforcement learning agent, based on the current state... Output Action ,in This indicates the execution node selected for this task. This indicates the number of scalable data layers that this task intends to unload and process. Subsequently, based on the aforementioned "resource allocation and effective rate determination" rules, the system determines the available transmission rate and available computing rate for this task, for use in subsequent latency and energy consumption calculations.
[0140] 5. If the task is executed locally, local resources will be used directly; if the task is offloaded to an edge node or cloud node, the selected layer will be used. Transmit the corresponding data; once the transmission phase is complete, the task enters the computation-ready state and participates in the allocation of computing resources at the beginning of the next time slot before performing computation on that node.
[0141] 6. Record , , And calculate Based on the number of successfully received layers Calculate reliability performance .
[0142] 7. Based on the task execution location and the number of unloading layers, and using a fine-grained layered energy consumption model, calculate the actual total energy consumption. .
[0143] 8. Calculate the immediate reward (utility value) for this task execution using the utility function formula. ).
[0144] 9. In time slots At the end, the environment performs state transitions and updates the queues according to the aforementioned "state transition and queue update" rules to obtain the next state. During the training phase, experience samples are used. The experience is stored in the experience replay buffer; the training module samples the experience and updates the network parameters, so that the average utility of long-term operation gradually increases.
[0145] 10. Proceed to the next scheduling slot and repeat the above steps.
[0146] Example
[0147] To verify the effectiveness of the "Scalable Industrial Vision Task Offloading Method Based on Energy Consumption Awareness" described in this invention under different edge node computing capabilities, a discrete time-slot simulation platform was constructed to simulate and evaluate the scalable task offloading and resource sharing process under a three-layer architecture (local / edge / cloud). The system follows the specifications described herein: tasks can be generated at any time within a time slot, but are only uniformly scheduled and begin transmission / computation at the start of the time slot; newly arriving tasks within a time slot enter the next time slot before participating in scheduling / service. Simultaneously, the total end-to-end task latency consists of three parts: queuing, transmission, and computation, with transmission and computation being serial stages, and stage switching only occurring at time slot boundaries.
[0148] Simulation scene and node settings:
[0149] Consider an industrial vision task generated by a terminal device, which can be executed by the following computing nodes: local nodes, edge nodes, and cloud nodes (collectively referred to as computing nodes). Within each time slot, the nodes adopt an equal resource sharing rule for concurrent tasks: the uplink rate is evenly distributed according to the number of concurrent transmission tasks during the transmission phase, and the computing rate is evenly distributed according to the number of concurrent computing tasks during the computing phase.
[0150] To avoid simulation degradation caused by "unlimited concurrency leading to the effective rate of a single task approaching 0", a node concurrency capacity limit is further introduced in the simulation: when the number of concurrent tasks on a node reaches the limit, the node will no longer accept new tasks in the current time slot, and new tasks must wait in the queue until a subsequent time slot. This waiting time is incorporated into the simulation. Statistics. In this embodiment, the concurrency limit is calculated uniformly based on "number of tasks in the transmission phase + number of tasks in the computation phase" to characterize the actual concurrency constraints brought about by the number of threads, scheduling queues, and computation instances in the engineering system.
[0151] Task and arrival model:
[0152] Each industrial vision task is formed through scalable coding. The layer can expand the data flow; the decision variable is a joint action. ,in To select the execution node, This is to be transmitted and processed up to the [number]th [number]. The number of layers. Task parameters include the total data size. Computing requirements per unit of data .
[0153] In the simulation, the number of arriving tasks in each time slot follows a Poisson distribution (the average arrival rate is per time slot). The arrival times are evenly distributed within the time slots; after a task arrives, it must wait until the next time slot begins to enter the scheduling set. The waiting queue is organized in a first-in, first-out manner; when the waiting queue capacity overflows, the excess tasks are discarded. Each strategy operates under the same random seed until the total number of processed tasks reaches [a certain threshold]. .
[0154] Latency, reliability, energy consumption, and utility calculations:
[0155] End-to-end latency of the task is defined in this specification:
[0156]
[0157] It also satisfies the time slot boundary switching mechanism of "no consumption of computing resources during transmission, and participation in computing resource allocation only starting from the next time slot after transmission is completed." If the latency threshold is exceeded, the task service will fail to meet the standard and a penalty will be triggered in the utility / reward calculation (in the simulation, the utility is counted as 0).
[0158] Regarding the reliability model, the simulation adopts a monotonically increasing layer-proportional reliability form: for nodes... Given full-layer reliability parameters When the number of processing layers is selected as Time to take The full-layer reliability parameters for local, edge, and cloud are set to 0.85, 0.92, and 0.98, respectively.
[0159] The energy consumption model and utility function strictly follow the form given in the instruction manual: Total Energy Consumption It consists of transmission energy consumption and computing energy consumption, and is weighted. Adjust the level of focus on local device energy consumption versus server-side energy consumption. The utility function used is:
[0160]
[0161] in, Normalized energy consumption baseline Calculate according to the instructions.
[0162] To demonstrate the gains of the present invention's "joint selection of execution nodes + joint selection of unloading layers", the following comparison scheme is set up:
[0163] The method of this invention (scalable greedy): In each time slot, first calculate the minimum number of unloading layers. Construct a set of candidate nodes That is, for each candidate node Calculate its in Predicted total delay ,like If the node is not selected, it is removed from the candidate set; then a joint selection is made on the remaining nodes. In order to maximize the estimated utility.
[0164] Baseline 1 (Non-Scalable Optimal Node): Allows selection of execution nodes, but is fixed. This means that scalable layering is not used; only full-layer processing is performed to isolate the benefits of "adjustable layer count." If all nodes have reached their concurrency limits, the task will not be issued and will remain in the waiting queue.
[0165] Baseline 2 (Cloud SVC): The execution node is fixed in the cloud, and only the number of layers can be selected. This is used to isolate the benefits of "node selectability". If, under the current concurrency and waiting latency conditions, the cloud does not meet the latency constraints for any layer, the task will not be sent in this time slot and will remain in the waiting queue.
[0166] Baseline 3 (Local SVC): The execution node is fixed to local, and only the layer can be selected. This is used to isolate the benefits of "node selectability". If, under the current concurrency and waiting latency conditions, the local node does not meet the latency constraints for any layer, then the task will not be sent out in this time slot and will remain in the waiting queue.
[0167] All the above comparison schemes use the same time-slot advancement, equal resource sharing, concurrency limit and failure judgment rules to ensure fairness.
[0168] This embodiment uses the controlled variable method, keeping other parameters constant and only changing the total computation rate of edge node 2. The impact of this study on the long-term average utility of the four strategies was examined. The main parameter settings are shown in Table 1.
[0169] Table 1
[0170]
[0171] Simulation Results and Analysis: Under controlled variable conditions, with the total computing power of the local node and cloud node fixed at 8 and 40 respectively, only the total computing speed of edge node 2 is changed. The values are 5, 10, 15, and 20, respectively. Under the same task arrival process and the same random seed conditions, the proposed method (scalable greedy) and the baseline: non-scalable optimal node ( Baseline: Cloud-based SVC ( , Variable) and baseline: Local SVC ( , The average utility of the four (variable) strategies was compared, and the results are as follows: Figure 2 As shown.
[0172] Depend on Figure 2 It is evident that with the increasing computing power of edge nodes... With the increase of [parameter metric], the average utility of the strategy proposed in this invention continuously improves, rising from approximately 0.60 to 0.69, and consistently achieving the highest value across the four sets of parameters. This indicates that when additional computing resources are added to the edge, the method of this invention can, through joint optimization of "node selection + hierarchical decision-making," promptly allocate more suitable tasks to the edge for processing, thereby effectively reducing latency costs and improving the overall average utility of the system. In contrast, the baseline: non-scalable optimal node ( The average utility of the method also increases with its size, but only from about 0.12 to 0.19, which is a very small increase. Moreover, the overall performance remains the lowest. This indicates that although the method can take advantage of some of the benefits brought by the growth of edge computing power, it is not very adaptable to task differences and resource changes due to the fixed number of layers and insufficient adjustment capabilities.
[0173] As can be seen from the other two baselines, the average utility of the baseline: cloud-based SVC and the baseline: local SVC remains basically unchanged, stabilizing at around 0.50 and 0.42 respectively, hardly changing with... Changes occur because, under these two strategies, the task execution nodes are fixed to either the cloud or local location. Changes in the computing power of edge nodes do not directly alter the task transmission, queuing, and computation processes; therefore, the average utility remains unchanged. Insensitive. In other words, the increase in computing power at edge nodes does not automatically translate into an improvement in system performance. Only when the scheduling strategy can actively select edge nodes and make decisions based on task layering can these additional resources be effectively utilized.
[0174] Further comparison of the differences between the four strategies reveals that, as Furthermore, the performance gap between the "method of this invention" and various baselines continues to widen. Taking "cloud-based SVC" as an example, the average utility difference increases from approximately 0.10 to 0.19; for "local SVC," the difference increases from approximately 0.18 to 0.27; and compared to "non-scalable optimal nodes," the "method of this invention" consistently maintains a significant advantage. This indicates that the method proposed in this invention not only has higher average utility but is also more sensitive to changes in edge resources, enabling it to more fully identify, match, and utilize newly added edge computing resources. In summary... Figure 2 Four strategies in different The bar chart comparison results under the given values show that, with the improvement of edge node computing power, only strategies that simultaneously possess hierarchical adaptive capability and node joint selection capability can achieve more significant performance gains. This also verifies the effectiveness of the joint optimization mechanism proposed in this invention. Specific Implementation Method Two:
[0176] This embodiment is a scalable industrial vision task offloading and scheduling device based on energy consumption perception. The device includes a processor and a memory. It should be understood that it includes any device including a processor and a memory described in this invention. The device may also include other units and modules that perform display, interaction, processing, control and other functions through signals or instructions.
[0177] The memory stores at least one instruction, which is loaded and executed by the processor to implement the energy consumption-aware scalable industrial vision task offloading method.
[0178] Those skilled in the art will understand that at least one stored instruction is a computer program product corresponding to a method or system. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can employ one or more computer-usable storage media containing computer-usable program code. The computer storage medium can include a readable medium on which instructions are stored, and may include, but is not limited to, magnetic storage media, optical storage media; magneto-optical storage media include read-only memory (ROM), random access memory (RAM), erasable programmable memory (e.g., EPROM and EEPROM), and flash memory layers, or other types of media suitable for storing electronic instructions. The solutions in the embodiments of this application can be implemented using various computer languages, such as the object-oriented programming language Java and the interpreted scripting language JavaScript.
[0179] This application is described with reference to flowchart illustrations and / or block diagrams of methods, systems, and computer program products according to embodiments of this application, and can also be used with corresponding devices. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0180] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0181] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0182] Although preferred embodiments of this application have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of this application.
[0183] Obviously, those skilled in the art can make various modifications and variations to this application without departing from the spirit and scope of this application. Therefore, if such modifications and variations fall within the scope of the claims of this application and their equivalents, this application also intends to include such modifications and variations.
[0184] The above examples of the present invention are merely illustrative of the computational model and process of the present invention, and are not intended to limit the implementation of the present invention. Those skilled in the art will recognize that other variations or modifications can be made based on the above description. It is impossible to exhaustively list all possible implementations here. Any obvious variations or modifications derived from the technical solutions of the present invention are still within the scope of protection of the present invention.
Claims
1. A scalable industrial vision task offloading method based on energy consumption perception, characterized in that, include: In each scheduling time slot The local node generates a vision task with a total data size of Divide the total data into The layer's scalable data flow; tasks on nodes When executing a task, the scheduling time slot will be... The resulting visual task is at the node The system completes algorithm processing / inference calculations and outputs results in time slots. Selected node The system adopts an equal resource allocation rule to share resources among concurrent tasks, and determines the effective uplink transmission rate allocated to tasks based on the nodes, and calculates the total system energy consumption, including transmission energy consumption and computing energy consumption. The state transition and queue update are performed according to the progress of the task, and deep reinforcement learning is used to solve the problem based on MDP. The process of state transition and queue update includes: in time slots At the start time, tasks that have been generated and entered the scheduling set up to that time are executed according to the decision's execution node. Add to the corresponding node queue; in the time slot Newly generated tasks during the duration will be temporarily stored and will be available in time slots. The scheduling process begins at the start of the time slot. For tasks currently being served in the queues of each node, the task transmission or computation progress is advanced according to the effective transmission / computing resources allocated in this time slot. If a task completes its current stage at the end of this time slot, its stage status is updated at the time slot boundary, and it participates in the corresponding resource allocation at the start of the next time slot. If the task is completed entirely, it is removed and resources are released; otherwise, the remaining workload is retained to continue service in subsequent time slots. The concurrent task count for each node in the next time slot is updated accordingly. and Queue length and queuing delay estimation for the next time slot By combining the changes in channel state and computing resource state in the next time slot, the next state is obtained. ;in For nodes In the time slot The number of tasks in the transmission phase that share uplink transmission resources. For nodes In the time slot The number of tasks that are in the computation phase and share computing resources; The process of solving deep reinforcement learning problems based on MDP includes: abstracting the scheduling system as... ;in: For state space, Indicates scheduling time slot The system status includes task parameters, queue status, channel and computing power status, and energy consumption parameters; For the action space, Indicates time slot The joint scheduling action is selected by the execution location. Selection of Unloading Layers Joint decision, Indicates time slot The number of unloading / processing layers selected in the internal decision-making process; The state transition probability is used to characterize the state transition probability in a given context. Reaching the next state under certain conditions The transfer relationship is jointly determined by task arrival, queue update, channel state change, and computing power occupation / release; The reward function is based on the immediate utility of each scheduling slot. As a reward signal; The discount factor is used; based on MDP, the system observes the current state in each time slot, and the agent selects a scheduling action accordingly. The system then evolves to the next state based on the state transition and queue update mechanism, generating immediate feedback corresponding to the current decision. During the iterative update process based on the reinforcement learning strategy, the overall optimization objective is to maximize the long-term average utility, i.e. ,in, Represents the total number of scheduling slots used to calculate long-run average utility, the th The immediate utility of each scheduling slot , The execution utility function is determined based on total latency, reliability performance, and total system energy consumption; while satisfying the total latency... Delay threshold Under the premise of deep reinforcement learning, learning strategies To maximize long-term average utility.
2. The scalable industrial vision task offloading method based on energy consumption awareness according to claim 1, characterized in that, Total latency Includes the waiting latency of tasks in the queue. Transmission latency of task unloading to compute nodes And the processing latency of tasks on computing nodes. .
3. The scalable industrial vision task offloading method based on energy consumption awareness according to claim 2, characterized in that, The utility function is as follows: in, , and These are reliability, delay factor, and energy consumption factor, respectively. ; Indicates the reliability performance of task execution; Total delay; This represents the total energy consumption of the system. This is the baseline value for energy consumption.
4. The scalable industrial vision task offloading method based on energy consumption awareness according to claim 3, characterized in that, The total energy consumption of the system is as follows: in, To adjust the parameters; This represents the set of local nodes, the set of edge nodes, and the set of cloud nodes; This represents the energy consumption per computation cycle during local computation. This indicates the actual number of layers received in the unloading data; The total number of layers for scalable data streams; The computing resources required per unit of data; This represents the total data size corresponding to the task. Indicates the device's wireless transmission power. Indicates the current uplink transmission rate; This represents the energy consumption per computation cycle during edge node computation; Indicates the device's wireless transmission power. Indicates the current uplink transmission rate; This indicates the energy consumption per computing cycle during cloud computing.
5. The scalable industrial vision task offloading method based on energy consumption awareness according to claim 4, characterized in that, The energy consumption benchmark value ,in This represents the unit transmission energy consumption under the worst-case effective channel transmission condition.
6. The scalable industrial vision task offloading method based on energy consumption awareness according to claim 3, characterized in that, The reliability performance is determined based on the reliability model. Any model that meets the following two conditions can be used as a reliability model: 1) The maximum reliability of any computing node for the task should be within the range Inside; 2) Reliability performance should vary with the amount of input data. The increase in follows an increasing functional relationship.
7. The scalable industrial vision task offloading method based on energy consumption awareness according to claim 6, characterized in that, The reliability performance ,in This indicates the reliability performance when all data is transmitted to the compute nodes. ; This indicates the number of layers actually received in the unloading data. .
8. The scalable industrial vision task offloading method based on energy consumption awareness according to claim 1, characterized in that, The channel and computing power status in the system state includes the total uplink transmission rate of each candidate node in the current time slot. and the available computing speed of each node The available computational speed of the nodes ,in For nodes In the time slot Total available computing speed, For nodes In the time slot The number of tasks that are in the computation phase and share computing resources.
9. The scalable industrial vision task offloading method based on energy consumption awareness according to claim 1, characterized in that, The energy consumption parameters in the system state include the wireless transmission power sent to each node. and the unit energy consumption of each node Unit energy consumption Depending on the selected execution node type, the corresponding energy consumption model , , .
10. A scalable industrial vision task offloading and scheduling device based on energy consumption sensing, characterized in that, The device includes a processor and a memory, the memory storing at least one instruction, which is loaded and executed by the processor to implement the scalable industrial vision task offloading method based on energy consumption awareness as described in any one of claims 1 to 9.