Electric vehicle charging data generation method and device based on attention and conditional probability distribution, and storage medium

By constructing a deep neural network in the feature space to enhance the conditional probability model, and combining feature attention and residual blocks, the shortcomings of traditional models in handling high-dimensional data and complex dependencies in electric vehicle charging data generation are solved, and more accurate charging behavior modeling and prediction are achieved.

CN120611155BActive Publication Date: 2025-11-25SHANGHAI UNIVERSITY OF ELECTRIC POWER
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202511113237.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-08-11
Publication Date
2025-11-25
Estimated Expiration
2045-08-11

AI Technical Summary

Technical Problem

Traditional models struggle to handle complex high-dimensional data and capture intricate dependencies when generating electric vehicle charging data. They fail to fully capture the complexities of electric vehicle charging behavior, particularly the charging habits of different user groups, differences in battery capacity, and choices of charging methods.

Method used

A feature space for electric vehicle charging behavior is constructed, and conditional probability modeling enhanced by deep neural networks is adopted. The model is trained by combining feature attention and residual blocks, and charging behavior data that conforms to physical constraints is generated by Gibbs sampling.

Benefits of technology

It significantly improves modeling accuracy and expressive power, accurately reproducing the complex characteristics of charging behavior. The generated data is highly consistent with the original data, especially in handling multi-peak distribution features and maintaining the dependencies between features.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120611155B_ABST
    Figure CN120611155B_ABST
Patent Text Reader

Abstract

The application relates to an electric vehicle charging data generation method and device based on attention and conditional probability distribution, and a storage medium, and comprises the following steps: constructing a feature space of electric vehicle charging behavior, performing feature-level deep neural network enhanced conditional probability modeling on continuous value features, time-related features and discrete value features respectively, and obtaining a conditional probability neural network model based on feature attention and residual blocks; acquiring electric vehicle charging behavior training data, training the conditional probability neural network model by adopting a learning rate that decreases with an increase in training rounds; and performing Gibbs sampling under variable constraints based on the trained conditional probability neural network model, and screening electric vehicle charging behavior data that meets physical constraints. Compared with the prior art, the application has the advantages of integrating multiple types of probability distribution models and dynamically predicting probability distribution parameters by using deep neural networks.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer technology, in particular to an electric vehicle charging data generation method and device based on attention and conditional probability distribution and a storage medium. BACKGROUND

[0002] At present, in the field of electric vehicle charging data generation and analysis, traditional simulation models based on vehicle travel surveys and data-driven statistical models are the mainstream of research and application. These models provide support for understanding and predicting electric vehicle charging behavior to some extent. For example, simulation models based on vehicle travel surveys can simulate the charging demand of electric vehicles in different scenarios by constructing travel demand models, energy consumption models and charging selection models. Data-driven statistical models model and predict charging events by learning the probability distribution of existing data sets.

[0003] However, with the rapid growth of the number of electric vehicles and the continuous expansion of charging infrastructure, these traditional models gradually reveal some limitations.

[0004] Chinese patent publication No. CN114580789B provides a multi-type electric vehicle load prediction method and system based on charging behavior. The method analyzes the probability characteristics of the daily driving distance and the starting charging time of electric vehicles, establishes a calculation model of the starting state of charge and the starting charging time of electric vehicles, and achieves the effect of predicting the daily load of electric vehicles. This method is based on data-driven statistical models that learn the probability distribution of existing data for modeling. Their parameter dimensions are relatively limited, and they can only focus on basic parameters such as charging duration, start time, and charging energy, but it is difficult to fully capture the complexity of electric vehicle charging behavior, such as charging habits of different user groups, battery capacity differences, and charging method selection (fast charging or slow charging). Traditional models have obvious shortcomings in handling complex high-dimensional data and capturing complex dependencies in data.

[0005] Therefore, in order to overcome the limitations of existing technologies and meet the needs of large-scale electric vehicle charging system data analysis and prediction, it is necessary to develop a neural network-based generative model for electric vehicle charging data generation to achieve more comprehensive and accurate modeling and prediction of charging behavior, and to provide stronger support for charging infrastructure planning and power system scheduling. SUMMARY

[0006] The purpose of the present application is to overcome the shortcomings of the prior art and provide an electric vehicle charging data generation method, device and storage medium based on attention and conditional probability distribution to solve or partially solve the problem of insufficient handling of complex high-dimensional data and capturing of complex dependencies in data in traditional models for generating electric vehicle charging data.

[0007] The object of the present application can be achieved by the following technical solutions:

[0008] In one aspect of the present application, a method for generating electric vehicle charging data based on attention and conditional probability distribution is provided, comprising the following steps:

[0009] A feature space of electric vehicle charging behavior is constructed, and a deep neural network enhanced conditional probability modeling is performed at the feature level for continuous value features, time related features and discrete value features, to obtain a conditional probability neural network model based on feature attention and residual block;

[0010] Electric vehicle charging behavior training data is obtained, and the conditional probability neural network model is trained using a learning rate that decreases with increasing training rounds;

[0011] Based on the trained conditional probability neural network model, Gibbs sampling is performed under variable constraints to screen electric vehicle charging behavior data that meets physical constraints.

[0012] As a preferred technical solution, the deep neural network enhanced conditional probability modeling of the continuous value features is:

[0013]

[0014]

[0015]

[0016]

[0017]

[0018]

[0019] wherein, is the probability of under the condition that is the feature to be modeled, is the probability of under the condition that is the feature to be modeled, is all other features except the feature to be modeled, , is the weight, , is the bias, is the conditional probability density of the feature, is the Gamma function, , is a parameter limited in a preset interval, is the hidden layer representation of the neural network after attention mechanism and residual connection processing.

[0020] As a preferred technical solution, the time-related feature deep neural network enhanced conditional probability is modeled as:

[0021]

[0022]

[0023]

[0024]

[0025]

[0026]

[0027]

[0028] wherein, is the probability of under the condition that is the modeling feature, is all other features except the modeling feature, , , , , , is the weight, , , , is the bias, is the number of mixture components, is the weight of the th component, represents a normal distribution, and are the mean and standard deviation of the th component, , are the preset minimum and maximum values, is the limiting interval function, is the feature set input into the condition encoder, including all other features except the current predicted feature.

[0029] As a preferred technical solution, the time-related feature deep neural network enhanced conditional probability is modeled as:

[0030]

[0031]

[0032]

[0033]

[0034] wherein, is the feature gating result, is the Sigmoid activation function, , , is the weight, , , is the bias, is the feature set input to the conditional encoder, including all features except the current prediction, represents element-level multiplication, is the probability that the discrete value feature is , is the target feature y with a category c corresponding logit value, is the number of categories.

[0035] As a preferred technical solution, the process of training the conditional probability neural network model comprises the following steps:

[0036] The electric vehicle charging behavior training data is subjected to feature extraction, normalization and coding processing;

[0037] The parameters of the conditional probability model corresponding to each feature are initialized;

[0038] In each training round, the gradient flow is improved by residual connection, the features are extracted by attention mechanism, the gradient of each variable is calculated, and the parameters of the corresponding conditional probability model are updated by gradient descent method with a learning rate that decreases with the increase of the training round;

[0039] After training, the parameters of the conditional probability model are returned.

[0040] As a preferred technical solution, the learning rate is:

[0041]

[0042] wherein, is the learning rate of the t th round, is the initial learning rate, is the total number of rounds, is the termination factor.

[0043] As a preferred technical solution, the process of screening the electric vehicle charging behavior data meeting the physical constraints based on the trained conditional probability neural network model under variable constraints comprises the following steps:

[0044] Initializing a batch sample matrix to generate an initial value;

[0045] Iteratively updating the sample value through Gibbs sampling;

[0046] Setting a constraint condition of variable level;

[0047] After the number of iterations reaches a threshold value, a sample of stable distribution is obtained;

[0048] Screening the electric vehicle charging behavior data meeting the physical constraints;

[0049] Saving the screened electric vehicle charging behavior data as structured data for electric vehicle charging behavior analysis and prediction.

[0050] As a preferred technical solution, the continuous value feature includes an initial state of charge and an ending state of charge, the time-related feature includes a start charging time and a charging duration, and the discrete value feature includes a battery capacity and a user type.

[0051] In another aspect of the present application, an electronic device is provided, comprising one or more processors and a memory, the memory having stored therein one or more programs, the one or more programs including instructions for executing the aforementioned electric vehicle charging data generation method based on attention and conditional probability distribution.

[0052] In another aspect of the present application, a computer-readable storage medium is provided, comprising one or more programs for execution by one or more processors of an electronic device, the one or more programs including instructions for executing the aforementioned electric vehicle charging data generation method based on attention and conditional probability distribution.

[0053] Compared with the prior art, the present application has at least one of the following beneficial effects:

[0054] (1) Integrated multi-type probability distribution model: To solve the problem that the traditional model has limited parameter dimension and is difficult to accurately model the continuous bounded, continuous multi-peak, discrete and other different types of charging behavior characteristics, and cannot comprehensively capture the complexity of the charging behavior, the feature space of the electric vehicle charging behavior is constructed, and the feature-level deep neural network enhanced conditional probability modeling is performed for continuous value features, time-related features and discrete value features, respectively. The conditional probability neural network model based on feature attention and residual block is obtained, the probability distribution model suitable for different characteristics of electric vehicle charging behavior features is selected and integrated into the same framework, which significantly improves the modeling accuracy and expression ability, and the distribution of the generated data in each feature dimension is highly consistent with the original data. The range characteristics of continuous bounded values, the distribution form of continuous multi-peak characteristics and the category ratio of discrete characteristics can be accurately restored.

[0055] (2) Deep neural network dynamic prediction probability distribution parameters: To solve the problem that the traditional model uses fixed parameter distribution and cannot learn the nonlinear dependency between features, and the ability to process high-dimensional complex data and capture complex dependencies between features is insufficient, the deep neural network is combined with the conditional probability distribution, and the parameters of each probability distribution are dynamically calculated by using the neural network supplemented by residual blocks and attention mechanisms. The model can learn the nonlinear dependency between features, improve the expression ability and flexibility, and the generated data can effectively preserve the complex correlation between features in the charging behavior, providing more accurate support for comprehensive modeling and prediction of charging behavior.

[0056] (3) Combination of feature attention mechanism and residual block: To solve the problem that deep neural network training is prone to gradient vanishing and explosion, and cannot adaptively distinguish feature importance, resulting in poor model stability and insufficient capture of key features, the feature attention mechanism module and the residual block module are constructed. The attention mechanism enhances the focusing ability of important features, and the residual block improves the gradient flow of deep network, improves the stability and expression ability of model training, especially in handling multi-peak distribution characteristics and maintaining the dependency between features, which guarantees the authenticity of the generated data. BRIEF DESCRIPTION OF DRAWINGS

[0057] Figure 1 Flowchart of the electric vehicle charging data generation method based on attention and conditional probability distribution in the embodiment;

[0058] Figure 2 Schematic diagram of the model training process in the embodiment;

[0059] Figure 3 Schematic diagram of the data generation process in the embodiment;

[0060] Figure 4This is a schematic diagram comparing the distribution of electric vehicle charging behavior data and the original data on continuous features in the embodiment.

[0061] Figure 5 This is a schematic diagram comparing the distribution of electric vehicle charging behavior data and the original data on discrete features in the embodiment.

[0062] Figure 6 This is a schematic diagram of the electronic device in the embodiment. Detailed Implementation

[0063] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0064] Example 1

[0065] To address the problems existing in the aforementioned prior art, this embodiment provides a method for generating electric vehicle charging data based on attention and conditional probability distribution. By combining multiple conditional probability distributions and deep neural network techniques, it simulates and generates electric vehicle charging behavior data. See [link to relevant documentation]. Figure 1 The overall architecture of the method mainly consists of three core parts: First, it uses neural networks to directly model the conditional probability distribution. Then, through conditional probability models and chain rules The method implicitly expresses the joint probability distribution of electric vehicle (EV) charging data, and finally, through Gibbs sampling, iterates multiple times to converge to a state that conforms to the joint probability distribution, thus generating an EV charging event. The specific steps of the method are as follows:

[0066] Step S1: The neural network directly models the conditional probability distribution. .

[0067] Specifically, step S1 includes:

[0068] Step S101: Construct a feature set and define the feature space of electric vehicle charging behavior, including initial state of charge (start_soc), end state of charge (end_soc), start charging time (start_hour), charging duration (duration), battery capacity (battery_capacity), and user type (veh_label).

[0069] Step S102 involves constructing a deep neural network-enhanced conditional probability model for each feature, specifically including:

[0070] (1) Construct a feature attention mechanism module, which includes the following structure:

[0071]

[0072] wherein, is an input feature vector, representing a sample point in the feature space, denotes a Sigmoid activation function, and the second term on the right side of the above formula represents a residual connection, which directly adds the original input to the output of the attention mechanism to improve information flow and gradient propagation.

[0073] The feature weight is calculated using a linear layer and a Sigmoid activation function, the weight is applied to the input feature, and a residual connection is added to achieve adaptive enhancement of the feature.

[0074] The mathematical expression of the feature attention mechanism is:

[0075]

[0076] wherein, denotes a Sigmoid function, and are weight matrices and bias terms, respectively, and ⊙ denotes element multiplication.

[0077] (2) Construct a residual block module, which includes the following structure:

[0078]

[0079] A sequence of two linear layers and two layer normalization layers, using a residual connection method to improve the gradient flow performance of deep networks.

[0080] The mathematical expression of the residual block is:

[0081]

[0082]

[0083]

[0084]

[0085]

[0086]

[0087] In the above formula, , are weight matrices, , are bias terms, zThis represents the saved original input, used to implement residual connections. x This represents the input feature vector, and in the residual block, it represents the feature representation currently being processed. ReLU represents the layer normalization operation used to stabilize deep network training. It normalizes the input of each layer by subtracting the mean and dividing by the standard deviation. ReLU() denotes the modified linear unit activation function, defined as ReLU( x ) = max(0, x ), used to introduce nonlinearity.

[0088] (3) For continuous value characteristics (initial state of charge, final state of charge), construct a Beta distribution model:

[0089]

[0090] In the above formula, For the condition is Under the premise The probability, For the features currently being modeled, All features other than those currently being modeled are used as conditions. Parameters and Calculated using a deep neural network:

[0091]

[0092]

[0093] In the above formula, , The model consists of two neural network functions used to compute distribution parameters from conditional features. The input layer receives all features except the target feature. The hidden layer applies BatchNorm normalization and ReLU activation, embeds a feature attention mechanism and residual blocks to enhance the network's expressive power. The output layer predicts the α and β parameters of the Beta distribution and applies Softplus to ensure the parameters are positive, implementing parameter validity checks to prevent numerical instability.

[0094] The probability density function of the Beta distribution is:

[0095]

[0096] in, The Beta function is defined as follows:

[0097]

[0098] This is the Gamma function. Parameters and Output by network and passed through softplus transformation:

[0099]

[0100]

[0101] Where the softplus function is defined as:

[0102]

[0103] To ensure numerical stability, the parameters are limited:

[0104]

[0105]

[0106] (4) For time-related features (start charging time, charging duration), a Gaussian mixture model (GMM) is constructed:

[0107]

[0108] In the above formula, is the probability of under the condition , is the current feature being modeled, is all other features except the current modeled feature, as a condition, , and are calculated by a deep neural network:

[0109]

[0110]

[0111]

[0112] In the above formula, , , are neural network functions used to calculate weights, means and standard deviations from conditional features, respectively. The basic structure of the model is similar to the Beta distribution network, with a conditional encoder added to allow other features to adjust the distribution. The output layer predicts the mean, standard deviation and weight parameters of the mixed Gaussian, and applies log_softmax to improve numerical stability and implement a backup distribution mechanism in abnormal situations.

[0113] The probability density function of the Gaussian mixture model is:

[0114] ​

[0115] where is the number of mixed components, is the weight of the i th Gaussian component in the mixture, denotes a normal distribution, and are the mean and standard deviation of the i th component, respectively, denotes a normal distribution with mean and variance .

[0116] The computation of these parameters by the network is:

[0117]

[0118]

[0119]

[0120] where, The function is defined as:

[0121]

[0122] The conditional information fusion adopts:

[0123]

[0124] where, , is the feature set input to the conditional encoder, including all features except the current predicted feature, for example, when predicting a feature in a certain dimension, contains the feature values of the other 5 dimensions, is the conditional encoding, which represents the calculation process of the conditional information, aiming to convert other features into conditional information that has an impact on the current predicted feature, so as to adjust the distribution of the current predicted feature.

[0125] (5) For discrete features (battery capacity, user type), a classification distribution model is constructed:

[0126]

[0127] In the above formula, is the probability vector of the classification distribution, where each element represents the probability of the corresponding category, which is calculated by a deep neural network:

[0128]

[0129] In the above formula, is a neural network function for computing class probabilities from conditional features. In addition to the basic network structure, the classification distribution model adds a feature gating mechanism, applies a Dropout regularization layer to prevent overfitting, and uses a Softmax activation function in the output layer to generate a class probability distribution.

[0130] The mathematical expression of the feature gating mechanism is:

[0131]

[0132]

[0133] The class probability is calculated as:

[0134]

[0135]

[0136] In the above formula, is the number of classes, represents element-wise multiplication, i.e., Hadamard product, and represents the modulation of features by the gating mechanism, is the weight vector generated by the feature gating mechanism for selectively focusing on features, is the intermediate layer representation of the neural network, and the features after gating processing, represents the original class scores without softmax.

[0137] Step S2, through the conditional probability model and the conditional probability chain rule , implicitly represents the joint probability distribution of the Electrical Vehicle (EV) data.

[0138] This step uses a conditional probability neural network model for training, optimizing the parameters of the conditional probability distribution so that the model can capture the mutual dependence between features. The training objective is to maximize the conditional log-likelihood:

[0139]

[0140] Specifically, referring to Figure 2 , the training process includes data preprocessing, model initialization, feature attention and residual connection mechanism application, and gradient descent update steps. In each training round, the parameters of each conditional probability model are updated in turn, and finally the trained model parameters are obtained. Step S2 includes:

[0141] Step S201, data preprocessing.

[0142] Read the original charging data, filter six features of initial SOC, terminal SOC, start time, duration, battery capacity and user label; reset the start time to the standard reference time, such as 6 am; map the battery capacity to the category label; create a data loader and set the batch size to 512.

[0143] Step S202, initialize Beta model, GMM model and Discreate model parameters .

[0144] Initialize six conditional probability models corresponding to six feature dimensions, two Beta distribution models for initial SOC and terminal SOC, two GMM models for start time and duration, and two discrete distribution models for battery capacity and user type.

[0145] Step S203, model training.

[0146] During training, use the Adam optimizer with an initial learning rate of 0.005 and apply the LinearLR learning rate scheduler to linearly reduce the learning rate to half during training. Each batch of data is used to calculate the loss by forward propagation, perform gradient backpropagation and parameter update, record the training loss of each model, implement an abnormal handling mechanism to ensure the robustness of the training process.

[0147] Loss function calculation:

[0148] Beta distribution model:

[0149]

[0150] where is the conditional Beta distribution probability density.

[0151] GMM model:

[0152]

[0153] Discrete distribution model:

[0154]

[0155] Learning rate scheduling strategy:

[0156]

[0157] where, is the learning rate of the t-th round, is the initial learning rate, is the total number of rounds, represents the calculation of expectation, The termination factor is 0.5 in this embodiment.

[0158] Referring to Figure 2 The training process specifically includes the following steps:

[0159] (1) For each training round e Execute (2)-(5) from 1 to E The training round reaches E After executing (6).

[0160] (2) Apply attention mechanism to extract relevant features Where is the hidden representation of the i th feature before applying attention, is the hidden representation after applying the attention mechanism.

[0161] (3) Apply residual connection to improve gradient flow Where is the hidden representation after applying the residual connection, i.e. the intermediate feature vector obtained after processing the original input features through the neural network layer, which captures the abstract features and deeper patterns of the data.

[0162] (4) Calculate the gradient i of the variable .

[0163] (5) Update the weights of the variable i using the gradient descent method, return to (1).

[0164] (6) End all training and return model parameters .

[0165] Step S3, through Gibbs sampling, multiple iterations converge to states that meet the joint probability distribution, generating electric vehicle charging events.

[0166] Referring to Figure 3 , the data generation process is based on Gibbs sampling technology, including parameter initialization, batch sample initialization, multi-step iterative sampling, and sample post-processing steps. Through iterative sampling of conditional probability models, electric vehicle charging behavior data that meets physical constraints is generated. Step S3 specifically includes:

[0167] Step S301, initialize the sample size N , the number of sampling steps S , the batch size B , the probability model and its parameters

[0168] Load the trained six models, initialize the batch sample matrix, and randomly generate initial values:

[0169]

[0170] where d is the feature dimension, d = 6 in this method.

[0171] Step S302, initialize an empty sample set Store the samples.

[0172] Initialize an empty sample set .

[0173] Step S303, iterative calculation.

[0174] The iterative process specifically includes:

[0175] (1) For each batch b Execute (2)-(3) from 1 to N / B After N / B , the batch is executed.

[0176] (2) Random value initialization batch sample .

[0177] (3) For each step s Execute (4) from 1 to S After S , execute (8).

[0178] (4) For each variable i Execute (5) from 1 to m After m , , execute step (3).

[0179] (5) Calculate the conditional distribution

[0180] (6) Sample new values from the conditional distribution

[0181] (7) Apply constraints according to variable types, , return to step (4).

[0182] (8) Add the final sample to the dataset , , execute step (1).

[0183] where, in step (7), add constraints to specific features to ensure the physical reasonableness of the generated data:

[0184] The SOC value is limited in the range of [0, 1];

[0185] The start time is limited in the range of [0, 1], corresponding to 0-24 hours;

[0186] The charging duration is limited to a positive value.

[0187] In step S304, the generated samples are post-processed.

[0188] The generated samples are post-processed to filter valid charging data, including the following constraints:

[0189] The charging amount is a positive value: Final SOC > Initial SOC.

[0190] The charging duration is not zero: Duration > 0.

[0191] The charging power is reasonable: (Final SOC - Initial SOC) * Battery capacity / Duration / 100 < 120kW, where Final SOC and Initial SOC are the state of charge after charging and before charging, respectively, Duration is the charging duration, and Battery capacity is the battery capacity.

[0192] In step S305, the processed data set is returned .

[0193] The filtered valid charging behavior data is saved as structured data for electric vehicle charging behavior analysis and prediction.

[0194] To verify the effectiveness of the method, the distribution of each feature of the original charging data in step S201 and the data set in step S305 are compared, as shown in Figure 4 The distribution comparison of the electric vehicle charging behavior data generated by the method (slash) and the original data (blank) on continuous features (initial SOC, end SOC, start time, and charging duration). It can be seen that the generated data successfully retains the distribution characteristics of the original data, especially in the multi-peak distribution characteristics (such as the start charging time). See Figure 5 The distribution comparison of the electric vehicle charging behavior data generated by the method (slash) and the original data (blank) on discrete features (battery capacity and user label). The generated data accurately restores the distribution ratio of different battery capacity types and the distribution ratio of user types.

[0195] According to Figure 4 and Figure 5The method generates electric vehicle charging behavior data (Generate data) on the statistical distribution of initial SOC (Initial SOC), final SOC (Final SOC), start time (Start time), duration (Duration), battery capacity (Battery capacity), and user label (User label), which is highly consistent with the raw data (Raw data), proving that the method can effectively capture and restore the complex characteristics of electric vehicle charging behavior. Compared with traditional methods, by introducing the attention mechanism and residual connection, the method significantly improves the expression ability and stability of the model, especially in handling multi-peak distribution characteristics and maintaining the dependence between features.

[0196] Embodiment 2

[0197] On the basis of embodiment 1, the present embodiment provides an electronic device, comprising: one or more processors and a memory, the memory having one or more programs stored therein, the one or more programs comprising instructions for performing the attention and conditional probability distribution based electric vehicle charging data generation method as described in embodiment 1.

[0198] As Figure 6 described, at the hardware level, the electronic device includes a processor, an internal bus, a network interface, a memory, and a non-volatile memory, and of course, it can also include other hardware required by the business. The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs to implement the above Figure 1 described method. Of course, in addition to the software implementation, the present application does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc., that is, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or a logic device.

[0199] The memory can include non-permanent memory in a computer readable medium, random access memory (RAM) and / or non-volatile memory such as read-only memory (ROM) or flash memory (flash RAM). The memory is an example of a computer readable medium.

[0200] Computer-readable media includes permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology for information storage. Information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassette, magnetic disk storage or other magnetic storage device, or any other non-transmission medium that can be used to store information accessible by a computing device. According to the definition herein, computer-readable media does not include transitory media such as modulated data signals and carriers.

[0201] The present application integrates different types of probability distribution models (Beta distribution, Gaussian mixture model and categorical distribution) in the same framework, selects the most suitable probability model for different characteristics of electric vehicle charging behavior characteristics (continuous bounded value, continuous unbounded value and discrete value), improves the modeling accuracy and expression ability; combine deep neural network with conditional probability distribution, use neural network to dynamically predict probability distribution parameters, instead of fixed parameter distribution in traditional method. This design enables the model to learn the nonlinear dependence between features, greatly improving the expression ability and flexibility of the model.

[0202] The above is only a specific embodiment of the present application, but the protection scope of the present application is not limited thereto, any person skilled in the art can easily think of various equivalent modifications or replacements within the technical range disclosed by the present application, and these modifications or replacements should be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. A method for generating electric vehicle charging data based on attention and conditional probability distribution, characterized in that, Includes the following steps: A feature space for electric vehicle charging behavior is constructed. For continuous value features, time-related features, and discrete value features, feature-level deep neural network-enhanced conditional probability modeling is performed to obtain a conditional probability neural network model based on feature attention and residual blocks. Acquire electric vehicle charging behavior training data and train the conditional probability neural network model using a learning rate that decreases with the number of training rounds; Based on the trained conditional probabilistic neural network model, Gibbs sampling is performed under variable constraints to filter electric vehicle charging behavior data that conforms to physical constraints. The filtered valid charging behavior data is then saved as structured data for electric vehicle charging behavior analysis and prediction. The continuous value features include the initial state of charge and the final state of charge; the time-related features include the start time of charging and the duration of charging; and the discrete value features include battery capacity and user type. The physical constraints include: The charge level is positive: Final SOC > Initial SOC; Charging duration is not zero: Duration > 0; Reasonable charging power: (Final SOC - Initial SOC) * Battery capacity / Duration / 100 < 120kW; Where Final SOC and Initial SOC are the states of charge before and after charging, respectively; Duration is the charging duration; and Battery capacity is the battery capacity. The construction process of the conditional probability neural network model includes: (1) Construct a feature attention mechanism module, which includes the following structure: In the formula, The input feature vector represents a sample point in the feature space. The expression represents the Sigmoid activation function. The second term on the right-hand side of the equation represents the residual connection, which directly adds the original input to the output of the attention mechanism, improving information flow and gradient propagation. This is the weight matrix; (2) Construct the residual block module, which contains the following structure: In the formula, Presentation layer normalization operation, For the input feature vector, (3) For continuous value characteristics, construct a Beta distribution model; (4) Construct a Gaussian mixture model for time-related features; (5) Construct a classification distribution model for discrete features.

2. The method for generating electric vehicle charging data based on attention and conditional probability distribution according to claim 1, characterized in that, The conditional probability modeling of the deep neural network-enhanced continuous-value features is as follows: in, For the condition is Under the premise The probability, Features for modeling For all features other than those modeled, , As weight, , For bias, The conditional probability density of features. For the Gamma function, , To limit the parameters to a preset range, This is the hidden layer representation of the neural network after processing with attention mechanisms and residual connections. , These are two neural network functions.

3. The method for generating electric vehicle charging data based on attention and conditional probability distribution according to claim 1, characterized in that, The conditional probability modeling of the time-related features enhanced by a deep neural network is as follows: in, For the condition is Under the premise The probability, Features for modeling For all features other than those modeled, , , , As weight, , , , For bias, For the amount of mixed components, For the first The weights of each component Indicates a normal distribution. and The first The mean and standard deviation of each component. , The preset minimum and maximum values, For a restricted interval function, The set of features input to the conditional encoder includes all features except those currently being predicted. , , This is a neural network function.

4. The method for generating electric vehicle charging data based on attention and conditional probability distribution according to claim 1, characterized in that, The conditional probability modeling of the deep neural network-enhanced discrete-value features is as follows: in, For feature-gated results, It is the Sigmoid activation function. , , As weight, , , For bias, The set of features input to the conditional encoder includes all features except those currently being predicted. Represents element-wise multiplication. The discrete value characteristic is The probability, Target features y Value is a category c The corresponding logit value, For the number of categories, Let be the probability vector of the categorical distribution, where each element represents the probability of the corresponding class. For neural network functions, For the condition is Under the premise The probability, Features for modeling This refers to all features other than those used in modeling.

5. The method for generating electric vehicle charging data based on attention and conditional probability distribution according to claim 1, characterized in that, The process of training the conditional probability neural network model includes the following steps: Feature extraction, normalization, and encoding are performed on the training data of electric vehicle charging behavior. Initialize the parameters of the conditional probability model corresponding to each feature; In each training epoch, gradient flow is improved through residual connections, features are extracted through attention mechanisms, the gradient of each variable is calculated, and the parameters of the corresponding conditional probability model are updated using gradient descent with a learning rate that decreases as the training epoch increases. After training is complete, the parameters of the conditional probability model are returned.

6. The method for generating electric vehicle charging data based on attention and conditional probability distribution according to claim 5, characterized in that, The learning rate is: in, For the first t Learning rate of the round, The initial learning rate, The total number of rounds. This is the termination factor.

7. The method for generating electric vehicle charging data based on attention and conditional probability distribution according to claim 1, characterized in that, The process of using a trained conditional probability neural network model to perform Gibbs sampling under variable constraints and filter electric vehicle charging behavior data that conforms to physical constraints includes the following steps: Initialize the batch sample matrix and generate initial values; The sample values ​​are updated iteratively using Gibbs sampling. Set variable-level constraints; After the number of iterations reaches a threshold, a stable distribution of samples is obtained; Filter electric vehicle charging behavior data that conforms to physical constraints; The filtered electric vehicle charging behavior data is saved as structured data for electric vehicle charging behavior analysis and prediction.

8. An electronic device, characterized in that, include: One or more processors and a memory, wherein the memory stores one or more programs, the one or more programs including instructions for executing the electric vehicle charging data generation method based on attention and conditional probability distribution as described in any one of claims 1-7.

9. A computer-readable storage medium, characterized in that, Includes one or more programs executable by one or more processors of an electronic device, said one or more programs including instructions for performing the electric vehicle charging data generation method based on attention and conditional probability distribution as described in any one of claims 1-7.

Citation Information

Patent Citations

  • A method and system for predicting load of multiple types of electric vehicles based on charging behavior

    CN114580789B

  • Online estimation method and system for state of charge of energy storage battery based on deep learning combined extended Kalman filtering

    CN116359742A

  • Dynamic health adaptive monitoring method and system using artificial intelligence

    CN119480112A