Resource optimization method and device of cloud game system, terminal equipment and medium

Through deep reinforcement learning models and edge computing, the resource allocation of cloud gaming systems is optimized, solving the problems of high bandwidth consumption, high latency and poor stability of cloud gaming, achieving lower latency and more reasonable resource allocation, and improving cloud gaming performance and stability.

CN118708332APending Publication Date: 2024-09-27CENT SOUTH UNIV

Patent Information

Application Number
CN202410714506.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-04
Publication Date
2024-09-27

AI Technical Summary

Technical Problem

Cloud gaming faces the problems of high bandwidth consumption, high latency response, poor stability and poor picture quality, especially in high resolution and virtual reality scenarios.

Method used

Adopt a deep reinforcement learning model and combine it with edge computing to optimize the resource allocation of the cloud gaming system. By calculating the differences in game latency, network resources and computing resources, a resource optimization model is built to optimize game latency and resource allocation, reduce bandwidth consumption, and improve stability. .

Benefits of technology

It significantly reduces game latency, optimizes resource allocation, avoids bandwidth loss caused by idle resources, and improves the stability and performance of cloud games.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118708332A
    Figure CN118708332A
Patent Text Reader

Abstract

The invention is suitable for the technical field of cloud computing, and provides a resource optimization method and device of a cloud game system, terminal equipment and a medium. The method comprises the steps that a task request sent by a user terminal is acquired; according to the CPU number demand and the bandwidth demand, the game picture rendering instruction is distributed to an edge server, and the game delay of the task request, the game video picture quality score, the network load of the edge computing network and the computing load of the edge computing network are calculated; calculating a network resource allocation difference of the edge computing network, and calculating a computing resource allocation difference of the edge computing network according to the computing load; based on the deep reinforcement learning model, with minimum game delay, minimum network resource allocation difference and minimum computing resource allocation difference as optimization objectives, constructing a resource optimization model; and optimizing the resources of the cloud game system according to the resource optimization model. According to the invention, the problems of large broadband consumption, high time delay and unstable image quality of the cloud game can be solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the field of cloud computing technology, and in particular, relates to a resource optimization method, device, terminal equipment and medium for a cloud gaming system. Background Art

[0002] In recent years, electronic games have become a new way for people to entertain, compete and socialize, but traditional electronic games have limitations such as limited hardware, limited usage scenarios, high cross-platform development costs, and limited user scale. In order to make up for the shortcomings of traditional electronic games, cloud games came into being.

[0003] In cloud gaming, complex game software runs on powerful servers in data centers, and game scenes are transmitted to gamers in real time via the Internet. Gamers can use lightweight software on mobile devices to interact with the game. Since cloud gaming runs on cloud servers, it helps players get rid of their dependence on hardware devices, reduces the cost of upgrading hardware devices, and allows them to play games anytime, anywhere across platforms. In terms of security, since the game uses a video streaming mechanism, users do not need to download data files, so game plug-ins can be completely eliminated, greatly saving developers' investment in game plug-ins.

[0004] However, the real popularization of cloud gaming still faces some challenges:

[0005] 1. High bandwidth consumption

[0006] Since cloud games transmit a large amount of game screen data downstream, cloud games as video streams need to consume more bandwidth. In addition, the quality of the multimedia stream rendered by the game scene depends on the network communication bandwidth. The higher the image quality of the multimedia stream, the higher the bandwidth resources consumed. Under the H264 encoding condition (a common video encoding standard, also known as AVC (Advanced Video Coding)), the bit rate of high-definition cloud games (resolution of 1080P and frame rate of 30 frames per second) can reach about 8000 kilobits per second (Kbps), and the network bandwidth must reach 10 megabits per second (Mbps) to run stably and smoothly. As application terminals expand to large-screen TVs, virtual reality (VR) and other devices, the requirements for resolution and frame rate are gradually increasing, and bandwidth consumption is also increasing. For 4K (a display resolution standard) high-definition cloud games to run smoothly, the network bandwidth must reach at least 80Mbps.

[0007] 2. High latency response

[0008] Interaction delays in cloud games include network delay (network round-trip delay) and server response delay (the delay from receiving user input from the server to sending the corresponding game screen from the server), of which network delay accounts for more than 70%. The delay characteristics of cloud games make them more demanding in terms of delay than traditional games. Games with high requirements for operation response delay (for example: action, fighting, first-person shooter, racing, etc.) usually need to control the delay within 80 milliseconds (ms), and VR cloud games usually need to control the delay within 20ms.

[0009] 3. Poor stability

[0010] Currently, due to the large distance between the cloud data center and the user terminal device, the delay in sending video frames from the server to the player is very high, the stability is poor, and frame loss is prone to cause screen freezes.

[0011] 4. Poor picture quality

[0012] Currently, due to the limited resources of edge network nodes and the dynamic nature of the allocated resources, fixed video encoding configuration parameters cannot adapt to dynamic resource configuration, which can easily cause video freezes. Summary of the invention

[0013] The present application provides a resource optimization method, apparatus, terminal device and medium for a cloud gaming system, which can solve the current problems of high bandwidth consumption, high latency and instability in cloud gaming.

[0014] In a first aspect, the present application provides a resource optimization method for a cloud gaming system, which is applied to a cloud data center of the cloud gaming system, wherein the cloud gaming system includes a cloud data center, an edge computing network, and multiple user terminals, and the resource optimization method includes:

[0015] Obtain multiple task requests sent by multiple user terminals; the task requests correspond to the user terminals one by one, and the task requests include game screen rendering instructions, CPU quantity and bandwidth requirements;

[0016] For each task request, according to the CPU quantity requirement and bandwidth requirement, the game screen rendering instruction is allocated to an edge server in the edge computing network, and the game delay, game video quality score, network load of the edge computing network and computing load of the edge computing network of the task request are calculated respectively; the edge computing network includes multiple edge servers;

[0017] According to the network load, the network resource allocation difference of the edge computing network is calculated, and according to the computing load, the computing resource allocation difference of the edge computing network is calculated; the network resource allocation difference is used to characterize the balanced distribution of the network load, and the computing resource allocation difference is used to characterize the distribution of the computing power of the edge server;

[0018] Based on the deep reinforcement learning model, a resource optimization model is constructed with the lowest game latency, the smallest network resource allocation difference, and the smallest computing resource allocation difference as the optimization goals;

[0019] According to the resource optimization model, the resources of the cloud gaming system are optimized.

[0020] Optional, the expression for game delay is T i =t c,j +t i +t j,i , where T i represents the game delay of the task request sent by user terminal i, i = 1, 2, ..., n, n represents the total number of user terminals, t c,j represents the transmission delay of data from cloud data center c to edge server j in the edge computing network, j = 1, 2, ..., m, m represents the total number of edge servers in the edge computing network, d c,j represents the amount of data transmitted from the cloud computing center c to the edge server j, represents the data transmission rate from cloud data center c to edge server j, B represents the channel bandwidth, p c,j represents the transmission power from cloud data center c to edge server j, represents the channel gain, which is related to the transmission distance, σ c represents noise, t i is the processing delay, which means the time it takes for the edge server to complete the game screen rendering instruction in the task request sent by user terminal i, t j,i represents the transmission delay of data from edge server j to user terminal i, d j,i represents the amount of data transmitted from edge server j to user terminal i, represents the data transmission rate from edge server j to user terminal i, p j,i represents the transmission power from edge server j to user terminal i, represents the channel gain, σ j Indicates noise;

[0021] The expression of network load is: in, represents the network load of edge server j, B j,i represents the transmission bandwidth from edge server j to user terminal i, B j represents the downlink bandwidth of edge server j;

[0022] The expression for calculating the load is in, represents the computational load of edge server j, f j,i represents the CPU frequency transmitted from edge server j to user terminal i, F j represents the total CPU frequency of edge server j.

[0023] Optionally, calculating the difference in network resource allocation of the edge computing network according to the network load, and calculating the difference in computing resource allocation of the edge computing network according to the computing load, including:

[0024] By calculating the formula

[0025]

[0026] Get the network resource allocation difference var(l net );

[0027] By calculating the formula

[0028]

[0029] Get the computing resource allocation difference var(l cp ).

[0030] Optionally, the resource optimization model includes a state space S t , action space A and reward function r; where S t represents the state space at time step t, c i represents the CPU quantity required in the task request sent by user terminal i, represents the downlink bandwidth transmitted from edge server j to user terminal i, R j represents the remaining CPU number of edge server j. The action space A includes the action space A1 of the offloading path between servers and the action space A2 of computing resource allocation. A1 = (A 11 ,A 12 ,...,A 1u ,..,A 1U ), A 1u represents the u-th action of the inter-server offloading path, A2=(A 21 ,A 22 ,...,A 2v ,..,A 2V ), A 2υ It represents the υth action of computing resource allocation, and the expression of reward function r is r=T max -w1·T-w2·var(l net )-w3·var(l cp )-w4Fair, T maxrepresents the preset delay threshold, T represents the average game delay, Fair represents the game fairness index. g represents the gth group of user terminals, g = 1, 2, ..., M, M represents the total number of user terminal groups, Fair g Indicates the game fairness of the g-th group of user terminals,

[0031] Optionally, the resources of the cloud gaming system are optimized according to the resource optimization model, including:

[0032] Solve the inter-server offloading path action and computing resource allocation action corresponding to the maximum reward value;

[0033] According to the offloading path actions and computing resource allocation actions between servers, the resources of the cloud gaming system are optimized.

[0034] In a second aspect, the present application provides a resource optimization device for a cloud gaming system, comprising:

[0035] The task request acquisition module is used to acquire multiple task requests sent by multiple user terminals; the task request corresponds to the user terminal one by one, and the task request includes the game screen rendering instruction and the CPU quantity requirement;

[0036] A load calculation module is used to allocate the game screen rendering instruction to an edge server in the edge computing network for each task request according to the CPU quantity requirement, and calculate the game delay of the task request, the network load of the edge server, and the computing load of the edge server respectively; the edge computing network includes multiple edge servers;

[0037] A difference calculation module is used to calculate the network resource allocation difference of the edge computing network according to the network load, and to calculate the computing resource allocation difference of the edge computing network according to the computing load; the network resource allocation difference is used to characterize the balanced distribution of the network load, and the computing resource allocation difference is used to characterize the distribution of the computing power of the edge server;

[0038] The optimization model building module is used to build a resource optimization model based on the deep reinforcement learning model with the optimization goals of minimizing game latency, minimizing network resource allocation differences, and minimizing computing resource allocation differences;

[0039] The optimization module is used to optimize the resources of the cloud gaming system according to the resource optimization model.

[0040] In a third aspect, the present application provides a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above-mentioned resource optimization method when executing the computer program.

[0041] In a fourth aspect, the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the above-mentioned resource optimization method is implemented.

[0042] The above solution of the present application has the following beneficial effects:

[0043] The resource optimization method for the cloud gaming system provided in the present application calculates the game delay, the network resource allocation difference of the edge server and the computing resource allocation difference, and then takes the lowest game delay, the smallest network resource allocation difference and the smallest computing resource allocation difference as the optimization goals, constructs a resource optimization model, and finally optimizes the resources of the cloud gaming according to the resource optimization model, so that the resource allocation and scheduling method of the optimized cloud gaming greatly reduces the game delay, makes the resource allocation of the cloud gaming more reasonable, avoids the bandwidth loss caused by idle resources, and reduces the bandwidth consumption; in addition, the resource optimization method also combines the idea of ​​edge computing, and through the edge server, can reduce the distance between the server and the user terminal, thereby improving stability.

[0044] Other beneficial effects of the present application will be described in detail in the subsequent specific implementation section. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0046] Figure 1 An architectural diagram of a cloud gaming system provided in accordance with an embodiment of the present application;

[0047] Figure 2 A flowchart of a resource optimization method for a cloud gaming system provided in one embodiment of the present application;

[0048] Figure 3 A schematic diagram of the structure of a resource optimization device for a cloud gaming system provided in one embodiment of the present application;

[0049] Figure 4 A schematic diagram of the structure of a terminal device provided in one embodiment of the present application. DETAILED DESCRIPTION

[0050] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.

[0051] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.

[0052] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.

[0053] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.

[0054] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.

[0055] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.

[0056] In response to the current problems of high bandwidth consumption, high latency and instability in cloud gaming, the present application provides a resource optimization method for a cloud gaming system, which is applied to the cloud data center of the cloud gaming system. By calculating the game latency, network resource allocation differences and computing resource allocation differences of edge servers, a resource optimization model is constructed with the lowest game latency, the smallest network resource allocation difference and the smallest computing resource allocation difference as the optimization goals. Finally, the resources of the cloud gaming are optimized according to the resource optimization model, so that the resource allocation and scheduling method of the optimized cloud gaming greatly reduces the game latency, makes the resource allocation of the cloud gaming more reasonable, avoids bandwidth loss caused by idle resources, and reduces bandwidth consumption. In addition, the resource optimization method also combines the idea of ​​edge computing. Through the edge server, the distance between the server and the user terminal can be reduced, thereby improving stability.

[0057] The following is an exemplary description of the system architecture of the cloud gaming system in this application.

[0058] like Figure 1 As shown, in the embodiment of the present application, the cloud gaming system includes a cloud data center (such as Figure 1 11), edge computing network (as shown in Figure 1 12) and multiple user terminals (such as Figure 1 131, 132, and 133), wherein the cloud data center has a large amount of computing resources and can quickly process various complex computing tasks. It is mainly composed of a physical machine cluster; the edge computing network includes multiple edge servers (such as Figure 1 121, 122, and 123), the edge server is responsible for rendering the game screen and transmitting the rendered frame sequence to the user terminal; the user terminal is usually a computer or a mobile phone.

[0059] Exemplarily, after the user starts a cloud game, the user terminal will parse the operation instructions input by the user (such as: controlling the character to move forward) into a task request (screen rendering instructions and the number of CPUs required to complete the screen rendering), and then send it to the cloud data center. Subsequently, the cloud data center assigns the screen rendering instructions to an edge server in the edge computing network based on the number of CPUs required in the task request. The edge server that receives the screen rendering instructions completes the game screen rendering according to the instructions, generates a frame sequence, and transmits it to the user terminal. At this point, a cloud game operation of the user terminal is completed.

[0060] It should be noted that, in the embodiments of the present application, in order to reasonably allocate the task requests of the user terminals, the software-defined networking (SDN) technology may be used to allocate the task requests to the appropriate edge servers.

[0061] By using the SDN network, the logical centralized control of the distributed network infrastructure can be realized. The control plane of the SDN determines how to transmit data between the communication infrastructures, and the data plane performs data transmission. Exemplarily, in the embodiment of the present application, the master-slave scheme of the SDN controller is adopted, and the central controller is deployed on the edge server with strong computing power, which is used for all relevant information collected by the network to optimize the resource allocation strategy. The local SDN controller is deployed on other edge servers to manage the internal network of the edge server and send the network-related information of each edge server to the central controller that supervises the communication between data centers (IDC, Internet Data Center). In order to avoid single point of failure (SPOF, Single Point of Failure), the master-slave scheme of the SDN controller is adopted. Correspondingly, each edge server is controlled by a master SDN controller, and three standby controllers (slave SDN controllers) are in standby state to achieve fault tolerance. When the master SDN controller fails, the slave SDN controller enters the working state and replaces the failed master SDN controller to perform control tasks.

[0062] The following is an exemplary description of the resource optimization method for the cloud gaming system provided in this application.

[0063] It should be noted that the resource optimization method of the cloud gaming system is applied to the cloud data center of the above-mentioned cloud gaming system.

[0064] like Figure 2 As shown, the resource optimization method of the cloud gaming system provided by the present application includes the following steps:

[0065] Step 21: Acquire multiple task requests sent by multiple user terminals.

[0066] It should be noted that, in the embodiment of the present application, the same user terminal can only send one task request at the same time step, and the task request sent includes game screen rendering instructions, CPU quantity and bandwidth requirements.

[0067] Exemplarily, in one embodiment of the present application, the game instruction:

[0068] Cont1 = {scene screen change rendering instructions corresponding to the player's backward action, CPU number requirement: 4, bandwidth requirement: 1 mbps}.

[0069] Step 22, for each task request, according to the number of CPUs and bandwidth requirements, the game screen rendering instructions are allocated to an edge server in the edge computing network, and the game delay, game video quality score, network load of the edge computing network, and computing load of the edge computing network of the task request are calculated respectively.

[0070] The above-mentioned edge computing network includes multiple edge servers.

[0071] Exemplarily, the game video quality score is a weighted sum of game resolution, game frame rate, game graphics detail, and game anti-aliasing (the weights can be pre-set).

[0072] According to the number of CPUs required, the game screen rendering instructions can be distributed to an edge server in the edge computing network using the above-mentioned SDN.

[0073] SDN includes data plane, control plane and application plane. The data plane is the basic network facility, which can collect device information and channel information in real time. The control plane is composed of SDN controllers, which are deployed on edge network nodes and can respond to control decisions in real time. The application plane receives various user needs and is the highest presentation of optimization strategies.

[0074] Specifically, the expression of game delay is T i =t c,j +t i +t j,i , where T i represents the game delay of the task request sent by user terminal i, i = 1, 2, ..., n, n represents the total number of user terminals, t c,j represents the transmission delay of data from cloud data center c to edge server j in the edge computing network, j = 1, 2, ..., m, m represents the total number of edge servers in the edge computing network, d c,j represents the amount of data transmitted from the cloud computing center c to the edge server j, represents the data transmission rate from cloud data center c to edge server j, B represents the channel bandwidth, p c,j represents the transmission power from cloud data center c to edge server j, represents the channel gain, which is related to the transmission distance, σ c represents noise, t i is the processing delay, which means the time it takes for the edge server to complete the game screen rendering instruction in the task request sent by user terminal i, t j,i represents the transmission delay of data from edge server j to user terminal i, d j,i represents the amount of data transmitted from edge server j to user terminal i, represents the data transmission rate from edge server j to user terminal i, p j,i represents the transmission power from edge server j to user terminal i, represents the channel gain, σ jIndicates noise.

[0075] The expression of network load is: in, represents the network load of edge server j, B j,i represents the transmission bandwidth from edge server j to user terminal i, B j represents the downlink bandwidth of edge server j. It should be understood that downlink bandwidth refers to the data transmission capacity from a server or network provider to an end user device. In the embodiment of the present application, it represents the rate at which a user terminal receives edge server data.

[0076] The expression for calculating the load is in, represents the computational load of edge server j, f j,i represents the CPU frequency transmitted from edge server j to user terminal i, F j represents the total CPU frequency of edge server j.

[0077] It should be understood that game latency refers to the time interval between user operation and server response in online games, which can also be called network latency or Ping. The lower the game latency, the smoother the cloud game.

[0078] Step 23, calculate the network resource allocation difference of the edge computing network according to the network load, and calculate the computing resource allocation difference of the edge computing network according to the computing load.

[0079] Specifically, by calculating the formula

[0080]

[0081] Get the network resource allocation difference var(l net ).

[0082] It should be noted that in the embodiments of the present application, the difference in network resource allocation is used to characterize the balanced distribution of network load. The greater the difference in network resource allocation, the more unbalanced the network load distribution is. A large number of task requests may be allocated to a few edge servers, while other edge servers are idle, resulting in a waste of network resources. The unbalanced distribution of network resources is usually caused by the concentration of user terminals in certain areas (such as towns with high population density), or a large number of user terminals pouring into the same area, causing the edge servers in the area to be overloaded.

[0083] By calculating the formula

[0084]

[0085] Get the computing resource allocation difference var(l cp).

[0086] It should be noted that in the embodiments of the present application, the computing resource allocation difference represents the distribution of computing power of the edge server. The greater the computing resource allocation difference, the more unbalanced the computing power distribution of the edge server. The edge server is overloaded, which may lead to longer routing delays and processing delays, thereby increasing the service time. It can also mean that the cloud data center allocates complex image rendering tasks to edge servers with poor processing capabilities.

[0087] It should be understood that reducing the differences in computing resource allocation is also aimed at alleviating network load problems, so as to reduce the differences in network resource allocation, thereby reducing network congestion, reducing game delays, and improving stability.

[0088] Step 24, based on the deep reinforcement learning model, build a resource optimization model with the lowest game delay, the smallest network resource allocation difference, and the smallest computing resource allocation difference as the optimization goals.

[0089] Specifically, in the embodiment of the present application, the resource optimization model includes a state space S t , action space A and reward function r; where S t represents the state space at time step t, c i represents the CPU quantity required in the task request sent by user terminal i, represents the downlink bandwidth transmitted from edge server j to user terminal i, R j represents the remaining CPU number of edge server j. The action space A includes the action space A1 of the offloading path between servers and the action space A2 of computing resource allocation. A1 = (A 11 ,A 12 ,...,A 1u ,..,A 1U ), A 1u represents the u-th action of the inter-server offloading path, A2=(A 21 ,A 22 ,...,A 2v ,..,A 2V ), A 2v The reward function r is expressed as r = T for the vth action of computing resource allocation. max -w1·T-w2·var(l net )-w3·var(l cp )-w4Fair, T max represents the preset delay threshold, T represents the average game delay, Fair represents the game fairness index. g represents the gth group of user terminals, g = 1, 2, ..., M, M represents the total number of user terminal groups, Fair g Indicates the game fairness of the g-th group of user terminals,

[0090] Considering that in practical applications, channel conditions (channel bandwidth, transmission speed, etc.), server available computing resources, user location and other states have Markov characteristics and are completely observable, therefore, in the embodiment of the present application, the resource optimization model adopts the Markov decision model (MDP, Markov Decision Process). The above-mentioned state space, action space and reward function are the basic elements of the Markov decision model, and the state transition probability of the Markov decision model is set to random.

[0091] Exemplarily, in one embodiment of the present application, an action A of the server-to-server unloading path 1u The rendering task of user terminal i is offloaded to edge server j, which is expressed as A 1u,i =(0,0,1,0), which means that in an edge computing network with only four edge servers, the rendering task of user terminal i is offloaded to the third edge server, where 0 means no offloading, 1 means offloading, and the sequence number of the element indicates the number of the edge server.

[0092] It should be noted that the above-mentioned server offloading path generally refers to a process or path of transferring certain calculations or tasks from one server to other devices or another server.

[0093] Common server uninstallation paths include:

[0094] ① Network layer offloading: Move certain network functions (such as firewalls and load balancing) from the server to dedicated network devices or middleware. This can reduce the load on the server and improve network performance and scalability.

[0095] ② Storage layer offloading: Transferring storage operations (such as data compression and data backup) from the server to dedicated storage devices or cloud services. This can free up server resources and improve data processing efficiency and storage capacity.

[0096] ③ Computing layer offloading: moving certain computing-intensive tasks (such as image processing and machine learning) from servers to dedicated computing devices (such as graphics processors GPUs and dedicated hardware accelerators) to improve computing performance and energy efficiency.

[0097] The above server offloading paths can effectively share the load of edge servers and improve the performance and resource utilization of the overall system. There have been relatively mature studies in this field, and their specific processes and processing steps will not be repeated here.

[0098] Step 25, optimize the resources of the cloud gaming system according to the resource optimization model.

[0099] Specifically, it includes steps 25.1 to 25.2:

[0100] Step 25.1, solve the inter-server offloading path action and computing resource allocation action corresponding to the maximum reward value.

[0101] Step 25.2, optimize the resources of the cloud gaming system according to the inter-server offloading path actions and computing resource allocation actions.

[0102] Exemplarily, the solved inter-server offloading path action is that the cloud gaming system offloads the task request sent by the user terminal from the original edge computing server Z1 to the edge computing server Z2, and the solved computing resource allocation action is that the cloud data center allocates computing resources to the edge computing server Z3. By completing the corresponding actions in accordance with the instructions of the optimal action, the resources of the cloud gaming system can be optimized.

[0103] In an embodiment of the present application, an iterative closest point algorithm (SAC, Soft Actor-Critic) may be used to solve the inter-server offloading path action and computing resource allocation action corresponding to the maximum reward value.

[0104] The specific solution process is as follows:

[0105] Step i, initialization.

[0106] Initialize the policy network (Actor) and Q value network (Critic), as well as the target Q value network and target entropy parameters.

[0107] Step ii, sampling data.

[0108] Use the current policy network to collect a certain amount of trajectory data from the environment. At each time step, select an action based on the current state, execute the action, and observe the reward and next state.

[0109] Step iii, calculate the Q value.

[0110] The Q value of each time step is calculated using the current policy network and the Q value network. Based on the current state and action, the Q value network is used to calculate the Q value of the current state-action pair.

[0111] Step iv, update the policy network.

[0112] Use the policy gradient update method to maximize the expected return of the policy on the sampled data. Maintain the stability of the policy update by minimizing the relative entropy (KL, Kullback-Leibler divergence) of the policy.

[0113] Step v, update the Q value network.

[0114] Using the idea of ​​Q-learning, the rewards and next states generated by the samples of the current policy network are used to update the Q-value network. The goal is to make the Q-value network close to the real cumulative reward.

[0115] Step vi, update the target network.

[0116] The target Q value network and target entropy parameters are updated periodically, and the parameters of the current network and the parameters of the target network are smoothly merged by soft updating.

[0117] Step vii, repeatedly execute steps 14.2 to 14.6 until the number of iterations reaches a preset maximum number of iterations, and obtain the inter-server unloading path action and computing resource allocation action corresponding to the maximum reward value.

[0118] It can be seen that the resource optimization method of the cloud gaming system provided by the present application calculates the game delay, the network resource allocation difference of the edge server and the computing resource allocation difference, and then takes the lowest game delay, the smallest network resource allocation difference and the smallest computing resource allocation difference as the optimization goals, constructs a resource optimization model, and finally optimizes the resources of the cloud game according to the resource optimization model, so that the resource allocation and scheduling method of the optimized cloud game greatly reduces the game delay, and makes the resource allocation of the cloud game more reasonable, avoids bandwidth loss caused by idle resources, and reduces bandwidth consumption; in addition, the resource optimization method also combines the idea of ​​edge computing. Through the edge server, the distance between the server and the user terminal can be reduced, thereby improving stability.

[0119] The following is an exemplary description of the resource optimization device of the cloud gaming system provided in this application.

[0120] like Figure 3 As shown, the resource optimization device 300 of the cloud gaming system includes:

[0121] The task request acquisition module 301 is used to acquire multiple task requests sent by multiple user terminals; the task request corresponds to the user terminal one by one, and the task request includes game screen rendering instructions, CPU quantity and bandwidth requirements.

[0122] The load calculation module 302 is used to allocate the game screen rendering instructions to an edge server in the edge computing network for each task request according to the number of CPUs and bandwidth requirements, and calculate the game delay, game video quality score, network load of the edge server and computing load of the edge server of the task request respectively; the edge computing network includes multiple edge servers.

[0123] The difference calculation module 303 is used to calculate the network resource allocation difference of the edge computing network according to the network load, and to calculate the computing resource allocation difference of the edge computing network according to the computing load; the network resource allocation difference is used to characterize the balanced distribution of the network load, and the computing resource allocation difference is used to characterize the distribution of the computing power of the edge server.

[0124] The optimization model construction module 304 is used to construct a resource optimization model based on a deep reinforcement learning model with the lowest game delay, the smallest network resource allocation difference, and the smallest computing resource allocation difference as optimization goals.

[0125] The optimization module 305 is used to optimize the resources of the cloud gaming system according to the resource optimization model.

[0126] It should be noted that the information interaction, execution process, etc. between the above-mentioned devices / units are based on the same concept as the method embodiment of the present application. Their specific functions and technical effects can be found in the method embodiment part and will not be repeated here.

[0127] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.

[0128] like Figure 4 As shown, an embodiment of the present application provides a terminal device, such as Figure 4 As shown, the terminal device D10 of this embodiment includes: at least one processor D100 ( Figure 4Only one processor is shown in the figure), a memory D101, and a computer program D102 stored in the memory D101 and executable on the at least one processor D100, wherein the processor D100 implements the steps of any of the above-mentioned method embodiments when executing the computer program D102.

[0129] Specifically, when the processor D100 executes the computer program D102, it obtains multiple task requests sent by multiple user terminals, and then, for each task request, respectively, according to the CPU quantity requirement, allocates the game screen rendering instructions to an edge server in the edge computing network, and respectively calculates the game delay of the task request, the network load of the edge computing network, and the computing load of the edge computing network; the edge computing network includes multiple edge servers, and then calculates the network resource allocation difference of the edge computing network according to the network load, and calculates the computing resource allocation difference of the edge computing network according to the computing load; the network resource allocation difference is used to characterize the balanced distribution of the network load, and the computing resource allocation difference is used to characterize the distribution of the computing power of the edge server, and then based on the deep reinforcement learning model, a resource optimization model is constructed with the lowest game delay, the smallest network resource allocation difference, and the smallest computing resource allocation difference as the optimization goals, and finally, according to the resource optimization model, the resources of the cloud gaming system are optimized. Among them, by calculating the game delay, the network resource allocation difference and the computing resource allocation difference of the edge server, and then taking the lowest game delay, the smallest network resource allocation difference and the smallest computing resource allocation difference as the optimization goals, a resource optimization model is constructed. Finally, according to the resource optimization model, the resources of the cloud game are optimized, so that the optimized resource allocation and scheduling method of the cloud game greatly reduces the game delay, and makes the resource allocation of the cloud game more reasonable, avoids the bandwidth loss caused by idle resources, and reduces bandwidth consumption; in addition, this resource optimization method also combines the idea of ​​edge computing. Through the edge server, the distance between the server and the user terminal can be reduced, thereby improving stability.

[0130] The processor D100 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.

[0131] In some embodiments, the memory D101 may be an internal storage unit of the terminal device D10, such as a hard disk or memory of the terminal device D10. In other embodiments, the memory D101 may also be an external storage device of the terminal device D10, such as a plug-in hard disk, a smart memory card (SMC, SmartMedia Card), a secure digital (SD, Secure Digital) card, a flash card (Flash Card), etc. equipped on the terminal device D10. Further, the memory D101 may also include both an internal storage unit of the terminal device D10 and an external storage device. The memory D101 is used to store an operating system, an application program, a boot loader (BootLoader), data and other programs, such as the program code of the computer program, etc. The memory D101 may also be used to temporarily store data that has been output or is to be output.

[0132] An embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in the above-mentioned method embodiments can be implemented.

[0133] An embodiment of the present application provides a computer program product. When the computer program product runs on a terminal device, the terminal device can implement the steps in the above-mentioned method embodiments when executing the computer program product.

[0134] If the integrated unit is implemented in the form of 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 present application implements all or part of the process in the above-mentioned embodiment method, which can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may at least include: any entity or device that can carry the computer program code to the resource optimization device / terminal device of the cloud gaming system, a recording medium, a computer memory, a read-only memory (ROM, Read-Only Memory), a random access memory (RAM, Random Access Memory), an electric carrier signal, a telecommunication signal, and a software distribution medium. For example, a USB flash drive, a mobile hard disk, a magnetic disk or an optical disk. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electric carrier signals and telecommunication signals.

[0135] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

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

[0137] In the embodiments provided in the present application, it should be understood that the disclosed devices / network equipment and methods can be implemented in other ways. For example, the device / network equipment embodiments described above are merely schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

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

[0139] In summary, the resource optimization method of the cloud gaming system provided by this application has the following advantages:

[0140] 1. This application applies the cloud-edge-end architecture assisted by SDN technology to cloud gaming, making full use of the powerful computing power of cloud computing, the flexibility, low latency and reliability of the edge environment. Through SDN technology, the distributed network infrastructure is logically centralized to achieve coordination between cloud-edge-end and optimize the performance of the entire cloud gaming system.

[0141] 2. In view of the actual needs of cloud games and the characteristics of edge servers, this application proposes a multimodal optimization goal, aiming to optimize the interaction delay and picture quality of game players, improve the fairness of multiplayer games, and balance the computing load and network load between regions.

[0142] 3. In order to adapt to the dynamically changing MEC system environment, this application proposes a resource allocation algorithm based on Soft Actor-Critic. The algorithm interacts with the edge computing environment (MEC, Mobile Edge Computing), obtains the state of the dynamic environment, and improves the strategy according to the state to achieve adaptive resource allocation, effectively solving the problem of dynamic environmental changes.

[0143] The above is a preferred embodiment of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles described in the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. A resource optimization method for a cloud gaming system, applied to a cloud data center of the cloud gaming system, wherein the cloud gaming system includes a cloud data center, an edge computing network, and multiple user terminals. It is characterized in that The resource optimization method comprises: Acquire multiple task requests sent by the multiple user terminals; the task requests correspond to the user terminals one by one, and the task requests include game screen rendering instructions, CPU quantity and bandwidth requirements; For each task request, the game screen rendering instruction is allocated to an edge server in the edge computing network according to the number of CPUs and bandwidth requirements, and the game delay, game video quality score, network load of the edge server and computing load of the edge server of the task request are calculated respectively; the edge computing network includes multiple edge servers; According to the network load, the network resource allocation difference of the edge computing network is calculated, and according to the computing load, the computing resource allocation difference of the edge computing network is calculated; the network resource allocation difference is used to characterize the balanced distribution of the network load, and the computing resource allocation difference is used to characterize the distribution of the computing capacity of the edge server; Based on the deep reinforcement learning model, a resource optimization model is constructed with the lowest game delay, the smallest network resource allocation difference, and the smallest computing resource allocation difference as optimization goals; Based on the resource allocation result, aiming at the highest quality of the game screen, adjusting the game video encoding parameters under the constraints of the allocated available resources, so as to achieve mutual adaptation between physical resource allocation and video encoding parameter configuration; According to the resource optimization model, the resources of the cloud gaming system are optimized.

2. The resource optimization method according to claim 1, It is characterized in that The expression of the game delay is T i =t c,j +t i +t j,i , where T i represents the game delay of the task request sent by user terminal i, i = 1, 2, ..., n, n represents the total number of user terminals, t c,j represents the transmission delay of data from cloud data center c to edge server j in the edge computing network, j=1,2,...,m, m represents the total number of edge servers in the edge computing network, d c,j represents the amount of data transmitted from the cloud computing center c to the edge server j, represents the data transmission rate from cloud data center c to edge server j, B represents the channel bandwidth, p c,j represents the transmission power from cloud data center c to edge server j, represents the channel gain, which is related to the transmission distance, σ c represents noise, t i is the processing delay, which indicates the time it takes for the edge server to complete the game screen rendering instruction in the task request sent by user terminal i, t j,i represents the transmission delay of data from edge server j to user terminal i, d j,i represents the amount of data transmitted from edge server j to user terminal i, represents the data transmission rate from edge server j to user terminal i, p j,i represents the transmission power from edge server j to user terminal i, represents the channel gain, σ j Indicates noise; The expression of the network load is: in, represents the network load of edge server j, B j,i represents the transmission bandwidth from edge server j to user terminal i, B j represents the downlink bandwidth of edge server j; The expression for calculating the load is: in, represents the computational load of edge server j, f j,i represents the CPU frequency transmitted from edge server j to user terminal i, F j represents the total CPU frequency of edge server j.

3. The resource optimization method according to claim 2, It is characterized in that Calculating a network resource allocation difference of the edge computing network according to the network load, and calculating a computing resource allocation difference of the edge computing network according to the computing load, including: By calculating the formula Get the network resource allocation difference var(l net ); By calculating the formula Get the computing resource allocation difference var(l cp ).

4. The resource optimization method according to claim 3, It is characterized in that The resource optimization model includes a state space S t , action space A and reward function r; where S t represents the state space at time step t, c i represents the CPU quantity required in the task request sent by user terminal i, represents the downlink bandwidth transmitted from edge server j to user terminal i, R j represents the remaining CPU number of edge server j, and the action space A includes the action space A of the offloading path between servers 1 and the action space A for computing resource allocation 2 , A 1 =(A 11 ,A 12 ,...,A 1u ,..,A 1U ), A 1u represents the u-th action of the inter-server offloading path, A 2 =(A 21 ,A 22 ,...,A 2v ,..,A 2V ), A 2v The reward function r is expressed as r = T for the vth action of computing resource allocation. max -w 1 ·Tw 2 var(l net )-w 3 var(l cp )-w 4 Fair, T max represents the preset delay threshold, T represents the average game delay, Fair represents the game fairness index. g represents the gth group of user terminals, g = 1, 2, ..., M, M represents the total number of user terminal groups, Fair g Indicates the game fairness of the g-th group of user terminals, 5. The resource optimization method according to claim 4, It is characterized in that Optimizing the resources of the cloud gaming system according to the resource optimization model includes: Solve the inter-server offloading path action and computing resource allocation action corresponding to the maximum reward value; According to the inter-server unloading path action and the computing resource allocation action, the resources of the cloud gaming system are optimized.

6. A resource optimization device for a cloud gaming system, It is characterized in that include: A task request acquisition module, used to acquire multiple task requests sent by the multiple user terminals; The task request corresponds to the user terminal one by one, and the task request includes a game screen rendering instruction, a CPU quantity and a bandwidth requirement; A load calculation module is used to allocate the game screen rendering instruction to an edge server in the edge computing network for each task request according to the number of CPUs and bandwidth requirements, and calculate the game delay, game video quality score, network load of the edge server and computing load of the edge server of the task request; the edge computing network includes multiple edge servers; a difference calculation module, configured to calculate a network resource allocation difference of the edge computing network according to the network load, and to calculate a computing resource allocation difference of the edge computing network according to the computing load; The network resource allocation difference is used to characterize the balanced distribution of network load, and the computing resource allocation difference is used to characterize the distribution of computing power of edge servers; An optimization model building module, for building a resource optimization model based on a deep reinforcement learning model with the lowest game delay, the smallest network resource allocation difference, and the smallest computing resource allocation difference as optimization goals; An optimization module, used to optimize the resources of the cloud gaming system according to the resource optimization model; The video encoding parameter configuration module is used to adaptively adjust the cloud game video encoding parameter configuration according to the resource optimization result.

7. A terminal device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, It is characterized in that When the processor executes the computer program, the resource optimization method according to any one of claims 1 to 5 is implemented.

8. A computer-readable storage medium storing a computer program. It is characterized in that When the computer program is executed by a processor, the resource optimization method according to any one of claims 1 to 5 is implemented.

Citation Information

Patent Citations

  • A method for edge cloud game cache and resource scheduling

    CN109460297A

  • Edge computing task allocation method of fusion recommendation system

    CN112749010A

  • Task migration method of edge computing network based on deep reinforcement learning

    CN116489711A

Cited By

  • Connection resource scheduling method, cloud platform and electronic equipment

    CN119697234A

  • A connection resource scheduling method, cloud platform and electronic device

    CN119697234B

  • Network resource allocation method and device, terminal equipment and computer program product

    CN119814547A

  • Network resource allocation method, apparatus, terminal device, and computer program product

    CN119814547B

  • 5G-based adaptive network resource scheduling method

    CN120076054A