Cloud computing task allocation model construction method and system and application method and application system thereof
By building a teacher model, using recurrent neural networks and graph neural networks to capture the complex patterns and correlations of task and server parameters, the problem of taking into account efficiency and accuracy in the cloud computing task allocation method is solved, and efficient and fair resource allocation is achieved.
Patent Information
- Application Number
- CN202411646847.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-18
- Publication Date
- 2025-02-28
AI Technical Summary
The existing cloud computing task allocation methods cannot take into account both allocation efficiency and allocation accuracy, and the traditional methods are inefficient and lack open and transparent allocation logic.
By building a teacher model, recurrent neural networks and graph neural networks capture the complex patterns and correlations of task and server parameters, and obtain a cloud computing task allocation model through model compression and knowledge distillation to achieve efficient resource allocation.
It realizes the efficient capture of complex patterns and correlations in input data while capturing the topological structure and temporal dynamics in resource allocation problems, and improves the efficiency and fairness of resource allocation.
Smart Images

Figure CN119537020A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of task allocation, and more specifically, to a cloud computing task allocation model construction method, system and application method and application system thereof. Background Art
[0002] Today, edge computing has been facing the challenge of limited resources, so these scattered resources need to be efficiently coordinated and managed to achieve maximum resource utilization.
[0003] In traditional edge computing allocation methods, tasks need to queue up on the main server and be allocated to several sub-servers, which requires frequent communication between the main server and the sub-servers, resulting in low allocation efficiency. At the same time, the actual situation of the main server and the sub-servers is not public, and there is a lack of an effective and comprehensive workload measurement mechanism; for example, if the sub-server cluster is charged according to the amount of tasks processed, some sub-servers will also cause disputes over the amount of tasks because the main server and sub-server information is not public.
[0004] The prior art discloses a cloud computing resource allocation method based on an improved genetic algorithm. The method first constructs a mathematical model of cloud resource allocation, and then designs an improved genetic algorithm to solve it. The main improvement is the generation of its initial population and the improvement of the crossover and mutation method. When initializing the population, the virtual machines are divided into H groups using a sub-adaptive algorithm, and each group corresponds to a physical machine, thereby ensuring the effectiveness of the initial population. A gene evaluation function is introduced to evaluate the load of each physical machine, and crossover and mutation are performed based on this, thereby ensuring the efficiency of the algorithm. Finally, the virtual machine allocation plan with the minimum number of physical machine activations and the maximum resource utilization is obtained through iteration. The efficiency of this method is relatively low. Summary of the invention
[0005] In view of the defect that the existing cloud computing task allocation methods cannot take into account both allocation efficiency and allocation accuracy, the present invention provides a cloud computing task allocation model construction method, system and its application method and application system, which can capture the complex patterns and correlations in the input tasks while taking into account the allocation efficiency through model compression and knowledge distillation.
[0006] The primary purpose of the present invention is to solve the above technical problems. The technical solution of the present invention is as follows:
[0007] A method for constructing a cloud computing task allocation model, comprising:
[0008] S101: construct a training sample set, including training task parameters, server parameters, and corresponding allocation sequence labels;
[0009] S102: inputting the training sample set into the constructed teacher model, setting the loss function for iterative training, until the loss function reaches a minimum, and obtaining a trained teacher model;
[0010] S103: Modify the structure of the trained teacher model to obtain a cloud computing task allocation model.
[0011] Furthermore, the teacher model includes: a recurrent neural network unit, a graph neural network unit, a tensor repetition unit, a tensor reorganization unit, a tensor division unit, a first linear layer, an activation layer, a second linear layer, and a sequence integration unit;
[0012] The output end of the neural network unit is connected to the input end of the tensor reorganization unit, the output end of the tensor reorganization unit and the output end of the tensor repeating unit are connected to the input end of the tensor division unit, the output end of the tensor division unit is connected to the input end of the recurrent neural network unit, the output end of the recurrent neural network unit is connected to the input end of the first linear layer, the output end of the first linear layer is connected to the input end of the activation layer, the output end of the activation layer is connected to the input end of the second linear layer, and the output end of the second linear layer is connected to the input end of the sequence integration unit;
[0013] The training task parameters are input into the input end of the graph neural network unit, the server parameters are input into the input end of the tensor repeating unit, and the sequence integration unit outputs the assigned sequence label.
[0014] Furthermore, in step S103, the structure of the trained teacher model is modified to obtain a cloud computing task allocation model, including:
[0015] Extract recurrent neural network units and graph neural network units from the trained teacher model, add tensor expansion units, decoding units, dimension reorganization units, and sequence integration units to obtain a cloud computing task allocation model;
[0016] Among them, the output end of the tensor expansion unit is connected to the input end of the recurrent neural network unit, the output end of the recurrent neural network unit and the output end of the graph neural network unit are connected to the input end of the dimension reorganization unit, the output end of the dimension reorganization unit is connected to the input end of the decoding unit, and the output end of the decoding unit is connected to the input end of the sequence integration unit.
[0017] Further, the recurrent neural network unit includes a recurrent neural network layer and a first fully connected layer connected in sequence;
[0018] The graph neural network unit includes a graph convolution layer and a second fully connected layer connected in sequence;
[0019] The decoding unit includes a third linear layer.
[0020] Furthermore, in step S102, the loss function is as follows:
[0021]
[0022] i represents the sequence number, n represents the number of training tasks, and y i Indicates the server number assigned to the i-th training task, The server of the i-th training task assigns a label number.
[0023] Furthermore, in step S101, a genetic algorithm is used to generate the assigned sequence tags.
[0024] A cloud computing task allocation model construction system, comprising:
[0025] Sample set construction module: constructs a training sample set, including training task parameters, server parameters, and corresponding assigned sequence labels;
[0026] Training module: input the training sample set into the constructed teacher model, set the loss function for iterative training, until the loss function reaches the minimum, and obtain the trained teacher model;
[0027] Allocation model building module: modify the structure of the trained teacher model to obtain a cloud computing task allocation model.
[0028] A cloud computing task allocation model application method, comprising:
[0029] S201: receiving a number of tasks to be assigned submitted by a user, and obtaining task parameters of each task to be assigned;
[0030] S202: Inputting the task parameters of each task to be assigned and the server parameters of multiple servers to be selected into the cloud computing task assignment model to obtain a task assignment sequence;
[0031] S203: Allocate each to-be-allocated task to each to-be-selected server according to the task allocation sequence.
[0032] Furthermore, the task parameters of the task to be assigned include: task size, workload load, and amount of data transmitted;
[0033] The server parameters of the server to be selected include: CPU operation speed, bandwidth, and processing delay.
[0034] A cloud computing task allocation model application system, comprising:
[0035] Task receiving module: receiving several tasks to be assigned submitted by the user, and obtaining the task parameters of each task to be assigned;
[0036] An allocation sequence generation module: inputs the task parameters of each task to be allocated and the server parameters of multiple servers to be selected into the cloud computing task allocation model to obtain a task allocation sequence;
[0037] Task allocation module: allocates each task to be allocated to each server to be selected according to the task allocation sequence.
[0038] Compared with the prior art, the present invention has the following beneficial effects:
[0039] The present invention can effectively capture the complex patterns and correlations in the input data while effectively capturing the topological structure and time dynamics in the resource allocation problem through the teacher model.
[0040] By compressing the teacher model and performing knowledge distillation on it, a cloud computing task allocation model is obtained to achieve a trade-off between performance and complexity, and to realize resource allocation that balances efficiency and fairness.
[0041] In practical applications, by setting the cloud computing task allocation model in the server of the edge node, the task allocation logic is made open and transparent, so as to efficiently generate fair and reasonable resource allocation plans. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] Figure 1 This is a flowchart of a method for building a cloud computing task allocation model provided in Example 1.
[0043] Figure 2 This is a structural diagram of the teacher model provided in Example 1.
[0044] Figure 3 This is a structural diagram of the cloud computing task allocation model provided in Example 1.
[0045] Figure 4 This is a structural diagram of a cloud computing task allocation model building system provided in Example 1.
[0046] Figure 5 This is a flowchart of a cloud computing task allocation model application method provided in Example 1.
[0047] Figure 6 This is a structural diagram of a cloud computing task allocation model application system provided in Example 1. DETAILED DESCRIPTION
[0048] The drawings are for illustrative purposes only and should not be construed as limiting the present patent;
[0049] In order to better illustrate the present embodiment, some parts in the drawings may be omitted, enlarged or reduced, and do not represent the size of the actual product;
[0050] It is understandable to those skilled in the art that some well-known structures and their descriptions may be omitted in the drawings.
[0051] The technical solution of the present invention is further described below in conjunction with the accompanying drawings and embodiments.
[0052] Example 1
[0053] like Figure 1 As shown, a method for constructing a cloud computing task allocation model includes:
[0054] S101: construct a training sample set, including training task parameters, server parameters, and corresponding allocation sequence labels;
[0055] S102: inputting the training sample set into the constructed teacher model, setting the loss function for iterative training, until the loss function reaches a minimum, and obtaining a trained teacher model;
[0056] S103: Modify the structure of the trained teacher model to obtain a cloud computing task allocation model.
[0057] Furthermore, if Figure 2 As shown, the teacher model includes: a recurrent neural network unit, a graph neural network unit, a tensor repetition unit, a tensor reorganization unit, a tensor division unit, a first linear layer, an activation layer, a second linear layer, and a sequence integration unit;
[0058] The output end of the neural network unit is connected to the input end of the tensor reorganization unit, the output end of the tensor reorganization unit and the output end of the tensor repeating unit are connected to the input end of the tensor division unit, the output end of the tensor division unit is connected to the input end of the recurrent neural network unit, the output end of the recurrent neural network unit is connected to the input end of the first linear layer, the output end of the first linear layer is connected to the input end of the activation layer, the output end of the activation layer is connected to the input end of the second linear layer, and the output end of the second linear layer is connected to the input end of the sequence integration unit;
[0059] The training task parameters are input into the input end of the graph neural network unit, the server parameters are input into the input end of the tensor repeating unit, and the sequence integration unit outputs the assigned sequence label.
[0060] It should be noted that by combining graph neural networks and recurrent neural networks and utilizing the characteristics of graph structure and sequence data to perform resource allocation, it is possible to better capture the complex patterns and correlations in the input data.
[0061] Furthermore, if Figure 3 As shown, in step S103, the structure of the trained teacher model is modified to obtain a cloud computing task allocation model, including:
[0062] Extract recurrent neural network units and graph neural network units from the trained teacher model, add tensor expansion units, decoding units, dimension reorganization units, and sequence integration units to obtain a cloud computing task allocation model;
[0063] Among them, the output end of the tensor expansion unit is connected to the input end of the recurrent neural network unit, the output end of the recurrent neural network unit and the output end of the graph neural network unit are connected to the input end of the dimension reorganization unit, the output end of the dimension reorganization unit is connected to the input end of the decoding unit, and the output end of the decoding unit is connected to the input end of the sequence integration unit.
[0064] It should be noted that the cloud computing task allocation model uses recurrent neural network units and graph neural network units, which has good diversity and robustness, and can enhance the generalization ability of the model in complex environments.
[0065] It should be noted that the cloud computing task allocation model only retains the recurrent neural network units and graph neural network units of the teacher model, thereby simplifying the teacher model and achieving a trade-off between performance and complexity through model compression and knowledge distillation.
[0066] It should be noted that the function of the sequence integration unit is to use the server with the largest probability prediction value among the servers of each task as the assigned server of the task, thereby forming a task assignment sequence.
[0067] Further, the recurrent neural network unit includes a recurrent neural network layer and a first fully connected layer connected in sequence;
[0068] The output end of the recurrent neural network layer is connected to the input end of the first fully connected layer;
[0069] The graph neural network unit includes a graph convolution layer and a second fully connected layer connected in sequence;
[0070] The output end of the graph convolutional layer is connected to the input end of the second fully connected layer;
[0071] The decoding unit includes a third linear layer.
[0072] Furthermore, in step S102, the loss function is as follows:
[0073]
[0074] i represents the sequence number, n represents the number of training tasks, and y i Indicates the server number assigned to the i-th training task, The server of the i-th training task assigns a label number.
[0075] Furthermore, in step S101, a genetic algorithm is used to generate the assigned sequence tags.
[0076] It should be noted that by using data augmentation methods and genetic algorithms to generate some synthetic and optimized data samples, using deep learning models to train on this expanded training sample set, and evaluating the trained model on the test set, it is expected that better optimization results may be obtained.
[0077] like Figure 4 As shown, a cloud computing task allocation model construction system includes:
[0078] Sample set construction module: constructs a training sample set, including training task parameters, server parameters, and corresponding assigned sequence labels;
[0079] Training module: input the training sample set into the constructed teacher model, set the loss function for iterative training, until the loss function reaches the minimum, and obtain the trained teacher model;
[0080] Allocation model building module: modify the structure of the trained teacher model to obtain a cloud computing task allocation model.
[0081] like Figure 5 As shown, a cloud computing task allocation model application method includes:
[0082] S201: receiving a number of tasks to be assigned submitted by a user, and obtaining task parameters of each task to be assigned;
[0083] S202: Inputting the task parameters of each task to be assigned and the server parameters of multiple servers to be selected into the cloud computing task assignment model to obtain a task assignment sequence;
[0084] S203: Allocate each to-be-allocated task to each to-be-selected server according to the task allocation sequence.
[0085] It should be noted that in this solution, the status of multiple servers to be selected is equal, there is no difference between the main server and the sub-server, and each server is decentralized.
[0086] It should be noted that this method can obtain a fair resource allocation plan that meets the needs of all participants, and can also take into account the overall system performance indicators, so that the allocation results balance the personal interests of the participants with the overall optimization of the system. This method does not require the participation of the central server and therefore does not require multiple data transmissions, so it is more efficient.
[0087] In a specific embodiment, the formula for measuring the effect of the entire allocation scheme is as follows:
[0088]
[0089] N is the total number of servers, i and j represent serial numbers, and W q,j represents the queuing delay of the jth server, λ j represents the arrival rate of the jth server, μ j represents the service rate of the jth server, ω i represents the workload of the ith task, D i represents the amount of data transmitted by the i-th task, f j represents the CPU speed of the jth server, b j The bandwidth of data transmission to the jth server.
[0090] Furthermore, the task parameters of the task to be assigned include: task size, workload load, and amount of data transmitted;
[0091] The server parameters of the server to be selected include: CPU operation speed, bandwidth, and processing delay.
[0092] like Figure 6 As shown, a cloud computing task allocation model application system includes:
[0093] Task receiving module: receiving several tasks to be assigned submitted by the user, and obtaining the task parameters of each task to be assigned;
[0094] An allocation sequence generation module: inputs the task parameters of each task to be allocated and the server parameters of multiple servers to be selected into the cloud computing task allocation model to obtain a task allocation sequence;
[0095] Task allocation module: allocates each task to be allocated to each server to be selected according to the task allocation sequence.
[0096] Example 2
[0097] Based on the cloud computing task allocation model construction method, system and its application method and application system described in Example 1, that is, this embodiment adopts the same cloud computing task allocation model construction method, system and its application method and application system as Example 1.
[0098] This method can be specifically applied to blockchain computing node allocation.
[0099] Edge computing involves a large number of distributed resources, including computing, storage, bandwidth, etc., which require efficient coordination and management of these decentralized resources. Traditional centralized resource management methods are inefficient and lack credibility, while the introduction of blockchain technology can achieve decentralized resource transactions and scheduling, significantly improving the openness, efficiency and resource utilization of transactions. Common consensus mechanisms include proof of work (PoW) and proof of stake (PoS), but both are relatively one-sided and do not require participants to contribute enough to the community.
[0100] The game can generate consensus knowledge. Nodes must reach consensus by selecting strategies and decide on the update of blockchain status. Using the Proof of Contribution (PoC) consensus mechanism, resources involved in computing and competition are selected to maximize contributions to shortening latency or balancing overall resource utilization. PoC determines the influence of participants in the network based on their computing power and resource level, which has a positive impact on the performance efficiency of edge networks.
[0101] The cloud computing task allocation model is deployed on the edge nodes of the blockchain, and PoC transactions of resources are realized on the chain through peer-to-peer communication and decentralized consensus.
[0102] It should be noted that since edge nodes may belong to different stakeholders, centralized management may cause trust and privacy issues. Therefore, the teacher model is maintained by the resource management system / center, while the cloud computing task allocation model allocates resources on the blockchain nodes. Even if some blockchain nodes fail to calculate or have malicious behavior, the entire blockchain system can still operate normally. Each blockchain node cannot fully understand the internal status of other blockchain nodes, which reduces the possibility of the system being destroyed.
[0103] Since the blockchain system as a whole constitutes a Byzantine fault-tolerant system, the Euclidean distance diversity score can be used to further measure the stability of the allocation scheme, preventing a single stakeholder from controlling the entire blockchain system and increasing the cost for attackers.
[0104] The formula for the Euclid diversity score D is as follows:
[0105]
[0106] d(P i ,P j )=sqrt[(P i1 -P j1 ) 2 +(P i2 -P j2 ) 2 +…+(P iN -P jN ) 2 ]
[0107] i and j represent the sequence number, n represents the number of cloud computing tasks, d(P i ,P j ) represents task P i With task P j The Euclidean distance, P i1 Represents task P i The probability of being assigned to server 1, P iN Represents task P i The probability of being assigned to server number N, where N is the total number of servers.
[0108] The same or similar reference numerals correspond to the same or similar components;
[0109] The terms used in the drawings to describe positional relationships are only used for illustrative purposes and should not be construed as limiting this patent;
[0110] Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not intended to limit the embodiments of the present invention. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the embodiments here. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the claims of the present invention.
Claims
1. A method for constructing a cloud computing task allocation model, characterized in that: include: S101: construct a training sample set, including training task parameters, server parameters, and corresponding allocation sequence labels; S102: inputting the training sample set into the constructed teacher model, setting the loss function for iterative training, until the loss function reaches a minimum, and obtaining a trained teacher model; S103: Modify the structure of the trained teacher model to obtain a cloud computing task allocation model.
2. A method for constructing a cloud computing task allocation model according to claim 1, characterized in that: The teacher model includes: a recurrent neural network unit, a graph neural network unit, a tensor repetition unit, a tensor reorganization unit, a tensor division unit, a first linear layer, an activation layer, a second linear layer, and a sequence integration unit; The output end of the neural network unit is connected to the input end of the tensor reorganization unit, the output end of the tensor reorganization unit and the output end of the tensor repeating unit are connected to the input end of the tensor division unit, the output end of the tensor division unit is connected to the input end of the recurrent neural network unit, the output end of the recurrent neural network unit is connected to the input end of the first linear layer, the output end of the first linear layer is connected to the input end of the activation layer, the output end of the activation layer is connected to the input end of the second linear layer, and the output end of the second linear layer is connected to the input end of the sequence integration unit; The training task parameters are input into the input end of the graph neural network unit, the server parameters are input into the input end of the tensor repeating unit, and the sequence integration unit outputs the assigned sequence label.
3. A method for constructing a cloud computing task allocation model according to claim 2, characterized in that: In step S103, the structure of the trained teacher model is modified to obtain a cloud computing task allocation model, including: Extract recurrent neural network units and graph neural network units from the trained teacher model, add tensor expansion units, decoding units, dimension reorganization units, and sequence integration units to obtain a cloud computing task allocation model; Among them, the output end of the tensor expansion unit is connected to the input end of the recurrent neural network unit, the output end of the recurrent neural network unit and the output end of the graph neural network unit are connected to the input end of the dimension reorganization unit, the output end of the dimension reorganization unit is connected to the input end of the decoding unit, and the output end of the decoding unit is connected to the input end of the sequence integration unit.
4. A method for constructing a cloud computing task allocation model according to claim 3, characterized in that: The recurrent neural network unit comprises a recurrent neural network layer and a first fully connected layer connected in sequence; The graph neural network unit includes a graph convolution layer and a second fully connected layer connected in sequence; The decoding unit includes a third linear layer.
5. The method for constructing a cloud computing task allocation model according to claim 1, characterized in that: In step S101, a genetic algorithm is used to generate the assigned sequence tags.
6. The method for constructing a cloud computing task allocation model according to claim 1, characterized in that: In step S102, the loss function is as follows: i represents the sequence number, n represents the number of training tasks, and y i Indicates the server number assigned to the i-th training task, The server of the i-th training task assigns a label number.
7. A cloud computing task allocation model construction system, applied to the construction method according to any one of claims 1 to 6, characterized in that: include: Sample set construction module: constructs a training sample set, including training task parameters, server parameters, and corresponding assigned sequence labels; Training module: input the training sample set into the constructed teacher model, set the loss function for iterative training, until the loss function reaches the minimum, and obtain the trained teacher model; Allocation model building module: modify the structure of the trained teacher model to obtain a cloud computing task allocation model.
8. A cloud computing task allocation model application method, characterized in that: include: S201: receiving a number of tasks to be assigned submitted by a user, and obtaining task parameters of each task to be assigned; S202: Inputting the task parameters of each task to be assigned and the server parameters of multiple servers to be selected into the cloud computing task assignment model according to any one of claims 1 to 6 to obtain a task assignment sequence; S203: Allocate each to-be-allocated task to each to-be-selected server according to the task allocation sequence.
9. The method for applying a cloud computing task allocation model according to claim 8, characterized in that: The task parameters of the task to be assigned include: task size, workload load, and amount of data transmitted; The server parameters of the server to be selected include: CPU operation speed, bandwidth, and processing delay.
10. A cloud computing task allocation model application system, applied to the application method described in claim 8 or 9, characterized in that: include: Task receiving module: receiving several tasks to be assigned submitted by the user, and obtaining the task parameters of each task to be assigned; An allocation sequence generation module: inputting the task parameters of each task to be allocated and the server parameters of multiple selected servers into the cloud computing task allocation model according to any one of claims 1 to 6 to obtain a task allocation sequence; Task allocation module: allocates each task to be allocated to each server to be selected according to the task allocation sequence.