LSTM model-based charging load prediction method and terminal

Through the charging amount prediction method based on the LSTM model, the information sequence is constructed using historical charging data and encoded and decoded, the problem of charging amount prediction of optical storage charging stations is solved, and accurate charging amount prediction and operating cost reduction is achieved.

WO2025091727A1PCT designated stage expired Publication Date: 2025-05-08CONTEMPORARY NEBULA TECH ENERGY CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/079215
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-11-02
Filing Date
2024-02-29
Publication Date
2025-05-08

AI Technical Summary

Technical Problem

How to effectively predict the charge amount of the optical storage charging station to help the operation work plan in advance and reduce operating costs.

Method used

The charging amount prediction method based on the LSTM model is adopted to construct a charging information sequence by obtaining historical charging data, and encoding and decoding is used using the LSTM model to implement the Seq2Seq framework and charge prediction is performed.

Benefits of technology

It realizes effective prediction of the charging capacity of the optical storage charging inspection station, helps the operation work to plan in advance, reduces operating costs, and improves the accuracy of charging capacity scheduling.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024079215_08052025_PF_FP_ABST
    Figure CN2024079215_08052025_PF_FP_ABST
Patent Text Reader

Abstract

The present invention relates to the field of charging load prediction, and in particular to an LSTM model-based charging load prediction method. The method comprises: acquiring historical charging data of a target station, and constructing charging information sequences on the basis of the historical charging data; performing encoder-based encoding on the charging information sequences by means of an LSTM model to obtain encoded information of the charging information sequences; and performing information extraction and concatenation on the basis of the encoded information, and using a multi-layer LSTM model to perform decoding to obtain prediction data. According to the present invention, charging information sequences are constructed on the basis of historical charging data, encoder-based encoding is performed by means of an LSTM model, and upon information extraction and concatenation, a multi-layer LSTM model is used to perform decoding, so that an LSTM model-based Seq2Seq framework is achieved, and the charging load of a photovoltaic-storage-charging-inspection station can be effectively predicted.
Need to check novelty before this filing date? Find Prior Art

Description

A charging capacity prediction method and terminal based on LSTM model Technical Field

[0001] The present invention relates to the technical field of charge capacity prediction, and in particular to a charge capacity prediction method and terminal based on an LSTM model. Background Art

[0002] As the popularity of electric vehicles increases, more and more charging stations are being used as supporting facilities. One type of charging station is called a photovoltaic, energy storage, charging and inspection station, which has the functions of photovoltaic + energy storage + charging + inspection. In the daily operation of the station, reasonable arrangement of the charging time of energy storage facilities is conducive to reducing operating costs and meeting peak charging needs, which is of great significance to the energy scheduling of the photovoltaic, energy storage, charging and inspection station.

[0003] Therefore, it is very necessary to predict the charging capacity of the solar storage charging and inspection station, which helps to carry out operations that require advance planning using the charging capacity. Technical issues

[0004] The technical problem to be solved by the present invention is to provide a charging capacity prediction method and terminal based on the LSTM model to realize the charging capacity prediction of the solar storage and charging inspection station. Technical Solutions

[0005] In order to solve the above technical problems, the technical solution adopted by the present invention is:

[0006] A charging capacity prediction method based on an LSTM model includes the following steps:

[0007] S1. Obtain historical charging data of a target station and construct a charging information sequence based on the historical charging data;

[0008] S2. Encode each of the charging information sequences using an LSTM model to obtain encoding information of each of the charging information sequences;

[0009] S3. Extract and concatenate information based on the encoded information, and use a multi-layer LSTM model for decoding to obtain predicted data.

[0010] In order to solve the above technical problems, another technical solution adopted by the present invention is:

[0011] A charging capacity prediction terminal based on an LSTM model includes a processor, a memory, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the charging capacity prediction method based on the LSTM model described above are implemented. Beneficial effects

[0012] The beneficial effects of the present invention are as follows: a charging capacity prediction method and terminal based on the LSTM model of the present invention constructs a charging information sequence according to historical charging data, encodes it through an LSTM model, and uses a multi-layer LSTM model for decoding after information extraction and splicing, realizing a Seq2Seq framework based on the LSTM model, which can effectively predict the charging capacity of a solar storage and charging inspection station. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] FIG1 is a flow chart of a method for predicting charging capacity based on an LSTM model according to an embodiment of the present invention;

[0014] FIG2 is a structural diagram of a charging capacity prediction terminal based on an LSTM model according to an embodiment of the present invention;

[0015] FIG3 is a structural example diagram of a prediction model for unstable small charge capacity scenarios of a charge capacity prediction method based on an LSTM model according to an embodiment of the present invention;

[0016] FIG4 is a structural example diagram of a stable small charge capacity scenario prediction model of a charge capacity prediction method based on an LSTM model according to an embodiment of the present invention;

[0017] FIG5 is a structural example diagram of a stable large charge capacity scenario prediction model of a charge capacity prediction method based on an LSTM model according to an embodiment of the present invention;

[0018] FIG6 is a structural example diagram of a prediction model for an unstable large charge capacity scenario of a charge capacity prediction method based on an LSTM model according to an embodiment of the present invention;

[0019] FIG7 is a flowchart illustrating a scenario-based method for predicting charging capacity based on an LSTM model according to an embodiment of the present invention;

[0020] FIG8 is a diagram illustrating an example of an LSTM unit structure of a charging capacity prediction method based on an LSTM model according to an embodiment of the present invention;

[0021] FIG9 is an example diagram of a fully connected layer of a charging capacity prediction method based on an LSTM model according to an embodiment of the present invention;

[0022] Description of labels:

[0023] 1. A charging capacity prediction terminal based on an LSTM model; 2. A processor; 3. A memory. Modes for Carrying Out the Invention

[0024] To illustrate the technical content, achieved objectives and effects of the present invention in detail, the following description is given in conjunction with the embodiments and accompanying drawings.

[0025] Referring to FIG1 and FIG3 , a charging capacity prediction method based on an LSTM model includes the following steps:

[0026] S1. Obtain historical charging data of a target station and construct a charging information sequence based on the historical charging data;

[0027] S2. Encode each of the charging information sequences using an LSTM model to obtain encoding information of each of the charging information sequences;

[0028] S3. Extract and concatenate information based on the encoded information, and use a multi-layer LSTM model for decoding to obtain predicted data.

[0029] From the above description, it can be seen that the beneficial effects of the present invention are: a charging capacity prediction method and terminal based on the LSTM model of the present invention constructs a charging information sequence according to historical charging data, encodes it through the LSTM model, and uses a multi-layer LSTM model for decoding after information extraction and splicing, realizing a Seq2Seq framework based on the LSTM model, which can effectively predict the charging capacity of the optical storage and charging inspection station.

[0030] Furthermore, the charging information sequence includes a historical charging sequence within a first preset number of days, a charging sequence on the same day of each week within a first preset number of weeks, and holiday information and corresponding charging sequences within a second preset number of days;

[0031] Step S3 includes the steps of:

[0032] S31, extracting information from the encoded information through a fully connected layer to obtain an information vector;

[0033] S32. Concatenate the information vectors obtained by extracting the coded information of each charging information sequence;

[0034] S33. Use a multi-layer LSTM model to decode the concatenated data and obtain the predicted data through the fully connected layer.

[0035] As can be seen from the above description, the charging information sequence considers holiday factors and the cyclical factors of each day of the week to predict charging capacity, improving prediction accuracy. Furthermore, constructing the charging information sequence and predicting charging capacity on a daily basis is more suitable for charging scenarios where there are no vehicles charging for most of the day, with only two or three periods of charging. However, these charging periods are highly random and have no regular pattern based on long-term historical data.

[0036] Furthermore, the charging information sequence includes a historical charging sequence within a first preset number of days, a charging sequence for the same day and time period of each week within a first preset number of weeks, a charging sequence for the same time period of each day within a second preset number of weeks, and holiday information and corresponding charging sequences within a second preset number of days;

[0037] Step S1 is specifically as follows:

[0038] S11. Obtain the peak, valley, and flat electricity price periods and historical charging data of the target station, aggregate and calculate the daily charging data of the target station according to the peak, valley, and flat electricity price periods, and obtain the charging capacity of the target station in each time period of each day;

[0039] S12: Construct a historical charging sequence within a first preset number of days, a charging sequence for the same day and time period of each week within a first preset number of weeks, a charging sequence for the same time period of each day within a second preset number of weeks, holiday information within a second preset number of days, and corresponding charging sequences.

[0040] From the above description, it can be seen that in addition to considering holiday factors and periodic factors of each day of the week, the peak, valley and flat electricity price periods of the target station are also considered. The charging data is aggregated and calculated according to the peak, valley and flat electricity price periods, and a charging sequence based on the peak, valley and flat electricity price periods is constructed for charging capacity prediction, thereby improving the accuracy of charging capacity prediction. This is especially suitable for charging scenarios where there are no cars charging in most periods, and cars charging in a few periods, but the charging periods are regular. From the perspective of long-term historical data, the charging periods are relatively concentrated every day.

[0041] Furthermore, step S3 includes the steps of:

[0042] S31, extracting information from the encoded information through a fully connected layer to obtain an information vector;

[0043] S32. Concatenate the information vectors obtained by extracting the coded information of each charging information sequence;

[0044] S33. Repeat the spliced ​​data, then use the multi-layer LSTM model to decode it, and obtain the charging capacity prediction data for each time period of each day through the fully connected layer.

[0045] From the above description, it can be seen that performing a Repeat action on the spliced ​​data is more beneficial to the prediction of the Seq2Seq architecture of the encoder-decoder and improves the accuracy of the prediction.

[0046] Furthermore, the charging information sequence includes a historical charging sequence within a first preset number of days, a charging sequence for the same day and time period of each week within a first preset number of weeks, a historical weather sequence, and holiday information within a second preset number of days and the corresponding charging sequence;

[0047] Step S1 is specifically as follows:

[0048] S11. Obtain historical charging data of a target station, perform aggregate calculations on an hourly basis, and obtain the charging capacity of the target station per hour per day.

[0049] S12: Create a historical charging sequence within a first preset number of days, a charging sequence within a first preset number of weeks on the same day and hour of each week, a historical weather sequence, holiday information within a second preset number of days, and corresponding charging sequences.

[0050] As can be seen from the above description, in addition to considering holiday factors and periodic factors based on each day of the week, combined with weather factors, charging information is aggregated on an hourly basis to construct data series, thereby improving the accuracy of charging capacity predictions. This is particularly suitable for scenarios with stable, large hourly charging capacities, where vehicles are charging for most of the day and the charging capacity during the same period fluctuates around a certain value on different days. This provides accurate hourly charging predictions.

[0051] Furthermore, step S3 includes the steps of:

[0052] S31, extracting information from the encoded information through a fully connected layer to obtain an information vector;

[0053] S32. Concatenate the information vectors obtained by extracting the coded information of each charging information sequence;

[0054] S33, performing a Repeat action on the spliced ​​data, and splicing it with the weather information and holiday information of the sample day;

[0055] S34. Based on the data obtained in step S33, a multi-layer LSTM model is used for decoding, and the charge capacity prediction data for each hour of each day is obtained through a fully connected layer.

[0056] From the above description, it can be seen that after the data is repeated, the weather information and holiday information of the sample day are spliced ​​together to predict the charging capacity, thereby improving the accuracy of the prediction.

[0057] Furthermore, step S1 further includes constructing a short-term charging sequence;

[0058] The short-term charging sequence includes a charging sequence within a preset number of hours and charging information for the previous hour;

[0059] wherein the preset number of hours is not less than two;

[0060] Step S2 further includes the steps of:

[0061] Encode each of the short-term charging sequences through an LSTM model to obtain encoding information of each short-term charging sequence;

[0062] Step S3 is replaced by:

[0063] Executing steps S31 to S33 on the encoded information of each charging information sequence, and decoding the data obtained in step S33 using a multi-layer LSTM model to obtain benchmark prediction data for each hour of each day;

[0064] Executing steps S31 to S32 on the encoded information of each charging information sequence and each short-term charging sequence, and performing a Repeat action on the spliced ​​data. Based on the obtained data, a multi-layer LSTM model is used for decoding to obtain fluctuation prediction data for each hour of each day;

[0065] According to the sum of the reference prediction data and the fluctuation prediction data for each hour of each day, the charge amount prediction data for each hour of each day is obtained.

[0066] From the above description, it can be seen that on the basis of the charging prediction of the hourly stable large charging volume scenario, a fluctuation prediction structure is added, and a short-term charging sequence is introduced to perform fluctuating power prediction. The charging prediction results of the hourly stable large charging volume scenario are corrected according to the obtained fluctuation prediction data to improve the prediction accuracy. This is especially suitable for scenarios where there is charging volume in 24 time periods every day, but the charging volume fluctuates greatly.

[0067] Please refer to Figure 2, a charging capacity prediction terminal based on the LSTM model includes a processor, a memory, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the charging capacity prediction method based on the LSTM model described above are implemented.

[0068] The present invention provides a charging capacity prediction method and terminal based on an LSTM model, which are suitable for predicting the charging capacity of a solar storage and charging inspection station.

[0069] Referring to Figures 1 and 3, the first embodiment of the present invention is:

[0070] A charging capacity prediction method based on an LSTM model includes the following steps:

[0071] S1. Obtain historical charging data of a target station and construct a charging information sequence based on the historical charging data;

[0072] The charging information sequence includes a historical charging sequence within a first preset number of days, a charging sequence on the same day of each week within a first preset number of weeks, and holiday information within a second preset number of days and corresponding charging sequences.

[0073] In this example, historical charging data for the target station is obtained and aggregated daily to obtain the station's daily charging capacity. A historical charging sequence for the past 30 days, a historical charging sequence for the same day of the week for the past eight weeks, and holiday information and corresponding charging sequences for the past 360 days are constructed.

[0074] In this embodiment, the first preset number of days is 30 days, the first preset number of weeks is 8 weeks, and the second preset number of days is 360. In other equivalent embodiments, the first preset number of days, the first preset number of weeks, and the second preset number of days can be adjusted according to actual needs.

[0075] S2. Encode each of the charging information sequences through an LSTM model to obtain encoding information of each of the charging information sequences.

[0076] In this embodiment, each historical sequence is encoded through the LSTM model to obtain the information of each historical sequence.

[0077] S3, extracting and splicing information according to the encoded information, and decoding using a multi-layer LSTM model to obtain predicted data;

[0078] Step S3 includes the steps of:

[0079] S31, extracting information from the encoded information through a fully connected layer to obtain an information vector;

[0080] S32. Concatenate the information vectors obtained by extracting the coded information of each charging information sequence;

[0081] S33. Use a multi-layer LSTM model to decode the concatenated data and obtain the predicted data through the fully connected layer.

[0082] In this embodiment, the encoded sequence information is further extracted through the fully connected layer; the information vectors extracted from each sequence are spliced; the spliced ​​information is decoded using a multi-layer LSTM; and the decoded information is used for daily charging capacity prediction through the fully connected layer.

[0083] The deep model structure can be seen in Figure 3.

[0084] The core of the charging capacity prediction scenario model of this embodiment is to aggregate the charging capacity of 24 time periods per day into the charging capacity of one day, and convert the charging capacity prediction problem of this type of scenario into the daily charging capacity problem of the charging station, avoiding the problem of large randomness of the charging period.

[0085] Referring to FIG. 1 and FIG. 4 , the second embodiment of the present invention is as follows:

[0086] A charging capacity prediction method based on an LSTM model, which differs from the first embodiment in that the charging information sequence includes a historical charging sequence within a first preset number of days, a charging sequence for the same day and time period of each week within a first preset number of weeks, a charging sequence for the same time period of each day within a second preset number of weeks, and holiday information and corresponding charging sequences within a second preset number of days;

[0087] Step S1 is specifically as follows:

[0088] S11. Obtain the peak, valley, and flat electricity price periods and historical charging data of the target station, aggregate and calculate the daily charging data of the target station according to the peak, valley, and flat electricity price periods, and obtain the charging capacity of the target station in each time period of each day;

[0089] In this embodiment, the peak, valley and flat electricity price periods of the target station are obtained, and the daily data of the charging station is aggregated and calculated according to the peak, valley and flat time periods to obtain the charging capacity of the station in each time period of each day.

[0090] S12: Construct a historical charging sequence within a first preset number of days, a charging sequence for the same day and time period of each week within a first preset number of weeks, a charging sequence for the same time period of each day within a second preset number of weeks, holiday information within a second preset number of days, and corresponding charging sequences.

[0091] In this embodiment, a charging sequence for the past 30 days, a charging sequence for the same time period on the same day of the week for the past 8 weeks, a charging sequence for the same time period for the past 2 weeks, and holiday information for the past 360 days are constructed.

[0092] In this embodiment, the first preset number of days is 30 days, the first preset number of weeks is 8 weeks, the second preset number of weeks is 2 weeks, and the second preset number of days is 360 days. In other equivalent embodiments, the first preset number of days, the first preset number of weeks, the second preset number of weeks, and the second preset number of days can be adjusted according to actual needs.

[0093] Step S3 includes the steps of:

[0094] S31, extracting information from the encoded information through a fully connected layer to obtain an information vector;

[0095] S32. Concatenate the information vectors obtained by extracting the coded information of each charging information sequence;

[0096] S33. Repeat the spliced ​​data, then use the multi-layer LSTM model to decode it, and obtain the charging capacity prediction data for each time period of each day through the fully connected layer.

[0097] In this embodiment, each historical sequence is encoded through the LSTM model to obtain the information of each historical sequence; the encoded sequence information is further extracted through the fully connected layer; the information vectors extracted from each sequence are spliced; the spliced ​​information is repeated to facilitate Seq2Seq prediction, and the information after the Repeat action is decoded using a multi-layer LSTM, and the decoded information is used for charging capacity prediction in each time period of each day through the fully connected layer.

[0098] The deep model structure can be seen in Figure 4.

[0099] The core of the charging capacity prediction scenario model of this embodiment lies in the charging capacity of 24 time periods every day. The time periods are divided according to the peak, valley and flat electricity prices of the charging station location, and the charging capacity of each time period of each day is aggregated. The charging capacity prediction problem of this type of scenario is converted into the charging capacity problem of each time period of the charging station every day, avoiding the problem of charging capacity fluctuation caused by small charging in each hour.

[0100] Referring to FIG. 1 and FIG. 5 , the third embodiment of the present invention is as follows:

[0101] A charging capacity prediction method based on an LSTM model, which differs from the first or second embodiment in that the charging information sequence includes a historical charging sequence within a first preset number of days, a charging sequence for the same day and time of each week within a first preset number of weeks, a charging sequence for the same hour of each day within a second preset number of weeks, a historical weather sequence, and holiday information within a second preset number of days and the corresponding charging sequence;

[0102] Step S1 is specifically as follows:

[0103] S11. Obtain historical charging data of a target station, perform aggregate calculations on an hourly basis, and obtain the charging capacity of the target station per hour per day.

[0104] In this embodiment, the daily data of the charging station is aggregated and calculated on an hourly basis to obtain the charging capacity of the station per hour.

[0105] S12. Create a historical charging sequence within a first preset number of days, a charging sequence for the same day and hour of each week within a first preset number of weeks, a historical weather sequence, a charging sequence for the same hour of each day within a second preset number of weeks, holiday information within a second preset number of days, and corresponding charging sequences.

[0106] In this embodiment, a charging sequence for the past 30 days, a charging sequence for the same hour on the same day of the week for the past 8 weeks, a charging sequence for the same hour for the past 2 weeks, holiday information for the past 360 days, and a historical weather sequence are constructed.

[0107] In this embodiment, the first preset number of days is 30 days, the first preset number of weeks is 8 weeks, the second preset number of weeks is 2 weeks, and the second preset number of days is 360 days. In other equivalent embodiments, the first preset number of days, the first preset number of weeks, the second preset number of weeks, and the second preset number of days can be adjusted according to actual needs.

[0108] Step S3 includes the steps of:

[0109] S31, extracting information from the encoded information through a fully connected layer to obtain an information vector;

[0110] S32. Concatenate the information vectors obtained by extracting the coded information of each charging information sequence;

[0111] S33, performing a Repeat action on the spliced ​​data, and splicing it with the weather information and holiday information of the sample day;

[0112] S34. Based on the data obtained in step S33, a multi-layer LSTM model is used for decoding, and the charge capacity prediction data for each hour of each day is obtained through a fully connected layer.

[0113] In this embodiment, each historical sequence is encoded through the LSTM model to obtain the information of each historical sequence; the encoded sequence information is further extracted through the fully connected layer; the information vectors extracted from each sequence are spliced; the spliced ​​information is repeated to facilitate Seq2Seq prediction; the vector after the Repeat action is spliced ​​with the weather information and holiday information of the sample day; multi-layer LSTM is used for information decoding; and the decoded information is used for charging capacity prediction in each time period of each day through the fully connected layer.

[0114] The deep model structure can be seen in Figure 5.

[0115] The core of the charging capacity prediction scenario model of this embodiment is that the charging capacity in the 24 time periods of a day is relatively stable. In this type of scenario, the charging capacity of each time period can be directly predicted.

[0116] Referring to FIG. 1 and FIG. 6 , the fourth embodiment of the present invention is as follows:

[0117] A charging capacity prediction method based on an LSTM model, which differs from the third embodiment in that step S1 further includes constructing a short-term charging sequence;

[0118] The short-term charging sequence includes a charging sequence within a preset number of hours and charging information for the previous hour;

[0119] Wherein, the preset number of hours is not less than two.

[0120] In this embodiment, the daily data of charging stations is aggregated and calculated on an hourly basis to obtain the charging capacity of the stations every hour of every day. This includes constructing charging sequences for the past 30 days, charging sequences for the same time period on the same day of the week for the past 8 weeks, charging sequences for the same time period for the past 2 weeks, holiday information for the past 360 days, historical weather sequences, short-term 24-hour charging sequences, and charging data for the previous hour.

[0121] In this city's embodiment, the first preset number of days is 30 days, the first preset number of weeks is 8 weeks, the second preset number of weeks is 2 weeks, the second preset number of days is 360 days, and the preset number of hours is 24 hours. In other equivalent embodiments, the first preset number of days, the first preset number of weeks, the second preset number of weeks, the preset number of hours and the second preset number of days can be adjusted according to actual needs, among which the preset number of hours can be adjusted to 3 hours, 6 hours or other values ​​according to needs.

[0122] Step S2 further includes the steps of:

[0123] Each of the short-term charging sequences is encoded by an encoder through an LSTM model to obtain encoding information of each short-term charging sequence.

[0124] Step S3 is replaced by:

[0125] Steps S31 to S33 are executed on the encoded information of each charging information sequence, and a multi-layer LSTM model is used to decode the data obtained in step S33 to obtain benchmark prediction data for each hour of each day.

[0126] In this embodiment, the acquisition of the benchmark prediction data may refer to the acquisition of the charge capacity prediction data for each hour of each day in the third embodiment.

[0127] Steps S31 to S32 are executed for the coded information of each charging information sequence and each short-term charging sequence, and a Repeat action is performed on the spliced ​​data. Based on the obtained data, a multi-layer LSTM model is used for decoding to obtain fluctuation prediction data for each hour of each day.

[0128] In this embodiment, each of the charging information sequences and each of the short-term charging sequences are respectively encoded through the LSTM model to obtain the information of each historical sequence; the encoded sequence information is further extracted through the fully connected layer; the information vectors extracted from each sequence are spliced; the spliced ​​information is repeated to facilitate Seq2Seq prediction; the information after the Repeat action is decoded using a multi-layer LSTM; the decoded information is used for the prediction of the fluctuating charging amount in each time period of each day through the fully connected layer to obtain the fluctuation prediction data.

[0129] According to the sum of the reference prediction data and the fluctuation prediction data for each hour of each day, the charge amount prediction data for each hour of each day is obtained.

[0130] In this embodiment, the baseline prediction data and the fluctuation prediction data are added to obtain the final charge capacity prediction value.

[0131] The depth model structure can be seen in Figure 6.

[0132] The core of the charging capacity prediction scenario model of this embodiment is that there is charging capacity in 24 time periods every day, but the charging capacity fluctuates greatly. In this type of scenario, a fluctuation prediction structure can be added to the stable large charging capacity prediction model to optimize the model and directly predict the charging capacity for each time period.

[0133] Please refer to FIG7 , the fifth embodiment of the present invention is:

[0134] A charging capacity prediction method based on an LSTM model differs from embodiments one to four in that, based on statistics of historical charging data of a target station, the steps in the charging capacity prediction method based on an LSTM model of the above embodiments one to four are selected to be used.

[0135] Referring to Figure 7, in this embodiment, the charging scenarios are divided into unstable small charging capacity scenarios (using the steps in a charging capacity prediction method based on an LSTM model in Example 1), stable small charging capacity scenarios (using the steps in a charging capacity prediction method based on an LSTM model in Example 2), stable large charging capacity scenarios (using the steps in a charging capacity prediction method based on an LSTM model in Example 3), and unstable large charging capacity scenarios (using the steps in a charging capacity prediction method based on an LSTM model in Example 4).

[0136] Among them, the unstable small charging volume scenario: 24 hours a day, there are no cars charging during most of the time, and there are cars charging during two or three periods, but the charging period is very random. From the long-term historical data, there is no regularity in the charging period.

[0137] Stable small charging volume scenario: 24 hours a day, there are no cars charging during most of the time, and there are cars charging during a few periods, but the charging periods are regular. From the long-term historical data, the daily charging periods are relatively concentrated.

[0138] Stable high-charging scenario: 24 hours a day, there are cars charging most of the time, and the charging volume in the same period fluctuates around a value on different days, with good regularity.

[0139] Unstable high charging volume scenario: There are cars charging most of the time 24 hours a day, but the charging volume in the same period will fluctuate on different days, with poor regularity.

[0140] The specific steps for scene division are:

[0141] S1. Obtain historical charging data from the solar-storage charging inspection station and collect statistics on the historical charging data;

[0142] S2. Obtain and classify the charging scenarios to which the solar-storage-charging inspection station belongs based on the statistically obtained degree of overlap of daily charging times, daily charging duration, and hourly charging amount;

[0143] Step S2 includes the steps of:

[0144] S21. Obtain the statistically obtained degree of overlap of daily charging times, daily charging duration, and hourly charging capacity;

[0145] The calculation of the degree of overlap is specifically as follows:

[0146] Divide a day into time periods and record whether there is charging behavior in each time period, generating a binary array of charging status for each time period of the day;

[0147] The binary array of charging conditions for a preset number of days is subjected to period overlap statistics, and the degree of overlap is calculated based on the number n of periods with the same charging conditions:

[0148] Overlap=n / 24;

[0149] In this embodiment, each day is divided into 24 hours. The presence of charging activity during this period is recorded as 1, and the absence of charging activity is recorded as 0. The degree of overlap is determined based on the charging period data of the past three days. If the charging conditions in the same period of the past three days are consistent, this period is defined as the charging condition and recorded as 1. Otherwise, it is recorded as 0. If the charging conditions in 21 of the 24 periods overlap, the degree of overlap is defined as 21 / 24 = 0.875. S22: Based on the degree of overlap, the charging scenario is classified as stable or unstable.

[0150] Step S22 is specifically as follows:

[0151] It is determined whether the overlap degree Overlap is greater than a preset stability threshold. If so, the charging scene is classified as stable; otherwise, the charging scene is classified as unstable.

[0152] In this embodiment, the stability threshold is set to 0.5. An overlap value greater than 0.5 is defined as a stable scenario, and otherwise an unstable scenario. In other equivalent embodiments, the stability threshold can be adjusted according to actual needs.

[0153] S23. Calculate a charge threshold based on the number and power of charging piles at the solar-storage-charging inspection station. Further classify charging scenarios into high-charge and low-charge scenarios based on the daily charging duration, the charge per charging duration, and the charge threshold.

[0154] Step S23 is specifically as follows:

[0155] Based on the daily charging time and the charging amount per time, calculate the average daily actual charging amount P_CHARGE of the solar-storage-charging inspection station;

[0156] Get the number of charging piles N and the charging power P of each charging pile at the solar storage and charging inspection station i , (i≤N), calculate the rated total charging power W of the solar storage charging inspection station per hour:

[0157] ;

[0158] If the actual total charge amount P_CHARGE>k*24*W, it is classified as a large charge amount scenario; otherwise, it is classified as a small charge amount scenario;

[0159] Wherein, k represents a preset ratio.

[0160] In this embodiment, it is assumed that the number of charging piles at a certain station is N, and the power of each charging pile is P. Then the total rated charging power of the station is NP. In 24 hours a day, if the daily charging amount of a station P_CHARGE>0.2*24*NP, it is defined as a large charging amount scenario, otherwise it is defined as a small charging amount scenario.

[0161] In this embodiment, the preset ratio is 0.2. In other equivalent embodiments, the ratio can be adjusted according to actual needs.

[0162] S3. Select a pre-trained prediction model based on the charging scenario of the solar-storage-charging inspection station to predict the charging capacity;

[0163] Step S3 is specifically as follows:

[0164] According to the stable / unstable, large / small charging scenarios of the solar storage and charging inspection station, the corresponding pre-trained prediction model is selected to predict the charging amount.

[0165] Please refer to FIG2 , the sixth embodiment of the present invention is:

[0166] A charging capacity prediction terminal 1 based on an LSTM model includes a processor 2, a memory 3, and a computer program stored in the memory 3 and runnable on the processor 2. When the processor 2 executes the computer program, the steps of the charging capacity prediction method based on the LSTM model described in any one of the above embodiments 1 to 5 are implemented.

[0167] The following is an explanation of some technical terms in this article:

[0168] Encoder-Decoder Architecture: The encoder-decoder architecture is a commonly used framework in machine learning. It consists of two main components: an encoder and a decoder. The encoder is responsible for processing the input data and capturing its representation in a compact and meaningful form. In the case of charge level prediction, the input data can be a series of historical charge levels. The encoder is typically composed of a recurrent neural network (RNN), such as a long short-term memory (LSTM) or a gated recurrent unit (GRU), or a more advanced model such as a Transformer. The encoder reads the input sequence step by step, updating its internal state at each step and generating a fixed-length vector representation, often called a "context vector" or "thought vector," which encodes the meaning of the input sequence. The decoder, on the other hand, uses the context vector generated by the encoder to generate the desired output sequence. Similar to the encoder, the decoder is typically implemented using an RNN or a Transformer. It takes the context vector as its initial input and generates the output sequence step by step, producing one element at a time. At each step, the decoder considers the previously generated element and its own internal state to predict the next element in the sequence. This process continues until the entire output sequence is generated. During training, the encoder-decoder model is trained by minimizing an appropriate loss function that measures the difference between the predicted output sequence and the true sequence. This is achieved by comparing the predicted sequence to the target sequence and adjusting the model's parameters through techniques such as backpropagation and gradient descent.

[0169] LSTM: Figure 8 shows a single LSTM unit, where x(t) represents the input at time step t; h(t-1) represents the hidden state at time step t-1 (the output of the previous time step); h(t) represents the hidden state at time step t (the output of the current time step); and y(t) represents the output at time step t. An LSTM unit has three key components: the input gate, which controls which information is input into the LSTM unit's memory cells; the forget gate, which controls which information is forgotten or deleted from the memory cells; and the output gate, which controls the flow of information from the memory cells to the hidden state and outputs the output at the current time step. The input, forget, and output gates of the LSTM unit generate probability values ​​between 0 and 1 using a sigmoid function. The outputs of these gates are multiplied by the memory cell state to control the flow of information. The LSTM unit also has a memory cell, which stores and transmits information. The information in the memory cell can be updated based on the input gate, forget gate, and new input. The entire LSTM model can be composed of multiple LSTM units, each of which is connected sequentially in time to achieve modeling and prediction of sequence data.

[0170] Fully connected layer: Please refer to Figure 9, which shows a fully connected layer, where: x represents the input vector (or the output from the previous layer); y represents the output vector (or the input passed to the next layer); W represents the weight matrix used to connect the input and output; b represents the bias vector used to offset the output value. In a fully connected layer, there is a connection between each input and each output. The input and weight are multiplied by matrix multiplication, and the bias vector is added to obtain the output vector. This process can be expressed as the following formula: y = W * x + b. Each neuron in the fully connected layer is connected to all neurons in the previous layer, so it can capture the complex relationships in the input vector. Fully connected layers are often used in the middle layer of deep neural networks to extract high-level features of the input data and pass them to subsequent layers for further processing and prediction.

[0171] Repeat: Also known as RepeatVector, in deep learning, RepeatVector is an operation used for data repetition. It repeats the input data multiple times to generate a new tensor. Specifically, the RepeatVector operation takes an input vector and repeats it multiple times to generate a new tensor. The purpose of this operation is to expand the input vector to a size that matches the target shape. It is often used in sequence generation tasks, where a vector is required as input and repeated at each time step to generate a complete sequence. For example, suppose we have an input vector x with a shape of (batch_size, input_dim) and we want to repeat it n times to generate a new tensor with a shape of (batch_size, n, input_dim). We can use the RepeatVector operation to achieve this goal. The mathematical representation of RepeatVector is: output = RepeatVector(n)(x), where n represents the number of repetitions and x represents the input vector. By using the RepeatVector operation, we can copy and repeat the input vector in sequence generation tasks to generate longer sequences. This is useful for models that need to utilize previous contextual information, such as recurrent neural networks or sequence-to-sequence models. It is important to note that the RepeatVector operation simply repeats the input vector multiple times and does not have any learning parameters. It is a pure data repetition operation.

[0172] Seq2Seq: Seq2Seq (Sequence-to-Sequence) is a deep learning framework for sequence-to-sequence tasks. Based on an encoder-decoder architecture, it maps one sequence to another by taking one as input and generating another as output. A Seq2Seq model consists of two main components: an encoder and a decoder. The encoder encodes the input sequence into a fixed-length vector representation that captures the semantics and context of the input sequence. Common encoder models include recurrent neural networks (RNNs) such as LSTMs or GRUs, as well as more advanced models such as the Transformer. The encoder processes each element of the input sequence step by step, updating its internal state and ultimately generating a context vector or "encoder output." The decoder receives the encoder output and a partial input of the target sequence (usually a special start token) and gradually generates elements of the target sequence. The decoder is also typically implemented based on an RNN or Transformer. At each time step, the decoder uses the output of the previous time step, the encoder output, and its own internal state to generate the next output element. This process continues until the entire target sequence is generated. During training, a Seq2Seq model optimizes its parameters by minimizing an appropriate loss function (such as cross-entropy loss) to ensure that the generated sequence is as close as possible to the target sequence. This typically involves using standard optimization techniques such as backpropagation and gradient descent. In summary, a Seq2Seq model encodes the input sequence into a fixed-length vector via an encoder and then decodes this vector into an output sequence via a decoder, thereby achieving sequence-to-sequence mapping. This framework has been widely applied in various fields and has achieved remarkable results.

[0173] In summary, the charging capacity prediction method and terminal based on the LSTM model provided by the present invention construct a charging information sequence according to historical charging data, encode it through the LSTM model, and use a multi-layer LSTM model for decoding after information extraction and splicing, realizing a Seq2Seq framework based on the LSTM model, which can effectively predict the charging capacity of the solar storage and charging inspection station.

[0174] The above descriptions are merely embodiments of the present invention and are not intended to limit the patent scope of the present invention. Any equivalent transformations made using the contents of the present invention's description and drawings, or directly or indirectly applied in related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A charging capacity prediction method based on LSTM model, characterized in that: Includes steps: S1. Acquire historical charging data of a target station, and construct a charging information sequence according to the historical charging data; S2. Encode each of the charging information sequences by an encoder through an LSTM model to obtain encoding information of each of the charging information sequences; S3. Extract and concatenate information according to the encoded information, and use a multi-layer LSTM model to decode to obtain predicted data.

2. According to a charging capacity prediction method based on LSTM model according to claim 1, it is characterized in that: The charging information sequence includes a historical charging sequence within a first preset number of days, a charging sequence on the same day of each week within a first preset number of weeks, and holiday information within a second preset number of days and a corresponding charging sequence; Step S3 includes the steps of: S31, extracting information from the encoded information through a fully connected layer to obtain an information vector; S32, concatenating the information vectors obtained by extracting the coded information of each charging information sequence; S33. Use a multi-layer LSTM model to decode the concatenated data, and obtain the predicted data through the fully connected layer.

3. The charging capacity prediction method based on the LSTM model according to claim 1, characterized in that: The charging information sequence includes a historical charging sequence within a first preset number of days, a charging sequence within a first preset number of weeks at the same time of the same day of each week, a charging sequence within a second preset number of weeks at the same time of each day, and holiday information within a second preset number of days and corresponding charging sequences; Step S1 is specifically as follows: S11, obtaining the peak, valley and flat electricity price time periods and historical charging data of the target station, aggregating and calculating the daily charging data of the target station according to the peak, valley and flat electricity price time periods, and obtaining the charging amount of the target station in each time period every day; S12: construct a historical charging sequence within a first preset number of days, a charging sequence for the same day and time period of each week within a first preset number of weeks, a charging sequence for the same time period of each day within a second preset number of weeks, holiday information within a second preset number of days and a corresponding charging sequence.

4. A charging capacity prediction method based on LSTM model according to claim 3, characterized in that: Step S3 includes the steps of: S31, extracting information from the encoded information through a fully connected layer to obtain an information vector; S32, concatenating the information vectors obtained by extracting the coded information of each charging information sequence; S33, repeat the spliced ​​data, and then use the multi-layer LSTM model to decode it, and obtain the charging amount prediction data for each time period of each day through the fully connected layer.

5. The charging capacity prediction method based on the LSTM model according to claim 1, characterized in that: The charging information sequence includes a historical charging sequence within a first preset number of days, a charging sequence for the same day and time period of each week within a first preset number of weeks, a charging sequence for the same time period of each day within a second preset number of weeks, a historical weather sequence, holiday information within a second preset number of days and a corresponding charging sequence; Step S1 is specifically as follows: S11, obtaining historical charging data of the target station, performing aggregate calculation in units of hours, and obtaining the charging capacity of the target station per hour per day; S12, creating a historical charging sequence within a first preset number of days, a charging sequence within a first preset number of weeks on the same day and hour of each week, a historical weather sequence, holiday information within a second preset number of days, and a corresponding charging sequence.

6. A charging capacity prediction method based on LSTM model according to claim 5, characterized in that: Step S3 includes the steps of: S31, extracting information from the encoded information through a fully connected layer to obtain an information vector; S32, concatenating the information vectors obtained by extracting the coded information of each charging information sequence; S33, performing a Repeat action on the spliced ​​data, and splicing it with the weather information and holiday information of the sample day; S34. According to the data obtained in step S33, a multi-layer LSTM model is used for decoding, and the charging amount prediction data for each hour per day is obtained through a fully connected layer.

7. A charging capacity prediction method based on LSTM model according to claim 6, characterized in that: Step S1 also includes constructing a short-term charging sequence; The short-term charging sequence includes a charging sequence within a preset number of hours and charging information of the previous hour; Wherein, the preset number of hours is not less than two; Step S2 also includes the steps of: Encode each of the short-term charging sequences through an LSTM model to obtain encoding information of each short-term charging sequence; Step S3 is replaced by: Execute steps S31 to S33 on the coded information of each charging information sequence, and decode using a multi-layer LSTM model according to the data obtained in step S33 to obtain benchmark prediction data for each hour of each day; Execute steps S31 to S32 for the coded information of each charging information sequence and each short-term charging sequence, and perform a Repeat action on the spliced ​​data. According to the obtained data, use a multi-layer LSTM model to perform decoding to obtain fluctuation prediction data for each hour of each day. The charge amount prediction data for each hour of each day is obtained according to the sum of the reference prediction data and the fluctuation prediction data for each hour of each day.

8. A charging capacity prediction terminal based on an LSTM model, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps in the charging capacity prediction method based on the LSTM model described in any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Electricity consumption prediction method and device, computer equipment and storage medium

    CN113284001A

  • Power dispatching method and terminal for optical storage charging station

    CN116436008A

  • Step-by-step decomposition model-based charging station utilization rate prediction method and system

    CN116644853A

  • Equipment management apparatus, equipment management system, equipment management method, and program

    WO2016166836A1