Resource scheduling method and related device, equipment, system and storage medium

By preloading virtual avatar resources locally on the computing node and selecting the target node based on importance and remaining capacity, the problems of resource waste and latency in virtual avatar resource scheduling are solved, achieving efficient resource utilization and rapid response.

CN121705034BActive Publication Date: 2026-06-05IFLYTEK CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
IFLYTEK CO LTD
Filing Date
2026-02-11
Publication Date
2026-06-05

AI Technical Summary

Technical Problem

In existing technologies, resource scheduling for virtual avatars suffers from problems such as wasted computing node hardware resources and high loading latency. In particular, when fulfilling virtual avatar trigger requests, it is difficult to simultaneously improve resource utilization and reduce loading latency.

Method used

By preloading some virtual avatar resources in the local space of the computing node, and selecting the target node to respond to the trigger request based on the importance and remaining capacity, the loaded data is reused and additional data is loaded, thus realizing dynamic resource scheduling.

Benefits of technology

This improved the resource utilization of computing nodes, reduced loading latency, ensured timely response to virtual avatar trigger requests, and enhanced the system's flexibility and stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121705034B_ABST
    Figure CN121705034B_ABST
Patent Text Reader

Abstract

The application discloses a resource scheduling method and related device, equipment, system and storage medium, wherein the resource scheduling method comprises: sending an image resource package to each computing node in a computing cluster; in response to detecting a trigger request of a target image, selecting a computing node as a target node for responding to the trigger request based on resource data already loaded in a local space by each computing node and the remaining capacity of the local space; wherein the target node multiplexes first data already loaded in the local space in response to the trigger request, and additionally loads second data in the local space, the first data being resource data already loaded in the local space and required for loading the target image, and the second data being resource data not yet loaded in the local space and required for loading the target image. The above scheme can improve the resource utilization of the computing node under the premise of meeting the trigger request of the virtual image, and minimize the loading delay.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of cloud computing technology, and in particular to a resource scheduling method and related apparatus, equipment, system and storage medium. Background Technology

[0002] With the rapid iteration of virtual avatars, their application boundaries continue to expand, but the related resource scheduling and management are facing multiple severe challenges.

[0003] Currently, existing technologies mainly employ either static preloading or dynamic on-demand loading strategies. The former, by preloading all virtual avatars on a single node, leads to a significant waste of computing node hardware resources. The latter, based on "request-triggered loading," while alleviating resource redundancy to some extent, fails to address the critical issue of high loading latency. Therefore, how to improve computing node resource utilization and minimize loading latency while fulfilling virtual avatar trigger requests has become an urgent problem to be solved. Summary of the Invention

[0004] The main technical problem addressed by this application is to provide a resource scheduling method and related devices, equipment, systems, and storage media that can improve the resource utilization of computing nodes and minimize loading latency while satisfying the triggering requests of virtual avatars.

[0005] To address the aforementioned technical problems, the first aspect of this application provides a resource scheduling method, comprising: sending an image resource package to each computing node in a computing cluster; wherein the image resource includes resource data required by each virtual image in the interactive scene during loading, and the computing nodes preload at least some virtual images in their local space based on the importance of each virtual image; in response to a trigger request for a detected target image, selecting a computing node as the target node for responding to the trigger request based on the resource data already loaded in the local space of each computing node and the remaining capacity of the local space; wherein the target image is any one of the virtual images, and the target node, in response to the trigger request, reuses the first data already loaded in its local space and additionally loads the second data in its local space, wherein the first data is the resource data already loaded in the local space and required for loading the target image, and the second data is the resource data not yet loaded in the local space and required for loading the target image.

[0006] To address the aforementioned technical problems, a second aspect of this application provides a resource scheduling method, comprising: receiving an image resource package from a scheduling node; wherein the image resource package includes resource data required by each virtual image in the interactive scene during loading; loading at least some virtual images in advance in local space based on the importance of each virtual image; selecting a target node as the target node in response to a trigger request from a scheduled node based on a target image, reusing the first data already loaded in local space, and additionally loading the second data in local space; wherein the first data is resource data already loaded in local space and required for loading the target image, the second data is resource data not yet loaded in local space and required for loading the target image, the target image is any one of the virtual images, and the scheduling node selects a computing node as the target node for responding to the trigger request based on the resource data already loaded by each computing node in local space and the remaining capacity of local space.

[0007] To address the aforementioned technical problems, a third aspect of this application provides a resource scheduling device, comprising: a sending module and a selection module. The sending module is configured to send an image resource package to each computing node in a computing cluster; wherein the image resource includes resource data required by each virtual image in the interactive scene during loading, and the computing nodes preload at least some virtual images in their local space based on the importance of each virtual image; the selection module is configured to, in response to a trigger request for a detected target image, select a computing node as the target node for responding to the trigger request based on the resource data already loaded in the local space of each computing node and the remaining capacity of the local space; wherein the target image is any one of the virtual images, and the target node, in response to the trigger request, reuses the first data already loaded in its local space and additionally loads the second data in its local space, wherein the first data is the resource data already loaded in the local space and required for loading the target image, and the second data is the resource data not yet loaded in the local space and required for loading the target image.

[0008] To address the aforementioned technical problems, a fourth aspect of this application provides a resource scheduling device, comprising: a receiving module, a loading module, and a response module. The receiving module is used to receive an image resource package from a scheduling node; wherein the image resource package includes resource data required by each virtual image in the interactive scene during loading. The loading module is used to preload at least some virtual images in the local space based on the importance of each virtual image. The response module is used to select a target node in response to a trigger request from a scheduled node based on a target image, reuse the first data already loaded in the local space, and additionally load the second data in the local space. The first data is resource data already loaded in the local space and required to load the target image, and the second data is resource data not yet loaded in the local space and required to load the target image. The target image is any one of the virtual images, and the scheduling node selects a computing node as the target node for responding to the trigger request based on the resource data already loaded by each computing node in the local space and the remaining capacity of the local space.

[0009] To address the aforementioned technical problems, the fifth aspect of this application provides an electronic device, including a communication circuit, a memory, and a processor. The communication circuit and the memory are respectively coupled to the processor. The memory stores at least program instructions, and the processor executes the program instructions to implement the resource scheduling method in the first or second aspect described above.

[0010] To address the aforementioned technical problems, the sixth aspect of this application provides a resource scheduling system, including a scheduling node and several computing nodes communicatively connected to the scheduling node. The several computing nodes form a computing cluster, and the scheduling node is used to execute the resource scheduling method in the first aspect, while the computing nodes are used to execute the resource scheduling method in the second aspect.

[0011] To address the aforementioned technical problems, a seventh aspect of this application provides a computer-readable storage medium storing program instructions executable by a processor, the program instructions being used to implement the resource scheduling method in the first or second aspect described above.

[0012] The above scheme sends an image resource package to each computing node in the computing cluster. The image resource package contains the resource data required by each virtual image in the interactive scene when loading. The computing nodes pre-load at least a portion of the virtual images in their local space based on the importance of each virtual image. Then, in response to a trigger request that detects a target image, based on the resource data already loaded in each computing node's local space and the remaining capacity of the local space, a computing node is selected as the target node to respond to the trigger request. The target image is any one of the virtual images. The target node, in response to the trigger request, reuses the first data already loaded in its local space and additionally loads a second data in its local space. The first data is the resource data already loaded in the local space and required to load the target image, while the second data is the resource data not yet loaded in the local space and required to load the target image. This approach, on the one hand, ensures that the image resource package containing the resource data required by each virtual image when loading is sent... After being delivered to the compute nodes, the compute nodes preload at least a portion of the virtual avatars in their local space based on the importance of each avatar. Compared to full preloading, on-demand loading based on importance allows compute nodes to preload relatively important virtual avatars, enabling timely responses to their trigger requests. This helps improve the resource utilization of compute nodes while fulfilling the trigger requests of virtual avatars. Furthermore, by combining the resource data already loaded in the compute nodes' local space with the remaining capacity of the local space, a target node is selected to respond to the trigger requests. The target node reuses the first data already loaded in its local space—the resource data required to load the target avatar. Thus, the target node only needs to load the second data in its local space, minimizing loading latency. Therefore, this approach improves the resource utilization of compute nodes and minimizes loading latency while fulfilling the trigger requests of virtual avatars. Attached Figure Description

[0013] Figure 1 This is a flowchart illustrating an embodiment of the resource scheduling method of this application;

[0014] Figure 2 This is a flowchart illustrating another embodiment of the resource scheduling method of this application;

[0015] Figure 3 This is a schematic diagram of the framework of an embodiment of the resource scheduling device of this application;

[0016] Figure 4 This is a schematic diagram of another embodiment of the resource scheduling device of this application;

[0017] Figure 5This is a schematic diagram of the framework of an embodiment of the electronic device of this application;

[0018] Figure 6 This is a schematic diagram of the framework of an embodiment of the resource scheduling system of this application;

[0019] Figure 7 This is a schematic diagram of a framework of an embodiment of the computer-readable storage medium of this application. Detailed Implementation

[0020] The embodiments of this application will now be described in detail with reference to the accompanying drawings.

[0021] In the following description, specific details such as particular system architectures, interfaces, and technologies are presented for illustrative purposes rather than for limiting purposes, in order to provide a thorough understanding of this application.

[0022] In this paper, the terms "system" and "network" are often used interchangeably. The term "and / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone. Additionally, the slash " / " generally indicates that the preceding and following related objects have an "or" relationship. Furthermore, "many" in this paper indicates two or more objects.

[0023] Please see Figure 1 , Figure 1 This is a flowchart illustrating an embodiment of the resource scheduling method of this application. It should be noted that the process operations in this embodiment can be executed by an electronic device with computing capabilities or related equipment containing an electronic device. The specific structure and type of the electronic device and related equipment containing the electronic device are not limited herein. Furthermore, the electronic device or related equipment used for the process operations in this embodiment can be a scheduling node. Specifically, this embodiment may include the following steps:

[0024] Step S11: Send the image resource package to each computing node in the computing cluster.

[0025] In this embodiment, the image resources may include resource data required by each virtual image in the interactive scene during loading. Thus, after sending the image resource package to each computing node in the computing cluster, each computing node can store the resource data required by each virtual image during loading, without needing to fetch resources across nodes to complete the loading of any virtual image. This overcomes the limitation in related embodiments that "computing nodes can only load fixed images," providing a foundation for subsequent elastic scheduling. Furthermore, computing nodes can pre-load at least some virtual images in their local space (e.g., memory space, video memory space, or other storage space supporting high-speed reads) based on the importance of each virtual image.

[0026] In an implementation scenario, the virtual avatars within the interaction scene can be configured according to the specific human-computer interaction context. For example, taking a customer service scenario as an example, the virtual avatars in the interaction scene could include, but are not limited to: virtual avatars serving VIP customers, virtual avatars serving regular customers, virtual avatars serving new customers, and virtual avatars serving potential customers, etc., and will not be listed here. Alternatively, taking an educational scenario as another example, the virtual avatars in the interaction scene could include, but are not limited to: virtual avatars serving teachers of different subjects, virtual avatars serving students of different grades, and virtual avatars serving parents, etc., and will not be listed here. Of course, the above examples are merely a few possible cases in practical applications, and other possible scenarios are not limited here (e.g., if the specific human-computer interaction scenario encompasses multiple sub-scenarios, the virtual avatars in the interaction scene can cover virtual avatars serving each sub-scenarios respectively), and will not be listed here either.

[0027] In an implementation scenario, resource data can include, but is not limited to: the 3D model of the virtual avatar, the texture map of the virtual avatar, and the animation data of the virtual avatar. For any two virtual avatars, their resource data can be completely different, or partially the same and partially different. It should be noted that the 3D model of the virtual avatar can include, but is not limited to, formats such as FBX, GLB, and OBJ, and the texture map of the virtual avatar can include, but is not limited to, formats such as PNG, JPG, and EXR. In practical applications, to facilitate the packaging of the virtual avatar's resource data into an avatar resource package, 3D models and texture maps of different formats can be uniformly converted into efficient formats adapted to the node hardware. At the same time, lightweight optimizations can be performed on the resource data (e.g., simplifying non-critical face counts, compressing texture resolution, etc.) to reduce hardware resource consumption and parsing time during loading while minimizing the impact on visual effects. In addition, to unify the resource structure, the complete resource chain of each virtual character can be sorted out according to the standard directory structure of "model core file + texture material package + animation dataset + configuration meta information", and the dependencies (such as model and texture mapping, animation and skeleton adaptation rules) can be clarified, so as to avoid loading failure due to missing dependencies as much as possible.

[0028] In one implementation scenario, the avatar resource package may also include an index file. The index file records the mapping relationship between the avatar's identifier and its resource path, facilitating rapid detection and location of target resources by computing nodes. For example, different avatars can have different identifiers, meaning the identifiers can distinguish between different avatars. In this way, the unified format of the avatar resource package and the unified index of its index file reduce parsing time. Furthermore, storing the avatar resource package locally on the computing node or mounting it at high speed minimizes latency during cross-network resource transmission, thus improving the response speed to subsequent triggered requests.

[0029] In one implementation scenario, as a possible example, during the initialization phase of each compute node, the importance of the virtual avatar can be initialized based on the statistical frequency of the virtual avatar when historical requests are triggered. For example, the higher the statistical frequency of the virtual avatar when historical requests are triggered, the higher its importance (i.e., it can be considered a high-frequency avatar), and vice versa. As another possible example, during the initialization phase of each compute node, the importance of the virtual avatar can be statically preset. For example, the business side can pre-enter the importance of each virtual avatar through the configuration center (in addition, concurrency thresholds, resource allocation rules, etc., can also be entered; see the relevant descriptions below for details), so that it can be automatically loaded and taken effect when the system starts. As yet another possible example, during the initialization phase of each compute node, the importance of the virtual avatar can also support hot configuration updates based on the aforementioned static presets. For example, configuration parameters can be modified without restarting (e.g., temporarily increasing the importance or concurrency threshold of a virtual avatar before a major event); another example is the ability to automatically recommend configurations based on historical access data (e.g., if the system analyzes that a virtual avatar has a peak concurrency of 60 in the past 30 days, it can recommend a concurrency threshold of 60 and a redundancy coefficient of 1.3), thus lowering the configuration threshold. As another possible example, during the initialization phase of each compute node, it can also detect whether a scene configuration template exists (e.g., a scene configuration template for "lower grade education scene"). If it exists, the virtual avatars associated with the scene configuration template (e.g., virtual avatars associated with the "lower grade education scene" scene configuration template can include: virtual avatars serving lower grade teachers, virtual avatars serving lower grade students, and virtual avatars serving lower grade parents) can be initialized according to the parameters configured in the scene configuration template (e.g., importance P0, default concurrency of 50, redundancy coefficient of 1.5). When adding virtual avatars under the same scene later, the scene configuration template can be directly applied to improve configuration efficiency. It should be noted that P0 can represent the highest priority (i.e., the highest importance), but it can also include P1 (representing the second highest priority, i.e., the second highest importance) and P2 (representing the lowest priority, i.e., the lowest importance). For example, for a virtual avatar such as a brand's virtual spokesperson, its importance can be set to P0; for a virtual avatar such as a core paid avatar, its importance can be set to P1. Of course, the above example is only one possible way to initialize importance; other possible scenarios are not limited here, nor will they be listed in detail.Furthermore, to configure the importance of each virtual avatar, one possible approach is to precisely configure it using the avatar's identifier, such as batch inputting the importance of each virtual avatar based on its identifier. Alternatively, another possible approach is to support tag-based configuration, such as assigning tags like "Key Protection," "Core Business," and "High Value" to virtual avatars to automatically identify their importance (e.g., automatically identifying a virtual avatar tagged "Key Protection" as having an importance of P0). This approach is suitable for batch management scenarios. Of course, the above examples are merely a few possible implementations for configuring importance in practical applications; other possible implementation methods are not limited here, nor will they be listed in detail.

[0030] In one implementation scenario, during the initialization phase of a computing node, the image resource package can be fully pre-configured to the local storage of the computing node (or mounted to the node via high-speed sharing), and the index file can be loaded into the node's memory simultaneously, so that at least a portion of the virtual images can be selected from the local storage and loaded into the local space on demand based on the index file.

[0031] In one implementation scenario, when a computing node selects at least some virtual avatars to preload into its local space based on their importance, it can first sort the virtual avatars according to their importance, and then select those whose importance meets preset conditions from the sorted virtual avatars to preload into the local space. For example, the virtual avatars can be sorted in descending order of importance, and the preset condition can be set to be located before a preset position (e.g., the first two positions), or the preset condition can be set to be located before a preset position (e.g., the first two positions) and have an importance higher than a threshold (e.g., P1 mentioned above). In addition, if the virtual avatars are not preloaded into the local space, their resource data can be stored in the computing node's storage space (e.g., the computing node's local disk, which has a slightly slower read speed than the aforementioned local space). Of course, the above example is only one possible example in practical applications, and other possible scenarios are not limited here, nor will they be listed one by one.

[0032] In one implementation scenario, in addition to the aforementioned pre-loading based on importance, a "full-image guaranteed loading" rule can be further superimposed. This means that each virtual image is continuously loaded at least once on a computing node in the computing cluster. In other words, during the initialization phase, virtual images of higher importance (e.g., key images, high-frequency images) can be pre-loaded on multiple computing nodes, while those of lower importance (e.g., low-frequency images) can be pre-loaded on at least one computing node, ensuring that all virtual images are in a "ready state" as much as possible. Furthermore, the health status of the pre-loaded nodes can be monitored in real time. If the computing node that is the only one pre-loading a virtual image fails (e.g., hardware malfunction, network interruption) or has a high load, an idle node can be immediately selected to automatically load the virtual image. This ensures that at least one computing node is always loaded with a virtual image, helping to guarantee the continuity and timeliness of basic access.

[0033] In one implementation scenario, when adding, updating, or removing virtual avatars, the updated avatar resource package can be pushed to each computing node in the computing cluster through a cluster synchronization protocol. This ensures that the avatar resource package version is consistent across all computing nodes, minimizing loading anomalies or interaction obstacles caused by resource version differences. In this way, avatar resource packages can be deployed uniformly and synchronized in batches without the need to configure resources for individual nodes. This helps reduce the operational complexity of resource updates and version iterations, while also helping to avoid management chaos caused by scattered resources.

[0034] Step S12: In response to the trigger request of the detected target image, based on the resource data already loaded in the local space of each computing node and the remaining capacity of the local space, select a computing node as the target node to respond to the trigger request.

[0035] In this embodiment of the disclosure, the target image can be any of the various virtual images. For example, taking a customer service scenario as an example of human-computer interaction, the target image can be any of the following: a virtual image serving VIP customers, a virtual image serving ordinary customers, a virtual image serving new customers, a virtual image serving potential customers, etc. As another example, taking an educational scenario as an example of human-computer interaction, the target image can be any of the following: a virtual image serving teachers of different subjects, a virtual image serving students of different grades, a virtual image serving parents, etc. Of course, the above examples are merely a few possible examples in practical applications, and other possible situations are not limited here, nor will they be listed one by one.

[0036] In this embodiment of the disclosure, the target node responds to the trigger request by reusing the first data already loaded in the local space and additionally loading the second data in the local space. The first data is the resource data already loaded in the local space and required for loading the target image, and the second data is the resource data not yet loaded in the local space and required for loading the target image.

[0037] In one implementation scenario, to achieve resource reuse, computing nodes can be sorted based on the degree of overlap between the resource data already loaded in their local space and the resource data required to load the target image (e.g., sorted from highest to lowest overlap). Then, based on the sorted nodes, candidate nodes are selected sequentially (e.g., after sorting from highest to lowest overlap, nodes are selected sequentially from front to back). Finally, the remaining capacity of the candidate nodes' local space determines whether to select a candidate node as the target node. It should be noted that if a candidate node is not selected as the target node, the process can be repeated until a target node is determined. This approach, by first filtering candidate nodes based on the degree of overlap between already loaded resources and required resources, and then combining this with the remaining capacity of the candidate nodes' local space to determine whether to select a candidate node as the target node, maximizes resource reuse while ensuring that the remaining resources of the target node can support loading the target image.

[0038] In a specific implementation scenario, as mentioned earlier, the resource data already loaded in the local space of the computing node may include, but is not limited to: model structure data already loaded in memory space, texture materials and rendering resources already loaded in video memory space, and prefabricated image components, etc. Here, there is no limitation on the resource data already loaded in the local space. Furthermore, the resource data required to load the target image can be found in the aforementioned description of resource data, and will not be repeated here.

[0039] In a specific implementation scenario, after selecting a candidate node, it is possible to check whether the remaining capacity of the candidate node's local space (e.g., the aforementioned memory space, video memory space, etc.) meets the loading requirements of the second data. It should be noted that in this implementation scenario, the second data specifically refers to the resource data required for loading the target image that has not yet been loaded into the candidate node's local space. Based on this, if the remaining capacity meets the loading requirements of the second data, the candidate node can be directly selected as the target node. Conversely, if the remaining capacity does not meet the loading requirements of the second data (e.g., high-precision models, 4K textures, etc., in the second data have exceeded the remaining resource reserves of the candidate node, such as memory space, video memory space, etc., or have reached the candidate node's safe load limit, thus preventing the loading of the second data), the local space of the candidate node can be scaled down based on the unloadable scores of each virtual image already loaded and idle on the candidate node. The process then returns to the step of checking whether the remaining capacity meets the loading requirements of the second data, until a candidate node is selected as the target node. It should be noted that if a candidate node still cannot be selected as the target node (e.g., after scaling down and returning to the aforementioned detection steps, it is still found that a candidate node cannot be selected as the target node), the process can return to the step of executing the sorting operation based on each computing node, and sequentially select computing nodes as candidate nodes until the target node is determined. In this approach, when the remaining capacity is insufficient to load the second data, the local space of the candidate node is scaled down based on the unloadable score of each virtual image that is already loaded and idle. The process then returns to the step of checking whether the remaining capacity meets the loading requirements of the second data, until a candidate node is selected as the target node. If a candidate node still cannot be selected as the target node, the process returns to the step of executing the sorting operation based on each computing node, and sequentially selects computing nodes as candidate nodes until the target node is determined. This allows for the orderly selection of unloadable virtual images based on the unloadable score of each loaded and idle virtual image during scaling down, and combined with the return execution mechanism, effectively improves the robustness of the overall process.

[0040] In a specific implementation scenario, to measure the unloadability score of each virtual character already loaded and idle on a candidate node, the unloadability score of each virtual character can be obtained based on the current values ​​of several evaluation metrics. It should be noted that these evaluation metrics may include, but are not limited to, access frequency, continuous active duration, importance, and resource volume. The unloadability score is negatively correlated with access frequency, continuous active duration, and importance, and positively correlated with resource volume. That is, the higher the access frequency, the longer the continuous active duration, the higher the importance, and the smaller the resource volume, the lower the unloadability score; conversely, the lower the access frequency, the shorter the continuous active duration, the lower the importance, and the larger the resource volume, the higher the unloadability score. Based on this, at least some virtual characters can be selected as characters to be unloaded based on their unloadability scores. Then, the resource data already loaded in the local space of the candidate node for these characters can be unloaded, thereby optimizing the local space of the candidate node. For example, virtual characters that are already loaded and idle in the candidate node can be sorted in descending order of their unloadability score. Then, the virtual characters ranked before a preset position (e.g., the first two) can be selected as the characters to be unloaded. Of course, the above example is only one possible way to select characters to be unloaded in practical applications; other possible scenarios are not limited here, nor will they be listed one by one. Furthermore, after performing a scaling-down optimization, it is also possible to check whether the remaining capacity meets the loading requirements of the second data. If not, another scaling-down optimization can be performed, ensuring that the normal operation of currently active characters is not affected during the scaling-down optimization process. This method, combining the current values ​​of virtual characters on several evaluation indicators to measure their unloadability score, and then selecting at least a portion of virtual characters as characters to be unloaded to align with the unloading of resource data already loaded in the local space, can improve the accuracy of the unloadability score.

[0041] In a specific implementation scenario, for any virtual avatar (or only for virtual avatars other than key avatars), when the current number of concurrent virtual avatars falls below a preset percentage (e.g., 50%) of the concurrency threshold and shows no upward trend for a preset duration (e.g., 10 minutes), the hardware resources occupied by this virtual avatar on redundant nodes can be gradually released. For example, data resources loaded by non-core avatars on high-load computing nodes can be offloaded first, or redundant nodes can be scheduled to return to their original locations for expansion by other virtual avatars, thus achieving the reuse of hardware resources. It should be noted that the current number of concurrent virtual avatars and the concurrency threshold can be found in the following description of expansion operations, which will not be repeated here.

[0042] In a specific implementation scenario, after performing scaling down optimization until the loading requirements of the target image are met, a loading request can be initiated again to ensure that the target image is successfully loaded and runs stably. That is, the whole process forms a fully automated closed loop of "request triggering → resource reuse → sufficiency judgment → idle unloading → secondary loading", which ultimately realizes dynamic adjustment and efficient management of image resources. This helps to improve the computing node's rapid response to diverse image loading requirements, and can also continuously optimize the hardware resource occupancy status, avoiding abnormal problems such as running lag and crashes caused by resource loading as much as possible, ultimately balancing loading efficiency and system stability.

[0043] In one implementation scenario, virtual avatars can also be configured with concurrency thresholds and redundancy coefficients based on their importance. During resource scheduling, concurrency detection can be performed based on the computing cluster to obtain the current number of virtual avatars operating concurrently in real time. Then, based on the concurrency threshold, redundancy coefficient, and current number of virtual avatars operating concurrently in real time, it can be determined whether to perform a scaling operation for the virtual avatars. If it is determined that no scaling operation is needed for the virtual avatars, the step of performing concurrency detection based on the computing cluster to obtain the current number of virtual avatars operating concurrently in real time can be returned. If it is determined that a scaling operation is needed for the virtual avatars, the concurrency threshold, current number of virtual avatars operating concurrently in real time, and the reference number of concurrent connections supported by the computing nodes for the virtual avatars can be analyzed to obtain the target number of scaling operations. Furthermore, based on the current status of each computing node in the computing cluster, the target number of computing nodes can be selected from the computing cluster to perform the scaling operation for the virtual avatars. The above method monitors the current number of virtual avatars concurrently during resource scheduling. By combining the concurrency threshold and redundancy coefficient of the virtual avatars, it determines in real time whether to perform expansion operations for the virtual avatars. If expansion is required, it analyzes the concurrency threshold of the virtual avatars, the current number of concurrent users, and the reference number of computing nodes that can support the concurrency of the virtual avatars to obtain the target number of expansions. Based on this, and combined with the current status of each computing node in the computing cluster, it selects the target number of computing nodes from the computing cluster to perform expansion operations for the virtual avatars, forming an automated closed loop of "monitoring-judgment-scheduling-feedback". This enables the coordinated linkage between real-time concurrency monitoring and virtual avatar expansion.

[0044] In a specific implementation scenario, each virtual avatar (or a group of avatars with the same priority tag) can be configured with a concurrency threshold. For example, a P0-level virtual avatar can be configured with a default concurrency threshold of 50. Taking a single compute node supporting 5 concurrent connections as an example, this P0-level virtual avatar needs to guarantee the basic carrying capacity of 10 compute nodes by default. It should be noted that the concurrency threshold of a virtual avatar can be calculated based on the resource volume of the virtual avatar and the carrying capacity of a single compute node.

[0045] In a specific implementation scenario, each virtual avatar can also be configured with a redundancy coefficient (e.g., 1.2, 1.5, etc.). When the current number of virtual avatars operating concurrently in real time approaches the concurrency threshold, capacity can be expanded in advance according to the redundancy coefficient. For example, with a concurrency threshold of 50 and a redundancy coefficient of 1.2, capacity expansion can be triggered when the current number of virtual avatars operating concurrently in real time reaches 40, in order to avoid congestion during sudden fluctuations. As a possible example, for key avatars, the maximum concurrent capacity of a single compute node can be configured separately (e.g., for ordinary avatars, a single compute node can handle 5 concurrent connections, while for key avatars, which may have higher resource consumption, a single compute node can be configured to handle 3 concurrent connections), to ensure that the compute node load is within a safe range as much as possible and to reduce response latency caused by overload. In addition, multiple redundancy coefficients can be set to form multiple warning lines. For example, a first redundancy coefficient and a second redundancy coefficient can be set, with the first redundancy coefficient being greater than the second redundancy coefficient (e.g., the first redundancy coefficient can be set to 1.25 and the second redundancy coefficient can be set to 1.11). When the product of the current number of concurrent users and the first redundancy coefficient reaches the concurrency threshold, the first warning line is triggered (at this time, an early warning can be issued, but the expansion operation is temporarily suspended). When the product of the current number of concurrent users and the second redundancy coefficient reaches the concurrency threshold, the second warning line can be triggered (at this time, the expansion operation can be performed immediately).

[0046] In a specific implementation scenario, after obtaining the current number of virtual avatars operating concurrently in real time, the concurrency threshold and redundancy coefficient of the virtual avatars can be used to determine whether to perform a scaling operation. As one possible example, if the product of the current number of concurrent users and the redundancy coefficient reaches the concurrency threshold, a scaling operation can be initiated; otherwise, the scaling operation can be temporarily suspended. As another possible example, as mentioned earlier, the virtual avatars can be configured with a first redundancy coefficient and a second redundancy coefficient. If the product of the current number of concurrent users and the first redundancy coefficient reaches the concurrency threshold, an alert can be issued, but the scaling operation can be temporarily suspended. If the product of the current number of concurrent users and the second redundancy coefficient reaches the concurrency threshold, the scaling operation can be performed immediately.

[0047] In a specific implementation scenario, when scaling up is required, the target scaling quantity can be determined by analyzing the virtual avatar's concurrency threshold, the current real-time concurrency level, and the reference number of concurrent connections supported by the virtual avatar across compute nodes. Specifically, the target scaling quantity can be determined based on the difference between the concurrency threshold and the current number, along with the reference number. For ease of understanding, let's take an example where the virtual avatar's concurrency threshold is set to 10 and a single compute node can concurrently handle 5 connections. When the current real-time concurrency level is 18, the difference between the concurrency threshold and the current number is 8 connections. Since a single compute node can concurrently handle 5 connections (i.e., the reference number is 5), two more compute nodes are needed to handle the extra 8 connections; therefore, the target quantity can be calculated as 2. Alternatively, the target scaling quantity can also be determined based on the difference between the concurrency threshold and the current number, the load range after the scaling operation, and the reference number. To facilitate understanding, let's continue with the previous example. If the load range after the expansion operation is 60%~70%, since expanding by only 2 compute nodes will only leave a maximum of 2 paths, exceeding the 60%~70% load range, further expansion is needed. Expanding by 3 compute nodes will leave a maximum of 7 paths, achieving the 60%~70% load range. Therefore, the target number can be determined as 3. Of course, the above examples are only a few possible scenarios in practical applications. Other possible situations are not limited here, nor will they be listed one by one.

[0048] In a specific implementation scenario, after selecting the computing nodes for the expansion operation, expansion linkage events can be pushed (e.g., expansion linkage data can be structured data), including but not limited to the following information: the image identifier of the virtual avatar that needs to perform the expansion operation, the computing node currently carrying the virtual avatar that needs to perform the expansion operation and its load data, as well as the aforementioned real-time detected concurrency number and concurrency threshold, the suggested target number of expansions, and the resource conditions for priority selection nodes (such as the following description of conditions related to the current state), so as to provide a clear basis for subsequent node selection.

[0049] In a specific implementation scenario, after determining the target number of virtual avatars to be expanded, the target number of computing nodes can be selected from the computing cluster based on the current state of each computing node in the cluster to perform the expansion operation for the virtual avatars. Specifically, the current state of a computing node may include, but is not limited to: the real-time number of concurrent virtual avatars currently connected to the computing node, the remaining computing resources of the computing node, the current network latency of the computing node, and whether the computing node is located in the same network segment as the computing node hosting the virtual avatars that need to be expanded. Other possible scenarios for the current state are not limited here. For example, taking the current state including the real-time number of concurrent virtual avatars connected to the computing node as an example, if the real-time number is lower than a preset percentage (e.g., 50%) of the maximum concurrent path capacity of the computing node, it can be selected for the expansion operation. As another example, taking the current state including the remaining computing resources (e.g., memory space, video memory space, etc.) of the computing node as an example, if the remaining computing resources exceed a preset percentage (e.g., 30%) of the total computing resources of the computing node, it can be selected for the expansion operation. In addition, the current status may also include: the access popularity trend of virtual avatars (e.g., the access growth rate in the last 1 minute / 5 minutes / 15 minutes), the number of active sessions, the historical peak concurrency distribution, the utilization rate of hardware resources (e.g., CPU, memory space, video memory space, etc.) of a single computing node, the number of currently loaded virtual avatars and their resource usage ratio, network I / O throughput, etc., which will not be elaborated here. Of course, the above examples are only a few possible examples in practical applications. Other possible selection methods (e.g., selecting computing nodes for expansion operations only when multiple of the above conditions are met simultaneously) are not limited here, nor will they be listed one by one.

[0050] In a specific implementation scenario, when the virtual avatar that needs to be expanded is a key avatar, the node selection priority during the expansion of the key avatar can be specified (e.g., prioritize the use of high-specification nodes, prioritize the use of nodes with more idle resources, such as no less than 40% of computing nodes) to ensure that the key avatar receives better hardware resource support as much as possible.

[0051] In a specific implementation scenario, it may be impossible to find computing nodes suitable for scaling up in practical applications. In this case, an emergency mechanism similar to the aforementioned scaling-down optimization can be activated. For example, some low-priority inactive resources can be temporarily unloaded to release node redundancy, freeing up resources for virtual avatar scaling up and ensuring uninterrupted service as much as possible.

[0052] In one implementation scenario, as mentioned earlier, there may be key virtual characters among the various virtual characters. Specifically, virtual characters can be selected as key characters based on their importance. Based on this, resources can be extracted from the character resource package to obtain an independent resource package for the key character. Nodes in the computing cluster can be filtered to obtain a dedicated cluster for the key character. Each computing node in the dedicated cluster releases resources when it detects that a loaded virtual character is no longer being requested. This allows the independent resource package for the key character to be sent to each computing node in the dedicated cluster. Each computing node in the dedicated cluster pre-loads the key character in its local space based on the independent resource package. Therefore, in response to a trigger request for the key character, it directly switches the trigger request for the key character to the dedicated cluster. The above method configures key images with their own independent resource packages and dedicated clusters, and sends the independent resource packages of key images to each computing node in the dedicated cluster. Each computing node in the dedicated cluster preloads the key images in its local space based on the independent resource packages. In this way, when a trigger request for a key image is detected, the trigger request for the key image can be directly switched to the dedicated cluster. Since the independent resource packages are smaller than the image resource packages, it helps to further shorten the loading time. Furthermore, since the dedicated clusters for key images are dedicated to the key images and there is no contention, all computing nodes in the dedicated clusters can load in parallel during large-scale expansion, which helps to quickly handle sudden high concurrency.

[0053] In a specific implementation scenario, to identify key virtual characters, as one possible example, a virtual character can be selected as a key character if its importance is characterized as requiring independent support. For instance, a virtual character can be designated as a key character if its importance is characterized as a brand ambassador, a core livestream virtual character, a high-value paid character, or a virtual character requiring key support during sudden trending events. Alternatively, as another possible example, a virtual character can be selected as a key character if the current number of concurrent virtual characters within a preset time limit and the target number requiring expansion simultaneously meet the target conditions. For instance, when the concurrent number of virtual characters increases by more than 200% within a short period (e.g., 5 minutes), and the estimated number of expansion nodes is no less than 10 (i.e., the aforementioned target number is no less than 10); or when the business side provides a "requires independent support" label, the virtual character can be designated as a key character. Of course, the above examples are merely a few possible examples for identifying key characters; other possible methods of identification are not limited here, nor will they be listed in detail.

[0054] In a specific implementation scenario, the complete resources of key images (such as model files, texture maps, animation data, metadata, etc.) can be extracted separately from the image resource package, and irrelevant image resources can be removed to construct an independent resource package for the key images. Compared with the image resource package, the size of the independent resource package can theoretically be only 1 / N of the image resource package, which helps to significantly reduce the redundancy of retrieval, parsing and storage when loading nodes.

[0055] In a specific implementation scenario, a dedicated cluster (or independent resource pool partition) can be configured for the separated independent resource packages. The compute nodes within the dedicated cluster only pre-configure the independent resource packages for key virtual images, without needing to store the full resources, further reducing node resource consumption and loading time. Furthermore, the independent cluster can employ high-speed storage mounting and dedicated network links to ensure optimal efficiency in resource loading and data transmission. As a possible example, after separating the dedicated cluster from the original compute cluster, the dedicated cluster can be physically isolated from the original compute cluster to prevent the dedicated cluster serving key virtual images from being affected by other virtual image loading, expansion, or other operations.

[0056] In a specific implementation scenario, after independent deployment is completed, the scheduling node can automatically update the routing rules and smoothly switch all access requests for key images to the dedicated cluster. The computing nodes in the original computing cluster that load key images can gradually release resources (e.g., when the triggered request ends, resources can be released) to avoid business interruption and request loss.

[0057] In a specific implementation scenario, when the high-concurrency scenario for key images ends (e.g., when the hot topic subsides or the live broadcast ends), the dedicated cluster can be quickly disbanded, and the computing nodes of the dedicated cluster can be returned to the computing cluster, or only a small number of computing nodes can be retained in the dedicated cluster as a backup, and the remaining computing nodes can be reused in other scenarios, so as to avoid the dedicated cluster being idle for a long time as much as possible.

[0058] In one implementation scenario, when multiple target images trigger requests, priority routing can be implemented for key images. This means that trigger requests for key images have higher priority than those for ordinary images. In other words, resource scheduling can be prioritized for trigger requests for key images, routing them to low-load nodes that have already loaded the key image to minimize queuing. It should be noted that if there are no low-load nodes in the computing cluster that have already loaded the key image, the trigger requests for key images can be routed to computing nodes using the aforementioned scheduling method. Furthermore, during scaling operations, if scaling requests for key images and ordinary images are triggered simultaneously, the scaling request for key images can be prioritized to ensure that the scaling speed of key images is not affected as much as possible. Additionally, as mentioned earlier, the basic node resources corresponding to the "concurrency threshold" configured for key images can be marked as "priority resources," and under normal circumstances, they should not be occupied by other virtual images (especially ordinary images) to ensure the stability of basic access as much as possible. It should be noted that extreme situations may include, but are not limited to, the removal of key images from shelves or the transformation of key images into ordinary images. The specific circumstances of extreme situations are not limited here, nor will they be listed one by one.

[0059] The above scheme sends an image resource package to each computing node in the computing cluster. The image resource package contains the resource data required by each virtual image in the interactive scene when loading. The computing nodes pre-load at least a portion of the virtual images in their local space based on the importance of each virtual image. Then, in response to a trigger request that detects a target image, based on the resource data already loaded in each computing node's local space and the remaining capacity of the local space, a computing node is selected as the target node to respond to the trigger request. The target image is any one of the virtual images. The target node, in response to the trigger request, reuses the first data already loaded in its local space and additionally loads a second data in its local space. The first data is the resource data already loaded in the local space and required to load the target image, while the second data is the resource data not yet loaded in the local space and required to load the target image. This approach, on the one hand, ensures that the image resource package containing the resource data required by each virtual image when loading is sent... After being delivered to the compute nodes, the compute nodes preload at least a portion of the virtual avatars in their local space based on the importance of each avatar. Compared to full preloading, on-demand loading based on importance allows compute nodes to preload relatively important virtual avatars, enabling timely responses to their trigger requests. This helps improve the resource utilization of compute nodes while fulfilling the trigger requests of virtual avatars. Furthermore, by combining the resource data already loaded in the compute nodes' local space with the remaining capacity of the local space, a target node is selected to respond to the trigger requests. The target node reuses the first data already loaded in its local space—the resource data required to load the target avatar. Thus, the target node only needs to load the second data in its local space, minimizing loading latency. Therefore, this approach improves the resource utilization of compute nodes and minimizes loading latency while fulfilling the trigger requests of virtual avatars.

[0060] Please see Figure 2 , Figure 2 This is a flowchart illustrating another embodiment of the resource scheduling method of this application. It should be noted that the process operations in this embodiment can be executed by an electronic device with computing capabilities or related equipment containing an electronic device. The specific structure and type of the electronic device and related equipment containing the electronic device are not limited herein. Furthermore, the electronic device or related equipment used for the process operations in this embodiment can be a computing node. Specifically, this embodiment may include the following steps:

[0061] Step S21: Receive image resource packets from the scheduling node.

[0062] In this embodiment of the disclosure, the image resources include the resource data required by each virtual image in the interactive scene when loading. For details, please refer to the relevant descriptions in the foregoing embodiments of the disclosure, which will not be repeated here.

[0063] Step S22: Based on the importance of each virtual character, load at least some of the virtual characters in the local space in advance.

[0064] For details, please refer to the relevant descriptions in the foregoing disclosed embodiments, which will not be repeated here.

[0065] Step S23: In response to the scheduled node's trigger request based on the target image, select it as the target node, reuse the first data already loaded in the local space, and load the second data in the local space.

[0066] In this embodiment of the disclosure, the first data is the resource data that has been loaded in the local space and is required to load the target image, and the second data is the resource data that has not yet been loaded in the local space and is required to load the target image. The target image is any one of the virtual images. The scheduling node selects the computing node as the target node for responding to the trigger request based on the resource data that each computing node has loaded in the local space and the remaining capacity of the local space. For details, please refer to the relevant descriptions in the foregoing embodiments of the disclosure, which will not be repeated here.

[0067] The above scheme receives an image resource package from the scheduling node. This image resource package contains the resource data required by each virtual image in the interactive scene during loading. Based on the importance of each virtual image, at least some virtual images are pre-loaded in the local space. Then, in response to a trigger request from the scheduled node based on a target image, the scheduled node is selected as the target node. The first data already loaded in the local space is reused, and a second data is additionally loaded in the local space. The first data consists of resource data already loaded in the local space and required for loading the target image, while the second data consists of resource data not yet loaded in the local space and required for loading the target image. The target image can be any of the virtual images. The scheduling node selects a computing node as the target node to respond to the trigger request based on the resource data already loaded in the local space by each computing node and the remaining capacity of the local space. This is because the image resource package containing the resource data required by each virtual image during loading... After being sent to the compute nodes, the compute nodes preload at least a portion of the virtual avatars in their local space based on the importance of each virtual avatar. Compared to full preloading, on-demand loading based on importance allows compute nodes to preload relatively important virtual avatars, enabling timely responses to their trigger requests. This helps improve the resource utilization of compute nodes while fulfilling the trigger requests of virtual avatars. Furthermore, by combining the resource data already loaded in the compute nodes' local space with the remaining capacity of the local space, a target node is selected to respond to the trigger requests. The target node reuses the first data already loaded in its local space—the resource data required to load the target avatar. Thus, the target node only needs to load the second data in its local space, minimizing loading latency. Therefore, this approach improves the resource utilization of compute nodes and minimizes loading latency while fulfilling the trigger requests of virtual avatars.

[0068] Please see Figure 3 , Figure 3This is a schematic diagram of the framework of an embodiment of the resource scheduling device of this application. The resource scheduling device 30 includes a sending module 31 and a selection module 32. The sending module 31 is used to send image resource packages to each computing node in the computing cluster. The image resources include the resource data required by each virtual image in the interactive scene when loading, and the computing nodes preload at least some virtual images in their local space based on the importance of each virtual image. The selection module 32 is used to select a computing node as the target node for responding to the trigger request when a trigger request for a target image is detected, based on the resource data already loaded in the local space of each computing node and the remaining capacity of the local space. The target image is any one of the virtual images. The target node, in response to the trigger request, reuses the first data already loaded in the local space and additionally loads the second data in the local space. The first data is the resource data already loaded in the local space and required for loading the target image, and the second data is the resource data not yet loaded in the local space and required for loading the target image.

[0069] In the above scheme, the resource scheduling device 30 sends image resource packages to each computing node in the computing cluster. The image resources contain the resource data required by each virtual image in the interactive scene when loading. The computing nodes pre-load at least a portion of the virtual images in their local space based on the importance of each virtual image. Then, in response to a trigger request for a target image, based on the resource data already loaded in the local space of each computing node and the remaining capacity of the local space, a computing node is selected as the target node to respond to the trigger request. The target image is any one of the virtual images. The target node, in response to the trigger request, reuses the first data already loaded in its local space and additionally loads a second data in its local space. The first data is the resource data already loaded in the local space and required to load the target image, while the second data is the resource data not yet loaded in the local space and required to load the target image. This ensures that the image resources contain the resource data required by each virtual image when loading. After the source package is sent to the compute nodes, the compute nodes preload at least a portion of the virtual avatars in their local space based on the importance of each virtual avatar. Compared to full preloading, on-demand loading based on importance allows compute nodes to preload relatively important virtual avatars, enabling timely responses to their trigger requests. This helps improve the resource utilization of compute nodes while fulfilling the trigger requests of virtual avatars. Furthermore, by combining the resource data already loaded in the compute nodes' local space with the remaining capacity of the local space, a target node is selected to respond to the trigger requests. The target node reuses the first data already loaded in its local space—the resource data already loaded and required to load the target avatar. Thus, the target node only needs to load the second data in its local space, minimizing loading latency. Therefore, this approach improves the resource utilization of compute nodes and minimizes loading latency while fulfilling the trigger requests of virtual avatars.

[0070] In some disclosed embodiments, the selection module 32 includes a node sorting submodule, used to sort each computing node based on the degree of duplication between the resource data already loaded in the local space of each computing node and the resource data required to load the target image; the selection module 32 includes a candidate selection submodule, used to sequentially select computing nodes as candidate nodes based on each computing node after the sorting operation; the selection module 32 includes a target selection submodule, used to determine whether to select a candidate node as a target node based on the remaining capacity of the local space of the candidate node; wherein, if it is determined that a candidate node should not be selected as a target node, the step of sequentially selecting computing nodes as candidate nodes based on each computing node after the sorting operation is performed is returned until a target node is determined.

[0071] In some disclosed embodiments, the target selection submodule includes a capacity detection unit for detecting whether the remaining capacity meets the loading requirements of the second data; the target selection submodule includes a direct selection unit for directly selecting a candidate node as the target node in response to the remaining capacity meeting the loading requirements of the second data; the target selection submodule includes a scaling-down iteration unit for optimizing the local space of the candidate node based on the unloadable score of each virtual image that has been loaded and is in an idle state, in response to the remaining capacity not meeting the loading requirements of the second data, and returning to the step of detecting whether the remaining capacity meets the loading requirements of the second data, until a candidate node is selected as the target node; wherein, if a candidate node still cannot be selected as the target node, the step of sequentially selecting a computing node as a candidate node based on each computing node after the sorting operation is performed is returned, until the target node is determined.

[0072] In some disclosed embodiments, the scaling-down iteration unit includes an unloading scoring subunit, used to obtain the unloading score of each virtual image based on the current values ​​of several evaluation indicators for each virtual image that has been loaded and is in an idle state on the candidate node; wherein, the several evaluation indicators include at least one of: access frequency, continuous active duration, importance, and resource volume, and the unloading score is negatively correlated with access frequency, continuous active duration, and importance, and positively correlated with resource volume; the scaling-down iteration unit includes an image unloading subunit, used to select at least some virtual images as images to be unloaded based on the unloading scores of each virtual image that has been loaded and is in an idle state on the candidate node; the scaling-down iteration unit includes a resource unloading subunit, used to unload the resource data that has been loaded in the local space of the candidate node for the images to be unloaded, so as to realize the scaling-down optimization of the local space of the candidate node.

[0073] In some disclosed embodiments, the virtual avatar is further configured with a concurrency threshold and redundancy coefficient based on its importance. The resource scheduling device 30 includes a concurrency detection module for performing concurrency detection based on the computing cluster to obtain the current number of virtual avatars in real-time concurrency. The resource scheduling device 30 includes a capacity expansion determination module for determining whether a capacity expansion operation needs to be performed for the virtual avatar based on the concurrency threshold, redundancy coefficient, and current number of virtual avatars in real-time concurrency. The resource scheduling device 30 includes a return loop module for returning to the step of performing concurrency detection based on the computing cluster to obtain the current number of virtual avatars in real-time concurrency in response to determining that no capacity expansion operation needs to be performed for the virtual avatar. The resource scheduling device 30 includes a capacity expansion analysis module for analyzing the concurrency threshold, current number of virtual avatars in real-time concurrency, and reference number of computing nodes that support concurrency for the virtual avatar in response to determining that a capacity expansion operation needs to be performed for the virtual avatar, obtaining the target number of computing nodes that need to be expanded, and selecting the target number of computing nodes from the computing cluster based on the current state of each computing node in the computing cluster for performing the capacity expansion operation for the virtual avatar.

[0074] In some disclosed embodiments, the current state includes at least one of the following: the real-time number of concurrent virtual avatars on the computing node, the remaining computing resources of the computing node, the current network latency of the computing node, and whether the computing node is currently located in the same network segment as the computing node that hosts the virtual avatar that needs to perform the expansion operation.

[0075] In some publicly disclosed embodiments, the analysis expansion module is specifically used to obtain the target number of units that need to be expanded based on the difference between the concurrency threshold and the current number, as well as a reference number.

[0076] In some disclosed embodiments, the resource scheduling device 30 includes a priority selection module for selecting virtual images as priority images based on their importance; the resource scheduling device 30 includes a stripping and filtering module for stripping resources based on image resource packages to obtain independent resource packages for priority images, and filtering nodes based on computing clusters to obtain dedicated clusters for priority images; wherein, each computing node in the dedicated cluster releases resources when it detects that a loaded virtual image is no longer requested; the resource scheduling device 30 includes a resource sending module for sending independent resource packages for priority images to each computing node in the dedicated cluster; wherein, each computing node in the dedicated cluster preloads the priority image in its local space based on the independent resource packages; the resource scheduling device 30 includes a direct switching module for directly switching the trigger request for the priority image to the dedicated cluster in response to the detection of a trigger request for the priority image.

[0077] In some disclosed embodiments, the priority selection module is specifically used to select a virtual image as a priority image in response to the virtual image's importance being characterized as requiring independent protection.

[0078] In some disclosed embodiments, the priority selection module is further configured to select a virtual image as a priority image in response to detecting that the current number of virtual images concurrently operating within a preset time limit and the target number of images requiring expansion simultaneously meet the target conditions.

[0079] In some disclosed embodiments, the resource data includes at least one of: a 3D model of the virtual avatar, a texture map of the virtual avatar, and animation data of the virtual avatar; and / or, the local space includes at least one of memory space and video memory space; and / or, if the virtual avatar is not preloaded into the local space, the resource data of the virtual avatar is stored in the storage space of the computing node; and / or, the avatar resource package also includes an index file, which is used to record the mapping relationship between the avatar's avatar identifier and the virtual avatar's resource path.

[0080] Please see Figure 4 , Figure 4 This is a schematic diagram of another embodiment of the resource scheduling device of this application. The resource scheduling device 40 includes: a receiving module 41, a loading module 42, and a response module 43. The receiving module 41 is used to receive image resource packages from the scheduling node; wherein, the image resources include resource data required by each virtual image in the interactive scene when loading; the loading module 42 is used to preload at least some virtual images in the local space based on the importance of each virtual image; the response module 43 is used to select as the target node in response to the trigger request of the scheduled node based on the target image, reuse the first data already loaded in the local space, and additionally load the second data in the local space; wherein, the first data is the resource data already loaded in the local space and required to load the target image, the second data is the resource data not yet loaded in the local space and required to load the target image, the target image is any one of the virtual images, and the scheduling node selects the computing node as the target node for responding to the trigger request based on the resource data already loaded by each computing node in the local space and the remaining capacity of the local space.

[0081] In the above scheme, the resource scheduling device 40 receives image resource packages from the scheduling node. These image resources contain the resource data required by each virtual image in the interactive scene during loading. Based on the importance of each virtual image, at least some virtual images are pre-loaded in the local space. Then, in response to a trigger request from the scheduled node based on a target image, the scheduled node is selected as the target node. The first data already loaded in the local space is reused, and a second data is additionally loaded in the local space. The first data consists of resource data already loaded in the local space and required for loading the target image, while the second data consists of resource data not yet loaded in the local space and required for loading the target image. The target image can be any of the virtual images. The scheduling node selects a computing node as the target node to respond to the trigger request based on the resource data already loaded by each computing node in its local space and the remaining capacity of the local space. This is because the image package contains the resource data required by each virtual image during loading. After the resource package is sent to the compute nodes, the compute nodes preload at least a portion of the virtual avatars in their local space based on the importance of each virtual avatar. Compared to full preloading, on-demand loading based on importance allows compute nodes to preload relatively important virtual avatars, enabling timely responses to their trigger requests. This helps improve the resource utilization of compute nodes while fulfilling the trigger requests of virtual avatars. Furthermore, by combining the resource data already loaded in the compute nodes' local space with the remaining capacity of the local space, a target node is selected to respond to the trigger requests. The target node reuses the first data already loaded in its local space—the resource data required to load the target avatar. Thus, the target node only needs to load the second data in its local space, minimizing loading latency. Therefore, this approach improves the resource utilization of compute nodes and minimizes loading latency while fulfilling the trigger requests of virtual avatars.

[0082] Please see Figure 5 , Figure 5 This is a schematic diagram of a framework of an embodiment of the electronic device of this application. The electronic device 50 includes a communication circuit 51, a memory 52, and a processor 53. The memory 52 stores at least program instructions, and the processor 53 is used to execute the program instructions to implement the steps in any of the above-described resource scheduling method embodiments. For details, please refer to the foregoing disclosed embodiments, which will not be repeated here. It should be noted that when the electronic device 50 is used to execute the steps in the first resource scheduling method embodiment described above, the electronic device 50 may specifically be a scheduling node; when the electronic device 50 is used to execute the steps in the second resource scheduling method embodiment described above, the electronic device 50 may specifically be a computing node.

[0083] Specifically, processor 53 controls itself and memory 52 to implement the steps in any of the resource scheduling method embodiments described above. Processor 53 may also be referred to as a CPU (Central Processing Unit). Processor 53 may be an integrated circuit chip with signal processing capabilities. Processor 53 may also be a general-purpose processor, digital signal processor (DSP), application-specific integrated circuit (ASIC), field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. A general-purpose processor may be a microprocessor or any conventional processor. Furthermore, processor 53 may be implemented using integrated circuit chips.

[0084] In the above scheme, the electronic device 50 includes a communication circuit 51, a memory 52, and a processor 53. The memory 52 stores at least program instructions, and the processor 53 is used to execute the program instructions to implement the steps in any of the above resource scheduling method embodiments. On the one hand, after the image resource package containing the resource data required by each virtual image during loading is sent to the computing node, the computing node loads at least a portion of the virtual images in its local space in advance based on the importance of each virtual image. Compared with full preloading, the computing node loads on demand based on importance, which can load relatively important virtual images in advance, so that it can respond to the triggering requests of relatively important virtual images in a timely manner. This helps to improve the resource utilization of the computing node while satisfying the triggering requests of virtual images, and can also respond in a timely manner when the triggering requests of these virtual images are detected. On the other hand, by combining the resource data already loaded in the local space of the computing node and the remaining capacity of the local space, a target node for responding to the triggering request is selected, and the target node reuses the first data already loaded in the local space. The first data is the resource data already loaded in the local space and required for loading the target image. In this way, the target node only needs to load the second data in the local space, which helps to minimize the loading delay. Therefore, while satisfying the triggering request of the virtual avatar, it can improve the resource utilization of the computing node and minimize the loading delay as much as possible.

[0085] Please see Figure 6 , Figure 6 This is a schematic diagram of the framework of an embodiment of the resource scheduling system of this application. The resource scheduling system 60 includes a scheduling node 61 and a plurality of computing nodes 62 communicatively connected to the scheduling node 61. The plurality of computing nodes 62 form a computing cluster (e.g., Figure 6 (As shown in the dashed box), and the scheduling node 61 is used to execute the steps in the first resource scheduling method embodiment above, and the computing node 62 is used to execute the steps in the second resource scheduling method embodiment above. For details, please refer to the aforementioned resource scheduling method embodiment, which will not be repeated here.

[0086] In the above scheme, the resource scheduling system 60 includes a scheduling node 61 and several computing nodes 62 communicatively connected to the scheduling node 61. The several computing nodes 62 form a computing cluster. The scheduling node 61 is used to execute the steps in the first resource scheduling method embodiment described above, and the computing nodes 62 are used to execute the steps in the second resource scheduling method embodiment described above. On the one hand, since the image resource package containing the resource data required by each virtual image during loading is sent to the computing node, the computing node loads at least a portion of the virtual images in its local space in advance based on the importance of each virtual image. Compared with full preloading, the computing node loads on demand based on importance, which can preload relatively important virtual images. This allows for timely responses to trigger requests from relatively important virtual avatars, improving resource utilization of computing nodes while fulfilling their trigger requests. Furthermore, by combining the resource data already loaded in the local space and the remaining capacity of the local space, a target node is selected to respond to the trigger requests. This target node reuses the first set of data already loaded in its local space—the resource data required to load the target avatar. Thus, the target node only needs to load the second set of data in its local space, minimizing loading latency. Therefore, this approach improves resource utilization of computing nodes and minimizes loading latency while fulfilling the trigger requests of virtual avatars.

[0087] Please see Figure 7 , Figure 7 This is a schematic diagram of a framework of an embodiment of the computer-readable storage medium of this application. The computer-readable storage medium 70 stores program instructions 71 that can be executed by a processor. The program instructions 71 are used to implement the steps in any of the resource scheduling method embodiments described above.

[0088] In the above scheme, the computer-readable storage medium 70 stores program instructions 71 that can be executed by the processor. The program instructions 71 are used to implement the steps in any of the above resource scheduling method embodiments. On the one hand, after the image resource package containing the resource data required by each virtual image during loading is sent to the computing node, the computing node loads at least a portion of the virtual images in its local space in advance based on the importance of each virtual image. Compared with full preloading, the computing node loads on demand based on importance, which can load relatively important virtual images in advance, so that it can respond to the triggering requests of relatively important virtual images in a timely manner. This helps to improve the resource utilization of the computing node while satisfying the triggering requests of virtual images, and can also respond in a timely manner when the triggering requests of these virtual images are detected. On the other hand, by combining the resource data already loaded in the local space of the computing node and the remaining capacity of the local space, a target node for responding to the triggering request is selected, and the target node reuses the first data already loaded in the local space. The first data is the resource data already loaded in the local space and required for loading the target image. In this way, the target node only needs to load the second data in the local space, which helps to minimize the loading delay. Therefore, while satisfying the triggering request of the virtual avatar, it can improve the resource utilization of the computing node and minimize the loading delay as much as possible.

[0089] In some embodiments, the functions or modules of the apparatus provided in this disclosure can be used to perform the methods described in the above method embodiments. The specific implementation can be referred to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.

[0090] The description of the various embodiments above tends to emphasize the differences between the various embodiments. The similarities or similarities between them can be referred to, and for the sake of brevity, they will not be repeated here.

[0091] In the several embodiments provided in this application, it should be understood that the disclosed methods and apparatus can be implemented in other ways. For example, the apparatus implementations described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0092] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment, depending on actual needs.

[0093] Furthermore, the functional units in the various embodiments of this application 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. The integrated unit can be implemented in hardware or as a software functional unit.

[0094] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part 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.) or processor to execute all or part of the steps of the methods of various embodiments of this application. 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.

[0095] If the technical solution of this application involves personal information, the product using this technical solution has clearly informed the user of the personal information processing rules and obtained the user's voluntary consent before processing the personal information. If the technical solution of this application involves sensitive personal information, the product using this technical solution has obtained the user's separate consent before processing the sensitive personal information, and also meets the requirement of "express consent". For example, at personal information collection devices such as cameras, clear and prominent signs are set up to inform users that they have entered the scope of personal information collection and that personal information will be collected. If an individual voluntarily enters the collection scope, it is deemed that they have agreed to the collection of their personal information; or on the personal information processing device, with clear signs / information informing users of the personal information processing rules, authorization is obtained from the individual through pop-up information or by asking the individual to upload their personal information; wherein, the personal information processing rules may include information such as the personal information processor, the purpose of personal information processing, the processing method, and the types of personal information processed.

Claims

1. A resource scheduling method, characterized in that, include: Send image resource packages to each computing node in the computing cluster; wherein, the image resources contain the resource data required by each virtual image in the interactive scene when loading, and the computing nodes preload at least a portion of the virtual images in their local space based on the importance of each virtual image, the local space including at least one of memory space and video memory space; In response to a trigger request that detects a target image, based on the resource data already loaded in the local space by each of the computing nodes and the remaining capacity of the local space, a computing node is selected as the target node for responding to the trigger request; wherein, the target image is any one of the virtual images, and the target node, in response to the trigger request, reuses the first data already loaded in the local space and additionally loads the second data in the local space, wherein the first data is the resource data already loaded in the local space and required to load the target image, and the second data is the resource data not yet loaded in the local space and required to load the target image.

2. The method according to claim 1, characterized in that, The step of selecting a computing node as the target node for responding to the triggering request based on the resource data already loaded on each computing node in its local space and the remaining capacity of the local space includes: The computing nodes are sorted based on the degree of overlap between the resource data already loaded in the local space and the resource data required to load the target image. Based on each computing node after the sorting operation, the computing nodes are selected as candidate nodes in sequence; Based on the remaining capacity of the local space of the candidate node, determine whether to select the candidate node as the target node; wherein, if it is determined that the candidate node should not be selected as the target node, return to the step of selecting each computing node as a candidate node in turn based on each computing node after the sorting operation, until the target node is determined.

3. The method according to claim 2, characterized in that, Determining whether to select a candidate node as the target node based on the remaining capacity of the candidate node's local space includes: Detect whether the remaining capacity meets the loading requirements of the second data; In response to the fact that the remaining capacity meets the loading requirements of the second data, the candidate node is directly selected as the target node; In response to the fact that the remaining capacity does not meet the loading requirements of the second data, based on the unloadable score of each virtual image that has been loaded and is in an idle state, the local space of the candidate node is scaled down and optimized, and the process returns to the step of detecting whether the remaining capacity meets the loading requirements of the second data, until the candidate node is selected as the target node; wherein, if the candidate node still cannot be selected as the target node, the process returns to the step of selecting each computing node as a candidate node in turn based on the sorting operation, until the target node is determined.

4. The method according to claim 3, characterized in that, The optimization of local space for candidate nodes based on the unloadability rating of each virtual image that is already loaded and in an idle state includes: Based on the current values ​​of several evaluation indicators for each virtual character that has been loaded and is in an idle state at the candidate node, an unloadable score is obtained for each virtual character; wherein, the several evaluation indicators include at least one of: access frequency, continuous active duration, importance and resource volume, the unloadable score is negatively correlated with the access frequency, the continuous active duration and the importance, and the unloadable score is positively correlated with the resource volume; Based on the uninstallability rating of each virtual character that is already loaded and in an idle state in the candidate node, at least some of the virtual characters are selected as characters to be uninstalled. The resource data already loaded in the local space of the candidate node based on the image to be uninstalled is uninstalled to achieve the scaling down optimization of the local space of the candidate node.

5. The method according to claim 1, characterized in that, The virtual avatar is also configured with a concurrency threshold and redundancy coefficient based on its importance level, and the method further includes: Concurrency detection is performed based on the computing cluster to obtain the current number of virtual avatars operating concurrently in real time; Based on the concurrency threshold, redundancy coefficient, and current number of real-time concurrent users of the virtual avatar, determine whether it is necessary to perform a capacity expansion operation for the virtual avatar. In response to determining that no scaling operation is required for the virtual avatar, the process returns to the step of performing concurrency detection based on the computing cluster to obtain the current number of virtual avatars in real time. In response to determining that the scaling operation needs to be performed for the virtual avatar, the system analyzes the concurrency threshold of the virtual avatar, the current number of real-time concurrent connections, and the reference number of concurrent connections supported by the computing nodes for the virtual avatar to obtain the target number of connections to be scaled up. Based on the current state of each computing node in the computing cluster, the system selects the target number of computing nodes from the computing cluster to perform the scaling operation for the virtual avatar.

6. The method according to claim 5, characterized in that, The current state includes at least one of the following: the real-time number of concurrent virtual avatars currently hosted by the computing node, the remaining computing resources of the computing node, the current network latency of the computing node, and whether the computing node is currently located in the same network segment as the computing node that hosts the virtual avatar that needs to perform the expansion operation. And / or, the analysis based on the concurrency threshold of the virtual image, the current number of real-time concurrent connections, and the reference number of concurrent connections supported by the computing node for the virtual image to obtain the target number that needs to be expanded includes: obtaining the target number that needs to be expanded based on the difference between the concurrency threshold and the current number and the reference number.

7. The method according to claim 1, characterized in that, The method further includes: Based on the importance of each virtual character, the virtual character is selected as the key character; Based on the image resource package, resources are stripped to obtain an independent resource package for the key image. Based on the computing cluster, nodes are filtered to obtain a dedicated cluster for the key image. In the dedicated cluster, each computing node releases resources when it detects that the loaded virtual image is no longer requested. Send the key image's independent resource package to each of the computing nodes in the dedicated cluster; wherein, each of the computing nodes in the dedicated cluster preloads the key image in its local space based on the independent resource package; In response to the detection of the trigger request for the key image, the trigger request for the key image is directly switched to the dedicated cluster.

8. The method according to claim 7, characterized in that, The step of selecting a virtual character as a key character based on the importance of each virtual character includes: selecting a virtual character as the key character in response to the virtual character's importance being characterized as requiring independent protection; And / or, the method further includes: in response to detecting that the current number of virtual images concurrently operating within a preset time limit and the target number requiring expansion simultaneously meet the target conditions, selecting the virtual image as the key image.

9. The method according to any one of claims 1 to 8, characterized in that, The resource data includes at least one of the following: the 3D model of the virtual character, the texture map of the virtual character, and the animation data of the virtual character; And / or, if the virtual image is not preloaded into the local space, the resource data of the virtual image is stored in the storage space of the computing node; And / or, the image resource package further includes an index file, which is used to record the mapping relationship between the image identifier of the virtual image and the resource path of the virtual image.

10. A resource scheduling method, characterized in that, include: Receive image resource packages from the scheduling node; wherein, the image resources contain the resource data required by each virtual image in the interactive scene when loading; Based on the importance of each of the virtual images, at least some of the virtual images are preloaded in local space; wherein, the local space includes at least one of memory space and video memory space; In response to being selected as the target node by the scheduling node based on the target image trigger request, the first data already loaded in the local space is reused, and the second data is additionally loaded in the local space; wherein, the first data is resource data already loaded in the local space and required to load the target image, the second data is resource data not yet loaded in the local space and required to load the target image, the target image is any one of the virtual images, and the scheduling node selects the computing node as the target node for responding to the trigger request based on the resource data already loaded in the local space by each computing node and the remaining capacity of the local space.

11. A resource scheduling device, characterized in that, include: A sending module is used to send image resource packages to each computing node in the computing cluster; wherein, the image resources include the resource data required by each virtual image in the interactive scene when loading, and the computing node preloads at least a portion of the virtual images in its local space based on the importance of each virtual image, the local space including at least one of memory space and video memory space; The selection module is used to respond to a trigger request that detects a target image, and selects a computing node as the target node to respond to the trigger request based on the resource data already loaded in the local space of each computing node and the remaining capacity of the local space; wherein, the target image is any one of the virtual images, and the target node, in response to the trigger request, reuses the first data already loaded in the local space and additionally loads the second data in the local space, wherein the first data is the resource data already loaded in the local space and required to load the target image, and the second data is the resource data not yet loaded in the local space and required to load the target image.

12. A resource scheduling device, characterized in that, include: The receiving module is used to receive image resource packages from the scheduling node; wherein, the image resources include the resource data required by each virtual image in the interactive scene when loading; A loading module is used to preload at least a portion of the virtual images in a local space based on the importance of each virtual image; wherein the local space includes at least one of memory space and video memory space; A response module is configured to respond to a trigger request from the scheduling node based on a target image, selecting the scheduling node as the target node, reusing the first data already loaded in the local space, and additionally loading the second data in the local space; wherein, the first data is resource data already loaded in the local space and required to load the target image, the second data is resource data not yet loaded in the local space and required to load the target image, the target image is any one of the virtual images, and the scheduling node selects the computing node as the target node for responding to the trigger request based on the resource data already loaded by each computing node in the local space and the remaining capacity of the local space.

13. An electronic device, characterized in that, The system includes a communication circuit, a memory, and a processor. The communication circuit and the memory are respectively coupled to the processor. The memory stores at least program instructions. The processor is used to execute the program instructions to implement the resource scheduling method according to any one of claims 1 to 10.

14. A resource scheduling system, characterized in that, The system includes a scheduling node and several computing nodes that are communicatively connected to the scheduling node. The several computing nodes form a computing cluster. The scheduling node is used to execute the resource scheduling method according to any one of claims 1 to 9, and the computing nodes are used to execute the resource scheduling method according to claim 10.

15. A computer-readable storage medium, characterized in that, The system stores program instructions that can be executed by a processor, the program instructions being used to implement the resource scheduling method according to any one of claims 1 to 10.