Server instance and server-free instance combined scheduling method and system

Through the joint scheduling method of server instances and serverless instances, using the delay compensation waste strategy, and combining the advantages of the two instances, the problem of low resource utilization and high cost of the machine learning inference service load is solved, and the problem of unknown demand is realized low-cost and efficient resource management.

CN118779099APending Publication Date: 2024-10-15SHANDONG UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410809268.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-21
Publication Date
2024-10-15

AI Technical Summary

Technical Problem

The uncertainty and volatility of machine learning inference service loads lead to low cloud server resource utilization. It is difficult for existing technology to effectively combine server instances and serverless instances to optimize costs, and it fails to achieve reasonable performance when future demand is unpredictable. resource scheduling.

Method used

This paper proposes a joint scheduling method with server instances and serverless instances, which uses a delay compensation strategy to determine whether there is waste based on the cumulative cost of serverless instances in the previous reservation period, and reserves server instances to reduce waste. Combining the advantages of both instances, adaptive scheduling handles machine learning inference load demands.

Benefits of technology

When future demands are unknown, low-cost processing of machine learning inference service loads is achieved, resource waste is reduced, cloud server usage costs are optimized, and performance requirements of inference services are met.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118779099A_ABST
    Figure CN118779099A_ABST
Patent Text Reader

Abstract

The invention discloses a joint scheduling method and system for instances with servers and instances without servers. The joint scheduling method comprises the following steps: acquiring a machine learning reasoning load demand; when the accumulated cost of the server-free instances in the current reservation period exceeds the cost of the server instances in one reservation period, showing that waste exists, reserving the server instances, adding phantom reservation, and updating the number of available server instances in the next reservation period until no waste exists; judging whether the number of server instances meets a machine learning reasoning load requirement or not; and if not, starting a new server-free instance to process the remaining machine learning reasoning load demand, and feeding back a processing result of the machine learning reasoning load until the demand is met. Under the condition that future demands are not predicted, a delay waste compensation method is adopted to jointly dispatch server instances and server-free instances, and the use cost of the cloud server is optimized on the premise that the inference service performance requirement is met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of cloud scheduling technology, and in particular to a method and system for joint scheduling of server instances and serverless instances. Background Art

[0002] The statements in this section merely provide background information related to the present invention and do not necessarily constitute prior art.

[0003] Driven by algorithmic innovations in the computer field and the increasing number of large data sets, machine learning reasoning service tasks are also increasing, such as language processing, image recognition, and recommendation systems. Machine learning reasoning service workloads are characterized by uncertainty, volatility, and the need for timely response. How to meet user latency requirements and process reasoning service workloads cost-effectively is an important research topic.

[0004] Cloud computing can flexibly provide computing resource services to cope with the uncertainty of inference task workloads and save costs. With the continuous development of cloud computing, the types of computing resources provided by cloud providers have been continuously enriched and improved, especially the rapid development of serverless instances. In the past, serverless instances had large performance fluctuations due to the lack of support from underlying hardware, and did not have enough memory space to accommodate some large inference service models. Now, with the continuous development of serverless instances, performance issues have been greatly improved, and there will no longer be problems with large performance fluctuations. In most cases, the performance requirements of inference services can be met. In addition, serverless instances can now select memory on their own, making it possible for them to handle online inference services.

[0005] Secondly, cloud providers currently offer two main billing models for server instances: on-demand billing and reserved billing. The reserved billing model offers price discounts, but requires a longer reservation period than the on-demand billing model. Serverless instances only have an on-demand, per-second billing method. Since the billing cycle of serverless instances is shorter, they are more suitable for handling fluctuating requests.

[0006] The biggest goal of cloud users is to obtain cloud server instances in a cost-optimal manner. Although it sounds feasible to simply obtain instances completely on demand, in reality, the resource cost is very high. Because by using reserved instances, you can use the instances for free or with a certain discount by paying a reservation fee in advance, which reduces the overall cost; on the other hand, if you only use reserved instances, when there is a sudden but short-lived fluctuating load, it will also waste service resources and increase costs.

[0007] Therefore, the fundamental reason why machine learning inference services affect the utilization of cloud service resources is the unpredictability of future demand and the waste of resources; the load of machine learning inference services is very volatile, so it is difficult to have a good prediction of its future load pattern, and most of the current related studies only consider either server instances or serverless instances separately, without considering the two types of servers together, which ultimately affects the utilization of cloud service resources. Summary of the invention

[0008] In order to solve the above problems, the present invention proposes a method and system for jointly scheduling server instances and serverless instances. In the absence of prediction of future demand, a delay compensation waste method is adopted to jointly schedule server instances and serverless instances. This method is suitable for adaptively judging whether to enable server instances or serverless instances to handle machine learning reasoning load demands when the machine learning reasoning load demands change dynamically, thereby optimizing the cloud server usage cost while meeting the reasoning service performance requirements.

[0009] In order to achieve the above object, the present invention adopts the following technical solution:

[0010] In a first aspect, the present invention provides a method for jointly scheduling a server instance and a serverless instance, comprising:

[0011] Get the machine learning inference load demand and the number of server instances currently in reserved state;

[0012] Determine whether there is waste in the accumulated cost of the serverless instance in the previous reservation period. When the accumulated cost of the serverless instance exceeds the cost of the server instance in one reservation period, it indicates waste. In this case, the server instance is reserved and the phantom reservation is increased. The number of available server instances in the next reservation period is updated until there is no waste.

[0013] Determine whether the number of server instances currently in the reserved state meets the machine learning inference load demand; if not, start a new serverless instance to handle the remaining machine learning inference load demand until the machine learning inference load demand is met, and then feedback the processing result of the machine learning inference load.

[0014] As an optional implementation method, after obtaining the machine learning inference load demand, the processing capability of the serverless instance is tested based on the machine learning inference load data, that is, the number of machine learning inference loads that can be processed simultaneously while meeting the latency requirements; at the same time, the machine learning inference loads that a serverless instance can process simultaneously while meeting the latency requirements are integrated into one inference service load task.

[0015] As an optional implementation method, the process of determining whether there is waste includes:

[0016] The serverless instances in the previous reservation period are divided into groups of two, and the cumulative cost of each group of serverless instances in the previous reservation period is calculated. Based on whether the cumulative cost of a group of serverless instances in the previous reservation period is greater than the cost of reserving a server instance for one reservation period, it is determined whether there is a waste of serverless instances.

[0017] As an optional implementation, the process of determining whether there is waste is expressed as follows:

[0018] Among them, the left side of the inequality represents the cumulative cost of a group of serverless instances in a reservation period counting forward from time t, and the right side of the inequality represents the cost of reserving a server instance for a reservation period; d is the number of machine learning inference load requirements at the current moment; p2 is the cost of the serverless instance; p1 is the cost of reserving a server instance for a reservation period; γ is the length of a reservation period.

[0019] As an optional implementation, phantom reservation is to mark the processing of waste to prevent repeated processing. Specifically, starting from the time t of the new reservation, the number of reserved server instances is increased by 1 in the previous reservation period, and the number of server instances in the previous reservation period does not actually change. This is called phantom reservation.

[0020] As an alternative implementation, the phantom reservation is represented by x i ←x i +1,i=t-γ+1,...,t-1; among them, x i represents the number of reserved server instances at time i, and γ represents a reservation period.

[0021] In a second aspect, the present invention provides a joint scheduling system with server instances and serverless instances, comprising:

[0022] An acquisition module is configured to obtain a machine learning inference load demand and a number of server instances currently in a reserved state;

[0023] The first scheduling module is configured to determine whether there is waste in the accumulated cost of the serverless instance in the previous reservation period, and when the accumulated cost of the serverless instance exceeds the cost of the server instance in a reservation period, it indicates that there is waste, and the server instance is reserved and the phantom reservation is increased, and the number of available server instances in the next reservation period is updated until there is no waste;

[0024] The second scheduling module is configured to determine whether the number of server instances currently in the reserved state meets the machine learning inference load demand; if not, a new serverless instance is started to process the remaining machine learning inference load demand until the machine learning inference load demand is met, and then the processing result of the machine learning inference load is fed back.

[0025] In a third aspect, the present invention provides an electronic device comprising a memory and a processor, and computer instructions stored in the memory and executed on the processor, wherein when the computer instructions are executed by the processor, the method described in the first aspect is performed.

[0026] In a fourth aspect, the present invention provides a computer-readable storage medium for storing computer instructions, wherein when the computer instructions are executed by a processor, the method described in the first aspect is performed.

[0027] In a fifth aspect, the present invention provides a computer program product, comprising a computer program, which, when executed by a processor, implements the method described in the first aspect.

[0028] Compared with the prior art, the present invention has the following beneficial effects:

[0029] The present invention proposes a method and system for jointly scheduling server instances and serverless instances. In the absence of a forecast of future demand, a delay compensation waste method is adopted to jointly schedule server instances and serverless instances. That is, server instances are reserved according to the waste of serverless instances in the previous reservation period. The lower unit price of server instances when the load is stable and the superiority of serverless instances in handling sudden and fluctuating loads are comprehensively utilized to handle machine learning inference service loads, so as to achieve a cost close to the optimal one and solve the waste problem when handling fluctuating machine learning inference loads.

[0030] The present invention proposes a joint scheduling method and system for server instances and serverless instances, which is suitable for adaptively judging whether to enable server instances or serverless instances to handle machine learning inference load demands when the machine learning inference load demands change dynamically. It can reduce the cost of cloud servers as much as possible while meeting the inference service performance requirements without any prior knowledge of future workloads.

[0031] The present invention proposes a method and system for jointly scheduling server instances and serverless instances. During the task running process, without any prior knowledge of future workloads, it is determined in real time whether the use of serverless instances in the previous reservation period has caused waste. If waste has occurred, the waste is compensated by reserving server instances, thereby scheduling more reasonable servers for machine learning reasoning tasks and optimizing the cost of cloud server use while ensuring the required performance.

[0032] Advantages of additional aspects of the present invention will be given in part in the following description, and in part will become obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0033] The accompanying drawings in the specification, which constitute a part of the present invention, are used to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute improper limitations on the present invention.

[0034] Figure 1 A flow chart of a method for jointly scheduling server instances and serverless instances provided in Example 1 of the present invention. DETAILED DESCRIPTION

[0035] The present invention will be further described below in conjunction with the accompanying drawings and embodiments.

[0036] It should be noted that the following detailed descriptions are exemplary and are intended to provide further explanation of the present invention. Unless otherwise specified, all technical and scientific terms used herein have the same meanings as those commonly understood by those skilled in the art to which the present invention belongs.

[0037] It should be noted that the terms used herein are only for describing specific embodiments, and are not intended to limit exemplary embodiments according to the present invention. As used herein, unless the context clearly indicates otherwise, the singular form is also intended to include the plural form. In addition, it should be understood that the terms "include" and "comprise" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0038] In the absence of conflict, the embodiments of the present invention and the features of the embodiments may be combined with each other.

[0039] The present invention proposes a joint scheduling method for server instances and serverless instances. The overall idea is: based on the received machine learning inference load demand and the expenses incurred by the serverless instances in the previous reservation period, it is determined whether there is any waste of serverless instance expenses in this reservation period. If no waste occurs, no operation is performed. If waste occurs, a strategy of delaying compensation for the waste is adopted, and a server instance is reserved to delay compensation for this part of the expenses incurred by the serverless instances only.

[0040] The specific process is as follows: initially, all workloads are assumed to be processed by serverless instances first. When each machine learning inference load demand arrives, the accumulated cost of a group of serverless instances in the most recent reservation period is checked forward. When the accumulated cost of a group of serverless instances exceeds the cost of a server instance for one reservation period, that is, when waste occurs, a server instance is reserved to replace this group of serverless instances; after the replacement is completed, the check is repeated until all waste is processed; at this time, if the current server instance cannot meet the current machine learning inference load demand, a new serverless instance is opened to handle this part of the demand.

[0041] Example 1

[0042] This embodiment provides a method for jointly scheduling a server instance and a serverless instance, including:

[0043] Get the machine learning inference load demand and the number of server instances currently in reserved state;

[0044] Determine whether there is waste in the accumulated cost of the serverless instance in the previous reservation period. When the accumulated cost of the serverless instance exceeds the cost of the server instance in one reservation period, it indicates waste. In this case, the server instance is reserved and the phantom reservation is increased. The number of available server instances in the next reservation period is updated until there is no waste.

[0045] Determine whether the number of server instances currently in the reserved state meets the machine learning inference load demand; if not, start a new serverless instance to handle the remaining machine learning inference load demand until the machine learning inference load demand is met, and then feedback the processing result of the machine learning inference load.

[0046] Combine the following Figure 1 The method of this embodiment is described in detail.

[0047] Step 1: Load collection and input;

[0048] Specifically:

[0049] Receive machine learning inference load data obtained by real-time sampling through an interface provided by the public cloud system;

[0050] The obtained machine learning inference load data is tested on the server to test the processing capacity of the serverless instance for machine learning inference load, that is, the number of machine learning inference loads that can be processed simultaneously while meeting the user's latency requirements;

[0051] The machine learning inference load that a serverless instance can handle simultaneously while meeting performance requirements is integrated into an inference service load task, which is convenient for scheduling to the serverless instance for processing.

[0052] For example, if a serverless instance can process five image inference requests at the same time without violating its tail latency, the five image processing requests are grouped together into one inference service workload task. Through this method, the real-time collected machine learning inference workload data is converted into an inference service task as input.

[0053] Step 2: No server instance waste judgment mechanism;

[0054] In the initial state, each machine learning inference load demand is processed by serverless instances by default. At the time node when each new machine learning inference load demand arrives, the usage of serverless instances within a reservation period is counted to determine whether there is any waste in the accumulated cost of serverless instances in the previous reservation period.

[0055] Specifically:

[0056] The serverless instances are grouped according to the performance difference between serverless instances and server instances. In general, server instances have better processing capabilities than serverless instances to meet latency requirements, so serverless instances are grouped according to their performance. Generally speaking, the request processing capacity of serverless instances is half of that of server instances. Therefore, the serverless instances in the previous reservation period are divided into groups of two to facilitate the calculation of whether serverless instances are wasted. Defined as: X - =min{X,2};

[0057] Calculate the cumulative cost of each group of serverless instances in the previous reservation period and compare it with the cost of reserving a server instance. Determine whether there is a waste of serverless instances based on whether the cumulative cost of a group of serverless instances in the previous reservation period is greater than the cost of a server instance. This is expressed as:

[0058]

[0059] The left side of the inequality represents the cumulative cost of a group of serverless instances in a reservation period counting forward from time t, and the right side of the inequality represents the cost of reserving a server instance for a reservation period; d is the number of machine learning inference load requirements at the current moment; p2 is the cost of the serverless instance; p1 is the cost of reserving a server instance for a reservation period; γ is the length of a reservation period; the values ​​of p1, p2 and γ are provided by the cloud computing platform provider.

[0060] When the cumulative cost of a group of serverless instances within a reservation period counting forward from time t is greater than the cost of reserving a server instance for a reservation period, it is determined that there is a waste state of serverless instances, and a reservation of the server instance is performed at this time; otherwise, it is determined that there is no serverless waste state, and no reservation operation is performed.

[0061] Step 3: When it is determined that there is a waste state of serverless instances, a reservation of server instances is made to compensate for this waste error; and each time a server instance is reserved, a phantom reservation is added to indicate that the current waste state has been processed to prevent repeated processing; after processing a reservation of a server instance, repeatedly check whether there is waste of serverless instances within the current reservation period until there is no waste.

[0062] Specifically:

[0063] Phantom reservation is: starting from the time t of the new reservation, the number of reserved server instances increases by 1 in the previous reservation period, and the number of server instances in the previous reservation period does not change. This method is called phantom reservation.

[0064] Adding a phantom reservation operation is to mark the processing of wasteful behavior to indicate that this part of waste has been processed to prevent repeated processing, which is expressed as:

[0065] x i ←x i +1,i=t-γ+1,...,t-1;

[0066] Among them, x i represents the number of reserved instances at this moment, and γ represents a reservation period.

[0067] Therefore, in the case where the serverless instances are overused in the previous reservation period and are in a wasted state, the cost can be made close to the optimal by reserving new server instances to compensate for the delay. It has been proved through theory and experiments that; in the case where the serverless instances are not overused in the previous reservation period, no new server instances are reserved. By maintaining the current number of instances and retaining the instances, the service cost is controlled to achieve a cost close to the optimal cost.

[0068] The specific implementation method is as follows:

[0069] (1) Obtain the machine learning inference load demand sequence d at a certain moment i , the number of server instances currently in the reservation state is x i , γ is the duration of a reservation period, r t is the number of newly reserved server instances at time t;

[0070] (2) For each time t, execute the following loop:

[0071] (2-1) Starting from time t, check forward one reservation period and calculate whether the total cost of a group of serverless instances in the previous reservation period exceeds the cost of a server instance reserved for one reservation period, that is, determine whether there is a waste in the accumulated cost of the serverless instances in the previous reservation period;

[0072] (2-2) If there is waste, reserve a server instance;

[0073] (2-3) After the server instance reservation is completed, the number of available server instances in a future reservation period is updated.

[0074] (2-4) Add a phantom reservation for the previous reservation period to indicate that this part has been processed.

[0075] (2-5) When there is no waste in the serverless instance, the loop is exited, and the serverless waste checking and compensation process ends.

[0076] Step 4: After jumping out of the loop, the delay compensation algorithm ends and determines whether the existing server instances meet the machine learning inference load requirements at this moment; if they do, the existing server instances are used to handle these requirements; if the existing server instances cannot handle the machine learning inference load requirements at this moment, the serverless instances are started to handle the remaining machine learning inference load requirements.

[0077] The pseudo code of the above joint scheduling method is shown in the following table:

[0078]

[0079] The most fundamental reason why machine learning reasoning services affect service costs is the unpredictability of future demand and the waste of resources. To this end, the method of this embodiment can adopt a delay compensation waste method to jointly schedule server instances and serverless instances in the absence of predictions of future demand to achieve close to optimal costs. Finally, the server scheduling situation is recorded in detail through the server instance scheduling log and the serverless instance scheduling log, which can be used to verify the cost saving effect of the server instance and serverless instance joint scheduling system.

[0080] Some related studies require good predictions of future demand conditions, but the workload of machine learning inference services is very volatile, and it is difficult to have a good prediction of its future load pattern. Other related studies mostly consider either server instances or serverless instances separately, without considering the two servers together.

[0081] The method of this embodiment is different from other related studies. The method of this embodiment jointly considers server instances and serverless instances, uses a delay compensation algorithm, and comprehensively utilizes the lower unit price of server instances when the load is stable and the superiority of serverless instances in handling sudden and fluctuating loads to handle machine learning inference service loads, thereby achieving a near-optimal cost without knowing the future load conditions.

[0082] It should be noted that all data is obtained in compliance with laws and regulations and user consent, and the data is used legally.

[0083] Example 2

[0084] This embodiment provides a server instance and serverless instance joint scheduling system, including:

[0085] An acquisition module is configured to obtain a machine learning inference load demand and a number of server instances currently in a reserved state;

[0086] The first scheduling module is configured to determine whether there is waste in the accumulated cost of the serverless instance in the previous reservation period, and when the accumulated cost of the serverless instance exceeds the cost of the server instance in a reservation period, it indicates that there is waste, and the server instance is reserved and the phantom reservation is increased, and the number of available server instances in the next reservation period is updated until there is no waste;

[0087] The second scheduling module is configured to determine whether the number of server instances currently in the reserved state meets the machine learning inference load demand; if not, a new serverless instance is started to process the remaining machine learning inference load demand until the machine learning inference load demand is met, and then the processing result of the machine learning inference load is fed back.

[0088] It should be noted that the above modules correspond to the steps described in Example 1, and the examples and application scenarios implemented by the above modules and the corresponding steps are the same, but are not limited to the contents disclosed in the above Example 1. It should be noted that the above modules, as part of the system, can be executed in a computer system such as a set of computer executable instructions.

[0089] In further embodiments, there is also provided:

[0090] An electronic device includes a memory and a processor, and computer instructions stored in the memory and executed on the processor, wherein when the computer instructions are executed by the processor, the method described in Embodiment 1 is performed. For the sake of brevity, it will not be described in detail here.

[0091] It should be understood that in this embodiment, the processor may be a central processing unit CPU, and the processor may also be other general-purpose processors, digital signal processors DSP, application-specific integrated circuits ASIC, off-the-shelf programmable gate arrays FPGA or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.

[0092] The memory may include a read-only memory and a random access memory, and provide instructions and data to the processor. A portion of the memory may also include a non-volatile random access memory. For example, the memory may also store information about the device type.

[0093] A computer-readable storage medium is used to store computer instructions, and when the computer instructions are executed by a processor, the method described in Example 1 is completed.

[0094] The method in Example 1 can be directly embodied as a hardware processor, or a combination of hardware and software modules in the processor. The software module can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware. To avoid repetition, it is not described in detail here.

[0095] A computer program product includes a computer program, and when the computer program is executed by a processor, the method described in embodiment 1 is implemented.

[0096] The present invention also provides at least one computer program product tangibly stored on a non-transitory computer-readable storage medium. The computer program product includes computer executable instructions, such as instructions included in a program module, which are executed in a device on a real or virtual processor of the target to perform the process / method as described above. Typically, program modules include routines, programs, libraries, objects, classes, components, data structures, etc. that perform specific tasks or implement specific abstract data types. In various embodiments, the functions of program modules can be combined or divided between program modules as needed. Machine executable instructions for program modules can be executed in local or distributed devices. In distributed devices, program modules can be located in local and remote storage media.

[0097] The computer program code for implementing the method of the present invention can be written in one or more programming languages. These computer program codes can be provided to the processor of a general-purpose computer, a special-purpose computer or other programmable data processing device, so that the program code, when executed by the computer or other programmable data processing device, causes the function / operation specified in the flow chart and / or block diagram to be implemented. The program code can be executed completely on a computer, partially on a computer, as an independent software package, partially on a computer and partially on a remote computer or completely on a remote computer or server.

[0098] In the context of the present invention, computer program codes or related data may be carried by any appropriate carrier to enable a device, apparatus or processor to perform the various processes and operations described above. Examples of carriers include signals, computer readable media, etc. Examples of signals may include electrical, optical, radio, acoustic or other forms of propagation signals, such as carrier waves, infrared signals, etc.

[0099] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with this embodiment can be implemented in electronic hardware or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0100] Although the above describes the specific implementation mode of the present invention in conjunction with the accompanying drawings, it is not intended to limit the scope of protection of the present invention. Those skilled in the art should understand that various modifications or variations that can be made by those skilled in the art on the basis of the technical solution of the present invention without creative work are still within the scope of protection of the present invention.

Claims

1. A method for jointly scheduling server instances and serverless instances, characterized in that: include: Get the machine learning inference load demand and the number of server instances currently in reserved state; Determine whether there is waste in the accumulated cost of the serverless instance in the previous reservation period. When the accumulated cost of the serverless instance exceeds the cost of the server instance in one reservation period, it indicates waste. In this case, the server instance is reserved and the phantom reservation is increased. The number of available server instances in the next reservation period is updated until there is no waste. Determine whether the number of server instances currently in the reserved state meets the machine learning inference load demand; if not, start a new serverless instance to handle the remaining machine learning inference load demand until the machine learning inference load demand is met, and then feedback the processing result of the machine learning inference load.

2. A method for jointly scheduling server instances and serverless instances as claimed in claim 1, characterized in that: After obtaining the machine learning inference load demand, test the processing capacity of the serverless instance based on the machine learning inference load data, that is, the number of machine learning inference loads that can be processed simultaneously while meeting the latency requirements; at the same time, integrate the machine learning inference loads that a serverless instance can process simultaneously while meeting the latency requirements into one inference service load task.

3. A method for jointly scheduling server instances and serverless instances as claimed in claim 1, characterized in that: The process of determining whether there is waste includes: The serverless instances in the previous reservation period are divided into groups of two, and the cumulative cost of each group of serverless instances in the previous reservation period is calculated. Based on whether the cumulative cost of a group of serverless instances in the previous reservation period is greater than the cost of reserving a server instance for one reservation period, it is determined whether there is a waste of serverless instances.

4. A method for jointly scheduling server instances and serverless instances as claimed in claim 3, characterized in that: The process of determining whether there is waste is expressed as: Among them, the left side of the inequality represents the cumulative cost of a group of serverless instances in a reservation period counting forward from time t, and the right side of the inequality represents the cost of reserving a server instance for a reservation period; d is the number of machine learning inference load requirements at the current moment; p2 is the cost of the serverless instance; p1 is the cost of reserving a server instance for a reservation period; γ is the length of a reservation period.

5. A method for jointly scheduling server instances and serverless instances as claimed in claim 1, characterized in that: Phantom reservation is to mark the processing of waste to prevent repeated processing. Specifically, starting from the time t of the new reservation, the number of reserved server instances increases by 1 in the next reservation period. The number of server instances in the previous reservation period does not actually change. This is called phantom reservation.

6. A method for jointly scheduling server instances and serverless instances as claimed in claim 5, characterized in that: Phantom reservation is represented by x i ←x i +1, i=t-γ+1,...,t-1; where, x i represents the number of reserved server instances at time i, and γ represents a reservation period.

7. A joint scheduling system with server instances and serverless instances, characterized in that: include: An acquisition module is configured to obtain a machine learning inference load demand and a number of server instances currently in a reserved state; The first scheduling module is configured to determine whether there is waste in the accumulated cost of the serverless instance in the previous reservation period, and when the accumulated cost of the serverless instance exceeds the cost of the server instance in a reservation period, it indicates that there is waste, and the server instance is reserved and the phantom reservation is increased, and the number of available server instances in the next reservation period is updated until there is no waste; The second scheduling module is configured to determine whether the number of server instances currently in the reserved state meets the machine learning inference load demand; if not, a new serverless instance is started to process the remaining machine learning inference load demand until the machine learning inference load demand is met, and then the processing result of the machine learning inference load is fed back.

8. An electronic device, characterized in that: The method comprises a memory and a processor and computer instructions stored in the memory and executed on the processor, wherein when the computer instructions are executed by the processor, the method according to any one of claims 1 to 6 is completed.

9. A computer-readable storage medium, characterized in that: Used to store computer instructions, which, when executed by a processor, complete the method described in any one of claims 1 to 6.

10. A computer program product, characterized in that The invention comprises a computer program, which, when executed by a processor, implements the method according to any one of claims 1 to 6.