Task processing method and device, equipment and storage medium

By acquiring task and edge device information and combining it with a neural network model to optimize task offloading and resource scheduling, the problem of low resource scheduling efficiency is solved, the real-time performance and efficiency of task processing are improved, and the quality of user service is optimized.

CN121070531APending Publication Date: 2025-12-05CHINA MOBILE COMM CORP GUANGXI CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410720407.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-05
Publication Date
2025-12-05

AI Technical Summary

Technical Problem

In existing technologies, resource scheduling efficiency is low, load prediction is inaccurate, real-time performance is poor, scheduling strategies are simplistic, and factors such as user experience and resource utilization are not effectively considered, resulting in unreasonable task allocation.

Method used

By acquiring information about tasks and edge devices, scheduling and execution strategies are determined, including various strategies for tasks to be executed by edge devices, base stations, and computing nodes. By combining neural network models, task offloading and resource scheduling are optimized, taking into account task latency tolerance and device resource availability, and task allocation is dynamically adjusted.

Benefits of technology

It improved the real-time performance and efficiency of task processing, optimized resource scheduling, enhanced user service quality, and minimized task completion time while making rational use of resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121070531A_ABST
    Figure CN121070531A_ABST
Patent Text Reader

Abstract

The invention discloses a task processing method and device, equipment and a storage medium, and belongs to the technical field of cloud computing and big data. The method comprises the steps that task information of a task and device information of an edge device are obtained, the task information comprises first information used for representing the tolerance degree of the task to task delay time, and the device information comprises second information used for representing the residual resource amount of the edge device and third information used for representing the computing power of the edge device; determining a scheduling execution strategy of the task based on the task information and the equipment information, the scheduling execution strategy comprises a first scheduling execution strategy of which the task is executed by the edge device, a second scheduling execution strategy of which the task is executed by the base station connected with the edge device, a third scheduling execution strategy of which the task is executed by the edge device and the base station, or a fourth scheduling execution strategy of which the task is executed by a computing node connected with the base station; and processing the task according to the scheduling execution strategy. Therefore, the efficiency of task allocation and resource scheduling is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application belongs to the technical field of cloud computing and big data, and particularly relates to a task processing method and device, equipment and a storage medium. BACKGROUND

[0002] In a cloud computing environment, resource scheduling and load balancing are key to ensuring the performance and scalability of cloud services. Resource scheduling refers to the allocation of tasks or requests to appropriate edge nodes to achieve efficient task execution and rational resource utilization. Resource scheduling needs to consider factors such as the load of edge nodes, network latency, and data transmission. Among them, the historical running data of edge nodes and machine learning algorithms can be used to predict the load of edge nodes, so as to perform resource scheduling based on the prediction results.

[0003] However, since the load of edge nodes is easily affected by various factors such as sudden events and changes in user behavior, it is difficult to ensure the accuracy of the prediction results by only using historical running data to predict the load; and the aforementioned resource scheduling method usually only performs resource scheduling based on the prediction results, ignoring other factors such as user experience and resource utilization, which can easily lead to unreasonable task allocation and low resource scheduling efficiency. SUMMARY

[0004] The embodiments of the present application provide a task processing method, device, equipment and storage medium, which can solve the problem of low resource scheduling efficiency in related technologies.

[0005] In a first aspect, the embodiments of the present application provide a task processing method, which can include:

[0006] Obtaining task information of a task and device information of an edge device, the task information including first information, the first information being used to represent the tolerance degree of the task to task delay time, the device information including second information and third information, the second information being used to represent the remaining resource amount of the edge device, and the third information being used to represent the computing capability of the edge device;

[0007] Based on the task information and the device information, determining a scheduling execution strategy of the task, the scheduling execution strategy including a first scheduling execution strategy that the task is executed by the edge device, a second scheduling execution strategy that the task is executed by a base station connected with the edge device, a third scheduling execution strategy that the task is executed by the edge device and the base station, or a fourth scheduling execution strategy that the task is executed by a computing node connected with the base station;

[0008] Processing the task according to the scheduling execution strategy.

[0009] In a second aspect, the embodiments of the present application provide a task processing device, which can include:

[0010] The acquisition module is configured to acquire task information of the task and device information of the edge device, the task information comprising first information, the first information being used to represent a tolerance degree of the task to a task delay time, the device information comprising second information and third information, the second information being used to represent a remaining resource amount of the edge device, and the third information being used to represent a computing capability of the edge device;

[0011] The determination module is configured to determine a scheduling execution strategy of the task based on the task information and the device information, the scheduling execution strategy comprising a first scheduling execution strategy in which the task is executed by the edge device, a second scheduling execution strategy in which the task is executed by a base station connected to the edge device, a third scheduling execution strategy in which the task is executed by the edge device and the base station, or a fourth scheduling execution strategy in which the task is executed by a computing node connected to the base station.

[0012] The processing module is configured to process the task according to the scheduling execution strategy.

[0013] In a third aspect, an embodiment of the present application provides a computer device, which comprises a processor and a memory storing computer program instructions.

[0014] The processor executes the computer program instructions to implement the task processing method shown in the first aspect.

[0015] In a fourth aspect, an embodiment of the present application provides a computer storage medium, which stores computer program instructions, and the computer program instructions are executed by a processor to implement the task processing method shown in the first aspect.

[0016] In a fifth aspect, an embodiment of the present application provides a chip, which comprises a processor and a communication interface, the communication interface and the processor being coupled, and the processor is configured to run programs or instructions to implement the task processing method shown in the first aspect.

[0017] In a sixth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium, and the computer program product is executed by at least one processor to implement the task processing method shown in the first aspect.

[0018] The task processing method, device, equipment and storage medium provided by the embodiments of the present application obtain task information of a task and device information of an edge device, the task information includes first information, the first information is used to represent the tolerance degree of the task to the task delay time, the device information includes second information and third information, the second information is used to represent the remaining resource amount of the edge device, and the third information is used to represent the computing capability of the edge device; based on the task information and the device information, a scheduling execution strategy of the task is determined, the scheduling execution strategy includes a first scheduling execution strategy that the task is executed by the edge device, a second scheduling execution strategy that the task is executed by a base station connected with the edge device, a third scheduling execution strategy that the task is executed by the edge device and the base station, or a fourth scheduling execution strategy that the task is executed by a computing node connected with the base station; and the task is processed according to the scheduling execution strategy. In this way, the remaining resource amount and the computing capability of the edge device that can execute the task are considered, and the scheduling execution strategy of the task is determined considering the tolerance degree of the task to the task delay time, so as to realize the minimization of the task completion time, improve the task allocation efficiency while ensuring the real-time performance of the task processing; and the scheduling execution strategy of the task can allocate the task to various objects that execute the task, such as only the edge device, only the base station, both the edge device and the base station, or the computing node connected with the base station, so that the efficiency of the task processing can be effectively improved, and the resource scheduling efficiency is improved. BRIEF DESCRIPTION OF DRAWINGS

[0019] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings needed to be used in the embodiments of the present application will be briefly introduced. Those skilled in the art can obtain other drawings according to these drawings without creating any creative labor.

[0020] Figure 1 A flowchart of a task processing method provided by an embodiment of the present application;

[0021] Figure 2 A task allocation flowchart of a task processing method provided by an embodiment of the present application;

[0022] Figure 3 A neural network model training flowchart of a task processing method provided by an embodiment of the present application;

[0023] Figure 4 A structural diagram of a task processing device provided by an embodiment of the present application;

[0024] Figure 5 A structural diagram of a computer device provided by some embodiments of the present application;

[0025] Figure 6A hardware structure schematic diagram of a computer device provided for some embodiments of the present application is shown. DETAILED DESCRIPTION

[0026] The features and exemplary embodiments of various aspects of the present application will be described below in detail, in order to make the purposes, technical solutions and advantages of the present application more clear and apparent, the present application will be further described in detail below in combination with the drawings and specific embodiments. It should be understood that the specific embodiments described herein are only intended to explain the present application, but not to limit the present application. The present application can be implemented without some of these specific details for those skilled in the art. The following description of the embodiments is only to provide a better understanding of the present application by showing examples of the present application.

[0027] It should be noted that, in this paper, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that there is any such actual relationship or order between the entities or operations. Moreover, the terms "include", "contain" or any other variants thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such process, method, article or device. Without more limitations, the elements defined by the statement "include" do not exclude the presence of other identical elements in the process, method, article or device including the elements.

[0028] The acquisition, storage, use, processing, etc. of data (including but not limited to features, information, etc. in this paper) in the technical solutions of the present application comply with the relevant provisions of national laws and regulations. In order to solve the above technical problems, the present application provides a task processing method and device, a computer device and a storage medium.

[0029] An artificial neural network (Artificial Neural Networks) is a mathematical model that simulates the neurons of the human brain and the interconnections between the neurons, and it is one of the most important and commonly used models in the field of artificial intelligence. The neural network model is composed of a large number of artificial neurons (Artificial Neuron), each neuron receives input signals from other neurons, and processes the signals through an activation function, and then transmits the results to the next layer of neurons. A neural network is usually composed of multiple layers, each layer contains a number of neurons. The neural network is trained through input samples, and the connection weights between neurons are adjusted through a back propagation algorithm, so that the model can gradually learn the rules and characteristics of the data, so as to realize classification, regression, clustering and other tasks. At present, neural networks have a wide range of applications in machine learning and deep learning.

[0030] In the related art, the scheduling technology based on load prediction is usually used to predict the future load situation by using historical data and machine learning algorithms, and to dynamically schedule resources to meet the needs of users. This technology can improve resource utilization and system performance, and usually includes the following processes: data collection, i.e. collecting monitoring data of the system at the edge device and the remote (cloud computing center), including the utilization rate of central processor, memory usage, network traffic, etc.; data processing, i.e. processing and analyzing the collected data, using statistical and machine learning algorithms, etc. to establish a load prediction model, and training and optimizing the model to improve prediction accuracy and accuracy; load prediction, i.e. predicting the future load situation according to the model and historical data, obtaining the load trend and load peak in the future period, etc.; resource scheduling, i.e. dynamically scheduling the resources of edge devices and cloud to meet the future load demand, when the future load is predicted to increase, the system can allocate tasks to more edge devices or cloud resources to improve system performance and reliability, when the future load is predicted to decrease, the system can appropriately reduce the allocation and use of resources to avoid waste of resources and increase of cost; monitoring and feedback, i.e. real-time monitoring and feedback of the scheduling result, timely adjusting and optimizing the resource allocation and scheduling strategy of the system to adapt to the changing load demand and system environment.

[0031] However, the above-mentioned scheduling technology based on load prediction has the following disadvantages: inaccurate prediction, i.e. the accuracy of load prediction is difficult to guarantee due to the influence of various factors such as sudden events and changes in user behavior; poor real-time performance, i.e. load prediction needs to analyze and process historical data, which requires a certain amount of time, and real-time performance is one of the important indicators of cloud edge computing, so the real-time performance of the prediction result may be limited; moreover, load prediction needs a period of time to analyze and process historical operation data, and real-time performance is one of the important indicators of cloud edge computing, so the real-time performance of resource scheduling is affected; single scheduling strategy, i.e. the scheduling technology based on load prediction usually only considers the future load situation, ignoring other factors such as user experience and resource utilization, so it may not achieve optimal resource scheduling and task allocation.

[0032] Based on this, this application focuses on optimizing the load prediction-based scheduling technology from the above three perspectives. By analyzing the task information of the task and the device information of the edge device, the real-time performance and prediction accuracy can be improved. Furthermore, by dividing the task into more detailed parts, the scheduling execution strategy is enriched, which improves the efficiency of task unloading and execution according to the scheduling execution strategy, thereby improving the overall quality of service (QoS) of the user.

[0033] The following will be combined with the appendix Figures 1 to 6 This application describes in detail the task processing method, apparatus, computer equipment, and storage medium of the embodiments thereof.

[0034] It should be noted that these embodiments are not intended to limit the scope of this application.

[0035] Therefore, in order to better illustrate the content of the embodiments of this application, the following will be combined with... Figure 1 The following describes a task processing method provided in an embodiment of this application.

[0036] Figure 1 This is a flowchart of a task processing method provided in an embodiment of this application.

[0037] like Figure 1 As shown, this task processing method can be applied to any of the devices in the embodiments of this application. Here, the first device is used as an example for illustration. The task processing method may specifically include the following steps:

[0038] Step 110: Obtain task information and edge device information. The task information includes first information, which characterizes the task's tolerance for task latency. The device information includes second and third information, whereby the second information characterizes the remaining resources of the edge device and the third information characterizes the computing power of the edge device. Step 120: Based on the task information and device information, determine the task's scheduling and execution strategy. The scheduling and execution strategy includes a first scheduling and execution strategy where the task is executed by the edge device, a second scheduling and execution strategy where the task is executed by the base station connected to the edge device, a third scheduling and execution strategy where the task is executed by both the edge device and the base station, or a fourth scheduling and execution strategy where the task is executed by a computing node connected to the base station. Step 130: Process the task according to the scheduling and execution strategy.

[0039] Thus, the remaining resource amount and the computing capability of the edge device capable of executing the task are used to determine the scheduling execution strategy of the task, considering the tolerance of the task to the task delay time, so as to minimize the task completion time, ensure the real-time processing of the task, improve the task allocation efficiency, and allocate the task to various objects capable of executing the task, such as only the edge device, only the base station, both the edge device and the base station, or the computing processing connected to the base station, so as to effectively improve the task processing efficiency and further improve the resource scheduling efficiency.

[0040] The above steps are described in detail as follows.

[0041] Firstly, the task information of the task and the device information of the edge device are acquired, the task information includes the first information used to represent the tolerance of the task to the task delay time, and the device information includes the second information used to represent the remaining resource amount of the edge device and the third information used to represent the computing capability of the edge device.

[0042] Thus, the remaining resource amount and the computing capability of the edge device capable of executing the task are used to determine the scheduling execution strategy of the task, considering the tolerance of the task to the task delay time, so as to minimize the task completion time, ensure the real-time processing of the task, improve the task allocation efficiency, and allocate the task to various objects capable of executing the task, such as only the edge device, only the base station, both the edge device and the base station, or the computing processing connected to the base station, so as to effectively improve the task processing efficiency and further improve the resource scheduling efficiency.

[0043] The steps involved in the task processing method in the embodiments of the present application are described in detail as follows.

[0044] The task processing method in the embodiments of the present application can be applied to a task processing system including an edge device, a base station connected to the edge device, and a computing node connected to the base station before the device information of the edge device is acquired.

[0045] The task processing system in the embodiments of the present application can include multiple edge devices, base stations and computing nodes, and is a complex system composed of a cloud computing center, edge devices, a network, base stations, computing nodes and service management, etc.

[0046] Among the entire task processing system, each edge device is connected with a base station that provides services for it at all times, each base station is configured with an edge server having different computing capabilities to enable it to provide computing or storage services as an edge device. Among the entire edge computing system, in addition to the base stations configured with edge servers, there are also some small edge devices, which can be composed of some idle home routers, cell machine rooms, idle small servers, etc. These nodes are not directly deployed on the base station, but can be connected with the base station through 5G or wired network, etc. and serve as a supplement to edge computing resources. In addition, there are a small part of large cloud computing centers, which can provide powerful computing or storage capabilities.

[0047] Based on this, use to represent the set of all devices in the task processing system, which includes M devices, which can be cloud computing centers, edge devices, base stations connected with edge devices, computing nodes connected with base stations, etc. The computing nodes can include computing nodes connected with base stations, i.e. mobile devices such as mobile phones, tablet computers, etc., wherein satisfy the following formula:

[0048]

[0049] Each device in the set has different computing capabilities FM. For example, the system contains s base stations with edge computing capabilities and connected with edge devices, and satisfies s < M. In addition, each base station serves Ns computing nodes, which can be described as the following formula:

[0050]

[0051] Based on this, the number of computing nodes served by each base station is different and changes at any time, which also conforms to the characteristics of the mobile edge cloud scenario. The computing nodes are connected with the base stations through 5G technology, etc. to forward the task request to the base station with computing or storage capability for processing, and when the computing or storage capability of the base station is insufficient to support the completion of the task, it will select the task offloading mode to forward it to the remaining computing nodes for execution.

[0052] For all computing nodes n, the following formula (1) is satisfied:

[0053]

[0054] wherein each computing node has a corresponding task satisfying the following formula (2):

[0055]

[0056] wherein a n represents the task data volume of the task included in the task information, d n represents the number of required processor cycles, represents the first information. In some embodiments of the present application, it is assumed that the output data size of the task is much smaller than the task data volume.

[0057] Based on this, the step 110 can specifically include:

[0058] A fixed frequency or time interval is set between the cloud computing center and the edge device (and between the edge device and the base station connected thereto), and through the ping tool, the network delay, transmission time, and other two-way information between the cloud computing center and the edge device (and between the edge device and the base station connected thereto) are continuously collected, as well as the edge device, base station, and other self information such as device information representing the remaining resource volume of the edge device, representing the computing capability of the edge device, and the remaining resource volume of the base station, and the collected information is saved in a database, providing data support for subsequent neural network model training and determination of scheduling execution strategy.

[0059] Based on the foregoing task processing system, the embodiments of the present application model and predict the device information between the edge device, the base station connected thereto, and the computing node connected to the base station, and the network status data between the foregoing edge device, base station, and computing node through neural network technology, and determine the task allocation of the cloud computing center, edge device, base station, and computing node according to the monitored task information such as real-time resource requirements of the application program, including computing, storage, and network resources, so as to dynamically adjust the task offloading scheme, optimize the scheduling resource strategy of task offloading and resource scheduling, and improve the service quality of the electronic device while ensuring the performance index requirements such as real-time performance of the current application program.

[0060] In the process of edge device and cloud computing center collaboration, frequent data exchange and collaboration between edge device and cloud are usually required, therefore, network condition will directly affect the effectiveness and real-time performance of multi-party collaboration (such as edge device and base station, at least two base stations, base station and computing node connected thereto). Specifically, network delay, bandwidth, packet loss rate, network congestion and other factors can affect the effectiveness of multi-party collaboration. If the network delay is high, the time of data transmission between the cloud and the edge device will be longer, thereby affecting the real-time performance and efficiency of collaboration; if the network bandwidth is low, the speed of data transmission will be slow, which will also affect the effectiveness of collaboration; if the network congestion is serious, data packets will be lost or delayed, further affecting the real-time performance and stability of collaboration. Therefore, in order to improve the efficiency of task offloading and resource scheduling strategy, the device information of each party device itself and the network condition of multi-party data transmission need to be monitored and optimized in real time, a series of measures are taken to improve the network bandwidth, reduce the delay, reduce the packet loss rate and alleviate the network congestion, so as to ensure the efficiency and stability of data transmission.

[0061] The change law of the network depends on many factors, including network topology, transmission medium, load of network device, packet size and type, etc. These factors are partly determined when the network infrastructure is built, and are unpredictable, and it is difficult to improve or optimize these influencing factors from a technical point of view, unless through facility upgrade or hardware modification. However, in the long run, there may be some regular changes in network condition. For example, another part of the influencing factors of network condition, such as network delay and network traffic, may have obvious fluctuations in certain time periods, such as working hours and off-work hours, weekdays and non-weekdays, etc., and the regularity of these fluctuations may affect the network condition. In addition, some specific events, such as network attacks, weather, etc. may also affect the network condition. Through analysis and modeling of historical data, the possible impact of some events can be predicted, and corresponding measures can be taken to optimize network performance and stability.

[0062] Inspired by this, the embodiments of the present application need to extract the change law hidden in the historical network condition data by monitoring the historical delay, traffic and other device information between the multi-parties (such as edge device and base station, at least two base stations, base station and computing node connected thereto) and the task information of the task, and on this basis, formulate scheduling execution strategy related to task offloading and resource scheduling, optimize task deployment and improve the overall execution efficiency of the system.

[0063] In addition, each device in the task processing system, such as edge device, base station, computing node, has different amount of remaining resources and computing capability f nwherein, in the embodiments of the present application, the second information is used to represent the remaining resource amount of the edge device, the third information is used to represent the computing capability of the edge device, the fourth information is used to represent the remaining resource amount of the base station, and the fifth information is used to represent the computing capability of the base station.

[0064] In the working process of the system, each task can be selected to be executed locally or offloaded to the edge server for execution. For the edge device n, the task execution decision of the device is represented by to satisfy the following formula:

[0065]

[0066] wherein, represents that the task is selected to be executed on the local device, i.e., the edge device, represents that the edge device is selected to offload the task to the base station serving the edge device for execution.

[0067] When the task is selected to be executed locally, if the and respectively represent the execution time and the energy consumption of the task Ln, the two satisfy the following formula (3):

[0068]

[0069] wherein, is the power of the edge device n. When the task is selected to be executed on the server, there are two cases, one is that the task is completely offloaded to the base station for execution, and the other is that the task is partially offloaded to the base station for execution, which will be described in detail below based on the following step 120.

[0070] Step 120 involves step 1201 and step 1202.

[0071] Step 1201, based on the task information and the device information, a scheduling cost function corresponding to an object for executing the task is constructed; wherein the object includes at least one of the following: an edge device, a base station, the scheduling cost function is used to control the target time length for which the task is executed to be less than or equal to a preset associated time length associated with the first information, and control the resource amount of the object after the task is executed to be greater than or equal to a preset resource amount.

[0072] Here, since the scheduling cost function includes different types of scheduling cost functions, at least four ways to determine the scheduling cost function are provided below.

[0073] In some embodiments of the present application, the scheduling cost function includes a first scheduling cost function corresponding to the edge device, the task information further includes a task data amount of the task and a processor cycle number for executing the task, based on which, the step 1201 can specifically include step 12011 and step 12012.

[0074] At step 12011, it is determined whether the edge device performs the task alone according to the task information and the device information.

[0075] Exemplarily, the main goal of task offloading and resource scheduling is to minimize the completion time of tasks. In addition, some characteristics of tasks and edge devices also need to be considered. First, each task has its own maximum execution time. For tasks with lower delay tolerance, they should be executed in a shorter time. Second, the execution of tasks cannot exhaust the remaining energy of mobile terminals. In order to combine the above two characteristics into the completion time minimization problem proposed in the embodiments of the present application, a scheduling cost function is defined to comprehensively consider the completion time and energy consumption of tasks, which is described as the following formula (4):

[0076]

[0077] Wherein, T n is the completion time of the task, E n is the consumed resource amount of the task, when the task is selected to be executed locally, and when it is selected to be offloaded to the base station for execution, and wherein and respectively represent the transmission time and transmission energy consumption of the task assigned to the base station server, which can be represented as the following formula (5):

[0078]

[0079] Wherein, r s represents the first transmission information between the edge device and the base station, that is, it includes the rate of the edge device sending the task and the upload rate of the base station sending the complete data of the task (assuming that all devices served by the same base station have the same transmission rate). In the formula, a weight parameter β n is introduced to represent the delay tolerance of task n. The weight parameter satisfies the following formula (6):

[0080]

[0081] By introducing the weight, minimizing the scheduling cost function will make those tasks with lower delay tolerance have smaller task completion time.

[0082] Specifically, the target duration includes a first target duration, the device information further includes a device power of the edge device, and the preset resource amount includes a first preset resource amount. Based on this, the step 12011 can specifically include steps 120111-12013.

[0083] The step 120111 calculates a first target duration for the edge device to execute the task based on the third information, the task data amount, and the number of processor cycles.

[0084] The step 120112 calculates a first consumed resource amount for the edge device to execute the task based on the device power of the edge device and the first target duration.

[0085] The step 120113 determines that the edge device executes the task alone in a case where the first target duration is less than or equal to a preset associated duration associated with the first information and a first remaining resource amount is greater than or equal to the first preset resource amount, the first remaining resource amount being a difference between a remaining resource amount corresponding to the second information and the first consumed resource amount.

[0086] The step 120114 determines that the edge device cannot execute the task alone in a case where the first target duration is greater than the preset associated duration associated with the first information or the first remaining resource amount is less than the first preset resource amount.

[0087] The step 12012 constructs a first scheduling cost function according to the first duration for the edge device to execute the task and the first consumed resource amount for the edge device to execute the task in a case where it is determined that the edge device executes the task alone.

[0088] In some other embodiments of the present application, the scheduling cost function further includes a second scheduling cost function corresponding to the base station and a third scheduling cost function corresponding to the edge device and the base station, the device information further includes first transmission information between the edge device and the base station and base station information of the base station, the first transmission information including a first transmission duration and a first transmission consumed resource amount of the task, and the target duration includes a second target duration, the base station information including fourth information and fifth information, the fourth information being used to represent a remaining resource amount of the base station, and the fifth information being used to represent a computing capability of the base station. Based on this, the step 1201 can specifically include steps 12013 and 12015.

[0089] The step 12013 determines whether the base station executes the task alone according to the task information, the device information, and the base station information of the base station in a case where it is determined that the edge device cannot execute the task alone.

[0090] Further, the base station information further includes a power of the base station, and the preset resource amount includes a second preset resource amount. The step 12013 can specifically include steps 120131-120135.

[0091] In step 120131, the base station is determined to execute the task based on the base station information, the task data volume, and the processor cycle number.

[0092] In step 120132, the second target time length of the base station for executing the task is calculated based on the base station information, the task data volume, the processor cycle number, the first transmission time length of the task between the edge device and the base station, and the second transmission time length of the task between the edge device and the base station.

[0093] In step 120133, the second consumed resource volume of the base station for executing the task is calculated based on the base station power and the second target time length.

[0094] In step 120134, the base station is determined to execute the task alone in a case where the second target time length is less than or equal to the preset associated time length associated with the first information, and the second residual resource volume is greater than or equal to the second preset resource volume, where the second residual resource volume is a difference between the residual resource volume corresponding to the fourth information and the second consumed resource volume.

[0095] In step 120135, the base station is determined to be unable to execute the task alone in a case where the second target time length is greater than the preset associated time length associated with the first information, and the second residual resource volume is less than the second preset resource volume.

[0096] In step 12014, the second scheduling cost function is constructed based on the second target time length of the base station for executing the task and the second consumed resource volume of the base station for executing the task in a case where the base station is determined to execute the task alone.

[0097] In step 12015, the third scheduling cost function is constructed based on the third target time length of the edge device for executing the task and the third consumed resource volume of the base station for executing the task, and the fourth target time length of the base station for executing the task and the fourth consumed resource volume of the base station for executing the task in a case where the base station is determined to be unable to execute the task alone.

[0098] Exemplarily, in addition, there are two special cases in the system running process. One is that the task completion time is greater than the delay tolerance. The other is that the execution of the task exhausts the residual energy of the device (the edge device, the base station, or the computing node). In these two special cases, the task will fail and generate a constant cost φ. Obviously, when the task fails, it is unacceptable to the user, and therefore, in the assumption, φ is set to a value much greater than the normal cost β. n T n

[0099] According to the above description, in the embodiments of the present application, the task offloading problem of the system can be represented as a cost minimization problem, that is, the scheduling execution strategy of the task can be determined by the following formula (7):

[0100]

[0101] ​and satisfy the following constraints:

[0102]

[0103] where x, e, y represent the offloading decision, server selection and allocated computing resource respectively. C1 represents that the task can only be executed on the local edge device or offloaded to execute, C2 and C4 represent that the task is offloaded or partially offloaded to the unique base station to execute respectively, wherein, represents full offloading, and P represents partial offloading. C3 and C5 respectively ensure that the computing resource allocated to each task or instruction is greater than or equal to 0, and C6 is used to ensure that the computing resource required by each base station allocated to the task does not exceed the total computing capacity that the base station can provide.

[0104] Thus, when the energy consumption or computing capacity of the local edge device is insufficient to support the execution of the entire task, the task processing system will first select to offload the task to the base station equipped with small edge computing capacity for execution, because during the entire system operation process, the edge device and the base station providing services for it have established stable contact, and the task is preferentially offloaded to the base station for execution, which can effectively reduce the cost overhead generated by re-establishing the connection between the device and the server. During the task offloading process, data transmission will generate additional time overhead. If it is assumed that the propagation rate between the edge device and the base station is R, then the transmission time satisfies: n / R. Due to the development of wireless network technologies such as 5G, the propagation rate is usually close to the speed of light, so the additional time generated by task offloading can be ignored. According to this assumption, the time for the task to be offloaded to the base station for execution and processing can be shown by the following formula (8):

[0105]

[0106] wherein represents the computing resource allocated to the task L n offloaded to the selected base station.

[0107] Based on this, the base station is connected to the power grid and has sufficient energy support for task execution, so it does not need to consider the energy consumption of the edge server of the base station, but when the computing capacity of the base station is also insufficient to complete the execution of the entire task, it needs to offload the task to the nearby computing node for execution through the 5G network, and in this process, the transmission time of the task is also ignored. However, for the base station, it has different transmission delays between different computing nodes. Some nearby computing nodes may have a large network delay between the computing nodes due to network congestion, bandwidth limitation, network topology and other factors. At this time, the nearby computing node also does not necessarily have good network conditions. In this case, if the task is offloaded from the base station to the computing node for execution, it may not be the current optimal offloading strategy. Real-time monitoring of the current network conditions and selecting the server for task offloading according to the current monitoring results is not the optimal solution for computing or storage resource-limited computing nodes, and the measurement of the delay will produce a huge workload with a complexity of o(n 2 ) which will result in a large cost overhead. The fluctuation of the network conditions has a traceable pattern under certain circumstances, and the network delay is closely related to the human life pattern to a certain extent. By sampling and analyzing the historical network conditions between nodes, the computing node with the optimal network conditions at present can be predicted in advance, and the task can be offloaded to the target computing node according to the predicted results. The neural network can model the complex dependence relationship in the historical data and be used for predicting future data, which is helpful for the current optimal task offloading and resource scheduling strategy of the embodiments of the present application, so the embodiments of the present application adopt this technology to optimize the task offloading and execution. The detailed model design is introduced below.

[0108] In this scheme, the task L n can be decomposed into W n sub-instructions, which can be represented as and these sub-instructions satisfy the following condition formula (9):

[0109] L n,w ={a n,w ,d n,w ,e n,w} (9)

[0110] Where a n,w is the size of the sub-instruction input data, d n,w is the number of processor cycles required by the sub-instruction, and e n,w represents the base station decision of the instruction. In this case, in addition to the sub-instructions generated by the division of the task, an additional instruction L n,0 is needed to represent the results generated by all sub-instructions. The instruction satisfies L n,0 ={y n,0T n,0},where y n,0 is the required computing resource of instruction L n,0 , T n,0 represents the execution time.

[0111] Since the propagation time between devices, such as the edge device and the base station, and the base station and the computing node, is ignored, the total processing time can be represented by the following formula (10):

[0112]

[0113] where, is the computing resource provided by the base station e n,w on which the instruction L n,w is offloaded, each sub-instruction L n,w can be executed independently and synchronously, and thus the execution time is the sum of the maximum execution time of the sub-instructions and the execution time of the result collection instruction.

[0114] In some embodiments of the present application, the scheduling cost function further includes a fourth scheduling cost function corresponding to the computing node connected to the base station; the device information further includes first transmission information between the edge device and the base station, second transmission information between the base station and the computing node, and node information, the second transmission information including a second transmission duration and a second transmission resource consumption of the task, the node information including sixth information and seventh information, the sixth information being used to represent the residual resource amount of the computing node, and the seventh information being used to represent the computing capability of the computing node; and the target duration includes a fifth target duration, based on which the step 1201 can specifically include a step 12016 and a step 12017.

[0115] In the step 12016, in a case where it is determined that the base station cannot execute the task alone and the edge device and the base station cannot execute the task in combination, the target computing node for executing the task is extracted from the computing nodes connected to the base station based on the task information and the device information through the neural network model.

[0116] For example, the process of training the neural network model can refer to Figure 2The workload data including the device information of each party (the edge device, the base station connected with the edge device, and the computing node connected with the base station) and the task information of the task is respectively input into the embedding layer (encoder), the standard template library (STL), and the embedding layer (decoder). The embedding layer (encoder) encodes the workload data, so that the vector output by the embedding layer (encoder) can be input into the encoder layer to be recognized by the encoder layer. The embedding layer (decoder) decodes the input workload data, so that the vector output by the embedding layer (decoder) can be input into the decoder layer to be recognized by the decoder layer. The STL layer provides the data structure and the calculation algorithm for the embedding layer (encoder) and the embedding layer (decoder) based on the workload data, so that the embedding layer (decoder) decodes the workload data through the data structure and the calculation algorithm, and the embedding layer (encoder) encodes the workload data through the data structure and the calculation algorithm, so that the decoded data and the encoded data are input into the decoder layer, the fused data is decoded again through the encoder layer, and the computing node corresponding to the base station that can process the task is output through the output layer. At this time, Figure 2 The edge node with the best network condition with the current base station shown in the above embodiment is the target computing node that executes the task.

[0117] In step 12017, a fourth scheduling cost function is constructed based on the fifth target duration for the target computing node to execute the task and the fifth consumed resource amount for the target computing node to execute the task.

[0118] In step 1202, a scheduling execution strategy of the task is generated through the scheduling cost function.

[0119] Specifically, based on the above-mentioned step 1201 involved in some embodiments of the present application, the scheduling cost function includes a first scheduling cost function corresponding to the edge device, and the first scheduling cost function is used to indicate that the edge device executes the task alone. The scheduling execution strategy includes a first scheduling execution strategy. The step 1202 can include step 12021 and step 12022.

[0120] In step 12021, the resource amount and the computing capability resource for the edge device to execute the task are allocated based on the first scheduling cost function.

[0121] In step 12022, the first scheduling execution strategy is generated based on the computing resource allocated for the edge device to execute the task in a case where it is determined that the task is completely allocated.

[0122] In addition, based on another embodiment of the present application involved in the above step 1201, the scheduling cost function comprises a second scheduling cost function corresponding to the base station connected with the edge device, the second scheduling cost function is used to represent that the base station performs the task alone, and the scheduling execution strategy comprises a second scheduling execution strategy, based on which, the step 1202 can specifically comprise a step 12023 and a step 12024.

[0123] The step 12023 comprises: constructing a first instruction based on the second scheduling cost function, the first instruction carrying the task and the second scheduling cost function, and the first instruction being used to instruct the base station to allocate resource quantity and computing capability resource for performing the task based on the second scheduling cost function.

[0124] The step 12024 comprises: sending the first instruction to the base station as the second scheduling execution strategy.

[0125] In addition, based on another embodiment of the present application involved in the above step 1201, the scheduling cost function comprises a third scheduling cost function corresponding to the edge device and the base station, the second scheduling cost function is used to represent that the edge device and the base station perform the task cooperatively, and the scheduling execution strategy comprises a third scheduling execution strategy, based on which, the step 1202 can specifically comprise a step 12025 and a step 12027.

[0126] The step 12025 comprises: dividing the task based on the task information and the device information to obtain a first type of sub-instruction and a second type of sub-instruction, the first type of sub-instruction comprising N sub-instructions, the second type of sub-instruction comprising M sub-instructions, N being a positive integer, and M being a positive integer.

[0127] The step 12026 comprises: constructing a second instruction and a third instruction according to the third scheduling cost function, the second instruction carrying a first type of sub-task and the third scheduling cost function, the second instruction being used to instruct the edge device to allocate resource quantity and computing capability resource for performing the task based on the third scheduling cost function, and the third instruction carrying a second type of sub-task and the third scheduling cost function, the third instruction being used to instruct the base station to allocate resource quantity and computing capability resource for performing the task based on the third scheduling cost function.

[0128] The step 12027 comprises: sending the second instruction and the third instruction to the base station as the third scheduling execution strategy.

[0129] In addition, based on another embodiment of the present application involved in the above step 1201, the scheduling cost function comprises a fourth scheduling cost function corresponding to a computing node connected with the base station, the fourth scheduling cost function is used to represent that the edge device and the base station cannot be combined to perform the task and the base station cannot perform the task alone, and the scheduling execution strategy comprises a fourth scheduling execution strategy, based on which, the step 1202 can specifically comprise a step 12028 and a step 12029.

[0130] At step 12028, a fourth instruction is constructed based on the fourth scheduling cost function, the fourth instruction carrying the forwarding instruction, the task, and the fourth scheduling cost function, the fourth instruction being used for the computing node connected with the base station to allocate the resource amount and the computing capability resource for executing the task based on the fourth scheduling cost function, the forwarding instruction being used for instructing the base station to send the task and the fourth scheduling cost function to the computing node.

[0131] At step 12029, the fourth instruction is sent to the base station as the fourth scheduling execution strategy.

[0132] Therefore, the above step 120 is described in detail below in combination with the content shown in Figure 3

[0133] The scheduling strategy, and the task processing method provided by the embodiment of the present application can be applied to processing the request from the edge device in the 5G edge cloud (Multi-access Edge Computing, MEC) scenario. On one hand, when the energy, computing capability, etc. of the edge device meet the demand of the task, the task can be executed locally. When the edge device is insufficient to provide the resource required for executing the task, the edge device will first select to offload the task to the base station which is always connected with the edge device and provides services for the edge device, and execute the task on the base station. The task offloading is divided into partial offloading and complete offloading. When the base station is also insufficient to provide the resource required for executing the task, the base station will offload the task to other edge devices through the 5G technology to execute the task, so as to complete all the tasks.

[0134] Here, the object for executing the task can be predicted by the proposed neural network model (for example, the neural network prediction model shown in Figure 2 , so as to select the edge device with the best network condition (with the minimum transmission delay between the edge device and the base station) to execute the task. In this process, the following two key problems need to be considered. First, how to make a decision between the partial offloading and the complete offloading of the task; second, how to select the edge device to assist in executing the task when the base station resource is insufficient.

[0135] In order to better describe the adaptive cloud-edge task offloading and resource scheduling technology based on the neural network proposed by the embodiment of the present application, the task offloading decision-making and scheduling algorithm are described below.

[0136] As shown in Figure 3 , for each base station , the set of devices served by the base station is determined , and the weight φ of each device is allocated according to the delay tolerance of the task n ; the resources Δ of the devices are allocated in ascending order according to the task weight n ​, until all tasks are assigned or the resources of the base station are insufficient to perform the remaining tasks; repeat the above process cycle until all base station device assignments are complete.

[0137] Next, consider performing the above unexecuted tasks by partial offloading;

[0138] For each unexecuted task, if the task can be executed by partial offloading on the local device and the base station respectively, divide the task Li into sub-instructions Li,w; further divide the sub-instructions into {Li,1, Li,2,... Li,j} and {Li,j+1, Li,j+2,... Li,w}, and satisfy j

[0139] wherein the weight φ n is calculated by the following formula (11):

[0140]

[0141] The Δ n is the minimum computing resource required for task execution, and satisfies the following formula (12):

[0142]

[0143] However, due to the limited resources of each base station, there may be some tasks that are not completely offloaded for execution. Therefore, the task instructions can be split to be executed locally on the edge device and synchronously on the base station. Because partial task offloading will generate additional instructions, additional resources and time are required for execution. Therefore, each sub-instruction has its minimum required resource Δ n,w , which can be specifically shown in the following formula (13).

[0144]

[0145] When the computing resources required by the task exceed the sum of the resources that the local device and the base station can provide, the device will completely offload the task to other computing nodes for execution through 5G or other means. This process will be selected according to the prediction results of the neural network model, and T n satisfies the following formula (14):

[0146]

[0147] in, and These represent the processing time required for the task to be offloaded to the base station and for the task to be executed on the computing nodes predicted by the neural network, respectively. Since the base station and computing nodes are connected to the power grid and have sufficient energy to support task execution and offload tasks from the base station to other edge devices, the energy consumption on the base station and computing nodes does not need to be considered. Therefore, the total energy consumption of the device meets the requirements. This represents the round-trip time taken by the base station to offload a task to other edge devices. This time consists of propagation delay, transmission delay, queuing delay, and processing delay. The propagation delay is negligible as it approaches the speed of light, while the other delays are usually affected by network conditions and fluctuate. Selecting appropriate edge devices to execute tasks is crucial for optimizing task scheduling.

[0148] In order to select appropriate base stations and / or computing devices to perform tasks, the system will collect and update the network status between computing devices in real time during the task offloading process, and train the neural network prediction model through continuously updated data, thereby improving the prediction accuracy of the model and selecting the optimal edge device to perform the task.

[0149] The neural network prediction model in this application assumes that when neither the mobile device (edge ​​device) nor the base station connected to it can provide the computing resources required for task execution, the edge device offloaded by the base station has sufficient resources to execute the task. and These represent the time taken for the task to be offloaded from the device to the base station and the time taken for the task to be executed on the computing node, respectively. These metrics are determined by the nature of the task and the capabilities of the device, and are independent of the network conditions between the base station and the computing node. Therefore, the neural network model provided in this application primarily focuses on the task completion time T. n In Optimization is performed by selecting the best computation node (with the minimum...) This reduces the task completion time T. n Reduce the time required to optimize the overall task completion time.

[0150] Over the long term, most networks can experience diurnal differences, weekday and weekend changes, etc. at different times of the day. For example, a network can experience higher latency during working hours, and relatively lower latency during non-working hours. In addition, some networks can experience periodic fluctuations, which can be related to periodic operations such as specific tasks, regular maintenance, backups, etc. The regularity of these fluctuations can affect network conditions. In addition, some specific events, such as network attacks, weather, etc. can also affect network conditions, and such changes are usually unplanned and require timely troubleshooting and repair. By analyzing and modeling historical data, the possible impact of certain events can be predicted, and appropriate measures can be taken to optimize the scheduling strategy of the task.

[0151] In order to reasonably utilize the regularity and seasonal factors in network latency changes, the embodiments of the present application provide a STL (Seasonal-Trend decomposition using LOESS) method to extract seasonal data from historical network conditions. It is a method for decomposing time series data into trend, seasonality and residual three parts. The STL method smoothes the data by using local weighted regression (LOESS), and then provides a more detailed understanding of the time series by separating the trend, season and residual. This method is very useful for handling time series data with obvious seasonality and trend.

[0152] As shown in Figure 3 The embodiments of the present application provide a neural network architecture based on transformer to predict workloads, obtain the seasonal components decomposed by STL, and input them into the embedding layers of the encoder and decoder, respectively, which can effectively improve the network condition prediction between base stations and task offloading candidate computing nodes, and thus select the target node for task offloading.

[0153] According to the scheduling algorithm provided by the embodiments of the present application, by monitoring the network conditions between edge devices, base stations and computing nodes in real time, the neural network model provided by the embodiments of the present application is used to predict the computing node with the best task execution condition, and the decision of task offloading is continuously adjusted, so as to achieve the optimization of task cost and realize adaptive cloud-edge task offloading and resource scheduling.

[0154] Therefore, a target function of task offloading and resource scheduling can be determined based on the constraint conditions of the completion time and energy consumption of the task, and an offloading strategy of the task is determined based on the target function. According to whether the energy consumption and the computing resource meet the constraint conditions of the completion time and energy consumption of the task in the target function, a scheme of one of four offloading strategies of task execution by the local device, complete offloading to the base station for execution, partial offloading to the base station for execution, and offloading to the computing node for execution is determined. Then, a transformer model is used to predict a computing node having a good network condition with the current base station. Based on the predicted computing node, the task is offloaded to the computing node for execution.

[0155] In addition, the task processing method provided by the embodiments of the present application can reduce the training cost. The present application adopts a transformer-based neural network for modeling. The embedding layer in the transformer can directly learn features from the original load data without manual feature engineering, which greatly simplifies the design and implementation process of the model. In addition, the scheduling strategy is rich. That is, by considering the resource conditions (such as energy consumption and computing power) of the mobile device and the base station, the task offloading scheme is divided into local execution and offloading execution, which can effectively improve the efficiency of resource scheduling and task allocation. In addition, the real-time performance is high. That is, by continuously collecting the latest network condition information and using the neural network technology to learn the latest network condition in combination with historical data, the real-time performance of the prediction can be effectively improved.

[0156] It should be noted that the task processing method provided by the embodiments of the present application can be applied to the cloud-edge task offloading and resource scheduling technology, which is a research hotspot in the field of cloud computing and edge computing at present and has been widely applied in some application scenarios. At the same time, with the continuous development of artificial intelligence, Internet of Things and other technologies, the market application prospect of the technology is also very broad. In the following aspects, the technical solutions of the present application can be widely applied: 1. Internet of Things: The number of devices in the Internet of Things is large, but the computing power is often limited. Using cloud-edge task offloading and resource scheduling technology, the computing task can be offloaded to the edge device for processing, thereby improving the response speed and stability of the system. 2. 5G communication: The data transmission speed of 5G communication is fast, but the delay is high. By using cloud-edge task offloading and resource scheduling technology, the computing task can be offloaded to the edge device for processing, thereby reducing the delay of data transmission and improving the quality of communication. 3. Internet of Vehicles: The number of vehicles in the Internet of Vehicles is large, but the computing power is limited. By using cloud-edge task offloading and resource scheduling technology, the computing task can be offloaded to the edge device for processing, thereby improving the response speed and stability of the Internet of Vehicles system. 4. Medical care: The medical care field needs to process a large amount of medical data, but often needs to meet the requirements of privacy and security. By using cloud-edge task offloading and resource scheduling technology, sensitive data can be processed locally, reducing the risk of data transmission in the network and improving the security of the system.

[0157] The present application also provides a task processing device, which will be described in detail in combination with Figure 4 .

[0158] Figure 4 is a structural schematic diagram of the task processing device provided by an embodiment of the present application.

[0159] In some embodiments of the present application, Figure 4 the task processing device shown in the figure can be arranged in the computer device provided by the embodiments of the present application.

[0160] As Figure 4 shown, the task processing device 40 can specifically include:

[0161] The acquisition module 401 is configured to acquire task information of a task and device information of an edge device, the task information including first information, the first information being used to represent the tolerance degree of the task to a task delay time, the device information including second information and third information, the second information being used to represent a remaining resource amount of the edge device, and the third information being used to represent a computing capability of the edge device.

[0162] The determining module 402 is configured to determine a scheduling execution strategy of the task based on the task information and the device information, the scheduling execution strategy including a first scheduling execution strategy in which the task is executed by the edge device, a second scheduling execution strategy in which the task is executed by the base station connected to the edge device, a third scheduling execution strategy in which the task is executed by the edge device and the base station, or a fourth scheduling execution strategy in which the task is executed by a computing node connected to the base station.

[0163] The processing module 403 is configured to process the task according to the scheduling execution strategy.

[0164] In this way, the scheduling execution strategy of the task is determined by considering the remaining resource amount and the computing capability of the edge device capable of executing the task and the tolerance of the task to the task delay time, so that the minimization of the task completion time is realized, the task processing real-time is ensured, and the task allocation efficiency is improved. In addition, the task can be allocated to various objects for executing the task, such as only the edge device, only the base station, both the edge device and the base station, or the computing node connected to the base station, so that the efficiency of the task processing is effectively improved, and the resource scheduling efficiency is improved.

[0165] The task processing apparatus 40 in the embodiments of the present application will be described in detail below.

[0166] In some embodiments of the present application, the determining module 402 can be specifically configured to construct a scheduling cost function corresponding to an object for executing the task based on the task information and the device information, wherein the object includes at least one of the edge device and the base station, and the scheduling cost function is used to control the target time length in which the task is executed to be less than or equal to a preset associated time length associated with the first information, and control the resource amount of the object after the task is executed to be greater than or equal to a preset resource amount.

[0167] The scheduling execution strategy of the task is generated by the scheduling cost function.

[0168] In some embodiments of the present application, the determining module 402 can be specifically configured to determine whether the edge device executes the task alone according to the task information and the device information in a case where the scheduling cost function includes a first scheduling cost function corresponding to the edge device and the task information further includes a task data amount of the task and a processor cycle number for executing the task, and construct the first scheduling cost function according to a first time length in which the edge device executes the task and a first consumed resource amount of the edge device for executing the task in a case where it is determined that the edge device executes the task alone.

[0169] In some embodiments of the present application, the determining module 402 can be specifically configured to, in a case where the target time length comprises a first target time length, the device information further comprises a device power of the edge device, and the preset resource amount comprises a first preset resource amount, calculate the first target time length for the edge device to execute the task based on the third information, the task data amount, and the number of processor cycles.

[0170] Calculate the first consumed resource amount for the edge device to execute the task based on the device power of the edge device and the first target time length.

[0171] In a case where the first target time length is less than or equal to a preset associated time length associated with the first information, and the first remaining resource amount is greater than or equal to the first preset resource amount, determine that the edge device executes the task alone, and the first remaining resource amount is a difference amount between the remaining resource amount corresponding to the second information and the first consumed resource amount.

[0172] In a case where the first target time length is greater than the preset associated time length associated with the first information, or the first remaining resource amount is less than the first preset resource amount, determine that the edge device cannot execute the task alone.

[0173] In some embodiments of the present application, the determining module 402, in a case where the scheduling cost function further comprises a second scheduling cost function corresponding to the base station and a third scheduling cost function corresponding to the edge device and the base station, the device information further comprises first transmission information between the edge device and the base station and base station information of the base station, the first transmission information comprises a first transmission time length and a first transmission consumed resource amount of the task, the target time length comprises a second target time length, and the base station information comprises fourth information and fifth information, the fourth information is used to represent a remaining resource amount of the base station, and the fifth information is used to represent a computing capability of the base station, and in a case where it is determined that the edge device cannot execute the task alone, determine whether the base station executes the task alone according to the task information, the device information, and the base station information of the base station.

[0174] In a case where it is determined that the base station executes the task alone, construct the second scheduling cost function according to a second target time length for the base station to execute the task and a second consumed resource amount for the base station to execute the task.

[0175] In a case where it is determined that the base station cannot execute the task alone, construct the third scheduling cost function according to a third target time length for the edge device to execute the task and a third consumed resource amount for the base station to execute the task, and a fourth target time length for the base station to execute the task and a fourth consumed resource amount for the base station to execute the task.

[0176] In some embodiments of the present application, the determining module 402 can be specifically configured to, in a case where the base station information further comprises the power of the base station, and the preset resource amount comprises a second preset resource amount, calculate, based on the base station information, the task data amount, and the number of processor cycles, a basic target duration for the base station to execute the task; calculate, according to the basic target duration and a first transmission duration for the edge device and the base station to transmit the task, a second target duration for the base station to execute the task; calculate, based on the power of the base station and the second target duration, a second consumed resource amount for the base station to execute the task; in a case where the second target duration is less than or equal to a preset associated duration associated with the first information, and a second residual resource amount is greater than or equal to the second preset resource amount, determine that the base station executes the task alone, wherein the second residual resource amount is a difference between a residual resource amount corresponding to the fourth information and the second consumed resource amount; in a case where the second target duration is greater than the preset associated duration associated with the first information, and the second residual resource amount is less than the second preset resource amount, determine that the base station cannot execute the task alone.

[0177] In some embodiments of the present application, the determining module can be specifically configured to, in a case where the scheduling cost function further comprises a fourth scheduling cost function corresponding to a computing node connected with the base station, the device information further comprises first transmission information between the edge device and the base station, second transmission information between the base station and the computing node, and node information, the second transmission information comprises a second transmission duration and a second transmission consumed resource amount of the task, the node information comprises sixth information and seventh information, the sixth information is used to represent a residual resource amount of the computing node, the seventh information is used to represent a computing capability of the computing node, the target duration comprises a fifth target duration, and in a case where it is determined that the base station cannot execute the task alone and the edge device and the base station cannot execute the task in combination, extract, based on the task information and the device information, a target computing node for executing the task from the computing node connected with the base station through the neural network model.

[0178] Construct the fourth scheduling cost function based on a fifth target duration for the target computing node to execute the task and a fifth consumed resource amount for the target computing node to execute the task.

[0179] In some embodiments of the present application, the determining module can be specifically configured to, in a case where the scheduling cost function comprises a first scheduling cost function corresponding to the edge device, the first scheduling cost function is used to represent that the edge device executes the task alone, and the scheduling execution strategy comprises a first scheduling execution strategy, allocate, based on the first scheduling cost function, a resource amount and a computing capability resource for the edge device to execute the task.

[0180] In a case where it is determined that the task is completely allocated, generate the first scheduling execution strategy based on the computing resource allocated for the edge device to execute the task.

[0181] In some embodiments of the present application, the determining module 402 can be specifically configured to, in a case where the scheduling cost function comprises a second scheduling cost function corresponding to a base station connected with the edge device, the second scheduling cost function being used to represent that the base station performs the task alone, the scheduling execution strategy comprises a second scheduling execution strategy, based on the second scheduling cost function, construct a first instruction, the first instruction carrying the task and the second scheduling cost function, the first instruction being used to instruct the base station to allocate an amount of resources and a computing capability resource for performing the task based on the second scheduling cost function;

[0182] The task processing apparatus 40 can further comprise a sending module configured to send the first instruction to the base station as the second scheduling execution strategy.

[0183] In some embodiments of the present application, the determining module 402 can be specifically configured to, in a case where the scheduling cost function comprises a third scheduling cost function corresponding to the edge device and the base station, the second scheduling cost function being used to represent that the edge device and the base station perform the task cooperatively, the scheduling execution strategy comprises a third scheduling execution strategy, based on the task information and the device information, divide the task to obtain a first type of sub-instruction and a second type of sub-instruction, the first type of sub-instruction comprising N sub-instructions, the second type of sub-instruction comprising M sub-instructions, N being a positive integer, M being a positive integer;

[0184] based on the third scheduling cost function, construct a second instruction and a third instruction, the second instruction carrying the first type of sub-task and the third scheduling cost function, the second instruction being used to instruct the edge device to allocate an amount of resources and a computing capability resource for performing the task based on the third scheduling cost function, the third instruction carrying the second type of sub-task and the third scheduling cost function, the third instruction being used to instruct the base station to allocate an amount of resources and a computing capability resource for performing the task based on the third scheduling cost function;

[0185] send the second instruction and the third instruction to the base station as the third scheduling execution strategy.

[0186] In some embodiments of the present application, the determining module 402 can be specifically configured to, in a case where the scheduling cost function comprises a fourth scheduling cost function corresponding to a computing node connected with the base station, the fourth scheduling cost function being used to represent that the edge device and the base station cannot be combined to perform the task and the base station cannot perform the task alone, the scheduling execution strategy comprises a fourth scheduling execution strategy, based on the fourth scheduling cost function, construct a fourth instruction, the fourth instruction carrying a forwarding instruction, the task and the fourth scheduling cost function, the fourth instruction being used to instruct the computing node connected with the base station to allocate an amount of resources and a computing capability resource for performing the task based on the fourth scheduling cost function, the forwarding instruction being used to instruct the base station to send the task and the fourth scheduling cost function to the computing node;

[0187] send the fourth instruction to the base station as the fourth scheduling execution strategy.

[0188] Optionally, as shown in Figure 5 The electronic device 50 provided by the embodiment of the present application includes a processor 501 and a memory 502. The memory 502 stores a program or instruction executable on the processor 501. The program or instruction is executed by the processor 501 to implement the steps of the above-mentioned task processing method embodiment, and the same technical effects can be achieved. To avoid repetition, details are not described herein.

[0189] It should be noted that the electronic device in the embodiment of the present application includes the above-mentioned mobile electronic device and non-mobile electronic device.

[0190] Figure 6 is a structural schematic diagram of a computer device provided by an embodiment of the present application.

[0191] As shown in Figure 6 The computer device can include at least one of the following: an electronic device, a server, involved in the embodiments of the present application. The computer device can include a processor 601 and a memory 602 storing computer program instructions.

[0192] Specifically, the processor 601 can include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or can be configured to implement one or more integrated circuits of the embodiments of the present application.

[0193] The memory 602 can include a mass storage for data or instructions. By way of example and not limitation, the memory 602 can include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive or a combination of two or more of these. Where appropriate, the memory 602 can include removable or non-removable (or fixed) media. Where appropriate, the memory 602 can be internal or external to the integrated gateway disaster recovery device. In certain embodiments, the memory 602 is a non-volatile solid-state memory. In certain embodiments, the memory 602 includes solid-state storage (ROM). Where appropriate, this ROM can be mask-programmed ROM, programmable ROM (PROM), erasable PROM (EPROM), electrically erasable PROM (EEPROM), electrically alterable ROM (EAROM), or flash memory, or a combination of two or more of these.

[0194] The processor 601 reads and executes the computer program instructions stored in the memory 602 to implement any one of the data processing methods in the above-mentioned embodiments.

[0195] In one example, the computer device can further include a communication interface 603 and a bus 610. As shown, the processor 601, the memory 602, and the communication interface 603 are connected and communicate with each other through the bus 610. Figure 6

[0196] The communication interface 603 is mainly used to realize the communication between the modules, devices, units and / or equipment in the embodiments of the present application.

[0197] The bus 610 includes hardware, software or both to couple components of the traffic control device to each other. By way of example, and not limitation, the bus can include an Accelerated Graphics Port (AGP) or other graphics bus, an Enhanced Industry Standard System (ETSA) bus, a Front Side Bus (FSB), a HyperTransport (HT) interconnect, an Industry Standard System (TSA) bus, an InfiniBand interconnect, a Low Pin Count (LPC) bus, a memory bus, a Micro Channel System (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local (VLB) bus, or other suitable bus or combination of two or more of these. Where appropriate, the bus 610 can include one or more buses. Although specific buses are described and shown in the embodiments of the present application, the present application contemplates any suitable bus or interconnect.

[0198] The payment device can perform the data processing method in the embodiments of the present application, thereby realizing the data processing method and device described in combination Figures 1 to 6

[0199] In addition, in combination with the data processing method in the above embodiments, the embodiments of the present application can provide a computer readable storage medium to realize. The computer readable storage medium has computer program instructions stored thereon; the computer program instructions are executed by the processor to realize any one of the data processing methods in the above embodiments.

[0200] It should be clear that the present application is not limited to the specific configurations and processes described above and shown in the drawings. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present application is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between steps, after understanding the spirit of the present application.

[0201] ​​The functional blocks shown in the above structural block diagrams can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, they can be, for example, electronic circuits, ASICs (application specific integrated circuits), appropriate firmware, plug-ins, functional cards, and the like. When implemented in software, the elements of the present application are program or code segments that are used to perform the required tasks. The program or code segments can be stored in a machine-readable medium or transmitted through a data signal carried in a carrier wave over a transmission medium or communication link. The "machine-readable medium" can include any medium that can store or transfer information. Examples of the machine-readable medium include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, optical fiber media, radio frequency (RF) links, and the like. The code segments can be downloaded via a computer network such as the Internet, an intranet, or the like.

[0202] It should also be noted that the exemplary embodiments mentioned in the present application describe some methods or systems based on a series of steps or devices. However, the present application is not limited to the order of the above steps, that is, the steps can be performed in the order mentioned in the embodiments, or in an order different from that in the embodiments, or several steps can be performed simultaneously.

[0203] The above is only a specific implementation of the present application, and those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described systems, modules and units can refer to the corresponding processes in the foregoing method embodiments, which will not be described here. It should be understood that the protection scope of the present application is not limited thereto, and any person skilled in the art can easily think of various equivalent modifications or replacements within the technical scope disclosed in the present application, and these modifications or replacements should be covered within the protection scope of the present application.

Claims

1. A task processing method characterized by, The method comprises: obtaining task information of a task and device information of an edge device, the task information comprising first information used to represent a tolerance degree of the task to a task delay time, and the device information comprising second information used to represent a remaining resource amount of the edge device and third information used to represent a computing capability of the edge device; determining a scheduling execution strategy of the task based on the task information and the device information, the scheduling execution strategy comprising a first scheduling execution strategy in which the task is executed by the edge device, a second scheduling execution strategy in which the task is executed by a base station connected to the edge device, a third scheduling execution strategy in which the task is executed by the edge device and the base station, or a fourth scheduling execution strategy in which the task is executed by a computing node connected to the base station; processing the task according to the scheduling execution strategy.

2. The method of claim 1, wherein, The determining of the scheduling execution strategy of the task based on the task information and the device information comprises: constructing a scheduling cost function corresponding to an object executing the task based on the task information and the device information, wherein the object comprises at least one of the edge device, the base station, and the scheduling cost function is used to control a target time length in which the task is executed to be less than or equal to a preset associated time length associated with the first information, and control a resource amount of the object after the task is executed to be greater than or equal to a preset resource amount; generating the scheduling execution strategy of the task through the scheduling cost function.

3. The method of claim 2, wherein, The scheduling cost function comprises a first scheduling cost function corresponding to the edge device, and the task information further comprises a task data amount of the task and a processor cycle number of executing the task. The constructing of the scheduling cost function corresponding to the object executing the task based on the task information and the device information comprises: determining whether the edge device executes the task alone according to the task information and the device information; in a case where it is determined that the edge device executes the task alone, constructing the first scheduling cost function according to a first time length in which the edge device executes the task and a first consumed resource amount of the edge device executing the task.

4. The method of claim 3, wherein, The target time length comprises a first target time length, and the device information further comprises a device power of the edge device; and the preset resource amount comprises a first preset resource amount. The determining of whether the edge device executes the task alone according to the task information and the device information comprises: calculating a first target time length of the edge device executing the task based on the third information, the task data amount and the processor cycle number; calculating a first consumed resource amount of the edge device executing the task based on the device power of the edge device and the first target time length. In a case where the first target time length is less than or equal to a preset associated time length associated with the first information, and a first remaining resource amount is greater than or equal to a first preset resource amount, the edge device is determined to perform the task alone, the first remaining resource amount being a difference between a remaining resource amount corresponding to the second information and the first consumed resource amount; In a case where the first target time length is greater than the preset associated time length associated with the first information, or the first remaining resource amount is less than the first preset resource amount, the edge device is determined to be unable to perform the task alone.

5. The method of claim 3, wherein, The scheduling cost function further includes a second scheduling cost function corresponding to the base station and a third scheduling cost function corresponding to the edge device and the base station, the device information further includes first transmission information between the edge device and the base station and base station information of the base station, the first transmission information including a first transmission time length and a first transmission consumed resource amount of the task; the target time length includes a second target time length, the base station information includes fourth information and fifth information, the fourth information being used to represent a remaining resource amount of the base station, and the fifth information being used to represent a computing capability of the base station; The constructing, based on the task information and the device information, of the scheduling cost function corresponding to each preset policy of a plurality of preset policies includes: In a case where it is determined that the edge device is unable to perform the task alone, it is determined whether the base station performs the task alone according to the task information, the device information and the base station information of the base station; In a case where it is determined that the base station performs the task alone, the second scheduling cost function is constructed according to a second target time length of the base station performing the task and a second consumed resource amount of the base station performing the task; In a case where it is determined that the base station is unable to perform the task alone, the third scheduling cost function is constructed according to a third target time length of the edge device performing the task, a third consumed resource amount of the base station performing the task, a fourth target time length of the base station performing the task and a fourth consumed resource amount of the base station performing the task.

6. The method of claim 5, wherein, The base station information further includes power of the base station; and the preset resource amount includes a second preset resource amount; The determining, according to the task information, the device information and the base station information of the base station, of whether the base station performs the task alone includes: calculating a basic target time length of the base station performing the task based on the base station information, the task data amount and the number of processor cycles; calculating a second target time length of the base station performing the task according to the basic target time length and a first transmission time length of transmitting the task between the edge device and the base station; calculating a second consumed resource amount of the base station performing the task based on the power of the base station and the second target time length; and calculating a third consumed resource amount of the base station performing the task based on the power of the base station and the fourth target time length. in a case where the second target duration is less than or equal to a preset association duration associated with the first information and a second residual resource quantity is greater than or equal to the second preset resource quantity, it is determined that the base station can perform the task alone, wherein the second residual resource quantity is a difference between a residual resource quantity corresponding to the fourth information and the second consumed resource quantity; in a case where the second target duration is greater than the preset association duration associated with the first information and the second residual resource quantity is less than the second preset resource quantity, it is determined that the base station cannot perform the task alone.

7. The method of claim 3, wherein, The scheduling cost function further includes a fourth scheduling cost function corresponding to a computing node connected to the edge device; the device information further includes first transmission information between the edge device and the base station, second transmission information between the base station and the computing node, and node information, the second transmission information including a second transmission duration and a second transmission consumed resource quantity of the task, the node information including sixth information and seventh information, the sixth information being used to represent a residual resource quantity of the computing node, and the seventh information being used to represent a computing capability of the computing node; The target duration includes a fifth target duration. The constructing, based on the task information and the device information, of the scheduling cost function corresponding to each preset policy of a plurality of preset policies includes: in a case where it is determined that the base station cannot perform the task alone and the edge device and the base station cannot perform the task in combination, a target computing node performing the task is extracted from the computing nodes connected to the base station based on the task information and the device information through a neural network model; The fourth scheduling cost function is constructed based on a fifth target duration in which the target computing node performs the task and a fifth consumed resource quantity in which the target computing node performs the task.

8. The method of claim 2, wherein, The scheduling cost function includes a first scheduling cost function corresponding to the edge device, the first scheduling cost function being used to represent that the edge device performs the task alone, and the scheduling execution strategy includes a first scheduling execution strategy; The generating, through the scheduling cost function, of the scheduling execution strategy of the task includes: based on the first scheduling cost function, a resource quantity and a computing capability resource are allocated for the edge device to perform the task; in a case where it is determined that the task is fully allocated, the first scheduling execution strategy is generated based on the computing resource allocated for the edge device to perform the task.

9. The method of claim 2, wherein, The scheduling cost function includes a second scheduling cost function corresponding to a base station connected to the edge device, the second scheduling cost function being used to represent that the base station performs the task alone, and the scheduling execution strategy includes a second scheduling execution strategy; The generating, through the scheduling cost function, of the scheduling execution strategy of the task includes: based on the second scheduling cost function, a first instruction is constructed, the first instruction carrying the task and the second scheduling cost function, the first instruction being used to instruct the base station to allocate a resource quantity and a computing capability resource for performing the task based on the second scheduling cost function; and in a case where it is determined that the base station cannot perform the task alone and the edge device and the base station cannot perform the task in combination, a target computing node performing the task is extracted from the computing nodes connected to the base station based on the task information and the device information through a neural network model; The fourth scheduling cost function is constructed based on a fifth target duration in which the target computing node performs the task and a fifth consumed resource quantity in which the target computing node performs the task. The first instruction is sent to the base station as the second scheduling execution strategy.

10. The method of claim 2, wherein, The scheduling cost function comprises a third scheduling cost function corresponding to the edge device and the base station, the second scheduling cost function is used to represent that the edge device and the base station cooperatively execute the task, and the scheduling execution strategy comprises a third scheduling execution strategy; The scheduling execution strategy of the task is generated through the scheduling cost function, comprising: Based on the task information and the device information, the task is divided to obtain a first type of sub-instruction and a second type of sub-instruction, the first type of sub-instruction comprises N sub-instructions, the second type of sub-instruction comprises M sub-instructions, N is a positive integer, and M is a positive integer; According to the third scheduling cost function, a second instruction and a third instruction are constructed, the second instruction carries the first type of sub-task and the third scheduling cost function, and the second instruction is used to instruct the edge device to allocate resource quantity and computing power resource for executing the task based on the third scheduling cost function, the third instruction carries the second type of sub-task and the third scheduling cost function, and the third instruction is used to instruct the base station to allocate resource quantity and computing power resource for executing the task based on the third scheduling cost function; The second instruction and the third instruction sent to the base station are used as the third scheduling execution strategy.

11. The method of claim 2, wherein, The scheduling cost function comprises a fourth scheduling cost function corresponding to a computing node connected with the base station, the fourth scheduling cost function is used to represent that the edge device and the base station cannot combine to execute the task and the base station cannot execute the task alone, and the scheduling execution strategy comprises a fourth scheduling execution strategy; The scheduling execution strategy of the task is generated through the scheduling cost function, comprising: Based on the fourth scheduling cost function, a fourth instruction is constructed, the fourth instruction carries a forwarding instruction, the task and the fourth scheduling cost function, and the fourth instruction is used to instruct the computing node connected with the base station to allocate resource quantity and computing power resource for executing the task based on the fourth scheduling cost function, and the forwarding instruction is used to instruct the base station to send the task and the fourth scheduling cost function to the computing node; The fourth instruction sent to the base station is used as the fourth scheduling execution strategy.

12. A task processing apparatus characterized by comprising: Comprise: An acquisition module is used to acquire task information of a task and device information of an edge device, the task information comprises first information, the first information is used to represent the tolerance degree of the task to task delay time, the device information comprises second information and third information, the second information is used to represent the remaining resource quantity of the edge device, and the third information is used to represent the computing power of the edge device. determining, based on the task information and the device information, a scheduling execution policy of the task, the scheduling execution policy comprising a first scheduling execution policy in which the task is executed by the edge device, a second scheduling execution policy in which the task is executed by a base station connected to the edge device, a third scheduling execution policy in which the task is executed by the edge device and the base station, or a fourth scheduling execution policy in which the task is executed by a computing node connected to the base station; processing the task according to the scheduling execution policy.

13. A computer device, comprising: The device comprises a processor and a memory storing computer program instructions. The processor executes the computer program instructions to implement the task processing method according to any one of claims 1-11.

14. A computer program product, characterised in that, The program product is stored in a non-transitory storage medium, and the program product is executed by at least one processor to implement the steps of the task processing method according to any one of claims 1-11.