A communication network field maintenance model migration method based on delay optimization
By adopting a model migration method based on service demand similarity and delay optimization in on-site maintenance of the communication network, the problems of service demand differences and computing resource limitations during model migration are solved, and efficient and accurate model migration and task completion are achieved.
Patent Information
- Application Number
- CN202210399528.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-15
- Publication Date
- 2025-04-04
- Estimated Expiration
- 2042-04-15
AI Technical Summary
In on-site maintenance of communication networks, due to differences in service requirements and computing resource limitations during model migration, the migration accuracy and task duration are delayed. The existing technology has failed to effectively solve these problems.
The model migration method based on service demand similarity and delay optimization is adopted. By calculating type similarity, name similarity and interpretation information similarity, selecting the appropriate migration method, and using a multi-priority queue model and an improved discrete particle swarm algorithm, task offloading and model migration are optimized.
It realizes the efficiency and accuracy of model migration, reduces the task completion delay, improves the task completion rate, and is suitable for on-site maintenance scenarios of communication networks.
Smart Images

Figure CN114742166B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of communication network field maintenance, and in particular to a communication network field maintenance model migration method based on delay optimization. Background Art
[0002] As the communication network continues to expand and its structure becomes increasingly complex, the problems of heavy workload, many management problems, and lack of automated support tools in the field maintenance of the communication network are becoming increasingly prominent. In response to these problems, the field maintenance system of the communication network has also begun to adopt a mobile edge computing architecture to improve the quality and efficiency of the field maintenance of the communication network. In this scenario, the models used in the field maintenance of the communication network are trained by different edge nodes, and the models are relatively independent. However, the smart terminal devices (such as wearable devices, inspection drones, and inspection robots) connected to the edge nodes in the field maintenance of the communication network are all mobile, which causes the edge nodes they can access to change. However, these image recognition and fault diagnosis models are not deployed to all edge nodes, and it is difficult to directly migrate the models to other edge nodes for use. If the trained models are directly migrated, the model migration accuracy may be too poor or even unusable. In addition, when migrating models on edge nodes, model training will be involved, which will consume a lot of computing resources, and the execution of model migration will affect the execution of normal maintenance tasks.
[0003] In order to solve the above problems, there are some model migration methods in the prior art, such as:
[0004] Technical Solution 1: CN202111206993.4 proposes a model migration method and device, which includes: obtaining a target model, a validation data set, and a parameter fine-tuning data set; performing knowledge distillation on the target model to obtain a migration model, and in the process of performing the knowledge distillation on the target model, optimizing the migration model according to the validation data set and the error function corresponding to the knowledge distillation; using the parameter fine-tuning data set to perform self-supervised training on the migration model to fine-tune the parameters of the migration model. The above technical means are used to solve the problem of the lack of robot model migration methods in the prior art.
[0005] Technical Solution 2: CN202110510119.3 proposes a model migration method and device, wherein the model is a scoring card model, and the method includes: based on a first training sample of the source scene and a sample label corresponding to the first training sample data, training a first machine learning model corresponding to the source scene; obtaining a second unlabeled training sample of the target scene; wherein the second training sample has the same feature space as the first training sample; based on adjusting the feature distribution of the second training sample to approximate the feature distribution of the first training sample, calibrating the trained model parameters of the first machine learning model to obtain a second machine learning model after the model parameters are calibrated to complete the model migration.
[0006] Technical Solution 3: CN202010219449.2 proposes a model migration training method, device, equipment and storage medium, which relates to the field of artificial intelligence. The specific implementation scheme is: using the network parameters of at least two migration layers in the source model as the initial parameters of the associated migration layer in the target model; constructing an objective function based on the distance between the training parameters associated with the at least two migration layers and the initial parameters; based on the objective function, training the target model including the initial parameters. Finally, the inheritance of the source model's information and the adaptation of the target model are achieved, avoiding the overfitting phenomenon in the model migration training process and improving the generalization ability of the target model.
[0007] In the existing model migration methods, Technical Solution 1 obtains the migration model by performing knowledge distillation on the target model, and uses the data set to fine-tune the model, but the knowledge distillation method has relatively harsh application conditions and is relatively sensitive to parameters. Technical Solution 2 calibrates the trained model parameters of the first machine learning model to obtain the second machine learning model after the model parameters are calibrated, thereby completing the model migration, but this technical solution mainly considers the distribution of sample data, and does not study the service requirements of the source model and the destination model. Technical Solution 3 introduces the distance between the training parameters of the migration layer and the initial parameters, thereby taking into account the model migration and training of each migration layer during the model training process, but only focuses on the relationship between the parameters, and does not study the service requirements of the source model and the destination model. In addition, Technical Solutions 1, 2, and 3 do not consider the impact of model migration on the execution of ordinary maintenance tasks in the on-site maintenance scenario of the communication network, and their solutions are not suitable for the on-site maintenance scenario of the communication network. Summary of the invention
[0008] In response to the above technical problems, the present invention provides a model migration method suitable for on-site maintenance of communication networks based on service demand similarity and delay optimization. It comprehensively considers migration tasks and maintenance tasks, can efficiently complete model migration, effectively reduce task completion delay, and ensure task completion rate.
[0009] In order to achieve the above object, the present invention provides the following technical solutions:
[0010] A method for migrating a communication network field maintenance model based on delay optimization comprises the following steps:
[0011] S1. Similarity-based service demand analysis calculates type similarity, name similarity and explanation information similarity respectively, and finally calculates the comprehensive similarity according to the weight of each similarity;
[0012] S2. Use service demand similarity to measure the relevance of the model, and select the migration method in different situations according to the service demand similarity; when the service demand of the new model is exactly the same as the service demand of the model to be migrated, directly migrate the model; when the service demand of the new model is similar to the service demand of the model to be migrated, freeze the backbone network; when the service demand of the new model is less similar to the service demand of the model to be migrated, use multi-stage transfer learning to migrate the model;
[0013] S3. Considering multiple indicators such as task delay, edge node resources, and task resource requirements, a multi-priority queue model and an improved discrete particle swarm algorithm are used to complete migration tasks and maintenance task offloading in the on-site maintenance scenario of the communication network, thereby minimizing task delay.
[0014] Furthermore, the calculation method of the type similarity in step S1 is: classify and label different data feature spaces, assuming that the source model RC and the target model TC are model types, the type similarity is as follows:
[0015]
[0016] If the data feature spaces of the source model and the target model are the same, the type similarity is 1, otherwise, the type similarity is 0.
[0017] Furthermore, the method for calculating the name similarity in step S1 is:
[0018] First, calculate the name vector according to formula (2):
[0019]
[0020] Among them, name_vec is the name vector, vec i is the i-th word vector in the name;
[0021] Secondly, the similarity between the two name vectors is calculated according to formula (3):
[0022]
[0023] Among them, Sim nameis the name similarity, name_vec1 is the first name vector, and name_vec2 is the second name vector.
[0024] Furthermore, the calculation method of the similarity of the explanation information in step S1 is: first, use the BiLSTM-CRF algorithm to perform word segmentation analysis on the explanation information according to the characteristics of the on-site maintenance of the communication network, classify the text by the trained model, judge the influence of the entity type on the model similarity, extract the text with greater influence for similarity calculation, and then calculate the similarity of words of the same type.
[0025] Furthermore, step S1 extracts the text of equipment components and faults for similarity calculation. The method is: the interpretation information of the two models is parsed to obtain the equipment component set and fault set of the two model interpretation information. The service requirement S1 parses m equipment component information, which is E1={e 11 , e 12 , ..., e 1m}, and p pieces of fault information, which is F1 = {f 11 , f 12 , ..., f 1p}; Service S2 parses out n equipment component information, which is E2 = {e 21 , e 22 , ..., e 2n}, and q fault information, which is F2 = {f 21 , f 22 , ..., f 2q};
[0026] According to formula (4), the similarity matrix of E1 and E2 is calculated:
[0027]
[0028] According to formula (4), the matrix is traversed to obtain the maximum value of each column, and the maximum value set P = {p1, p2, ..., p l}, where l = min(m, n);
[0029] Calculate the device component similarity S according to formula (5) e :
[0030]
[0031] The similarity matrix of F1 and F2 is calculated according to formula (6), where each item is the similarity of two fault information:
[0032]
[0033] According to formula (6), we traverse the matrix and take the maximum value of each column to obtain the maximum value set Q{q1, q2, ..., q k}, where k = min(p, q);
[0034] According to formula (7), the fault similarity S is calculated f :
[0035]
[0036] Combining the equipment component similarity and fault similarity, the explanation information similarity is obtained according to formula (8):
[0037] Sim explain =ω1S e +ω2S f (8)
[0038] In formula (8), S explain To explain the information similarity, S e is the similarity of equipment components, S f is the fault similarity; ω1, ω2 are weight coefficients, and ω1+ω2=1.
[0039] Furthermore, the technical method for calculating the comprehensive similarity in step S1 is: on the basis of the type similarity being 1, the comprehensive similarity is calculated according to formula (9):
[0040] S=Sim category (ω1·Sim name +ω2·Sim explain ) (9)
[0041] In formula (9), ω1 and ω2 are the weights of name similarity and explanation information similarity, respectively, satisfying ω1+ω2=1.
[0042] Furthermore, the multi-priority queue model in step S3 includes three queues, namely, an F heap, an M first-in-first-out queue, and an S first-in-first-out queue; first, tasks are divided into three levels according to their importance and task delay sensitivity, P1 being the highest priority task, P2 being the medium priority task, and P3 being the task with lower delay requirements; then tasks of level P1 are added to the F heap, tasks of level P2 are added to the M queue, and tasks of level P3 are added to the S queue; F is a large top heap, and the priority is determined according to the task deadline. Each time a task is selected for execution, the task with the highest priority at the top of the heap will be executed. When the top task of the heap does not meet the execution requirements, that is, the task start time is greater than the current time, the first task in the M queue is selected for execution; when a new task is added to the F heap, the priority of the task is calculated and inserted into the heap; if there is a task in the M queue approaching the deadline, it needs to be immediately assigned to the MEC (Mobile Edge Computing) service node for execution, otherwise it will be discarded. At this time, the priority of the task is increased and the task is inserted into the F heap; if there is a task in the S queue approaching the deadline, the priority of the task is increased and inserted into the end of the M queue waiting for execution.
[0043] Furthermore, the improved discrete particle swarm algorithm in step S3 is:
[0044] First, n subpopulations are set, each of which has m particles. In each subpopulation, there are two types of particles, exploration type and navigation type. In each iteration, the algorithm updates the position and velocity of each particle. In the i-th iteration, the velocity of the d-th dimension of the k-th particle in the j-th population is updated as:
[0045]
[0046] In formula (27), ω is the inertia coefficient of the particle, c1 is the dynamic learning factor of the particle, c2 is the subpopulation dynamic learning factor, c3 is the population dynamic learning factor, r1, r2 and r3 are random coefficients; Hewei are the current optimal positions of particles, sub-swarms, and swarms, respectively; type = 1 means that the particle is a navigation particle, considering the optimal solution of the particle and the swarm; type = 2 means that the particle is an exploration particle, considering the optimal solution of the particle and the sub-swarm;
[0047] The change in position is represented by probability, with values of -1, 0, 1. The probability function is:
[0048]
[0049] The velocity value is mapped to the interval [0,1] through the probability function, and the particle position update formula is obtained by using the direction of the particle velocity:
[0050]
[0051] Formula (29) is the position update formula for the kth particle in the dth dimension, and r is a random number on [0,1].
[0052] Furthermore, after the particle swarm algorithm is diversified and discretized, the inertia weight and learning factor are redefined. First, the inertia weight ω adopts a nonlinear decreasing function:
[0053]
[0054] Among them, ω max =0.9,ω min =0.4, when ω changes from 0.9 to 0.4, the algorithm reaches the optimal value, i is the current iteration number, and I is the maximum iteration number;
[0055] In the iterative process, dynamic learning factors are used, the individual learning factor c1 gradually decreases, and the population learning factors c2 and c3 gradually increase. The values of c1, c2 and c3 at the i-th iteration are shown in formulas (31)(32)(33):
[0056]
[0057]
[0058]
[0059] Where i is the current iteration number and I is the total iteration number.
[0060] Furthermore, the method of step S3 is as follows: according to the similarity of service requirements, the MEC service nodes that can be assigned to each migration task are screened; according to the task set, the initial position matrix X and the initial speed matrix V of the particle are obtained; according to the value of each particle in the population, the task is unloaded; each MEC service node is queued using a multi-priority queue model; the fitness of the particle in this iteration is calculated; the historical maximum fitness and the historical maximum fitness position of the particle are updated; the sub-population and global maximum fitness and the maximum fitness position are updated; the inertia weight is updated according to formula (30); the learning factor is updated according to formulas (31), (32), and (33); if the particle is a navigation type, the particle speed is updated according to type1 in formula (27); if the particle is an exploration type, the particle speed is updated according to type2 in formula (27); the probability matrix P is obtained according to the particle speed; the particle position X is updated according to formula (29); and the minimum average delay T is calculated.min , calculate the optimal task allocation vector Repeat until the number of iterations is reached.
[0061] Compared with the prior art, the present invention has the following beneficial effects:
[0062] The communication network field maintenance model migration method based on delay optimization proposed in the present invention designs a model migration strategy according to the service requirements of the source model and the destination model, and minimizes the completion delay of the migration task and the maintenance task.
[0063] First, before model migration, the communication network field maintenance services are pre-screened and type similarity, name similarity, and explanation information similarity are calculated. When calculating the explanation information similarity, the BiLSTM-CRF algorithm is first used to identify the key communication network entity types, and similarity is calculated for specific entity types to reduce the impact of irrelevant information and improve the service matching accuracy. Finally, the comprehensive similarity is calculated based on the weights of each similarity.
[0064] Secondly, for the model migration problem, since some edge nodes have the problem of less collected data, the present invention adopts a transfer learning method. According to the similarity of service requirements, the migration method in different situations is selected, and the model migration is performed by direct migration, freezing the backbone network, and multi-stage migration, respectively, which solves the problem of complex intelligent operation and maintenance environment of the communication network and low migration efficiency.
[0065] Finally, since the communication network maintenance tasks are complex and some tasks are urgent, the present invention simultaneously considers the unloading of migration tasks and maintenance tasks, fully considers multiple indicators such as task delay, edge node resources, and task resource requirements, and uses an improved discrete particle swarm algorithm to complete the unloading of migration tasks and maintenance tasks in the communication network on-site maintenance scenario, thereby minimizing task delay and improving task completion efficiency.
[0066] In addition, the present invention conducts simulation experiments on the proposed service demand similarity model, the migration strategy based on the service demand similarity model, and the task offloading strategy that minimizes delay. The simulation results show that the model migration strategy based on service demand similarity can reduce the blindness of model migration, alleviate the problem of limited on-site maintenance data of the communication network, and realize efficient model migration according to service requirements. At the same time, the task offloading algorithm that minimizes delay can ensure that the migration task and the maintenance task are executed efficiently at the same time, effectively reducing the maintenance task completion delay while completing the model migration, and improving the task completion rate. BRIEF DESCRIPTION OF THE DRAWINGS
[0067] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present invention. For ordinary technicians in this field, other drawings can also be obtained based on these drawings.
[0068] Figure 1 A communication network field maintenance system model provided by an embodiment of the present invention.
[0069] Figure 2 A comparison chart of the multi-stage migration effects provided by an embodiment of the present invention.
[0070] Figure 3 The waiting delays of different algorithm tasks provided in the embodiments of the present invention.
[0071] Figure 4 The embodiment of the present invention provides an effect of the number of migration tasks on the total completion time of a maintenance task.
[0072] Figure 5 The embodiment of the present invention provides an influence of the number of migration tasks on the task completion rate of maintenance tasks.
[0073] Figure 6 The embodiment of the present invention provides an effect of the number of migration tasks on the average completion time of the migration tasks. DETAILED DESCRIPTION
[0074] In order to enable those skilled in the art to better understand the technical solution of the present invention, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments.
[0075] The present invention designs a model migration strategy based on the service requirements of the source model and the destination model in the on-site maintenance scenario of the communication network, and establishes a model migration method suitable for on-site maintenance of the communication network around the problem of minimizing the completion delay of the migration task and the maintenance task. The steps of the model migration method are as follows:
[0076] 1. Service demand analysis based on similarity
[0077] In order to avoid the resource burden and cost overhead caused by frequent model migration in the field maintenance of the communication network, the present invention designs a service demand similarity analysis method in the field maintenance scenario of the communication network, aiming to select MEC service nodes with similar service requirements for the trained model for migration, reduce the blindness of migration, and improve migration efficiency. The service demand analysis based on similarity calculates the type similarity, name similarity, and explanation information similarity respectively, and finally calculates the comprehensive similarity according to the weight of each similarity.
[0078] (1) Type similarity
[0079] During the on-site maintenance of the communication network, the data feature spaces of different models are diverse, including image data, voice data, text data, and so on. When the feature spaces of the source domain and the target domain are the same, for example, when both are images, it is isomorphic transfer learning, otherwise it is heterogeneous transfer learning. Since the heterogeneous transfer learning process is complex and relies too much on prior knowledge, only isomorphic transfer learning is focused on. Based on the above, in the on-site maintenance scenario of the communication network, different data feature spaces are classified and labeled, for example, image data is 1, voice data is 2, and text data is 3. Since only isomorphic transfer learning is considered, the data feature space types of the source model and the target model must match completely before migration can be performed. Assuming that the source model RC and the target model TC are model types, the type similarity is as follows:
[0080]
[0081] If the data feature spaces of the source model and the target model are the same, the type similarity is 1, otherwise, the type similarity is 0.
[0082] (2) Name similarity
[0083] The name information of the communication network field maintenance model is stored in text form. The present invention uses the word2vec method to calculate the word vector, calculates the sentence vector based on the word vector, and then calculates the cosine similarity of the sentence vector to obtain the name similarity. First, the name vector is calculated by formula (2), name_vec is the name vector, vec i is the i-th word vector in the name.
[0084]
[0085] Secondly, calculate the similarity between the two name vectors. name is the name similarity, name_vec is the first name vector, name_vec2 is the second name vector, and the similarity of the two vectors is calculated according to formula (3), which is the name similarity.
[0086]
[0087] (3) Explain information similarity
[0088] The explanation information of the model is described by a paragraph of text, which is an introduction and explanation of the model. In order to improve the pertinence of the similarity of the explanation information, the present invention first uses the BiLSTM-CRF algorithm to perform word segmentation analysis on the explanation information according to the characteristics of the on-site maintenance of the communication network, and then calculates the similarity of words of the same type to improve the accuracy of the calculation.
[0089] Table 1 Communication network field maintenance entity types and their descriptions
[0090]
[0091] As shown in Table 1, the entity types of communication network field maintenance are divided into 9 types. Based on the entity type classification, the present invention uses the BiLSTM-CRF model to train the communication network field maintenance data. When calculating the similarity of the explanation information, the trained model classifies the text. Since many entity types in the explanation information text have little effect on the judgment of model similarity, such as role, time, weather, etc., only the text of equipment components and faults is extracted for similarity calculation.
[0092] According to the above method, the interpretation information of the two models is parsed to obtain the device component set and fault set of the two model interpretation information. The service requirement S1 is parsed to obtain m device component information, which is E1 = {e 11 , w 12 , ..., e 1m}, and p pieces of fault information, which is F1 = {f 11 , f 12 , ..., f 1p Service S2 parses out n pieces of equipment component information, which is E2 = {e 21 , e 22 , ..., e 2n}, and q fault information, which is F2 = {f 21 , f 22 , ..., f 2q}.
[0093] First, the similarity matrix of E1 and E2 is calculated, as shown in formula (4), where each item is the similarity of the information of two device components.
[0094]
[0095] According to formula (4), the matrix is traversed to obtain the maximum value of each column, and the maximum value set P = {p1, p2, ..., p l}, where l = min(m, n). Calculate the similarity S of device components e , S e The larger it is, the greater the similarity.
[0096]
[0097] Similarly, the similarity matrix of F1 and F2 can be calculated according to formula (6), where each item is the similarity of two fault information.
[0098]
[0099] According to formula (6), we traverse the matrix and take the maximum value of each column to obtain the maximum value set Q{q1, q2, ..., q k}, where k = min(p, q). Calculate the fault similarity S f , S f The larger it is, the greater the similarity.
[0100]
[0101] Combining the similarity of equipment components and faults, we can finally get the similarity of explanation information. In formula (8), S explain To explain the information similarity, S e is the similarity of equipment components, S f is the fault similarity. ω1, ω2 are weight coefficients, and ω1+ω2=1.
[0102] Sim explain =ω1S e +ω2S f (8)
[0103] (4) Comprehensive similarity
[0104] Type similarity ensures that the data feature space of the source model and the target model are isomorphic resources, and the model can be migrated. Name similarity and explanation information similarity ensure that the service requirements of the source model and the target model are similar. Therefore, when evaluating the comprehensive similarity of service requirements, it is necessary to comprehensively consider the influence of name similarity and explanation information similarity on the basis of type similarity being 1. The final comprehensive similarity is:
[0105] S=Sim category (ω1·Sim name +ω2·Sim explain ) (9)
[0106] As shown in formula (9), ω1 and ω2 are the weights of name similarity and explanation information similarity, respectively, satisfying ω1+ω2=1.
[0107] 2. Model Migration Strategy Based on Service Demand Similarity
[0108] In view of the similarity-based service demand analysis algorithm designed above, the present invention proposes a model migration strategy based on service demand similarity. In the on-site maintenance scenario of the communication network, MEC service nodes at different locations of the communication network often have the same or similar service requirements. However, the training of large models such as YOLOv3 is very time-consuming and requires a lot of data support. Therefore, after an MEC service node completes the training and deployment of the model, if other MEC service nodes have the same or similar service requirements, the service model can be migrated to other MEC service nodes, thereby reducing the training time of other nodes. Since the size of the training data and the gap in the correlation between the new data and the previous data are directly related to the choice of migration method, the present invention uses service demand similarity to measure the correlation of the model, and selects the migration method in different situations according to the service demand similarity.
[0109] First, when the service requirements of the new model are exactly the same as those of the model to be migrated, the model will be migrated directly without additional training. In this case, the model can be migrated directly from the source MEC service node to the destination MEC service node without additional training.
[0110] Secondly, when the service demand of the new model is similar to that of the model to be migrated, in this case, since the service demand is highly similar, the base model of the source model can be used as a feature extractor of the new model, so that the new model can benefit from the features learned from the source model, and only part of the network needs to be trained to achieve a good detection effect, and the time consumption of model training can be greatly reduced. The specific scheme used by the present invention is to first freeze all convolutional layers in the backbone network of the YOLOv3 model, load the model to be migrated and its weight parameters, and train the model, and only update the parameter values of the unfrozen layers.
[0111] Finally, when the service demand of the new model is poorly similar to the service demand of the model to be migrated, the present invention uses multi-stage transfer learning to migrate the model. In the case of poor similarity in service demand, the present invention considers first using the method of freezing some convolutional layers to extract universal features of the image, prevent overfitting, reduce model training time, and then fine-tune on this basis to improve model accuracy. The specific scheme is that the first step is to freeze the selected number of layers and train the parameters after the frozen layer. The second step is fine-tuning, and all parameters in the network are trained. Different learning rates are used in the two stages, with a larger learning rate in the first stage and a smaller learning rate during fine-tuning.
[0112] 3. Task offloading strategy to minimize latency
[0113] (1) System model
[0114] Figure 1It is a system model for on-site maintenance of the communication network. In the on-site maintenance scenario of the communication network, after obtaining the maintenance task, the operation and maintenance personnel wearing smart wearable devices, inspection drones, and inspection robots will perform maintenance work. The smart terminal device can upload the collected on-site audio and video data to the MEC service node and the cloud center for deep learning model training. After the model training is completed, the MEC service node with similar service requirements can be selected for model migration to complete model reuse. During the working process, the smart terminal device can process tasks in real time through the deployed deep learning model, or it can offload tasks to the MEC service node and the cloud center for processing. Finally, after the maintenance task is completed, the task completion result is updated to the MEC service node and the cloud center to achieve resource synchronization.
[0115] a) Problem Formulation
[0116] Definition 1: T n,m,q The delay in completing the maintenance task. The maintenance task n generated by the intelligent terminal device m offloads the computing task to the MEC service node k through the channel q for processing. The delay of the maintenance task in the on-site maintenance scenario of the communication network includes queuing delay, unloading delay, execution delay and calculation result return delay. Since the downlink propagation speed is very fast and the amount of calculation result data is small, the time to return the calculation result is very short, so this part of the delay will be ignored. Therefore, the delay of the maintenance task can be calculated by the following formula:
[0117]
[0118] Shannon's theorem is used in the calculation of the upload speed of the intelligent terminal device m. The upload speed of the terminal device m for task offloading on the transmission channel q is:
[0119]
[0120] Among them, B q is the bandwidth of channel q, P m,q is the power of data unloading of intelligent terminal device m through channel q, G m,q is the channel gain, is the additive white Gaussian noise power.
[0121] According to V m,q calculate Among them, d n Indicates the data size of task n.
[0122]
[0123] Assume that a MEC service node has multiple channels for terminal devices to offload tasks, each channel serves a smart terminal device, and the computing resources of the MEC service node are shared by the maintenance tasks and migration tasks offloaded to the node.
[0124]
[0125] A n,q,k =1, indicating that maintenance task n is offloading computing units to MEC node k through channel q, A n,q,k =0, which means that channel n is idle. k =1, the migration task is being executed on MEC service node k, A k =0, which means that the migration task is not executed on the current MEC node k. Calculate the number of smart terminal device users served by MEC service node k. n is the computational load of task n.
[0126] Finally, the total delay of the maintenance task is:
[0127]
[0128] Definition 2: T n,k′ The delay of completing the migration task is the time delay of MEC node k′ to offload the migration task to MEC service node k. The delay of the migration task in the communication network field maintenance scenario is related to the queuing delay, transmission delay and execution delay.
[0129]
[0130] Now let's calculate Among them, d n represents the data size of migration task n, V k′,k The data transmission rate of MEC service node k′ is:
[0131]
[0132] The transmission rate from MEC service node k′ to MEC service node k is V k′,k .
[0133] Next we need to calculate The calculation method is the same as that of the maintenance task, but the computing resources of the migration task at the same time are twice that of the maintenance task.
[0134]
[0135] The total latency of the migration task is:
[0136]
[0137] Definition 3: E m,n is the energy consumption of smart terminal device m when executing task n. In the on-site maintenance scenario of the communication network, MEC service nodes usually have enough energy to execute tasks, so the consumption of MEC service node resources is not considered. However, due to the limited energy of smart terminal devices, the energy consumption of smart terminals will be restricted. The energy calculation formula of terminal devices is:
[0138]
[0139] Among them, P m,q The power of the terminal equipment, Transfer time for the task.
[0140] The present invention makes unloading decisions based on the maintenance tasks generated by the above-mentioned communication network field maintenance system model for the intelligent terminal devices and the migration tasks generated by the MEC service nodes, with the goal of minimizing the delay in completing all tasks. Therefore, the optimization goal is:
[0141]
[0142] The constraints are:
[0143] (1) The task must be executed before the tolerance time, otherwise the task will be discarded.
[0144] C1:
[0145] (2) The migration task must select MEC service nodes with similar service requirements for migration. Calculate the current model service requirement s of the migration task model The service demand set S1 = {s1, s2, ..., s i}, if the maximum value meets the threshold, the current MEC service node k can be selected for migration.
[0146] C2:
[0147] (3) MEC service node k can only execute one migration task at a time. n When it is 1, it means that the i-th task is a migration task. n When it is 0, the i-th task is a maintenance task.
[0148] C3:
[0149] (4) An intelligent terminal device can only connect to one channel at a time. qWhen it is 1, it indicates that the intelligent terminal device m is unloading through the channel q.
[0150] C4:
[0151] (5) A channel can only connect to one intelligent terminal device at a time. m,q When it is 1, it indicates that the intelligent terminal device m is unloading through the channel q.
[0152] C5:
[0153] (6) The total energy consumption of the smart terminal over a period of time does not exceed the specified threshold.
[0154] C6:E m ≤E threshold (26)
[0155] (2) Multi-priority queue model
[0156] Using different queuing algorithms for tasks on MEC service nodes will have different effects on task completion delays. Therefore, a multi-priority queue model suitable for on-site maintenance of communication networks needs to be designed. The present invention divides tasks into migration tasks and maintenance tasks. Migration tasks are generated by MEC service nodes, and maintenance tasks are generated by intelligent terminal devices, including inspection image processing tasks, speech recognition tasks, video processing tasks, and the like.
[0157] Due to the complexity of the types of on-site maintenance tasks of the communication network, the present invention divides them into three levels according to the importance of the tasks and the sensitivity of the task delay. P1 is the task with the highest priority, which is the migration task in the present invention, because the completion of the migration task will directly affect the completion of the subsequent maintenance tasks. P2 is a task with medium priority, which has strict delay requirements and needs to be completed as soon as possible, such as image tasks that need to be processed in real time during on-site inspections of on-site maintenance of the communication network. P3 is a task with lower delay requirements, which requires more resources during the processing and has a certain tolerance time, such as video processing tasks during the inspection process. Based on the above, the present invention designs a multi-priority queue model.
[0158] First, the present invention establishes three queues, namely, the F heap, the M first-in-first-out queue, and the S first-in-first-out queue. Tasks of level P1 are added to the F heap, tasks of level P2 are added to the M queue, and tasks of level P3 are added to the S queue. F is a large top heap, and the priority is determined according to the task deadline. Each time a task is selected for execution, the task with the highest priority at the top of the heap will be executed. When the top task does not meet the execution requirements, that is, the task start time is greater than the current time, the first task in the M queue is selected for execution. When a new task is added to the F heap, the priority of the task is calculated and inserted into the heap. If there is a task in the M queue approaching the deadline, it needs to be immediately assigned to the MEC service node for execution, otherwise it will be discarded. At this time, the priority of the task is increased and the task is inserted into the F heap. If there is a task in the S queue approaching the deadline, the priority of the task is increased and inserted into the end of the M queue waiting for execution. In addition, in order to ensure the processing capacity of the edge node, only one migration task can be executed on an MEC service node at the same time. Therefore, when the migration task is executed, the start time of other migration tasks under the same edge node needs to be updated.
[0159] (3) Discrete Particle Swarm Optimization
[0160] The present invention takes minimizing task delay as the optimization goal and solves a d-dimensional vector Make the function The value of is as small as possible, where d is the dimension of the feasible solution space, that is, the number of tasks. The final solution is the MEC service node to which different tasks are assigned.
[0161] In the classic particle swarm algorithm, the speed of particles is calculated according to the same formula. During the iteration process, the diversity of the population is gradually lost, and the range of particle movement is limited, making it difficult to jump out of the local optimal solution. At the same time, the task offloading in the field maintenance scenario of the communication network is discrete, and a discrete particle swarm algorithm is required for calculation. Therefore, the present invention improves the above problems.
[0162] First, set n subpopulations, each of which has m particles. In each subpopulation, there are two types of particles, exploration type and navigation type. In each iteration, the algorithm updates the position and velocity of each particle. In the i-th iteration, the velocity of the d-th dimension of the k-th particle in the j-th population is updated to:
[0163]
[0164] In formula (27), ω is the inertia coefficient of the particle, c1 is the dynamic learning factor of the particle, c2 is the subpopulation dynamic learning factor, c3 is the population dynamic learning factor, and r1, r2 and r3 are random coefficients. Hewei They are the current optimal positions of particles, sub-swarms, and swarms, respectively. Type = 1 means that the particle is a navigation particle, considering the optimal solution of the particle and the swarm. Type = 2 means that the particle is an exploration particle, considering the optimal solution of the particle and the sub-swarm.
[0165] In addition, since the task unloading in the present invention is discrete, the intelligent terminal device and the MEC service node can communicate with multiple MEC service nodes within the communication range. Therefore, a new probability function is designed according to the actual situation, and the probability is used to represent the change in position, with values of -1, 0, and 1. The probability function is:
[0166]
[0167] By mapping the velocity value to the interval [0,1] through the probability function and using the direction of the particle velocity, the particle position update formula can be obtained as:
[0168]
[0169] The above formula is the position update formula for the kth particle in the dth dimension. r is a random number in [0,1].
[0170] After the particle swarm algorithm is diversified and discretized, the present invention redefines the inertia weight and learning factor. First, the inertia weight determines the influence of the particle's previous velocity on this iteration. A nonlinear decreasing function is used. In the early stage of the iteration, ω is larger, which is conducive to global optimization, and in the later stage, ω is smaller, which is conducive to local optimization:
[0171]
[0172] Among them, ω max =0.9,ω min =0.4, when ω increases from 0.9 to 0.4, the algorithm reaches the optimal value, i is the current number of iterations, and I is the maximum number of iterations.
[0173] The learning factor can reflect the information exchange status between populations in the particle swarm algorithm. When the learning factor is always the same value, the influence of individuals and populations on particles will not change. Therefore, the algorithm considers using dynamic learning factors. During the iteration process, the individual learning factor c1 gradually decreases, and the population learning factors c2 and c3 gradually increase, making the particles more diverse in the early iterations and prompting the particles to obtain the optimal solution according to the population optimality in the later iterations.
[0174]
[0175]
[0176]
[0177] The values of c1, c2 and c3 at the i-th iteration are as shown in the formula, where i is the current iteration number and I is the total iteration number.
[0178] Based on the above discrete particle swarm algorithm and multi-priority queue model, the present invention designs a task offloading strategy that minimizes latency. The pseudo code is as follows:
[0179]
[0180]
[0181] In order to evaluate the model migration method proposed in the present invention for field maintenance of communication networks, we conducted the following simulation experiments.
[0182] 1. Model migration strategy based on service demand similarity
[0183] The present invention first verifies the model migration strategy based on the similarity of service requirements. When the service requirements of the two models are relatively similar, the migration will be performed by freezing all the convolutional layers in the backbone network. According to the experimental results of the service requirement analysis based on similarity, the present invention selects a pair of relatively similar requirements for experimentation. The service requirements are both insulator fault diagnosis, and the similarity is above 0.8. Therefore, the present invention uses two different insulator data sets for experimentation. First, the original model is obtained by training according to the insulator data set with a larger data volume. Then, the migration strategy proposed by the present invention is used to migrate the model using the insulator data set with a smaller data volume. The basic model used in the present invention is the YOLOv3 model. Table 2 compares the mAP values of the models under different migration methods. If the original model is used directly for identification, the final mAP can reach 80.2% because the service requirements of the two models are relatively similar. However, the mAP is only 74.7% when the new data set is used for direct training. This is because the data volume is small and the YOLOv3 model structure is relatively complex, and the best training effect cannot be achieved. However, if the strategy proposed in the present invention is adopted, the migration method of freezing the backbone network is adopted, because the features learned from the source model can be benefited, and the model is trained according to the new data set, the final mAP can reach 86.3%.
[0184] Table 2 Comparison of model accuracy under different migration strategies
[0185]
[0186] However, when the service requirements of the two models are not similar, the above method cannot be used. For example, the model to be migrated is a communication network field maintenance target recognition model, and the target model is an insulator fault detection model. If the above migration method is used in this case, the recognition effect of the final target model will be poor due to the large difference between the two model data sets. Therefore, the present invention uses a multi-stage model migration method. To verify the feasibility of the strategy, the simulation uses the YOLOv3 model trained on the COCO training set for migration to complete the identification of insulator faults. Figure 2 As shown, the present invention first compares the migration effects under different numbers of frozen layers, and the number of frozen layers is selected according to the YOLOv3 structure. As the number of frozen layers increases, the amount of training calculations decreases, and the model training time gradually decreases. When the number of frozen layers is 43, the precision and recall of the model reach the highest, reaching more than 88%. When the number of frozen layers is 0, the model accuracy is low because the model has an overfitting problem at this time. When the number of frozen layers is too high, such as 52 layers, the model accuracy gradually decreases because the model features learned in the deep layer of YOLOv3 are no longer universal and cannot be used directly. Therefore, when the service demand similarity of the model is low, the present invention chooses to freeze 43 convolutional layers for multi-stage migration. At this time, the migration strategy is more efficient, which is reflected in the model training speed and model accuracy.
[0187] 2. Task offloading strategy to minimize latency
[0188] In the task offloading strategy simulation with minimal latency, there are 8 wireless access base stations, each of which can serve 4 terminal devices at the same time. The calculation formula of the wireless channel gain in the simulation is G m,q =127+30*logd. Other parameters are shown in Table 3.
[0189] Table 3 Simulation parameters
[0190]
[0191]
[0192] The present invention compares the proposed multi-priority task scheduling model (MPTS) with the first-in first-out queue (FCFS) and the earliest deadline priority queue (EDF). Figure 3As shown, when the amount of tasks is small, the algorithm proposed in the present invention has a smaller gap than other algorithms, because the queue is short at this time and most tasks can be processed quickly. As the number of tasks increases, the FCFS queue is blocked, and the new short tasks will be blocked after the long tasks, resulting in the problem of increased overall queuing delay. For the EDF queue, there are tasks with later deadlines but earlier arrivals in the task queue. Therefore, although the use of the EDF algorithm guarantees the completion rate of the tasks, it is difficult to reduce the average waiting delay, and the EDF queue needs to be queued according to the deadline during the queuing process, and the time complexity is high. The MPTS algorithm proposed in the present invention divides the tasks into three levels, first processes the migration tasks with the highest priority, and considers the arrival time and the latest completion time of tasks at different levels, adjusts the priority of the tasks in time, gives priority to the more urgent small tasks, and then processes the large tasks with higher delay tolerance, which ultimately reduces the task waiting delay.
[0193] Finally, the present invention compares the task offloading strategy that minimizes latency with other algorithms, including the Random Computing Offloading (RCO) algorithm and the Binary Particle Swarm Optimization (BPSO) algorithm. Figure 4 , Figure 5 As shown in the figure, the total completion time and task completion rate of the maintenance tasks of the three algorithms under different numbers of migration tasks are compared. Figure 4 As shown in the figure, as the number of migration tasks increases, the computing resources of the MEC service node required for the migration tasks increase, and the total time to complete the maintenance tasks gradually increases. When there are fewer migration tasks, since the RCO algorithm randomly selects the MEC service node to be unloaded, the time required to complete the maintenance task is higher than that of other algorithms. Since the particle swarm algorithm is used for task unloading, the total time to complete the maintenance task of BPSO and the method proposed in the present invention is shorter. When the number of migration tasks exceeds 4, as the number of migration tasks increases, the algorithm proposed in this article has more advantages than other algorithms. This is because in order to ensure the efficient completion of maintenance tasks, the multi-priority queue proposed in the present invention comprehensively considers the priority and urgency of the tasks for queuing, and only allows the MEC service node to execute one migration task at the same time, and uses the improved discrete particle swarm algorithm to optimize the total completion time of the maintenance task.
[0194] For task completion rate, Figure 5As shown in the figure, as the number of migration tasks increases, the resources of MEC service nodes are limited, and the completion rate of maintenance tasks gradually decreases. Since the method proposed in the present invention takes into account the urgency of the task and the deadline of the task, the task completion rate is higher than that of other algorithms. In summary, the algorithm of the present invention performs task offloading by using a task offloading strategy that minimizes latency, while ensuring the task completion time and task completion rate of maintenance tasks.
[0195] Secondly, the present invention simulates the average completion time of migration tasks under different numbers of migration tasks. Figure 6 As shown in the figure, when the number of migration tasks is small, the average completion time of the migration tasks of the three algorithms is relatively small, because compared with the maintenance task, the migration task is time-consuming and has a higher priority. The occurrence of the migration task has a greater impact on the completion of the maintenance task, while the migration task can be executed smoothly. When the number of migration tasks is less than 12, the algorithm proposed by the present invention is better than the other algorithms. As the number of migration tasks increases, when the number of migration tasks continues to increase, the performance of the BPSO algorithm gradually outperforms the algorithm proposed by the present invention. On the contrary, Figure 5 As shown in the figure, the execution of migration tasks seriously affects the completion rate of the maintenance tasks of the BPSO algorithm. Considering that in the on-site maintenance scenario of the communication network, the training time of the model is relatively long and a large number of migration tasks will not appear in a short time, the algorithm proposed in the present invention still has advantages over other algorithms in completing migration tasks in the on-site maintenance scenario of the communication network.
[0196] The simulation results show that the model migration strategy based on service demand similarity can reduce the blindness of model migration, alleviate the problem of limited data volume of on-site maintenance of the communication network, and realize efficient model migration according to service requirements. At the same time, the task offloading algorithm that minimizes delay can ensure the efficient execution of migration tasks and maintenance tasks at the same time, effectively reducing the delay of maintenance task completion while completing model migration, and improving the task completion rate.
[0197] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for migrating a communication network field maintenance model based on delay optimization, characterized in that: The following steps are involved: S1. Similarity-based service demand analysis calculates type similarity, name similarity and explanation information similarity respectively, and finally calculates the comprehensive similarity according to the weight of each similarity; The calculation method of type similarity is: Different data feature spaces are classified and labeled. Assuming that the source model RC and the target model TC are model types, the type similarity is as follows: If the data feature space of the source model and the target model is the same, the type similarity is 1, otherwise, the type similarity is 0; The name similarity is calculated as: First, calculate the name vector according to formula (2): Among them, name_vec is the name vector, vec i is the i-th word vector in the name; Secondly, the similarity between the two name vectors is calculated according to formula (3): Among them, Sim name is the name similarity, name_vec1 is the first name vector, name_vec2 is the second name vector; The calculation method of explanation information similarity is: First, the BiLSTM-CRF algorithm is used to perform word segmentation analysis on the explanation information according to the characteristics of on-site maintenance of the communication network. The trained model is used to classify the text, determine the impact of entity type on model similarity, extract the text of equipment components and faults for similarity calculation, and then calculate the similarity of words of the same type. The method for extracting the text of equipment components and faults for similarity calculation is: parsing the interpretation information of the two models to obtain the equipment component set and fault set of the two model interpretation information, and parsing the service demand S1 to obtain m equipment component information, which is E1 = {e 11 ,e 12 ,…,e 1m }, and p pieces of fault information, which is F1 = {f 11 ,f 12 ,…,f 1p }; Service S2 parses out n equipment component information, which is E2 = {e 21 ,e 22 ,…,e 2n }, and q fault information, which is F2 = {f 21 ,f 22 ,…,f 2q }; According to formula (4), the similarity matrix of E1 and E2 is calculated: According to formula (4), we traverse the matrix and take the maximum value of each column to obtain the maximum value set P = p1,p2,…,p l }, where l = min(m,n); Calculate the device component similarity S according to formula (5) e : The similarity matrix of F1 and F2 is calculated according to formula (6), where each item is the similarity of two fault information: According to formula (6), we traverse the matrix and take the maximum value of each column to obtain the maximum value set Q = {q1, q2, ..., q k }, where k = min(p,q); According to formula (7), the fault similarity S is calculated f : Combining the equipment component similarity and fault similarity, the explanation information similarity is obtained according to formula (8): Sim explain =ω1S e +ω2S f (8) In formula (8), S explain To explain the information similarity, S e is the similarity of equipment components, S f is the fault similarity; ω1, ω2 are weight coefficients, and ω1+ω2=1; S2. Use service demand similarity to measure the relevance of the model, and select the migration method in different situations according to the service demand similarity; when the service demand of the new model is exactly the same as the service demand of the model to be migrated, directly migrate the model; when the service demand of the new model is similar to the service demand of the model to be migrated, freeze the backbone network; when the service demand of the new model is less similar to the service demand of the model to be migrated, use multi-stage transfer learning to migrate the model; S3. Considering multiple indicators such as task delay, edge node resources, and task resource requirements, a multi-priority queue model and an improved discrete particle swarm algorithm are used to complete migration tasks and maintenance task offloading in the on-site maintenance scenario of the communication network, thereby minimizing task delay.
2. The method for migrating a communication network field maintenance model based on delay optimization according to claim 1, characterized in that: The calculation method of the comprehensive similarity in step S1 is: on the basis of the type similarity being 1, the comprehensive similarity is obtained according to formula (9): S=Sim category (ω1·Sim name +ω2·Sim explain ) (9) In formula (9), ω1 and ω2 are the weights of name similarity and explanation information similarity, respectively, satisfying ω1+ω2=1.
3. The method for migrating a communication network field maintenance model based on delay optimization according to claim 1, characterized in that: The multi-priority queue model in step S3 includes three queues, namely, F heap, M first-in-first-out queue, and S first-in-first-out queue; first, tasks are divided into three levels according to their importance and task delay sensitivity, P1 is the highest priority task, P2 is the medium priority task, and P3 is the task with lower delay requirements; then tasks of level P1 are added to the F heap, tasks of level P2 are added to the M queue, and tasks of level P3 are added to the S queue; F is a large top heap, and the priority is determined according to the task deadline. Each time a task is selected for execution, the task with the highest priority at the top of the heap will be executed. When the top task of the heap does not meet the execution requirements, that is, the task start time is greater than the current time, the first task in the M queue is selected for execution; when a new task is added to the F heap, the priority of the task is calculated and inserted into the heap; if there is a task in the M queue approaching the deadline, it needs to be immediately assigned to the MEC service node for execution, otherwise it will be discarded. At this time, the priority of the task is increased and the task is inserted into the F heap; if there is a task in the S queue approaching the deadline, the priority of the task is increased and inserted into the end of the M queue waiting for execution.
4. The method for migrating a communication network field maintenance model based on delay optimization according to claim 1, characterized in that: The improved discrete particle swarm algorithm in step S3 is: First, n subpopulations are set, each of which has m particles. In each subpopulation, there are two types of particles, exploration type and navigation type. In each iteration, the algorithm updates the position and velocity of each particle. In the i-th iteration, the velocity of the d-th dimension of the k-th particle in the j-th population is updated as: In formula (27), ω is the inertia coefficient of the particle, c1 is the dynamic learning factor of the particle, c2 is the subpopulation dynamic learning factor, c3 is the population dynamic learning factor, r1, r2 and r3 are random coefficients; Hewei are the current optimal positions of particles, sub-swarms, and swarms, respectively; type = 1 means that the particle is a navigation particle, considering the optimal solution of the particle and the swarm; type = 2 means that the particle is an exploration particle, considering the optimal solution of the particle and the sub-swarm; The change in position is represented by probability, with values of -1, 0, 1. The probability function is: The velocity value is mapped to the interval [0,1] through the probability function, and the particle position update formula is obtained by using the direction of the particle velocity: Formula (29) is the position update formula for the kth particle in the dth dimension, and r is a random number on [0,1].
5. The method for migrating a communication network field maintenance model based on delay optimization according to claim 4, characterized in that: After the particle swarm algorithm is diversified and discretized, the inertia weight and learning factor are redefined. First, the inertia weight ω adopts a nonlinear decreasing function: Among them, ω max =0.9,ω min =0.4, when ω changes from 0.9 to 0.4, the algorithm reaches the optimal value, i is the current iteration number, and I is the maximum iteration number; In the iterative process, dynamic learning factors are used, the individual learning factor c1 gradually decreases, and the population learning factors c2 and c3 gradually increase. The values of c1, c2 and c3 at the i-th iteration are shown in formulas (31)(32)(33): Where i is the current iteration number and I is the total iteration number.
6. The method for migrating a communication network field maintenance model based on delay optimization according to claim 5, characterized in that: The method of step S3 is as follows: according to the similarity of service requirements, the MEC service nodes that can be assigned to each migration task are screened; according to the task set, the initial position matrix X and initial speed matrix V of the particle are obtained; according to the value of each particle in the population, the task is unloaded; each MEC service node is queued using a multi-priority queue model; the fitness of this particle in this iteration is calculated; the historical maximum fitness and historical maximum fitness position of the particle are updated; the sub-population and global maximum fitness and maximum fitness position are updated; the inertia weight is updated according to formula (30); the learning factor is updated according to formulas (31), (32), and (33); if the particle is a navigation type, the particle speed is updated according to type1 in formula (27); if the particle is an exploration type, the particle speed is updated according to type2 in formula (27); the probability matrix P is obtained according to the particle speed; the particle position X is updated according to formula (29); and the minimum average delay T is calculated. min , calculate the optimal task allocation vector Repeat until the number of iterations is reached.
Citation Information
Patent Citations
A model transfer training method, device, equipment and storage medium
CN111444958B
Model migration method and device and electronic equipment
CN113222177A
Model migration method and device
CN113635310A
Edge computing task allocation method for real-time online monitoring service of electric power Internet of Things
CN110717300A
Particle swarm-based service migration method in edge computing environment
CN110839075A