A method and device for predicting charging demand of electric vehicle
By constructing a hypergraph model and a support vector machine model, combined with multi-dimensional charging data, the problem of low accuracy of charging demand prediction in the existing technology is solved, and high-accuracy prediction of electric vehicle charging demand is achieved, helping to rationally plan charging infrastructure. .
Patent Information
- Application Number
- CN202410774552.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-17
- Publication Date
- 2024-09-10
- Estimated Expiration
- 2044-06-17
AI Technical Summary
When predicting the charging demand of electric vehicles, the existing technology ignores the complex interaction of multiple factors such as charging time, location, user behavior patterns, etc., resulting in low accuracy of prediction results and failure to fully reflect the dynamic changes in actual charging demand.
Multi-dimensional charging data sets are used for preprocessing, a hypergraph model is constructed and hypergraph feature vectors are extracted, and the pre-trained support vector machine model is used to predict charging demand, and the accuracy of the model is improved through parameter optimization.
It greatly improves the accuracy of predicting dynamic changes in electric vehicle charging demand, expands the scope of applications, and helps to rationally plan charging infrastructure and avoid resource waste.
Smart Images

Figure CN118365176B
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a method and device for predicting charging demand of electric vehicles. Background Art
[0002] At present, with the transformation of the global energy structure and the enhancement of environmental awareness, electric vehicles, as an important alternative to traditional fuel vehicles, have a rapidly growing market. The widespread use of electric vehicles not only reduces dependence on fossil fuels, but also helps reduce the impact of transportation on the environment. Existing technologies usually predict the charging demand for the next period based on the number of electric vehicles and the charging and discharging power in the electric vehicle charging station in the previous period; however, in practice, it is found that due to the high dynamics and complexity of electric vehicle charging conditions, existing technologies often ignore the complex multidimensional relationship between charging demands, such as the interaction of multiple factors such as charging time, location, and user behavior patterns, resulting in the prediction results being unable to fully reflect the dynamic changes in actual charging demand. It can be seen that the existing methods have low accuracy, limited application scope, and cannot fully reflect the dynamic changes in actual charging demand. Summary of the invention
[0003] The purpose of the embodiments of the present application is to provide a method and device for predicting electric vehicle charging demand, which can predict charging demand based on multi-dimensional charging data, greatly improve the accuracy of predicting dynamic changes in electric vehicle charging demand, expand the scope of application, and help to rationally plan charging infrastructure and avoid waste of resources.
[0004] The first aspect of the present application provides a method for predicting charging demand of an electric vehicle, comprising:
[0005] Collect multi-dimensional charging datasets for electric vehicles;
[0006] Preprocessing the multidimensional charging data set to obtain a preprocessed data set;
[0007] Constructing a hypergraph model based on the preprocessed data set;
[0008] Extracting a hypergraph feature vector based on the hypergraph model;
[0009] The charging demand is predicted by using a pre-trained support vector machine model and the hypergraph feature vector to obtain a prediction result;
[0010] Analyzing the prediction result to obtain an analysis result;
[0011] Optimize the parameters of the support vector machine model and the hypergraph model according to the analysis results to obtain a target hypergraph model and a target support vector machine model;
[0012] Determining whether the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target according to the analysis result;
[0013] If yes, charging demand prediction is performed according to the target hypergraph model and the target support vector machine model to obtain a charging demand prediction result.
[0014] In the above implementation process, the method can train and use a suitable hypergraph model and support vector machine, thereby greatly improving the accuracy of predicting the dynamic changes in electric vehicle charging demand.
[0015] Furthermore, the multidimensional charging data set includes at least charging time, charging location, user charging behavior patterns, historical charging data, electric vehicle type, electric vehicle battery capacity, user charging preference data, data on the impact of weather conditions on charging behavior, data on the impact of holidays on charging demand, data on the impact of special events on charging demand, and data on the impact of grid load conditions and charging price fluctuations on user charging choices.
[0016] Furthermore, the preprocessing of the multidimensional charging data set to obtain a preprocessed data set includes:
[0017] Performing outlier removal processing on the multidimensional charging data set to obtain a first processed data set;
[0018] performing standardization processing on the first processed data set to obtain a second processed data set;
[0019] The second processed data set is normalized to obtain a preprocessed data set.
[0020] Furthermore, constructing a hypergraph model according to the preprocessed data set includes:
[0021] Based on the definition of the preprocessed data set and the preset hypergraph model, an original hypergraph model is constructed; wherein each node in the original hypergraph model corresponds to a user sample in the preprocessed data set;
[0022] Based on the preprocessed data set, calculating the many-to-many relationship between each user; wherein the many-to-many relationship at least includes the similarity of common charging time period, the similarity of location proximity, and the similarity of charging behavior;
[0023] Constructing a hyperedge of the original hypergraph model based on the many-to-many relationship between each user;
[0024] According to a preset weight factor and the many-to-many relationship, assign a corresponding weight to each of the hyperedges;
[0025] A hypergraph model is constructed based on the original hypergraph model, the hyperedges and the weights.
[0026] Furthermore, extracting a hypergraph feature vector based on the hypergraph model includes:
[0027] Based on the hypergraph model, the number of hyperedges associated with the node, the average degree of neighboring nodes corresponding to the node, the average node degree of the hypergraph, and the density of the hypergraph are calculated;
[0028] Determining a node degree according to the number of hyperedges;
[0029] Determining a hyperedge weight according to the weight;
[0030] Determine the local structural feature according to the average degree of the neighboring nodes corresponding to the node;
[0031] Determining global structural features according to an average node degree of the hypergraph and a density of the hypergraph;
[0032] A hypergraph feature vector is constructed based on the node degree, the hyperedge weight, the local structural feature and the global structural feature.
[0033] Furthermore, the charging demand prediction is performed by using the pre-trained support vector machine model and the hypergraph feature vector to obtain a prediction result, including:
[0034] Constructing an original support vector machine model according to a preset radial basis function and preset parameters;
[0035] Acquire feature vector samples for training the original support vector machine model;
[0036] The original support vector machine model is trained by using the feature vector samples to obtain a trained support vector machine model;
[0037] The hypergraph feature vector is input into the support vector machine model to predict charging demand and obtain a prediction result; wherein the prediction result includes the future usage frequency of the charging station, the charging time period requirement and the regional charging demand.
[0038] Furthermore, the method further comprises:
[0039] When it is determined according to the analysis result that the accuracy of the target hypergraph model and the target support vector machine model does not reach the preset optimization target, the step of extracting the hypergraph feature vector based on the hypergraph model is performed.
[0040] A second aspect of the present application provides an electric vehicle charging demand prediction device, the electric vehicle charging demand prediction device comprising:
[0041] A collection unit, used for collecting a multi-dimensional charging data set of an electric vehicle;
[0042] A preprocessing unit, used for preprocessing the multi-dimensional charging data set to obtain a preprocessed data set;
[0043] A model building unit, used for building a hypergraph model according to the preprocessed data set;
[0044] A feature extraction unit, configured to extract a hypergraph feature vector based on the hypergraph model;
[0045] A prediction unit, used to predict charging demand by using a pre-trained support vector machine model and the hypergraph feature vector to obtain a prediction result;
[0046] An analysis unit, used to analyze the prediction result to obtain an analysis result;
[0047] A parameter optimization unit, used to optimize the parameters of the support vector machine model and the hypergraph model according to the analysis result to obtain a target hypergraph model and a target support vector machine model;
[0048] A judging unit, used to judge whether the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target according to the analysis result;
[0049] A determination unit is used to perform charging demand prediction based on the target hypergraph model and the target support vector machine model to obtain a charging demand prediction result when it is determined based on the analysis result that the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target.
[0050] Furthermore, the multidimensional charging data set includes at least charging time, charging location, user charging behavior patterns, historical charging data, electric vehicle type, electric vehicle battery capacity, user charging preference data, data on the impact of weather conditions on charging behavior, data on the impact of holidays on charging demand, data on the impact of special events on charging demand, and data on the impact of grid load conditions and charging price fluctuations on user charging choices.
[0051] Furthermore, the preprocessing unit comprises:
[0052] a removal processing subunit, configured to perform outlier removal processing on the multidimensional charging data set to obtain a first processed data set;
[0053] a standardization subunit, configured to perform standardization processing on the first processed data set to obtain a second processed data set;
[0054] The normalization subunit is used to perform normalization processing on the second processed data set to obtain a preprocessed data set.
[0055] Furthermore, the model building unit includes:
[0056] A first construction subunit is used to construct an original hypergraph model based on the preprocessed data set and the definition of the preset hypergraph model; wherein each node in the original hypergraph model corresponds to a user sample in the preprocessed data set;
[0057] A first calculation subunit, configured to calculate a many-to-many relationship between each user based on the preprocessed data set; wherein the many-to-many relationship includes at least a common charging time period similarity, a location proximity similarity, and a charging behavior similarity;
[0058] The first construction subunit is further used to construct the hyperedges of the original hypergraph model based on the many-to-many relationship between each user;
[0059] an allocating subunit, configured to allocate a corresponding weight to each of the hyperedges according to a preset weight factor and the many-to-many relationship;
[0060] The first construction subunit is further used to construct a hypergraph model based on the original hypergraph model, the hyperedges and the weights.
[0061] Furthermore, the feature extraction unit comprises:
[0062] A second calculation subunit is used to calculate the number of hyperedges associated with the node, the average degree of neighboring nodes corresponding to the node, the average node degree of the hypergraph, and the density of the hypergraph based on the hypergraph model;
[0063] A determination subunit, configured to determine a node degree according to the number of hyperedges;
[0064] The determining subunit is further used to determine the hyperedge weight according to the weight;
[0065] The determination subunit is further used to determine the local structural feature according to the average degree of the neighboring nodes corresponding to the node;
[0066] The determining subunit is further used to determine the global structural feature according to the average node degree of the hypergraph and the density of the hypergraph;
[0067] The second construction subunit is used to construct a hypergraph feature vector based on the node degree, the hyperedge weight, the local structural feature and the global structural feature.
[0068] Furthermore, the prediction unit comprises:
[0069] The third construction subunit is used to construct an original support vector machine model according to a preset radial basis function and preset parameters;
[0070] An acquisition subunit, used for acquiring feature vector samples for training the original support vector machine model;
[0071] A training subunit, used for training the original support vector machine model through the feature vector samples to obtain a trained support vector machine model;
[0072] The prediction subunit is used to input the hypergraph feature vector into the support vector machine model to predict the charging demand and obtain a prediction result; wherein the prediction result includes the future usage frequency of the charging station, the charging time period requirement and the regional charging demand.
[0073] Furthermore, the feature extraction unit is also used to extract a hypergraph feature vector based on the hypergraph model when it is determined according to the analysis result that the accuracy of the target hypergraph model and the target support vector machine model does not reach a preset optimization target.
[0074] The third aspect of the present application provides an electronic device, including a memory and a processor, wherein the memory is used to store a computer program, and the processor runs the computer program to enable the electronic device to execute the electric vehicle charging demand prediction method described in any one of the first aspect of the present application.
[0075] A fourth aspect of the present application provides a computer-readable storage medium storing computer program instructions, wherein when the computer program instructions are read and executed by a processor, the electric vehicle charging demand prediction method described in any one of the first aspect of the present application is executed.
[0076] The beneficial effects of the present application are as follows: the method and device can predict charging demand based on multi-dimensional charging data, greatly improving the accuracy of predicting dynamic changes in electric vehicle charging demand, expanding the scope of application, and helping to rationally plan charging infrastructure and avoid waste of resources. BRIEF DESCRIPTION OF THE DRAWINGS
[0077] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments of the present application will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0078] Figure 1 A schematic diagram of a flow chart of a method for predicting charging demand of an electric vehicle provided in an embodiment of the present application;
[0079] Figure 2 A schematic diagram of a flow chart of another electric vehicle charging demand prediction method provided in an embodiment of the present application;
[0080] Figure 3 A schematic diagram of an example flow chart of a method for predicting charging demand of an electric vehicle provided in an embodiment of the present application;
[0081] Figure 4 A schematic diagram of the structure of an electric vehicle charging demand prediction device provided in an embodiment of the present application;
[0082] Figure 5 A schematic diagram of the structure of another electric vehicle charging demand prediction device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0083] The technical solutions in the embodiments of the present application will be described below in conjunction with the drawings in the embodiments of the present application.
[0084] It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings. At the same time, in the description of this application, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance.
[0085] Example 1
[0086] Please see Figure 1 , Figure 1 A flow chart of a method for predicting charging demand of an electric vehicle provided in this embodiment. The method for predicting charging demand of an electric vehicle includes:
[0087] S101. Collect a multi-dimensional charging dataset of electric vehicles.
[0088] S102: preprocess the multi-dimensional charging data set to obtain a preprocessed data set.
[0089] S103. Construct a hypergraph model based on the preprocessed data set.
[0090] S104. Extracting a hypergraph feature vector based on the hypergraph model.
[0091] S105. Predict charging demand using a pre-trained support vector machine model and a hypergraph feature vector to obtain a prediction result.
[0092] S106: Analyze the prediction results to obtain analysis results.
[0093] S107. Optimize the parameters of the support vector machine model and the hypergraph model according to the analysis results to obtain a target hypergraph model and a target support vector machine model.
[0094] S108. Determine whether the accuracy of the target hypergraph model and the target support vector machine model reaches the preset optimization target based on the analysis results. If so, execute step S109; if not, execute step S104.
[0095] S109: Perform charging demand prediction based on the target hypergraph model and the target support vector machine model to obtain a charging demand prediction result.
[0096] In this embodiment, the execution subject of the method may be a computing device such as a computer or a server, and no limitation is made in this embodiment.
[0097] In this embodiment, the execution subject of the method may also be a smart device such as a smart phone, a tablet computer, etc., which is not limited in this embodiment.
[0098] It can be seen that the implementation of the electric vehicle charging demand prediction method described in this embodiment can predict the charging demand based on multi-dimensional charging data, greatly improve the accuracy of predicting the dynamic changes in electric vehicle charging demand, expand the scope of application, and help to rationally plan the charging infrastructure and avoid waste of resources.
[0099] Example 2
[0100] Please see Figure 2 , Figure 2 A flow chart of a method for predicting charging demand of an electric vehicle provided in this embodiment. The method for predicting charging demand of an electric vehicle includes:
[0101] S201. Collect a multi-dimensional charging dataset of electric vehicles.
[0102] In this embodiment, the multidimensional charging data set includes at least charging time, charging location, user charging behavior patterns, historical charging data, electric vehicle type, electric vehicle battery capacity, user charging preference data, data on the impact of weather conditions on charging behavior, data on the impact of holidays on charging demand, data on the impact of special events on charging demand, and data on the impact of grid load conditions and charging price fluctuations on user charging choices.
[0103] In this embodiment, the multidimensional dataset include:
[0104] ;
[0105] Among them, i represents the i-th user sample in the data set;
[0106] n is the total number of user samples;
[0107] Indicates the charging time of the i-th user sample, which is the timestamp of the start and end of charging;
[0108] Represents the geographical coordinates of the charging station of the i-th user sample;
[0109] represents the charging behavior pattern of the user initiating charging of the i-th user sample, including frequency and time preference;
[0110] Represents the user's historical charging record of the i-th user sample, including charging time and charging amount information;
[0111] represents the model and battery capacity of the electric vehicle in the i-th user sample;
[0112] represents the preference of the i-th user sample for fast charging or slow charging;
[0113] represents the weather conditions on the day when the i-th user sample charges;
[0114] Indicates the holidays and special events in the area where the i-th user sample is located;
[0115] represents the grid load status during the charging period of the i-th user sample;
[0116] Indicates the electricity price fluctuation during the charging period of the i-th user sample.
[0117] S202: Perform outlier removal processing on the multi-dimensional charging data set to obtain a first processed data set.
[0118] In this embodiment, the method can remove incomplete, erroneous or irrelevant data for each item in the multidimensional data set and delete any missing or outlier values.
[0119] S203: Perform standardization processing on the first processed data set to obtain a second processed data set.
[0120] In this embodiment, the method can be used for the cleaned multidimensional data set. , the numerical data dimension is used to calculate the charging time , Historical charging data , Weather conditions , Grid load status and electricity price fluctuations , perform Z-score standardization:
[0121] ;
[0122] in, is the value of the corresponding dimension in the original data item, and They are the mean and standard deviation of the data in this dimension, which are used to standardize all data under this dimension.
[0123] S204: normalize the second processed data set to obtain a preprocessed data set.
[0124] In this embodiment, the method can be used to normalize the multidimensional data set. Normalize all dimensions in the data to adjust the data range to [0, 1]:
[0125] ;
[0126] in, is the normalized value of the i-th sample in dimension d, and are the minimum and maximum of all normalized values in dimension d, respectively.
[0127] In this embodiment, the normalized multidimensional data set for:
[0128] .
[0129] S205. Based on the preprocessed data set and the definition of the preset hypergraph model, construct an original hypergraph model; wherein each node in the original hypergraph model corresponds to a user sample in the preprocessed data set.
[0130] S206. Based on the preprocessed data set, calculate the many-to-many relationship between each user; wherein the many-to-many relationship at least includes the similarity of common charging time period, the similarity of location proximity, and the similarity of charging behavior.
[0131] In this embodiment, the method can define a hypergraph:
[0132] H = (V, E);
[0133] Among them, V represents the node set in the hypergraph, corresponding to the electric vehicle users, E represents the hyperedge set, representing the many-to-many relationship between users, and each node Corresponding to the normalized multidimensional dataset A user sample i in .
[0134] In this embodiment, for any two nodes , calculate the similarity between them :
[0135] ;
[0136] in, and Respectively represent nodes and Eigenvalues in dimension d.
[0137] S207. Construct a hyperedge of the original hypergraph model based on the many-to-many relationship between each user.
[0138] In this embodiment, since each hyperedge connects user nodes with common features, the method can define the many-to-many relationship between users represented by the hyperedge based on the following criteria:
[0139] ① Similarity of common charging time periods : Calculated based on the frequency of charging of user i and user j in the same time period;
[0140] ② Location proximity similarity : Calculate the inverse of the average distance between two user charging stations using geographic coordinates;
[0141] ③Charging behavior similarity : Cosine similarity based on user charging behavior patterns.
[0142] S208. Assign a corresponding weight to each hyperedge according to a preset weight factor and a many-to-many relationship.
[0143] In this embodiment, the method can be used for each hyperedge Assign a weight , the weight is the comprehensive similarity between the connected node pairs:
[0144] ;
[0145] in, , , is a weight factor used to adjust the contribution of different similarity metrics in the hyperedge weight.
[0146] S209: construct a hypergraph model based on the original hypergraph model, hyperedges and weights.
[0147] In this embodiment, the constructed hypergraph model H can capture and represent the complex many-to-many relationship between electric vehicle users based on common charging time periods, location proximity, and charging behavior similarity.
[0148] In this embodiment, the method can efficiently model the complex multi-dimensional data and relationships in the electric vehicle charging demand by introducing the hypergraph theory, including the interaction of factors such as time, location, and user behavior patterns. It can be seen that this highly comprehensive data modeling method can greatly improve the prediction accuracy of the dynamic changes in electric vehicle charging demand compared to traditional methods.
[0149] S210. Based on the hypergraph model, calculate the number of hyperedges associated with the node, the average degree of neighboring nodes corresponding to the node, the average node degree of the hypergraph, and the density of the hypergraph.
[0150] S211. Determine the node degree according to the number of hyperedges.
[0151] In this embodiment, for each node in the hypergraph H , calculate the node degree As the basic characteristic of a node, the node degree is defined as The number of associated hyperedges, node degree Represents the number of charging events directly related to electric vehicle users. A high value indicates that the user has more connections in the charging network, reflecting high charging demand or diverse charging behavior patterns.
[0152] .
[0153] S212: Determine the hyperedge weight according to the weight.
[0154] In this embodiment, for each hyperedge in the hypergraph H , which uses the weights defined in the previous steps As the feature of the hyperedge, the weight It reflects the strength and closeness of the relationship between users connected by the connected hyperedge, revealing the potential similar charging needs among user groups.
[0155] S213: Determine the local structural features according to the average degree of the neighboring nodes corresponding to the node.
[0156] In this embodiment, for each node ,This method calculates the average degree of its neighbor nodes as a local structural feature, reflecting the average connection density of the node's direct social environment or charging network environment. In the context of charging demand prediction, it is used to understand the extent to which user charging behavior is affected by the behavior of similar user groups. Among them,
[0157] ;
[0158] Representation Node The set of neighbor nodes.
[0159] S214. Determine global structural features according to the average node degree of the hypergraph and the density of the hypergraph.
[0160] In this embodiment, the average value of all node degrees in the hypergraph provides an overview of the connection density of the entire charging network, which is used to evaluate the activity of the entire charging network and the overall trend of charging demand.
[0161] .
[0162] In this embodiment, the density of the hypergraph is defined as the ratio of the actual number of hyperedges to the maximum possible number of hyperedges of the number of nodes, which provides information about the overall connectivity of the charging network. A high density indicates that there are more common charging behaviors and similarities among users in the charging network.
[0163] .
[0164] S215. Construct a hypergraph feature vector based on node degrees, hyperedge weights, local structural features, and global structural features.
[0165] In this embodiment, the method can calculate the degree of each node. , the weight of the hyperedge , local structural features And global features of the hypergraph such as average node degree and density , construct feature vectors. Each feature vector represents the feature summary of a node in the hypergraph or the entire hypergraph, which is used to reflect the status and characteristics of the charging network:
[0166] ;
[0167] in, Represents the feature vector used for training or prediction.
[0168] S216: construct an original support vector machine model according to a preset radial basis function and preset parameters.
[0169] In this embodiment, the method can select radial basis function and parameter configuration support vector machine model:
[0170] ;
[0171] in, It is the width parameter of the RBF kernel, which controls the distribution of data points after conversion to the new feature space and needs to be optimized through cross-validation.
[0172] S217. Obtain feature vector samples for training the original support vector machine model.
[0173] S218. Train the original support vector machine model using the feature vector samples to obtain a trained support vector machine model.
[0174] In this embodiment, the method can use the feature vector extracted from the historical data as input, the corresponding charging station usage frequency, charging time period demand and regional charging demand as targets, and train the support vector machine model:
[0175] ;
[0176] ;
[0177] in, is the normal vector of the hyperplane, b is the offset, is the slack variable, C is the penalty parameter, is the actual class label.
[0178] S219. Input the hypergraph feature vector into a support vector machine model to predict charging demand and obtain a prediction result; wherein the prediction result includes the future usage frequency of the charging station, charging time period requirements and regional charging demand.
[0179] In this embodiment, the method can input the current or future feature vectors into the trained support vector machine model to predict the usage frequency of charging stations, charging time period requirements and regional charging requirements. The model output is the prediction of the demand category for the classification task or the predicted value of the demand for the regression task. At this time, a new feature vector , the prediction function of the SVM model is:
[0180] .
[0181] In this embodiment, the method can adjust the planning of charging infrastructure, grid management and user service optimization measures based on the prediction results, and is also used to further analyze the trends and patterns of electric vehicle charging demand:
[0182] ;
[0183] in, is the model's predicted value for the i-th sample, is the actual value.
[0184] S220: Analyze the prediction result to obtain an analysis result.
[0185] In this embodiment, the method can analyze the prediction output of the support vector machine model, compare the predicted charging demand with the actual observation value, pay attention to the prediction accuracy of peak charging hours and high-load areas of charging stations, and the model's responsiveness to holidays and extreme weather.
[0186] In this embodiment, the method can introduce a time accuracy index to measure the accuracy of the model in predicting charging demand in the time dimension during the peak charging period.
[0187] ;
[0188] P represents the peak charging time set, and are the actual and predicted charging demand in time period i, respectively;
[0189] At this point, the geographic accuracy index is introduced to evaluate the accuracy differences of the model in different geographic locations.
[0190] ;
[0191] G represents a collection of different geographical areas. and are the actual and predicted charging demands in region j, respectively.
[0192] S221. Optimize the parameters of the support vector machine model and the hypergraph model according to the analysis results to obtain the target hypergraph model and the target support vector machine model.
[0193] In this embodiment, the method can adjust the relationship weight factors (α, β, γ) in the hypergraph construction and the kernel function parameters and penalty coefficient C of the SVM model based on the analysis results, aiming at the analysis of time accuracy and geographical accuracy, and adopt an adaptive adjustment strategy to optimize the model's adaptability to high dynamic changes and geographical distribution of charging demand; based on the evaluation results in step S62, adjust the relationship weight factors (α, β, γ) in the hypergraph construction and the kernel function parameters and penalty coefficient C of the SVM model based on the analysis of time accuracy and geographical accuracy, and adopt an adaptive adjustment strategy to optimize the model's adaptability to high dynamic changes and geographical distribution of charging demand.
[0194] S222. Determine whether the accuracy of the target hypergraph model and the target support vector machine model reaches the preset optimization target based on the analysis results. If so, execute step S223; if not, execute step S210.
[0195] In this embodiment, the method can retrain the model with updated parameters through a continuous iterative process, and evaluate and adjust again until the model reaches the optimization goal in terms of the innovative evaluation index, and confirm the final model configuration.
[0196] S223. Perform charging demand prediction based on the target hypergraph model and the target support vector machine model to obtain a charging demand prediction result.
[0197] In this embodiment, the method can apply the optimized prediction results to the planning of charging infrastructure, power grid management and user service optimization.
[0198] Please see Figure 3 , Figure 3 An example flow chart of a method for predicting charging demand of electric vehicles is shown.
[0199] In this embodiment, the execution subject of the method may be a computing device such as a computer or a server, and no limitation is made in this embodiment.
[0200] In this embodiment, the execution subject of the method may also be a smart device such as a smart phone, a tablet computer, etc., which is not limited in this embodiment.
[0201] It can be seen that the implementation of the electric vehicle charging demand prediction method described in this embodiment can predict the charging demand based on multi-dimensional charging data, greatly improve the accuracy of predicting the dynamic changes in electric vehicle charging demand, expand the scope of application, and help to rationally plan the charging infrastructure and avoid waste of resources.
[0202] Example 3
[0203] This embodiment provides an application example of an electric vehicle charging demand prediction method. Specifically, when the method is applied to a typical medium-sized city, the forecast of electric vehicle charging demand in 2023 can be referred to: the city has 100,000 electric vehicles and 150 charging stations. On this basis, data can be collected from the following data sources:
[0204] ①Charging station data: including the geographical location of each charging station, the number of charging piles, the number of charging times per day, the duration of each charging, and the charging power.
[0205] ②User behavior data: collected through on-board equipment, including charging frequency, charging time preference, commonly used charging stations, etc.
[0206] ③ External factor data: city activity calendar, weather records (including temperature, rainfall), holiday schedule, etc.
[0207] In this case, the method can clean and normalize the collected data, converting time to hours of the day and geographic location to distance relative to the city center.
[0208] At this point, a multidimensional dataset is constructed, and each record includes: user ID, timestamp, charging station location, weather conditions, whether it is a holiday, charging duration, etc.
[0209] Based on the constructed multidimensional dataset, a hypergraph model is created. In this model, each electric vehicle user is a node, and the complex relationships between nodes (such as common charging time period, location proximity, and charging behavior similarity) are connected through hyperedges.
[0210] Then, features are extracted from the hypergraph model: node degree, hyperedge weight, local structural features of nodes, and global features of the hypergraph.
[0211] The extracted features are then used to train the SVM model to predict future charging demand. The radial basis function (RBF) is selected as the kernel function, and the optimal penalty parameter C and kernel parameter γ are determined through cross-validation.
[0212] Table 1 Charging station data
[0213]
[0214] Table 2 User behavior data
[0215]
[0216] Table 3 External factors data
[0217]
[0218] Table 4 Comparison between model prediction results and actual charging demand
[0219]
[0220] Based on Table 1-4 above, after the model training is completed, this method can use the data from the last month of 2023 as a test set for prediction and compare it with the actual charging demand data.
[0221] The prediction results show that during peak charging hours, the average error between the predicted demand and the actual demand is only 2.35%. During holidays and special weather conditions, the model also shows high accuracy, with the error controlled within 5%. By comparing with traditional prediction methods, on the same test set, the average error of traditional methods is 10%-15%, which is significantly higher than this method.
[0222] As can be seen from the above content, this method can efficiently model the complex multidimensional data and relationships in electric vehicle charging demand by introducing hypergraph theory, including the interaction of factors such as time, location, and user behavior patterns. This highly comprehensive data modeling method greatly improves the accuracy of predicting the dynamic changes in electric vehicle charging demand compared to traditional methods.
[0223] At the same time, the adaptive adjustment strategy of the parameters of the support vector machine model enables the model to adapt more flexibly to changes in charging demand, improving the prediction performance of the model in different charging scenarios. In particular, the prediction accuracy during peak charging hours and in different geographical locations has been significantly improved. At the same time, by introducing time accuracy indicators and geographic accuracy indicators, the performance of the model in specific scenarios can be evaluated more carefully, such as the prediction accuracy during peak charging hours and in different geographical areas.
[0224] In addition, this method can also accurately predict charging demand and provide a scientific basis for the layout, scale and configuration of charging equipment of electric vehicle charging stations, thereby helping to rationally plan charging infrastructure and avoid waste of resources.
[0225] Example 4
[0226] Please see Figure 4 , Figure 4 This is a schematic diagram of the structure of an electric vehicle charging demand prediction device provided in this embodiment. Figure 4 As shown, the electric vehicle charging demand prediction device includes:
[0227] A collection unit 310, used to collect a multi-dimensional charging data set of an electric vehicle;
[0228] A preprocessing unit 320, configured to preprocess the multi-dimensional charging data set to obtain a preprocessed data set;
[0229] A model building unit 330, configured to build a hypergraph model based on the preprocessed data set;
[0230] A feature extraction unit 340, configured to extract a hypergraph feature vector based on the hypergraph model;
[0231] A prediction unit 350 is used to predict charging demand by using a pre-trained support vector machine model and a hypergraph feature vector to obtain a prediction result;
[0232] An analysis unit 360 is used to analyze the prediction result to obtain an analysis result;
[0233] A parameter optimization unit 370, configured to optimize the parameters of the support vector machine model and the hypergraph model according to the analysis results to obtain a target hypergraph model and a target support vector machine model;
[0234] A judgment unit 380 is used to judge whether the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target according to the analysis result;
[0235] The determination unit 390 is used to perform charging demand prediction based on the target hypergraph model and the target support vector machine model to obtain a charging demand prediction result when it is determined based on the analysis results that the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target.
[0236] In this embodiment, the explanation of the electric vehicle charging demand prediction device can refer to the description in Example 1 or Example 2, and will not be repeated in this embodiment.
[0237] It can be seen that the electric vehicle charging demand prediction device described in this embodiment can perform charging demand prediction based on multi-dimensional charging data, greatly improves the prediction accuracy of dynamic changes in electric vehicle charging demand, expands the scope of application, and helps to rationally plan charging infrastructure and avoid waste of resources.
[0238] Example 5
[0239] Please see Figure 5 , Figure 5 This is a schematic diagram of the structure of an electric vehicle charging demand prediction device provided in this embodiment. Figure 5 As shown, the electric vehicle charging demand prediction device includes:
[0240] A collection unit 310, used to collect a multi-dimensional charging data set of an electric vehicle;
[0241] A preprocessing unit 320, configured to preprocess the multi-dimensional charging data set to obtain a preprocessed data set;
[0242] A model building unit 330, configured to build a hypergraph model based on the preprocessed data set;
[0243] A feature extraction unit 340, configured to extract a hypergraph feature vector based on the hypergraph model;
[0244] A prediction unit 350 is used to predict charging demand by using a pre-trained support vector machine model and a hypergraph feature vector to obtain a prediction result;
[0245] An analysis unit 360 is used to analyze the prediction result to obtain an analysis result;
[0246] A parameter optimization unit 370, configured to optimize the parameters of the support vector machine model and the hypergraph model according to the analysis results to obtain a target hypergraph model and a target support vector machine model;
[0247] A judgment unit 380 is used to judge whether the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target according to the analysis result;
[0248] The determination unit 390 is used to perform charging demand prediction based on the target hypergraph model and the target support vector machine model to obtain a charging demand prediction result when it is determined based on the analysis results that the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target.
[0249] In this embodiment, the multidimensional charging data set includes at least charging time, charging location, user charging behavior patterns, historical charging data, electric vehicle type, electric vehicle battery capacity, user charging preference data, data on the impact of weather conditions on charging behavior, data on the impact of holidays on charging demand, data on the impact of special events on charging demand, and data on the impact of grid load conditions and charging price fluctuations on user charging choices.
[0250] As an optional implementation, the preprocessing unit 320 includes:
[0251] The removal processing subunit 321 is used to perform outlier removal processing on the multi-dimensional charging data set to obtain a first processed data set;
[0252] The standardization subunit 322 is used to perform standardization processing on the first processed data set to obtain a second processed data set;
[0253] The normalization subunit 323 is used to perform normalization processing on the second processed data set to obtain a preprocessed data set.
[0254] As an optional implementation, the model building unit 330 includes:
[0255] The first construction subunit 331 is used to construct an original hypergraph model based on the preprocessed data set and the definition of the preset hypergraph model; wherein each node in the original hypergraph model corresponds to a user sample in the preprocessed data set;
[0256] A first calculation subunit 332 is used to calculate the many-to-many relationship between each user based on the preprocessed data set; wherein the many-to-many relationship at least includes the similarity of common charging time period, the similarity of location proximity, and the similarity of charging behavior;
[0257] The first construction subunit 331 is further used to construct the hyperedges of the original hypergraph model based on the many-to-many relationship between each user;
[0258] An allocating subunit 333, configured to allocate a corresponding weight to each hyperedge according to a preset weight factor and a many-to-many relationship;
[0259] The first construction subunit 331 is also used to construct a hypergraph model based on the original hypergraph model, hyperedges and weights.
[0260] As an optional implementation, the feature extraction unit 340 includes:
[0261] The second calculation subunit 341 is used to calculate the number of hyperedges associated with the node, the average degree of neighboring nodes corresponding to the node, the average node degree of the hypergraph, and the density of the hypergraph based on the hypergraph model;
[0262] A determination subunit 342, configured to determine the node degree according to the number of hyperedges;
[0263] The determination subunit 342 is further used to determine the hyperedge weight according to the weight;
[0264] The determination subunit 342 is further used to determine the local structural feature according to the average degree of the neighboring nodes corresponding to the node;
[0265] The determination subunit 342 is further used to determine the global structural feature according to the average node degree of the hypergraph and the density of the hypergraph;
[0266] The second construction subunit 343 is used to construct a hypergraph feature vector based on node degrees, hyperedge weights, local structural features and global structural features.
[0267] As an optional implementation, the prediction unit 350 includes:
[0268] The third construction subunit 351 is used to construct an original support vector machine model according to a preset radial basis function and preset parameters;
[0269] An acquisition subunit 352 is used to acquire feature vector samples for training the original support vector machine model;
[0270] The training subunit 353 is used to train the original support vector machine model through the feature vector samples to obtain a trained support vector machine model;
[0271] The prediction subunit 354 is used to input the hypergraph feature vector into the support vector machine model to predict the charging demand and obtain the prediction result; wherein the prediction result includes the future usage frequency of the charging station, the charging time period demand and the regional charging demand.
[0272] As an optional implementation, the feature extraction unit 340 is also used to extract a hypergraph feature vector based on the hypergraph model when it is determined based on the analysis results that the accuracy of the target hypergraph model and the target support vector machine model does not reach a preset optimization target.
[0273] In this embodiment, the explanation of the electric vehicle charging demand prediction device can refer to the description in Example 1 or Example 2, and will not be repeated in this embodiment.
[0274] It can be seen that the electric vehicle charging demand prediction device described in this embodiment can perform charging demand prediction based on multi-dimensional charging data, greatly improves the prediction accuracy of dynamic changes in electric vehicle charging demand, expands the scope of application, and helps to rationally plan charging infrastructure and avoid waste of resources.
[0275] An embodiment of the present application provides an electronic device, including a memory and a processor, wherein the memory is used to store a computer program, and the processor runs the computer program to enable the electronic device to execute the electric vehicle charging demand prediction method in Embodiment 1 or Embodiment 2 of the present application.
[0276] An embodiment of the present application provides a computer-readable storage medium storing computer program instructions. When the computer program instructions are read and executed by a processor, the electric vehicle charging demand prediction method in Embodiment 1 or Embodiment 2 of the present application is executed.
[0277] In several embodiments provided in the present application, it should be understood that the disclosed devices and methods can also be implemented in other ways. The device embodiments described above are merely schematic. For example, the flowcharts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the devices, methods and computer program products according to multiple embodiments of the present application. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, a program segment or a part of a code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of boxes in the block diagram and / or flowchart can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.
[0278] In addition, the functional modules in the various embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
[0279] If the function is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, and other media that can store program codes.
[0280] The above description is only an embodiment of the present application and is not intended to limit the scope of protection of the present application. For those skilled in the art, the present application may have various changes and variations. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application should be included in the scope of protection of the present application. It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in the subsequent drawings.
[0281] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
[0282] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
Claims
1. A method for predicting electric vehicle charging demand, characterized in that: include: Collect multi-dimensional charging datasets for electric vehicles; Preprocessing the multidimensional charging data set to obtain a preprocessed data set; Constructing a hypergraph model based on the preprocessed data set; Extracting a hypergraph feature vector based on the hypergraph model; The charging demand is predicted by using a pre-trained support vector machine model and the hypergraph feature vector to obtain a prediction result; Analyzing the prediction result to obtain an analysis result; Optimize the parameters of the support vector machine model and the hypergraph model according to the analysis results to obtain a target hypergraph model and a target support vector machine model; Determining whether the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target according to the analysis result; If yes, then performing charging demand prediction according to the target hypergraph model and the target support vector machine model to obtain a charging demand prediction result; Wherein, constructing a hypergraph model according to the preprocessed data set includes: Based on the definition of the preprocessed data set and the preset hypergraph model, an original hypergraph model is constructed; wherein each node in the original hypergraph model corresponds to a user sample in the preprocessed data set; Based on the preprocessed data set, calculating the many-to-many relationship between each user; wherein the many-to-many relationship at least includes the similarity of common charging time period, the similarity of location proximity, and the similarity of charging behavior; Constructing a hyperedge of the original hypergraph model based on the many-to-many relationship between each user; According to a preset weight factor and the many-to-many relationship, assign a corresponding weight to each of the hyperedges; Constructing a hypergraph model based on the original hypergraph model, the hyperedges and the weights; The step of extracting a hypergraph feature vector based on the hypergraph model includes: Based on the hypergraph model, the number of hyperedges associated with the node, the average degree of neighboring nodes corresponding to the node, the average node degree of the hypergraph, and the density of the hypergraph are calculated; Determining a node degree according to the number of hyperedges; Determining a hyperedge weight according to the weight; Determine the local structural feature according to the average degree of the neighboring nodes corresponding to the node; Determining global structural features according to an average node degree of the hypergraph and a density of the hypergraph; A hypergraph feature vector is constructed based on the node degree, the hyperedge weight, the local structural feature and the global structural feature.
2. The method for predicting electric vehicle charging demand according to claim 1, characterized in that: The multidimensional charging data set includes at least charging time, charging location, user charging behavior pattern, historical charging data, electric vehicle type, electric vehicle battery capacity, user charging preference data, data on the impact of weather conditions on charging behavior, data on the impact of holidays on charging demand, data on the impact of special events on charging demand, and data on the impact of power grid load conditions and charging price fluctuations on user charging choices.
3. The method for predicting electric vehicle charging demand according to claim 1, characterized in that: The preprocessing of the multi-dimensional charging data set to obtain a preprocessed data set includes: Performing outlier removal processing on the multidimensional charging data set to obtain a first processed data set; performing standardization processing on the first processed data set to obtain a second processed data set; The second processed data set is normalized to obtain a preprocessed data set.
4. The method for predicting electric vehicle charging demand according to claim 1, characterized in that: The charging demand prediction is performed by using the pre-trained support vector machine model and the hypergraph feature vector to obtain a prediction result, including: Constructing an original support vector machine model according to a preset radial basis function and preset parameters; Acquire feature vector samples for training the original support vector machine model; The original support vector machine model is trained by using the feature vector samples to obtain a trained support vector machine model; The hypergraph feature vector is input into the support vector machine model to predict charging demand and obtain a prediction result; wherein the prediction result includes the future usage frequency of the charging station, the charging time period requirement and the regional charging demand.
5. The method for predicting electric vehicle charging demand according to claim 1, characterized in that: The method further comprises: When it is determined according to the analysis result that the accuracy of the target hypergraph model and the target support vector machine model does not reach the preset optimization target, the step of extracting the hypergraph feature vector based on the hypergraph model is performed.
6. An electric vehicle charging demand prediction device, characterized in that: The electric vehicle charging demand prediction device comprises: A collection unit, used for collecting a multi-dimensional charging data set of an electric vehicle; A preprocessing unit, used for preprocessing the multi-dimensional charging data set to obtain a preprocessed data set; A model building unit, used for building a hypergraph model according to the preprocessed data set; A feature extraction unit, configured to extract a hypergraph feature vector based on the hypergraph model; A prediction unit, used to predict charging demand by using a pre-trained support vector machine model and the hypergraph feature vector to obtain a prediction result; An analysis unit, used to analyze the prediction result to obtain an analysis result; A parameter optimization unit, used to optimize the parameters of the support vector machine model and the hypergraph model according to the analysis result to obtain a target hypergraph model and a target support vector machine model; A judging unit, used to judge whether the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target according to the analysis result; a determination unit, configured to, when it is determined according to the analysis result that the accuracy of the target hypergraph model and the target support vector machine model reaches a preset optimization target, perform charging demand prediction according to the target hypergraph model and the target support vector machine model to obtain a charging demand prediction result; Wherein, the model building unit includes: A first construction subunit is used to construct an original hypergraph model based on the preprocessed data set and the definition of the preset hypergraph model; wherein each node in the original hypergraph model corresponds to a user sample in the preprocessed data set; A first calculation subunit, configured to calculate a many-to-many relationship between each user based on the preprocessed data set; wherein the many-to-many relationship includes at least a common charging time period similarity, a location proximity similarity, and a charging behavior similarity; The first construction subunit is further used to construct the hyperedges of the original hypergraph model based on the many-to-many relationship between each user; an allocating subunit, configured to allocate a corresponding weight to each of the hyperedges according to a preset weight factor and the many-to-many relationship; The first construction subunit is further used to construct a hypergraph model based on the original hypergraph model, the hyperedges and the weights; Wherein, the feature extraction unit comprises: A second calculation subunit is used to calculate the number of hyperedges associated with the node, the average degree of neighboring nodes corresponding to the node, the average node degree of the hypergraph, and the density of the hypergraph based on the hypergraph model; A determination subunit, configured to determine a node degree according to the number of hyperedges; The determining subunit is further used to determine the hyperedge weight according to the weight; The determination subunit is further used to determine the local structural feature according to the average degree of the neighboring nodes corresponding to the node; The determining subunit is further used to determine the global structural feature according to the average node degree of the hypergraph and the density of the hypergraph; The second construction subunit is used to construct a hypergraph feature vector based on the node degree, the hyperedge weight, the local structural feature and the global structural feature.
7. An electronic device, characterized in that: The electronic device includes a memory and a processor, the memory is used to store a computer program, and the processor runs the computer program to enable the electronic device to execute the electric vehicle charging demand prediction method according to any one of claims 1 to 5.
8. A readable storage medium, characterized in that: The readable storage medium stores computer program instructions, and when the computer program instructions are read and executed by a processor, the method for predicting charging demand of an electric vehicle according to any one of claims 1 to 5 is executed.
