Edge computing resource dynamic allocation and energy consumption optimization method in Internet of Vehicles environment
By predicting the movement trajectory of vehicle groups and dynamically selecting computing nodes, monitoring energy consumption and migrating tasks, the problem of frequent vehicle node switching in traditional methods is solved, and efficient allocation of computing resources and energy consumption optimization are achieved.
Patent Information
- Application Number
- CN202511193008.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-25
- Publication Date
- 2025-09-23
- Estimated Expiration
- 2045-08-25
AI Technical Summary
Traditional edge computing methods fail to effectively combine the real-time movement trajectories of vehicle groups for dynamic matching, resulting in vehicles frequently switching nodes or accessing nodes outside the coverage area, causing service interruptions or a sharp increase in latency. At the same time, a dynamic association mechanism between energy consumption and load has not been established, resulting in high energy consumption.
By predicting the future movement trajectory of the vehicle group, dynamically selecting the computing node with the best load information and coverage, monitoring the node energy consumption and migrating tasks to the target node when it exceeds the standard, energy consumption is optimized.
It achieves accurate matching of vehicle group computing resources and service continuity, reduces the energy consumption of edge nodes, and improves the efficiency of computing resource allocation in the Internet of Vehicles environment.
Smart Images

Figure CN120692579A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of vehicle networking technology, and more specifically, relates to a method for dynamic allocation of edge computing resources and energy consumption optimization in a vehicle networking environment. Background Art
[0002] With the rapid development of connected vehicle (IoV) technology, vehicles are increasingly demanding real-time data processing and low-latency communications. Edge computing, a technology that deploys computing resources at the edge of the network, can effectively reduce data transmission latency and improve service response speed, becoming one of the key technologies supporting IoV applications.
[0003] However, traditional methods mostly divide the service range of edge nodes based on fixed areas, and do not dynamically match them with the real-time movement trajectory of the vehicle group. As a result, the vehicle group frequently switches nodes or accesses nodes outside the coverage area during high-speed movement, causing service interruption or a sharp increase in latency. At the same time, edge node resource allocation only focuses on task feasibility, and does not establish a dynamic association mechanism between energy consumption and load.
[0004] Therefore, there is an urgent need for a method that can adapt to the dynamic characteristics of vehicle groups, achieve resource allocation and reduce the energy consumption of edge nodes. Summary of the Invention
[0005] The purpose of this application is to provide a method for dynamic allocation of edge computing resources and energy consumption optimization in a vehicle network environment, so as to realize the allocation of computing resources of vehicle groups and reduce the energy consumption of edge nodes.
[0006] In a first aspect, the present application provides a method for dynamically allocating edge computing resources and optimizing energy consumption in an Internet of Vehicles environment, including:
[0007] Acquire a first vehicle group in a first lane, and predict a first motion trajectory of the first vehicle group in a future preset time period;
[0008] Determining a computing node set corresponding to the first lane in a connected vehicle environment, and determining a target node sequence corresponding to the first motion trajectory based on load information and coverage of each node in the computing node set;
[0009] If the energy consumption value of the first node in the target node sequence exceeds the energy consumption threshold, a migration task of the first node and a target migration node corresponding to the first node are determined, and the migration task is migrated to the target migration node.
[0010] The second aspect of the present application provides a system for dynamic allocation of edge computing resources and energy consumption optimization in an Internet of Vehicles environment, including:
[0011] A prediction module, configured to obtain a first vehicle group in a first lane and predict a first motion trajectory of the first vehicle group in a future preset time period;
[0012] a determination module, configured to determine a computing node set corresponding to the first lane in a connected vehicle environment, and determine a target node sequence corresponding to the first motion trajectory based on load information and coverage of each node in the computing node set;
[0013] A migration module is used to determine the migration task of the first node and the target migration node corresponding to the first node if the energy consumption value of the first node in the target node sequence exceeds the energy consumption threshold, and migrate the migration task to the target migration node.
[0014] The third aspect of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and running on the processor. When the processor executes the computer program, it implements the steps of the above-mentioned method for dynamic allocation of edge computing resources and energy consumption optimization in a vehicle network environment.
[0015] In a fourth aspect of the present application, a computer-readable storage medium is provided, which stores a computer program. When the computer program is executed by a processor, it implements the steps of the above-mentioned method for dynamic allocation of edge computing resources and energy consumption optimization in a vehicle network environment.
[0016] The beneficial effects of the method for dynamic allocation of edge computing resources and energy consumption optimization in a connected vehicle environment provided by this application are:
[0017] First, by predicting the first movement trajectory of the first vehicle group in a preset time period in the future, the accuracy and continuity of the vehicle group matching by the computing node can be improved.
[0018] Second, by determining the target node sequence corresponding to the first motion trajectory based on the load information and coverage of each node in the calculation node set, the vehicle group can always access the optimal node within the coverage range within a preset time period.
[0019] Third, by monitoring the energy consumption value of the node and triggering the migration mechanism after the energy consumption value exceeds the energy consumption threshold, the migration task of the first node and the target migration node are determined, which can optimize the energy consumption of high-energy consumption nodes and reduce the energy consumption of nodes while realizing computing resource allocation. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the embodiments or descriptions of the prior art. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0021] Figure 1 A flowchart of a method for dynamically allocating edge computing resources and optimizing energy consumption in an Internet of Vehicles environment provided by one embodiment of the present application;
[0022] Figure 2 This is a structural block diagram of a system for dynamic allocation of edge computing resources and energy consumption optimization in an Internet of Vehicles environment provided by one embodiment of the present application;
[0023] Figure 3 A schematic block diagram of an electronic device provided in one embodiment of the present application. DETAILED DESCRIPTION
[0024] In the following description, specific details such as specific system structures and techniques are provided for purposes of illustration rather than limitation to facilitate a thorough understanding of the embodiments of the present application. However, it will be apparent to those skilled in the art that the present application may be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to avoid obscuring the description of the present application with unnecessary detail.
[0025] In order to make the purpose, technical solutions and advantages of this application clearer, specific embodiments will be described below with reference to the accompanying drawings.
[0026] Please refer to Figure 1 , Figure 1 A flowchart of a method for dynamically allocating edge computing resources and optimizing energy consumption in an Internet of Vehicles environment is provided in accordance with an embodiment of the present application. The method includes:
[0027] S101: Acquire a first vehicle group in a first lane, and predict a first motion trajectory of the first vehicle group in a future preset time period.
[0028] In this embodiment, the physical lanes currently served by the connected vehicle network can be divided, for example, based on their lane numbers, with each resulting physical lane being designated as a first lane. The lane number is unique identification information pre-set for each physical lane during the road planning process and can be obtained from a pre-stored file related to the physical lanes. The first lane represents a first lane with clear boundaries, functions, and directions corresponding to each physical lane number in the connected vehicle environment.
[0029] In this embodiment, the operation data of each divided physical lane, that is, each vehicle in the first lane in the preset time period, can be obtained in parallel every preset time period. The operation data includes the vehicle's position information, speed and heading angle.
[0030] In this embodiment, a first vehicle group in the first lane can be obtained. The vehicles in the first lane can be clustered based on the operating data of each vehicle in the first lane to obtain clusters. The vehicles corresponding to clusters where the number of each vehicle is greater than or equal to a threshold number can be determined as a first vehicle group. This first vehicle group can be used to represent each vehicle group in the first lane that has similar spatial distances, similar driving speeds, and substantially consistent driving directions, with no significant gaps within the first lane, and a number that reaches a threshold number. The clustering results for the first lane can be updated at preset time intervals, and a new first vehicle group can be determined. The preset time interval and number threshold can be determined based on actual conditions and are not limited by this application.
[0031] In this embodiment, the first vehicle group may include one or more. After obtaining the first vehicle group, the same processing method can be adopted for each first vehicle group, and the first motion trajectory of each first vehicle group in the future preset time period can be predicted based on the operating characteristics of each first vehicle group. The first motion trajectory of the first vehicle group may include the center position coordinates of the first vehicle group at each time step within the preset time period. The first motion trajectory can represent the overall movement path of the first vehicle group in the future preset time period, and can be formed by connecting the center positions of the first vehicle group corresponding to each time step. The time step is used to represent the minimum time unit of division, and is used to split the future preset time period into several continuous and equal-length time segments. The time step can be determined according to actual conditions and is not limited in this application.
[0032] Through the above method, the motion trajectory of the first vehicle group can be accurately predicted, providing an accurate basis in time and space dimensions for the subsequent matching of edge nodes and resource allocation.
[0033] Step S102: Determine the computing node set corresponding to the first lane in the Internet of Vehicles environment, and determine the target node sequence corresponding to the first motion trajectory based on the load information and coverage of each node in the computing node set.
[0034] In this embodiment, the corresponding computing node set of the first lane in the Internet of Vehicles environment can be determined. As an example, a relational database related to lanes and edge nodes in the Internet of Vehicles environment can be called. The database stores the mapping relationship between the identification information of each lane and the corresponding edge computing node. By retrieving the identification information of the first lane, all edge computing nodes that have spatial coverage associations with the lane can be obtained to form a computing node set. Among them, spatial coverage association means that the signal coverage range of the node actually overlaps with the physical section of the first lane, and the length of the overlapping section is not less than the length threshold, so as to ensure that the node can provide stable services to vehicles in the first lane. The length threshold can be determined according to actual conditions and is not limited in this application.
[0035] In this embodiment, after obtaining the set of computing nodes corresponding to the first lane, the load information and coverage range of each node in the set can be collected. The load information can include the node's current CPU (Central Processing Unit) usage, remaining memory capacity, task queue length, and data transmission latency. The coverage range can include the geographic coordinate boundaries covered by the node signal and the corresponding starting and ending mileages on the first lane.
[0036] In this embodiment, after obtaining the load information and coverage of each node in the computational node set, a corresponding target node sequence can be determined based on the first motion trajectory corresponding to the first vehicle group. For each time step in the first motion trajectory, the corresponding position on the first lane can be determined based on the center coordinates of the first vehicle group. Then, for each position, nodes whose coverage includes that mileage position are selected from the computational node set as candidate nodes for that time step.
[0037] In this embodiment, after obtaining the candidate nodes for each time step, the candidate nodes can be screened. As an example, screening conditions can be set, such as the CPU usage rate does not exceed the load rate threshold, the remaining memory capacity is not less than the memory demand corresponding to the first vehicle group, the task queue length does not exceed the queue length threshold, the data transmission delay does not exceed the delay threshold, etc. The candidate nodes that meet all the above screening conditions are determined as valid nodes. If there are multiple valid nodes in a time step, the comprehensive score of each valid node can be calculated. The comprehensive score can be based on indicators such as CPU usage rate, remaining memory capacity, task queue length and data transmission delay, and calculated according to the weight, and the valid node with the highest comprehensive score is selected as the target node for the time step. Among them, the load rate threshold, queue length threshold, delay threshold, etc. can be determined according to actual conditions, and this application does not limit them.
[0038] In this embodiment, after determining the target node of each time step, the target nodes of each time step can be arranged in chronological order to form an initial node sequence. After obtaining the initial node sequence, the initial node sequence can be subjected to a continuity check. Specifically, the coverage range of the target nodes corresponding to two adjacent time steps in the initial node sequence can be determined, and the overlapping distance of the coverage sections corresponding to the two adjacent time steps on the first lane can be determined. If the overlapping distance is not less than the second distance threshold, it means that a smooth switching can be achieved between the two target nodes; if the overlapping distance is less than the second distance threshold and the target nodes corresponding to the two time steps are different, it is further determined whether there is a node in the two target nodes that simultaneously meets the screening conditions corresponding to the first vehicle group in the two time steps. If there is a node that meets the condition, the node that meets the condition can be determined as the target node corresponding to the two time steps. The node sequence formed after continuity check and adjustment is the target node sequence corresponding to the first motion trajectory.
[0039] By determining the set of computing nodes and screening out the target node sequence, it is possible to ensure that the first vehicle group will always have suitable edge computing nodes to provide services for it within a preset time period in the future, and to ensure the continuity and stability of the service, thereby improving the reliability of edge computing resource allocation in the Internet of Vehicles environment.
[0040] Step S103: If the energy consumption value of the first node in the target node sequence exceeds the energy consumption threshold, the migration task of the first node and the target migration node corresponding to the first node are determined, and the migration task is migrated to the target migration node.
[0041] In this embodiment, the energy consumption values of each node in the target node sequence can be monitored in real time. When the energy consumption value of the first node is detected to exceed the energy consumption threshold, the task migration mechanism can be initiated. As an example, the energy consumption value of the first node may include the sum of computing energy consumption, data transmission energy consumption, and device standby energy consumption. The energy consumption threshold can be determined based on the hardware parameters, energy efficiency level, and historical operating data of the first node, which is not limited in this application.
[0042] In this embodiment, after determining that it is necessary to start the task migration mechanism, the migration task of the first node can be determined. All tasks currently running on the first node can be prioritized according to real-time performance, and the priority division can be based on factors such as the response time requirements of the task and the degree of impact on the driving safety of the vehicle group. For example, tasks such as real-time position calculation of the vehicle group and emergency braking signal processing can be classified as high-priority tasks, and tasks such as historical trajectory data backup and non-critical performance statistics can be classified as low-priority tasks. Low-priority tasks with a priority lower than a preset priority threshold can be determined as migration tasks, and the total computing power requirement of the migration task does not exceed a preset percentage of the current total task computing power requirement of the first node, so as to avoid affecting the processing efficiency of the first node for high-priority tasks due to the migration of a large number of tasks. The preset percentage can be determined according to actual conditions, such as the preset percentage can be 30%.
[0043] In this embodiment, after determining the migration task, the target migration node corresponding to the first node can be determined. The target migration node can be preferentially selected from the target node sequence to ensure data transmission stability, ensure that the target migration node has sufficient resources to undertake the migration task, meet the storage requirements of the migration task, and reduce data transmission delays during the task migration process.
[0044] In this embodiment, after determining the target migration node, the migration task can be migrated to the target migration node. After the migration is completed, the computing resources, storage resources, and communication resources corresponding to the migration task in the first node can be released to reduce the energy consumption of the first node.
[0045] Through the above-mentioned task migration process, when the energy consumption of the first node exceeds the standard, some tasks can be promptly migrated to the appropriate target migration node, which not only ensures the continuity and reliability of the vehicle group service, but also effectively reduces the energy consumption of the first node, and realizes the dynamic allocation and energy consumption optimization of edge computing resources in the Internet of Vehicles environment.
[0046] In one embodiment of the present application, obtaining a first vehicle group in a first lane includes:
[0047] Obtaining operating data of the vehicle in the first lane, the operating data including the vehicle's position information, speed, and heading angle;
[0048] Determine the Euclidean distance, speed difference, and heading angle difference between any two adjacent vehicles in the first lane based on the operating data, cluster the vehicles in the first lane based on the first constraint condition to obtain clusters; and determine the vehicle group corresponding to each cluster as the first vehicle group;
[0049] The first constraint condition includes:
[0050] The Euclidean distance is less than or equal to a first distance threshold, the speed difference is less than or equal to a speed threshold, the heading angle difference is less than or equal to an angle threshold, and the number of vehicles in the cluster is greater than or equal to a number threshold.
[0051] In this embodiment, the operation data of all vehicles in the first lane can be collected in real time, wherein the operation data includes the position information, speed and heading angle of the vehicle, and the position information of the vehicle can include the latitude and longitude coordinates of the vehicle.
[0052] In this embodiment, after obtaining the operating data, the Euclidean distance, speed difference, and heading angle difference between any two adjacent vehicles in the first lane can be calculated based on this operating data. Specifically, the Euclidean distance refers to the straight-line distance between the position coordinates of the two vehicles in the first lane; the speed difference refers to the difference in the absolute values of the two vehicles' real-time speeds; and the heading angle difference refers to the difference in the absolute values of the two vehicles' heading angles.
[0053] In this embodiment, vehicles in the first lane can be clustered based on a first constraint to form clusters. The first constraint includes: the Euclidean distance between any two vehicles is less than or equal to a first distance threshold, such as 10 meters, to ensure that the vehicles are spatially close; the speed difference between any two vehicles is less than or equal to a speed threshold, to ensure similar vehicle speeds; the heading angle difference between any two vehicles is less than or equal to an angle threshold, to ensure that the vehicles are traveling in substantially the same direction; and the number of vehicles in a cluster is greater than or equal to a number threshold, such as three vehicles, to ensure a vehicle group of a certain size. The first distance threshold, speed difference, angle threshold, and number threshold can be determined based on the actual conditions of the first road and are not limited in this application.
[0054] In this embodiment, the vehicle group corresponding to each cluster that meets the first constraint can be determined as the first vehicle group. If there are multiple clusters that meet the constraint in the first lane, each cluster corresponds to an independent first vehicle group, and motion trajectory prediction and edge node matching are subsequently performed separately for each first vehicle group.
[0055] Through the above-mentioned clustering processing based on multi-dimensional constraints, the vehicle group with collaborative movement characteristics in the first lane can be accurately identified, providing an accurate basis for the division of service objects for the subsequent targeted allocation of edge computing resources in the Internet of Vehicles.
[0056] In one embodiment of the present application, predicting a first motion trajectory of a first vehicle group in a future preset time period includes:
[0057] Determining operating characteristics of the first vehicle group, the operating characteristics comprising an average speed, a standard deviation of speed, an average heading angle, a standard deviation of heading angle, an average inter-vehicle spacing, a standard deviation of inter-vehicle spacing, a lane keeping probability, a vehicle density, and a length of the first vehicle group for each vehicle in the first vehicle group at each time step;
[0058] A first motion trajectory of the first vehicle group in a future preset time period is determined based on the pre-trained first graph neural network, where the first motion trajectory includes the center position coordinates of the first vehicle group in each time step in the future preset time period.
[0059] In this embodiment, the operating characteristics of the first vehicle group can be determined. The operating characteristics may include the average speed, speed standard deviation, average heading angle, heading angle standard deviation, average vehicle spacing, vehicle spacing standard deviation, lane keeping probability, vehicle density, and length of the first vehicle group for each vehicle in the first vehicle group at each time step. The operating characteristics are used to comprehensively characterize the overall motion state characteristics of the first vehicle group. Determining the operating characteristics of the first vehicle group may include: calculating the average speed of each vehicle in the first vehicle group at each time step within the currently monitored preset time period, which can reflect the overall driving speed of the first vehicle group; calculating the speed standard deviation corresponding to the degree of deviation of the speed of all vehicles in the first vehicle group from the average speed at each time step, where a smaller value indicates a more consistent vehicle speed; calculating the average heading angle of all vehicles in the first vehicle group at each time step to obtain an average heading angle, which reflects the overall driving direction of the vehicle group; calculating the degree of deviation of the heading angle of all vehicles in the first vehicle group from the average heading angle at each time step to obtain a heading angle standard deviation, where a smaller value indicates a more consistent vehicle driving direction; calculating the distance between adjacent vehicles in the first vehicle group at each time step. The average Euclidean distance is used to obtain the average inter-vehicle distance, which reflects the overall density of the vehicle group. The standard deviation of the inter-vehicle distance is calculated by calculating the degree of deviation between the inter-vehicle distance between adjacent vehicles in the first vehicle group at each time step and the average inter-vehicle distance. The smaller the value, the more uniform the vehicle distribution. The proportion of vehicles in the first vehicle group that deviate from the first lane at each time step is counted, and the lane keeping probability is determined based on this proportion. For example, if 2 out of 10 vehicles temporarily deviate, the lane keeping probability is 80%, which reflects the lane stability of the vehicle group. The average number of vehicles per unit length of lane at each time step is calculated to obtain the vehicle density, which reflects the congestion level of the vehicle group. The Euclidean distance between the first and last vehicle positions in the first vehicle group at each time step is calculated to reflect the spatial span of the vehicle group.
[0060] In this embodiment, after obtaining the above-mentioned operation characteristics, they can be input into a pre-trained first graph neural network to predict the first motion trajectory of the first vehicle group in a preset future time period. The first graph neural network is trained based on sample data of the vehicle group operation in the first lane. The operation characteristics can be input into the pre-trained first graph neural network, which includes an input layer, a first hidden layer, a second hidden layer, and an output layer. The input layer is used to receive the operation characteristics corresponding to each of the above-mentioned consecutive time steps. The first hidden layer has a dimension of 64 and uses a graph convolutional network to extract the internal correlation characteristics of the first vehicle group. The second hidden layer has a dimension of 32 and embeds an attention mechanism to strengthen the influence weight of the lead vehicle in the first vehicle group on the trajectory of the first vehicle group. The output layer outputs the first motion trajectory of the first vehicle group in the preset future time period. The first motion trajectory includes the coordinates of the center position of the first vehicle group at each time step in the preset future time period.
[0061] By combining the multi-dimensional operating characteristics of the first vehicle group with the time series prediction capability of the first neural network, the overall movement trend of the first vehicle group can be accurately captured, so that the predicted first motion trajectory not only conforms to the driving characteristics of individual vehicles, but also reflects the coordination rules of the vehicle group, providing a reliable spatiotemporal basis for the subsequent dynamic matching of edge nodes.
[0062] In one embodiment of the present application, determining a target node sequence corresponding to the first motion trajectory based on load information and coverage of each node in the computing node set includes:
[0063] For each time step within a future preset time period, determine the center position coordinates of the first vehicle group corresponding to the first motion trajectory in the time step; determine a first position range corresponding to the first vehicle group in the time step based on the center position coordinates; select at least one first candidate node whose coverage range includes the first position range from the set of computing nodes; and determine a target node corresponding to the time step based on the load rate, remaining memory capacity, task queue length, and average data packet delay of the first candidate node;
[0064] Arrange the target nodes corresponding to each time step in sequence according to the order of the time steps in the future preset time period to obtain a target node sequence;
[0065] Among them, if the target nodes corresponding to two adjacent time steps in the target node sequence are different, and the overlapping distance of the coverage ranges of the target nodes corresponding to the two adjacent time steps is less than the second distance threshold, then a node whose coverage range includes the second position range corresponding to the first vehicle group in the two adjacent time steps, and whose load rate is less than or equal to the load rate threshold, the remaining memory capacity is greater than or equal to the memory requirement corresponding to the first vehicle group, the task queue length is less than or equal to the queue length threshold, and the average data packet delay is less than or equal to the delay threshold is selected from the target nodes corresponding to the two adjacent time steps. The node is determined as the updated target node corresponding to the two adjacent time steps, and the target node sequence is updated based on the updated target node.
[0066] In this embodiment, for each time step within the future preset time period, the center position coordinates of the first vehicle group corresponding to the first motion trajectory at that time step can be determined. For example, if the time step is 1 second and the future preset time period is 5 seconds, the center position coordinates corresponding to the 5th time step are the center position coordinates of the first vehicle group at 5 seconds after the prediction starts.
[0067] In this embodiment, the first position range corresponding to the first vehicle group at that time step can be determined based on the center position coordinates. Specifically, the center position coordinates can be used as a reference point. In combination with the operating characteristics of the first vehicle group, for example, if the length of the first vehicle group is 80 meters and the maximum lateral width of all vehicles in the first vehicle group is 5 meters, a rectangular area can be formed, extending 40 meters forward and backward from the center position coordinates to cover the length of the first vehicle group and 2.5 meters left and right to cover the lateral width of the first vehicle group. To account for possible minor lane changes or speed fluctuations, a fluctuation threshold can be added to the rectangular area. For example, the fluctuation threshold can be set to a 10% redundancy range. Based on the fluctuation threshold, the length of the rectangular area can be extended by an additional 4 meters forward and backward from the center, and the width of the rectangular area can be extended by an additional 0.25 meters left and right from the center. The resulting area is the first position range for that time step. This first position range can cover the possible positions of all vehicles in the first vehicle group during that time step.
[0068] In this embodiment, at least one first candidate node whose coverage range includes the first position range can be selected from the computing node set. If the circular area of the first position range completely falls within the coverage range of a node, the node is selected as the first candidate node.
[0069] In this embodiment, the target node corresponding to the time step is determined based on the load rate, remaining memory capacity, task queue length and average data packet delay of the first candidate node. The target node can be screened according to the following rules: nodes with a load rate less than or equal to a preset load rate threshold, a remaining memory capacity greater than or equal to the memory requirement corresponding to the first vehicle group single time step, a task queue length less than or equal to a preset queue length threshold, and an average data packet delay less than or equal to a preset delay threshold can be retained. If only one node remains after screening, then the node is the target node; if there are multiple nodes, the comprehensive score of each node is calculated, such as the weighted sum of the scores of the load rate, remaining memory capacity, task queue length and average data packet delay of each node can be determined as a comprehensive score, and the node with the highest comprehensive score can be selected as the target node. The weights of the load rate, remaining memory capacity, task queue length and average data packet delay can be determined according to actual conditions, and this application does not limit them.
[0070] In this embodiment, the target nodes of each time step may be arranged in sequence according to the order of the time steps in a future preset time period to obtain an initial target node sequence.
[0071] If the target nodes corresponding to two adjacent time steps in the target node sequence are different, and the overlapping distance of the coverage ranges of the two target nodes is less than a second distance threshold, it is necessary to determine whether to update the target node sequence. Specifically, the second position range corresponding to the first vehicle group in the two adjacent time steps can be first determined. The second position range can be defined based on the center position coordinates corresponding to the first vehicle group in the two time steps and the maximum lateral width of the first vehicle group. The position ranges corresponding to the two time steps can be determined based on the above method for defining the first position range, and the combination of the position ranges corresponding to the two time steps is determined as the second position range. It can be determined from the two target nodes whether there is a node whose coverage range includes the second location range, and satisfies the following conditions: the load rate is less than or equal to the load rate threshold, the remaining memory capacity is greater than or equal to the memory requirement corresponding to the first vehicle group, the task queue length is less than or equal to the queue length threshold, and the average data packet delay is less than or equal to the delay threshold; if there is a node that meets the above screening conditions, it can be determined as the updated target node corresponding to the two adjacent time steps respectively; if both nodes meet the above conditions, the node with the larger load rate can be selected as the updated target node corresponding to the two adjacent time steps respectively. For example, if the corresponding target nodes in adjacent time steps are edge nodes R1 and edge nodes R2, and the second distance threshold is 35 meters, if the overlapping distance of the coverage ranges of the two is 30 meters, which is less than the second distance threshold, and if the coverage range of R2 includes the second position range corresponding to the first vehicle group and R2 satisfies the load rate less than or equal to the load rate threshold, the remaining memory capacity is greater than or equal to the memory requirement corresponding to the first vehicle group, the task queue length is less than or equal to the queue length threshold, and the average data packet delay is less than or equal to the delay threshold, then the target nodes of the two time steps are updated to R2, and then the entire target node sequence is adjusted based on the updated target node.
[0072] Through the above steps, it is possible to ensure that the target node sequence not only fits the movement trajectory of the first vehicle group, but also maintains service continuity during node switching, providing stable node support for the dynamic resource allocation of edge computing in the Internet of Vehicles.
[0073] In one embodiment of the present application, determining the target node corresponding to the time step according to the load rate, remaining memory capacity, task queue length, and average data packet delay of the first candidate node includes:
[0074] Determine as a second candidate node a node whose load rate is less than or equal to a load rate threshold, whose remaining memory capacity is greater than or equal to a memory requirement corresponding to the first vehicle group, whose task queue length is less than or equal to a queue length threshold, and whose average data packet delay is less than or equal to a delay threshold.
[0075] If the second candidate node contains only one node, the second candidate node is determined as the target node of the time step; if the second candidate node contains multiple nodes, the resource adaptability score of each second candidate node is calculated, and the second candidate node with the highest resource adaptability score is determined as the target node corresponding to the time step.
[0076] In this embodiment, the second candidate node corresponding to the time step can be determined based on the load rate, remaining memory capacity, task queue length, and average packet delay of the first candidate node. Specifically, a node among the first candidate nodes that meets screening conditions can be determined as the second candidate node. These screening conditions may include: a load rate less than or equal to a load rate threshold, remaining memory capacity greater than or equal to the memory requirement corresponding to the first vehicle group, a task queue length less than or equal to a queue length threshold, and an average packet delay less than or equal to a delay threshold.
[0077] In this embodiment, after obtaining the second candidate node, the target node corresponding to the time step can be determined based on the number of the second candidate nodes. If the second candidate node contains only one node, then the node can be directly determined as the target node for the time step; if the second candidate node contains multiple nodes, the resource adaptability score of each second candidate node can be calculated, and the node with the highest resource adaptability score can be determined as the target node. Among them, the calculation of the resource adaptability score can be performed in combination with the weight of each parameter. For example, the weight corresponding to each parameter can be determined separately according to the actual situation, such as the weight of the load rate can be set to 30%, the weight of the remaining memory capacity can be set to 20%, the weight of the task queue length can be set to 20%, and the weight of the average data packet delay can be set to 30%. During the specific calculation, the first ratio between the current load rate and the load rate threshold can be determined, and the difference between the value 1 and the first ratio can be determined as the load rate score; the ratio of the current remaining memory capacity to the remaining memory capacity of the vehicle group memory demand can be determined as the remaining memory capacity score; the second ratio between the current queue length and the queue length threshold can be determined, and the difference between the value 1 and the second ratio can be determined as the task queue length score; the third ratio between the average packet delay and the delay threshold can be determined, and the difference between the value 1 and the third ratio can be determined as the average packet delay score; the weighted sum of each score and its corresponding weight can be determined as the resource adaptability score.
[0078] Determining the second candidate node and target node in the above manner can ensure that the selected nodes can meet the needs of the first vehicle group in terms of load, memory, task processing capability, and transmission latency. At the same time, the optimal solution is selected from multiple candidate nodes through resource adaptability scoring, providing accurate and stable edge computing services for the vehicle group, and improving the rationality and reliability of resource allocation in the Internet of Vehicles environment.
[0079] In one embodiment of the present application, if the energy consumption value of a first node in a target node sequence exceeds an energy consumption threshold, determining a migration task of the first node and a target migration node corresponding to the first node, and migrating the migration task to the target migration node includes:
[0080] Monitor the energy consumption value of each node in the target node sequence at each time step;
[0081] If the energy consumption value of the first node in a first number of consecutive time steps exceeds the energy consumption threshold, determining the non-real-time task in the first node with a priority lower than a preset threshold as a migration task;
[0082] The nodes in the target node sequence that meet the second constraint condition are determined as candidate migration nodes, and the node with the smallest load rate among the candidate migration nodes is determined as the target migration node; wherein the second constraint condition is:
[0083] The overlapping distance corresponding to the coverage range of the first node is greater than or equal to a third distance threshold;
[0084] The current load rate is less than or equal to the load rate threshold;
[0085] The remaining memory capacity is greater than or equal to the first multiple of the memory corresponding to the migration task;
[0086] The communication delay corresponding to the migration path between the first node is less than or equal to the delay threshold.
[0087] In this embodiment, the energy consumption value corresponding to each node in the target node sequence at each time step can be monitored. The energy consumption value can be the sum of the energy consumption corresponding to computing energy consumption, data transmission energy consumption, and device standby energy consumption. Computing energy consumption refers to the energy consumption generated by computing components such as the CPU and GPU (Graphics Processing Unit) when the node processes a task, which can be calculated based on the power of the computing component and the task processing time; data transmission energy consumption refers to the energy consumption generated by the communication module when the node exchanges data with the first vehicle group and other nodes, which can be determined based on the data transmission volume, transmission rate, and communication module power; device standby energy consumption refers to the basic energy consumption when the node is in operation but not processing tasks, which is determined by the device hardware parameters. These three types of energy consumption can be collected in real time, and the sampling frequency is consistent with the time step.
[0088] If the energy consumption value of the first node in a first number of consecutive time steps exceeds the energy consumption threshold, the migration task determination process is initiated. As an example, the first number can be set to 3 time steps, and the energy consumption threshold can be set based on the rated power and energy efficiency standard of the first node. When the energy consumption value of the first node in three consecutive time steps of 5, 6, and 7 exceeds the energy consumption threshold, the task migration mechanism can be initiated. At this time, non-real-time tasks in the first node with a priority lower than the preset threshold can be determined as migration tasks. Task priority can be divided according to service type. For example, tasks directly related to driving safety such as vehicle real-time navigation data processing and emergency braking signal response are of high priority; tasks such as historical trajectory storage and non-critical performance statistics are of low priority. These low-priority tasks are determined as migration tasks, and the total computing power required by the migration tasks does not exceed a preset percentage of the current total task computing power of the first node to avoid affecting the processing of high-priority tasks. The preset percentage can be determined based on actual conditions. For example, the preset percentage can be set to 30%.
[0089] In this embodiment, after determining the migration task, nodes that meet the second constraint condition can be screened from the target node sequence as candidate migration nodes, and the node with the smallest load rate can be determined as the target migration node. Among them, the second constraint condition includes: the overlapping distance corresponding to the coverage range of the first node is greater than or equal to the third distance threshold, ensuring that the service area of the node and the location range of the first vehicle group have sufficient overlap, reducing the risk of service interruption of the first vehicle group; the current load rate is less than or equal to the load rate threshold, ensuring that the candidate node has sufficient redundant resources to undertake the migration task; the remaining memory capacity is greater than or equal to the first multiple of the memory corresponding to the migration task, such as 1.2 times. If the migration task requires 1GB of memory, the remaining memory of the candidate node is ≥1.2GB, meeting the storage requirements of the migration task; the communication delay corresponding to the migration path between the first node is less than or equal to the delay threshold, such as 30ms, ensuring that the task data can be transmitted quickly and reducing the migration time.
[0090] After determining the target migration node, the relevant data of the migration task, including the task program, intermediate calculation results, and progress markers, is transmitted to the target migration node via an encrypted data transmission channel. Once the target migration node completes the environment deployment and confirms that it is ready to take over the task, the migration task on the first node is stopped and the target migration node continues execution. After the migration is completed, the energy consumption of the first node can be significantly reduced, achieving energy optimization while ensuring service continuity.
[0091] Through the above process, when the node energy consumption exceeds the standard, migration tasks and target nodes can be accurately screened, which not only avoids the impact of high-priority tasks, but also ensures the stability of the target node after migration through the principle of minimizing the load rate, effectively balancing the service quality of the Internet of Vehicles and the needs of energy consumption control.
[0092] In one embodiment of the present application, if there is no candidate migration node that meets the second constraint in the target node sequence, a node that meets the second constraint is selected from a pool of backup nodes whose overlapping distance corresponding to the coverage range of the first node is greater than or equal to a third distance threshold and is determined as a candidate migration node;
[0093] If there is no candidate migration node that meets the second constraint in the standby node pool, the migration task is split into multiple subtasks, and the subtasks are respectively migrated to adjacent nodes of the first node whose load rate is less than or equal to the load rate threshold.
[0094] In this embodiment, when no node in the target node sequence meets the second constraint, the backup node pool can be called. The backup node pool is a collection of pre-deployed redundant edge nodes, including temporarily deployed mobile edge terminals, roadside units on surrounding non-main roads, etc., whose coverage must overlap with the first node to a certain extent. Nodes whose overlapping distance with the first node's coverage is greater than or equal to the third distance threshold can be screened from the backup node pool, and these nodes are checked to see if they meet other requirements in the second constraint, such as load rate, memory, latency, etc. Nodes that meet all of the requirements are determined as candidate migration nodes.
[0095] If there is still no candidate migration node that meets the second constraint in the backup node pool, the migration task can be split. Specifically, the migration task is split into multiple subtasks according to the computing power demand ratio, and the computing power demand of each subtask does not exceed the preset ratio threshold of the total demand of the original migration task, such as 30%; after splitting, these subtasks are respectively migrated to the neighboring nodes of the first node, and the neighboring nodes must meet the load rate less than or equal to the load rate threshold. Among them, the neighboring node characterizes the overlapping distance with the coverage range of the first node greater than or equal to the third distance threshold, and the geographical distance is less than or equal to the preset fourth distance threshold, that is, the geographically close edge node. During migration, it is necessary to ensure that the computing power of the subtasks undertaken by each neighboring node does not exceed a preset percentage of its remaining computing power, such as 30%, to avoid load overload due to excessive undertaking; the third distance threshold and the fourth distance threshold can be determined according to actual conditions, and this application does not limit them.
[0096] In this embodiment, during the subtask migration process, an independent encrypted data channel can be established for each subtask to synchronize the corresponding task data. After the neighboring nodes complete the environment deployment, the subtask execution is initiated separately. After the migration is complete, each subtask runs in parallel on the neighboring nodes, and the calculation results are ultimately aggregated and fed back to the first node or the first vehicle group to ensure the integrity of the service logic. For example, after the three subtasks are split and migrated to neighboring nodes N-1, N-2, and N-3 respectively, node N-1 will aggregate the results and transmit them back after completion, ensuring that the overall effect of the migration task is not affected.
[0097] Through the above-mentioned hierarchical processing strategy, when there are no suitable nodes in the target node sequence and the backup node pool, migration can still be achieved through task splitting. This not only avoids the risk of excessive load on a single node, but also ensures the continuity of the migration task, further improving the robustness of the energy consumption optimization solution for edge computing in the Internet of Vehicles, and adapting to complex and changing road scenarios.
[0098] In one embodiment of the present application, if there are vehicles in the first lane that do not meet the conditions for cluster aggregation, or the divided clusters do not meet the first constraint of the first vehicle group, these vehicles can be treated as independent individuals and independent identification files can be established. Their operating data, such as location information, speed, and heading angle, can be collected and updated in real time, and the data sampling frequency is consistent with that of the first vehicle group to ensure equivalent monitoring granularity. A prediction model applicable to individuals can be adopted, such as a single-vehicle trajectory prediction algorithm based on Kalman filtering, which directly predicts the individual motion trajectory of each vehicle within a preset time period in the future without calculating the center position of the group. The time step is synchronized with the time step of the first vehicle group. When matching edge nodes, the spatial coverage constraints are relaxed: for independent vehicles, the node coverage range only needs to include their individual position coordinates, and the overlapping length of the coverage range and the vehicle's driving path is greater than or equal to a preset path threshold. The path threshold can be determined based on actual conditions and is not limited in this application, such as 30 meters. In terms of resource allocation, the amount of resources is calculated according to the actual needs of the individual, and the node load rate threshold can be appropriately relaxed compared to the load rate threshold, such as increasing the load rate threshold by 5% to prioritize its basic service needs.
[0099] In this embodiment, all vehicles in the first lane can be re-clustered every preset time period. At the same time, these vehicles that have not formed a valid cluster are dynamically tracked. If the first constraint condition is met, they are clustered into the first vehicle group and included in the above-mentioned vehicle group management process; if it continues to be not met, individualized management is maintained until they leave the first lane.
[0100] Through the above processing, it can not only ensure that all vehicles in the first lane can obtain edge computing services, but also avoid resource waste through differentiated management strategies. This allows the solution to still operate efficiently in scenarios with sparse traffic or scattered vehicle distribution, covering the service needs of all vehicles on the road.
[0101] It should be further explained that in the present application, there may be one or more first lanes, and there may also be one or more first vehicle groups in the first lanes. Each first vehicle group in each first lane corresponds to a first motion trajectory in a preset time period in the future, and each first motion trajectory corresponds to a target node sequence; the energy consumption threshold corresponding to each target node sequence may be the same or different; it may be determined whether the energy consumption value in each target node sequence exceeds the energy consumption threshold corresponding to the target node sequence. If there is a first node in a target node sequence whose energy consumption value exceeds the energy consumption threshold, the migration task of the first node and the target migration node corresponding to the first node may be determined, and the migration task may be migrated to the target migration node.
[0102] Corresponding to the above embodiment, a method for dynamic allocation of edge computing resources and energy consumption optimization in a vehicle networking environment is provided. Figure 2 This is a structural block diagram of a system for dynamic allocation of edge computing resources and energy consumption optimization in a connected vehicle environment provided by an embodiment of the present application. For ease of explanation, only the parts related to the embodiment of the present application are shown. Figure 2 The edge computing resource dynamic allocation and energy consumption optimization system 20 in the Internet of Vehicles environment includes: a prediction module 21, a determination module 22 and a migration module 23.
[0103] The prediction module 21 is configured to obtain a first vehicle group in a first lane and predict a first motion trajectory of the first vehicle group in a future preset time period;
[0104] a determination module 22 for determining a computing node set corresponding to the first lane in the connected vehicle environment, and determining a target node sequence corresponding to the first motion trajectory based on load information and coverage of each node in the computing node set;
[0105] The migration module 23 is configured to determine the migration task of the first node and the target migration node corresponding to the first node if the energy consumption value of the first node in the target node sequence exceeds the energy consumption threshold, and migrate the migration task to the target migration node.
[0106] In one embodiment of the present application, the prediction module 21 is further used to: obtain operating data of vehicles in the first lane, the operating data including the vehicle's position information, speed and heading angle; determine the Euclidean distance, speed difference and heading angle difference between any two adjacent vehicles in the first lane based on the operating data, cluster the vehicles in the first lane according to the first constraint condition to obtain clusters; determine the vehicle group corresponding to each cluster as the first vehicle group; wherein the first constraint condition includes: the Euclidean distance is less than or equal to the first distance threshold, the speed difference is less than or equal to the speed threshold, the heading angle difference is less than or equal to the angle threshold, and the number of vehicles in the cluster is greater than or equal to the number threshold.
[0107] The prediction module 21 is further used to: determine the operating characteristics of the first vehicle group, the operating characteristics including the average speed, speed standard deviation, average heading angle, heading angle standard deviation, average vehicle spacing, vehicle spacing standard deviation, lane keeping probability, vehicle density, and length of the first vehicle group of each vehicle in the first vehicle group at each time step; determine a first motion trajectory of the first vehicle group in a future preset time period based on a pre-trained first graph neural network, the first motion trajectory including the center position coordinates of the first vehicle group at each time step in the future preset time period.
[0108] The determination module 22 is further configured to: determine the center position coordinates of the first vehicle group corresponding to the first motion trajectory in the time step for each time step within a future preset time period; determine the first position range corresponding to the first vehicle group in the time step based on the center position coordinates; select at least one first candidate node whose coverage range includes the first position range from the computing node set; determine the target node corresponding to the time step based on the load rate, remaining memory capacity, task queue length, and average data packet delay of the first candidate node; arrange the second candidate nodes of each time step in sequence according to the order of the time steps within the future preset time period to obtain a target node sequence; wherein, if two adjacent time steps in the target node sequence are If the target nodes corresponding to each other are different and the overlapping distance of the coverage ranges of the target nodes corresponding to the two adjacent time steps is less than the second distance threshold, then a node whose coverage range includes the second position range corresponding to the first vehicle group in the two adjacent time steps, and whose load rate is less than or equal to the load rate threshold, the remaining memory capacity is greater than or equal to the memory requirement corresponding to the first vehicle group, the task queue length is less than or equal to the queue length threshold, and the average data packet delay is less than or equal to the delay threshold is selected from the target nodes corresponding to the two adjacent time steps. The node is determined as the updated target node corresponding to the two adjacent time steps, and the target node sequence is updated based on the updated target node.
[0109] The determination module 22 is also used to: determine as the second candidate node a node in the first candidate node whose load rate is less than or equal to the load rate threshold, whose remaining memory capacity is greater than or equal to the memory requirement corresponding to the first vehicle group, whose task queue length is less than or equal to the queue length threshold, and whose average data packet delay is less than or equal to the delay threshold; if the second candidate node includes only one node, then determine the second candidate node as the target node of the time step; if the second candidate node includes multiple nodes, then calculate the resource adaptability score of each second candidate node, and determine the second candidate node with the highest resource adaptability score as the target node corresponding to the time step.
[0110] The migration module 23 is also used to: monitor the energy consumption value corresponding to each node in the target node sequence at each time step; if the energy consumption value of the first node in a first number of consecutive time steps exceeds the energy consumption threshold, the non-real-time task in the first node with a priority lower than the preset threshold is determined as the migration task; the node in the target node sequence that meets the second constraint condition is determined as the candidate migration node, and the node with the smallest load rate among the candidate migration nodes is determined as the target migration node; wherein the second constraint condition is: the overlapping distance corresponding to the coverage range of the first node is greater than or equal to the third distance threshold; the current load rate is less than or equal to the load rate threshold; the remaining memory capacity is greater than or equal to the first multiple of the memory corresponding to the migration task; and the communication delay corresponding to the migration path between the first node is less than or equal to the delay threshold.
[0111] The migration module 23 is also used to: if there is no candidate migration node that meets the second constraint condition in the target node sequence, then select a node that meets the second constraint condition from the backup node pool whose overlapping distance corresponding to the coverage range of the first node is greater than or equal to the third distance threshold and determine it as the candidate migration node; if there is no candidate migration node that meets the second constraint condition in the backup node pool, then split the migration task into multiple subtasks, and migrate the subtasks respectively to the neighboring nodes of the first node whose load rate is less than or equal to the load rate threshold.
[0112] See also Figure 3 , Figure 3 This is a schematic block diagram of an electronic device provided in one embodiment of the present application. Figure 3 The electronic device 300 in the embodiment shown may include: one or more processors 301, one or more input devices 302, one or more output devices 303, and one or more memories 304. The processors 301, input devices 302, output devices 303, and memories 304 communicate with each other via a communication bus 305. The memory 304 is used to store computer programs, which include program instructions. The processor 301 is used to execute the program instructions stored in the memory 304. The processor 301 is configured to call the program instructions to execute the functions of the modules / units in the above-mentioned system embodiments, such as Figure 2 The functions of the prediction module 21, the determination module 22 and the migration module 23 are shown.
[0113] It should be understood that in the embodiment of the present application, the processor 301 may be a central processing unit (CPU), and the processor may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc.
[0114] The input device 302 may include a touchpad, a fingerprint collection sensor (for collecting user fingerprint information and fingerprint direction information), a microphone, etc. The output device 303 may include a display (LCD, etc.), a speaker, etc.
[0115] The memory 304 may include a read-only memory and a random access memory, and provides instructions and data to the processor 301. A portion of the memory 304 may also include a non-volatile random access memory. For example, the memory 304 may also store device type information.
[0116] In a specific implementation, the processor 301, input device 302, and output device 303 described in the embodiment of the present application can execute the implementation method described in an embodiment of a method for dynamic allocation of edge computing resources and energy consumption optimization in a vehicle network environment provided by the embodiment of the present application, and can also execute the implementation method of the electronic device described in the embodiment of the present application, which will not be repeated here.
[0117] In another embodiment of the present application, a computer-readable storage medium is provided. The computer-readable storage medium stores a computer program. The computer program includes program instructions. When the program instructions are executed by a processor, all or part of the process of the method in the above embodiment is implemented. The computer program can also be used to instruct related hardware to complete the process. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by the processor, the steps of each of the above method embodiments are implemented. The computer program includes computer program code, which can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium can include: any entity or device capable of carrying computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal and software distribution medium.
[0118] The computer-readable storage medium can be an internal storage unit of the electronic device in any of the aforementioned embodiments, such as a hard disk or memory of the electronic device. The computer-readable storage medium can also be an external storage device of the electronic device, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) card, a flash memory card, etc. Furthermore, the computer-readable storage medium can include both an internal storage unit of the electronic device and an external storage device. The computer-readable storage medium is used to store computer programs and other programs and data required by the electronic device. The computer-readable storage medium can also be used to temporarily store data that has been output or is about to be output.
[0119] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in terms of function in the above description. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0120] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the electronic devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0121] In the several embodiments provided in this application, it should be understood that the disclosed electronic devices and methods can be implemented in other ways. For example, the system embodiments described above are merely schematic. For example, the division of units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces or units, or can be an electrical, mechanical or other form of connection.
[0122] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the embodiments of the present application.
[0123] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.
[0124] The above are only specific embodiments of the present application, but the scope of protection of the present application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in this application, and such modifications or substitutions should be included in the scope of protection of this application. Therefore, the scope of protection of this application should be based on the scope of protection of the claims.
Claims
1. A method for dynamic allocation of edge computing resources and energy consumption optimization in an Internet of Vehicles environment, characterized by: include: Acquire a first vehicle group in a first lane, and predict a first motion trajectory of the first vehicle group in a future preset time period; Determining a computing node set corresponding to the first lane in a connected vehicle environment, and determining a target node sequence corresponding to the first motion trajectory based on load information and coverage of each node in the computing node set; If the energy consumption value of the first node in the target node sequence exceeds the energy consumption threshold, a migration task of the first node and a target migration node corresponding to the first node are determined, and the migration task is migrated to the target migration node.
2. The method according to claim 1, characterized in that The obtaining of the first vehicle group in the first lane includes: Acquiring operating data of a vehicle in a first lane, the operating data including position information, speed, and heading angle of the vehicle; determining, based on the operating data, a Euclidean distance, a speed difference, and a heading angle difference between any two adjacent vehicles in a first lane, clustering the vehicles in the first lane according to a first constraint condition to obtain clusters; and determining a vehicle group corresponding to each cluster as the first vehicle group; The first constraint condition includes: The Euclidean distance is less than or equal to a first distance threshold, the speed difference is less than or equal to a speed threshold, the heading angle difference is less than or equal to an angle threshold, and the number of vehicles in the cluster is greater than or equal to a number threshold.
3. The method according to claim 1, characterized in that The predicting of the first movement trajectory of the first vehicle group in a future preset time period includes: Determining operating characteristics of the first vehicle group, the operating characteristics comprising an average speed, a standard deviation of speed, an average heading angle, a standard deviation of heading angle, an average inter-vehicle spacing, a standard deviation of inter-vehicle spacing, a lane keeping probability, a vehicle density, and a length of the first vehicle group at each time step of each vehicle in the first vehicle group; A first motion trajectory of the first vehicle group in a future preset time period is determined based on a pre-trained first graph neural network, where the first motion trajectory includes the center position coordinates of the first vehicle group in each time step in the future preset time period.
4. The method according to claim 1, wherein The determining, based on the load information and coverage of each node in the computing node set, a target node sequence corresponding to the first motion trajectory includes: For each time step within a future preset time period, determine the center position coordinates of the first vehicle group corresponding to the first motion trajectory in the time step; determine a first position range corresponding to the first vehicle group at the time step based on the center position coordinates; select at least one first candidate node from a set of computing nodes whose coverage range includes the first position range; and determine a target node corresponding to the time step based on the load rate, remaining memory capacity, task queue length, and average data packet delay of the first candidate node; Arrange the target nodes corresponding to each time step in sequence according to the order of the time steps in the future preset time period to obtain a target node sequence; Among them, if the target nodes corresponding to two adjacent time steps in the target node sequence are different, and the overlapping distance of the coverage ranges of the target nodes corresponding to the two adjacent time steps is less than the second distance threshold, then a node whose coverage range includes the second position range corresponding to the first vehicle group in the two adjacent time steps, and whose load rate is less than or equal to the load rate threshold, the remaining memory capacity is greater than or equal to the memory requirement corresponding to the first vehicle group, the task queue length is less than or equal to the queue length threshold, and the average data packet delay is less than or equal to the delay threshold is selected from the target nodes corresponding to the two adjacent time steps. The node is determined as the updated target node corresponding to the two adjacent time steps, and the target node sequence is updated based on the updated target node.
5. The method according to claim 4, characterized in that The determining of the target node corresponding to the time step according to the load rate, remaining memory capacity, task queue length, and average data packet delay of the first candidate node includes: Determine as a second candidate node a node among the first candidate nodes whose load rate is less than or equal to a load rate threshold, whose remaining memory capacity is greater than or equal to a memory requirement corresponding to the first vehicle group, whose task queue length is less than or equal to a queue length threshold, and whose average data packet delay is less than or equal to a delay threshold; If the second candidate node includes only one node, the second candidate node is determined as the target node of the time step; if the second candidate node includes multiple nodes, the resource adaptability score of each second candidate node is calculated, and the second candidate node with the highest resource adaptability score is determined as the target node corresponding to the time step.
6. The method according to claim 1, characterized in that If the energy consumption value of the first node in the target node sequence exceeds the energy consumption threshold, determining the migration task of the first node and the target migration node corresponding to the first node, and migrating the migration task to the target migration node, includes: Monitor the energy consumption value of each node in the target node sequence at each time step; If the energy consumption value of the first node in a first number of consecutive time steps exceeds the energy consumption threshold, determining the non-real-time task in the first node with a priority lower than a preset threshold as a migration task; Determine the nodes in the target node sequence that meet the second constraint as candidate migration nodes, and determine the node with the smallest load rate among the candidate migration nodes as the target migration node; wherein the second constraint is: The overlapping distance corresponding to the coverage range of the first node is greater than or equal to a third distance threshold; The current load rate is less than or equal to the load rate threshold; The remaining memory capacity is greater than or equal to the first multiple of the memory corresponding to the migration task; A communication delay corresponding to the migration path between the first node and the first node is less than or equal to a delay threshold.
7. The method according to claim 6, characterized in that If there is no candidate migration node that meets the second constraint in the target node sequence, selecting a node that meets the second constraint from a pool of backup nodes whose overlapping distance with the coverage range of the first node is greater than or equal to a third distance threshold and determines it as the candidate migration node; If there is no candidate migration node that meets the second constraint in the standby node pool, the migration task is split into multiple subtasks, and the subtasks are respectively migrated to adjacent nodes of the first node whose load rate is less than or equal to the load rate threshold.
8. A system for dynamic allocation of edge computing resources and energy consumption optimization in an Internet of Vehicles environment, characterized by: include: A prediction module, configured to obtain a first vehicle group in a first lane and predict a first motion trajectory of the first vehicle group in a future preset time period; a determination module, configured to determine a computing node set corresponding to the first lane in a connected vehicle environment, and determine a target node sequence corresponding to the first motion trajectory based on load information and coverage of each node in the computing node set; A migration module is used to determine the migration task of the first node and the target migration node corresponding to the first node if the energy consumption value of the first node in the target node sequence exceeds the energy consumption threshold, and migrate the migration task to the target migration node.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that: When the processor executes the computer program, it implements the steps of a method for dynamic allocation of edge computing resources and energy consumption optimization in a vehicle network environment as described in any one of claims 1 to 7.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by the processor, the steps of the method for dynamic allocation of edge computing resources and energy consumption optimization in a vehicle network environment as described in any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
efficient edge computing migration method for Internet of Vehicles application
CN109905859A
Revenue awareness service migration and resource allocation method of multi-edge cellular Internet of Vehicles
CN119562311A
Self-adaptive container migration method and system
CN120034907A
Vehicle control using trajectory clustering and reactive prediction
US12060060B1
Planning vehicle computational unit migration based on mobility prediction
US20200249039A1
Cited By
Adaptive load balancing method and system based on multi-dimensional intelligent perception
CN121411984A
Internet of vehicles low-delay communication method and system based on edge computing
CN121418910A
An edge-computing-based low-latency communication method and system for vehicle networking
CN121418910B