Photovoltaic string current prediction method and system based on CNN and LSTM methods

By applying CNN and LSTM methods to predict current, the problem of insufficient current monitoring accuracy of photovoltaic strings in the existing technology is solved, and higher current prediction accuracy and fault detection capabilities are achieved, and the photovoltaic power generation system is improved. stability.

CN114139766BActive Publication Date: 2024-12-10HUANENG DALI WIND POWER GENERATION CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111256410.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-10-27
Publication Date
2024-12-10
Estimated Expiration
2041-10-27

AI Technical Summary

Technical Problem

In the prior art, the accuracy of photovoltaic string current voltage monitoring and identification of problem strings is not high, making it difficult to effectively detect and maintain faults.

Method used

The photovoltaic string current prediction method based on CNN and LSTM methods is adopted. By acquiring spatiotemporal multi-dimensional data, the photovoltaic string current is predicted using a convolutional neural network and a long and short-term memory network to generate an accurate predicted current value.

Benefits of technology

It improves the accuracy of photovoltaic string current prediction, enhances the reliability of string fault detection and maintenance, and improves the stability of photovoltaic power generation system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114139766B_ABST
    Figure CN114139766B_ABST
Patent Text Reader

Abstract

The present invention discloses a photovoltaic string current prediction method and system based on CNN and LSTM methods. The method includes: obtaining the predicted string current data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located before the predicted moment, including the preset time length of the predicted moment; preprocessing the predicted string current data, obtaining the maximum current value and the minimum current value at the predicted moment, and the prediction sample data set; inputting the prediction sample data set into the trained current prediction model, predicting the predicted value of the photovoltaic string to be predicted at the predicted moment; generating the predicted current value of the photovoltaic string to be predicted at the predicted moment according to the maximum current value, the minimum current value and the predicted value. Thus, the predicted value of the photovoltaic string to be predicted at the predicted moment can be obtained by prediction, and the predicted current value of the photovoltaic string to be predicted at the predicted moment can be further obtained, and the method provided by the embodiment of the present invention is adopted, and the obtained predicted current value has a high accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of photovoltaic power generation, and in particular to a photovoltaic string current prediction method and system based on CNN and LSTM methods. Background Art

[0002] With the country's demand for energy conservation and emission reduction and the rise of clean energy, various power generation equipment using clean energy are becoming more and more popular, especially photovoltaic power generation.

[0003] At present, with the continuous development of the photovoltaic industry, the requirements for the reliable and stable operation of photovoltaic power generation systems are becoming higher and higher. The operation and maintenance of photovoltaic systems are receiving more and more attention and importance. As an important component of photovoltaic power generation systems, photovoltaic strings are particularly important for fault detection and maintenance.

[0004] In related technologies, the current and voltage of photovoltaic strings are monitored and the data of multiple strings are compared to identify problematic strings. However, the identification accuracy is not high. Summary of the Invention

[0005] The present invention aims to solve one of the technical problems in the above-mentioned technology at least to a certain extent.

[0006] To this end, the first purpose of the present invention is to propose a photovoltaic string current prediction method based on CNN and LSTM methods. For the first time, CNN (Convolutional Neural Network) and LSTM (Long Short-Term Memory) methods are applied to photovoltaic string current prediction based on spatiotemporal multidimensional data. By obtaining a prediction sample data set, the obtained prediction sample data set is input into a trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the time to be predicted, and further obtain the predicted current value of the photovoltaic string to be predicted at the time to be predicted, the photovoltaic string current prediction is highly accurate.

[0007] The second object of the present invention is to propose a photovoltaic string current prediction system based on CNN and LSTM methods.

[0008] A third object of the present invention is to provide an electronic device.

[0009] A fourth object of the present invention is to provide a computer-readable storage medium.

[0010] The first aspect of the present invention proposes a photovoltaic string current prediction method based on CNN and LSTM methods, including: obtaining predicted string current data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located within a preset time period before the predicted moment and including the predicted moment; preprocessing the predicted string current data to obtain the maximum current value and the minimum current value at the predicted moment, as well as a prediction sample data set; inputting the prediction sample data set into a trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted moment; generating the predicted current value of the photovoltaic string to be predicted at the predicted moment based on the maximum current value, the minimum current value and the predicted value.

[0011] In one embodiment of the present invention, preprocessing the predicted string current data to obtain a predicted sample data set includes:

[0012] The predicted string current data is sampled every first preset time interval, and the missing values ​​are interpolated using median filtering, which is recorded as I m,j , represents the current value of the mth PV string at time j; then the h strings of the same device are normalized at different times to generate predicted normalized data: in, The predicted normalized data of the m-th photovoltaic string at time j after normalization processing; among the predicted normalized data of the plurality of photovoltaic strings, N predicted normalized data before the time to be predicted are used as the predicted sample data set; wherein N is an integer greater than 0.

[0013] In one embodiment of the present invention, the current prediction model includes: a convolutional layer, a pooling layer, an LSTM layer and a fully connected layer. The prediction sample data set is input into the trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the time to be predicted, including: inputting the prediction sample data into the convolutional layer, the pooling layer, the LSTM layer and the fully connected layer in sequence to predict the predicted value of the photovoltaic string to be predicted at the time to be predicted.

[0014] In one embodiment of the present invention, the method further includes:

[0015] A training sample data set is obtained; the training sample data set is input into a current prediction model, and the current prediction model is trained to obtain a trained current prediction model.

[0016] In one embodiment of the present invention, obtaining a training sample dataset includes:

[0017] Acquire training string current data within a first time period during normal operation of multiple photovoltaic strings; and preprocess the training string current data to obtain a training sample data set.

[0018] In one embodiment of the present invention, preprocessing the training string current data to obtain a training sample data set includes:

[0019] The training string current data is sampled every second preset time interval, and the missing values ​​are interpolated using median filtering, which is recorded as I M,J , represents the current value of the Mth PV string at time J; then the H strings of the same device are normalized at different times to generate training normalized data: in, The training normalized data of the M-th photovoltaic string after normalization processing at time J is generated; the string current value at the first moment of any photovoltaic string in the training normalized data of the multiple photovoltaic strings is used as the dependent variable, and the string current values ​​of the multiple photovoltaic strings at M moments before the first moment are used as independent variables to generate the training sample data set; wherein M is an integer greater than 0.

[0020] In one embodiment of the present invention, inputting the training sample data set into the current prediction model and training the current prediction model to obtain a trained current prediction model includes:

[0021] The training sample data set is sequentially input into the convolution layer, pooling layer, LSTM layer and fully connected layer, the mean square error loss (MSE) is used as the loss function, and the adaptive matrix estimation Adam optimization algorithm is used to train the current prediction model to obtain a trained current prediction model.

[0022] The second aspect of the present invention proposes a photovoltaic string current prediction system based on CNN and LSTM methods, including: an acquisition unit, used to obtain predicted string current data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located within a preset time period before the predicted moment, including the predicted moment; a processing unit, used to preprocess the predicted string current data, obtain the maximum current value and the minimum current value at the predicted moment, and a prediction sample data set; a prediction unit, used to input the predicted sample data set into a trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted moment; a generation unit, used to generate the predicted current value of the photovoltaic string to be predicted at the predicted moment based on the maximum current value, the minimum current value and the predicted value.

[0023] The third embodiment of the present invention provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the method described in the first embodiment of the present invention is implemented.

[0024] The fourth embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon. When the program is executed by a processor, the method described in the first embodiment of the present application is implemented.

[0025] Additional aspects and advantages of the present invention will be set forth in part in the description which follows and, in part, will be obvious from the description which follows, or may be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:

[0027] Figure 1 Flowchart of a photovoltaic string current prediction method based on CNN and LSTM methods according to one embodiment of the present invention;

[0028] Figure 2 This is a flowchart of sub-step S2 of a photovoltaic string current prediction method based on a CNN and LSTM method according to an embodiment of the present invention;

[0029] Figure 3 is another flow chart of a photovoltaic string current prediction method based on CNN and LSTM methods according to an embodiment of the present invention;

[0030] Figure 4 This is a flowchart of sub-steps S100 of a photovoltaic string current prediction method based on CNN and LSTM methods according to an embodiment of the present invention;

[0031] Figure 5 Schematic diagram of the correlation between current data of different photovoltaic strings of the same device in a photovoltaic string current prediction method based on CNN and LSTM methods according to one embodiment of the present invention;

[0032] Figure 6 Schematic diagram of similarity of current data of the same photovoltaic string in a photovoltaic string current prediction method based on CNN and LSTM methods according to one embodiment of the present invention;

[0033] Figure 7 This is a flowchart of sub-step S102 of a photovoltaic string current prediction method based on a CNN and LSTM method according to an embodiment of the present invention;

[0034] Figure 8 2 is a schematic diagram of a photovoltaic string current prediction system based on a CNN and LSTM method according to an embodiment of the present invention;

[0035] Figure 9 FIG. 1 is a schematic structural diagram of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0036] The following describes embodiments of the present invention in detail, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present invention, and are not to be construed as limiting the present invention.

[0037] The following describes a photovoltaic string current prediction method and system based on CNN and LSTM methods according to an embodiment of the present invention with reference to the accompanying drawings.

[0038] Figure 1 The figure is a flowchart of a photovoltaic string current prediction method based on CNN and LSTM methods according to an embodiment of the present invention.

[0039] like Figure 1 As shown, the photovoltaic string current prediction method based on the CNN and LSTM method in an embodiment of the present invention includes:

[0040] S1: Acquire predicted string current data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located within a preset time period before and including the predicted moment.

[0041] In the embodiment of the present invention, predicted string current data of all photovoltaic strings in the device where the photovoltaic strings to be predicted are located within a preset time period before and including the predicted time is obtained.

[0042] Exemplarily, the photovoltaic string to be predicted may be a photovoltaic string in a combiner box or an inverter. When the photovoltaic string to be predicted is a photovoltaic string in a combiner box, the predicted string current data of all photovoltaic strings in the combiner box within a preset time length before the predicted moment including the predicted moment is obtained. When the photovoltaic string to be predicted is a photovoltaic string in an inverter, the predicted string current data of all photovoltaic strings in the inverter within a preset time length before the predicted moment including the predicted moment is obtained.

[0043] It should be noted that the time to be predicted can be a time in the future or a time in the past. The time in the future can be a time in the near future. In the embodiment of the present invention, the predicted string current data obtained is the predicted string current data within a preset time period before the time to be predicted.

[0044] In the embodiment of the present invention, the predicted string current data includes string current value data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located within a preset time period before and including the predicted time.

[0045] It can be understood that the predicted string current data of all photovoltaic strings in the device where the photovoltaic strings to be predicted are located is obtained within a preset time period before the predicted time and including the predicted time, wherein the preset time period can be 8 hours, or 12 hours, or 24 hours, or any other time period, and the embodiment of the present invention does not impose specific restrictions on this.

[0046] S2: Preprocess the predicted string current data to obtain the maximum current value and the minimum current value at the time to be predicted, as well as the prediction sample data set.

[0047] In an embodiment of the present invention, the predicted string current data of all photovoltaic strings in the device where the photovoltaic strings to be predicted are located, which are obtained within a preset time period before the predicted moment and including the predicted moment, are preprocessed to obtain the maximum current value and the minimum current value at the predicted moment, as well as a prediction sample data set.

[0048] It can be understood that the predicted string current data includes the string current value data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located within a preset time period before the predicted moment, including the predicted moment. By preprocessing the string current value data, the maximum current value and the minimum current value at the predicted moment, as well as the predicted sample data set, can be obtained.

[0049] In some embodiments, as Figure 2 As shown, the predicted string current data is preprocessed to obtain a predicted sample data set, including but not limited to the following steps:

[0050] S21: Sampling the predicted string current data at every first preset time interval and using median filtering to interpolate missing values, denoted as I m,j , represents the current value of the mth PV string at time j.

[0051] In an embodiment of the present invention, the predicted string current data of all photovoltaic strings in the device where the photovoltaic strings to be predicted are located, which are obtained before the predicted moment and within a preset time length including the predicted moment, are sampled every first preset time interval, wherein the first preset time interval can be 10 minutes, or 15 minutes, or 5 minutes, etc. The first preset time interval can also be other data, and the embodiment of the present invention does not impose specific restrictions on this.

[0052] In the embodiment of the present invention, the missing values ​​can be interpolated using median filtering to obtain prediction filtering data with continuous and non-missing time points.

[0053] It can be understood that the use of the median filtering method to interpolate missing values ​​can be used to supplement the missing values ​​with the median of each point in the neighborhood of the missing value.

[0054] S22: Then, normalize the h strings of the same device at different times to generate predicted normalized data:

[0055] in, is the predicted normalized data of the mth PV string at time j after normalization processing.

[0056] In the embodiment of the present invention, normalization processing is performed on h strings of the same device at different times to generate predicted normalized data.

[0057] S23: Using N predicted normalized data before the prediction moment among the predicted normalized data of the plurality of photovoltaic strings as a prediction sample data set; wherein N is an integer greater than 0.

[0058] In the embodiment of the present invention, N predicted normalized data before the time to be predicted are used as the prediction sample data set, where N is an integer greater than 0.

[0059] Exemplarily, N may be 5, 10, 15, 20, 25 or 30, or may be other data, and this embodiment of the present invention does not impose any specific limitation on this.

[0060] It should be noted that when N is 20, the number of selected prediction normalized data is sufficient to make the prediction results more accurate, and the number of selected prediction normalized data will not generate a large computational pressure on subsequent model operations, the prediction processing time is shorter, and the prediction efficiency is higher.

[0061] Please continue to refer to Figure 1 In the embodiment of the present invention, S3 is executed after S2: the prediction sample data set is input into the trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted time.

[0062] In an embodiment of the present invention, a current prediction model can be pre-set. By training the current prediction model, a trained current prediction model is obtained, so that the trained current prediction model can be used to process the prediction sample data set to obtain the predicted value of the photovoltaic string to be predicted at the predicted time.

[0063] In some embodiments, the current prediction model includes: a convolutional layer, a pooling layer, an LSTM layer, and a fully connected layer. The prediction sample data set is input into the trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted time, including:

[0064] The prediction sample data is input into the convolution layer, pooling layer, LSTM layer and fully connected layer in sequence to predict the predicted value of the photovoltaic string to be predicted at the predicted time.

[0065] In this embodiment of the present invention, the current prediction model includes a convolutional layer, a pooling layer, an LSTM layer, and a fully connected layer. Data from the prediction sample dataset is sequentially input into the trained current prediction model's convolutional layer, pooling layer, LSTM layer, and fully connected layer for processing, resulting in a predicted value for the photovoltaic string at the predicted time.

[0066] S4: Generate a predicted current value of the photovoltaic string to be predicted at the predicted time according to the maximum current value, the minimum current value and the predicted value.

[0067] In an embodiment of the present invention, the predicted string current data is preprocessed to obtain the maximum current value and the minimum current value at the time to be predicted, as well as a prediction sample data set. Then, the predicted sample data set is processed using a trained current prediction model to obtain a predicted value of the photovoltaic string to be predicted at the time to be predicted, so as to generate a predicted current value of the photovoltaic string to be predicted at the time to be predicted based on the maximum current value, the minimum current value and the predicted value.

[0068] It can be understood that the predicted value is a normalized value. If you want to obtain the predicted current value of the photovoltaic string to be predicted at the time to be predicted, you need to reverse the predicted value based on the maximum current value and the minimum current value at the time to be predicted to obtain the value before normalization, that is, the predicted current value of the photovoltaic string to be predicted at the time to be predicted.

[0069] By implementing the embodiment of the present invention, the predicted string current data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located, including the preset time length before the predicted moment, is obtained; the predicted string current data is preprocessed to obtain the maximum current value and the minimum current value at the predicted moment, as well as a prediction sample data set; the prediction sample data set is input into a trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted moment; based on the maximum current value, the minimum current value and the predicted value, the predicted current value of the photovoltaic string to be predicted at the predicted moment is generated. Thus, by predicting the predicted value of the photovoltaic string to be predicted at the predicted moment, the predicted current value of the photovoltaic string to be predicted at the predicted moment can be obtained, and the predicted current value obtained by using the method provided by the embodiment of the present invention is highly accurate.

[0070] In some embodiments, as Figure 3 As shown, the photovoltaic string current prediction method based on the CNN and LSTM method in an embodiment of the present invention further includes:

[0071] S100: Obtain a training sample dataset.

[0072] In some embodiments, as Figure 4 As shown, in the embodiment of the present invention, S100 includes but is not limited to the following sub-steps:

[0073] S101: Acquire training string current data of a plurality of photovoltaic strings within a first time period during normal operation.

[0074] In an embodiment of the present invention, training string current data for a first time period during normal operation of multiple photovoltaic strings is obtained, where the multiple photovoltaic strings may be photovoltaic strings of the same device, exemplarily, photovoltaic strings in a combiner box or inverter.

[0075] In the embodiment of the present invention, the training string current data includes string current values ​​within a first time period during normal operation of a plurality of strings.

[0076] In the embodiment of the present invention, the first time length may be 20 days, or 30 days, or other data, and the embodiment of the present invention does not impose any specific limitation on this.

[0077] like Figure 5 It can be seen that there is a strong correlation between the current data of different PV strings of the same device, such as Figure 6 It can be seen that the relationship between the current data of the same photovoltaic string on different dates is similar. Based on this, in the embodiment of the present disclosure, the training string current data within a first time period during the normal operation of multiple photovoltaic strings is obtained as a training sample data set, so that the data in the training sample data set is sufficient.

[0078] S102: Preprocess the training string current data to obtain a training sample data set.

[0079] In the embodiment of the present invention, the acquired training string current data within a first time period during the normal operation of the plurality of photovoltaic strings are preprocessed to obtain a training sample data set.

[0080] In some embodiments, as Figure 7 As shown, in the embodiment of the present invention, S102 includes but is not limited to the following sub-steps:

[0081] S1021: Sampling the training string current data at every second preset time interval and using median filtering to interpolate missing values, denoted as I M,J , represents the current value of the Mth PV string at time J.

[0082] In the embodiment of the present invention, the training string current data acquired during the first time length of the normal operation of the plurality of photovoltaic strings is sampled at every second preset time interval.

[0083] The second preset time interval may be 10 minutes, or 15 minutes, or other values, and the embodiment of the present invention does not impose any specific limitation on this.

[0084] In the embodiment of the present invention, the second preset time interval may be equal to the first preset time interval.

[0085] In the embodiment of the present invention, the missing values ​​can be interpolated using median filtering to obtain training filter data with continuous and non-missing time points.

[0086] It can be understood that the use of the median filtering method to interpolate missing values ​​can be used to supplement the missing values ​​with the median of each point in the neighborhood of the missing value.

[0087] S1022: Then, normalize the H strings of the same device at different times to generate training normalized data:

[0088] in, It is the normalized training data after normalization processing of the M-th PV string at time J.

[0089] In the embodiment of the present invention, normalization processing is performed on H strings of the same device at different times to generate training normalized data.

[0090] S1023: Generate a training sample data set by using the string current value at the first moment of any photovoltaic string in the training normalized data of the multiple photovoltaic strings as a dependent variable and the string current values ​​at M moments before the first moment of the multiple photovoltaic strings as independent variables; where M is an integer greater than 0.

[0091] In the embodiment of the present invention, the string current value at the first moment of any photovoltaic string is used as the dependent variable, and the string current values ​​of multiple photovoltaic strings at M moments before the first moment are used as independent variables to generate a training sample data set; wherein M is an integer greater than 0 that can be preset.

[0092] Exemplarily, M may be 5, 10, 15, 20, 25 or 30, or may be other data, which is not specifically limited in the embodiment of the present invention.

[0093] Please continue to refer to Figure 3 In the embodiment of the present invention, S200 is executed after S100: inputting the training sample data set into the current prediction model, training the current prediction model, and obtaining a trained current prediction model.

[0094] In the embodiment of the present invention, a current prediction model may be pre-set, and a training sample data set may be input into the current prediction model. The current prediction model may be trained to obtain a trained current prediction model.

[0095] In some embodiments, the training sample data set is sequentially input into the convolution layer, the pooling layer, the LSTM layer and the fully connected layer, the mean square error loss MSE is used as the loss function, and the adaptive matrix estimation Adam optimization algorithm is used to train the current prediction model to obtain a trained current prediction model.

[0096] In this embodiment of the present invention, the current prediction model includes a convolutional layer, a pooling layer, an LSTM layer, and a fully connected layer. Data from the training sample dataset is sequentially input into the convolutional layer, pooling layer, LSTM layer, and fully connected layer of the current prediction model. The mean squared error (MSE) loss function is used to train the current prediction model using the adaptive moment estimation (Adam) optimization algorithm to obtain a trained current prediction model.

[0097] It's understandable that the mean square error (MSE) loss function can be used. MSE is the most commonly used loss function in machine learning and deep learning regression tasks, also known as L2 loss. When the predicted PV string current equals the actual PV string current, the minimum value of the MSE loss function is 0, and the maximum value is infinity.

[0098] In order to implement the above embodiment, the present invention also proposes a photovoltaic string current prediction system based on CNN and LSTM methods.

[0099] Figure 8 Schematic diagram of the structure of a photovoltaic string current prediction system based on CNN and LSTM methods according to an embodiment of the present invention.

[0100] like Figure 8 As shown, the photovoltaic string current prediction system 10 based on the CNN and LSTM method according to an embodiment of the present invention includes: an acquisition unit 11, a processing unit 12, a prediction unit 13, and a generation unit 14, wherein:

[0101] The acquisition unit 11 is configured to acquire predicted string current data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located within a preset time period before and including the predicted moment.

[0102] The processing unit 12 is used to pre-process the predicted string current data to obtain the maximum current value and the minimum current value at the time to be predicted, as well as the prediction sample data set.

[0103] The prediction unit 13 is used to input the prediction sample data set into the trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted time.

[0104] The generating unit 14 is configured to generate a predicted current value of the photovoltaic string to be predicted at a predicted time according to the maximum current value, the minimum current value and the predicted value.

[0105] Regarding the photovoltaic string current prediction system based on the CNN and LSTM method in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method and will not be elaborated here.

[0106] By implementing the embodiment of the present invention, the acquisition unit 11 acquires the predicted string current data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located, including the preset time length before the predicted moment, and the predicted moment; the processing unit 12 preprocesses the predicted string current data to obtain the maximum current value and the minimum current value at the predicted moment, as well as the predicted sample data set; the prediction unit 13 inputs the predicted sample data set into the trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted moment; the generation unit 14 generates the predicted current value of the photovoltaic string to be predicted at the predicted moment based on the maximum current value, the minimum current value and the predicted value. Thus, by predicting the predicted value of the photovoltaic string to be predicted at the predicted moment, the predicted current value of the photovoltaic string to be predicted at the predicted moment can be obtained, and the predicted current value obtained by using the method provided by the embodiment of the present invention is highly accurate.

[0107] In order to implement the above embodiment, Figure 9 As shown, an embodiment of the present invention proposes an electronic device 1200, including: a memory 1201, a processor 1202, and a computer program stored in the memory 1201 and executable on the processor 1202. When the processor 1202 executes the program, the above-mentioned photovoltaic string current prediction method based on the CNN and LSTM method is implemented.

[0108] The beneficial effects that can be achieved by the electronic device of the embodiment of the present invention are the same as the beneficial effects achieved by the photovoltaic string current prediction method based on the CNN and LSTM methods described above, and will not be repeated here.

[0109] To implement the above embodiment, an embodiment of the present invention provides a computer-readable storage medium having a computer program stored thereon. When the program is executed by a processor, the above photovoltaic string current prediction method based on the CNN and LSTM method is implemented.

[0110] The beneficial effects that can be achieved by the computer-readable storage medium of the embodiment of the present invention are the same as the beneficial effects achieved by the photovoltaic string current prediction method based on the CNN and LSTM methods described above, and will not be repeated here.

[0111] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of the technical features being referred to. Thus, a feature identified as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, "plurality" means two or more, unless otherwise specifically defined.

[0112] In the present invention, unless otherwise expressly specified or limited, the terms "mounted," "connected," "connect," "fixed," etc. should be understood broadly. For example, they may refer to fixed connection, detachable connection, or integration; mechanical connection or electrical connection; direct connection or indirect connection through an intermediate medium; internal communication between two components or interaction between two components. Those skilled in the art will understand the specific meanings of the above terms in the present invention based on specific circumstances.

[0113] In the present invention, unless otherwise expressly specified or limited, when a first feature is "above" or "below" a second feature, it may mean that the first and second features are in direct contact, or that the first and second features are in indirect contact through an intermediary. Furthermore, when a first feature is "above," "above," or "above" a second feature, it may mean that the first feature is directly above or diagonally above the second feature, or simply means that the first feature is at a higher level than the second feature. When a first feature is "below," "below," or "below" a second feature, it may mean that the first feature is directly below or diagonally below the second feature, or simply means that the first feature is at a lower level than the second feature.

[0114] In the description of this specification, the reference terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" mean that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art can combine and combine different embodiments or examples described in this specification and features of different embodiments or examples without contradiction.

[0115] Although the embodiments of the present invention have been shown and described above, it will be understood that the above embodiments are illustrative and are not to be construed as limitations on the present invention. A person skilled in the art may change, modify, replace and modify the above embodiments within the scope of the present invention.

Claims

1. A photovoltaic string current prediction method based on CNN and LSTM method, characterized in that: include: Acquire predicted string current data of all photovoltaic strings in the device where the photovoltaic string to be predicted is located within a preset time period before and including the predicted moment; Preprocess the predicted string current data to obtain the maximum current value and the minimum current value at the time to be predicted, as well as the prediction sample data set; Inputting the prediction sample data set into the trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted time; Generate a predicted current value of the photovoltaic string to be predicted at the predicted time according to the maximum current value, the minimum current value and the predicted value; The preprocessing of the predicted string current data to obtain a predicted sample data set includes: The predicted string current data is sampled at a first preset time interval, and the missing values ​​are interpolated using a median filter, which is recorded as I m,j , represents the current value of the mth PV string at time j; Then, the h strings of the same device are normalized at different times to generate predicted normalized data: in, is the predicted normalized data of the mth PV string at time j after normalization processing; Among the predicted normalized data of the plurality of photovoltaic strings, N predicted normalized data before the time to be predicted are used as the predicted sample data set; wherein N is an integer greater than 0; The current prediction model includes: a convolution layer, a pooling layer, an LSTM layer and a fully connected layer. The prediction sample data set is input into the trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted time, including: The predicted sample data is sequentially input into the convolution layer, the pooling layer, the LSTM layer and the fully connected layer to predict the predicted value of the photovoltaic string to be predicted at the predicted time.

2. The method according to claim 1, characterized in that The method further comprises: Obtain training sample data set; The training sample data set is input into the current prediction model, and the current prediction model is trained to obtain a trained current prediction model.

3. The method according to claim 2, characterized in that The step of obtaining a training sample data set includes: Acquire training string current data within a first time length during normal operation of multiple photovoltaic strings; The training string current data is preprocessed to obtain a training sample data set.

4. The method according to claim 3, characterized in that The preprocessing of the training string current data to obtain a training sample data set includes: The training string current data is sampled every second preset time interval, and the missing values ​​are interpolated using median filtering, denoted as I M,J , represents the current value of the Mth PV string at time J; Then, the H strings of the same device are normalized at different times to generate training normalized data: in, is the training normalized data of the Mth photovoltaic string after normalization at time J; The training sample data set is generated by taking the string current value of any photovoltaic string at the first moment in the training normalized data of the multiple photovoltaic strings as the dependent variable, and taking the string current values ​​of the multiple photovoltaic strings at M moments before the first moment as the independent variable; wherein M is an integer greater than 0.

5. The method according to claim 4, characterized in that The step of inputting the training sample data set into the current prediction model and training the current prediction model to obtain a trained current prediction model comprises: The training sample data set is input into the convolution layer, the pooling layer, the LSTM layer and the fully connected layer in sequence, the mean square error loss MSE is used as the loss function, and the adaptive matrix estimation Adam optimization algorithm is used to train the current prediction model to obtain a trained current prediction model.

6. A photovoltaic string current prediction system based on CNN and LSTM method, characterized in that: include: An acquisition unit, used for acquiring predicted string current data of all photovoltaic strings in the device where the photovoltaic strings to be predicted are located within a preset time period before and including the predicted moment; A processing unit, used to pre-process the predicted string current data, obtain the maximum current value and the minimum current value at the time to be predicted, and a prediction sample data set; A prediction unit, used for inputting the prediction sample data set into a trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted time; A generating unit, configured to generate a predicted current value of the photovoltaic string to be predicted at a predicted time according to the maximum current value, the minimum current value and the predicted value; The preprocessing of the predicted string current data to obtain a predicted sample data set includes: The predicted string current data is sampled at a first preset time interval, and the missing values ​​are interpolated using a median filter, which is recorded as I m,j , represents the current value of the mth PV string at time j; Then, the h strings of the same device are normalized at different times to generate predicted normalized data: in, is the predicted normalized data of the mth PV string at time j after normalization processing; Among the predicted normalized data of the plurality of photovoltaic strings, N predicted normalized data before the time to be predicted are used as the predicted sample data set; wherein N is an integer greater than 0; The current prediction model includes: a convolution layer, a pooling layer, an LSTM layer and a fully connected layer. The prediction sample data set is input into the trained current prediction model to predict the predicted value of the photovoltaic string to be predicted at the predicted time, including: The predicted sample data is sequentially input into the convolution layer, the pooling layer, the LSTM layer and the fully connected layer to predict the predicted value of the photovoltaic string to be predicted at the predicted time.

7. An electronic device, characterized in that: include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the method according to any one of claims 1 to 5 is implemented.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 5 is implemented.