A processing method for predicting node load based on electric vehicle data

By collecting electric vehicle data around the clock and training models, and using Transformer or Bi-LSTM models for node load prediction, the problem of predicting the electricity load at the node level in electric vehicle charging pile networks has been solved, enabling accurate prediction of future electricity load and supporting dynamic power regulation of smart grids.

CN119721383BActive Publication Date: 2025-11-11一能充电科技(深圳)股份有限公司
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411893181.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-20
Publication Date
2025-11-11
Estimated Expiration
2044-12-20

AI Technical Summary

Technical Problem

Existing technologies struggle to accurately predict the node-level power load of electric vehicle charging pile network nodes, and there is a lack of effective data processing methods.

Method used

By collecting electric vehicle data around the clock, a vehicle and node dataset is constructed. The node load prediction model is then trained, and feature extraction and regression prediction are performed based on Transformer or Bi-LSTM models to predict future electricity load.

Benefits of technology

It enables accurate prediction of the load on electric vehicle charging pile network nodes, supports dynamic power regulation of smart grids, and improves the management efficiency of power supply areas.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119721383B_ABST
    Figure CN119721383B_ABST
Patent Text Reader

Abstract

This invention relates to a method for predicting node load based on electric vehicle data. The method includes: collecting data from all electric vehicles operating within the power supply area of ​​a first network node around the clock to obtain a first vehicle dataset; collecting data from the electricity load of the first network node around the clock to obtain a first node dataset; constructing a first dataset based on the first vehicle / node dataset; constructing a node load prediction model; training the model based on the first dataset; and after model training, using the node load prediction model to predict the electricity load of the first network node at a future first prediction time based on the collected data within the most recent first sampling period in the first vehicle dataset. This invention enables node load prediction based on electric vehicle data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing technology, and in particular to a method for predicting node load based on electric vehicle data. Background Technology

[0002] Distribution network areas can be subdivided into multiple network nodes using a grid-like approach, and the total load of all network nodes represents the total load of the distribution area. Smart grid management aims for dynamic power regulation at the node level, which presupposes the ability to predict node-level electricity load. Data collection reveals a correlation between the node's electricity load data and the charging data of all electric vehicles (EVs) within its power supply area. Furthermore, a series of related data about charging vehicles (such as total number of vehicles, vehicle type, and vehicle travel characteristics) are also correlated with the charging data. Therefore, it can be inferred that the corresponding node load can be predicted based on the collected EV data. How to predict node load based on EV data is precisely the technical problem this invention aims to solve. Summary of the Invention

[0003] The purpose of this invention is to address the shortcomings of existing technologies by providing a method for predicting node load based on electric vehicle data. This invention collects vehicle datasets from all electric vehicles operating within the power supply area of ​​network nodes around the clock, and collects node datasets from the power load of network nodes around the clock. A model training dataset, denoted as the first dataset, is constructed based on the vehicle and node datasets. A node load prediction model, used to predict node power load based on the vehicle embedding encoding tensor as model input, is trained based on the first dataset. After model training, the node load prediction model is used to predict the power load of network nodes at a specified future time based on the most recently collected data within the vehicle dataset. This invention solves the technical problem of how to predict node load based on electric vehicle data.

[0004] To achieve the above objectives, embodiments of the present invention provide a method for predicting node load based on electric vehicle data, the method comprising:

[0005] The power supply area of ​​the first network node is recorded as the corresponding first area; and all electric vehicles traveling in the first area are collected around the clock to obtain the corresponding first vehicle dataset; and the power load of the first network node is collected around the clock to obtain the corresponding first node dataset.

[0006] Set the data sampling duration to the first sampling duration L. S And set the prediction interval to the first interval length L;A Based on the first vehicle dataset, the first node dataset, and the first sampling duration L S and the first interval duration L A The dataset used to build the model training dataset is denoted as the first dataset.

[0007] A node load prediction model is constructed; and the node load prediction model is trained based on the first dataset; the node load prediction model is used to perform node power load prediction processing based on the vehicle embedding encoding tensor input to the model and output the corresponding node load prediction amount;

[0008] After the model training is completed, the node load prediction model is used to predict the load based on the most recent sampling time L in the first vehicle dataset. S The collected data is used to predict the power load of the first network node at a future first predicted time; the interval between the first predicted time and the current time is the first interval length L. A .

[0009] Preferably, the first vehicle dataset includes multiple first vehicle data records; the first vehicle data record includes a first collection period, a first vehicle identifier, a first location type, a first vehicle type, a first parking status, a first start-up status, a first navigation mode, a first charging mode, and a first charging level; the first collection period includes a first period start time and a first period end time, and the length of the period between the first period start time and the first period end time is fixedly denoted as the first period length ΔL1; the first vehicle identifier is a unique identifier for the corresponding electric vehicle; the first location type is used to mark the location type of the corresponding electric vehicle in the current period, and the first location type includes commercial locations, residential areas, and roads; the first vehicle type includes private cars and commercial vehicles. The vehicle; the first parking status is used to mark the parking status of the corresponding electric vehicle in the current time period, and the first parking status includes yes and no; the first starting trip status is used to mark whether the corresponding electric vehicle is in the trip starting time period in the current time period, and the first starting trip status includes yes and no; the first navigation mode is used to mark the navigation mode adopted by the corresponding electric vehicle in the current time period, and the first navigation mode includes the shortest driving route navigation mode and the shortest driving time navigation mode; the first charging mode is used to mark whether the corresponding electric vehicle is in the charging state in the current time period and the corresponding charging mode, and the first charging mode includes not charging, regular charging and fast charging; the first charging amount is the total charging amount of the corresponding electric vehicle in the current time period, and the first charging amount is 0 when the first charging mode is not charging;

[0010] The first node dataset includes multiple first node data records; the first node data records include a second collection period and the total load of the first node; the second collection period includes the start time and end time of the second period, the length of the period between the start time and end time of the second period is fixed and denoted as the second period length △L2, the second period length △L2 is N times the first period length △L1, and N is a preset positive integer; the total load of the first node is the total power load of the first network node in the current second collection period;

[0011] The first sampling duration L S It is an integer multiple of the length △L1 of the first time period;

[0012] The first dataset includes multiple first data records; each first data record includes a first vehicle embedding encoding tensor and a first electricity load label; the first vehicle embedding encoding tensor is composed of multiple first vehicle embedding encoding vectors; each first vehicle embedding encoding vector corresponds to an electric vehicle; all first vehicle embedding encoding vectors have the same vector length M, where M = L. S / △L1; The first vehicle embedding encoding vector is composed of M first time period encoding groups arranged in chronological order; each first time period encoding group corresponds to a first vehicle data record; the first time period encoding group includes location type encoding, vehicle type encoding, parking status encoding, start travel status encoding, navigation mode encoding, charging mode encoding, and charging power encoding.

[0013] Preferably, the step based on the first vehicle dataset, the first node dataset, and the first sampling duration L... S and the first interval duration L A The dataset used to build the model training dataset is denoted as the first dataset, and it specifically includes:

[0014] Step 31, according to the first sampling duration L S The first vehicle dataset is sequentially segmented to obtain multiple corresponding first segment datasets;

[0015] Each of the first segment datasets consists of multiple first vehicle data records; and the time span of each first segment dataset is the first sampling duration L. S ;

[0016] Step 32: Take the first first segment dataset as the corresponding current segment dataset;

[0017] Step 33: Take the segment end time of the current segmented dataset as the corresponding current end time; and divide the current end time by the first interval duration L. A The sums are used to obtain the corresponding current predicted time; and the total load of the first node data record corresponding to the second collection period whose start time of the second period is closest to the current predicted time is used as the corresponding current predicted load.

[0018] Step 34: Cluster the first vehicle data records with the same first vehicle identifier in the current segmented dataset into one class, and sort all the first vehicle data records in the same class according to the chronological order to form the corresponding first single vehicle record sequence.

[0019] Step 35: Each of the first single-vehicle record sequences is taken as the corresponding current single-vehicle record sequence; and a corresponding first vehicle embedding encoding vector is set for the current single-vehicle record sequence according to the vector data format of the first vehicle embedding encoding vector; the encoding values ​​of all codes in all first time point encoding groups of the current vehicle embedding encoding vector are initialized to 0; and a correspondence is established between each of the first vehicle data records in the current single-vehicle record sequence and a first time period encoding group within the current vehicle embedding encoding vector according to the time period correspondence; and a traversal is performed on all the first vehicle data records in the current single-vehicle record sequence; and during this traversal, the currently traversed first vehicle data record is taken as the corresponding current record; and the first location type, first vehicle type, first parking status, first starting travel status, and the first vehicle type are set for the current record. The first navigation mode and the first charging mode are respectively subjected to one-hot encoding to obtain the corresponding current location type code, current vehicle type code, current parking status code, current start travel status code, current navigation mode code, and current charging mode code; and based on the preset charging power embedding encoding rules, the first charging power of the currently recorded data is embedded and encoded to obtain the corresponding current charging power code; and based on the obtained current location type code, current vehicle type code, current parking status code, current start travel status code, current navigation mode code, current charging mode code, and current charging power code, the encoding values ​​of the location type code, vehicle type code, parking status code, start travel status code, navigation mode code, charging mode code, and charging power code in the first time period encoding group corresponding to the current record in the current vehicle embedding encoding vector are reset;

[0020] Step 36: After setting all the first vehicle embedding encoding vectors corresponding to the current segmented dataset, a corresponding first vehicle embedding encoding tensor is formed by all the first vehicle embedding encoding vectors corresponding to the current segmented dataset; the current predicted load corresponding to the current segmented dataset is used as a corresponding first electricity load label; and a corresponding first data record is formed by the first vehicle embedding encoding tensor and the first electricity load label corresponding to the current segmented dataset.

[0021] Step 37: Identify whether the current segmented dataset is the last first segmented dataset; if not, take the next first segmented dataset as the new current segmented dataset and return to step 33; if yes, then the corresponding first dataset is composed of all the obtained first data records.

[0022] Preferably, the node load prediction model comprises a feature extraction network and a regression prediction network; the node load prediction model has at least two implementation methods: one based on a Transformer model and the other based on a Bi-LSTM model; when the node load prediction model is implemented based on a Transformer model, the feature extraction network and the regression prediction network are implemented based on the encoder and decoder of the Transformer model, respectively; when the node load prediction model is implemented based on a Bi-LSTM model, the feature extraction network is implemented by connecting a CNN network with linear layers, and the regression prediction network is implemented by connecting a Bi-LSTM model with an MLP network.

[0023] The feature extraction network is used to receive the vehicle embedding encoding tensor input from the model, and to perform electric vehicle power consumption feature extraction processing on the vehicle embedding encoding tensor to obtain the corresponding electric vehicle power consumption feature tensor, which is then sent to the regression prediction network; the regression prediction network is used to perform node load prediction processing based on the electric vehicle power consumption feature tensor to obtain the corresponding node load prediction and output it.

[0024] Preferably, training the node load prediction model based on the first dataset specifically includes:

[0025] Step 51: Based on a preset first segmentation ratio, the first dataset is divided into two data subsets, denoted as the first training set and the first evaluation set.

[0026] Wherein, both the first training set and the first evaluation set include multiple first data records; the ratio of the total number of records in the first training set and the first evaluation set satisfies the first segmentation ratio;

[0027] Step 52: Calculate the total number of records N in the first dataset. r Based on a preset total number of records B in a single batch, the first dataset is divided into N batches using a sliding method in a single-step sliding manner. b The first batch of records, 1 <B<N r N b =N r -B+1;

[0028] The first batch of records consists of B first data records, and the last B-1 first data records of the previous first batch of records overlap with the first B-1 first data records of the next first batch of records.

[0029] Step 53: Take the first subset of records from the first batch as the corresponding current subset;

[0030] Step 54: Input the first vehicle embedding encoding tensor of each first data record in the current subset into the node load prediction model as the corresponding vehicle embedding encoding tensor to perform node power load prediction processing, and use the node load prediction output by the model as the corresponding first power load prediction; and form a corresponding first prediction-label pair by the first power load prediction and the first power load label corresponding to each first data record in the current subset; and form a corresponding first prediction-label pair set by all the first prediction-label pairs corresponding to the current subset.

[0031] Step 55: Substitute the first prediction-label pair set corresponding to the current subset into a preset first model loss function; and modulate the model parameters of the node load prediction model in one round based on a preset first model optimizer in the direction of minimizing the first model loss function;

[0032] Wherein, the first model loss function includes at least the L1 loss function and the L2 loss function; the first model optimizer includes at least the SGD optimizer and the Adam optimizer;

[0033] Step 56: Identify whether the current subset is the last subset of the first batch of records; if not, take the next subset of the first batch of records as the new current subset and return to step 54; if yes, proceed to step 57.

[0034] Step 57: Perform a traversal of all the first data records in the first evaluation set; during this traversal, take the currently traversed first data record as the corresponding current evaluation record; input the first vehicle embedding encoding tensor of the current evaluation record as the corresponding vehicle embedding encoding tensor into the node load prediction model for node power load prediction processing, and take the node load prediction output by the model as the corresponding second power load prediction; and form a corresponding second prediction-label pair by the second power load prediction corresponding to the current evaluation record and the first power load label; at the end of this traversal, form a corresponding second prediction-label pair set by taking all the obtained second prediction-label pairs; and input the second prediction-label pair set into a preset first model evaluation function to calculate the corresponding first evaluation value;

[0035] The first model evaluation function includes at least the RMSE function;

[0036] Step 58: Identify whether the first evaluation value meets the preset first evaluation value range; if not, return to step 53 to continue training; if it meets the range, stop model training and confirm that the prediction model training is complete.

[0037] Preferably, the node load prediction model utilizes the most recent first sampling duration L within the first vehicle dataset. S The collected data is used to predict the electricity load of the first network node at the first predicted time in the future, specifically including:

[0038] Step 61: Periodically use the current time as the corresponding first sampling end time according to a preset first time frequency; and subtract the first sampling duration L from the first sampling end time. S The obtained time is used as the corresponding first sampling start time; and the first sampling start time and the first sampling end time constitute the corresponding first sampling period; and the first sampling end time is compared with the first interval duration L. A The sum of the times is taken as the corresponding first prediction time.

[0039] Step 62: Extract all the first data records in the first vehicle dataset that have a time intersection with the first collection period and the first sampling period, sort them in chronological order, and form the corresponding sampled vehicle dataset.

[0040] Step 63: Cluster the first vehicle data records with the same first vehicle identifier in the sampled vehicle dataset into one category, and sort all the first vehicle data records in the same category in chronological order to form the corresponding second single vehicle record sequence.

[0041] Step 64: Each second vehicle record sequence is taken as the corresponding current vehicle record sequence; a corresponding second vehicle embedding encoding vector is set for the current vehicle record sequence according to the vector data format of the first vehicle embedding encoding vector; the encoding values ​​of all codes in all first time point encoding groups of the current vehicle embedding encoding vector are initialized to 0; a correspondence is established between each first vehicle data record in the current vehicle record sequence and a first time period encoding group within the current vehicle embedding encoding vector according to the time period correspondence; a traversal is performed on all first vehicle data records in the current vehicle record sequence; during this traversal, the currently traversed first vehicle data record is taken as the corresponding current record; and one-hot encoding is performed on the first location type, first vehicle type, first parking status, first starting travel status, first navigation mode, and first charging mode of the current record to obtain the corresponding... The system generates the following codes: current location type code, current vehicle type code, current parking status code, current starting travel status code, current navigation mode code, and current charging mode code. Based on a preset charging power embedding code rule, the system embeds and encodes the first charging power of the currently recorded data to obtain the corresponding current charging power code. Based on the obtained current location type code, current vehicle type code, current parking status code, current starting travel status code, current navigation mode code, current charging mode code, and current charging power code, the system resets the encoding values ​​of the location type code, vehicle type code, parking status code, starting travel status code, navigation mode code, charging mode code, and charging power code in the first time period encoding group corresponding to the current record in the current vehicle embedding encoding vector. At the end of this round of traversal, all the second vehicle embedding encoding vectors corresponding to the sampled vehicle dataset are combined to form a corresponding second vehicle embedding encoding tensor.

[0042] Step 65: Input the second vehicle embedding coding tensor as the corresponding vehicle embedding coding tensor into the node load prediction model to perform node power load prediction processing, and use the node load prediction quantity output by the model as the corresponding first node load prediction quantity.

[0043] Step 66: Use the unique node identifier of the first network node as the corresponding first network node identifier; use the preset data monitoring interface of the power grid management system as the corresponding first monitoring interface; and use the first network node identifier, the first prediction time, and the first node load prediction amount to form a corresponding first node prediction record; and send the first node prediction record to the power grid management system through the first monitoring interface.

[0044] This invention provides a method for predicting node load based on electric vehicle data. As described above, this invention collects vehicle datasets by 24 / 7 data collection from all electric vehicles operating within the power supply area of ​​a network node, and collects node datasets by 24 / 7 data collection from the power load of the network node. A model training dataset, designated as the first dataset, is constructed based on the vehicle and node datasets. A node load prediction model, used to predict node power load based on the vehicle embedding encoding tensor input to the model, is trained on the first dataset. After model training, the node load prediction model is used to predict the power load of the network node at a specified future time based on the recently collected data within the vehicle dataset. This invention solves the technical problem of how to predict node load based on electric vehicle data. Attached Figure Description

[0045] Figure 1 A schematic diagram of a method for predicting node load based on electric vehicle data provided in an embodiment of the present invention;

[0046] Figure 2 This is a schematic diagram of the data structure of the first vehicle dataset, the first node dataset, and the first segment dataset provided in an embodiment of the present invention;

[0047] Figure 3 This is a schematic diagram of the module of the node load prediction model provided in an embodiment of the present invention. Detailed Implementation

[0048] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are merely some embodiments of this invention, and not all embodiments. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this invention.

[0049] This invention provides a method for predicting node load based on electric vehicle data for intelligent terminals or systems on the network node, distribution substation, or smart grid side. This method is as follows: Figure 1The schematic diagram of a method for predicting node load based on electric vehicle data provided in an embodiment of the present invention mainly includes the following steps:

[0050] Step 1: Record the power supply area of ​​the first network node as the corresponding first area; collect all electric vehicles traveling in the first area around the clock to obtain the corresponding first vehicle dataset; and collect all power load of the first network node around the clock to obtain the corresponding first node dataset.

[0051] Here, as Figure 2 The data structure diagram of the first vehicle dataset, first node dataset, and first segment dataset provided in this embodiment of the invention is shown. The first vehicle dataset in this embodiment includes multiple first vehicle data records. The first vehicle data record includes a first collection period, a first vehicle identifier, a first location type, a first vehicle type, a first parking status, a first start travel status, a first navigation mode, a first charging mode, and a first charging level. The first collection period includes a first period start time and a first period end time, and the period length between the first period start time and the first period end time is fixed and denoted as the first period length ΔL1. The first vehicle identifier is a unique identifier for the corresponding electric vehicle. The first location type is used to mark the location type of the corresponding electric vehicle in the current period, and the first location type includes commercial venues. The system includes: locations, residential areas, and roads; the first vehicle type includes private cars and commercial vehicles; the first parking status is used to mark the parking status of the corresponding electric vehicle in the current time period, including yes and no; the first starting trip status is used to mark whether the corresponding electric vehicle is in the starting trip period in the current time period, including yes and no; the first navigation mode is used to mark the navigation mode used by the corresponding electric vehicle in the current time period, including the shortest driving route navigation mode and the shortest driving time navigation mode; the first charging mode is used to mark whether the corresponding electric vehicle is in the charging state in the current time period and the corresponding charging mode, including not charging, regular charging, and fast charging; the first charging amount is the total charging amount of the corresponding electric vehicle in the current time period, and the first charging amount is 0 when the first charging mode is not charging.

[0052] like Figure 2 As shown, the first node dataset of this embodiment includes multiple first node data records; the first node data records include a second collection period and the total load of the first node; the second collection period includes the start time of the second period and the end time of the second period, the length of the period between the start time of the second period and the end time of the second period is fixed and denoted as the second period length △L2, the second period length △L2 is N times the first period length △L1, and N is a preset positive integer; the total load of the first node is the total power load of the first network node in the current second collection period.

[0053] Step 2, set the data sampling duration to the first sampling duration L. S And set the prediction interval to the first interval length L; A Based on the first vehicle dataset, the first node dataset, and the first sampling duration L S and the first interval duration L A The dataset used to build the model training dataset is denoted as the first dataset.

[0054] Specifically, this includes: Step 21, setting the data sampling duration to the first sampling duration L. S And set the prediction interval to the first interval length L; A ;

[0055] Here, the first sampling duration L in this embodiment of the invention S It is an integer multiple of the length of the first time period △L1; the first interval duration L in this embodiment of the invention A Under normal circumstances, it is assumed to be an integer multiple of the second time period length △L2;

[0056] Step 22, based on the first vehicle dataset, the first node dataset, and the first sampling duration L S and the first interval duration L A The dataset used to build the model training dataset is denoted as the first dataset.

[0057] The first dataset includes multiple first data records; each first data record includes a first vehicle embedding encoding tensor and a first electricity load label; the first vehicle embedding encoding tensor consists of multiple first vehicle embedding encoding vectors; each first vehicle embedding encoding vector corresponds to one electric vehicle; all first vehicle embedding encoding vectors have the same vector length M, where M = L. S / △L1; The first vehicle embedding encoding vector is composed of M first time period encoding groups sorted in chronological order; each first time period encoding group corresponds to a first vehicle data record; the first time period encoding group includes location type encoding, vehicle type encoding, parking status encoding, start trip status encoding, navigation mode encoding, charging mode encoding, and charging power encoding;

[0058] Specifically, this includes: Step 221, according to the first sampling duration L S The first vehicle dataset is sequentially segmented to obtain multiple corresponding first segment datasets;

[0059] Among them, such as Figure 2 As shown, each first segment dataset consists of multiple first vehicle data records; and the time span of each first segment dataset is the first sampling duration L. S ;

[0060] Step 222: Take the first first segment dataset as the corresponding current segment dataset;

[0061] Step 223: Take the segment end time of the current segmented dataset as the corresponding current end time; and divide the current end time by the first interval duration L. A The sum of the times is used as the corresponding current predicted time; and the total load of the first node data record corresponding to the second collection period whose start time of the second period is closest to the current predicted time is used as the corresponding current predicted load.

[0062] Step 224: Cluster the first vehicle data records with the same first vehicle identifier in the current segmented dataset into one class, and sort all the first vehicle data records in the same class according to the chronological order to form the corresponding first single vehicle record sequence.

[0063] Step 225: Each first vehicle record sequence is used as the corresponding current vehicle record sequence; a corresponding first vehicle embedding encoding vector is set for the current vehicle record sequence according to the vector data format of the first vehicle embedding encoding vector; the encoding values ​​of all codes in all first time point encoding groups of the current vehicle embedding encoding vector are initialized to 0; a correspondence is established between each first vehicle data record in the current vehicle record sequence and a first time period encoding group within the current vehicle embedding encoding vector according to the time period correspondence; a traversal is performed on all first vehicle data records in the current vehicle record sequence; during this traversal, the currently traversed first vehicle data record is used as the corresponding current record; and the first location type, first vehicle type, first parking status, and first starting travel status of the current record are set. The current location type code, current vehicle type code, current parking status code, current start travel status code, current navigation mode code, and current charging mode code are obtained by performing one-hot encoding on the current location, current navigation mode, and current charging mode respectively. Based on the preset charging power embedding encoding rules, the first charging power of the current record is embedded and encoded to obtain the corresponding current charging power code. Based on the obtained current location type code, current vehicle type code, current parking status code, current start travel status code, current navigation mode code, current charging mode code, and current charging power code, the encoding values ​​of the location type code, vehicle type code, parking status code, start travel status code, navigation mode code, charging mode code, and charging power code of the first time period encoding group corresponding to the current record in the current vehicle embedding encoding vector are reset.

[0064] Here, the charging power embedding encoding rules can be customized based on application requirements. By default, a normalized embedding encoding method can be used for encoding, such as normalizing all charging power by taking the node's rated load as the maximum load.

[0065] Step 226: After setting all the first vehicle embedding encoding vectors corresponding to the current segment dataset, a corresponding first vehicle embedding encoding tensor is formed by all the first vehicle embedding encoding vectors corresponding to the current segment dataset; the current predicted load corresponding to the current segment dataset is used as a corresponding first electricity load label; and a corresponding first data record is formed by the first vehicle embedding encoding tensor and the first electricity load label corresponding to the current segment dataset.

[0066] Step 227: Identify whether the current segmented dataset is the last first segmented dataset; if not, use the next first segmented dataset as the new current segmented dataset and return to step 223; if yes, the corresponding first dataset is composed of all the obtained first data records.

[0067] Step 3: Construct a node load prediction model; and train the node load prediction model based on the first dataset;

[0068] Specifically, this includes: Step 31, constructing a node load prediction model;

[0069] Here, the node load prediction model of this embodiment of the invention is used to perform node power load prediction processing based on the vehicle embedding encoding tensor input to the model and output the corresponding node load prediction; such as Figure 3 The schematic diagram of the node load prediction model provided in the embodiment of the present invention is shown. The node load prediction model consists of a feature extraction network and a regression prediction network.

[0070] It should be noted that the node load prediction model in this embodiment of the invention has at least two implementation methods: one based on the Transformer model and the other based on the Bi-LSTM model. When the node load prediction model is implemented based on the Transformer model, the feature extraction network and the regression prediction network are implemented based on the encoder and decoder of the Transformer model, respectively. When the node load prediction model is implemented based on the Bi-LSTM model, the feature extraction network is implemented by connecting a CNN network with a linear layer, and the regression prediction network is implemented by connecting a Bi-LSTM model with an MLP network.

[0071] It should also be noted that the feature extraction network of the node load prediction model is used to receive the vehicle embedding encoding tensor as input to the model, and to perform electric vehicle power consumption feature extraction processing on the vehicle embedding encoding tensor to obtain the corresponding electric vehicle power consumption feature tensor, which is then sent to the regression prediction network; the regression prediction network of the node load prediction model is used to perform node load prediction processing based on the electric vehicle power consumption feature tensor to obtain the corresponding node load prediction and output it.

[0072] Step 32, and train the node load prediction model based on the first dataset;

[0073] Specifically, it includes: step 321, dividing the first dataset into two data subsets based on a preset first segmentation ratio, denoted as the corresponding first training set and first evaluation set;

[0074] Here, the first segmentation ratio is a pre-set ratio parameter, such as 9:1; both the first training set and the first evaluation set include multiple first data records; the ratio of the total number of records in the first training set and the first evaluation set satisfies the first segmentation ratio;

[0075] Step 322: Calculate the total number of records N in the first dataset. r Based on the preset total number of records B in a single batch, the first dataset is divided into N batches using a sliding method in a single-step sliding manner. b A first batch of records subset;

[0076] Here, the total number of records in a single batch, B, is a pre-set positive integer, 1. <B<N r Total number of batches N b =N r -B+1; Each first batch of records consists of B first data records, and the last B-1 first data records of the previous first batch of records overlap with the first B-1 first data records of the next first batch of records.

[0077] Step 323: Take the first batch of records subset as the corresponding current subset;

[0078] Step 324: Input the first vehicle embedding coding tensor of each first data record in the current subset into the node load prediction model as the corresponding vehicle embedding coding tensor to perform node power load prediction processing, and use the node load prediction quantity output by the model as the corresponding first power load prediction quantity; and form a corresponding first prediction-label pair by the first power load prediction quantity and the first power load label quantity corresponding to each first data record in the current subset; and form a corresponding first prediction-label pair set by all the first prediction-label pairs corresponding to the current subset.

[0079] Step 325: Substitute the first prediction-label pair set corresponding to the current subset into the preset first model loss function; and based on the preset first model optimizer, perform a round of modulation on the model parameters of the node load prediction model in the direction of minimizing the first model loss function;

[0080] The first model loss function includes at least the L1 loss function and the L2 loss function; the first model optimizer includes at least the SGD optimizer and the Adam optimizer.

[0081] Step 326: Identify whether the current subset is the last first batch of record subsets; if not, take the next first batch of record subsets as the new current subset and return to step 324; if yes, proceed to step 327.

[0082] Step 327: Perform a traversal of all first data records in the first evaluation set; during this traversal, take the currently traversed first data record as the corresponding current evaluation record; input the first vehicle embedding encoding tensor of the current evaluation record into the node load prediction model as the corresponding vehicle embedding encoding tensor for node power load prediction processing, and take the node load prediction output by the model as the corresponding second power load prediction; and form a corresponding second prediction-label pair by the second power load prediction and the first power load label of the current evaluation record; at the end of this traversal, form a corresponding second prediction-label pair set by taking all the obtained second prediction-label pairs; and input the second prediction-label pair set into the preset first model evaluation function to calculate the corresponding first evaluation value.

[0083] The first model evaluation function includes at least the RMSE function;

[0084] Step 328: Identify whether the first evaluation value meets the preset first evaluation value range; if not, return to step 323 to continue training; if it meets the range, stop model training and confirm that the prediction model training is complete.

[0085] Here, the first evaluation value range is a pre-set numerical range.

[0086] Step 4: After model training is complete, the node load prediction model is used based on the most recent first sampling time L in the first vehicle dataset. S The collected data is used to predict the power load of the first network node at the first predicted time in the future;

[0087] Wherein, the time interval between the first prediction time and the current time is the first interval duration L. A ;

[0088] Specifically, this includes: Step 41, periodically using the current time as the corresponding first sampling end time according to a preset first time frequency; and subtracting the first sampling duration L from the first sampling end time. S The obtained time is used as the corresponding first sampling start time; and the first sampling start time and the first sampling end time constitute the corresponding first sampling period; and the first sampling end time is combined with the first interval duration L. A The sum of the times is used as the corresponding first prediction time.

[0089] Here, the first time frequency is a preset frequency parameter;

[0090] Step 42: Extract all the first data records in the first vehicle dataset that have a time intersection with the first collection period and the first sampling period, sort them in chronological order, and form the corresponding sampled vehicle dataset.

[0091] Step 43: Cluster the first vehicle data records with the same first vehicle identifier in the sampled vehicle dataset into one class, and sort all the first vehicle data records in the same class according to the chronological order to form the corresponding second single vehicle record sequence.

[0092] Step 44: Each second vehicle record sequence is used as the corresponding current vehicle record sequence; a corresponding second vehicle embedding encoding vector is set for the current vehicle record sequence according to the vector data format of the first vehicle embedding encoding vector; the encoding values ​​of all codes in all first time point encoding groups of the current vehicle embedding encoding vector are initialized to 0; a correspondence is established between each first vehicle data record in the current vehicle record sequence and a first time period encoding group within the current vehicle embedding encoding vector according to the time period correspondence; a traversal is performed on all first vehicle data records in the current vehicle record sequence; during this traversal, the currently traversed first vehicle data record is used as the corresponding current record; and one-hot encoding is performed on the first location type, first vehicle type, first parking status, first starting travel status, first navigation mode, and first charging mode of the current record to obtain... The system generates the corresponding current location type code, current vehicle type code, current parking status code, current start travel status code, current navigation mode code, and current charging mode code. Based on the charging power embedding encoding rules, it embeds and encodes the first charging power of the current record to obtain the corresponding current charging power code. Based on the obtained current location type code, current vehicle type code, current parking status code, current start travel status code, current navigation mode code, current charging mode code, and current charging power code, it resets the encoding values ​​of the location type code, vehicle type code, parking status code, start travel status code, navigation mode code, charging mode code, and charging power code of the first time period encoding group corresponding to the current record in the current vehicle embedding encoding vector. At the end of this round of traversal, a corresponding second vehicle embedding encoding tensor is formed by all the second vehicle embedding encoding vectors corresponding to the sampled vehicle dataset.

[0093] Step 45: Input the second vehicle embedding coding tensor as the corresponding vehicle embedding coding tensor into the node load prediction model to perform node power load prediction processing, and use the node load prediction output by the model as the corresponding first node load prediction.

[0094] Step 46: Use the unique node identifier of the first network node as the corresponding first network node identifier; use the preset data monitoring interface of the power grid management system as the corresponding first monitoring interface; and use the first network node identifier, the first prediction time and the first node load prediction amount to form the corresponding first node prediction record; and send the first node prediction record to the power grid management system through the first monitoring interface.

[0095] The above description of the embodiments of the present invention demonstrates how to predict the node load at a future moment based on the collected data of a time period. It should also be noted that if the collected data of multiple consecutive time periods are used based on the method of the embodiments of the present invention, the node load at multiple moments within a future time period can be predicted. Then, curve fitting of the predicted values ​​at multiple consecutive moments can obtain the node load prediction curve for a future time period.

[0096] In summary, this invention provides a method for predicting node load based on electric vehicle data. As described above, this invention collects data from all electric vehicles operating within the power supply area of ​​a network node to obtain a vehicle dataset, and collects data from the power load of the network node to obtain a node dataset. A model training dataset, designated as the first dataset, is constructed based on the vehicle and node datasets. A node load prediction model, used to predict node power load based on the vehicle embedding encoding tensor input to the model, is trained based on the first dataset. After model training, the node load prediction model is used to predict the power load of the network node at a future specified time based on the recently collected data within the vehicle dataset. This invention solves the technical problem of how to predict node load based on electric vehicle data, and it helps to refine the granularity of dynamic control of the smart grid at the node level.

[0097] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.

[0098] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented in hardware, a software module executed by a processor, or a combination of both. The software module can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

[0099] The specific embodiments described above further illustrate the purpose, technical solution, and beneficial effects of the present invention. It should be understood that the above description is only a specific embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A method for processing node load prediction based on electric vehicle data, characterized in that, The method includes: The power supply area of ​​the first network node is recorded as the corresponding first area; and all electric vehicles traveling in the first area are collected around the clock to obtain the corresponding first vehicle dataset; and the power load of the first network node is collected around the clock to obtain the corresponding first node dataset. Set the data sampling duration to the first sampling duration L. S And set the prediction interval to the first interval length L; A Based on the first vehicle dataset, the first node dataset, and the first sampling duration L S and the first interval duration L A The dataset used to build the model training dataset is denoted as the first dataset. A node load prediction model is constructed; and the node load prediction model is trained based on the first dataset; the node load prediction model is used to perform node power load prediction processing based on the vehicle embedding encoding tensor input to the model and output the corresponding node load prediction amount; After the model training is completed, the node load prediction model is used to predict the load based on the most recent sampling time L in the first vehicle dataset. S The collected data is used to predict the power load of the first network node at a future first predicted time; the interval between the first predicted time and the current time is the first interval length L. A ; The first vehicle dataset includes multiple first vehicle data records; each first vehicle data record includes a first collection period, a first vehicle identifier, a first location type, a first vehicle type, a first parking status, a first start-up status, a first navigation mode, a first charging mode, and a first charging level; the first collection period includes a first period start time and a first period end time, with the period length between the first period start time and the first period end time fixed as the first period length ΔL1; the first vehicle identifier is a unique identifier for the corresponding electric vehicle; the first location type is used to mark the location type of the corresponding electric vehicle in the current period, and the first location type includes commercial locations, residential areas, and roads; the first vehicle type includes private cars and commercial vehicles. The first parking status is used to mark the parking status of the corresponding electric vehicle in the current time period, and the first parking status includes yes and no; the first starting trip status is used to mark whether the corresponding electric vehicle is in the trip starting time period in the current time period, and the first starting trip status includes yes and no; the first navigation mode is used to mark the navigation mode adopted by the corresponding electric vehicle in the current time period, and the first navigation mode includes the shortest driving route navigation mode and the shortest driving time navigation mode; the first charging mode is used to mark whether the corresponding electric vehicle is in the charging state in the current time period and the corresponding charging mode, and the first charging mode includes not charging, regular charging and fast charging; the first charging amount is the total charging amount of the corresponding electric vehicle in the current time period, and the first charging amount is 0 when the first charging mode is not charging. The first node dataset includes multiple first node data records; the first node data records include a second collection period and the total load of the first node; the second collection period includes the start time and end time of the second period, the length of the period between the start time and end time of the second period is fixed and denoted as the second period length △L2, the second period length △L2 is N times the first period length △L1, and N is a preset positive integer; the total load of the first node is the total power load of the first network node in the current second collection period; The first sampling duration L S It is an integer multiple of the length △L1 of the first time period; The first dataset includes multiple first data records; each first data record includes a first vehicle embedding encoding tensor and a first electricity load label; the first vehicle embedding encoding tensor is composed of multiple first vehicle embedding encoding vectors; each first vehicle embedding encoding vector corresponds to an electric vehicle; all first vehicle embedding encoding vectors have the same vector length M, where M=L. S / △L1; The first vehicle embedding encoding vector is composed of M first time period encoding groups arranged in chronological order; each first time period encoding group corresponds to a first vehicle data record; the first time period encoding group includes location type encoding, vehicle type encoding, parking status encoding, start travel status encoding, navigation mode encoding, charging mode encoding, and charging power encoding.

2. The method for processing node load prediction based on electric vehicle data according to claim 1, characterized in that, The first vehicle dataset, the first node dataset, and the first sampling duration L are used as the basis for the above. S and the first interval duration L A The dataset used to build the model training dataset is denoted as the first dataset, and it specifically includes: Step 31, according to the first sampling duration L S The first vehicle dataset is sequentially segmented to obtain multiple corresponding first segment datasets; Each of the first segment datasets consists of multiple first vehicle data records; and the time span of each first segment dataset is the first sampling duration L. S ; Step 32: Take the first first segment dataset as the corresponding current segment dataset; Step 33: Take the segment end time of the current segmented dataset as the corresponding current end time; and divide the current end time by the first interval duration L. A The sums are used to obtain the corresponding current predicted time; and the total load of the first node data record corresponding to the second collection period whose start time of the second period is closest to the current predicted time is used as the corresponding current predicted load. Step 34: Cluster the first vehicle data records with the same first vehicle identifier in the current segmented dataset into one class, and sort all the first vehicle data records in the same class according to the chronological order to form the corresponding first single vehicle record sequence. Step 35: Each of the first single-vehicle record sequences is taken as the corresponding current single-vehicle record sequence; and a corresponding first vehicle embedding encoding vector is set for the current single-vehicle record sequence according to the vector data format of the first vehicle embedding encoding vector; the encoding values ​​of all codes in all first time period encoding groups of the current vehicle embedding encoding vector are initialized to 0; and a correspondence is established between each of the first vehicle data records in the current single-vehicle record sequence and a first time period encoding group in the current vehicle embedding encoding vector according to the time period correspondence; and a traversal is performed on all the first vehicle data records in the current single-vehicle record sequence; and during this traversal, the currently traversed first vehicle data record is taken as the corresponding current record; and the first location type, first vehicle type, first parking status, first starting travel status, and the first... The navigation mode and the first charging mode are respectively subjected to one-hot encoding to obtain the corresponding current location type code, current vehicle type code, current parking status code, current start travel status code, current navigation mode code, and current charging mode code; and based on the preset charging power embedding encoding rules, the first charging power of the currently recorded data is embedded and encoded to obtain the corresponding current charging power code; and based on the obtained current location type code, current vehicle type code, current parking status code, current start travel status code, current navigation mode code, current charging mode code, and current charging power code, the encoding values ​​of the location type code, vehicle type code, parking status code, start travel status code, navigation mode code, charging mode code, and charging power code in the first time period encoding group corresponding to the current record in the current vehicle embedding encoding vector are reset; Step 36: After setting all the first vehicle embedding encoding vectors corresponding to the current segmented dataset, a corresponding first vehicle embedding encoding tensor is formed by all the first vehicle embedding encoding vectors corresponding to the current segmented dataset; the current predicted load corresponding to the current segmented dataset is used as a corresponding first electricity load label; and a corresponding first data record is formed by the first vehicle embedding encoding tensor and the first electricity load label corresponding to the current segmented dataset. Step 37: Identify whether the current segmented dataset is the last first segmented dataset; if not, take the next first segmented dataset as the new current segmented dataset and return to step 33; if yes, then the corresponding first dataset is composed of all the obtained first data records.

3. The method for processing node load prediction based on electric vehicle data according to claim 1, characterized in that, The node load prediction model comprises a feature extraction network and a regression prediction network. The model has at least two implementation methods: one based on a Transformer model and the other based on a Bi-LSTM model. When implemented using a Transformer model, the feature extraction network and the regression prediction network are implemented using the encoder and decoder of the Transformer model, respectively. When implemented using a Bi-LSTM model, the feature extraction network is implemented by connecting a CNN network with linear layers, and the regression prediction network is implemented by connecting a Bi-LSTM model with an MLP network. The feature extraction network is used to receive the vehicle embedding encoding tensor input from the model, and to perform electric vehicle power consumption feature extraction processing on the vehicle embedding encoding tensor to obtain the corresponding electric vehicle power consumption feature tensor, which is then sent to the regression prediction network; the regression prediction network is used to perform node load prediction processing based on the electric vehicle power consumption feature tensor to obtain the corresponding node load prediction and output it.

4. The method for processing node load prediction based on electric vehicle data according to claim 1, characterized in that, The training of the node load prediction model based on the first dataset specifically includes: Step 51: Based on a preset first segmentation ratio, the first dataset is divided into two data subsets, denoted as the first training set and the first evaluation set. Wherein, both the first training set and the first evaluation set include multiple first data records; the ratio of the total number of records in the first training set and the first evaluation set satisfies the first segmentation ratio; Step 52: Calculate the total number of records N in the first dataset. r Based on a preset total number of records B in a single batch, the first dataset is divided into N batches using a sliding method in a single-step sliding manner. b The first batch of records, 1 <B<N r N b =N r -B+1; The first batch of records consists of B first data records, and the last B-1 first data records of the previous first batch of records overlap with the first B-1 first data records of the next first batch of records. Step 53: Take the first subset of records from the first batch as the corresponding current subset; Step 54: Input the first vehicle embedding encoding tensor of each first data record in the current subset into the node load prediction model as the corresponding vehicle embedding encoding tensor to perform node power load prediction processing, and use the node load prediction output by the model as the corresponding first power load prediction; and form a corresponding first prediction-label pair by the first power load prediction and the first power load label corresponding to each first data record in the current subset; and form a corresponding first prediction-label pair set by all the first prediction-label pairs corresponding to the current subset. Step 55: Substitute the first prediction-label pair set corresponding to the current subset into a preset first model loss function; and modulate the model parameters of the node load prediction model in one round based on a preset first model optimizer in the direction of minimizing the first model loss function; Wherein, the first model loss function includes at least the L1 loss function and the L2 loss function; the first model optimizer includes at least the SGD optimizer and the Adam optimizer; Step 56: Identify whether the current subset is the last subset of the first batch of records; if not, take the next subset of the first batch of records as the new current subset and return to step 54; if yes, proceed to step 57. Step 57: Perform a traversal of all the first data records in the first evaluation set; during this traversal, take the currently traversed first data record as the corresponding current evaluation record; input the first vehicle embedding encoding tensor of the current evaluation record as the corresponding vehicle embedding encoding tensor into the node load prediction model for node power load prediction processing, and take the node load prediction output by the model as the corresponding second power load prediction; and form a corresponding second prediction-label pair by the second power load prediction corresponding to the current evaluation record and the first power load label; at the end of this traversal, form a corresponding second prediction-label pair set by taking all the obtained second prediction-label pairs; and input the second prediction-label pair set into a preset first model evaluation function to calculate the corresponding first evaluation value; The first model evaluation function includes at least the RMSE function; Step 58: Identify whether the first evaluation value meets the preset first evaluation value range; if not, return to step 53 to continue training; if it meets the range, stop model training and confirm that the prediction model training is complete.

5. The method for processing node load prediction based on electric vehicle data according to claim 1, characterized in that, The node load prediction model is used based on the most recent first sampling duration L in the first vehicle dataset. S The collected data is used to predict the electricity load of the first network node at the first predicted time in the future, specifically including: Step 61: Periodically use the current time as the corresponding first sampling end time according to a preset first time frequency; and subtract the first sampling duration L from the first sampling end time. S The obtained time is used as the corresponding first sampling start time; and the first sampling start time and the first sampling end time constitute the corresponding first sampling period; and the first sampling end time is compared with the first interval duration L. A The sum of the times is taken as the corresponding first prediction time. Step 62: Extract all the first data records in the first vehicle dataset that have a time intersection with the first collection period and the first sampling period, sort them in chronological order, and form the corresponding sampled vehicle dataset. Step 63: Cluster the first vehicle data records with the same first vehicle identifier in the sampled vehicle dataset into one category, and sort all the first vehicle data records in the same category in chronological order to form the corresponding second single vehicle record sequence. Step 64: Each second vehicle record sequence is taken as the corresponding current vehicle record sequence; a corresponding second vehicle embedding encoding vector is set for the current vehicle record sequence according to the vector data format of the first vehicle embedding encoding vector; the encoding values ​​of all codes in all first time period encoding groups of the current vehicle embedding encoding vector are initialized to 0; a correspondence is established between each first vehicle data record in the current vehicle record sequence and a first time period encoding group in the current vehicle embedding encoding vector according to the time period correspondence; a traversal is performed on all first vehicle data records in the current vehicle record sequence; during this traversal, the currently traversed first vehicle data record is taken as the corresponding current record; and one-hot encoding is performed on the first location type, first vehicle type, first parking status, first starting travel status, first navigation mode, and first charging mode of the current record to obtain the corresponding current record. The system generates the following codes: current location type code, current vehicle type code, current parking status code, current starting travel status code, current navigation mode code, and current charging mode code. Based on a preset charging power embedding encoding rule, the system embeds and encodes the first charging power of the currently recorded data to obtain the corresponding current charging power code. Based on the obtained current location type code, current vehicle type code, current parking status code, current starting travel status code, current navigation mode code, current charging mode code, and current charging power code, the encoding values ​​of the location type code, vehicle type code, parking status code, starting travel status code, navigation mode code, charging mode code, and charging power code in the first time period encoding group corresponding to the current record in the current vehicle embedding encoding vector are reset. At the end of this round of traversal, all the second vehicle embedding encoding vectors corresponding to the sampled vehicle dataset are combined to form a corresponding second vehicle embedding encoding tensor. Step 65: Input the second vehicle embedding coding tensor as the corresponding vehicle embedding coding tensor into the node load prediction model to perform node power load prediction processing, and use the node load prediction quantity output by the model as the corresponding first node load prediction quantity. Step 66: Use the unique node identifier of the first network node as the corresponding first network node identifier; use the preset data monitoring interface of the power grid management system as the corresponding first monitoring interface; and use the first network node identifier, the first prediction time, and the first node load prediction amount to form a corresponding first node prediction record; and send the first node prediction record to the power grid management system through the first monitoring interface.

Citation Information

Patent Citations

  • Power grid dispatching method based on intra-regional electric vehicle charging load prediction

    CN112036624A

  • Electric vehicle charging station load prediction method, device and equipment based on graph neural network

    CN118941050A