Containerized AI micro-service mirror image layer scheduling method and device

By constructing an optimized objective function and a greedy sequential insertion algorithm in the edge cloud network system to optimize the image layer loading order, and combining it with a minimum thread load priority strategy, the problems of cold start latency and low resource utilization in containerized AI microservice image layer scheduling are solved, achieving more efficient image layer loading and resource utilization.

CN121050830APending Publication Date: 2025-12-02BEIJING UNIV OF POSTS & TELECOMM
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511137568.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-14
Publication Date
2025-12-02

AI Technical Summary

Technical Problem

Existing containerized AI microservice image layer scheduling methods suffer from high cold start latency and low thread resource utilization. In particular, they lack a collaborative optimization mechanism in multi-threaded concurrent environments, leading to frequent thread idles and conflicts.

Method used

By constructing an optimization objective function for the edge cloud network system, the greedy sequential insertion algorithm is used to optimize the image layer loading order. Combined with the thread load minimum priority strategy, the task queue of each thread in the thread set is determined, thereby achieving global optimization of image layer loading.

Benefits of technology

It effectively reduces the cold start latency of AI microservices, improves the utilization of multi-threaded resources, enhances the deployment elasticity of microservice systems, and optimizes the image layer loading order and thread resource allocation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121050830A_ABST
    Figure CN121050830A_ABST
Patent Text Reader

Abstract

The invention provides a containerized AI micro-service mirror image layer scheduling method and device, and relates to the technical field of containerized AI micro-service deploy.The method includes the steps that an optimized objective function for mirror image layer scheduling is constructed through a target node in an edge cloud network system, a mirror image layer is loaded and modeled into a sequence optimization problem with the high forward sub-modularity, and the sequence optimization problem is solved; and solving the optimization objective function by using a greedy sequence insertion algorithm to obtain a loading sequence of all mirror image layers. On this basis, a task queue of each thread in the thread set is determined in combination with a thread load minimum priority strategy; according to the method, global optimization of the loading sequence of the mirror image layer is realized, and the scheduling strategy can be dynamically adjusted according to the mirror image structure and the node resource state, so that the cold start time delay of the AI micro-service is effectively reduced, the multi-thread resource utilization rate is improved, and the deployment flexibility of the micro-service system is enhanced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the technical field of containerized AI microservice deployment, and in particular to a method and apparatus for scheduling containerized AI microservice image layers. Background Technology

[0002] In edge computing scenarios, with the widespread application of artificial intelligence models, containerization technology has become the mainstream form of AI microservice deployment. Compared with traditional virtual machines, containers have lighter resource consumption and faster startup speed, making them suitable for lightweight model inference tasks at the edge. Mainstream container platforms adopt a layered image structure, encapsulating the operating system, dependency libraries, and business logic in layers to achieve layer reuse and version management. Container runtime initializes the image through a layer-by-layer loading mechanism; if there is no local cache, it needs to be pulled remotely. Due to the resource limitations of edge nodes and network instability, multiple image layers need to be loaded during cold starts, and the time spent pulling images becomes a key factor affecting service availability.

[0003] During container startup, the loading order of image layers determines the availability time of critical resources and is a key factor affecting cold start latency. Although existing research has focused on optimizing the image layer loading order, it generally overlooks the coupling relationship between loading order and thread resources in a multi-threaded concurrent loading environment. The lack of a unified scheduling mechanism for their coordination leads to problems such as thread idleness and frequent conflicts in multi-threaded concurrent environments, weakening overall loading efficiency. Therefore, existing containerized AI microservice image layer scheduling methods suffer from high cold start latency and low thread resource utilization. Summary of the Invention

[0004] The purpose of this invention is to provide a containerized AI microservice image layer scheduling method and apparatus to alleviate the technical problems of high cold start latency and low thread resource utilization of existing containerized AI microservice image layer scheduling methods.

[0005] In a first aspect, the present invention provides a containerized AI microservice image layer scheduling method, comprising: acquiring the set of image layers, image layer dependency graph, bandwidth of the target node, cache status of all image layers on the target node and its communication neighbor nodes, data volume of each image layer, and decompression and mounting time of each image layer, which are dependent on each AI microservice to be deployed on the target node in an edge cloud network system; wherein, the target node represents any node in the edge cloud network system; and constructing an optimal method for image layer scheduling of the target node based on the set of image layers, image layer dependency graph, decompression and mounting time of each image layer, cache status of all image layers, data volume of each image layer, and bandwidth of the target node. The objective function is optimized; where the optimization objective function represents the service startup time of the last AI microservice to be started among all AI microservices to be deployed. Based on the image layer dependency graph, the cache status of all image layers on the target node and its communication neighbor nodes, and the user's response tolerance time for each AI microservice, the set of constraints for the optimization objective function is determined. Under the constraints of the set of constraints, the greedy sequential insertion algorithm is used to solve the optimization objective function to obtain the loading order of all image layers. Under the constraints of the target node's bandwidth and the preset concurrent thread capacity, based on the loading order of all image layers and the minimum thread load priority strategy, the task queue of each thread in the thread set of the target node is determined.

[0006] In an optional implementation, an optimization objective function for image layer scheduling on the target node is constructed based on the set of image layers that each AI microservice depends on, the image layer dependency graph, the decompression and mounting time of each image layer, the cache status of all image layers, the data volume of each image layer, and the bandwidth of the target node. This includes: calculating the loading time of the target image layer based on the decompression and mounting time of the target image layer, the cache status of the target image layer on the target node, the data volume of the target image layer, and the bandwidth of the target node; wherein, the target image layer represents any image layer among all image layers; determining all preceding dependent layers of the target image layer based on the image layer dependency graph; the sum of the loading completion time of the last preceding dependent layer to be loaded and the loading time of the target image layer is taken as the loading completion time of the target image layer; the loading completion time of the last image layer to be loaded in the set of image layers that the target AI microservice depends on is taken as the service startup time of the target AI microservice; wherein, the target AI microservice represents any AI microservice among all AI microservices to be deployed; and constructing an optimization objective function based on the service startup times of all target AI microservices.

[0007] In an optional implementation, based on the mirror layer dependency graph, the cache state of all mirror layers on the target node and its communication neighbor nodes, and the user's tolerance time for each AI microservice, a set of constraints for the optimization objective function is determined, including: determining mirror layer dependency constraints based on the mirror layer dependency graph; determining mirror layer scheduling constraints based on the cache state of all mirror layers on the target node and its communication neighbor nodes; determining service latency constraints based on the user's tolerance time for each AI microservice; and constructing a set of constraints for the optimization objective function based on the mirror layer dependency constraints, mirror layer scheduling constraints, and service latency constraints.

[0008] In an optional implementation, under the constraints of the constraint set, a greedy sequential insertion algorithm is used to solve the optimization objective function to obtain the loading order of all mirror layers. This includes: initializing the scheduling queue used to characterize the loading order of mirror layers to an empty queue; repeating the following steps until the loading order of all mirror layers is obtained; randomly selecting a mirror layer from the mirror layers whose loading order has not yet been determined to obtain the mirror layer to be sorted; under the constraints of the constraint set, enumerating all possible insertion positions of the mirror layer to be sorted in the current scheduling queue, and calculating the change in the objective function corresponding to each possible insertion position; wherein, the objective function represents the loading completion time of the scheduling queue after inserting the mirror layer to be sorted into the current scheduling queue; and taking the insertion position that minimizes the change in the objective function as the position of the mirror layer to be sorted in the current scheduling queue.

[0009] In an optional implementation, under the constraints of the target node's bandwidth and preset concurrent thread capacity, based on the loading order of all image layers and the minimum thread load priority strategy, the task queue of each thread in the target node's thread set is determined, including: under the constraints of the target node's bandwidth and preset concurrent thread capacity, determining the number of threads that pull image layers in parallel in the initial state, and the first image layer to be loaded in the task queue of each parallel pulling thread, based on the loading order of all image layers; repeating the following steps until all image layer loading tasks are mapped to the thread set; accumulating the loading time of all image layers to be loaded in the current task queue of each thread to obtain the current load of each thread; selecting the thread with the minimum current load as the target thread for the target node to load the next image layer.

[0010] In an optional implementation, the target mirror layer is located in the cache of the target node and / or the target node's communication neighbor nodes.

[0011] In an optional implementation, the mirror layer scheduling constraint includes: the target node is allowed to pull the target mirror layer from the target communication neighbor node only if the target mirror layer exists in the cache of the target communication neighbor node; wherein, the target communication neighbor node refers to any communication neighbor node of the target node.

[0012] Secondly, the present invention provides a containerized AI microservice image layer scheduling device, comprising: an acquisition module, configured to acquire the set of image layers, image layer dependency graph, bandwidth of the target node, cache status of all image layers on the target node and its communication neighbor nodes, data volume of each image layer, and decompression and mounting time of each image layer, for each AI microservice to be deployed on a target node in an edge cloud network system; wherein, the target node represents any node in the edge cloud network system; and a construction module, configured to construct an optimization objective function for image layer scheduling of the target node based on the set of image layers, image layer dependency graph, decompression and mounting time of each image layer, cache status of all image layers, data volume of each image layer, and bandwidth of the target node. The optimization objective function represents the service startup time of the last AI microservice to be deployed among all AI microservices. The first determining module is used to determine the set of constraints for the optimization objective function based on the image layer dependency graph, the cache status of all image layers on the target node and its communication neighbor nodes, and the user's response tolerance time for each AI microservice. The solving module is used to solve the optimization objective function using a greedy sequential insertion algorithm under the constraints of the set of constraints to obtain the loading order of all image layers. The second determining module is used to determine the task queue of each thread in the thread set of the target node based on the loading order of all image layers and the minimum thread load priority strategy, under the constraints of the target node's bandwidth and preset concurrent thread capacity.

[0013] Thirdly, the present invention provides an electronic device, including a memory and a processor, wherein the memory stores a computer program that can run on the processor, and the processor executes the computer program to implement the containerized AI microservice image layer scheduling method described in any of the foregoing embodiments.

[0014] Fourthly, the present invention provides a computer-readable storage medium storing computer instructions, which, when executed by a processor, implement the containerized AI microservice image layer scheduling method described in any of the foregoing embodiments.

[0015] This invention provides a method for scheduling image layers in containerized AI microservices. It constructs an optimization objective function for scheduling image layers on target nodes in an edge cloud network system, modeling image layer loading as a sequence optimization problem with strong forward submodularity. A greedy sequential insertion algorithm is then used to solve the optimization objective function, yielding the loading order of all image layers. Based on this, a minimum thread load priority strategy is combined to determine the task queue for each thread in the thread set. This invention achieves global optimization of the image layer loading order, dynamically adjusting the scheduling strategy according to the image structure and node resource status. This effectively reduces the cold start latency of AI microservices, improves multi-threaded resource utilization, and enhances the deployment elasticity of the microservice system. Attached Figure Description

[0016] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0017] Figure 1 A flowchart illustrating a containerized AI microservice image layer scheduling method provided in this embodiment of the invention; Figure 2 This is a comparison chart of microservice startup experiment results provided in an embodiment of the present invention; Figure 3 This is a comparison chart of storage resource utilization experimental results provided in an embodiment of the present invention; Figure 4 A comparison chart of startup times for various algorithms provided in embodiments of the present invention; Figure 5 A functional module diagram of a containerized AI microservice image layer scheduling device provided in an embodiment of the present invention; Figure 6 This is a schematic diagram of an electronic device provided in an embodiment of the present invention. Detailed Implementation

[0018] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.

[0019] Therefore, the following detailed description of the embodiments of the invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the invention without inventive effort are within the scope of protection of the invention.

[0020] The following detailed description of some embodiments of the present invention is provided in conjunction with the accompanying drawings. Unless otherwise specified, the following embodiments and features can be combined with each other.

[0021] To alleviate the problem of long container image loading times, existing technologies mainly focus on three aspects: image content optimization, layer caching mechanisms, and loading process control. Regarding content optimization, common methods include image trimming, merging, and basic layer reconstruction, aiming to improve layer reusability, reduce image size, and lower pull costs. As for caching mechanisms, mainstream container platforms achieve image layer reuse by locally caching loaded layers, avoiding repeated pulls; systems like Kubernetes support pre-pull mechanisms, which pre-load critical layers by setting image pull strategies or pre-warming containers to reduce startup latency during actual deployment.

[0022] In addition to the methods mentioned above, recent research has begun to focus on the impact of image layer loading order on startup performance. Some methods sort image layers based on access frequency, layer size, or historical loading time. For example, the LOPO algorithm optimizes layer priority based on pulling historical data, while the OCS method estimates loading time and prioritizes critical path layers. However, although existing research has focused on optimizing image layer loading order, it generally overlooks the close coupling between loading order and thread resources in a multi-threaded concurrent loading environment. The lack of a system mechanism for co-optimizing these two factors leads to some threads idling and frequent conflicts, thus weakening the actual effect of loading order optimization. In view of this, this invention provides a containerized AI microservice image layer scheduling method to alleviate the technical problems mentioned above.

[0023] Example 1 Figure 1 A flowchart of a containerized AI microservice image layer scheduling method provided in an embodiment of the present invention is shown below. Figure 1 As shown, the method specifically includes the following steps: Step S102: Obtain the set of image layers, the image layer dependency graph, the bandwidth of the target node, the cache status of all image layers on the target node and its communication neighbor nodes, the data volume of each image layer, and the decompression and mounting time of each image layer, which are dependent on each AI microservice to be deployed on the target node in the edge cloud network system.

[0024] Here, the target node refers to any node in the edge cloud network system.

[0025] This invention addresses the issue of high image retrieval latency during container cold starts by establishing a multi-threaded concurrent scheduling system model for edge nodes. The edge cloud network system consists of a group of edge nodes, denoted as... , This represents the total number of nodes in the edge cloud network system, and the target (edge) node. It has a fixed bandwidth. Preset concurrent thread capacity and local image layer cache capacity , The preset concurrent thread capacity represents the maximum number of threads that can concurrently pull data from the target node in any time slot.

[0026] Container images are organized in a layered structure and target specific nodes in an edge cloud network system. The set of AI microservices to be deployed is represented as , This represents the total number of AI microservices to be deployed. The set of image layers that are relied upon is represented as , , , This represents the union of the image layers that all AI microservices to be deployed depend on. , The set represents the total number of image layers to be loaded for the target node. The i-th mirror layer The amount of data is expressed as Mirror layer The decompression and mounting times are expressed as follows: In this embodiment of the invention, the image layer does not belong to any specific microservice, but rather serves as a shared foundational component for all microservices that depend on it. Any image layer only needs to be pulled once by the target node to be used by all microservices that depend on it, thus avoiding the problem of redundant loading.

[0027] In this embodiment of the invention, each node can pre-cache several image layers within the capacity constraint of its local image layer cache capacity. Already at the target node In the cache, the cache tag is... ,otherwise Therefore, obtaining the cache status of all mirror layers on the target node and its communication neighbor nodes is equivalent to determining the set of mirror layers currently cached by each of the above nodes (the target node and its communication neighbor nodes).

[0028] In a typical edge microservice deployment system, service images consist of multiple read-only layers with explicit dependency structures between them. This is typically represented as a directed acyclic graph (DAG), denoted as the image layer dependency graph. This means that loading some image layers depends on the completion of other layers. For example, if image layer X depends on image layers Y and Z, then image layers Y and Z must be loaded before image layer X can be loaded.

[0029] Step S104: Based on the set of image layers that each AI microservice depends on, the image layer dependency graph, the decompression and mounting time of each image layer, the cache status of all image layers, the data volume of each image layer, and the bandwidth of the target node, construct an optimization objective function for the target node to schedule image layers.

[0030] The optimization objective function represents the service startup time of the last AI microservice to be started among all the AI ​​microservices to be deployed.

[0031] Specifically, according to the definition of the optimization objective function above, in order to construct the optimization objective function, it is necessary to determine the target node. The service startup time of each AI microservice to be deployed, and the AI ​​microservice The service startup time depends on the set of image layers it depends on. The loading completion time of the last image layer to be loaded is denoted as: ,in, Represents the mirror layer Loading completion time AI microservices The service startup time. In this embodiment of the invention, the image layer The loading completion time consists of the following three parts: 1. The time determined by the image layer dependency graph. 1. The loading completion time of the last dependent layer to finish loading among all dependent image layers (denoted as preceding dependent layers); 2. Based on the image layers on the target node. Cache status, image layer The mirror layer is determined by the amount of data and the bandwidth of the target node. Retrieval time 3. Mirror layer The time required for decompression and mounting.

[0032] Based on the above analysis, we can see that, according to the set of image layers that each AI microservice depends on, the image layer dependency graph, the cache status of all image layers, the data volume of each image layer, the bandwidth of the target node, and the decompression and mounting time of each image layer, we can construct an optimization objective function for image layer scheduling on the target node. The optimization variable of this objective function is the set of... Loading order of all mirror layers , , This represents the i-th loaded image layer.

[0033] Step S106: Based on the mirror layer dependency graph, the cache status of all mirror layers on the target node and its communication neighbor nodes, and the user's response tolerance time for each AI microservice, determine the set of constraints for optimizing the objective function.

[0034] The dependency graph of the image layers determines the dependencies between them, thus limiting the order in which some image layers can be fetched. Based on the cache status of all image layers on the target node and its communicating neighbor nodes, the cached image layers on the target node and on each of its communicating neighbor nodes can be determined, thus limiting the range of image layers the target node can fetch from each communicating neighbor node. The startup time of each AI microservice must not exceed the user's response tolerance; therefore, the user's response tolerance time for each AI microservice limits the loading order of some image layers. These constraints constitute the set of constraints for solving the optimization objective function.

[0035] Step S108: Under the constraints of the constraint set, the greedy sequential insertion algorithm is used to solve the optimization objective function to obtain the loading order of all mirror layers.

[0036] It is known that the order in which image layers are loaded has a decisive impact on the final service startup time. Therefore, this embodiment of the invention models the loading order of image layers as an optimization variable in the objective function, minimizing the overall service startup latency by rationally scheduling the loading order of image layers. Analysis of the structural characteristics of the objective function reveals that it aims to optimize for the earliest service startup time. Considering node resources, image layer dependencies, and the scheduling space formed by the local and neighboring cache states of image layers, it belongs to a resource-constrained strong forward submodular optimization problem. That is, the objective function satisfies "strong forward submodularity".

[0037] To better understand the "strong forward submodularity," let's take an example: for any two mirror layer scheduling sequences... Insert into the same mirror layer The resulting change in the objective function satisfies: . This indicates the time it takes for the scheduling queue to complete loading.

[0038] This characteristic means that, given a shorter current scheduling sequence, the insertion of a particular mirror layer is more likely to significantly impact the target value. Leveraging this mathematical property, this invention employs a Greedy Sequential Insertion (GSI) algorithm to solve the objective function under constraints, gradually obtaining the loading order of all mirror layers. This method not only guarantees near-optimal theoretical performance but also adapts online to complex deployment structures and multi-threaded scheduling constraints. It intelligently constructs loading sequences without relying on training data or fixed rules, filling the technical gap in current container loading optimization that lacks a unified modeling framework.

[0039] Step S110: Under the constraints of the target node's bandwidth and preset concurrent thread capacity, determine the task queue of each thread in the target node's thread set based on the loading order of all image layers and the minimum thread load priority strategy.

[0040] As defined by the preset concurrent thread capacity, it limits the maximum number of threads that can concurrently pull images from the target node in any given time slot. Pulling image layers requires bandwidth; therefore, the target node's bandwidth limits the number of image layers that can be concurrently pulled in the same time slot. After determining the loading order of all image layers, this embodiment of the invention, under the constraints of the two concurrent thread pulling settings mentioned above, determines the task queue of each thread in the target node's thread set according to the minimum thread load priority strategy. Simply put, when all thread task queues are not empty, the thread with the lowest thread load is selected to process the next image layer to be scheduled in the loading order, where the thread load is the sum of the loading times of all image layers to be scheduled in its current task queue.

[0041] This invention provides a method for scheduling image layers in containerized AI microservices. It constructs an optimization objective function for scheduling image layers on target nodes in an edge cloud network system, modeling image layer loading as a sequence optimization problem with strong forward submodularity. A greedy sequential insertion algorithm is then used to solve the objective function, yielding the loading order of all image layers. Based on this, a minimum thread load priority strategy is combined to determine the task queue for each thread in the thread set. This invention achieves global optimization of the image layer loading order, dynamically adjusting the scheduling strategy according to the image structure and node resource status. This effectively reduces the cold start latency of AI microservices, improves multi-threaded resource utilization, and enhances the deployment elasticity of the microservice system.

[0042] In an optional implementation, step S104 above, based on the set of image layers that each AI microservice depends on, the image layer dependency graph, the decompression and mounting time of each image layer, the cache status of all image layers, the data volume of each image layer, and the bandwidth of the target node, constructs an optimization objective function for image layer scheduling of the target node, specifically including the following steps: Step S1041: Calculate the loading time of the target image layer based on the decompression and mounting time of the target image layer, the cache status of the target image layer on the target node, the data volume of the target image layer, and the bandwidth of the target node; where the target image layer represents any image layer among all image layers.

[0043] In this embodiment of the invention, the formula for calculating the loading time of the mirror layer is: ;in, Represents the mirror layer Retrieval time, Represents the mirror layer The decompression and mounting time, , Represents the target node upper mirror layer The cache tag, if the mirror layer Already at the target node In the cache, the cache tag is... If the mirror layer Not at the target node In the cache, then , Represents the mirror layer The amount of data, Represents the target node The bandwidth.

[0044] According to the above formula for loading time, when hour, That is, if the target node has already cached the image layer locally. Then the mirror layer The loading time is only the time for decompression and mounting. When At that time, the target node needs to retrieve the image from the cache. Pull the mirror layer on the communication neighbor node .

[0045] In this embodiment of the invention, the target image layer is located in the cache of the target node and / or its communication neighbor nodes. That is, the image layer upon which the AI ​​microservice to be deployed on the target node depends must already be cached locally on the target node and / or its communication neighbor nodes, as shown below. This does not consider the case of pulling data from a remote mirror layer database.

[0046] Step S1042: Determine all preceding dependent layers of the target mirror layer based on the mirror layer dependency graph.

[0047] Step S1043: The sum of the loading completion time of the last pre-dependent layer that has been loaded and the loading time of the target image layer is taken as the loading completion time of the target image layer.

[0048] Specifically, the formula for calculating the loading completion time of the mirror layer is: ,in, Represents the mirror layer The set consisting of all preceding dependency layers, Represents the mirror layer Loading completion time Represents the mirror layer Loading time This indicates the loading completion time of the last preceding dependency layer among all preceding dependency layers, i.e., the mirror layer. Start loading time .

[0049] Step S1044: The loading completion time of the last image layer in the set of image layers that the target AI microservice depends on is taken as the service startup time of the target AI microservice; where the target AI microservice refers to any AI microservice among all AI microservices to be deployed.

[0050] The set of mirror layers can be calculated through steps S1041-S1043 above. The loading completion time of each image layer. Based on this, the service startup time of the target AI microservice is expressed as: , Indicates target AI microservices The set of image layers it depends on The loading completion time of the last image layer to be loaded.

[0051] Step S1045: Construct an optimization objective function based on the service startup time of all target AI microservices. The expression for the optimization objective function is: , This indicates the service startup time of the last AI microservice to be started among all the AI ​​microservices to be deployed.

[0052] In an optional implementation, step S106 above, based on the mirror layer dependency graph, the cache status of all mirror layers on the target node and its communication neighbor nodes, and the user-side response tolerance time for each AI microservice, determines the set of constraints for optimizing the objective function, specifically including the following steps: Step S1061: Determine the dependency constraints of the mirror layer based on the mirror layer dependency graph.

[0053] The meaning of mirror layer dependency has been explained above. Therefore, if the mirror layer... The preceding dependency layer includes a mirror layer. Then the mirror layer dependency constraint can be expressed as: , Represents the mirror layer In loading order The sorting position in Represents the mirror layer In loading order The sorting position in the image, that is, the mirror layer. Must be in the mirror layer Loading will follow.

[0054] Mirror layer dependency constraints can also be expressed as: That is, the mirror layer. The start loading time in the image layer After the loading completion time (in this case, the mirror layer) (There are other preceding dependency layers), or, mirror layers. The start loading time is equal to the image layer. Loading completion time (in this case, for mirror layers) There are no other preceding dependency layers.

[0055] Step S1062: Determine the mirror layer scheduling constraints based on the cache status of all mirror layers on the target node and its communication neighbor nodes.

[0056] In this embodiment of the invention, the mirror layer scheduling constraint includes: the target node is allowed to pull the target mirror layer from the target communication neighbor node only if the target mirror layer exists in the cache of the target communication neighbor node; wherein, the target communication neighbor node refers to any communication neighbor node of the target node.

[0057] Based on this, the scheduling constraints of the mirror layer are expressed as follows: ,in, Indicates the target node used to characterize time slot t. From its communication neighbor nodes Pull the mirror layer The scheduling state variables, Indicates the target node in time slot t upper mirror layer Cache tags, Indicates the neighbor node in time slot t. upper mirror layer Cache tags, .

[0058] When in , At that time, according to the above constraints, it can be seen that The value can be either 0 or 1, that is, time slot t allows the target node From its communication neighbor nodes Pull the mirror layer However, it does not restrict whether this fetch is executed, because the target node... Mirror layers can also be found in other caches. The neighboring nodes perform the pull operation. Mirror layer scheduling constraints can prevent illegal access and scheduling failures during the scheduling process.

[0059] Step S1063: Based on the user's tolerance time for the response time of each AI microservice, determine the service latency constraints. The service latency constraints are expressed as follows: , This indicates the user's perspective on AI microservices. Response tolerance time.

[0060] Step S1064: Based on the image layer dependency constraints, image layer scheduling constraints, and service delay constraints, construct a set of constraints for optimizing the objective function.

[0061] In an optional implementation, step S108 above, under the constraints of the constraint set, uses a greedy sequential insertion algorithm to solve the optimization objective function to obtain the loading order of all mirror layers, specifically including the following steps: Step S1081: Initialize the scheduling queue used to characterize the loading order of the image layer into an empty queue.

[0062] Step S1082: Repeat steps S1083 to S1085 until the loading order of all mirror layers is obtained.

[0063] Step S1083: Randomly select a mirror layer from the mirror layers whose loading order has not yet been determined to obtain the mirror layers to be sorted.

[0064] Step S1084: Under the constraints of the constraint set, enumerate all insertable positions of the image layer to be sorted in the current scheduling queue, and calculate the change of the objective function corresponding to each insertable position; wherein, the objective function represents the loading completion time of the scheduling queue after inserting the image layer to be sorted into the current scheduling queue.

[0065] Step S1085: The insertion position that minimizes the change in the objective function is taken as the position of the image layer to be sorted in the current scheduling queue.

[0066] As described above, the solution for the mirror layer loading order begins when the scheduling queue is empty. In each round, an unscheduled mirror layer is selected. Under the constraints of the constraint set, all possible insertion positions of the layer in the current scheduling sequence are enumerated, and the change in the objective function after insertion is evaluated. Finally, the insertion scheme that minimizes the increase in the objective function is selected, and the layer is inserted into the current scheduling queue. This process is repeated iteratively until all mirror layers are scheduled.

[0067] The scheduling process for the aforementioned image layers takes into account multiple factors, including the sharing between image layers and loading time. Compared to traditional heuristic-based methods, this algorithm achieves better service startup latency under multi-threaded loading conditions and possesses good scalability and deployment adaptability, making it suitable for large-scale parallel deployment scenarios of microservices.

[0068] In an optional implementation, step S110 above, under the constraints of the target node's bandwidth and preset concurrent thread capacity, determines the task queue of each thread in the target node's thread set based on the loading order of all image layers and the minimum thread load priority strategy, specifically including the following steps: Step S1101: Under the constraints of the target node's bandwidth and the preset concurrent thread capacity, determine the number of threads for parallel image layer retrieval in the initial state and the first image layer to be loaded in the task queue of each parallel image layer based on the loading order of all image layers.

[0069] Step S1102: Repeat steps S1103 to S1104 until all image layer loading tasks are mapped to thread sets.

[0070] Step S1103: The loading time of all image layers to be loaded in the current task queue of each thread is accumulated to obtain the current load of each thread.

[0071] Step S1104: Select the thread with the lowest current load as the target thread for loading the next image layer on the target node.

[0072] Specifically, the target node is known. The default concurrent thread capacity is Therefore, in any given time slot, the number of threads concurrently pulling data from the target node must not exceed [a certain limit]. The target node is known. The bandwidth is Therefore, when multiple threads concurrently pull image layers, the sum of image layers pulled concurrently in each time slot must not exceed the bandwidth limit. In other words, the bandwidth constraint is expressed as: ,in, This represents the set of mirror layers concurrently pulled in time slot t. , Represents the mirror layer The amount of data, Represents the mirror layer The loading time.

[0073] Based on the loading order of all the mirror layers already solved above, the order of loading the target node can be determined. A mirror layer, but this Whether a single image layer can be pulled concurrently depends on bandwidth constraints. Specifically, if the loading order includes the first... If loading multiple image layers simultaneously cannot meet the bandwidth constraint, then attempt to fetch the first image layer in the parallel loading order. If the bandwidth constraint is met at this time, then the number of threads that pull the image layer in parallel in this time slot is determined to be [number]. ,Should A thread from Randomly select from the threads, and then compare with the previous ones. Each mirror layer can be randomly matched. If the parallel fetching and loading order is earlier... If the bandwidth constraint cannot be met even with one mirror layer, the number of parallel threads will continue to be reduced until the bandwidth constraint is met. The above describes a method of gradually reducing the number of parallel threads to determine the allowed number of threads for parallel fetching. Users can also set it to gradually increase from a single thread to multiple parallel threads to determine the allowed number of threads for parallel fetching.

[0074] Next, this embodiment of the invention uses a minimum thread load priority strategy to gradually determine the task queue of each thread. Specifically, it first uses the formula... Computation thread The current load, Represents thread The current set of image layers to be loaded in the task queue. Then, the thread with the lowest current load is selected as the target thread for loading the next image layer, in order to reduce the overall waiting time. The target thread is represented as: .

[0075] Under the constraints of bandwidth and the number of parallel fetching threads, guided by the minimum thread load priority strategy, the corresponding scheduling thread can be selected for each image layer in turn based on the loading order of all image layers. This binds the image layer scheduling sequence with thread resources, so that the loading tasks of the image layers are scientifically mapped to the thread set for execution.

[0076] In summary, the method proposed in this invention effectively alleviates container cold start latency and improves service deployment efficiency through global optimization of the image layer loading order. This method models the image layer scheduling problem as a strong forward submodular optimization problem and employs a greedy sequential insertion algorithm to generate a thread-aware image layer loading sequence while ensuring a theoretical approximation ratio. Compared with existing heuristic strategies such as sorting by layer size or static topology depth, this invention achieves significant improvements in performance optimization and system adaptability. Specific technical effects are verified through the following experimental results.

[0077] First, under cold start conditions, i.e., when all image layers are not pre-cached, the microservice startup time using the method of this invention is reduced by 91.04%, 85.58%, and 88.22% respectively compared to the traditional Local Search Algorithm (LASA), Greedy Algorithm (LOPO), and No-Repeating Scheduling Strategy (OCS), significantly improving system response efficiency and demonstrating the crucial role of the "layer re-scheduling phase" in cold start scenarios. Figure 2 As shown, the method of the present invention can prioritize scheduling the bottleneck layer on the critical path, reduce thread contention and loading blocking, thereby effectively compressing the overall startup time.

[0078] Secondly, the method of this invention also significantly improves the utilization efficiency of system storage resources. For example... Figure 3 As shown, under the same test conditions, the cache hit rate achieved by this invention reaches 96.79%, exceeding that of other algorithms by 43.95%, 2.75%, and 2.61%, respectively. This performance improvement indicates that this method can better coordinate the layer loading order and image reuse relationship, reduce repeated fetch operations, minimize unnecessary remote layer fetching, effectively reduce bandwidth burden, and improve cache utilization.

[0079] In further testing, the scheduling performance of the GSI algorithm, the traditional greedy algorithm, and the local search algorithm under a multi-threaded configuration was compared, such as... Figure 4 As shown, the method of this invention exhibits lower system startup time across all thread count settings. The total system latency significantly decreases as the number of threads increases from 1 to 3, thanks to the algorithm's good adaptation to thread parallelism. When the number of threads continues to increase from 3 to 5, the system startup time slightly rebounds, mainly because bandwidth bottlenecks limit the ability of multiple threads to simultaneously pull the image layer, leading to network congestion. Nevertheless, the GSI algorithm maintains superior overall scheduling performance compared to other algorithms in this scenario, demonstrating strong resource adaptability and system stability.

[0080] Therefore, it can be seen that the method proposed in the embodiments of the present invention is theoretically based on submodal optimization modeling, with clear performance guarantees. In engineering practice, it can effectively reduce service cold start latency, improve cache hit rate, optimize thread resource allocation, and maintain high system scheduling performance under different resource configurations. It has good application promotion value and engineering adaptability.

[0081] Example 2 This invention also provides a containerized AI microservice image layer scheduling device, which is mainly used to execute the containerized AI microservice image layer scheduling method provided in Embodiment 1 above. The following is a detailed description of the containerized AI microservice image layer scheduling device provided in this invention.

[0082] Figure 5 A functional block diagram of a containerized AI microservice image layer scheduling device provided in an embodiment of the present invention is shown below. Figure 5 As shown, the device mainly includes: an acquisition module 10, a construction module 20, a first determination module 30, a solution module 40, and a second determination module 50, wherein: The acquisition module 10 is used to acquire the set of image layers, the image layer dependency graph, the bandwidth of the target node, the cache status of all image layers on the target node and its communication neighbor nodes, the data volume of each image layer, and the decompression and mounting time of each image layer, which are all dependent on each AI microservice to be deployed on the target node in the edge cloud network system; wherein, the target node refers to any node in the edge cloud network system.

[0083] Module 20 is used to construct an optimization objective function for image layer scheduling on the target node based on the set of image layers that each AI microservice depends on, the image layer dependency graph, the decompression and mounting time of each image layer, the cache status of all image layers, the data volume of each image layer and the bandwidth of the target node; where the optimization objective function represents the service startup time of the last AI microservice to be started among all the AI ​​microservices to be deployed.

[0084] The first determining module 30 is used to determine the set of constraints for optimizing the objective function based on the image layer dependency graph, the cache status of all image layers on the target node and its communication neighbor nodes, and the user's response tolerance time for each AI microservice.

[0085] The solver module 40 is used to solve the optimization objective function using a greedy sequential insertion algorithm under the constraints of the constraint set, and obtain the loading order of all mirror layers.

[0086] The second determining module 50 is used to determine the task queue of each thread in the thread set of the target node, based on the loading order of all image layers and the minimum thread load priority strategy, under the constraints of the target node's bandwidth and preset concurrent thread capacity.

[0087] This invention provides a containerized AI microservice image layer scheduling device. By constructing an optimization objective function for image layer scheduling of target nodes in an edge cloud network system, image layer loading is modeled as a sequence optimization problem with strong forward submodularity. A greedy sequential insertion algorithm is used to solve the optimization objective function, obtaining the loading order of all image layers. Based on this, a minimum thread load priority strategy is combined to determine the task queue for each thread in the thread set. This invention achieves global optimization of the image layer loading order, dynamically adjusting the scheduling strategy according to the image structure and node resource status, thereby effectively reducing the cold start latency of AI microservices, improving multi-threaded resource utilization, and enhancing the deployment elasticity of the microservice system.

[0088] Optionally, module 20 is specifically used for: The loading time of the target image layer is calculated based on the decompression and mounting time of the target image layer, the cache status of the target image layer on the target node, the data volume of the target image layer, and the bandwidth of the target node; where the target image layer represents any image layer among all image layers.

[0089] All preceding dependent layers of the target mirror layer are determined based on the mirror layer dependency graph.

[0090] The loading completion time of the target image layer is the sum of the loading completion time of the last completed dependency layer among all the dependency layers.

[0091] The loading completion time of the last image layer in the set of image layers that the target AI microservice depends on is taken as the service startup time of the target AI microservice; where the target AI microservice refers to any AI microservice among all AI microservices to be deployed.

[0092] Optimization objective function is constructed based on the service startup time of all target AI microservices.

[0093] Optionally, the first determining module 30 is specifically used for: Based on the mirror layer dependency graph, determine the mirror layer dependency constraints.

[0094] Based on the cache status of all mirror layers on the target node and its communication neighbor nodes, determine the mirror layer scheduling constraints.

[0095] Based on the user's tolerance time for the response of each AI microservice, service latency constraints are determined.

[0096] Based on the constraints of image layer dependency, bandwidth, image layer scheduling, thread scheduling, cache capacity, and service latency, a set of constraints is constructed for the optimization objective function.

[0097] Optionally, the solver module 40 is specifically used for: The scheduling queue, which is used to characterize the loading order of image layers, is initialized to an empty queue.

[0098] Repeat the following steps until you obtain the loading order of all mirror layers.

[0099] Randomly select one image layer from the image layers whose loading order has not yet been determined to obtain the image layers to be sorted.

[0100] Under the constraints of the set of constraints, enumerate all possible insertion positions of the unsorted mirror layer in the current scheduling queue, and calculate the change in the objective function corresponding to each possible insertion position; where the objective function represents the loading completion time of the scheduling queue after inserting the unsorted mirror layer into the current scheduling queue.

[0101] The insertion position that minimizes the change in the objective function will be the position of the unsorted mirror layer in the current scheduling queue.

[0102] Optionally, the second determining module 50 is specifically used for: Under the constraints of the target node's bandwidth and the preset concurrent thread capacity, the number of threads that pull image layers in parallel in the initial state is determined based on the loading order of all image layers, and the first image layer to be loaded in the task queue of each parallel pulling thread is determined.

[0103] Repeat the following steps until all image layer loading tasks are mapped to the thread set.

[0104] The loading time of all image layers to be loaded in the current task queue of each thread is accumulated to obtain the current load of each thread.

[0105] Select the thread with the lowest current load as the target thread for loading the next image layer on the target node.

[0106] Optionally, the target mirror layer is located in the cache of the target node and / or the target node's communicating neighbor nodes.

[0107] Optionally, the mirror layer scheduling constraints include: the target node is allowed to pull the target mirror layer from the target communication neighbor node only if the target mirror layer exists in the cache of the target communication neighbor node; wherein, the target communication neighbor node refers to any communication neighbor node of the target node.

[0108] Example 3 See Figure 6This invention provides an electronic device, which includes a processor 60, a memory 61, a bus 62, and a communication interface 63. The processor 60, the communication interface 63, and the memory 61 are connected via the bus 62. The processor 60 is used to execute executable modules, such as computer programs, stored in the memory 61.

[0109] The memory 61 may include high-speed random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Communication between this system network element and at least one other network element is achieved through at least one communication interface 63 (which can be wired or wireless), such as the Internet, wide area network, local area network, metropolitan area network, etc.

[0110] Bus 62 can be an ISA bus, PCI bus, or EISA bus, etc. The bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 6 The symbol is represented by a single double-headed arrow, but this does not mean that there is only one bus or one type of bus.

[0111] The memory 61 is used to store programs. After receiving an execution instruction, the processor 60 executes the program. The method executed by the apparatus defined by the process disclosed in any of the foregoing embodiments of the present invention can be applied to the processor 60 or implemented by the processor 60.

[0112] Processor 60 may be an integrated circuit chip with signal processing capabilities. In implementation, each step of the above method can be completed by the integrated logic circuitry in the hardware of processor 60 or by instructions in software form. Processor 60 can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this invention. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of this invention can be directly embodied in the execution of a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software modules can reside in random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. The storage medium is located in memory 61. Processor 60 reads the information in memory 61 and, in conjunction with its hardware, completes the steps of the above method.

[0113] The computer program product of the containerized AI microservice image layer scheduling method and apparatus provided in this embodiment of the invention includes a computer-readable storage medium storing processor-executable non-volatile program code. The instructions included in the program code can be used to execute the methods described in the preceding method embodiments. For specific implementation, please refer to the method embodiments, which will not be repeated here.

[0114] In addition, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0115] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a processor-executable, non-volatile, computer-readable storage medium. Based on this understanding, the technical solution of this invention, essentially, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0116] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.

[0117] In the description of this invention, it should be noted that the terms "center," "upper," "lower," "left," "right," "vertical," "horizontal," "inner," and "outer," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship commonly used when the product of this invention is in use. They are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this invention. In addition, the terms "first," "second," "third," etc., are only used to distinguish descriptions and should not be construed as indicating or implying relative importance.

[0118] Furthermore, terms such as "horizontal," "vertical," and "sag" do not imply that components must be absolutely horizontal or suspended, but rather that they can be slightly tilted. For example, "horizontal" simply means that its direction is more horizontal relative to "vertical," and does not mean that the structure must be completely horizontal, but can be slightly tilted.

[0119] In the description of this invention, it should also be noted that, unless otherwise explicitly specified and limited, the terms "set," "install," "connect," and "link" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.

[0120] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for scheduling containerized AI microservice image layers, characterized in that, include: The system obtains the set of image layers, the image layer dependency graph, the bandwidth of the target node, the cache status of all image layers on the target node and its communication neighbor nodes, the data volume of each image layer, and the decompression and mounting time of each image layer, which are all dependent on each AI microservice to be deployed on the target node in the edge cloud network system. The target node refers to any node in the edge cloud network system. Based on the set of image layers that each AI microservice depends on, the image layer dependency graph, the decompression and mounting time of each image layer, the cache status of all image layers, the data volume of each image layer, and the bandwidth of the target node, an optimization objective function for image layer scheduling of the target node is constructed; wherein, the optimization objective function represents the service startup time of the last AI microservice to be started among all AI microservices to be deployed; Based on the image layer dependency graph, the cache status of all image layers on the target node and its communication neighbor nodes, and the user's response tolerance time for each AI microservice, the set of constraints for the optimization objective function is determined. Under the constraints of the set of constraints, the optimization objective function is solved using a greedy sequential insertion algorithm to obtain the loading order of all mirror layers; Under the constraints of the target node's bandwidth and preset concurrent thread capacity, the task queue of each thread in the target node's thread set is determined based on the loading order of all image layers and the minimum thread load priority strategy.

2. The containerized AI microservice image layer scheduling method according to claim 1, characterized in that, Based on the set of image layers that each AI microservice depends on, the image layer dependency graph, the decompression and mounting time of each image layer, the cache status of all image layers, the data volume of each image layer, and the bandwidth of the target node, an optimization objective function for image layer scheduling of the target node is constructed, including: The loading time of the target image layer is calculated based on the decompression and mounting time of the target image layer, the cache status of the target image layer on the target node, the data volume of the target image layer, and the bandwidth of the target node; wherein, the target image layer represents any image layer among all image layers. Based on the mirror layer dependency graph, determine all the preceding dependency layers of the target mirror layer; The loading completion time of the target image layer is the sum of the loading completion time of the last pre-dependent layer among all the pre-dependent layers and the loading time of the target image layer. The loading completion time of the last image layer in the set of image layers that the target AI microservice depends on is taken as the service startup time of the target AI microservice; wherein, the target AI microservice refers to any AI microservice among all AI microservices to be deployed; The optimization objective function is constructed based on the service startup time of all target AI microservices.

3. The containerized AI microservice image layer scheduling method according to claim 1, characterized in that, Based on the mirror layer dependency graph, the cache status of all mirror layers on the target node and its communication neighbor nodes, and the user-side response tolerance time for each AI microservice, the set of constraints for the optimization objective function is determined, including: Based on the aforementioned mirror layer dependency graph, determine the mirror layer dependency constraints. Based on the cache status of all mirror layers on the target node and its communication neighbor nodes, determine the mirror layer scheduling constraints. Based on the user's tolerance time for the response time of each AI microservice, service latency constraints are determined. Based on the image layer dependency constraints, the image layer scheduling constraints, and the service latency constraints, a set of constraints for the optimization objective function is constructed.

4. The containerized AI microservice image layer scheduling method according to claim 1, characterized in that, Under the constraints of the aforementioned set of constraints, the greedy sequential insertion algorithm is used to solve the objective function, yielding the loading order of all mirror layers, including: Initialize the scheduling queue, which represents the loading order of image layers, to an empty queue; Repeat the following steps until the loading order of all image layers is obtained; Randomly select one image layer from the image layers whose loading order has not yet been determined to obtain the image layers to be sorted; Under the constraints of the set of constraints, enumerate all insertable positions of the image layer to be sorted in the current scheduling queue, and calculate the change of the objective function corresponding to each insertable position; wherein, the objective function represents the loading completion time of the scheduling queue after inserting the image layer to be sorted into the current scheduling queue; The insertion position that minimizes the change in the objective function will be used as the position of the image layer to be sorted in the current scheduling queue.

5. The containerized AI microservice image layer scheduling method according to claim 1, characterized in that, Under the constraints of the target node's bandwidth and preset concurrent thread capacity, based on the loading order of all image layers and the minimum thread load priority strategy, the task queue of each thread in the target node's thread set is determined, including: Under the constraints of the target node's bandwidth and the preset concurrent thread capacity, the number of threads that pull image layers in parallel in the initial state and the first image layer to be loaded in the task queue of each parallel pull thread are determined based on the loading order of all image layers. Repeat the following steps until all image layer loading tasks are mapped to the thread set; The loading time of all image layers to be loaded in the current task queue of each thread is accumulated to obtain the current load of each thread; The thread with the lowest current load is selected as the target thread for loading the next image layer on the target node.

6. The containerized AI microservice image layer scheduling method according to claim 2, characterized in that, The target mirror layer is located in the cache of the target node and / or the target node's communication neighbor nodes.

7. The containerized AI microservice image layer scheduling method according to claim 3, characterized in that, The mirror layer scheduling constraints include: the target node is allowed to pull the target mirror layer from the target communication neighbor node only if the target mirror layer exists in the cache of the target communication neighbor node; wherein, the target communication neighbor node refers to any communication neighbor node of the target node.

8. A containerized AI microservice image layer scheduling device, characterized in that, include: The acquisition module is used to acquire the set of image layers, the image layer dependency graph, the bandwidth of the target node, the cache status of all image layers on the target node and its communication neighbor nodes, the data volume of each image layer, and the decompression and mounting time of each image layer, which are all dependent on each AI microservice to be deployed on the target node in the edge cloud network system; wherein, the target node refers to any node in the edge cloud network system. The construction module is used to construct an optimization objective function for image layer scheduling of the target node based on the set of image layers that each AI microservice depends on, the image layer dependency graph, the decompression and mounting time of each image layer, the cache status of all image layers, the data volume of each image layer, and the bandwidth of the target node; wherein, the optimization objective function represents the service startup time of the last AI microservice to be started among all AI microservices to be deployed; The first determining module is used to determine the set of constraints for the optimization objective function based on the image layer dependency graph, the cache status of all image layers on the target node and its communication neighbor nodes, and the user's response tolerance time for each AI microservice. The solution module is used to solve the optimization objective function using a greedy sequential insertion algorithm under the constraints of the set of constraints, and to obtain the loading order of all mirror layers; The second determining module is used to determine the task queue of each thread in the thread set of the target node, based on the loading order of all image layers and the minimum thread load priority strategy, under the constraints of the bandwidth and preset concurrent thread capacity of the target node.

9. An electronic device comprising a memory and a processor, wherein the memory stores a computer program executable on the processor, characterized in that, When the processor executes the computer program, it implements the containerized AI microservice image layer scheduling method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions, which, when executed by a processor, implement the containerized AI microservice image layer scheduling method as described in any one of claims 1 to 7.