Scheduling method and device, equipment and storage medium
The scheduling method optimizes AI cloud service resource allocation by predicting future needs and matching terminals with suitable service nodes, addressing inefficiencies and ensuring high-quality service delivery.
Patent Information
- Application Number
- CN202411181830.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-27
- Publication Date
- 2024-12-31
AI Technical Summary
Existing AI cloud services face resource wastage due to inefficient scheduling of resources, leading to potential overutilization and poor service quality.
A scheduling method that determines resource utilization of service nodes, predicts future resource needs based on task information using a target model, and allocates terminals to service nodes that meet specific resource thresholds to avoid overloading.
This approach optimizes resource allocation, reducing waste and ensuring high-quality service delivery by matching terminals with appropriate service nodes, even in dynamic conditions.
Smart Images

Figure CN119225923A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of cloud service technology, and in particular to a scheduling method, apparatus, device and storage medium. Background Art
[0002] Artificial Intelligence (AI) cloud services refer to various services provided in a cloud computing environment, including computing, storage, networking, database, artificial intelligence processing, etc. Users can use these services by accessing cloud service nodes, where cloud service nodes refer to nodes in the cloud computing infrastructure, usually one or more servers or virtual machines, used to host the operation of cloud services.
[0003] During the use of AI cloud services, if the resources of AI cloud services are not reasonably scheduled, it is easy to cause waste of resources in AI cloud services. Therefore, how to reasonably schedule AI cloud service resources is a problem that needs to be solved at present. Summary of the invention
[0004] The present disclosure provides a scheduling method, apparatus, device and storage medium.
[0005] According to a first aspect of the present disclosure, a scheduling method is provided, comprising:
[0006] Determine first information of each service node in at least one service node, wherein the first information represents the utilization of resources of the service node, and the resources include at least one of the following: computing resources, memory resources, network bandwidth resources, and storage space resources;
[0007] Receiving a service request from a first terminal, the service request carrying first task information requested to be executed by the first terminal, the first task information representing information of the task requested to be executed by the first terminal;
[0008] In response to the service request, predicting first resource information of the first terminal according to the first task information by using a target model, wherein the first resource information represents occupation of service node resources by the first terminal in a first time period in the future;
[0009] According to the first resource information and the first information of each service node, a target service node is determined from the at least one service node, and the first terminal is scheduled to the target service node.
[0010] According to a second aspect of the present disclosure, a scheduling device is provided, including:
[0011] A first acquisition module is used to determine first information of each service node in at least one service node, wherein the first information represents the utilization of resources of the service node, and the resources include at least one of the following: computing resources, memory resources, network bandwidth resources, and storage space resources;
[0012] A second acquisition module is used to receive a service request from a first terminal, where the service request carries first task information requested to be executed by the first terminal, where the first task information represents information about the task requested to be executed by the first terminal;
[0013] A first processing module, configured to respond to the service request and predict first resource information of the first terminal according to the first task information by using a target model, wherein the first resource information represents occupation of service node resources by the first terminal in a first time period in the future;
[0014] The second processing module is used to determine a target service node from the at least one service node according to the first resource information and the first information of each service node, and schedule the first terminal to the target service node.
[0015] According to a third aspect of the present disclosure, there is provided an electronic device, including:
[0016] at least one processor; and
[0017] a memory communicatively connected to the at least one processor; wherein,
[0018] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the scheduling method described in the present disclosure.
[0019] According to a fourth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute the scheduling method described in the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] The above and other objects, features and advantages of the exemplary embodiments of the present disclosure will become readily understood by reading the detailed description below with reference to the accompanying drawings. In the accompanying drawings, several embodiments of the present disclosure are shown in an exemplary and non-limiting manner, in which:
[0021] In the drawings, the same or corresponding reference numerals represent the same or corresponding parts.
[0022] Figure 1 A schematic diagram of a scheduling method provided by an embodiment of the present disclosure is shown;
[0023] Figure 2A schematic diagram of a resource scheduling method for AI cloud services provided by an application embodiment of the present disclosure is shown;
[0024] Figure 3 A schematic diagram of the structure of a scheduling device provided by an embodiment of the present disclosure is shown;
[0025] Figure 4 A schematic structural diagram of an electronic device provided by an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0026] In order to make the purpose, features, and advantages of the present disclosure more obvious and easy to understand, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present disclosure.
[0027] Figure 1 A schematic diagram of a scheduling process provided by an embodiment of the present disclosure is shown; Figure 1 As shown, the scheduling method includes:
[0028] Step 101: determining first information of each service node in at least one service node, wherein the first information represents the utilization of resources of the service node, and the resources include at least one of the following: computing resources, memory resources, network bandwidth resources, and storage space resources;
[0029] Step 102: receiving a service request from a first terminal, wherein the service request carries information about a first task requested to be performed by the first terminal, and the first task information represents information about the task requested to be performed by the first terminal;
[0030] Step 103: In response to the service request, predict first resource information of the first terminal according to the first task information using a target model, where the first resource information represents occupation of service node resources by the first terminal in a first time period in the future;
[0031] Step 104: Determine a target service node from the at least one service node according to the first resource information and the first information of each service node, and schedule the first terminal to the target service node.
[0032] In some embodiments, the method is applied to a management device of a cloud service, and the management device can interact with each service node, such as obtaining first information of the service node; the management device is also used to receive service requests from user terminals and schedule them.
[0033] The management device may be a general management device that is separately configured for a service node, and the management device may also be implemented by a service node among the at least one service node.
[0034] The user terminal can be any intelligent terminal that can request cloud services, such as a mobile phone, a smart phone, a laptop computer, a digital broadcast receiver, a personal digital assistant (PDA), a tablet computer (PAD), a portable multimedia player (PMP), a navigation device, etc.
[0035] The service node may be a node that provides AI cloud services. The node may be implemented by one or more servers or virtual machines, and the server or virtual machine is used to carry the operation of the AI cloud service.
[0036] In some embodiments, determining first information of each service node of at least one service node includes:
[0037] Collecting the utilization of at least one resource of each service node in real time;
[0038] The resources include at least one of the following: computing resources, memory resources, network bandwidth resources, and storage space resources;
[0039] The computing resources may include: CPU (Central Processing Unit) resources, GPU (Graphics Processing Unit) resources, etc.
[0040] In some embodiments, using a target model to predict first resource information of the first terminal according to the first task information includes:
[0041] Using the target model to identify the first task information, obtaining first resource information;
[0042] The first task information includes at least one of the following: task type, task data size, task start time, task end time, and task duration;
[0043] The first resource information includes at least one of the following: a computing resource occupancy value, a memory resource occupancy value, a network bandwidth resource occupancy value, and a storage space resource occupancy value.
[0044] Here, a target model is provided for predicting first resource information according to task information in a service request. The first resource information may be resource occupancy within a first time period.
[0045] Here, the task type refers to the requested AI task type, which is related to the service type provided by the service node, for example, it may include: image processing tasks, text processing tasks, audio processing tasks, video processing tasks, etc.
[0046] The task data size is the data size corresponding to the required processing task. For example, if the task type is an image processing task, the task data size is the image size; similarly, if the task type is a video processing task, the task data size is the video size.
[0047] The task start time is the expected start time of the task, and the task end time is the expected end time of the task.
[0048] Task duration is related to the task start time and task end time, and is the expected time required to complete the task.
[0049] Here, the target model may be pre-trained. In some embodiments, the method further includes:
[0050] Acquire a training data set, wherein the training data set includes at least one training data;
[0051] Using the training data set to train the neural network model to obtain the target model;
[0052] The training data includes: sample task information and labels corresponding to the sample task information;
[0053] The sample task information includes at least one of the following: task type, data size corresponding to the task, task start time, task end time, and task duration;
[0054] The tag includes at least one of the following: a computing resource occupancy value, a memory resource occupancy value, a network bandwidth resource occupancy value, and a storage space resource occupancy value in a first future time period.
[0055] Here, the training data may be obtained by sorting out the collected historical data. For example, a plurality of sample task information and a label corresponding to each sample task information may be determined based on the historical data.
[0056] There is no limitation on the type of neural network model used, which can be any type, for example, long short-term memory network (LSTM), gated recurrent unit (GRU), etc.
[0057] In this way, through the pre-trained target model, the first terminal sending the service request can be predicted, specifically predicting the occupancy of the service node resources by the first terminal in the first time period in the future, and then the resource scheduling of the service node can be performed in combination with the service node resource utilization.
[0058] In some embodiments, the method further comprises:
[0059] Determine first task information or task execution information of a second terminal served by each service node;
[0060] Predicting second resource information of each second terminal according to the first task information or task execution information of the second terminal, where the second resource information represents occupation of service node resources by the second terminal in a future first time period;
[0061] Predicting resource utilization of each of the service nodes in a first future time period according to the first resource information and the second resource information;
[0062] Correspondingly, determining a target service node from the at least one service node according to the first resource information and the first information of each service node includes:
[0063] Determine a target service node that meets a first condition from the at least one service node according to the first resource information of the first terminal, the first information of each service node, and the resource utilization rate of each service node in a future first time period;
[0064] Wherein, the first condition is satisfied, including at least one of the following:
[0065] The utilization rate of the current resources of the service node is less than the first threshold;
[0066] The resource utilization of the service node in the future first time period is less than the second threshold.
[0067] Here, in order to avoid the situation where the service node resources are fully utilized, it is proposed to select whether to schedule the new user terminal (ie, the first terminal) to the service node according to the current resource utilization rate of the service node and the resource utilization rate in the future.
[0068] The first threshold and the second threshold may be set based on the actual request, for example, the first threshold and the second threshold may be 80%, 60%, etc. Moreover, the first threshold and the second threshold may take the same value or different values.
[0069] The utilization rate of resources may include: the utilization rate of each resource among computing resources, memory resources, network bandwidth resources, and storage space resources. The utilization rate of each resource may be the utilization of the resource by the service node divided by the total resources that the service node can provide. The utilization rates of different resources may correspond to different first thresholds and second thresholds.
[0070] In the disclosed embodiment, the first terminal may be scheduled to the service node only when the current resource utilization of the service node is less than a first threshold value and / or the resource utilization of the service node in a first future time period is less than a second threshold value, so as to avoid the situation where the service node resources are fully loaded, thereby avoiding the problem of the terminal's service being affected due to insufficient service node resources.
[0071] Here, the first terminal is a new user terminal that sends a service request; and the second terminal is an old user terminal that has joined the service node.
[0072] In the disclosed embodiment, in consideration of the prediction of service node resources, it is necessary to consider not only the resource occupancy of the first terminal but also the resource occupancy of the second terminal that has joined. Therefore, it is necessary to predict the resource occupancy of the second terminal, that is, to obtain the second resource information.
[0073] Here, a method is proposed for predicting the second resource information of the second terminal based on the first task information or task execution information of the second terminal, and predicting the resource utilization of each service node in a first future time period based on the first resource information and the second resource information.
[0074] In some embodiments, predicting the second resource information of each second terminal according to the first task information or task execution information of the second terminal includes:
[0075] If the duration of the second terminal joining the service node is less than the duration threshold, identifying the first task information of the second terminal by using the target model, and determining the second resource information of the second terminal;
[0076] If the duration of the second terminal joining the service node is greater than or equal to the duration threshold, determine the resource occupation of the second terminal in the second time period, and determine the second resource information according to the resource occupation of the second terminal in the second time period.
[0077] Here, considering that the longer the second terminal joins the service node, the less accurate the prediction result using the initial first task information, two prediction methods are provided, which are selected according to the length of time the second terminal joins the service node.
[0078] If the duration of the second terminal joining the service node is less than the duration threshold, that is, the time of joining the service node is short, it can use the target model to identify the first task information of the second terminal and predict the second resource information of the second terminal;
[0079] If the duration of the second terminal joining the service node is greater than or equal to the duration threshold, that is, the time of joining the service node is long, if the result obtained by using the target model prediction is relatively inaccurate, it is proposed to determine the resource occupancy of the second terminal in the second time period, and determine the second resource information according to the resource occupancy of the second terminal in the second time period. Here, according to the resource occupancy of the second terminal in the second time period, the resource occupancy value in the second time period can be averaged as the predicted value of the resource occupancy in the future first time period. The second time period can be a period of time before the prediction.
[0080] It should be noted that since resources may include: computing resources, memory resources, network bandwidth resources, and storage space resources; the above average values are calculated separately for each resource. For example, the predicted value of computing resource occupancy may be obtained by taking the average value of the resource occupancy value of the computing resource in the second time period. Similarly, the predicted value of memory resource occupancy is obtained by taking the average value of the resource occupancy value of the memory resource in the second time period. Other resources are similar and will not be repeated here.
[0081] In some embodiments, the method further comprises:
[0082] detecting resource occupancy of at least one second terminal in real time, and / or predicting second resource information of at least one second terminal;
[0083] Determine a target second terminal that meets the second condition according to the resource occupancy of each second terminal detected in real time and / or the predicted second resource information of each second terminal;
[0084] Scheduling the target second terminal to a service node that meets a third condition, or extending resources allocated by the service node to the target second terminal;
[0085] Wherein, the second condition is satisfied, including at least one of the following:
[0086] The current resource occupancy value is greater than the third threshold;
[0087] In a third time period in the future, the resource occupancy value is greater than a third threshold;
[0088] The third condition is satisfied, including at least one of the following:
[0089] In idle state;
[0090] The utilization rate of the service node resources is less than a fourth threshold.
[0091] Here, considering that there may be some very active terminals, namely the target second terminals, in order to provide better services for them and avoid their excessive occupation of resources affecting other terminals on the same service node, the resource occupation of at least one second terminal is detected in real time, and / or the second resource information of at least one second terminal is predicted to determine the target second terminal (i.e., the active terminal), and schedule it to a service node with a lower resource utilization rate (such as a utilization rate less than the fourth threshold). If there is no service node that meets the lower resource utilization rate, a new service node is expanded. For example, hot migration technology can be used to migrate the virtual machine running on the service node to a new service node, which improves the user experience and provides better services for the target second terminal.
[0092] In some embodiments, determining a target service node from the at least one service node according to the first resource information and the first information of each service node includes:
[0093] determining a task type according to the first task information;
[0094] Determining, according to the task type, at least one candidate service node from the at least one service node that provides a service corresponding to the task type;
[0095] A target service node is determined from at least one candidate service node according to the first resource information and the first information of each candidate service node.
[0096] Here, the services provided by each service node may be different. For example, service node 1 and service node 2 provide services for image processing tasks, service node 3 and service node 4 provide services for video processing tasks, and service node 5 and service node 6 provide services for text processing tasks. In order to achieve accurate services, one or more candidate service nodes that provide services corresponding to the task type requested by the terminal can be determined first, and then the target service node can be determined from at least one candidate service node in combination with the first information of each candidate service node.
[0097] Through the method provided by the embodiment of the present disclosure, the terminal is connected to a service node that matches it according to its service request; if it is determined that the resource utilization of the service node exceeds a certain threshold, it is connected to a service node with lower utilization or a newly expanded service node, thereby avoiding the waste caused by too many service nodes being started and avoiding the problem of poor service quality caused by full load of service node resources.
[0098] Figure 2 A schematic diagram of a resource scheduling method for AI cloud services provided by an application embodiment of the present disclosure is shown; Figure 2As shown, the resource scheduling method for AI cloud services includes:
[0099] Step 201: monitor the resource utilization of the currently used service nodes;
[0100] Here, step 201 includes:
[0101] Collect the operating status data of each currently used service node in real time, including: CPU resource utilization, memory resource utilization, GPU resource utilization, network bandwidth resource utilization, storage space utilization, etc.
[0102] Step 202: Receive a service request from a new user terminal and predict resource occupancy of the new user terminal in a first time period;
[0103] Here, the service request carries task information, including: the type of AI task, the data size of the AI task, the execution start time, the execution end time, etc.
[0104] Here, the target model is used to identify the task information, and the resource occupancy of the new user terminal in the future (specifically, it may be in the first future time period) is predicted.
[0105] The target model can be pre-trained. For example, a training method is provided in the above scheduling method, which will not be described in detail here.
[0106] Step 203: Based on the resource scheduling strategy, select a target service node according to the resource occupancy of the new user terminal in the first time period and the resource utilization of each currently used service node;
[0107] Here, the resource scheduling strategy includes:
[0108] Real-time monitoring is performed on CPU resource utilization, memory resource utilization, GPU resource utilization, network bandwidth resource utilization, and storage space utilization. If the utilization of one or more resources of a service node exceeds a first threshold (e.g., 80%), new user terminals are stopped from accessing the service node.
[0109] If it is predicted based on the future resource occupation of the new user terminal that the utilization rate of one or more resources after the service node accesses the new user terminal exceeds a second threshold (e.g., 80%), the new user terminal is not connected to the service node; otherwise, if it does not exceed the second threshold, the new user terminal may be connected to the service node;
[0110] If the resource utilization rates of the currently used service nodes all exceed the first threshold, a new service node is expanded, and the new user terminal is connected to the new service node;
[0111] If it is predicted based on the future resource occupancy of the new user terminal that the utilization of one or more resources of the currently used service node exceeds the second threshold after the new user terminal is connected, a new service node is expanded and the new user terminal is connected to the new service node.
[0112] Step 204: Schedule the new user terminal to the target service node so that the target service node provides services for the new user terminal.
[0113] In some embodiments, the method further comprises:
[0114] Monitor the resource usage of each terminal, and determine the active terminal (equivalent to the above-mentioned target second terminal) according to the resource usage of each terminal;
[0115] An idle service node is determined, and the active terminal is scheduled to the idle service node to provide high-quality service.
[0116] Here, the idle service node may be a service node whose resource utilization is lower than a certain threshold, or may be a newly expanded service node.
[0117] The active terminal is: one or more resources have been occupied for a long time, for example, a resource occupied by a single terminal accounts for more than 50% of the resource utilization of the entire service node;
[0118] Alternatively, the active terminal is: a terminal predicted by the target model to have high resource occupancy in the future.
[0119] Through the method provided by the embodiment of the present disclosure, the terminal is connected to a service node that matches it according to its service request, and after determining that the resource utilization of the service node exceeds a certain threshold, it is connected to other or newly expanded service nodes, thereby achieving on-demand expansion of service nodes and avoiding resource waste; at the same time, when maintaining the cloud computing service node, for active terminals, the virtual machine running on the service node can be migrated to an idle service node through hot migration technology, thereby improving the user experience.
[0120] Figure 3 A schematic diagram of the structure of a scheduling device provided by an embodiment of the present disclosure is shown; Figure 3 As shown, the scheduling device includes:
[0121] A first acquisition module is used to determine first information of each service node in at least one service node, wherein the first information represents the utilization of resources of the service node, and the resources include at least one of the following: computing resources, memory resources, network bandwidth resources, and storage space resources;
[0122] A second acquisition module is used to receive a service request from a first terminal, where the service request carries first task information requested to be executed by the first terminal, where the first task information represents information about the task requested to be executed by the first terminal;
[0123] A first processing module, configured to respond to the service request and predict first resource information of the first terminal according to the first task information by using a target model, wherein the first resource information represents occupation of service node resources by the first terminal in a first time period in the future;
[0124] The second processing module is used to determine a target service node from the at least one service node according to the first resource information and the first information of each service node, and schedule the first terminal to the target service node.
[0125] In some embodiments, the first processing module is used to identify the first task information using a target model to obtain first resource information;
[0126] The first task information includes at least one of the following: task type, task data size, task start time, task end time, and task duration;
[0127] The first resource information includes at least one of the following: a computing resource occupancy value, a memory resource occupancy value, a network bandwidth resource occupancy value, and a storage space resource occupancy value.
[0128] In some embodiments, the first processing module is further used to obtain a training data set, wherein the training data set includes at least one training data;
[0129] Using the training data set to train the neural network model to obtain the target model;
[0130] The training data includes: sample task information and labels corresponding to the sample task information;
[0131] The sample task information includes at least one of the following: task type, data size corresponding to the task, task start time, task end time, and task duration;
[0132] The tag includes at least one of the following: a computing resource occupancy value, a memory resource occupancy value, a network bandwidth resource occupancy value, and a storage space resource occupancy value in a first future time period.
[0133] In some embodiments, the first processing module is further used to determine the first task information or task execution information of the second terminal served by each service node;
[0134] Predicting second resource information of each second terminal according to the first task information or task execution information of the second terminal, where the second resource information represents occupation of service node resources by the second terminal in a future first time period;
[0135] Predicting resource utilization of each of the service nodes in a first future time period according to the first resource information and the second resource information;
[0136] Correspondingly, the second processing module is used to determine a target service node that meets the first condition from the at least one service node according to the first resource information of the first terminal, the first information of each service node, and the resource utilization rate of each service node in the future first time period;
[0137] Wherein, the first condition is satisfied, including at least one of the following:
[0138] The utilization rate of the current resources of the service node is less than the first threshold;
[0139] The resource utilization of the service node in the future first time period is less than the second threshold.
[0140] In some embodiments, the first processing module is used to identify the first task information of the second terminal using the target model and determine the second resource information of the second terminal if the duration of the second terminal joining the service node is less than a duration threshold;
[0141] If the duration of the second terminal joining the service node is greater than or equal to the duration threshold, determine the resource occupation of the second terminal in the second time period, and determine the second resource information according to the resource occupation of the second terminal in the second time period.
[0142] In some embodiments, the second processing module is further used to detect resource occupancy of at least one second terminal in real time, and / or predict second resource information of at least one second terminal;
[0143] Determine a target second terminal that meets the second condition according to the resource occupancy of each second terminal detected in real time and / or the predicted second resource information of each second terminal;
[0144] Scheduling the target second terminal to a service node that meets a third condition, or extending resources allocated by the service node to the target second terminal;
[0145] Wherein, the second condition is satisfied, including at least one of the following:
[0146] The current resource occupancy value is greater than the third threshold;
[0147] In a third time period in the future, the resource occupancy value is greater than a third threshold;
[0148] The third condition is satisfied, including at least one of the following:
[0149] In idle state;
[0150] The utilization rate of the service node resources is less than a fourth threshold.
[0151] In some embodiments, the second processing module is used to determine the task type according to the first task information;
[0152] Determining, according to the task type, at least one candidate service node from the at least one service node that provides a service corresponding to the task type;
[0153] A target service node is determined from at least one candidate service node according to the first resource information and the first information of each candidate service node.
[0154] It is understandable that the scheduling device provided in the above embodiment can distribute the above processing to different program modules as needed when implementing the corresponding scheduling method to complete all or part of the processing described above. In addition, the device provided in the above embodiment and the embodiment of the corresponding method belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.
[0155] An embodiment of the present disclosure provides a computer-readable storage medium storing executable instructions, wherein the executable instructions are stored. When the executable instructions are executed by a processor, the processor will be triggered to execute the scheduling method provided by the embodiment of the present disclosure.
[0156] In some embodiments, the computer-readable storage medium may be a ferroelectric random access memory (FRAM), a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), a flash memory, a magnetic surface memory, an optical disk, or a CD-ROM; it may also be various devices including one or any combination of the above memories.
[0157] In some embodiments, executable instructions may be in the form of a program, software, software module, script or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a stand-alone program or as a module, model, subroutine or other unit suitable for use in a computing environment.
[0158] By way of example, executable instructions may be deployed to be executed on one computing device, or on multiple computing devices located at one site, or on multiple computing devices distributed across multiple sites and interconnected by a communication network.
[0159] An embodiment of the present disclosure provides a computer program product, which includes a computer program / instructions. When the computer program / instructions are executed by a processor, the scheduling method described in the present disclosure is implemented.
[0160] Figure 4 The structure diagram of an electronic device provided by the embodiment of the present disclosure is shown in FIG. Figure 4 As shown, the electronic device 40 includes: a processor 401 and a memory 402 for storing a computer program that can be run on the processor; when the processor 401 is used to run the computer program, it executes the scheduling method provided by the embodiment of the present disclosure.
[0161] In actual application, the electronic device 40 may further include: at least one network interface 403. The various components in the electronic device 40 are coupled together via a bus system 404. It is understood that the bus system 404 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 404 also includes a power bus, a control bus, and a status signal bus. However, for the sake of clarity, Figure 4 In the figure, various buses are labeled as bus system 404. There may be at least one processor 401. The network interface 403 is used for wired or wireless communication between the electronic device 40 and other devices.
[0162] The memory 402 in the embodiment of the present disclosure is used to store various types of data to support the operation of the electronic device 40 .
[0163] The method disclosed in the above embodiment of the present disclosure can be applied to the processor 401, or implemented by the processor 401. The processor 401 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit in the processor 401 or the instruction in the form of software. The above processor 401 can be a general processor, a digital signal processor (DSP, DiGital Signal Processor), or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. The processor 401 can implement or execute the disclosed methods, steps and logic block diagrams in the embodiment of the present disclosure. The general processor can be a microprocessor or any conventional processor, etc. The steps of the method disclosed in the embodiment of the present disclosure can be directly embodied as a hardware decoding processor to execute, or the hardware and software modules in the decoding processor can be combined to execute. The software module can be located in a storage medium, which is located in the memory 402. The processor 401 reads the information in the memory 402 and completes the steps of the above method in combination with its hardware.
[0164] In some embodiments, the electronic device 40 can be implemented by one or more application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), general-purpose processors, controllers, microcontrollers (MCUs), microprocessors, or other electronic components to execute the aforementioned method.
[0165] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.
[0166] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of the present disclosure, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0167] The above is only a specific embodiment of the present disclosure, but the protection scope of the present disclosure is not limited thereto. Any person skilled in the art who is familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present disclosure, which should be included in the protection scope of the present disclosure. Therefore, the protection scope of the present disclosure should be based on the protection scope of the claims.
Claims
1. A scheduling method, characterized in that: The method comprises: Determine first information of each service node in at least one service node, wherein the first information represents the utilization of resources of the service node, and the resources include at least one of the following: computing resources, memory resources, network bandwidth resources, and storage space resources; Receiving a service request from a first terminal, the service request carrying first task information requested to be executed by the first terminal, the first task information representing information of the task requested to be executed by the first terminal; In response to the service request, predicting first resource information of the first terminal according to the first task information by using a target model, wherein the first resource information represents occupation of service node resources by the first terminal in a first time period in the future; According to the first resource information and the first information of each service node, a target service node is determined from the at least one service node, and the first terminal is scheduled to the target service node.
2. The method according to claim 1, characterized in that Predicting first resource information of the first terminal according to the first task information using a target model includes: Using the target model to identify the first task information, and obtain first resource information; The first task information includes at least one of the following: task type, task data size, task start time, task end time, and task duration; The first resource information includes at least one of the following: a computing resource occupancy value, a memory resource occupancy value, a network bandwidth resource occupancy value, and a storage space resource occupancy value.
3. The method according to claim 2, characterized in that The method further comprises: Acquire a training data set, wherein the training data set includes at least one training data; Using the training data set to train the neural network model to obtain the target model; The training data includes: sample task information and labels corresponding to the sample task information; The sample task information includes at least one of the following: task type, data size corresponding to the task, task start time, task end time, and task duration; The tag includes at least one of the following: a computing resource occupancy value, a memory resource occupancy value, a network bandwidth resource occupancy value, and a storage space resource occupancy value in a first future time period.
4. The method according to claim 1, characterized in that The method further comprises: Determine first task information or task execution information of a second terminal served by each service node; Predicting second resource information of each second terminal according to the first task information or task execution information of the second terminal, where the second resource information represents occupation of service node resources by the second terminal in a future first time period; Predicting resource utilization of each of the service nodes in a first future time period according to the first resource information and the second resource information; Correspondingly, determining a target service node from the at least one service node according to the first resource information and the first information of each service node includes: Determine a target service node that meets a first condition from the at least one service node according to the first resource information of the first terminal, the first information of each service node, and the resource utilization rate of each service node in a future first time period; Wherein, the first condition is satisfied, including at least one of the following: The utilization rate of the current resources of the service node is less than the first threshold; The resource utilization of the service node in the future first time period is less than the second threshold.
5. The method according to claim 4, characterized in that Predicting second resource information of each second terminal according to the first task information or task execution information of the second terminal includes: If the duration of the second terminal joining the service node is less than the duration threshold, identifying the first task information of the second terminal by using the target model, and determining the second resource information of the second terminal; If the duration of the second terminal joining the service node is greater than or equal to the duration threshold, determine the resource occupation of the second terminal in the second time period, and determine the second resource information according to the resource occupation of the second terminal in the second time period.
6. The method according to claim 1, characterized in that The method further comprises: detecting resource occupancy of at least one second terminal in real time, and / or predicting second resource information of at least one second terminal; Determine a target second terminal that meets the second condition according to the resource occupancy of each second terminal detected in real time and / or the predicted second resource information of each second terminal; Scheduling the target second terminal to a service node that meets a third condition, or extending resources allocated by the service node to the target second terminal; Wherein, the second condition is satisfied, including at least one of the following: The current resource occupancy value is greater than the third threshold; In a third time period in the future, the resource occupancy value is greater than a third threshold; The third condition is satisfied, including at least one of the following: In idle state; The utilization rate of the service node resources is less than a fourth threshold.
7. The method according to claim 1, characterized in that The determining a target service node from the at least one service node according to the first resource information and the first information of each service node includes: determining a task type according to the first task information; Determining, according to the task type, at least one candidate service node from the at least one service node that provides a service corresponding to the task type; A target service node is determined from at least one candidate service node according to the first resource information and the first information of each candidate service node.
8. A scheduling device, characterized in that: The device comprises: A first acquisition module is used to determine first information of each service node in at least one service node, wherein the first information represents the utilization of resources of the service node, and the resources include at least one of the following: computing resources, memory resources, network bandwidth resources, and storage space resources; A second acquisition module is used to receive a service request from a first terminal, where the service request carries first task information requested to be executed by the first terminal, where the first task information represents information about the task requested to be executed by the first terminal; A first processing module, configured to respond to the service request and predict first resource information of the first terminal according to the first task information by using a target model, wherein the first resource information represents occupation of service node resources by the first terminal in a first time period in the future; The second processing module is used to determine a target service node from the at least one service node according to the first resource information and the first information of each service node, and schedule the first terminal to the target service node.
9. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory in communication with the at least one processor; wherein, The memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to execute: Determine first information of each service node in at least one service node, wherein the first information represents the utilization of resources of the service node, and the resources include at least one of the following: computing resources, memory resources, network bandwidth resources, and storage space resources; Receiving a service request from a first terminal, the service request carrying first task information requested to be executed by the first terminal, the first task information representing information of the task requested to be executed by the first terminal; In response to the service request, predicting first resource information of the first terminal according to the first task information by using a target model, wherein the first resource information represents occupation of service node resources by the first terminal in a first time period in the future; According to the first resource information and the first information of each service node, a target service node is determined from the at least one service node, and the first terminal is scheduled to the target service node.
10. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to cause the computer to execute: Determine first information of each service node in at least one service node, wherein the first information represents the utilization of resources of the service node, and the resources include at least one of the following: computing resources, memory resources, network bandwidth resources, and storage space resources; Receiving a service request from a first terminal, the service request carrying first task information requested to be executed by the first terminal, the first task information representing information of the task requested to be executed by the first terminal; In response to the service request, predicting first resource information of the first terminal according to the first task information by using a target model, wherein the first resource information represents occupation of service node resources by the first terminal in a first time period in the future; According to the first resource information and the first information of each service node, a target service node is determined from the at least one service node, and the first terminal is scheduled to the target service node.
Citation Information
Cited By
Task scheduling method and related equipment
CN120144243A
