Cloud edge collaborative task allocation method and device based on task difficulty analysis, terminal equipment and storage medium
By calculating the complexity of tasks and combining the computing capabilities of terminals and cloud servers, task allocation is dynamically adjusted, and the problem of not being able to effectively perceive task difficulty in the existing technology is solved, and more efficient cloud-edge collaborative task allocation is achieved.
Patent Information
- Application Number
- CN202510552983.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-29
- Publication Date
- 2025-07-08
AI Technical Summary
The existing technology cannot effectively perceive the task difficulty, resulting in low practicality of cloud-edge collaborative task allocation results.
By obtaining the calculation amount, data amount and real-time requirements of the task, calculate the complexity of the task, and based on the terminal's computing capabilities, determine whether the task should be processed independently by the terminal or collaboratively by other terminals in the cloud server or other terminals in the local area network.
It improves the practicality of cloud-edge collaborative task allocation, complies with the task's calculation quantity, data quantity and real-time requirements, and realizes the optimal utilization of computing resources.
Smart Images

Figure CN120281769A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of load scheduling, and particularly to a cloud-edge collaborative task allocation method, device, terminal device and storage medium based on task difficulty analysis. Background Art
[0002] In the current cloud-edge coordination intelligent system, common task processing technical means mainly include task allocation and resource scheduling. In terms of task allocation, simple strategies such as based on task priority, resource load, etc. are usually adopted. However, in the face of different tasks in the prior art, due to the inability to effectively perceive the task difficulty and consider the task difficulty for computing resource allocation, it is easy to lead to low practicality of the cloud-edge collaborative task allocation result. Summary of the Invention
[0003] The present invention provides a cloud-edge collaborative task allocation method, device, terminal device and storage medium based on task difficulty analysis, which can solve the problem of low practicality of the cloud-edge collaborative task allocation result caused by the inability to effectively perceive the task difficulty in the prior art.
[0004] An embodiment of the present invention provides a cloud-edge collaborative task allocation method based on task difficulty analysis, including:
[0005] Obtaining the computing volume index of all tasks to be allocated, the data volume index of all tasks to be allocated, the real-time requirement index of all tasks to be allocated, the average computing volume index of historical tasks, the average data volume index of historical tasks and the average real-time requirement index of historical tasks; wherein, the real-time requirement index is used to measure the level of real-time requirements of tasks;
[0006] For each task to be allocated, according to the computing volume index of the task to be allocated, the data volume index of the task to be allocated, the real-time requirement index of the task to be allocated, the average computing volume index, the average data volume index and the average real-time requirement index, through the task complexity calculation formula, calculate the task complexity of the task to be allocated; wherein, the task complexity is in a direct proportional relationship with the computing volume index, the data volume index and the real-time requirement index;
[0007] Obtaining the terminal computing power index of the terminal where the task to be allocated is currently located; wherein, the terminal computing power index is used to measure the level of terminal computing power;
[0008] Judging whether the task complexity exceeds the terminal computing power index, if so, allocating the part of the task to be allocated that exceeds the terminal computing power index to a cloud server or other terminals in the local area network, if not, independently processing by the terminal where the task to be allocated is located.
[0009] Further, the task complexity calculation formula is:
[0010] C task,i = α i ·K i + β i ·V i + γ i ·T i ;
[0011]
[0012] In the formula, C task,i represents the task complexity of the i-th task to be assigned; K i represents the computational workload index of the i-th task to be assigned; V i represents the data volume index of the i-th task to be assigned; T i represents the real-time requirement index of the i-th task to be assigned; α i represents the influence coefficient of the computational workload index of the i-th task to be assigned; β i represents the influence coefficient of the data volume index of the i-th task to be assigned; γ i represents the influence coefficient of the real-time requirement index of the i-th task to be assigned; represents the average computational workload index of the i-th task to be assigned; represents the average data volume index of the i-th task to be assigned; represents the average real-time requirement index of the i-th task to be assigned; N represents the number of tasks to be assigned.
[0013] Further, the step of allocating the part of the task to be assigned that exceeds the terminal computing power index to the cloud server or other terminals in the local area network includes:
[0014] Obtain the number of idle terminals in the local area network, the average terminal computing power index of all idle terminals in the local area network, the cloud service computing power index, the first transmission rate of the task to be assigned from the source terminal to other terminals in the local area network, and the second transmission rate of the task to be assigned from the source terminal to the cloud server;
[0015] Calculate the first task processing time required for collaborative processing by terminals in the local area network according to the data volume index, the task complexity, the number of idle terminals, the average terminal computing power index, and the first transmission rate;
[0016] Calculate the second task processing time required for collaborative processing by the cloud service according to the data volume index, the task complexity, the terminal computing power index, the cloud service computing power index, and the second transmission rate;
[0017] Determine whether the first task processing time exceeds the second task processing time. If so, allocate the part of the task to be allocated that exceeds the terminal computing power index to the cloud server. If not, allocate the part of the task to be allocated that exceeds the terminal computing power index to other terminals in the local area network.
[0018] Further, the calculation formula for the first task processing time is:
[0019]
[0020] In the formula, T LAN represents the first task processing time; V represents the data volume index; C task represents the task complexity; N available represents the number of idle terminals; represents the average terminal computing power index;
[0021] R device_to_LAN represents the first transmission rate;
[0022] The calculation formula for the second task processing time is:
[0023]
[0024] In the formula, T cloud_collaboration represents the second task processing time; C device represents the terminal computing power index; C cloud represents the cloud service computing power index; R device_to_cloud represents the second transmission rate.
[0025] Another embodiment of the present invention further provides a cloud-edge collaborative task allocation device based on task difficulty analysis, including: a data acquisition module, a task complexity calculation module, and a task allocation module;
[0026] The data acquisition module is used to acquire the computing volume index of all tasks to be allocated, the data volume index of all tasks to be allocated, the real-time requirement index of all tasks to be allocated, the average computing volume index of historical tasks, the average data volume index of historical tasks, and the average real-time requirement index of historical tasks; wherein, the real-time requirement index is used to measure the level of real-time requirements of tasks.
[0027] The task complexity calculation module is used to calculate the task complexity of each task to be assigned according to the calculation amount index, the data amount index, the real-time requirement index, the average calculation amount index, the average data amount index, and the average real-time requirement index of the task to be assigned through the task complexity calculation formula; wherein, the task complexity is in a direct proportion relationship with the calculation amount index, the data amount index, and the real-time requirement index.
[0028] The data acquisition module is further used to acquire the terminal computing power index of the terminal where the task to be assigned is currently located; wherein, the terminal computing power index is used to measure the level of terminal computing power.
[0029] The task assignment module is used to determine whether the task complexity exceeds the terminal computing power index. If so, the part of the task to be assigned that exceeds the terminal computing power index is assigned to the cloud server or other terminals in the local area network. If not, the task is independently processed by the terminal where the task to be assigned is located.
[0030] Further, the task complexity calculation formula is:
[0031] C task,i =α i ·K i +β i ·V i +γ i ·T i ;
[0032]
[0033]
[0034] In the formula, C task,i represents the task complexity of the i-th task to be assigned; K i represents the calculation amount index of the i-th task to be assigned; V i represents the data amount index of the i-th task to be assigned; T i represents the real-time requirement index of the i-th task to be assigned; α i represents the influence coefficient of the calculation amount index of the i-th task to be assigned; β i represents the influence coefficient of the data amount index of the i-th task to be assigned; γ i represents the influence coefficient of the real-time requirement index of the i-th task to be assigned; represents the average calculation amount index of the i-th task to be assigned; represents the average data amount index of the i-th task to be assigned; Indicates the average real-time requirement index of the i-th task to be allocated; N represents the number of tasks to be allocated.
[0035] Further, the step of allocating the part of the task to be allocated that exceeds the terminal computing power index to the cloud server or other terminals in the local area network includes:
[0036] Obtain the number of idle terminals in the local area network, the average terminal computing power index of all idle terminals in the local area network, the cloud service computing power index, the first transmission rate of the task to be allocated from the source terminal to other terminals in the local area network, and the second transmission rate of the task to be allocated from the source terminal to the cloud server;
[0037] Calculate the first task processing time required for collaborative processing by terminals in the local area network according to the data volume index, the task complexity, the number of idle terminals, the average terminal computing power index, and the first transmission rate;
[0038] Calculate the second task processing time required for collaborative processing by the cloud service according to the data volume index, the task complexity, the terminal computing power index, the cloud service computing power index, and the second transmission rate;
[0039] Determine whether the first task processing time exceeds the second task processing time. If so, allocate the part of the task to be allocated that exceeds the terminal computing power index to the cloud server; if not, allocate the part of the task to be allocated that exceeds the terminal computing power index to other terminals in the local area network.
[0040] Further, the calculation formula for the first task processing time is:
[0041]
[0042] In the formula, T LAN represents the first task processing time; V represents the data volume index; C task represents the task complexity; N available represents the number of idle terminals; represents the average terminal computing power index;
[0043] R device_to_LAN represents the first transmission rate;
[0044] The calculation formula for the second task processing time is:
[0045]
[0046] In the formula, T cloud_collaboration represents the second task processing time; C device represents the terminal computing power index; Ccloud represents the cloud service computing capacity metric; R device_to_cloud represents the second transmission rate.
[0047] Another embodiment of the present invention further provides a terminal device, including: a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, the steps of the cloud-edge collaborative task allocation method based on task difficulty analysis of the present invention are implemented.
[0048] Another embodiment of the present invention further provides a computer-readable storage medium item, including: a stored computer program. When the computer program runs, it controls the device where the computer-readable storage medium is located to execute the steps of the cloud-edge collaborative task allocation method based on task difficulty analysis of the present invention.
[0049] By implementing the present invention, the following beneficial effects are achieved:
[0050] The present invention obtains the computational amount metric, data amount metric, and real-time requirement metric of the task to be allocated, and calculates the task complexity; according to the task complexity and the terminal computing capacity metric of the terminal where it is located, it determines whether the task should be independently processed by the terminal device or jointly processed by the cloud server or other terminals within the local area network. The present invention considers the task complexity during the task allocation process, especially pays attention to the computational amount metric, data amount metric, and real-time requirement metric of the task, making the cloud-edge collaborative task allocation result more in line with the computational amount situation, data amount situation, and real-time requirements of the task to be allocated, and having higher practicality. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] In order to more clearly illustrate the technical solutions of the present application, the drawings required for the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0052] Figure 1 is a flowchart of a cloud-edge collaborative task allocation method based on task difficulty analysis provided by an embodiment of the present invention;
[0053] Figure 2 is a structural diagram of a cloud-edge collaborative task allocation device based on task difficulty analysis provided by another embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0054] To make the objectives, technical solutions, and advantages of this application clearer, the following will clearly and completely describe the technical solutions in this application in conjunction with the accompanying drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, rather than all of them. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in this application without creative efforts belong to the scope of protection of this application.
[0055] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which this application belongs; the terms used herein are only for the purpose of describing specific embodiments and are not intended to limit this application; the term "including" and any of its variations in the specification and claims of this application and the above description of the drawings are intended to cover non-exclusive inclusion.
[0056] In the description of the embodiments of this application, technical terms such as "first" and "second" are only used to distinguish different objects and cannot be understood as indicating or implying relative importance or implicitly indicating the quantity, specific order, or primary-secondary relationship of the indicated technical features.
[0057] Referring to, to solve the problem of low practicality of the cloud-edge collaborative task allocation result caused by the inability to effectively perceive the task difficulty in the prior art, a cloud-edge collaborative task allocation method based on task difficulty analysis provided by an embodiment of the present invention includes:
[0058] See Figure 1 , to solve the problem of low practicality of the cloud-edge collaborative task allocation result caused by the inability to effectively perceive the task difficulty in the prior art, a cloud-edge collaborative task allocation method based on task difficulty analysis provided by an embodiment of the present invention includes:
[0059] S1. Obtain the computation amount index of all tasks to be allocated, the data amount index of all tasks to be allocated, the real-time requirement index of all tasks to be allocated, the average computation amount index of historical tasks, the average data amount index of historical tasks, and the average real-time requirement index of historical tasks; wherein, the real-time requirement index is used to measure the level of the real-time requirement of the task.
[0060] In one embodiment, obtaining the computation amount index of all tasks to be allocated includes:
[0061] For each task to be allocated, obtain the execution time of the task to be allocated and the CPU occupancy rate during the runtime of the task to be allocated;
[0062] Calculate the computational complexity metric of the task to be allocated according to the execution time and the CPU occupancy rate;
[0063] Among them, the calculation formula of the computational complexity metric is:
[0064] K = k1·t exec + k2·CPU usage ;
[0065] In the formula, K represents the computational complexity metric; t exec represents the task execution time; CPU usage represents the CPU occupancy rate; k1 and k2 are proportionality coefficients, which are adjusted according to the scarcity of computing resources and the task type in the system. In a compute-intensive task scenario, increase the value of k2; in a sensitive task, increase the value of k2.
[0066] In one embodiment, obtain the data volume metrics of all tasks to be allocated, including:
[0067] For each task to be allocated, obtain the data transfer volume and data processing volume of the task to be allocated;
[0068] Calculate the data volume metric of the task to be allocated according to the data transfer volume and the data processing volume;
[0069] Among them, the calculation formula of the data volume metric is:
[0070] V = k3·Data size + k4·Data processed ;
[0071] In the formula, V represents the data volume metric; Data size represents the data transfer volume; Data processed represents the data processing volume; k3 and k4 are proportionality coefficients, which are adjusted according to the cost of data transfer and processing and the task characteristics. In a scenario with frequent data transfer, increase the value of k3; in a task with complex data processing, increase the value of k4.
[0072] In one embodiment, obtain the real-time requirement metrics of all tasks to be allocated, including:
[0073] For each task to be allocated, obtain the response time metric and the delay tolerance metric of the task to be allocated;
[0074] Calculate the real-time requirement metric of the task to be allocated according to the response time metric and the delay tolerance metric;
[0075] Among them, the calculation formula of the real-time requirement metric is:
[0076]
[0077] In the formula, T represents the real-time requirement index; t response represents the response time requirement index; t response represents the delay tolerance index; k5 and k6 are proportionality coefficients, which are adjusted according to the sensitivity of the task to the response time and the delay tolerance. In scenarios with extremely high requirements for the response time, increase the value of k5; in tasks where the delay tolerance is more concerned, increase the value of k6.
[0078] The smaller the response time value, the more urgent the task and the higher the real-time requirement; the smaller the delay tolerance value, the lower the tolerance and the higher the real-time.
[0079] S2. For each task to be assigned, calculate the task complexity of the task to be assigned through the task complexity calculation formula according to the calculation amount index, the data amount index, the real-time requirement index, the average calculation amount index, the average data amount index, and the average real-time requirement index of the task to be assigned; among them, the task complexity is directly proportional to the calculation amount index, the data amount index, and the real-time requirement index.
[0080] In a preferred embodiment, the task complexity calculation formula is:
[0081] C task,i = α i ·K i + β i ·V i + γ i ·T i ;
[0082]
[0083]
[0084] In the formula, C task,i represents the task complexity of the i-th task to be assigned; K i represents the calculation amount index of the i-th task to be assigned; V i represents the data amount index of the i-th task to be assigned; T i represents the real-time requirement index of the i-th task to be assigned; α i represents the influence coefficient of the calculation amount index of the i-th task to be assigned; β i represents the influence coefficient of the data amount index of the i-th task to be assigned; γ i represents the influence coefficient of the real-time requirement index of the i-th task to be assigned; represents the average calculation amount index of the i-th task to be assigned; represents the average data volume index of the i-th task to be allocated; represents the average real-time requirement index of the i-th task to be allocated; N represents the number of tasks to be allocated.
[0085] It should be noted that in the above formula, represents the computational complexity uncertainty, represents the data volume uncertainty, represents the real-time requirement uncertainty.
[0086] In this embodiment, the task complexity is obtained through the uncertainty adaptive influence coefficient setting method in multi-task learning. The influence coefficient can be dynamically adjusted through the uncertainty of the task, that is, the influence coefficient is inversely proportional to the noise of the task, that is, the more difficult the task, the greater the weight. The noise of the task includes computational complexity uncertainty, data volume uncertainty, and real-time requirement uncertainty.
[0087] S3. Obtain the terminal computing power index of the terminal where the task to be allocated is currently located; wherein, the terminal computing power index is used to measure the level of terminal computing power.
[0088] S4. Determine whether the task complexity exceeds the terminal computing power index. If so, allocate the part of the task to be allocated that exceeds the terminal computing power index to the cloud server or other terminals in the local area network. If not, the terminal where the task to be allocated is located processes it independently.
[0089] In step S4, if the task complexity exceeds the terminal computing power index, this means that the terminal device can only process part of the task, and the remaining part is processed by the cloud server or other terminals in the local area network; if the task complexity does not exceed the terminal computing power index, this means that the task can be completely processed by the terminal device without the participation of other terminals or the cloud server in the local area network. According to this division method, the device capabilities and task complexity are dynamically adjusted for task allocation to achieve the optimal utilization of computing resources.
[0090] It should be noted that by calculating the task complexity and comparing it with the computing capabilities of the terminal device and the cloud center. For some simple tasks, they are processed independently by the terminal device to quickly provide services to customers; for complex tasks, multiple terminal devices and the servers of the cloud center cooperate to process them. The terminal devices upload the real-time collected data, and the servers of the cloud center perform centralized analysis and calculation, and then issue the optimized scheduling scheme instructions to each intelligent terminal; for tasks involving big data analysis and long-term planning, the terminal devices can cooperate with the cloud server to process them. The cloud server stores and analyzes a large amount of historical data to provide decision support for optimization, and the terminal devices are responsible for gradually implementing and feedback adjusting the optimized scheme.
[0091] In a preferred embodiment, allocating the part of the task to be allocated that exceeds the terminal computing power index to a cloud server or other terminals in a local area network includes:
[0092] Obtain the number of idle terminals in the local area network, the average terminal computing power index of all idle terminals in the local area network, the cloud service computing power index, the first transmission rate of the task to be allocated from the terminal where it is located to other terminals in the local area network, and the second transmission rate of the task to be allocated from the terminal where it is located to the cloud server;
[0093] According to the data volume index, the task complexity, the number of idle terminals, the average terminal computing power index, and the first transmission rate, calculate the first task processing time required for collaborative processing by terminals in the local area network;
[0094] According to the data volume index, the task complexity, the terminal computing power index, the cloud service computing power index, and the second transmission rate, calculate the second task processing time required for collaborative processing by the cloud service;
[0095] Determine whether the first task processing time exceeds the second task processing time. If so, allocate the part of the task to be allocated that exceeds the terminal computing power index to the cloud server. If not, allocate the part of the task to be allocated that exceeds the terminal computing power index to other terminals in the local area network.
[0096] In a preferred embodiment, the calculation formula for the first task processing time is:
[0097]
[0098] In the formula, T LAN represents the first task processing time; V represents the data volume index; C task represents the task complexity; N available represents the number of idle terminals; represents the average terminal computing power index;
[0099] R device_to_LAN represents the first transmission rate;
[0100] The calculation formula for the second task processing time is:
[0101]
[0102] In the formula, T cloud_collaboration represents the second task processing time; C device represents the terminal computing power index; C cloud represents the cloud service computing power index; R device_to_cloud represents the second transmission rate.
[0103] In this embodiment, if T LAN ≤T cloud_collaboration , the task selects multiple terminals within the local area network to process collaboratively; if T LAN >T cloud_collaboration , the task selects the cloud server to process collaboratively.
[0104] In one embodiment, when allocating the part of the to-be-allocated task that exceeds the terminal computing power index to other terminals in the local area network, an appropriate number of terminal devices are dynamically selected within the local area network according to the task requirements to complete the task collaboratively. The total computing power N available ×C device of multiple terminal devices within the local area network must meet the computing requirements of the task to ensure that the task is completed within a reasonable time. The minimum number of terminal devices required can be calculated in real time
[0105] It should be noted that the present invention obtains the computing amount index, data amount index, and real-time requirement index of the to-be-allocated task, and calculates the task complexity; according to the task complexity, the terminal computing power index of the terminal where the task is located, the cloud server computing power index, the transmission rate between terminals within the local area network, and the transmission rate from the terminal to the cloud server, it is judged whether the task should be independently processed by the terminal device, processed collaboratively by multiple terminal devices within the local area network, or processed collaboratively by the terminal where the task is located and the cloud server; among them, when the computing power of the terminal where the task is located is sufficient, it is independently completed by the terminal where the task is located; when the computing power of the idle terminal devices within the local area network where the terminal where the task is located is greater than or equal to the computing power required for the task, some idle terminal devices within the local area network are dynamically expanded according to certain rules so that they are combined into an overall computing resource with sufficient computing power to jointly complete this task. When all the idle terminals within the local area network where the terminal where the task is located are not enough to complete the task, the task is completed collaboratively by the terminal where the task is located and the cloud server. The present invention realizes cloud-edge collaborative completion of the task through an adaptive control algorithm, which dynamically expands according to the task difficulty and computing resources.
[0106] As Figure 2 shown, based on the above method item embodiment, a corresponding device item embodiment is provided;
[0107] An embodiment of the present invention provides a cloud-edge collaborative task allocation device based on task difficulty analysis, including: a data acquisition module, a task complexity calculation module, and a task allocation module;
[0108] The data acquisition module is used to acquire the computing volume index of all tasks to be assigned, the data volume index of all tasks to be assigned, the real-time requirement index of all tasks to be assigned, the average computing volume index of historical tasks, the average data volume index of historical tasks, and the average real-time requirement index of historical tasks; wherein, the real-time requirement index is used to measure the level of real-time requirements for tasks.
[0109] The task complexity calculation module is used to calculate the task complexity of each task to be assigned according to the computing volume index of the task to be assigned, the data volume index of the task to be assigned, the real-time requirement index of the task to be assigned, the average computing volume index, the average data volume index, and the average real-time requirement index through a task complexity calculation formula; wherein, the task complexity is in a direct proportion relationship with the computing volume index, the data volume index, and the real-time requirement index.
[0110] The data acquisition module is further used to acquire the terminal computing power index of the terminal where the task to be assigned is currently located; wherein, the terminal computing power index is used to measure the level of terminal computing power.
[0111] The task allocation module is used to determine whether the task complexity exceeds the terminal computing power index. If so, the part of the task to be assigned that exceeds the terminal computing power index is allocated to a cloud server or other terminals in the local area network. If not, the task is independently processed by the terminal where the task to be assigned is located.
[0112] In a preferred embodiment, the task complexity calculation formula is:
[0113] C task,i =α i ·K i +β i ·V i +γ i ·T i ;
[0114]
[0115] In the formula, C task,i represents the task complexity of the i-th task to be assigned; K i represents the computing volume index of the i-th task to be assigned; V i represents the data volume index of the i-th task to be assigned; T i represents the real-time requirement index of the i-th task to be assigned; α i represents the influence coefficient of the computing volume index of the i-th task to be assigned; β i represents the influence coefficient of the data volume index of the i-th task to be assigned; γ iIndicates the impact coefficient of the real-time requirement index of the i-th task to be assigned; Indicates the average computing volume index of the i-th task to be assigned; Indicates the average data volume index of the i-th task to be assigned; Indicates the average real-time requirement index of the i-th task to be assigned; N represents the number of tasks to be assigned.
[0116] In a preferred embodiment, the step of allocating the part of the task to be assigned that exceeds the terminal computing power index to a cloud server or other terminals in the local area network includes:
[0117] Obtain the number of idle terminals in the local area network, the average terminal computing power index of all idle terminals in the local area network, the cloud service computing power index, the first transmission rate of the task to be assigned from the source terminal to other terminals in the local area network, and the second transmission rate of the task to be assigned from the source terminal to the cloud server;
[0118] Calculate the first task processing time required for collaborative processing by terminals in the local area network according to the data volume index, the task complexity, the number of idle terminals, the average terminal computing power index, and the first transmission rate;
[0119] Calculate the second task processing time required for collaborative processing by the cloud service according to the data volume index, the task complexity, the terminal computing power index, the cloud service computing power index, and the second transmission rate;
[0120] Determine whether the first task processing time exceeds the second task processing time. If so, allocate the part of the task to be assigned that exceeds the terminal computing power index to the cloud server. If not, allocate the part of the task to be assigned that exceeds the terminal computing power index to other terminals in the local area network.
[0121] In a preferred embodiment, the calculation formula for the first task processing time is:
[0122]
[0123] In the formula, T LAN represents the first task processing time; V represents the data volume index; C task represents the task complexity; N available represents the number of idle terminals; represents the average terminal computing power index;
[0124] R device_to_LAN represents the first transmission rate;
[0125] The calculation formula for the second task processing time is:
[0126]
[0127] Wherein, T cloud_collaboration represents the second task processing time; C device represents the terminal computing power index; C cloud represents the cloud service computing power index; R device_to_cloud represents the second transmission rate.
[0128] It can be understood that the above device item embodiments correspond to the method item embodiments of the present invention, and can implement the cloud-edge collaborative task allocation method based on task difficulty analysis provided by any one of the above method item embodiments of the present invention.
[0129] It should be noted that the above-described device embodiments are merely illustrative, and some or all of the modules can be selected according to actual needs to achieve the purpose of the present embodiment solution. In addition, in the attached drawings of the device embodiments provided by the present invention, the connection relationship between modules indicates that they have a communication connection, which can be specifically implemented as one or more communication buses or signal lines. Those of ordinary skill in the art can understand and implement without creative efforts.
[0130] Based on the above method item embodiments, another embodiment of the present invention provides a terminal device, which includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements the cloud-edge collaborative task allocation method based on task difficulty analysis according to any one of the embodiments of the present invention.
[0131] Exemplarily, in this embodiment, the computer program can be divided into one or more modules, and the one or more modules are stored in the memory and executed by the processor to complete the present invention. The one or more module elements can be a series of computer program instruction segments capable of completing specific functions, and the instruction segments are used to describe the execution process of the computer program in the terminal device.
[0132] The terminal device can be a computing device such as a desktop computer, a notebook, a palm computer, and a cloud server. The terminal device may include, but is not limited to, a processor and a memory.
[0133] The so-called processor may be a Central Processing Unit (CPU), or may also be other general-purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field-Programmable Gate Arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The processor is the control center of the terminal device and connects all parts of the entire terminal device through various interfaces and lines.
[0134] Based on the above method embodiment, another embodiment of the present invention provides a computer-readable storage medium, including a stored computer program, wherein when the computer program runs, it controls the device where the computer-readable storage medium is located to execute the cloud-edge collaborative task allocation method based on task difficulty analysis described in any one of the above method embodiments of the present invention.
[0135] Among them, if the modules / units integrated in the device / terminal device are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, to implement all or part of the processes in the above method embodiments of the present invention, it can also be completed by a computer program instructing relevant hardware. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by a processor, the steps of the above various method embodiments can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in the form of source code, object code, executable file, or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disc, computer memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier signal, telecommunication signal, and software distribution medium, etc.
[0136] The above is the preferred embodiment of the present invention. It should be noted that for those of ordinary skill in the art, without departing from the principle of the present invention, several improvements and refinements can be made, and these improvements and refinements are also regarded as the protection scope of the present invention.
Claims
1. A cloud-edge collaborative task allocation method based on task difficulty analysis, characterized in that Including: Obtain the computational workload metrics of all tasks to be assigned, the data volume metrics of all tasks to be assigned, the real-time requirement metrics of all tasks to be assigned, the average computational workload metrics of historical tasks, the average data volume metrics of historical tasks, and the average real-time requirement metrics of historical tasks; wherein, the real-time requirement metrics are used to measure the level of real-time requirements for tasks; For each task to be assigned, calculate the task complexity of the task to be assigned through a task complexity calculation formula according to the computational workload metrics of the task to be assigned, the data volume metrics of the task to be assigned, the real-time requirement metrics of the task to be assigned, the average computational workload metrics, the average data volume metrics, and the average real-time requirement metrics; wherein, the task complexity is in a proportional relationship with the computational workload metrics, the data volume metrics, and the real-time requirement metrics; Obtain the terminal computing power metrics of the terminal where the task to be assigned is currently located; wherein, the terminal computing power metrics are used to measure the level of terminal computing power; Determine whether the task complexity exceeds the terminal computing power metrics. If so, allocate the part of the task to be assigned that exceeds the terminal computing power metrics to a cloud server or other terminals in the local area network. If not, the terminal where the task to be assigned is located processes it independently.
2. The cloud-edge collaborative task allocation method based on task difficulty analysis according to claim 1, wherein The task complexity calculation formula is: C task,i = α i · K i + β i · V i + γ i · T i ; Where, C task,i represents the task complexity of the i-th task to be assigned; K i represents the computation volume index of the i-th task to be assigned; V i represents the data volume index of the i-th task to be assigned; T i represents the real-time requirement index of the i-th task to be assigned; α i represents the influence coefficient of the computation volume index of the i-th task to be assigned; β i represents the influence coefficient of the data volume index of the i-th task to be assigned; γ i represents the influence coefficient of the real-time requirement index of the i-th task to be assigned; represents the average computation volume index of the i-th task to be assigned; represents the average data volume index of the i-th task to be assigned; represents the average real-time requirement index of the i-th task to be assigned; N represents the number of tasks to be assigned.
3. The cloud-edge collaborative task allocation method based on task difficulty analysis according to claim 1, wherein, The step of allocating the part of the task to be assigned that exceeds the terminal computing power metrics to a cloud server or other terminals in the local area network includes: Obtain the number of idle terminals in the local area network, the average terminal computing power metrics of all idle terminals in the local area network, the cloud service computing power metrics, the first transmission rate of the task to be assigned from the current terminal to other terminals in the local area network, and the second transmission rate of the task to be assigned from the current terminal to the cloud server; Calculate the first task processing time required for collaborative processing by terminals in the local area network according to the data volume metrics, the task complexity, the number of idle terminals, the average terminal computing power metrics, and the first transmission rate; Calculate the second task processing time required for collaborative processing by the cloud service according to the data volume metrics, the task complexity, the terminal computing power metrics, the cloud service computing power metrics, and the second transmission rate; Determine whether the first task processing time exceeds the second task processing time. If so, allocate the part of the task to be assigned that exceeds the terminal computing power metrics to the cloud server. If not, allocate the part of the task to be assigned that exceeds the terminal computing power metrics to other terminals in the local area network.
4. The cloud-edge collaborative task allocation method based on task difficulty analysis according to claim 3, characterized in that, The calculation formula for the first task processing time is: where, T LAN represents the first task processing time; V represents the data volume index; C task represents the task complexity; N available represents the number of idle terminals; represents the average terminal computing power index; R device_to_LAN represents the first transmission rate; The calculation formula for the second task processing time is: where T cloud_collaboration represents the second task processing time; C device Indicates the terminal computing power index; C cloud Indicates the cloud service computing power index; R device_to_cloud Indicates the second transmission rate.
5. A cloud-edge collaborative task allocation device based on task difficulty analysis, characterized in that, Including: A data acquisition module, a task complexity calculation module, and a task allocation module; The data acquisition module is used to acquire the computational complexity metrics of all tasks to be assigned, the data volume metrics of all tasks to be assigned, the real-time requirement metrics of all tasks to be assigned, the average computational complexity metrics of historical tasks, the average data volume metrics of historical tasks, and the average real-time requirement metrics of historical tasks; wherein, the real-time requirement metrics are used to measure the level of real-time requirements for tasks. The task complexity calculation module is used to calculate the task complexity of each task to be assigned according to the computational complexity metric of the task to be assigned, the data volume metric of the task to be assigned, the real-time requirement metric of the task to be assigned, the average computational complexity metric, the average data volume metric, and the average real-time requirement metric through a task complexity calculation formula; wherein, the task complexity is in a direct proportional relationship with the computational complexity metric, the data volume metric, and the real-time requirement metric. The data acquisition module is further used to acquire the terminal computing power metric of the terminal where the task to be assigned is currently located; wherein, the terminal computing power metric is used to measure the level of terminal computing power. The task allocation module is used to determine whether the task complexity exceeds the terminal computing power metric. If so, the part of the task to be assigned that exceeds the terminal computing power metric is allocated to a cloud server or other terminals in the local area network. If not, the task to be assigned is independently processed by the terminal where it is located.
6. The cloud-edge collaborative task allocation device based on task difficulty analysis according to claim 5, wherein, The task complexity calculation formula is: C task,i = α i ·K i + β i ·V i + γ i ·T i ; Where, C task,i represents the task complexity of the i-th task to be assigned; K i represents the computational volume index of the i-th task to be assigned; V i represents the data volume index of the i-th task to be assigned; T i represents the real-time requirement index of the i-th task to be assigned; α i represents the influence coefficient of the computational volume index of the i-th task to be assigned; β i represents the influence coefficient of the data volume index of the i-th task to be assigned; γ i represents the influence coefficient of the real-time requirement index of the i-th task to be assigned; represents the average computational volume index of the i-th task to be assigned; represents the average data volume index of the i-th task to be assigned; represents the average real-time requirement index of the i-th task to be assigned; N represents the number of tasks to be assigned.
7. The cloud-edge collaborative task allocation device based on task difficulty analysis according to claim 5, characterized in that, The allocation of the part of the task to be assigned that exceeds the terminal computing power metric to a cloud server or other terminals in the local area network includes: Acquiring the number of idle terminals in the local area network, the average terminal computing power metric of all idle terminals in the local area network, the cloud service computing power metric, the first transmission rate of the task to be assigned from its current terminal to other terminals in the local area network, and the second transmission rate of the task to be assigned from its current terminal to the cloud server. Calculating the first task processing time required for collaborative processing by terminals in the local area network according to the data volume metric, the task complexity, the number of idle terminals, the average terminal computing power metric, and the first transmission rate. Calculating the second task processing time required for collaborative processing by the cloud service according to the data volume metric, the task complexity, the terminal computing power metric, the cloud service computing power metric, and the second transmission rate. Determining whether the first task processing time exceeds the second task processing time. If so, the part of the task to be assigned that exceeds the terminal computing power metric is allocated to the cloud server. If not, the part of the task to be assigned that exceeds the terminal computing power metric is allocated to other terminals in the local area network.
8. The cloud-edge collaborative task allocation device based on task difficulty analysis according to claim 7, wherein The calculation formula for the first task processing time is: Where, T LAN represents the first task processing time; V represents the data volume index; C task represents the task complexity; N available represents the number of idle terminals; represents the average terminal computing power index; R device_to_LAN represents the first transmission rate; The calculation formula for the second task processing time is: where T cloud_collaboration represents the second task processing time; C device represents the terminal computing power index; C cloud represents the cloud service computing power index; R device_to_cloud represents the second transmission rate.
9. A terminal device, characterized in that, It includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements the cloud-edge collaborative task allocation method based on task difficulty analysis as described in any one of claims 1-4.
10. A computer-readable storage medium, characterized in that, Including: A stored computer program, wherein when the computer program runs, it controls the device where the computer-readable storage medium is located to execute the cloud-edge collaborative task allocation method based on task difficulty analysis according to any one of claims 1-4.
Citation Information
Cited By
Computing task allocation method based on end-cloud fusion, computer equipment and medium
CN120723488A
End-cloud fusion-based computing task allocation method, computer device and medium
CN120723488B