A task scheduling method, device, apparatus and storage medium

By utilizing scheduling nodes to rationally allocate hardware resources in the catering industry's business scenarios, the problem of huge hardware resource demands has been solved, achieving efficient utilization of hardware resources and reducing operation and maintenance costs.

CN115080212BActive Publication Date: 2026-02-27上海明胜品智人工智能科技有限公司
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210771504.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-30
Publication Date
2026-02-27
Estimated Expiration
2042-06-30

AI Technical Summary

Technical Problem

In business scenarios such as catering, different computer vision models need to be trained and applied based on hardware resources, resulting in huge hardware resource requirements, increased operation and maintenance costs, and low scheduling efficiency.

Method used

The scheduling node receives pending tasks from the task submission node, determines the target task scheduling strategy based on the number of tasks and the number of idle processing nodes, rationally allocates hardware resources, realizes parallel or serial processing, and reduces redundant configuration of hardware resources.

Benefits of technology

It saves the hardware resources required for each task submission node, reduces operation and maintenance costs, and improves the efficiency of task scheduling.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115080212B_ABST
    Figure CN115080212B_ABST
Patent Text Reader

Abstract

The application provides a task scheduling method and device, equipment and a storage medium. The scheduling method comprises: receiving a plurality of tasks submitted by a plurality of task submission nodes; determining a target task scheduling strategy from a plurality of preset task scheduling strategies according to the number of tasks and the number of idle processing nodes in an idle state in the plurality of task processing nodes; and assigning a target task processing node for processing each received task from the plurality of task processing nodes according to the target task scheduling strategy. Thus, the application can save the hardware resources required to be landed on the user terminal corresponding to each task submission node during the task scheduling process, thereby reducing the operation and maintenance cost consumed during the task scheduling process and improving the scheduling efficiency of the tasks.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of machine learning, in particular to a task scheduling method and device, equipment and a storage medium. BACKGROUND

[0002] With the development of industry intelligence, more and more industries choose to land a business model according to their own business needs in actual business scenarios to solve different sub-business needs in the business scenario, so as to use the trained business model to solve various business needs that may occur in the actual operation process of the business scenario. For example, taking the catering industry as an example, a catering enterprise can land and deploy various computer vision models (such as a computer vision model for identifying the raw and cooked degree of dishes, a computer vision model for identifying the completeness of dish ingredients, etc.) in actual catering business scenarios to solve different business needs that may occur in the operation process of the catering enterprise and improve the operation efficiency of the catering enterprise.

[0003] At present, taking the above-mentioned catering business scenario as an example, different types of computer vision models landed in the catering business scenario are used to perform different model application tasks (such as identifying the raw and cooked degree of dishes, identifying the completeness of dish ingredients, etc.), and before actual application, different computer vision models also need to perform their own model training tasks based on different labeled sample data. At this time, since different model application tasks and different model training tasks need to be based on hardware resources (such as processors, computers, etc.) to be implemented, the hardware resources that need to be landed at each independent business scenario are very large. SUMMARY

[0004] Therefore, the purpose of the present application is to provide a task scheduling method, device, equipment and storage medium, which allocates hardware resources capable of executing a processing task to each independent task submission node submitted by the processing task through task scheduling, so as to save the hardware resources that need to be landed at the user terminal corresponding to each task submission node in the task scheduling process, which is conducive to reducing the operation and maintenance cost consumed in the task scheduling process and improving the scheduling efficiency of the processing task.

[0005] In a first aspect, an embodiment of the present application provides a task scheduling method, which is applied to a scheduling node; the scheduling method comprises:

[0006] receiving a processing task submitted by a plurality of task submission nodes; wherein the processing task comprises a model training task in a target business scenario and / or a model application task in the target business scenario;

[0007] determine, from the plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches the number of the received tasks, wherein the task scheduling performance is related to the number of the received tasks that each idle processing node needs to process in the target task scheduling strategy;

[0008] allocate, according to the target task scheduling strategy, a target task processing node for processing each of the received tasks from the plurality of task processing nodes.

[0009] In an optional implementation, the determining, from the plurality of preset task scheduling strategies, the target task scheduling strategy whose task scheduling performance matches the number of the received tasks, comprises:

[0010] calculating a number difference between the number of the idle processing nodes and the number of the received tasks;

[0011] when the number difference is a non-negative number, determining a first task scheduling strategy from the plurality of preset task scheduling strategies as the target task scheduling strategy, wherein the first task scheduling strategy is used to represent a task scheduling strategy in which the received tasks are processed in parallel by the idle processing nodes;

[0012] when the number difference is a negative number and an absolute value of the number difference is less than or equal to a first preset threshold, determining a second task scheduling strategy from the plurality of preset task scheduling strategies as the target task scheduling strategy, wherein the second task scheduling strategy is used to represent a task scheduling strategy in which the received tasks are processed in parallel by a target number of idle processing nodes and the received tasks are processed in series by a remaining number of idle processing nodes other than the target number of idle processing nodes;

[0013] when the number difference is a negative number and the absolute value of the number difference is greater than the first preset threshold, determining a third task scheduling strategy from the plurality of preset task scheduling strategies as the target task scheduling strategy, wherein the third task scheduling strategy is used to represent a task scheduling strategy in which the received tasks are processed in series by the idle processing nodes.

[0014] In an optional implementation, when the target task scheduling strategy is the second task scheduling strategy, the target number of idle processing nodes for parallel processing of the received to-be-processed tasks is determined by the following method:

[0015] According to the preset target number, the target number of idle processing nodes is randomly selected from the idle processing nodes in the plurality of task processing nodes;

[0016] Alternatively,

[0017] According to the predicted processing time of each to-be-processed task, the to-be-processed task with a predicted processing time greater than a preset processing time threshold is determined as a first to-be-processed task that needs to be processed in parallel in the second task scheduling strategy from all the received to-be-processed tasks;

[0018] The number of the first to-be-processed tasks is taken as the target number, and the target number of idle processing nodes is randomly selected from the idle processing nodes in the plurality of task processing nodes;

[0019] Alternatively,

[0020] According to the task processing efficiency of each task processing node, the target number of idle processing nodes is preferentially selected from the idle processing nodes in the plurality of task processing nodes in a manner of preferentially selecting task processing nodes with low task processing efficiency.

[0021] In an optional implementation, when the to-be-processed task is the model training task, the scheduling method further comprises:

[0022] For each model training task, the model training task is split into a plurality of model training subtasks according to the different types of annotation training samples included in the model training task, wherein each model training subtask corresponds to annotation training samples of one type of annotation;

[0023] Each model training subtask is scheduled and processed as an independent to-be-processed task.

[0024] In an optional implementation, the receiving of the to-be-processed tasks submitted by the plurality of task submission nodes comprises: receiving the to-be-processed tasks submitted by the plurality of task submission nodes in a current scheduling period; and the target idle processing nodes in an idle state in the current scheduling period are determined from the plurality of task processing nodes by the following method:

[0025] inputting historical traffic data obtained in a last scheduling period into a pre-trained traffic prediction model to obtain a traffic prediction result output by the traffic prediction model for a next scheduling period, wherein the traffic prediction result is used to represent a task quantity prediction result for tasks to be processed received in the next scheduling period;

[0026] predicting a node quantity of idle processing nodes required for task scheduling in the next scheduling period according to the traffic prediction result for the next scheduling period to obtain a node prediction result for the next scheduling period, wherein the first scheduling strategy is used to represent a task scheduling strategy matching a task scheduling performance and the traffic prediction result;

[0027] from idle processing nodes in an idle state in the plurality of task processing nodes, removing idle processing nodes of the node quantity represented by the node prediction result, and taking the remaining idle processing nodes as target idle processing nodes in an idle state in a current scheduling period.

[0028] In an optional implementation, after the plurality of tasks to be processed submitted by the plurality of task submission nodes are received, the method for determining the target task scheduling strategy further includes:

[0029] inputting a task quantity of the received tasks to be processed, a task attribute of each of the tasks to be processed, occupation information of the task processing nodes in a same historical receiving period, and a node quantity of idle processing nodes in an idle state in a current receiving period into a target algorithm model, taking that a task scheduling result meets a task attribute requirement of each of the tasks to be processed as an output constraint condition, and taking that an overall time consumption for task scheduling of each of the received tasks to be processed is the shortest as an output target, to obtain an optimal scheduling scheme for the output target output by the target algorithm model, wherein the optimal scheduling scheme meets the output constraint condition;

[0030] taking the optimal scheduling scheme as the target task scheduling strategy, and allocating, according to the optimal scheduling scheme, a target task processing node for processing each of the received tasks to be processed from the plurality of task processing nodes.

[0031] In an optional implementation, after the target task processing node for processing each of the received tasks to be processed is allocated, the scheduling method further includes:

[0032] in response to an exception in processing of the task to be processed by the target task processing node, controlling the target task processing node to automatically perform task processing on the task to be processed again to obtain a secondary processing result of the target task processing node for the task to be processed.

[0033] in response to the result of the secondary processing being normal, controlling the target task processing node to end the task processing operation for the to-be-processed task;

[0034] in response to the result of the secondary processing being abnormal, controlling the target task processing node to automatically re-perform task processing for the to-be-processed task.

[0035] In a second aspect, an embodiment of the present application provides a task scheduling apparatus, which is applied to a scheduling node; the scheduling apparatus comprises:

[0036] a receiving module, configured to receive to-be-processed tasks submitted by a plurality of task submitting nodes; wherein the to-be-processed tasks comprise model training tasks in a target business scenario and / or model application tasks in the target business scenario;

[0037] a processing module, configured to determine, from a plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches the number of tasks of the to-be-processed tasks, according to the number of tasks of the to-be-processed tasks received and the number of idle processing nodes in an idle state in the plurality of task processing nodes; wherein the task scheduling performance is related to the number of tasks of the to-be-processed tasks that each idle processing node needs to process in the task scheduling strategy;

[0038] a scheduling module, configured to allocate, according to the target task scheduling strategy, a target task processing node for processing each to-be-processed task received from the plurality of task processing nodes.

[0039] In a third aspect, an embodiment of the present application provides a task scheduling system, which comprises a plurality of task submitting nodes, a plurality of task processing nodes and a scheduling node; the scheduling node is configured to:

[0040] receive to-be-processed tasks submitted by the plurality of task submitting nodes; wherein the to-be-processed tasks comprise model training tasks in a target business scenario and / or model application tasks in the target business scenario;

[0041] determine, from a plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches the number of tasks of the to-be-processed tasks, according to the number of tasks of the to-be-processed tasks received and the number of idle processing nodes in an idle state in the plurality of task processing nodes; wherein the task scheduling performance is related to the number of tasks of the to-be-processed tasks that each idle processing node needs to process in the task scheduling strategy;

[0042] According to the target task scheduling strategy, a target task processing node for processing each of the received to-be-processed tasks is allocated from the plurality of task processing nodes.

[0043] In a fourth aspect, an embodiment of the present application provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements the steps of the task scheduling method when executing the computer program.

[0044] In a fifth aspect, an embodiment of the present application provides a computer readable storage medium, and the computer readable storage medium stores a computer program, and the computer program performs the steps of the task scheduling method when executed by a processor.

[0045] The technical scheme provided by the embodiment of the present application can include the following beneficial effects:

[0046] The task scheduling method, device, equipment and storage medium provided by the embodiment of the present application, through the scheduling node receiving the to-be-processed tasks submitted by the plurality of task submission nodes, according to the task quantity of the to-be-processed tasks and the node quantity of the idle processing nodes in the idle state in the plurality of task processing nodes, determining the target task scheduling strategy from the plurality of preset task scheduling strategies, the task scheduling performance of which matches the task quantity of the to-be-processed tasks, and according to the target task scheduling strategy, allocating the target task processing node for processing each of the received to-be-processed tasks from the plurality of task processing nodes.

[0047] In this way, the present application allocates the hardware resources capable of executing the to-be-processed tasks submitted by each independent task submission node through the task scheduling mode, so as to save the hardware resources needed to be landed at the user terminal corresponding to each task submission node in the task scheduling process, which is conducive to reducing the operation and maintenance cost consumed in the task scheduling process, and improves the scheduling efficiency of the to-be-processed tasks.

[0048] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and easy to understand, the following preferred embodiments are described in detail below, and the accompanying drawings are described as follows. BRIEF DESCRIPTION OF DRAWINGS

[0049] In order to more clearly illustrate the technical scheme of the embodiments of the present application, the following will briefly introduce the drawings needed in the embodiments. It should be understood that the following drawings only show some embodiments of the present application, and therefore should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can also be obtained without creative labor on the basis of these drawings.

[0050] Figure 1A flowchart illustrating a task scheduling method provided in an embodiment of this application is shown.

[0051] Figure 2 The diagram illustrates a flowchart of a method for split-task scheduling of model training tasks provided in an embodiment of this application.

[0052] Figure 3 A flowchart illustrating the first method for determining a target task scheduling strategy provided in an embodiment of this application is shown.

[0053] Figure 4 The illustration shows a flowchart of a method for determining a target idle processing node that is idle in the current scheduling cycle from multiple task processing nodes, according to an embodiment of this application.

[0054] Figure 5 A flowchart illustrating the second method for determining a target task scheduling strategy provided in an embodiment of this application is shown.

[0055] Figure 6 The illustration shows a flowchart of a method for automatically retrying a pending task that has failed to be processed, as provided in an embodiment of this application.

[0056] Figure 7 A schematic diagram of the structure of a task scheduling device provided in an embodiment of this application is shown;

[0057] Figure 8 A schematic diagram of the structure of a task scheduling system provided in an embodiment of this application is shown;

[0058] Figure 9 A schematic diagram of the structure of a computer device 900 provided in an embodiment of this application is shown. Detailed Implementation

[0059] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. It should be understood that the accompanying drawings in this application are for illustrative and descriptive purposes only and are not intended to limit the scope of protection of this application. Furthermore, it should be understood that the schematic drawings are not drawn to scale. The flowcharts used in this application illustrate operations implemented according to some embodiments of this application. It should be understood that the operations in the flowcharts may not be implemented in sequence, and steps without logical contextual relationships may be reversed or implemented simultaneously. In addition, those skilled in the art, guided by the content of this application, may add one or more other operations to the flowcharts, or remove one or more operations from the flowcharts.

[0060] In addition, the described embodiments are only some of the embodiments of the present application, rather than all the embodiments. The components of the embodiments of the present application described and shown in the accompanying drawings can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present application provided in the accompanying drawings is not intended to limit the scope of the claimed present application, but only represents selected embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by those skilled in the art without creative labor fall within the scope of protection of the present application.

[0061] It should be noted that the term "comprising" will be used in the embodiments of the present application to indicate the presence of the features declared thereafter, but does not exclude the addition of other features.

[0062] Currently, taking the catering business scenario as an example, different types of computer vision models landed in the catering business scenario are used to perform different model application tasks (such as the above-mentioned identification of the cooked degree of dishes, the identification of the completeness of dish ingredients, etc.), and before actual application, different computer vision models also need to perform respective model training tasks based on different labeled sample data. At this time, since different model application tasks and different model training tasks need to be implemented based on hardware resources (such as processors, computers, etc. hardware resources), the hardware resources needed to be landed at each independent business scenario are very large.

[0063] Based on this, the embodiments of the present application provide a task scheduling method, device, equipment and storage medium, a scheduling node receives a plurality of tasks submitted by a plurality of task submission nodes; according to the number of tasks of the to-be-processed tasks and the number of idle processing nodes in the idle state in the plurality of task processing nodes, from a plurality of preset task scheduling strategies, a target task scheduling strategy is determined, which matches the task quantity of the to-be-processed tasks; according to the target task scheduling strategy, for each to-be-processed task received, a target task processing node for processing the to-be-processed task is allocated from the plurality of task processing nodes.

[0064] In this way, the present application allocates hardware resources capable of executing the processing task for each to-be-processed task submitted by an independent task submission node through task scheduling, so as to save the hardware resources needed to be landed at the user terminal corresponding to each task submission node in the task scheduling process, which is conducive to reducing the operation and maintenance cost consumed in the task scheduling process, and improves the scheduling efficiency of the to-be-processed tasks.

[0065] The following will introduce in detail a task scheduling method, device, equipment and storage medium provided by the embodiments of the present application.

[0066] Referring to Figure 1 , as shown in Figure 1A flowchart of a task scheduling method provided by an embodiment of the application is shown, which is applied to a scheduling node; the scheduling method comprises steps S101-S103; specifically:

[0067] S101, receiving a plurality of tasks submitted by a plurality of task submission nodes.

[0068] Here, the to-be-processed task includes a model training task in a target business scenario and / or a model application task in the target business scenario; the task submission node is used to represent a user terminal in the target business scenario; wherein the specific model type corresponding to the to-be-processed task can be determined based on the actual business demand in the target business scenario; the specific terminal type of the user terminal represented by the above task submission node includes but is not limited to mobile phones, computers, tablets, and other electronic terminal devices.

[0069] Specifically, when the target business scenario is a catering business scenario, the business demand in the catering business scenario can include: identifying the cooked degree of dishes (such as judging the degree of doneness of the current dish, judging whether the cooked degree of the current dish meets the dish condition, etc.), identifying the completeness of dish ingredients (such as judging whether the ingredients on the pizza crust are evenly distributed, judging whether the current dish contains all the ingredients in the menu, etc.); At this time, the scheduling node can receive a plurality of task submission nodes (such as user terminals at different catering stores) submitted model training tasks (such as training models to learn to identify the cooked degree of dishes in input image data, training models to learn to identify the completeness of dish ingredients in input image data, etc.) and / or submitted model application tasks (such as inputting the image data of the current dish into the trained model to obtain the recognition result of the cooked degree of the current dish output by the model, etc.).

[0070] Specifically, when the target business scenario is an office business scenario, the business demand in the office business scenario can include: identifying whether the employee's dress conforms to the company's specifications (such as judging whether the current employee is wearing an employee uniform, judging whether the current employee is wearing a work card, etc.), identifying whether the office table and chair are placed in accordance with the regulations (such as judging whether there are extra tables and chairs placed in violation of regulations in the current aisle, judging whether there are illegal items placed on the current office table, etc.); At this time, the scheduling node can receive a plurality of task submission nodes (such as user terminals in different office departments) submitted model training tasks (such as training models to learn to identify whether the employee's dress conforms to the company's specifications in input image data, training models to learn to identify whether the office table and chair are placed in accordance with the regulations in input image data, etc.) and / or submitted model application tasks (such as inputting the image data of the current employee into the trained model to obtain the recognition result of whether the employee's dress conforms to the company's specifications output by the model, etc.).

[0071] It should be noted that the specific business type of the target business scenario, the specific model type corresponding to the above to-be-processed task, and the specific terminal type of the user terminal represented by the above task submission node are not limited in the embodiments of the present application.

[0072] S102, according to the received task quantity of the to-be-processed task and the node quantity of the idle processing nodes in the idle state in the plurality of task processing nodes, from the plurality of preset task scheduling strategies, determine a target task scheduling strategy whose task scheduling performance matches the task quantity of the to-be-processed task.

[0073] Here, the task scheduling performance is related to the task quantity of the to-be-processed task that each idle processing node in the task scheduling strategy needs to process.

[0074] In the embodiments of the present application, the scheduling node and the task processing node can be a terminal device (such as a computer, a tablet, etc. Electronic terminal device) or a server, and the scheduling node has a plurality of task scheduling strategies stored in advance; wherein, the plurality of task scheduling strategies are used to perform hierarchical scheduling on the currently received to-be-processed task according to the quantity gap between the task quantity of the currently received to-be-processed task and the currently schedulable hardware resources (i.e. The node quantity of the idle processing nodes in the idle state in the plurality of task processing nodes).

[0075] Specifically, in the process of the above hierarchical scheduling, the task scheduling performance corresponding to different task scheduling strategies is different, wherein the task scheduling strategy with higher task scheduling performance corresponds to higher scheduling level, at this time, for the plurality of currently received to-be-processed tasks, the scheduling is preferentially performed according to the task scheduling strategy with higher scheduling level, so as to improve the scheduling efficiency of the to-be-processed task in the process of task scheduling.

[0076] It should be noted that the less the number of tasks of the to-be-processed tasks that each idle processing node needs to process in the task scheduling strategy, the higher the task scheduling performance of the task scheduling strategy, and the higher the scheduling level corresponding to the task scheduling strategy. For example, if each idle processing node in the task scheduling strategy A only needs to process one to-be-processed task (equivalent to that the number of idle processing nodes is relatively sufficient at this time, and all received to-be-processed tasks can be processed in parallel), x1 idle processing nodes in the task scheduling strategy B only need to process one to-be-processed task, and x2 idle processing nodes need to process y to-be-processed tasks respectively to form a task queue (equivalent to that the number of idle processing nodes is not sufficient at this time, and therefore, x1 idle processing nodes are needed to process the received to-be-processed tasks in parallel, and x2 idle processing nodes are needed to process the received to-be-processed tasks in series); at this time, it can be determined that the task scheduling performance of the task scheduling strategy A is higher than that of the task scheduling strategy B, and if the number of currently received to-be-processed tasks is less than the number of idle processing nodes (that is, both the task scheduling strategy A and the task scheduling strategy B can complete the scheduling of the currently received to-be-processed tasks), the scheduling node can preferentially perform task scheduling on the currently received to-be-processed tasks according to the task scheduling strategy A.

[0077] S103, according to the target task scheduling strategy, each to-be-processed task received is allocated a target task processing node for processing the to-be-processed task from the plurality of task processing nodes.

[0078] Here, the task processing node can be a terminal device (such as a computer, a tablet, etc. Electronic terminal device) or a server, and each task processing node includes a plurality of available hardware resources, for example, the task processing node can include: GPU (graphics processing unit, graphics processing unit) resources required to complete model training tasks of image processing type models, CPU (central processing unit, central processing unit) resources required to complete data processing and analysis tasks in the model training process, etc.

[0079] It should be noted that the task processing node is different from the task submission node (that is, the same terminal device cannot simultaneously appear as a task processing node and a task submission node), that is, the task processing node does not need to be landed in the target business scenario; for example, still taking the catering scenario as the target business scenario, the task submission node can be a user terminal at different catering stores, and the task processing node can be a remote cloud service terminal or a cloud server, at this time, the task processing node is not located in the catering store.

[0080] Based on this, in the embodiments of the present application, without the need to distinguish the specific task content of the to-be-processed task, the scheduling node can only allocate a corresponding number of to-be-processed tasks to the idle processing nodes in the plurality of task processing nodes according to the number of tasks that each idle processing node in the target task scheduling strategy needs to process (i.e., the task scheduling performance of the target task scheduling strategy). That is, for each idle processing node, the hardware resources at the idle processing node can meet the task processing needs of the to-be-processed task regardless of what to-be-processed task the idle processing node is assigned to process. Thus, the hardware resources needed to be landed at the user terminal corresponding to each task submission node can be saved, which is conducive to reducing the operation and maintenance costs consumed in the task scheduling process.

[0081] In order to more clearly reflect the implementation details of the above steps S101-S103 in the embodiments of the present application, the implementation details of the above steps S101-S103 will be described in detail below by taking a catering scenario as an example:

[0082] Firstly, the plurality of task submission nodes and the plurality of task processing nodes together with the above scheduling node form a complete task scheduling system for executing the task scheduling method described in the above steps S101-S103. Before executing the task scheduling method described in the above steps S101-S103, each task submission node and each task processing node is pre-established in communication connection (such as wireless network communication connection, wired network communication connection, etc.) with the scheduling node, so that the task submission node can submit the to-be-processed task to the scheduling node, the scheduling node can receive the to-be-processed task submitted by the task submission node, the scheduling node can also distribute the to-be-processed task to the task processing node and receive the task processing result of the to-be-processed task fed back by the task processing node, so that the scheduling node can also send the obtained task processing result to the corresponding task submission node, completing the task scheduling of the to-be-processed task.

[0083] Specifically, in the embodiments of the present application, each task processing node can complete the communication initialization process with the scheduling node according to the optional implementation shown in steps a1-a3, so that the scheduling node can more conveniently and efficiently complete the task scheduling of the to-be-processed task:

[0084] Step a1, basic image preparation, wherein the basic image includes: an offline training image (used to submit a model training task to the scheduling node through an interface and receive the task processing result of the model training task fed back by the scheduling node) and an online service image (used to submit a model application task to the scheduling node through an interface and receive the task processing result of the model application task fed back by the scheduling node).

[0085] Here, specifically at the task submission node side (such as the user terminal at different catering stores in the catering scenario), each task submission node can build a training base image and an inference base image of each model in the target business scenario based on the Docker container technology, and require the calling mode of the model training interface in each target business scenario to be standardized and unified. Among them, for the above training base image, the model training data, configuration file, output result, input log file, etc. can be called by the training base image through the mounting mode, so as to form the to-be-processed task for packaging and sending.

[0086] Step a2, the task submission node registers the above prepared base image in step a1 to the scheduling node, so that the base image and the scheduling node can communicate with each other, thereby supporting different base images to send different types of to-be-processed tasks to the scheduling node.

[0087] Exemplary explanation, taking task submission node a as an example, the offline training image and the online service image in the task submission node a are registered to the scheduling node, at this time, taking the offline training image as an example, the offline training image in the task submission node a can package the model training data (such as multiple image data of different dishes) of the computer vision model, the labeled sample data (such as labeled sample data based on the cooked degree of dishes in the image, labeled sample data based on the completeness of dishes in the image, etc.) and other data as to-be-processed tasks and send them to the scheduling node, so that the scheduling node can determine the idle processing node that can be used to complete the to-be-processed task from multiple task submission nodes.

[0088] Step a3, each task processing node and the scheduling node keep communication, supporting the scheduling node to allocate tasks and schedule resources for each task processing node.

[0089] Here, at the task processing node and the scheduling node side, after the scheduling node determines the target task scheduling strategy, the task processing node side can manage the docker image based on the API (Application Programming Interface) in the docker-java library, create and start the model training base container and / or the model application base container, to execute the model training task and / or the model application task, and update the hardware resource utilization and the task processing progress and other task related information in the task processing process. At the same time, the task processing node side can also capture the container running situation, and asynchronously update the task processing progress, and record the related model training indicators, training logs and other task processing results after the task processing is completed, and release the related container resources.

[0090] Specifically, in the embodiments of the present application, for the task submission node side, it also needs to be explained that:

[0091] Considering that the to-be-processed task submitted by the task submission node may include a model training task, and based on the increasing business requirements encountered in actual business scenarios, the upgrade frequency requirement of the model on the task submission node side will also be accelerated; based on this, in the embodiments of the present application, the scheduling node side can support the task submission node to submit a model training task through a timing task triggered manner, and can also support the task submission node to submit a model training task through a message notification type triggered manner. In this way, the user terminal on the task submission node side only needs to focus on the labeling quality of the model training data, and then, through the timing task triggered / message notification type triggered manner, the training effect of the optimized model can be actively updated according to the latest labeled sample data and historical labeled sample data. Among them, in the training base image, based on NAS (Neural Architecture Search, neural network architecture search technology), the optimal deep model network structure can be selected as the specified task training model in the model training task, so that the task completion result (such as various completion indicators after model training) of the submitted model training task meets the user's expectation, and the actual business requirements of constantly updating and upgrading in the target business scenario are solved.

[0092] For the specific implementation process of the above step S101, the scheduling node can receive a model training task submitted by the task submission node, or can receive a model application task submitted by the task submission node. At this time, for the model application task, since the model application task is a specific application task for a trained model (equivalent to the physical meaning represented by the output result of the model in the model application task is determined, for example, the model application task can be to input the image data of the current dish into the trained model to obtain the recognition result of the model output for the current dish. Degree of cooking), therefore, when the to-be-processed task received belongs to the model application task, the scheduling node can directly distribute the model application task as an independent to-be-processed task to an independent idle processing node for processing.

[0093] Regarding model training tasks, considering that the same training data can be used to train models to learn and solve different types of business needs based on different types of labeled sample data, when the received task belongs to the model training task, in addition to scheduling the task as an independent task to be processed on an independent idle processing node, the task can also be split into multiple sub-tasks according to the types of labeled sample data included in the received task. Each sub-task can then be assigned as an independent task to a different idle processing node for processing. This allows the task processing result of each sub-task to address a specific type of business need, which helps improve the task scheduling efficiency of the model training task.

[0094] In one alternative implementation, refer to Figure 2 As shown, Figure 2 This illustration shows a flowchart of a method for split-task scheduling of model training tasks provided in an embodiment of this application. The method includes steps S201-S202; specifically:

[0095] S201, for each model training task, the model training task is divided into multiple model training sub-tasks based on the labeled training samples of different labeled types included in the model training task.

[0096] In this embodiment of the application, as an optional embodiment, when a task submission node submits a model training task as a task to be processed, it can submit training sample data and multiple labeled training samples obtained by labeling the training sample data with different labeling methods based on different model training purposes to the scheduling node at the same time. At this time, it should be noted that the submitted model training task is used to represent the above-mentioned training sample data and the above-mentioned multiple labeled training samples contained in the task to be processed for the model training process (equivalent to distinguishing the model application tasks submitted by other task submission nodes in terms of task type), and is not used to represent a specific model training task carrying a specific model training objective.

[0097] Here, each of the model training sub-tasks corresponds to a labeling training sample of a labeling type, that is, the submitted model training task does not specify which of the multiple labeling training samples is used to train the model (i.e., the submitted model training task does not carry a certain specified model training target), and the labeling type of each labeling training sample (i.e., the specific labeling manner of the labeling training sample) is obtained according to each specific model training purpose. Therefore, for the model training task submitted by the task submission node, the scheduling node can split the model training task into multiple model training sub-tasks according to the different labeling types of the labeling training samples included in the model training task, so as to schedule and process each model training sub-task as an independent to-be-processed task, so as to achieve the purpose of simultaneously training the model for completing different model training tasks using the same training sample data, and improve the task processing efficiency for the model training task.

[0098] S202, each of the model training sub-tasks is scheduled and processed as an independent to-be-processed task.

[0099] Here, taking the catering scenario as the target business scenario as an example, the model training task splitting manner shown in steps S201-S202 is described in detail as follows:

[0100] Specifically, in the catering scenario, when the task submission node submits the model training task, the training sample data submitted can be: after the dish is completed, the dish image data obtained after the dish is photographed; At this time, the training sample data can be labeled based on different model training purposes, thereby obtaining multiple labeled training samples submitted. For example, for the same dish image data, when the labeled training sample is a labeled training sample a obtained by labeling the dish in the image based on the raw and cooked degree, the model can be trained based on the labeled training sample a to learn to output a model output result for identifying the raw and cooked degree of the dish in the input image data, so as to solve the business demand of identifying the raw and cooked degree of the dish in the catering scenario; When the labeled training sample is a labeled training sample b obtained by labeling the dish in the image based on the completeness of the ingredients, the model can be trained based on the labeled training sample b to learn to output a model output result for identifying whether the dish in the input image data contains all the ingredients in the menu, so as to solve the business demand of identifying the completeness of the ingredients of the dish in the catering scenario.

[0101] For example, if the current received task A submitted by the task submission node belongs to a model training task, and the task A includes the dish image data, the labeled training sample a, and the labeled training sample b, the scheduling node can split the task A into a model training subtask A1 (including the dish image data and the labeled training sample a) and a model training subtask A2 (including the dish image data and the labeled training sample b) by performing steps S201-S202. If the number of idle processing nodes is sufficient (e.g., the number of idle processing nodes is greater than the number of tasks), the scheduling node can send the split model training subtask A1 to the idle processing node p1 for task processing, so as to train the model to learn the model output result for identifying the dish freshness level in the input image data (i.e., complete the task processing of the model training subtask A1 at the idle processing node p1) by using the hardware resources (e.g., GPU resources, CPU resources, etc.) at the idle processing node p1. The split model training subtask A2 is sent to the idle processing node p2 for task processing, so as to train the model to learn the model output result for identifying whether the dish in the input image data contains all the ingredients in the menu notes (i.e., complete the task processing of the model training subtask A2 at the idle processing node p2) by using the hardware resources (e.g., GPU resources, CPU resources, etc.) at the idle processing node p2.

[0102] For the specific implementation process of step S102, taking the number of preset task scheduling strategies as 3 as an example, when the three preset task scheduling strategies are used to perform hierarchical scheduling on the to-be-processed tasks, referring to FIG. 3, Figure 3 Figure 3 FIG. 3 shows a flow diagram of a first method for determining a target task scheduling strategy provided by an embodiment of the present application, which includes steps S301-S304; specifically:

[0103] S301, calculating the number difference between the number of idle processing nodes in the idle state in the plurality of task processing nodes and the number of tasks of the to-be-processed tasks.

[0104] It should be noted that, in the embodiment of the present application, according to the actual task scheduling requirements, the scheduling node can determine the task processing nodes that are not assigned with to-be-processed tasks as the idle processing nodes in the idle state; or determine the task processing nodes with a number of assigned to-be-processed tasks less than a preset threshold as the idle processing nodes in the idle state; and the specific definition of the idle state is not limited in the embodiment of the present application.

[0105] ​Specifically, at the scheduling node, the number of idle processing nodes is equivalent to a digital representation value of the "current schedulable hardware resource", and the number of to-be-processed tasks is equivalent to a digital representation value of the "current load pressure requiring task scheduling"; at this time, the scheduling node can obtain a digital specific representation value between the "load pressure" and the "schedulable hardware resource" by calculating the number difference, so as to determine, according to the size of the calculated number difference, a target task scheduling strategy from the plurality of preset task scheduling strategies, which satisfies the balance condition between the "load pressure" and the "schedulable hardware resource", so that the basic task scheduling requirement (such as the task waiting time of each to-be-processed task being less than the preset waiting time) can be met when the to-be-processed tasks currently received are scheduled according to the target task scheduling strategy.

[0106] S302, when the number difference is a non-negative number, determining a first task scheduling strategy as the target task scheduling strategy from the plurality of preset task scheduling strategies.

[0107] Here, the first task scheduling strategy is used to represent a task scheduling strategy for simultaneously processing each to-be-processed task received by the idle processing node in parallel.

[0108] Specifically, when the calculated number difference is a non-negative number, it indicates that the number of idle processing nodes currently in an idle state is greater than or equal to the number of to-be-processed tasks currently received; at this time, each to-be-processed task received can be randomly assigned to any idle processing node for processing according to the first task scheduling strategy, so as to achieve the task scheduling effect of simultaneously processing each to-be-processed task received in parallel.

[0109] For example, if the number of idle processing nodes is 20 and the number of to-be-processed tasks currently received is 10, 10 idle processing nodes can be randomly selected from the 20 idle processing nodes, and each idle processing node selected can be assigned a to-be-processed task, so that the idle processing node can simultaneously process the 10 to-be-processed tasks currently received in parallel, improving the task processing efficiency of the to-be-processed tasks.

[0110] S303, when the number difference is a negative number and the absolute value of the number difference is less than or equal to a first preset threshold, determining a second task scheduling strategy as the target task scheduling strategy from the plurality of preset task scheduling strategies.

[0111] Here, the second task scheduling strategy is used to represent a task scheduling strategy that utilizes a target number of idle processing nodes to perform parallel processing on the received to-be-processed tasks and utilizes a remaining number of idle processing nodes other than the target number to perform serial processing on the received to-be-processed tasks.

[0112] Specifically, when the calculated number difference is a negative number, it indicates that the number of idle processing nodes currently in an idle state is less than the number of to-be-processed tasks currently received (that is, the task scheduling cannot be performed according to the first task scheduling strategy). At this time, the greater the absolute value of the number difference, the fewer the number of available idle processing nodes, that is, the more to-be-processed tasks that each idle processing node needs to process. Based on this, by comparing the size relationship between the absolute value of the number difference and the first preset threshold, when the absolute value of the number difference is less than or equal to the first preset threshold, the second task scheduling strategy is determined as the target task scheduling strategy (equivalent to selecting a small number of idle processing nodes to still be responsible for processing only one to-be-processed task, and assigning multiple to-be-processed tasks to the remaining idle processing nodes).

[0113] It should be noted that the specific value of the first preset threshold can be customized according to actual task scheduling requirements, and the specific value of the first preset threshold is not limited in the embodiments of the present application.

[0114] In the embodiments of the present application, when the target task scheduling strategy is determined to be the second task scheduling strategy, in step S303, the target number of idle processing nodes used to perform parallel processing on the received to-be-processed tasks can be determined in at least the following three different optional ways, specifically:

[0115] Option 1: According to a preset target number, the target number of idle processing nodes is randomly extracted from the idle processing nodes in an idle state in the plurality of task processing nodes.

[0116] Option 2: From the side of the to-be-processed tasks, based on the different task processing times of to-be-processed tasks of different difficulty levels (for example, to-be-processed tasks with a low task difficulty coefficient require a shorter task processing time, and to-be-processed tasks with a high task difficulty coefficient require a longer time for processing), the target number of idle processing nodes can be determined according to the following steps b1-b2, specifically:

[0117] Step b1: According to the predicted processing time of each to-be-processed task, from all the received to-be-processed tasks, determine the to-be-processed tasks with a predicted processing time greater than a preset processing time threshold as first to-be-processed tasks that need to be processed in parallel in the second task scheduling strategy.

[0118] Step b2, taking the task quantity of the first to-be-processed task as the target quantity, randomly extracting the target quantity of idle processing nodes from the idle processing nodes in the plurality of task processing nodes.

[0119] Option 3, according to the task processing efficiency of each task processing node, preferentially extracting the target quantity of idle processing nodes from the idle processing nodes in the plurality of task processing nodes in a manner of preferentially extracting task processing nodes with low task processing efficiency.

[0120] Here, considering that the task processing efficiencies of different task processing nodes can be different, for example, the higher the hardware resource performance of a task processing node (such as the more advanced the model of a GPU processor, the higher the hardware resource performance of the task processing node), the higher the corresponding task processing efficiency (for example, for the same to-be-processed task, the task processing node with high task processing efficiency takes less time to process the task); therefore, by implementing the above-mentioned optional mode 3, the scheduling node can preferentially allocate fewer to-be-processed tasks to the task processing nodes with low task processing efficiency, and allocate more to-be-processed tasks to other task processing nodes with relatively high task processing efficiency, thereby helping to shorten the total task completion time of the to-be-processed tasks received in the same batch and improve the overall task scheduling efficiency.

[0121] S304, when the quantity difference belongs to a negative number and the absolute value of the quantity difference is greater than the first preset threshold, determining a third task scheduling strategy as the target task scheduling strategy from the plurality of preset task scheduling strategies.

[0122] Here, the third task scheduling strategy is used to represent a task scheduling strategy for serial processing of all received to-be-processed tasks by using idle processing nodes.

[0123] Specifically, when the calculated quantity difference belongs to a negative number, it indicates that the number of idle processing nodes currently in an idle state is less than the number of to-be-processed tasks currently received (that is, the task scheduling cannot be performed according to the first task scheduling strategy); at this time, the greater the absolute value of the quantity difference, the fewer the number of available idle processing nodes, that is, each idle processing node needs to process more to-be-processed tasks, based on which, by comparing the size relationship between the absolute value of the quantity difference and the first preset threshold, when the absolute value of the quantity difference is greater than the first preset threshold, the third task scheduling strategy can be determined as the target task scheduling strategy (equivalent to allocating multiple to-be-processed tasks to each idle processing node).

[0124] For the specific implementation process of the above steps S101-S103, in the task scheduling mode according to the above steps S101-S103, the basic task scheduling demand in the target business scenario can be met, and on this basis, in order to meet the higher demand for task scheduling in the target business scenario, the application embodiment further provides the advanced version scheduling scheme and the high-order version scheduling scheme as shown below, specifically:

[0125] For the advanced version scheduling scheme, on the basis of the basic version task scheduling scheme described in the above steps S101-S103, the step of "periodic task scheduling" is newly added in the advanced version scheduling scheme, that is, the task scheduling time is segmented according to the preset period length, so that before the task scheduling starts in each scheduling period, the traffic of the next scheduling period (equivalent to the number of tasks of the next scheduling period received by the to-be-processed task) is predicted in advance, so that the number of idle processing nodes that can be scheduled in the current scheduling period can be adjusted according to the high and low of the predicted traffic value of the next scheduling period, so as to achieve the dynamic adjustment result of expanding the hardware resources (that is, increasing the idle processing nodes) in the traffic peak period and appropriately reducing the hardware resources (such as reducing the idle processing nodes / without changing the number of idle processing nodes) in the traffic valley period, which is beneficial to further save the available hardware resources in the task scheduling system and reduce the operation and maintenance cost consumed in the task scheduling process.

[0126] In the above advanced version scheduling scheme, receiving the to-be-processed tasks submitted by the plurality of task submission nodes includes: receiving the to-be-processed tasks submitted by the plurality of task submission nodes in the current scheduling period; at this time, referring to Figure 4 , it is shown that Figure 4 a flowchart of a method for determining a target idle processing node in an idle state in a current scheduling period from a plurality of task processing nodes is shown, and the method includes steps S401-S403; specifically:

[0127] S401, input the historical traffic data counted in the last scheduling period into the pre-trained traffic prediction model to obtain the traffic prediction result output by the traffic prediction model for the next scheduling period.

[0128] Here, the traffic prediction result is used to represent the task quantity prediction result for the to-be-processed tasks received in the next scheduling period.

[0129] Specifically, taking the preset period length of 10 minutes as an example, before starting task scheduling in the current scheduling period (such as the scheduling period corresponding to 13:00-13:10), the task quantity of the to-be-processed tasks accumulated in the last scheduling period (that is, the scheduling period corresponding to 12:50-13:00) can be converted into the corresponding historical traffic data, and the historical traffic data is input into the pre-trained traffic prediction model to obtain the traffic prediction result output by the traffic prediction model for the next scheduling period (that is, the scheduling period corresponding to 13:10-13:20).

[0130] Here, as an optional embodiment, the traffic prediction model described above can be constructed using the Prophet micro-framework in the open-source python library, and an online service resource security threshold is set to ensure the stability of the online services required in the task scheduling process.

[0131] S402, according to the traffic prediction result for the next scheduling period, the node quantity of the idle processing nodes required for task scheduling in the next scheduling period according to the first scheduling strategy is predicted to obtain a node prediction result for the next scheduling period.

[0132] Here, the first scheduling strategy is used to represent a task scheduling strategy whose task scheduling performance matches the traffic prediction result; the specific determination method of the first scheduling strategy can refer to the specific implementation process of step S102, and the repeated parts will not be described here.

[0133] S403, from the idle processing nodes in the idle state in the plurality of task processing nodes, remove the idle processing nodes of the node quantity represented by the node prediction result, and take the remaining idle processing nodes as the target idle processing nodes in the idle state in the current scheduling period.

[0134] Specifically, the scheduling node performs the above steps S401-S403 to segment the task scheduling time by dividing the scheduling period, and before starting task scheduling at the beginning of each scheduling period, the traffic prediction model is used to predict the traffic of the next scheduling period, wherein the traffic prediction model outputs the traffic prediction result of the next scheduling period (equivalent to predicting how many tasks to be processed need to be scheduled in the next scheduling period); then, according to the traffic prediction result, the task scheduling resources (i.e. the idle processing nodes represented by the node number in the above node prediction result) that need to be reserved in the current scheduling period are estimated; then, in the current scheduling period, the reserved idle nodes are subtracted from the available idle processing nodes to obtain the actual schedulable idle processing nodes (i.e. the above target idle processing nodes) in the current scheduling period, so that in the current scheduling period, the target idle processing nodes are used to schedule the received tasks to be processed in the current scheduling period.

[0135] It should be noted that in the above advanced scheduling scheme, after determining the target idle processing nodes in the idle state in the current scheduling period according to the method described in steps S401-S403, the "idle processing nodes in the idle state in the plurality of task processing nodes" described in step S102 can be replaced with the "target idle processing nodes in the idle state in the current scheduling period" determined by steps S401-S403. The other task scheduling modes in the advanced scheduling scheme in the current scheduling period are the same as the specific scheduling modes described in steps S101-S103, and the repeated parts will not be described here.

[0136] For the high-order version scheduling scheme, on the basis of the basic version task scheduling scheme described in steps S101-S103, the difference between the target task scheduling strategy in step S102 is that in the high-order version scheduling scheme, the scheduling node contains a built-in algorithm to optimize the task queue composed of tasks to be processed in the shortest overall time, so as to dynamically adjust the task processing priority of each task to be processed in the task queue and the processing mechanism (such as the multiple hierarchical scheduling task scheduling strategies shown in step S102) for the tasks to be processed according to the task attribute, the historical hardware resource scheduling situation, the current hardware resource reservation situation (i.e. the reservation situation of idle processing nodes) and the task submission situation, so as to ensure smooth transition of current and future hardware resource scheduling while achieving the purpose of the shortest overall time of task processing, thereby greatly improving the scheduling efficiency of tasks to be processed.

[0137] In the above high-order version scheduling scheme, after receiving the tasks to be processed submitted by the plurality of task submission nodes, the task queue is constructed according to the task attribute of the tasks to be processedFigure 5 As shown, Figure 5 A flow diagram of a second method for determining a target task scheduling strategy is shown, which includes steps S501-S502; specifically:

[0138] S501, input the received task quantity of the to-be-processed task, the task attribute of each to-be-processed task, the occupation information of the task processing node in the same historical receiving period, and the node quantity of the idle processing node in an idle state in the current receiving period into a target algorithm model, take the task scheduling result meeting the task attribute requirement of each to-be-processed task as an output constraint condition, take the shortest overall time consumption for task scheduling of each received to-be-processed task as an output target, and obtain an optimal scheduling scheme for the output target output by the target algorithm model.

[0139] Specifically, the shortest overall time consumption is used to represent that when the received each to-be-processed task is executed by the idle processing node in the idle state in the current receiving period, the overall time consumed for task scheduling of all to-be-processed tasks received in the current receiving period is the shortest.

[0140] It should be noted that the optimal scheduling scheme meets the output constraint condition; wherein in the output constraint condition, the task attribute requirement of the to-be-processed task can include but is not limited to: waiting time requirement in the task scheduling process (such as the waiting time in the task scheduling process is at most 20 minutes), performance requirement of the task processing node (such as the resource performance of the hardware resource in the task processing node cannot be lower than xx, etc.); for the specific task attribute requirement of the to-be-processed task, the embodiments of the present application do not make any limitation.

[0141] S502, take the optimal scheduling scheme as the target task scheduling strategy, and according to the optimal scheduling scheme, allocate a target task processing node for processing each received to-be-processed task from the plurality of task processing nodes.

[0142] Specifically, in the high-order version scheduling scheme, after the target task scheduling strategy is determined, the specific task scheduling mode of the step S502 is still the same as the specific scheduling mode described in the step S103, and the repeated parts will not be repeated here.

[0143] It should be noted that, in the above high-order version scheduling scheme, as an optional embodiment, the above high-order version scheduling scheme can be obtained by changing the way of determining the "target task scheduling strategy" in the above step S102 on the basis of the basic version scheduling scheme described in the above steps S101-S103; as another optional embodiment, the above high-order version scheduling scheme can also be obtained by changing the way of determining the "target task scheduling strategy" in the above step S102 on the basis of the above advanced version scheduling scheme (i.e., on the basis of the above steps S101-S103 and the above steps S401-S403). The specific formulation of the above high-order version scheduling scheme is not limited by the embodiments of the present application.

[0144] In addition to the above steps, considering that the task processing node may fail in the process of actually processing the to-be-processed task, based on this, the embodiments of the present application also provide an automatic retry mechanism as shown in Figure 6 to control the task processing node to automatically initiate task retry for the current to-be-processed task when the task processing fails, so as to improve the processing success rate of the to-be-processed task.

[0145] Referring to Figure 6 , it is shown that Figure 6 a flow diagram of a method for automatically retrying a to-be-processed task that fails in processing is provided by the embodiments of the present application, and the method includes steps S601-S603; specifically:

[0146] S601, in response to an exception in processing of the to-be-processed task by the target task processing node, the target task processing node is controlled to automatically re-process the to-be-processed task to obtain a second processing result of the to-be-processed task by the target task processing node.

[0147] It should be noted that the above processing exception includes both device-type exceptions such as freezing, interruption, data loss, etc. during task processing of the to-be-processed task, and data-type exceptions such as abnormal task processing result after task processing of the to-be-processed task; the specific definition of the above processing exception is not limited by the embodiments of the present application.

[0148] S602, in response to a normal result of the second processing result, the target task processing node is controlled to end the task processing operation for the to-be-processed task.

[0149] Specifically, the scheduling node can control the target task processing node to end the task processing operation for the to-be-processed task and acquire the task processing result of the to-be-processed task from the target task processing node in response to the result of the secondary processing being normal, and feed back the acquired task processing result to the task submitting node that submits the to-be-processed task.

[0150] S603, in response to the result of the secondary processing being abnormal, controlling the target task processing node to automatically perform task processing for the to-be-processed task again.

[0151] Specifically, the scheduling node can control the target task processing node to automatically perform task processing for the to-be-processed task again in response to the result of the secondary processing being abnormal. For the to-be-processed task with an abnormal result, the scheduling node can repeatedly initiate the automatic retry steps shown in steps S601-S603 until a normal processing result of the to-be-processed task is successfully obtained, or can repeatedly initiate the automatic retry steps shown in steps S601-S603 within a limited number of retries according to a preset upper limit of the number of retries of automatic retries. The specific number of retries of automatic retries that can be initiated by the scheduling node is not limited in the embodiments of the present application.

[0152] The scheduling method for tasks provided in the embodiments of the present application receives to-be-processed tasks submitted by a plurality of task submitting nodes, determines a target task scheduling strategy with a task scheduling performance matching the number of to-be-processed tasks from a plurality of preset task scheduling strategies according to the number of to-be-processed tasks and the number of idle processing nodes in an idle state in the plurality of task processing nodes, and allocates a target task processing node for processing each received to-be-processed task from the plurality of task processing nodes according to the target task scheduling strategy.

[0153] In this way, the present application allocates hardware resources capable of executing a to-be-processed task for each to-be-processed task submitted by an independent task submitting node through task scheduling, so as to save hardware resources needed to be landed at a user terminal corresponding to each task submitting node in the task scheduling process, which is conducive to reducing the operation and maintenance cost consumed in the task scheduling process and improving the scheduling efficiency of to-be-processed tasks.

[0154] Based on the same inventive concept, the embodiments of the present application also provide a scheduling device corresponding to the scheduling method for tasks in the above embodiments. Since the scheduling device in the embodiments of the present application has a similar principle of solving problems to the scheduling method in the above embodiments of the present application, the implementation of the scheduling device can be referred to the implementation of the above scheduling method, and the repeated parts will not be described herein.

[0155] Referring to Figure 7 , the scheduling device comprises a receiving unit, a determining unit, an allocating unit and a processing unit. Figure 7A structural schematic diagram of a task scheduling device is shown. The device is applied to a scheduling node. The device comprises:

[0156] The receiving module 701 is configured to receive a plurality of tasks submitted by a plurality of task submission nodes. The tasks include model training tasks in a target business scenario and / or model application tasks in the target business scenario.

[0157] The processing module 702 is configured to determine a target task scheduling strategy from a plurality of preset task scheduling strategies according to a number of the tasks and a number of idle processing nodes in a plurality of task processing nodes. The target task scheduling strategy matches a task scheduling performance and the number of the tasks. The task scheduling performance is related to a number of the tasks that each idle processing node needs to process in the task scheduling strategy.

[0158] The scheduling module 703 is configured to allocate a target task processing node for processing each of the tasks from the plurality of task processing nodes according to the target task scheduling strategy.

[0159] In an optional implementation, the processing module 702 is specifically configured to:

[0160] Calculate a number difference between the number of the idle processing nodes and the number of the tasks.

[0161] When the number difference is a non-negative number, determine a first task scheduling strategy as the target task scheduling strategy from the plurality of preset task scheduling strategies. The first task scheduling strategy is used to represent a task scheduling strategy in which the idle processing nodes are used to simultaneously perform parallel processing on each of the tasks.

[0162] When the number difference is a negative number and an absolute value of the number difference is less than or equal to a first preset threshold, determine a second task scheduling strategy as the target task scheduling strategy from the plurality of preset task scheduling strategies. The second task scheduling strategy is used to represent a task scheduling strategy in which a target number of the idle processing nodes are used to perform parallel processing on the tasks, and a remaining number of the idle processing nodes other than the target number are used to perform serial processing on the tasks.

[0163] When the quantity difference belongs to a negative number and an absolute value of the quantity difference is greater than the first preset threshold, a third task scheduling strategy is determined as the target task scheduling strategy from a plurality of preset task scheduling strategies, where the third task scheduling strategy is used to represent a task scheduling strategy for performing serial processing on all received to-be-processed tasks by using idle processing nodes.

[0164] In an optional implementation, when the target task scheduling strategy is the second task scheduling strategy, the processing module 702 is configured to determine the target number of idle processing nodes for performing parallel processing on the received to-be-processed tasks by the following method:

[0165] According to the preset target number, the target number of idle processing nodes is randomly selected from idle processing nodes in an idle state in the plurality of task processing nodes;

[0166] Alternatively,

[0167] According to a predicted processing time of each to-be-processed task, a to-be-processed task with a predicted processing time greater than a preset processing time threshold is determined as a first to-be-processed task that needs to be processed in parallel in the second task scheduling strategy from all received to-be-processed tasks;

[0168] The number of tasks of the first to-be-processed task is used as the target number, and the target number of idle processing nodes is randomly selected from idle processing nodes in an idle state in the plurality of task processing nodes;

[0169] Alternatively,

[0170] According to a task processing efficiency of each task processing node, the target number of idle processing nodes is preferentially selected from idle processing nodes in an idle state in the plurality of task processing nodes in a manner of preferentially selecting a task processing node with a low task processing efficiency.

[0171] In an optional implementation, when the to-be-processed task is the model training task, the receiving module 701 is further configured to:

[0172] For each model training task, the model training task is split into a plurality of model training subtasks according to different annotation types of annotation training samples included in the model training task, where each model training subtask corresponds to annotation training samples of one annotation type;

[0173] Each model training subtask is scheduled and processed as an independent to-be-processed task.

[0174] In an optional implementation, when receiving the to-be-processed tasks submitted by the plurality of task submission nodes, the receiving module 701 is further configured to receive the to-be-processed tasks submitted by the plurality of task submission nodes in a current scheduling period; and the processing module 702 is further configured to determine, from the plurality of task processing nodes, a target idle processing node in an idle state in the current scheduling period by the following method:

[0175] inputting the historical traffic data obtained in the last scheduling period into a pre-trained traffic prediction model to obtain a traffic prediction result output by the traffic prediction model for a next scheduling period; wherein the traffic prediction result is used to represent a task quantity prediction result for to-be-processed tasks received in the next scheduling period;

[0176] predicting, according to the traffic prediction result for the next scheduling period, a node quantity of idle processing nodes required for task scheduling in the next scheduling period according to a first scheduling strategy to obtain a node prediction result for the next scheduling period; wherein the first scheduling strategy is used to represent a task scheduling strategy that matches the task scheduling performance and the traffic prediction result;

[0177] removing, from idle processing nodes in an idle state in the plurality of task processing nodes, idle processing nodes of the node quantity represented by the node prediction result, and taking the remaining idle processing nodes as target idle processing nodes in an idle state in the current scheduling period.

[0178] In an optional implementation, the processing module 702 is further configured to determine the target task scheduling strategy by the following method:

[0179] inputting the task quantity of the received to-be-processed tasks, the task attribute of each to-be-processed task, the occupation information of the task processing nodes in the same historical receiving period, and the node quantity of idle processing nodes in an idle state in the current receiving period into a target algorithm model, taking that the task scheduling result meets the task attribute requirement of each to-be-processed task as an output constraint condition, and taking that the overall time consumption for task scheduling of each received to-be-processed task is the shortest as an output target, to obtain an optimal scheduling scheme for the output target output by the target algorithm model; wherein the optimal scheduling scheme meets the output constraint condition;

[0180] taking the optimal scheduling scheme as the target task scheduling strategy, and allocating, according to the optimal scheduling scheme, a target task processing node for processing each received to-be-processed task from the plurality of task processing nodes.

[0181] In an optional implementation, after assigning a target task processing node to each received task to be processed, the scheduling module 703 is further configured to:

[0182] In response to an anomaly in the processing of the task to be processed by the target task processing node, the target task processing node is controlled to automatically reprocess the task to be processed, so as to obtain the secondary processing result of the target task processing node for the task to be processed.

[0183] If the result of the secondary processing is normal, the target task processing node is controlled to end the task processing operation for the task to be processed.

[0184] If the result of the secondary processing is abnormal, the target task processing node is controlled to automatically reprocess the task to be processed.

[0185] The task scheduling device provided in this application embodiment receives pending tasks submitted by multiple task submission nodes through a scheduling node; based on the number of pending tasks and the number of idle processing nodes in the multiple task processing nodes, a target task scheduling strategy that matches the task scheduling performance with the number of pending tasks is determined from a set of preset task scheduling strategies; according to the target task scheduling strategy, a target task processing node is assigned to each received pending task from the multiple task processing nodes to process the pending task.

[0186] In this way, this application allocates hardware resources capable of executing the processing task to each independent task submission node by means of task scheduling. This saves the hardware resources that need to be deployed at the user terminal corresponding to each task submission node during the task scheduling process, which helps to reduce the operation and maintenance costs consumed in the task scheduling process and improves the scheduling efficiency of the tasks to be processed.

[0187] Based on the same inventive concept, this application also provides a scheduling system corresponding to the task scheduling method in the above embodiments. Since the principle of the scheduling system in this application is similar to the scheduling method in the above embodiments, the implementation of the scheduling system can refer to the implementation of the aforementioned scheduling method, and the repeated parts will not be described again.

[0188] Reference Figure 8 As shown, Figure 8 This illustration shows a schematic diagram of a task scheduling system according to an embodiment of this application; the scheduling system includes: multiple task submission nodes 801, multiple task processing nodes 802, and a scheduling node 803; wherein, the scheduling node 803 is used for:

[0189] receive a plurality of to-be-processed tasks submitted by a plurality of task submission nodes 801; wherein, the to-be-processed tasks comprise model training tasks in a target business scenario and / or model application tasks in the target business scenario;

[0190] determine, from a plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches the number of the to-be-processed tasks, according to the number of the to-be-processed tasks received and the number of idle processing nodes in the plurality of task processing nodes 802 in an idle state; wherein, the task scheduling performance is related to the number of the to-be-processed tasks that each idle processing node needs to process in the task scheduling strategy;

[0191] allocate, according to the target task scheduling strategy, a target task processing node for processing each of the to-be-processed tasks received from the plurality of task processing nodes 802.

[0192] In an optional implementation, in the process of determining, from a plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches the number of the to-be-processed tasks, according to the number of the to-be-processed tasks received and the number of idle processing nodes in the plurality of task processing nodes 802 in an idle state, the scheduling node 803 is specifically configured to:

[0193] calculate a number difference between the number of idle processing nodes in the plurality of task processing nodes 802 in an idle state and the number of the to-be-processed tasks;

[0194] when the number difference belongs to non-negative numbers, determine a first task scheduling strategy as the target task scheduling strategy from a plurality of preset task scheduling strategies; wherein, the first task scheduling strategy is used to represent a task scheduling strategy in which idle processing nodes are used to simultaneously perform parallel processing on each of the to-be-processed tasks received;

[0195] when the number difference belongs to negative numbers and the absolute value of the number difference is less than or equal to a first preset threshold, determine a second task scheduling strategy as the target task scheduling strategy from a plurality of preset task scheduling strategies; wherein, the second task scheduling strategy is used to represent a task scheduling strategy in which a target number of idle processing nodes are used to perform parallel processing on the to-be-processed tasks received, and a remaining number of idle processing nodes other than the target number are used to perform serial processing on the to-be-processed tasks received;

[0196] When the quantity difference is a negative number and the absolute value of the quantity difference is greater than the first preset threshold, a third task scheduling strategy is determined as the target task scheduling strategy from the plurality of preset task scheduling strategies, where the third task scheduling strategy is used to represent a task scheduling strategy for performing serial processing on all received to-be-processed tasks by using idle processing nodes.

[0197] In an optional implementation, when the target task scheduling strategy is the second task scheduling strategy, the scheduling node 803 is configured to determine the target number of idle processing nodes for performing parallel processing on the received to-be-processed tasks by the following method:

[0198] According to the preset target number, the target number of idle processing nodes is randomly selected from the idle processing nodes in the idle state in the plurality of task processing nodes 802;

[0199] Alternatively,

[0200] According to the predicted processing time of each to-be-processed task, a to-be-processed task with a predicted processing time greater than a preset processing time threshold is determined as a first to-be-processed task that needs to be processed in parallel in the second task scheduling strategy from all received to-be-processed tasks;

[0201] The number of the first to-be-processed tasks is used as the target number, and the target number of idle processing nodes is randomly selected from the idle processing nodes in the idle state in the plurality of task processing nodes 802;

[0202] Alternatively,

[0203] According to the task processing efficiency of each task processing node 802, the target number of idle processing nodes is preferentially selected from the idle processing nodes in the idle state in the plurality of task processing nodes 802 in a manner of preferentially selecting a task processing node with a low task processing efficiency.

[0204] In an optional implementation, when the to-be-processed task is the model training task, the scheduling node 803 is further configured to:

[0205] For each model training task, the model training task is split into a plurality of model training subtasks according to different types of annotation training samples included in the model training task, where each model training subtask corresponds to annotation training samples of one type of annotation;

[0206] Each model training subtask is scheduled and processed as an independent to-be-processed task.

[0207] In an optional implementation, the receiving the to-be-processed tasks submitted by the plurality of task submission nodes 801 comprises: receiving, in a current scheduling period, the to-be-processed tasks submitted by the plurality of task submission nodes 801; and the scheduling node 803 is further configured to determine, from the plurality of task processing nodes 802, a target idle processing node in an idle state in the current scheduling period by the following method:

[0208] inputting the historical traffic data obtained in the last scheduling period into a pre-trained traffic prediction model to obtain a traffic prediction result output by the traffic prediction model for a next scheduling period; wherein the traffic prediction result is used to represent a task quantity prediction result for to-be-processed tasks received in the next scheduling period;

[0209] predicting, according to the traffic prediction result for the next scheduling period, a node quantity of idle processing nodes required for task scheduling in the next scheduling period according to a first scheduling strategy to obtain a node prediction result for the next scheduling period; wherein the first scheduling strategy is used to represent a task scheduling strategy whose task scheduling performance matches the traffic prediction result;

[0210] removing, from idle processing nodes in an idle state in the plurality of task processing nodes 802, idle processing nodes of the node quantity represented by the node prediction result, and taking the remaining idle processing nodes as target idle processing nodes in an idle state in the current scheduling period.

[0211] In an optional implementation, after the receiving the to-be-processed tasks submitted by the plurality of task submission nodes 801, the scheduling node 803 is further configured to determine the target task scheduling strategy by the following method:

[0212] inputting the task quantity of the received to-be-processed tasks, the task attribute of each to-be-processed task, the occupation information of the task processing nodes 802 in a same historical receiving period, and the node quantity of idle processing nodes in an idle state in a current receiving period into a target algorithm model, taking that a task scheduling result meets a task attribute requirement of each to-be-processed task as an output constraint condition, and taking that the overall time consumption for task scheduling of each to-be-processed task received is the shortest as an output target, to obtain an optimal scheduling scheme for the output target output by the target algorithm model; wherein the optimal scheduling scheme meets the output constraint condition;

[0213] taking the optimal scheduling scheme as the target task scheduling strategy, and allocating, according to the optimal scheduling scheme, a target task processing node for processing each to-be-processed task received from the plurality of task processing nodes 802.

[0214] In an alternative implementation, after the target task processing node is assigned for each of the received to-be-processed tasks, the scheduling node 803 is further configured to:

[0215] in response to an exception in the processing of the to-be-processed task by the target task processing node, control the target task processing node to automatically re-perform task processing on the to-be-processed task to obtain a secondary processing result of the to-be-processed task by the target task processing node;

[0216] in response to a normal result of the secondary processing result, control the target task processing node to end the task processing operation on the to-be-processed task;

[0217] in response to an abnormal result of the secondary processing result, control the target task processing node to automatically re-perform task processing on the to-be-processed task.

[0218] The above task scheduling system provided by the embodiments of the present application receives to-be-processed tasks submitted by multiple task submission nodes through a scheduling node; determines a target task scheduling strategy that matches the task quantity of the to-be-processed tasks and the quantity of idle processing nodes in an idle state in the multiple task processing nodes from a plurality of preset task scheduling strategies; and assigns a target task processing node for processing each of the received to-be-processed tasks from the multiple task processing nodes according to the target task scheduling strategy.

[0219] In this way, the present application assigns hardware resources capable of executing the to-be-processed tasks submitted by each independent task submission node through task scheduling, so as to save the hardware resources needed to be landed at the user terminal corresponding to each task submission node in the task scheduling process, which is conducive to reducing the operation and maintenance cost consumed in the task scheduling process and improving the scheduling efficiency of the to-be-processed tasks.

[0220] As shown in FIG. 9, Figure 9 The embodiments of the present application provide a computer device 900 for executing the task scheduling method, which comprises a memory 901, a processor 902, and a computer program stored in the memory 901 and executable on the processor 902, wherein the processor 902 executes the computer program to implement the steps of the task scheduling method.

[0221] Specifically, the memory 901 and the processor 902 can be general memory and processor, which are not limited here, and when the processor 902 runs the computer program stored in the memory 901, the task scheduling method can be executed.

[0222] Corresponding to the scheduling method of the task in the application, the embodiment of the application further provides a computer readable storage medium, and the computer readable storage medium stores a computer program, and the computer program is run by a processor to execute the steps of the scheduling method of the task.

[0223] Specifically, the storage medium can be a general storage medium, such as a mobile disk, a hard disk, and the like. The computer program on the storage medium can execute the scheduling method of the task when the computer program is run.

[0224] In the embodiments provided in the application, it should be understood that the disclosed system and method can be implemented in other manners. The system embodiments described above are only schematic. For example, the division of the units is only a logical function division. There can be another division manner for the actual implementation, for example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the displayed or discussed mutual couplings or direct couplings or communication connections between the units can be indirect couplings or communication connections through some interfaces, and electrical, mechanical or other forms.

[0225] The units described as separated components can or can not be physically separated, and the components displayed as units can or can not be physical units, i.e., can be located in one place, or can be distributed on a plurality of network units. In actual implementation, some or all of the units can be selected according to the actual needs to achieve the purposes of the embodiments.

[0226] In addition, each functional unit in the embodiments provided by the application can be integrated in a processing unit, or each unit can exist physically as a separate unit, or two or more units can be integrated in one unit.

[0227] If the functions are implemented in the form of software function units and sold or used as independent products, the software function units can be stored in a computer readable storage medium. Based on such an understanding, the technical solutions of the application essentially or the part that makes a contribution to the prior art or part of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium, and includes a plurality of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the application. The foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and various media that can store program codes.

[0228] It should be noted that like reference numerals and letters refer to like items throughout the accompanying drawings, and once an item is defined in one drawing, it should not be further defined and explained in subsequent drawings, and further, the terms "first", "second", "third" and the like are used only to distinguish descriptions, and cannot be understood as indicating or implying relative importance.

[0229] Finally, it should be noted that the above-described embodiments are merely specific embodiments of the present application, and are used to illustrate the technical solutions of the present application, but are not limiting, and the protection scope of the present application is not limited thereto, although the present application is described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can modify or easily think of changes to the technical solutions recorded in the foregoing embodiments, or make equivalent replacements to some technical features, and these modifications, changes or replacements do not make the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application. should be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. A method of scheduling tasks, characterized by, The scheduling method is applied to a scheduling node; The scheduling method comprises: receiving a plurality of to-be-processed tasks submitted by a plurality of task submission nodes; wherein the to-be-processed tasks comprise model training tasks in a target business scenario and / or model application tasks in the target business scenario; determining, from a plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches the number of the to-be-processed tasks, according to the number of the to-be-processed tasks received and the number of idle processing nodes in a plurality of task processing nodes in an idle state; wherein the task scheduling performance is related to the number of the to-be-processed tasks that each idle processing node needs to process in the task scheduling strategy; allocating, according to the target task scheduling strategy, a target task processing node for processing each to-be-processed task received from the plurality of task processing nodes for each to-be-processed task received; wherein the determining, from a plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches the number of the to-be-processed tasks, according to the number of the to-be-processed tasks received and the number of idle processing nodes in a plurality of task processing nodes in an idle state, comprises: calculating a quantity difference between the number of idle processing nodes in the plurality of task processing nodes in an idle state and the number of the to-be-processed tasks; when the quantity difference belongs to non-negative numbers, determining a first task scheduling strategy as the target task scheduling strategy from a plurality of preset task scheduling strategies; wherein the first task scheduling strategy is used to represent a task scheduling strategy for utilizing idle processing nodes to simultaneously perform parallel processing on each to-be-processed task received; when the quantity difference belongs to negative numbers and the absolute value of the quantity difference is less than or equal to a first preset threshold, determining a second task scheduling strategy as the target task scheduling strategy from a plurality of preset task scheduling strategies; wherein the second task scheduling strategy is used to represent a task scheduling strategy for utilizing a target number of idle processing nodes to perform parallel processing on the to-be-processed tasks received and utilizing a remaining number of idle processing nodes other than the target number to perform serial processing on the to-be-processed tasks received; when the quantity difference belongs to negative numbers and the absolute value of the quantity difference is greater than the first preset threshold, determining a third task scheduling strategy as the target task scheduling strategy from a plurality of preset task scheduling strategies; wherein the third task scheduling strategy is used to represent a task scheduling strategy for utilizing idle processing nodes to perform serial processing on all to-be-processed tasks received.

2. The scheduling method of claim 1, wherein, when the target task scheduling strategy is the second task scheduling strategy, the target number of idle processing nodes for performing parallel processing on the to-be-processed tasks received is determined by the following method: randomly extracting the target number of idle processing nodes from the idle processing nodes in the plurality of task processing nodes in an idle state according to a preset target number; or, According to the predicted processing time of each to-be-processed task, from all the received to-be-processed tasks, determine a to-be-processed task with a predicted processing time greater than a preset processing time threshold as a first to-be-processed task in the second task scheduling strategy that needs to be processed in parallel; Take the number of the first to-be-processed tasks as the target number, and randomly select the target number of idle processing nodes from the idle processing nodes in the plurality of task processing nodes; Or, According to the task processing efficiency of each task processing node, preferentially select the target number of idle processing nodes from the idle processing nodes in the plurality of task processing nodes in a manner of preferentially selecting task processing nodes with low task processing efficiency.

3. The scheduling method of claim 1, wherein, When the to-be-processed task is the model training task, the scheduling method further comprises: For each model training task, according to the different types of labeled training samples included in the model training task, the model training task is split into a plurality of model training subtasks; wherein each model training subtask corresponds to a type of labeled training sample; Each model training subtask is scheduled and processed as an independent to-be-processed task.

4. The scheduling method of claim 1, wherein, The receiving of the to-be-processed tasks submitted by the plurality of task submission nodes comprises: receiving the to-be-processed tasks submitted by the plurality of task submission nodes in the current scheduling period; and determining the target idle processing nodes in an idle state in the current scheduling period from the plurality of task processing nodes by the following method: Input the historical traffic data obtained in the last scheduling period into the pre-trained traffic prediction model to obtain the traffic prediction result output by the traffic prediction model for the next scheduling period; wherein the traffic prediction result is used to represent the task quantity prediction result for the to-be-processed tasks received in the next scheduling period; According to the traffic prediction result for the next scheduling period, predict the number of idle processing nodes required for task scheduling in the next scheduling period according to the first scheduling strategy to obtain a node prediction result for the next scheduling period; wherein the first scheduling strategy is used to represent a task scheduling strategy whose task scheduling performance matches the traffic prediction result; From the idle processing nodes in an idle state in the plurality of task processing nodes, remove the idle processing nodes with the number of nodes represented by the node prediction result, and take the remaining idle processing nodes as the target idle processing nodes in an idle state in the current scheduling period.

5. The scheduling method of claim 1, wherein, After receiving the to-be-processed tasks submitted by the plurality of task submission nodes, the method for determining the target task scheduling strategy further comprises: input the received task quantity of the to-be-processed tasks, the task attribute of each to-be-processed task, the occupation information of the task processing node in the same historical receiving period, and the node quantity of the idle processing nodes in an idle state at a current receiving period into a target algorithm model, take the task scheduling result meeting the task attribute requirement of each to-be-processed task as an output constraint condition, take the shortest overall time for task scheduling of each received to-be-processed task as an output target, obtain an optimal scheduling scheme for the output target output by the target algorithm model, wherein the optimal scheduling scheme meets the output constraint condition; take the optimal scheduling scheme as the target task scheduling strategy, and allocate, according to the optimal scheduling scheme, a target task processing node for processing each received to-be-processed task from the plurality of task processing nodes.

6. The scheduling method of claim 1, wherein, After the target task processing node for processing each received to-be-processed task is allocated, the scheduling method further includes: in response to an exception in processing of the to-be-processed task by the target task processing node, controlling the target task processing node to automatically perform task processing on the to-be-processed task again, to obtain a secondary processing result of the to-be-processed task by the target task processing node; in response to a normal result of the secondary processing result, controlling the target task processing node to end the task processing operation on the to-be-processed task; in response to an abnormal result of the secondary processing result, controlling the target task processing node to automatically perform task processing on the to-be-processed task again.

7. A task scheduling apparatus characterized by comprising: The scheduling device is applied to a scheduling node. The scheduling device includes: a receiving module configured to receive to-be-processed tasks submitted by a plurality of task submission nodes; wherein the to-be-processed tasks include model training tasks in a target business scenario and / or model application tasks in the target business scenario; a processing module configured to determine, from a plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches the task quantity of the to-be-processed tasks, according to the received task quantity of the to-be-processed tasks and the node quantity of idle processing nodes in an idle state in a plurality of task processing nodes; wherein the task scheduling performance is related to the task quantity of the to-be-processed tasks that need to be processed by each idle processing node in the task scheduling strategy; a scheduling module configured to allocate, according to the target task scheduling strategy, a target task processing node for processing each received to-be-processed task from the plurality of task processing nodes; wherein the processing module is specifically configured to: calculate the quantity difference between the node quantity of the idle processing nodes in an idle state in the plurality of task processing nodes and the task quantity of the to-be-processed tasks; When the quantity difference belongs to a non-negative number, a first task scheduling strategy is determined as the target task scheduling strategy from the plurality of preset task scheduling strategies, where the first task scheduling strategy is used to represent a task scheduling strategy in which idle processing nodes are used to simultaneously perform parallel processing on each of the received to-be-processed tasks. When the quantity difference belongs to a negative number and an absolute value of the quantity difference is less than or equal to a first preset threshold, a second task scheduling strategy is determined as the target task scheduling strategy from the plurality of preset task scheduling strategies, where the second task scheduling strategy is used to represent a task scheduling strategy in which a target number of idle processing nodes are used to perform parallel processing on the received to-be-processed tasks, and a remaining number of idle processing nodes other than the target number are used to perform serial processing on the received to-be-processed tasks. When the quantity difference belongs to a negative number and the absolute value of the quantity difference is greater than the first preset threshold, a third task scheduling strategy is determined as the target task scheduling strategy from the plurality of preset task scheduling strategies, where the third task scheduling strategy is used to represent a task scheduling strategy in which idle processing nodes are used to perform serial processing on all of the received to-be-processed tasks.

8. A system for scheduling tasks, characterized by The scheduling system includes a plurality of task submission nodes, a plurality of task processing nodes, and a scheduling node, where the scheduling node is configured to: receive to-be-processed tasks submitted by the plurality of task submission nodes, where the to-be-processed tasks include model training tasks in a target business scenario and / or model application tasks in the target business scenario; determine, from a plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches a task quantity of the to-be-processed tasks, according to the task quantity of the received to-be-processed tasks and a node quantity of idle processing nodes in an idle state in the plurality of task processing nodes, where the task scheduling performance is related to a task quantity of the to-be-processed tasks that needs to be processed by each idle processing node in the task scheduling strategy; allocate, according to the target task scheduling strategy, a target task processing node for processing each of the received to-be-processed tasks from the plurality of task processing nodes; In the process of determining, from a plurality of preset task scheduling strategies, a target task scheduling strategy whose task scheduling performance matches a task quantity of to-be-processed tasks, according to the task quantity of the received to-be-processed tasks and a node quantity of idle processing nodes in an idle state in the plurality of task processing nodes, the scheduling node is configured to: calculate a quantity difference between the node quantity of the idle processing nodes in the idle state in the plurality of task processing nodes and the task quantity of the to-be-processed tasks; when the quantity difference belongs to a non-negative number, determine a first task scheduling strategy as the target task scheduling strategy from the plurality of preset task scheduling strategies, where the first task scheduling strategy is used to represent a task scheduling strategy in which idle processing nodes are used to simultaneously perform parallel processing on each of the received to-be-processed tasks. When the quantity difference belongs to a negative number and an absolute value of the quantity difference is less than or equal to a first preset threshold, a second task scheduling strategy is determined as the target task scheduling strategy from a plurality of preset task scheduling strategies; the second task scheduling strategy is used to represent a task scheduling strategy in which a target number of idle processing nodes are used to perform parallel processing on the received to-be-processed tasks, and a remaining number of idle processing nodes other than the target number are used to perform serial processing on the received to-be-processed tasks. When the quantity difference belongs to a negative number and an absolute value of the quantity difference is greater than the first preset threshold, a third task scheduling strategy is determined as the target task scheduling strategy from a plurality of preset task scheduling strategies; the third task scheduling strategy is used to represent a task scheduling strategy in which all idle processing nodes are used to perform serial processing on the received to-be-processed tasks.

9. An electronic device, comprising: Comprise: A processor, a memory and a bus, the memory stores machine readable instructions executable by the processor, when the electronic device is running, the processor and the memory communicate through the bus, the machine readable instructions are executed by the processor to execute the steps of the scheduling method in any one of claims 1 to 6.

10. A computer-readable storage medium, characterized in that, The computer readable storage medium stores a computer program, the computer program is executed by the processor to execute the steps of the scheduling method in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Task scheduling method and device

    CN111355751A