Model training method of edge computing and edge-cloud collaboration system
By using an edge-cloud collaborative system and federated learning, the problems of insufficient computing power and poor synchronization of edge computing devices in model training are solved, achieving high-precision and efficient model training.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA MOBILE COMM LTD RES INST
- Filing Date
- 2022-03-07
- Publication Date
- 2026-05-01
AI Technical Summary
In existing technologies, edge computing devices suffer from insufficient computing power and limited data volume during model training, resulting in insufficient model accuracy and poor training synchronization.
An edge-cloud collaborative system based on deterministic networks is adopted. Through collaborative training between edge nodes and cloud nodes, edge nodes determine the maximum number of trainable layers based on their own computing power and reserve bandwidth resources. Cloud nodes complete the training of subsequent model layers and global model generation. A federated aggregation algorithm is used to improve model accuracy.
It improves the accuracy and synchronization of model training, alleviates the computational pressure on edge nodes, supports training on heterogeneous data, and raises the upper limit of model training.
Smart Images

Figure CN116777011B_ABST
Abstract
Description
Model training methods for edge computing and edge-cloud collaborative systems Technical Field
[0001] This invention relates to the field of optical access network and edge-cloud collaboration technology, and in particular to an edge computing model training method and an edge-cloud collaboration system. Background Technology
[0002] In existing technologies, edge computing devices, within their jurisdiction, input sample user data collected from various users into a first recommendation model for federated training. Upon meeting preset training termination conditions, the trained target first recommendation model is output. Each sample user data point contains the user's human characteristics and actual behavior information. The first recommendation model is used to predict user behavior and recommend related objects. This allows for federated training of the first recommendation model on edge computing devices without compromising user privacy or reducing network data transmission volume, resulting in a more accurate and widely applicable target first recommendation model. This, in turn, enables more accurate behavior prediction for new users and the development of more precise recommendation schemes.
[0003] With the development of edge intelligence in the Internet of Things (IoT), machine learning model training techniques have made significant progress. Current methods focus on improving training techniques, but they do not comprehensively consider the data privacy protection, data support, and computing power required for model training. Existing methods utilize independent training at the edge, which protects data privacy, but cannot guarantee the amount of data and computing power; it also introduces training synchronization problems. For example, using independent datasets from edge nodes for training cannot guarantee sufficient training data to support training requirements due to the limited storage capacity at the edge, leading to insufficient model accuracy. Summary of the Invention
[0004] The purpose of this invention is to provide a model training method and an edge-cloud collaborative system for edge computing, so as to solve the problem that the model training methods in edge computing scenarios in the prior art are prone to insufficient model accuracy.
[0005] To address the aforementioned problems, this invention provides a model training method for edge computing, applied to an edge-cloud collaborative system based on deterministic networks. The edge-cloud collaborative system includes a cloud node and multiple edge nodes, where transmission from the edge nodes to the cloud node satisfies deterministic latency. The method includes:
[0006] After each edge node determines the first model to be used, it determines the maximum number of trainable layers of the first model that the edge node can support based on its own computing power information.
[0007] Each edge node determines the required slice bandwidth and reserves bandwidth resources based on the maximum trainable number of layers and the deterministic latency.
[0008] Each edge node is trained based on the first model, and after training is completed, it sends the trained model parameters to the cloud node through reserved bandwidth resources. The cloud node then completes the subsequent model layer training and updates the edge model through the backpropagation algorithm.
[0009] The cloud node uses a federated aggregation algorithm to aggregate the edge models corresponding to each edge node, generate a global model, and then sends the global model to the edge node.
[0010] The method further includes:
[0011] The edge nodes are trained based on the global model until the training rounds reach a first value or the model accuracy reaches a second value.
[0012] Among them, the edge node determines the maximum number of trainable layers of the first model that it can support based on its own computing power information, including:
[0013] Edge nodes calculate their available computing power based on their own computing capabilities and current CPU utilization.
[0014] The edge node determines the maximum number of trainable layers of the first model that its available computing power can support, based on the number of computations required for each layer in the first model.
[0015] If the maximum number of trainable layers of the first model that the available computing power of the edge node can support is less than 1, then the edge node will exit the current model training.
[0016] The edge node calculates its available computing power based on its own computing capabilities and current CPU utilization, including:
[0017] The edge node calculates its available computing power (FLOPS) according to the first formula. ava The first formula is:
[0018] FLOPS ava = (1-cpu) ur )*FLOPS;
[0019] Among them, FLOPS ava This represents the available computing power of an edge node; FLOPS represents the computing power of the edge node itself; and CPU... ur This indicates the current CPU utilization of the edge node.
[0020] The computing power of the edge node itself includes: the floating-point computing power of the edge node per second; the method further includes:
[0021] The edge node determines its floating-point computing power (FLOPS) per second according to a second formula; wherein the second formula is:
[0022] FLOPS = X * CPU K *ε
[0023] Where X represents the number of cores on the edge node; CPU K ε represents the clock speed of a single core; ε represents the number of floating-point calculations per CPU cycle.
[0024] Wherein, the edge node determines the maximum number of trainable layers of the first model that its available computing power can support based on the number of computations required for each layer in the first model, including:
[0025] The edge node determines, according to a third formula, the maximum number of trainable layers of the first model that its available computing power can support; wherein, the third formula is:
[0026]
[0027] Among them, FLOPS ava Indicates the available computing power of the edge node; size bat Indicates the size of the training batch; cal i t represents the number of computations required for the i-th layer; t represents the training latency; the maximum i-th value satisfying the third formula is the maximum number of trainable layers.
[0028] Specifically, the edge nodes determine the required slice bandwidth for each edge node and reserve bandwidth resources based on the maximum trainable layer number and the deterministic latency, including:
[0029] The edge node calculates the amount of data transmitted from the edge node to the cloud node;
[0030] The edge node determines the bandwidth required to transmit the amount of data based on the deterministic delay.
[0031] The edge node allocates and reserves bandwidth resources based on the current network resources and the determined bandwidth size;
[0032] The edge nodes utilize the allocated resources to instantiate and orchestrate virtual network functions and interfaces within the network slice, thereby completing slice creation.
[0033] The method further includes, after the edge node allocates and reserves bandwidth resources based on current network resources and a determined bandwidth size, the method also includes:
[0034] Without affecting the performance of other slices, the edge node is configured with shared resources, which are used to transmit information other than model parameters.
[0035] This invention also provides an edge-cloud collaborative system based on deterministic networks, the edge-cloud collaborative system comprising:
[0036] A cloud node and multiple edge nodes; wherein the transmission from the edge nodes to the cloud node satisfies deterministic latency;
[0037] The edge nodes are used to: determine the maximum number of trainable layers that the edge nodes can support for the first model after determining the first model to be used, based on their own computing power information; determine the required slice bandwidth for each edge node and reserve bandwidth resources based on the maximum number of trainable layers and the deterministic latency; train based on the first model, and send the trained model parameters to the cloud node through the reserved bandwidth resources after training is completed.
[0038] The cloud nodes are used to: complete subsequent model layer training based on the model parameters obtained from edge node training, and update the edge models through backpropagation algorithm; further, use federated aggregation algorithm to aggregate the edge models corresponding to each edge node to generate a global model, and send the global model to the edge nodes.
[0039] The edge nodes are also used to: train the global model until the training rounds reach a first value or the model accuracy reaches a second value.
[0040] The edge nodes are also used for:
[0041] Calculate the available computing power of the edge node based on its own computing power and current CPU utilization.
[0042] Based on the number of computations required for each layer in the first model, determine the maximum number of trainable layers of the first model that the available computing power of the edge node can support.
[0043] The edge nodes are also used for:
[0044] Calculate the amount of data transmitted from the edge node to the cloud node;
[0045] Based on the deterministic delay, determine the bandwidth required to transmit the amount of data;
[0046] Based on the current network resources and the determined bandwidth size, allocate and reserve bandwidth resources for the edge nodes;
[0047] Using the allocated resources, the virtual network functions and interfaces in the network slice are instantiated and services are orchestrated to complete the slice creation.
[0048] The above-described technical solution of the present invention has at least the following beneficial effects:
[0049] The edge computing model training method and edge-cloud collaborative system of this invention embodiment include an edge-cloud collaborative system based on deterministic networks, used for machine model training of multiple edge nodes in the Internet of Things; wherein, the deterministic network ensures the synchronization of training, the edge-cloud system solves the problem of insufficient computing power of edge nodes and reduces the training pressure of edge nodes; federated learning ensures the number of training sessions and improves the model training accuracy. Attached Figure Description
[0050] Figure 1 shows a flowchart of the steps of the edge computing model training method provided in an embodiment of the present invention;
[0051] Figure 2 shows a schematic diagram of the structure of the edge-cloud collaborative system based on deterministic networks provided in an embodiment of the present invention. Detailed Implementation
[0052] To make the technical problems, technical solutions and advantages of the present invention clearer, a detailed description will be given below in conjunction with the accompanying drawings and specific embodiments.
[0053] As shown in Figure 1, this embodiment of the invention provides a model training method for edge computing, applied to an edge-cloud collaborative system based on deterministic networks. The edge-cloud collaborative system includes: a cloud node and multiple edge nodes, wherein the transmission from the edge node to the cloud node satisfies deterministic latency. The method includes:
[0054] Step 101: After each edge node determines the first model to be used, it determines the maximum number of trainable layers that the edge node can support for the first model based on its own computing power information.
[0055] For example, each edge node determines the first model to be used through voting.
[0056] Step 102: Each edge node determines the required slice bandwidth and reserves bandwidth resources based on the maximum trainable number of layers and the deterministic latency.
[0057] Step 103: Each edge node trains based on the first model, and after training is completed, sends the trained model parameters to the cloud node through the reserved bandwidth resources. The cloud node then completes the subsequent model layer training and updates the edge model through the backpropagation algorithm.
[0058] Step 104: The cloud node uses a federated aggregation algorithm to aggregate the edge models corresponding to each edge node, generate a global model, and send the global model to the edge node.
[0059] The edge computing model training method provided in this embodiment of the invention is a training algorithm that can achieve privacy protection, data support, and computing power support. Before step 101, the method provided in this embodiment of the invention further includes: building an edge collaborative system based on a federated learning algorithm. For example, according to the needs of IoT application scenarios, multiple edge nodes and one cloud node are deployed; and machine learning environments are configured on the edge nodes and the cloud node.
[0060] Furthermore, in this embodiment of the invention, the method further includes:
[0061] The edge nodes are trained based on the global model until the number of training epochs reaches a first value or the model accuracy reaches a second value. For example, the edge nodes are trained based on the global model until the number of training epochs reaches 200 or the model accuracy reaches 95%.
[0062] In at least one embodiment of the present invention, step 101, in which the edge node determines the maximum number of trainable layers of the first model that the edge node can support based on its own computing power information, includes:
[0063] Edge nodes calculate their available computing power based on their own computing capabilities and current CPU utilization.
[0064] The edge node determines the maximum number of trainable layers of the first model that its available computing power can support, based on the number of computations required for each layer in the first model.
[0065] In this embodiment of the invention, the edge node obtains a model partitioning scheme based on computing power, according to the maximum number of trainable layers of the first model that its available computing power can support. It should be noted that if the maximum number of trainable layers of the first model that the edge node's available computing power can support is less than 1, the edge node exits the current model training and waits for the next training iteration.
[0066] As an optional embodiment, the edge node calculates its available computing power based on its own computing capabilities and current CPU utilization, including:
[0067] The edge node calculates its available computing power (FLOPS) according to the first formula. ava The first formula is:
[0068] FLOPS ava = (1-cpu) ur)*FLOPS;
[0069] Among them, FLOPS ava This represents the available computing power of an edge node; FLOPS represents the computing power of the edge node itself; and CPU... ur This indicates the current CPU utilization of the edge node.
[0070] It should be noted that the available computing power (FLOPS) of the edge nodes... ava All of it can be used for federal learning tasks.
[0071] Optionally, the computing power of the edge node itself includes: the floating-point computing power of the edge node per second; the method further includes:
[0072] The edge node determines its floating-point computing power (FLOPS) per second according to a second formula; wherein the second formula is:
[0073] FLOPS = X * CPU K *ε
[0074] Where X represents the number of cores on the edge node; CPU K ε represents the clock speed of a single core; ε represents the number of floating-point calculations per CPU cycle.
[0075] In at least one embodiment of the present invention, the edge node determines the maximum number of trainable layers of the first model that its available computing power can support based on the number of computations required for each layer in the first model, including:
[0076] The edge node determines, according to a third formula, the maximum number of trainable layers of the first model that its available computing power can support; wherein, the third formula is:
[0077]
[0078] Among them, FLOPS ava Indicates the available computing power of the edge node; size bat Indicates the size of the training batch; cal i t represents the number of computations required for the i-th layer; t represents the training latency; the maximum i-th value satisfying the third formula is the maximum number of trainable layers.
[0079] In at least one embodiment of this application, step 102 includes:
[0080] The edge node calculates the amount of data transmitted from the edge node to the cloud node; for example, the edge node calculates the amount of data transmitted from the edge node to the cloud node according to the above model partitioning scheme.
[0081] The edge node determines the bandwidth required to transmit the amount of data based on the deterministic delay.
[0082] The edge node allocates and reserves bandwidth resources based on the current network resources and the determined bandwidth size;
[0083] The edge nodes utilize the allocated resources to instantiate and orchestrate virtual network functions and interfaces within the network slice, thereby completing slice creation.
[0084] Furthermore, after allocating and reserving bandwidth resources for the edge node based on current network resources and a determined bandwidth size, the method further includes:
[0085] Without affecting the performance of other slices, the edge node is configured with shared resources, which are used to transmit information other than model parameters.
[0086] In summary, this invention addresses the synchronization and accuracy issues in edge model training by proposing a federated learning training method based on deterministic networks, and designs model segmentation and network slicing schemes based on this method. Its advantages are: to improve model training accuracy, a computationally efficient model segmentation scheme is proposed, and a deterministic network slicing scheme is proposed based on deterministic latency; then, a federated learning architecture is used to complete global model training. Compared with traditional edge training methods, this invention has the following advantages:
[0087] a) The model is highly adaptable and supports training on heterogeneous data;
[0088] b) Improved the accuracy of distributed models, expanded the amount of data used through federated learning, and ensured the synchronization of training through deterministic networks, thereby increasing the upper limit of model training.
[0089] c) It alleviates the computational pressure of edge training by offloading the training task through model segmentation, thereby reducing the training pressure on the edge side.
[0090] To better understand the embodiments of the present invention, the present invention will be further described in detail below with reference to examples. Unless otherwise specified, the experimental methods described in the following examples can be conventional methods.
[0091] Example 1: The edge-cloud collaborative system based on deterministic networks includes: 1 cloud node O1 and 5 edge nodes U1, U2, U3, U4 and U5.
[0092] The cloud nodes are equipped with 10 Tesla P100 supercomputing graphics cards, and each edge node is equipped with an Intel Xeon E7-8837 processor with 8 CPUs, a clock speed of 2.66GHz, and 4 floating-point operations per cycle. The edge dataset consists of 32*32 image data.
[0093] Step 1: Deploy edge nodes and cloud nodes according to the specific business needs in the IoT application scenario;
[0094] Step 2: First, deploy the KubeFATE architecture on the divided edge nodes and cloud nodes based on docker-compose, and then deploy the deep learning environment - Tensorflow;
[0095] Step 3: After deployment is completed, the five edge nodes determine the neural network model architecture used by the edge node through voting and other methods. The voting results are shown in Table 1.
[0096] Table 1: Edge Node Voting Results
[0097] VGG-16LeNet-5AlexNetU1√××U2××√U3×√×U4√××U5√×× surface
[0098] Step 4: The cloud node sends the deep learning model VGG-16, training latency (4s), transmission latency (1s), and training batch (32) to the edge node, and the edge node completes the deployment of the VGG-16 model.
[0099] Step 5: Calculate the floating-point computing power per second (FLOPS) of the edge nodes based on their configuration to express their computing power (FLOPS).
[0100] FLOPS=8*2.66G*4=85.12gflops.
[0101] Step 6: After each edge node determines the neural network model it uses, it calculates the number of trainable model layers based on its own computing power and the actual network situation of the current edge node. The current computing power is shown in Table 2, the computing requirements of each layer of VGG-16 are shown in Table 3, and the maximum number of trainable model layers is shown in Table 4.
[0102] Table 2: Computing Power of Edge Nodes
[0103] Total computing power, used computing power, available computing power: U185.1237.6547.47, U285.1264.820.32, U385.1253.7531.37, U485.1245.2739.85, U585.1227.1757.95 surface
[0104] Table 3: Parameters of each layer in VGG-16 and the number of operations required to transmit that layer
[0105] Layer architecture parameter count and number of operations: 1 conv3-641,7283.6×10 6 2conv3-6436,8647.5×10 7 3conv3-12873,7287.5×10 7 4conv3-128147,4567.5×10 7 5conv3-256294,9127.5×10 7 6conv3-256589,8247.5×10 7 7conv3-256589,8247.5×10 7 8conv3-5121,179,6487.5×10 7 9conv3-5122,359,2967.5×10 7 10conv3-5122,359,2967.5×10 7 11conv3-5122,359,2961.8×10 7 12conv3-5122,359,2961.8×10 7 13conv3-5122,359,2961.8×10 7 14FC1102,760,4482.0×10 8 15FC216,777,2163.3×10 7 16FC34,096,0008×10 6 surface
[0106] Step 7: During model training, edge nodes simultaneously employ network slicing technology, slicing based on the number of edge training layers and transmission latency. The required slice bandwidth is shown in Table 4.
[0107] Table 4: Slice bandwidth required for transmission
[0108]
[0109]
[0110] Step 8: After each edge node completes its model training (e.g., U1 trains 6 layers, U2 trains 3 layers), it uploads the model parameters using the reserved bandwidth. The cloud node then completes the subsequent model layer training.
[0111] Step 9: After the training of each neural network model is completed, the edge nodes and cloud nodes update the edge model through the backpropagation algorithm;
[0112] Step 10: After multiple rounds (e.g., 5 rounds) of fixed training, the edge nodes upload the edge models (∑1, ∑2, ∑3, ∑4, ∑5) to the cloud nodes. The cloud nodes use a federated aggregation algorithm to aggregate and generate the global model ∑. g ;like:
[0113]
[0114] Step 11: Then the cloud node will ∑ the global model g The data is distributed to edge nodes, which are based on ∑ g Update the local model;
[0115] Step 12: Iterate through steps 6-11 at the edge nodes until the training epochs reach 200 or the model accuracy reaches 95%.
[0116] In summary, the edge-cloud collaborative system based on deterministic networks provided in this embodiment of the invention is used for machine model training of multiple edge nodes in the Internet of Things. The deterministic network ensures the synchronization of training, the edge-cloud system solves the problem of insufficient computing power of edge nodes and reduces the training pressure on edge nodes, and federated learning ensures the number of training sessions and improves the accuracy of model training.
[0117] As shown in Figure 2, this embodiment of the invention also provides an edge-cloud collaborative system based on a deterministic network, the edge-cloud collaborative system comprising:
[0118] A cloud node and multiple edge nodes; wherein the transmission from the edge nodes to the cloud node satisfies deterministic latency;
[0119] The edge nodes are used to: determine the maximum number of trainable layers that the edge node can support for the first model after determining the first model to be used; determine the required slice bandwidth for each edge node and reserve bandwidth resources based on the maximum number of trainable layers and the deterministic latency; train based on the first model, and send the trained model parameters to the cloud node through the reserved bandwidth resources after training is completed; for example, each edge node determines the first model to be used through voting.
[0120] The cloud nodes are used to: complete subsequent model layer training based on the model parameters obtained from edge node training, and update the edge models through backpropagation algorithm; further, use federated aggregation algorithm to aggregate the edge models corresponding to each edge node to generate a global model, and send the global model to the edge nodes.
[0121] Furthermore, in this embodiment of the invention, the edge node is also used to: train based on the global model until the training epochs reach a first value or the model accuracy reaches a second value. For example, the edge node is trained based on the global model until the training epochs reach 200 or the model accuracy reaches 95%.
[0122] In at least one embodiment of the present invention, the edge node is further used for:
[0123] Calculate the available computing power of the edge node based on its own computing power and current CPU utilization.
[0124] Based on the number of computations required for each layer in the first model, determine the maximum number of trainable layers of the first model that the available computing power of the edge node can support.
[0125] In this embodiment of the invention, the edge node obtains a model partitioning scheme based on computing power, according to the maximum number of trainable layers of the first model that its available computing power can support. It should be noted that if the maximum number of trainable layers of the first model that the edge node's available computing power can support is less than 1, the edge node exits the current model training and waits for the next training iteration.
[0126] As an optional embodiment, the edge node calculates its available computing power based on its own computing capabilities and current CPU utilization, including:
[0127] The edge node calculates its available computing power (FLOPS) according to the first formula. ava The first formula is:
[0128] FLOPS ava = (1-cpu) ur )*FLOPS;
[0129] Among them, FLOPS ava This represents the available computing power of an edge node; FLOPS represents the computing power of the edge node itself; and CPU... ur This indicates the current CPU utilization of the edge node.
[0130] It should be noted that the available computing power (FLOPS) of the edge nodes... ava All of it can be used for federal learning tasks.
[0131] Optionally, the computing power of the edge node itself includes: the floating-point computing power of the edge node per second; the method further includes:
[0132] The edge node determines its floating-point computing power (FLOPS) per second according to a second formula; wherein the second formula is:
[0133] FLOPS = X * CPU K *ε
[0134] Where X represents the number of cores on the edge node; CPU K ε represents the clock speed of a single core; ε represents the number of floating-point calculations per CPU cycle.
[0135] In at least one embodiment of the present invention, the edge node determines the maximum number of trainable layers of the first model that its available computing power can support based on the number of computations required for each layer in the first model, including:
[0136] The edge node determines, according to a third formula, the maximum number of trainable layers of the first model that its available computing power can support; wherein, the third formula is:
[0137]
[0138] Among them, FLOPS ava Indicates the available computing power of the edge node; size bat Indicates the size of the training batch; cal i t represents the number of computations required for the i-th layer; t represents the training latency; the maximum i-th value satisfying the third formula is the maximum number of trainable layers.
[0139] In at least one embodiment of this application, the edge node is further used for:
[0140] Calculate the amount of data transmitted from the edge node to the cloud node; for example, the edge node calculates the amount of data transmitted from the edge node to the cloud node according to the above model partitioning scheme;
[0141] Based on the deterministic delay, determine the bandwidth required to transmit the amount of data;
[0142] Based on the current network resources and the determined bandwidth size, allocate and reserve bandwidth resources for the edge nodes;
[0143] Using the allocated resources, the virtual network functions and interfaces in the network slice are instantiated and services are orchestrated to complete the slice creation.
[0144] Furthermore, after allocating and reserving bandwidth resources for the edge node based on current network resources and a determined bandwidth size, the method further includes:
[0145] Without affecting the performance of other slices, the edge node is configured with shared resources, which are used to transmit information other than model parameters.
[0146] In summary, this invention addresses the synchronization and accuracy issues in edge model training by proposing a federated learning training method based on deterministic networks, and designs model segmentation and network slicing schemes based on this method. Its advantages are: to improve model training accuracy, a computationally efficient model segmentation scheme is proposed, and a deterministic network slicing scheme is proposed based on deterministic latency; then, a federated learning architecture is used to complete global model training. Compared with traditional edge training methods, this invention has the following advantages: it has strong adaptability to models, supporting training on heterogeneous data; it improves the accuracy of distributed models by expanding data usage through federated learning and ensuring training synchronization through deterministic networks, thereby increasing the upper limit of model training; and it alleviates the computational pressure of edge training by offloading the training task through model segmentation, reducing the training pressure on the edge side.
[0147] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-readable storage media (including, but not limited to, disk storage and optical storage) containing computer-usable program code.
[0148] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in one or more blocks and / or blocks of the flowchart.
[0149] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce a paper article including instruction means that implement the functions specified in one or more flowcharts and / or one or more block diagrams.
[0150] These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause the computer or other programmable apparatus to perform a series of operational steps to produce a computer-implemented process, thereby providing steps for implementing the functions specified in one or more flowcharts and / or one or more block diagrams.
[0151] The above description represents the preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A model training method for edge computing, characterized in that, An edge-cloud collaborative system based on deterministic networks is proposed, comprising a cloud node and multiple edge nodes, wherein the transmission from the edge nodes to the cloud node satisfies deterministic latency. The method includes: each edge node determining a first model to be used, and based on its own computing power, determining the maximum number of trainable layers of the first model that the edge node can support; each edge node determining the required slice bandwidth and reserving bandwidth resources based on the maximum trainable layers and the deterministic latency; each edge node training based on the first model, and after training, sending the trained model parameters to the cloud node through the reserved bandwidth resources, whereby the cloud node completes subsequent model layer training and updates the edge model using a backpropagation algorithm; and the cloud node aggregating the edge nodes using a federated aggregation algorithm. For each edge model corresponding to a given point, a global model is generated and sent to the edge node. The edge node determines the maximum number of trainable layers it can support for the first model based on its own computing power information, including: calculating its available computing power based on its own computing capabilities and current CPU utilization; determining the maximum number of trainable layers based on the number of computations required for each layer in the first model; and further determining the maximum number of trainable layers based on the edge node's available computing power according to a third formula. in, Indicates the available computing power of the edge nodes; Indicates the size of the training batch; t represents the number of computations required for the i-th layer; t represents the training latency; the maximum i-th value satisfying the third formula is the maximum number of trainable layers.
2. The method according to claim 1, characterized in that, The method further includes: the edge nodes are trained based on the global model until the training rounds reach a first value or the model accuracy reaches a second value.
3. The method according to claim 1, characterized in that, If the maximum number of trainable layers of the first model that the available computing power of the edge node can support is less than 1, then the edge node will exit the current model training.
4. The method according to claim 1, characterized in that, The edge node calculates its available computing power based on its own computing capabilities and current CPU utilization, including: the edge node calculating its available computing power according to a first formula. The first formula is: (1- ) ;in, This represents the available computing power of the edge nodes. This represents the computing power of the edge node itself. This indicates the current CPU utilization of the edge node.
5. The method according to claim 1 or 4, characterized in that, The computing power of the edge node itself includes: the floating-point computing power of the edge node per second; the method further includes: the edge node determining its floating-point computing power per second according to a second formula. The second formula is: Where X represents the number of cores mounted on the edge node; Indicates the clock speed of a single core; This indicates the number of floating-point calculations performed by the CPU per cycle.
6. The method according to claim 1, characterized in that, The edge nodes determine the required slice bandwidth for each edge node and reserve bandwidth resources based on the maximum trainable layers and the deterministic latency. This includes: the edge nodes calculating the amount of data transmitted from the edge nodes to the cloud nodes; the edge nodes determining the bandwidth required to transmit the data based on the deterministic latency; the edge nodes allocating and reserving bandwidth resources for the edge nodes based on the current network resources and the determined bandwidth; and the edge nodes using the allocated resources to instantiate and orchestrate virtual network functions and interfaces in the network slice, thereby completing slice creation.
7. The method according to claim 6, characterized in that, After allocating and reserving bandwidth resources for the edge node based on the current network resources and the determined bandwidth size, the method further includes: configuring shared resources for the edge node without affecting the performance of other slices, wherein the shared resources are used to transmit information other than model parameters.
8. An edge-cloud collaborative system based on deterministic networks, characterized in that, The edge-cloud collaborative system includes: one cloud node and multiple edge nodes; wherein the transmission from the edge node to the cloud node satisfies deterministic latency; the edge node is used to: after determining the first model to be used, determine the maximum number of trainable layers that the edge node can support for the first model based on its own computing power information; and determine the required slice bandwidth for each edge node and reserve bandwidth resources based on the maximum number of trainable layers and the deterministic latency; train based on the first model, and send the trained model parameters to the cloud node through the reserved bandwidth resources after training is completed; the cloud node is used to: complete subsequent tasks based on the model parameters trained by the edge node. The model layer is trained, and the edge models are updated using the backpropagation algorithm. Further, a federated aggregation algorithm is used to aggregate the edge models corresponding to each edge node, generating a global model, which is then sent to the edge nodes. The edge nodes are further configured to: calculate their available computing power based on their own computing capabilities and current CPU utilization; determine the maximum number of trainable layers of the first model that their available computing power can support based on the number of computations required for each layer in the first model; and determine the maximum number of trainable layers of the first model that their available computing power can support based on a third formula. The third formula is: in, Indicates the available computing power of the edge nodes; Indicates the size of the training batch; t represents the number of computations required for the i-th layer; t represents the training latency; the maximum i-th value satisfying the third formula is the maximum number of trainable layers.
9. The edge-cloud collaborative system according to claim 8, characterized in that, The edge nodes are also used for: training based on the global model until the training rounds reach a first value or the model accuracy reaches a second value.
10. The edge-cloud collaborative system according to claim 8, characterized in that, The edge node is also used to: calculate the amount of data transmitted from the edge node to the cloud node; determine the bandwidth required to transmit the amount of data based on the deterministic latency; and allocate and reserve bandwidth resources for the edge node based on the current network resources and the determined bandwidth. Using the allocated resources, the virtual network functions and interfaces in the network slice are instantiated and services are orchestrated to complete the slice creation.
Citation Information
Patent Citations
Method and equipment for allocating cloud resources to network slices
CN113438678A
Layered federal learning method for edge aggregation interval adaptive control, computer equipment and storage medium
CN113469325A
Resource reservation method and device, terminal and node equipment
CN113810442A