Irradiance prediction method and system based on multi-view foundation cloud picture
Through the cloud bottom height calculation and stacking of machine learning models of multi-view foundation cloud maps, the accuracy of irradiance prediction in cloudy weather is solved, and high prediction accuracy and robustness are achieved.
Patent Information
- Application Number
- CN202411473658.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-22
- Publication Date
- 2025-02-07
AI Technical Summary
The prior art is difficult to accurately predict irradiance under cloudy weather conditions, especially the occlusion effect of cloud layer and the influence of cloud bottom height are not fully utilized.
By obtaining multi-view foundation cloud maps, extracting cloud map parameters and calculating the cloud base height, combining XGB and LGB models for model stacking, an irradiance prediction model is constructed.
The accuracy and robustness of irradiance prediction are improved, especially in complex weather conditions, the height characteristics of the cloud bottom can significantly improve the prediction accuracy.
Smart Images

Figure CN119399527A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of radiation prediction technology, and in particular to an irradiance prediction method and system based on multi-view ground-based cloud images. Background Art
[0002] Among all weather types, the irradiance prediction accuracy for sunny days is the highest. This is because the sun shines directly on sunny days without any clouds or other objects blocking it, and the change in irradiance is related to factors such as the position of the sun, weather conditions, and atmospheric transparency. In this case, the irradiance is more obvious and predictable. In cloudy weather, however, the obstruction of clouds will increase the difficulty of irradiance prediction. If the wind speed is high, it may even cause the movement of clouds within minutes, resulting in drastic fluctuations in irradiance, which will have a huge impact on the stability of the power grid and is more likely to destroy the entire power grid system. Therefore, in order to solve the problem of irradiance prediction accuracy, the main focus is on the study of various mechanism characteristics of clouds. By describing the potential impact of clouds on irradiation prediction, the purpose of improving irradiation prediction accuracy can be achieved.
[0003] At present, the research on irradiation prediction by domestic and foreign scholars is mainly based on ground-based cloud images collected by all-sky imagers, which can realize all-weather monitoring, have high temporal and spatial resolution, and have the functions of automation and remote monitoring. However, due to the high cost, its popularity is limited. At present, no scholar has combined cloud base height with irradiation prediction to analyze the impact of cloud height characteristics on irradiation prediction. Similarly, related research on cloud classification is still shallow. In terms of irradiation prediction, machine learning has become the mainstream research direction. Scholars have trained, adjusted, and improved different models to achieve the highest prediction accuracy, but the calculation of cloud base height is still not sufficient. Summary of the invention
[0004] The purpose of the present invention is to overcome the deficiencies in the prior art and to provide an irradiance prediction method and system based on multi-perspective ground-based cloud images, which realizes irradiance prediction in complex weather conditions by extracting cloud base height and achieves a certain accuracy.
[0005] To achieve the above object, the present invention is implemented by adopting the following technical solutions: On the one hand, the present invention provides an irradiance prediction method based on multi-view ground-based cloud images, comprising: Obtain multi-view ground cloud images; Extracting cloud image parameters of the multi-view ground-based cloud image, identifying and matching feature points of the multi-view ground-based cloud image, and calculating cloud base height using the feature points and basic matrix of the matched multi-view ground-based cloud image; Inputting the cloud image parameters and cloud bottom height into a pre-built irradiance prediction model, and outputting the irradiance prediction result; Wherein, the construction of the irradiance prediction model includes: The multiple XGB models are used as base learners and the LGB model is used as a meta-learner, and a model stacking method is adopted to construct an irradiance prediction model.
[0006] Optionally, before extracting the cloud map parameters of the multi-view ground-based cloud map, the multi-view ground-based cloud map is further subjected to distortion correction using a checkerboard calibration method, specifically: A fisheye camera is used to take multiple photos containing a chessboard at different angles and positions, and a calibration algorithm is used to detect corner points and extract sub-pixels of the chessboard. According to the extracted coordinates of the chessboard points, the parameters of the fisheye camera and the distortion parameters are calculated, and the parameters of the fisheye camera are changed into the distortion parameters.
[0007] Optionally, the identifying and matching feature points of the multi-view ground-based cloud image includes: The SIFT algorithm is used to identify the feature points of the multi-view ground-based cloud image, a descriptor of the feature point is generated, an index data structure of the descriptor is established using the FLANN library, and the feature points of the multi-view ground-based cloud image are matched.
[0008] Optionally, the basic matrix is expressed as: ; In the formula, is the three-dimensional coordinate of the spatial point P under the left-view foundation cloud map; is the basic matrix; is the three-dimensional coordinate of the spatial point P under the right-view foundation cloud map; for The x-axis coordinate of for The y-axis coordinate of for The x-axis coordinate of for The y-axis coordinate of .
[0009] Optionally, the step of calculating the cloud base height includes: A left-view fisheye camera A and a right-view fisheye camera B at the same height are used to respectively shoot a left-view ground cloud image I1 and a right-view ground cloud image I2, and a left feature point M on the left-view ground cloud image I1, a right feature point N on the right-view ground cloud image I2, and an intersection point P between a line connecting the left-view fisheye camera A and the left feature point M and a line connecting the right-view fisheye camera B and the right feature point N are respectively selected using a basic matrix; The intersection point between the line connecting the left-view fisheye camera A and the right-view fisheye camera B and the left-view ground cloud image I1 is taken as the left pole E, and the intersection point between the line connecting the left-view fisheye camera A and the right-view fisheye camera B and the right-view ground cloud image I2 is taken as the right pole F; the line connecting the left feature point M on the left-view ground cloud image I1 and the left pole E is taken as the left pole line L1, and the line connecting the right feature point N on the right-view ground cloud image I2 and the right pole F is taken as the right pole line L2; The motion relationship from the left-view ground foundation cloud image I1 to the right-view ground foundation cloud image I2 is obtained by using the left polar line L1 and the right polar line L2, and the three-dimensional coordinates of the intersection point P are calculated according to the motion relationship; The difference between the z-axis coordinate of the three-dimensional coordinates of the intersection point P and the height of the fisheye camera is used as the cloud bottom height.
[0010] Optionally, training the irradiance prediction model using mean absolute error, root mean square error and coefficient of determination includes: ; ; ; In the formula, is the mean absolute error; is the root mean square error; is the coefficient of determination; is the number of irradiance feature points; is the predicted value of irradiance; is the true value of irradiance; is the average value of the predicted irradiance.
[0011] In a second aspect, the present invention provides an irradiance prediction system based on a multi-view ground-based cloud map, comprising: A ground-based cloud image acquisition module is used to acquire multi-view ground-based cloud images; A cloud image parameter extraction module, used to extract cloud image parameters of the multi-view ground-based cloud image; A cloud base height calculation module is used to identify and match the feature points of the multi-view ground-based cloud image, and calculate the cloud base height using the feature points of the matched multi-view ground-based cloud image and the basic matrix; Inputting the cloud image parameters and cloud bottom height into a pre-built irradiance prediction model, and outputting the irradiance prediction result; Wherein, the construction of the irradiance prediction model includes: The multiple XGB models are used as base learners and the LGB model is used as a meta-learner, and a model stacking method is adopted to construct an irradiance prediction model.
[0012] In a third aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the steps of the irradiance prediction method based on multi-view ground-based cloud images described in the first aspect are implemented.
[0013] In a fourth aspect, the present invention provides a computer device, comprising: Memory, for storing computer instructions; A processor is used to execute the computer instructions to implement the steps of the irradiance prediction method based on multi-view ground-based cloud images described in the first aspect.
[0014] Beneficial Effects Compared with the prior art, the present invention has the following beneficial effects: The present invention plays a decisive role in irradiance prediction by calculating the cloud base height. After the cloud base height parameter is input, the irradiance prediction model has good irradiance prediction ability and robustness, and shows the best model performance under all conditions. For different types of clouds, the cloud base height characteristics can bring a certain amount of increase in the irradiance prediction accuracy. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Figure 1 FIG. 1 is a flow chart of an irradiance prediction method based on multi-view ground-based cloud images in an embodiment of the present invention; Figure 2 Shown is a schematic diagram of ground-based cloud image classification in one embodiment of the present invention; Figure 3 FIG. 1 is a schematic diagram of ground-based cloud image distortion correction in one embodiment of the present invention; Figure 4 The figure shows a schematic diagram of ground cloud map feature point matching in one embodiment of the present invention; Figure 5 FIG. 1 is a schematic diagram showing the principle of calculating cloud base height in one embodiment of the present invention; Figure 6 Shown is a schematic diagram of cloud base height data in one embodiment of the present invention; Figure 7 Shown is a schematic diagram of the stacking model principle in one embodiment of the present invention; Figure 8 Shown is a schematic diagram of an outdoor experimental platform in one embodiment of the present invention; Fig. 9 Shown is a schematic diagram of cloud base height correlation analysis results in one embodiment of the present invention; Fig.10 It is a schematic diagram showing the comparison of optimization rates of different models with cloud base height input in one embodiment of the present invention; Fig.11It is a schematic diagram of scattered point density of different models with cloud base height input in one embodiment of the present invention; Fig.12 It is a schematic diagram showing the comparison of results of different models with or without cloud base height input in one embodiment of the present invention; Fig.13 It is a schematic diagram of different model scatter point densities without cloud bottom height input in one embodiment of the present invention; Fig.14 Shown is a schematic diagram of flocculent cloud in one embodiment of the present invention; Fig.15 It is a schematic diagram showing the comparison of optimization rates of different models under flocculent clouds compared with the height without cloud bottom in one embodiment of the present invention; Fig.16 Shown is a schematic diagram of a fragmented cloud in one embodiment of the present invention; Fig.17 It is a schematic diagram showing the comparison of optimization rates of different models under broken clouds compared with the height without cloud base in one embodiment of the present invention; Fig.18 Shown is a schematic diagram of a block cloud in one embodiment of the present invention; Fig.19 It is a schematic diagram showing the comparison of the optimization rates of different models under block clouds compared with the height without cloud base in one embodiment of the present invention. DETAILED DESCRIPTION
[0016] The technical solution of the present invention is described in detail below through the accompanying drawings and specific embodiments. It should be understood that the embodiments of the present invention and the specific features in the embodiments are detailed descriptions of the technical solution of the present invention, rather than limitations on the technical solution of the present invention. The embodiments of the present invention and the technical features in the embodiments may be combined with each other unless there is a conflict.
[0017] The term "and / or" is only a description of the association relationship between related objects, indicating that there can be three relationships. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " generally indicates that the related objects are in an "or" relationship.
[0018] Example 1 like Figure 1 As shown, this embodiment introduces an irradiance prediction method based on a multi-view ground cloud map, which specifically includes the following steps: Get multi-view ground cloud images.
[0019] In this embodiment, the sky cloud camera is used to obtain the data. Raspberry Pi can basically replace the full sky imager due to its advantages of low cost, portability, and rich functions. This embodiment realizes the shooting, storage, and transmission functions of ground-based cloud images based on the Raspberry Pi 4b single-board computer. Compared with the full sky imager, due to the portability of the Raspberry Pi, it is not restricted by the venue. In addition, the fisheye camera module, GPS module, clock module, temperature control module, timing module, and power module are also configured inside. The functions of the modules can be realized by remotely connecting the Raspberry Pi, thereby improving the cloud image acquisition quality of the sky cloud camera.
[0020] After the ground-based cloud images are taken, all the cloud images are screened and classified. Figure 2 The middle, left, right, top and bottom represent bird obstruction, signal interruption, cloud presence and cloudlessness respectively.
[0021] The fisheye camera has a very wide field of view, which can usually reach 180° or more. This feature can help us obtain more information in the sky. The fisheye camera used in this embodiment has a diagonal field of view of 200°, a focal length of 0.87mm, a camera pixel of 5 million, a picture size of 2592×1944 pixels, an acquisition frequency of 3 pictures / min, an interval of 3 seconds between each picture, and a shutter speed of 50, 75, and 100 microseconds for each cloud picture. This acquisition frequency can accurately and timely reflect the changes in the clouds in the sky.
[0022] While the fisheye camera obtains a wide range of viewing angle information, it also causes serious deformation. Therefore, it is necessary to perform distortion correction on the ground-based cloud image taken by the fisheye camera. The chessboard calibration method is used to correct the distortion of the ground-based cloud image. Specifically: First, use a fisheye camera to take multiple photos containing chessboards at different angles and positions; then use the calibration algorithm to detect corner points and extract sub-pixels of the chessboard; then, calculate the camera's internal and external parameters and distortion parameters based on the coordinates of the extracted chessboard points; finally, change the corresponding camera parameters in the code to the distortion parameters obtained above to complete the distortion correction of the ground-based cloud map. Figure 3 It can be seen that this method has a good correction effect on the ground-based cloud image.
[0023] Extracting the cloud map parameters of the multi-view ground-based cloud map. The cloud map parameter extraction method is relatively mature, and will not be described in detail here. For details, please refer to the prior art.
[0024] The characteristic points of the multi-view ground-based cloud image are identified and matched, and the cloud base height is calculated using the characteristic points of the matched multi-view ground-based cloud image and the basic matrix.
[0025] In order to calculate the cloud base height, it is necessary to match the sky cloud information from the left and right perspectives at the same time, and use the matched feature point information for subsequent cloud base height calculation. This embodiment uses the combination of SIFT algorithm and FLANN library to identify, screen, and match cloud feature points in cloudy weather from multiple perspectives.
[0026] The SIFT algorithm is used to identify the feature points of the multi-view ground cloud map and generate the descriptors of the feature points. In the SIFT algorithm, a scale space is first constructed, and the input image is blurred using a Gaussian filter to generate a Gaussian pyramid, where each layer of the pyramid is composed of images of different scales, and each scale image is obtained by downsampling the image of the previous layer. The Gaussian blur operation formula involved is: ; In the formula, Represents the coordinates of the discrete space, that is, the position of the Gaussian kernel; Indicated in The weight value at the coordinate; It represents the standard deviation of the Gaussian kernel. This parameter determines the shape and blur of the Gaussian function. The larger it is, the wider the Gaussian kernel is and the greater the blur; It represents the center position of the discrete space, which is usually taken as the center point of the Gaussian kernel. It can be understood as the offset of the Gaussian kernel in the discrete space.
[0027] After completing the construction of the scale space, the Gaussian difference pyramid is the prerequisite for feature point detection. By subtracting adjacent layers in each group in the Gaussian pyramid, the Gaussian difference pyramid can be obtained. The formula is: ; ; ; In the formula, Represents the scale factor in the Gaussian difference function, which represents the scale ratio between two adjacent Gaussian functions.
[0028] After generating the feature descriptor, use the FLANN library to create an index data structure for the descriptor. This index can improve the efficiency of searching for the nearest neighbor. Call the Knnmatch function in the FLANN library to perform the nearest neighbor search.
[0029] In order to further improve the quality of matching points and reduce the possibility of mismatching, the ratio of the optimal matching distance to the suboptimal matching distance of each descriptor is calculated, and the quality of the matching points is determined by setting a threshold, thereby completing the feature point detection and matching of the left and right images of the multi-view ground cloud map. The actual multi-view ground cloud map matching results are shown in Figure 2. Figure 4 shown.
[0030] The fundamental matrix (F) is a concept in computer vision. It describes the extreme geometric relationship between two images, that is, the correspondence between the same scene in different angles. It is the necessary theoretical basis for us to realize cloud height calculation through multi-view ground-based cloud images. The fundamental matrix is expressed as: ; In the formula, is the three-dimensional coordinate of the spatial point P under the left-view foundation cloud map; is the basic matrix; is the three-dimensional coordinate of the spatial point P under the right-view foundation cloud map; for The x-axis coordinate of for The y-axis coordinate of for The x-axis coordinate of for The y-axis coordinate of .
[0031] When calculating the basic matrix, it is necessary to screen the matching points. Commonly used optimization methods include the eight-point method, the normalized eight-point method and the Ransac algorithm. The eight-point method quickly estimates the basic matrix from a small number of corresponding points, and the effect is better when the match is good and the noise is less. The normalized eight-point method improves the stability and accuracy of the algorithm through preprocessing. The Ransac algorithm calculates candidate solutions for the basic matrix through multiple random samplings and selects the best solution. The algorithm can effectively eliminate the influence of outliers, is more effective when there is a lot of noise or homography matrix estimation, and is more robust. Therefore, this embodiment selects the Ransac algorithm as the optimization algorithm for solving the basic matrix.
[0032] like Figure 5 The figure shows the principle of calculating the cloud base height. According to the principle of epipolar geometry, for any feature point in an image, its corresponding point in another image must be located on the corresponding epipolar line. Specifically: A left-view fisheye camera A and a right-view fisheye camera B at the same height are used to respectively shoot a left-view ground cloud image I1 and a right-view ground cloud image I2, and a left feature point M on the left-view ground cloud image I1, a right feature point N on the right-view ground cloud image I2, and an intersection point P between a line connecting the left-view fisheye camera A and the left feature point M and a line connecting the right-view fisheye camera B and the right feature point N are respectively selected using a basic matrix; The intersection point between the line connecting the left-view fisheye camera A and the right-view fisheye camera B and the left-view ground cloud image I1 is taken as the left pole E, and the intersection point between the line connecting the left-view fisheye camera A and the right-view fisheye camera B and the right-view ground cloud image I2 is taken as the right pole F; the line connecting the left feature point M on the left-view ground cloud image I1 and the left pole E is taken as the left pole line L1, and the line connecting the right feature point N on the right-view ground cloud image I2 and the right pole F is taken as the right pole line L2; The motion relationship from the left-view ground foundation cloud image I1 to the right-view ground foundation cloud image I2 is obtained by using the left polar line L1 and the right polar line L2, and the three-dimensional coordinates of the intersection point P are calculated according to the motion relationship; The difference between the z-axis coordinate of the three-dimensional coordinates of the intersection point P and the height of the fisheye camera is used as the cloud bottom height.
[0033] In daily life, the clouds that we can see with our eyes belong to the low cloud family, which are mainly classified into cumulus, cumulonimbus, stratus, stratocumulus and nimbostratus. The cloud base height is basically below 2000 meters. The specific range is shown in Table 1. In normal weather conditions, the movement of clouds is relatively slow, and the change of cloud height is in hours. Therefore, after calculating the initial cloud base height, the sliding average method is used to process the data to ensure that the change range of the cloud base height is in line with the actual situation. The smoothed data distribution is as follows Figure 6 As shown in the figure, the CBH data distribution of 4 days is shown, namely 2023-9-4, 2023-9-5, 2023-9-6, and 2023-9-7. All CBH mean values are less than 1500 meters, which is consistent with the range of cloud base height that we can see with the naked eye. A few outliers may be caused by calculation errors due to mismatching of feature points, but they do not affect the overall data distribution, and most of the outliers are within the range of cloud base height of normal low cloud families, which is normal, proving that the calculation method used in this article has a certain reliability.
[0034] Table 1 Low cloud group types and heights
[0035] The cloud image parameters and cloud bottom height are input into a pre-built irradiance prediction model, and the irradiance prediction result is output.
[0036] Among machine learning models, decision tree models are popular due to their high accuracy, good robustness, strong ability to handle nonlinear features, and ability to effectively prevent overfitting.
[0037] Model stacking is a machine learning method. The core of this method is to combine the advantages of various models and fuse them together using certain strategies. It aims to obtain a more powerful integrated learning model by combining multiple basic models. It has the advantages of strong interpretability, adaptability to various types of data, and good model prediction effect.
[0038] This paper uses this method to construct a LGB-XGB model as an irradiance prediction model. Figure 7 As shown, in this structure, two layers of algorithms are set in series, the first layer is denoted as Layer1, and the second layer is denoted as Layer2. In the first layer, we place the basic model, which must have a strong learning ability for data and high complexity, because the role of the first layer is to find the hidden relationship between the input features and the target features and establish hypotheses between them, so it must have a strong learning ability; the model of the second layer can be a model with strong explanatory ability and fast computing speed, and its main role is to integrate the assumptions made by the first layer learner and output the final prediction results.
[0039] Based on the above conditions, this paper selects the XGB model as the base learner of the first layer. After the XGB model is trained and outputs the prediction results of the first layer, the results are added to the original feature matrix as new feature columns, and then the LGB model is used as the base learner of the second layer to train the final prediction results.
[0040] Training the irradiance prediction model using mean absolute error, root mean square error and coefficient of determination includes: ; ; ; In the formula, is the mean absolute error; is the root mean square error; is the coefficient of determination; is the number of irradiance feature points; is the predicted value of irradiance; is the true value of irradiance; is the average value of the predicted irradiance.
[0041] Example 2 This embodiment introduces an irradiance prediction system based on multi-view ground-based cloud images, including: A ground-based cloud image acquisition module is used to acquire multi-view ground-based cloud images; A cloud image parameter extraction module, used to extract cloud image parameters of the multi-view ground-based cloud image; A cloud base height calculation module is used to identify and match the feature points of the multi-view ground-based cloud image, and calculate the cloud base height using the feature points of the matched multi-view ground-based cloud image and the basic matrix; Inputting the cloud image parameters and cloud bottom height into a pre-built irradiance prediction model, and outputting the irradiance prediction result; Wherein, the construction of the irradiance prediction model includes: The multiple XGB models are used as base learners and the LGB model is used as a meta-learner, and a model stacking method is adopted to construct an irradiance prediction model.
[0042] Example 3 This embodiment introduces a specific experimental design of an irradiance prediction method based on a multi-view ground cloud map, including: The total amount of data set for this experiment is 9814, the number of training set samples is 7502, and the number of test set samples is 2312. All data are taken by a self-made sky cloud camera. The shooting location is located on the roof of Building 55 of the Changzhou New Campus of Hohai University. The cloud map observation time is 9:00-16:00. The solar irradiance data is collected by TBQ-2H irradiance meter and Kipp&Zonen's SMP22 irradiance meter. The irradiance meter collects data once per second. Later, the irradiance data of the corresponding time of the ground-based cloud map is selected for matching. The actual picture of the self-made sky cloud camera and the irradiance collection instrument are as follows: Figure 8 shown.
[0043] In irradiance prediction, the final prediction result depends largely on the correlation of feature inputs. Before building the model, analyzing the correlation of features and selecting features with high correlation coefficients as model inputs can improve the accuracy of the model to a certain extent.
[0044] In order to verify that the cloud base height feature proposed in this embodiment will improve the irradiance prediction accuracy in cloudy weather after being added to the irradiance prediction, the input feature and the target feature are firstly correlated. This paper uses the Pearson correlation coefficient method to evaluate the correlation between the parameters. The final correlation result is as follows: Fig. 9 As shown, among all the input features, Kt has the highest correlation coefficient with the target parameter Kt_after5, which is 0.64; followed by devi_b and devi_g, with correlation coefficients of 0.33 and 0.25 respectively; and the next is the cloud base height parameter CBH, which has a correlation coefficient of 0.17 with the target feature, which preliminarily shows that the cloud base height parameter proposed in this embodiment has a certain improvement effect on the irradiance prediction accuracy.
[0045] Direct radiation prediction is to directly divide all data sets into training sets and test sets without screening data sets based on their cloud characteristics or other characteristics.
[0046] First, the advantages and disadvantages of different models with cloud height feature input are analyzed. To verify the advantages of the algorithm in this embodiment, the prediction accuracy of the BP neural network model, XGB model, LGB model, and XGB-LGB model with cloud height feature input is compared; next, the influence of cloud bottom height feature input on irradiance prediction in the case of direct irradiance prediction is analyzed, which is achieved by comparing the prediction results of different models with and without cloud bottom height feature input.
[0047] From the evaluation indicators of different models in Table 2 without cloud bottom height feature input, it can be seen that the prediction effect of the fusion model of the XGB-LGB model proposed in this embodiment is better than that of the other three models.
[0048] Table 2 Evaluation indicators of different models without cloud bottom height feature input
[0049] Specific: Among them, the BP model The lowest is only 0.8693, but considering that all data sets belong to cloudy weather, the BP model is difficult to predict, and the degree of fit of this model is already at a relatively good level.
[0050] For the XGB model and LGB model, They are 0.9001 and 0.8728 respectively. The RMSE is improved by 12.59% and 1.34% respectively compared with the BP model, which proves the advantages of the two basic models. The XGB model has achieved greater improvement due to its strong learning ability, while the advantage of the LGB model lies mainly in its powerful computing power and faster training speed.
[0051] Combining the advantages of the two basic models, XGB model and LGB model, the XGB-LGB model is integrated. It reached 0.9130, which is the best fit among all models, and the RMSE increased by 18.42% compared with the BP model, and by 6.67% and 17.32% compared with the XGB model and the LGB model, further illustrating the advantages of the XGB-LGB model over the other three models. The above experimental data illustrate the advantages of the cloud base height characteristics and models used in this embodiment, indicating that the experimental method can solve the irradiance prediction lag problem caused by cloud cover in cloudy weather to a certain extent.
[0052] The optimization rates of different models with cloud base height input are as follows: Fig.10As shown, it can be seen that the XGB-LGB model used in this embodiment has the highest optimization rate of 18.42% compared with the BP model, followed by the XGB model with an optimization rate of 12.59%. The optimization rate of the LGB model is relatively low, mainly because the LGB model mainly plays the role of optimizing the calculation speed in this article, and does not improve the accuracy much.
[0053] The scatter density diagrams of different models with cloud base height input are shown in Figure 2. Fig.11 As shown in the figure, the horizontal axis represents the predicted value, and the vertical axis represents the actual value, both in units of As can be seen from the figure, the data point distribution of the BP model is more discrete than that of the other three models, and the prediction effect of the model is slightly worse, but there are no data points with a particularly large degree of dispersion. Therefore, it can be considered that the BP model also has a certain degree of prediction accuracy; compared with the BP model, the data distribution of the XGB model and the LGB model is tighter, and the data point distribution of the XGB-LGB model is the same.
[0054] In summary, the distribution of data points in these four models is ideal for both low and high irradiance. However, after careful comparison, it can be found that the data points are more densely distributed under high irradiance than under low irradiance, which is the case in all four models. The reason for this phenomenon may be that there are few clouds under high irradiance, which do not block the sun, resulting in a small range of irradiance variation and relative stability, which will not have a big impact on the model's prediction. However, under low irradiance, there are many clouds with dense distribution, which block the sun. This phenomenon will bring some lag to the model's prediction, which may be an important reason for the discrete distribution of data points under low irradiance.
[0055] The evaluation indicators of different models without cloud bottom height feature input are shown in Table 3: Table 3 Evaluation indicators of different models without cloud bottom height feature input
[0056] Combined with the above experimental results, the results of different models with and without cloud base height input are compared. Fig.12 As shown in the figure, the final scatter density map without cloud base height input is as follows Fig.13 As shown in Table 3, when there is no cloud base height input, the BP model performs the worst. Only 0.8496, the performance of XGB model and LGB model is comparable. They are all around 0.85, which shows a certain degree of accurate prediction ability. The stacking model of XGB-LGB model performs best. It can reach 0.8969, which is better than the BP model and LGB model with cloud base height feature input. This once again proves that the XGB-LGB model used in this embodiment outperforms other models and is a relatively excellent regression prediction model. It also shows that the cloud base height feature parameter can alleviate the irradiation prediction lag caused by cloud cover to a certain extent in the face of cloudy and complex weather conditions.
[0057] In comparison with Table 2, it is found that when the cloud base height is input, the RMSE of the BP model is improved by 6.79%, the RMSE of the XGB model is improved by 16.03%, the RMSE of the LGB model is improved by 4.87%, and the XGB-LGB model is improved by 8.15% when the cloud base height is used as a feature input. The values were all improved after the cloud base height features were input, and the degree of model fitting became better.
[0058] from Fig.13 It can be seen that when there is no cloud base height as an input feature, the BP model performs the worst, and the distribution of data points is more dispersed than when there is cloud base height input. The prediction error for low irradiance is large, and the distribution of data points is not ideal. The main reason is that the clouds are densely distributed and change rapidly under low irradiance, which has a strong shielding effect on the sun. In the absence of cloud base height features, the prediction of both low and high irradiance is affected. The XGB model and LGB model also have the same performance. In addition, for the XGB-LGB model, the advantages of the model itself make its prediction deviation for high irradiance within an ideal range.
[0059] In summary, after adding the characteristic parameters of cloud bottom height, a relatively accurate prediction result is obtained for high irradiance in cloudy weather, and the data points under low irradiance are more convergent, which to a certain extent illustrates the uniqueness of the method of this embodiment. The problem of predicting sudden changes in irradiance caused by cloud motion is a key research direction for improving the accuracy of irradiation prediction in the future. The main research object is the cloud layer. Based on a more detailed study of the cloud layer, including texture features, spectral features, cloud movement speed, cloud coverage, cloud bottom height, etc., it can alleviate the irradiance lag caused by the drastic changes in irradiance and unstable motion laws caused by the sun being blocked by clouds in cloudy weather to a certain extent. By combining the XGB-LGB model, the performance of the model itself is improved, the model learning ability and training speed are improved, and accurate irradiation prediction in cloudy weather is achieved.
[0060] In addition to direct irradiance prediction, the dataset can also be classified by weather type, season, and cloud type to demonstrate the impact of cloud base height on irradiance prediction under different conditions.
[0061] This embodiment divides all ground-based cloud images into three common cloud types, namely flocculent clouds, broken clouds, and blocky clouds. The model prediction results with and without cloud base height feature input for each cloud type are analyzed and compared to further demonstrate the influence of cloud base height on irradiance prediction in cloudy weather.
[0062] like Fig.14 As shown in Table 4, 5, under the flocculent cloud weather conditions, the overall cloud amount is small, the cloud layer is wispy, the sky condition is stable, and it will not cause drastic changes in solar irradiance. This weather condition will last for a long time. As can be seen from Tables 4 and 5, in the flocculent cloud occlusion environment where the irradiance fluctuation is less affected, each prediction model shows good prediction performance. When there is a cloud base height feature, the lowest determination coefficient of the model is 0.8543. Even when there is no cloud base height feature input, the lowest determination coefficient is 0.8056. The performance of the irradiance prediction model combined with the cloud base height parameter is greatly improved compared with the irradiance prediction model without the cloud base height parameter. The RMSE of the BP model is improved by 13.41%, the RMSE of the XGB model is improved by 8.78%, the RMSE of the LGB model is improved by 19.67%, and the RMSE of the XGB-LGB model is improved by 14.24%.
[0063] Table 4 Evaluation indexes of cloud base height for different models under flocculent clouds
[0064] Table 5 Evaluation indexes of cloud-free bottom height of different models under flocculent clouds
[0065] For flocculent clouds, the performance of all models has been significantly improved after the introduction of cloud base height features. Fig.15 It can be seen that the sky condition is relatively stable when there are flocculent clouds, and the flocculent clouds account for a small proportion of the sky, so the solar irradiance will not fluctuate dramatically, which lays the foundation for the accuracy of the model.
[0066] like Fig.16As shown in the figure, the fragmentary clouds in the sky are distributed in a step-like manner. Under the cover of such clouds, the solar irradiance shows obvious fluctuations. Fragmentary clouds usually appear briefly in stages and last for a short time. As can be seen from Tables 6 and 7, compared with the flocculent cloud environment, under the cover of fragile clouds, the performance of each prediction model is relatively poor because the clouds often briefly block the sun. This is mainly due to the short duration of fragile clouds. In the case of cloud base height feature input, the determination coefficient of all models is higher than 0.7454, and in the case of no cloud base height feature input, the determination coefficient is as low as 0.7267. In all models, regardless of whether there is cloud base height input or not, the determination coefficient of the XGB-LGB model reaches 0.8005, which further proves the advantages of the model built in this paper. Compared with the models without cloud base height features, the RMSE of the BP model increased by 5.21%, the RMSE of the XGB model increased by 4.05%, the RMSE of the LGB model increased by 2.25%, and the RMSE of the XGB-LGB model increased by 3.02%. Although the improvement effect is not as large as that of flocculent clouds, it still proves the importance of cloud base height features.
[0067] Table 6 Evaluation indexes of cloud base height for different models under broken clouds
[0068] Table 7 Evaluation indexes of cloud-free base height of different models under broken clouds
[0069] When the sky is covered with fragmented clouds, the improvement of each model after introducing the cloud bottom height feature is very small. Fig.17 It can be seen that this is mainly due to the fact that the fragmented clouds appear for a short time and have a large distribution range. The accuracy of each model before the introduction of cloud base height is unsatisfactory. Even after the introduction of cloud base height features, the performance cannot be greatly improved due to the nature of fragmented clouds themselves.
[0070] like Fig.18As shown in Tables 8 and 9, the performance of each prediction model is not ideal under such cloud cover. This is because the cloud information in the sky is prone to rapid changes, which greatly reduces the overall prediction accuracy. The determination coefficient of the LGB model for direct irradiance prediction is only 0.6275, and the optimal XGB-LGB model only reaches 0.6887, which still has a large room for optimization. After combining the cloud base height characteristics, the determination coefficients of all models have been improved. Among them, the RMSE of the BP model increased by 9.87%, the RMSE of the XGB model increased by 8.15%, the RMSE of the LGB model increased by 10.32%, and the RMSE of the XGB-LGB model increased by 7.66%, indicating that the cloud base height characteristic parameters can solve the problem of difficult irradiance prediction in cloudy weather to a certain extent.
[0071] Table 8 Evaluation indexes of cloud base height for different models under broken clouds
[0072] Table 9 Evaluation indexes of cloud-free base height of different models under broken clouds
[0073] Under blocky cloud distribution, the model accuracy is the lowest among the three cloud types. Fig.19 It can be seen that blocky clouds account for the largest proportion of the sky among the three types, and their obstruction to the sun is also the most serious, which leads to drastic fluctuations in solar irradiance, thereby reducing the prediction accuracy of the model. After introducing the cloud base height feature, the improvement of each model is relatively ideal, indicating that there is still much room for improvement in the prediction accuracy of this cloud type.
[0074] In view of the problem that the irradiance fluctuates violently and the cloud layer changes rapidly in cloudy weather, making it difficult to make accurate irradiance predictions, this embodiment proposes to calculate the cloud base height in cloudy weather through a multi-view sky cloud camera, and obtain a fusion model by stacking two base models. With the cloud base height as an input feature parameter, the fusion model is used for training and prediction. Experiments have shown that the cloud base height parameter has a very important influence on the irradiance prediction in cloudy conditions. Combined with the fusion model, accurate prediction of irradiance in cloudy weather can be achieved, and a certain accuracy rate can be achieved.
[0075] Example 4 This embodiment provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of the irradiance prediction method based on multi-view ground-based cloud images described in Embodiment 1 or 3 are implemented.
[0076] Example 5 This embodiment provides a computer device, including: Memory, for storing computer instructions; A processor is used to execute the computer instructions to implement the steps of the irradiance prediction method based on multi-view ground-based cloud images described in Example 1 or 3.
[0077] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0078] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0079] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0080] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0081] The embodiments of the present invention are described above in conjunction with the accompanying drawings, but the present invention is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the enlightenment of the present invention, ordinary technicians in this field can also make many forms without departing from the scope of protection of the purpose of the present invention and the claims, which all fall within the protection of the present invention.
Claims
1. A method for predicting irradiance based on multi-view ground cloud images, characterized in that: include: Obtain multi-view ground cloud images; Extracting cloud image parameters of the multi-view ground-based cloud image, identifying and matching feature points of the multi-view ground-based cloud image, and calculating cloud base height using the feature points and basic matrix of the matched multi-view ground-based cloud image; Inputting the cloud image parameters and cloud bottom height into a pre-built irradiance prediction model, and outputting the irradiance prediction result; Wherein, the construction of the irradiance prediction model includes: Multiple XGB models are used as base learners and LGB models are used as meta-learners. The model stacking method is adopted to construct the irradiance prediction model.
2. The irradiance prediction method based on multi-view ground cloud map according to claim 1 is characterized in that: Before extracting the cloud map parameters of the multi-view ground-based cloud map, the method further includes using a chessboard calibration method to perform distortion correction on the multi-view ground-based cloud map, specifically: A fisheye camera is used to take multiple photos containing a chessboard at different angles and positions, and a calibration algorithm is used to detect corner points and extract sub-pixels of the chessboard. According to the extracted coordinates of the chessboard points, the parameters of the fisheye camera and the distortion parameters are calculated, and the parameters of the fisheye camera are changed into the distortion parameters.
3. The irradiance prediction method based on multi-view ground cloud map according to claim 1 is characterized in that: The identifying and matching the feature points of the multi-view ground-based cloud image includes: The SIFT algorithm is used to identify the feature points of the multi-view ground-based cloud image, a descriptor of the feature point is generated, an index data structure of the descriptor is established using the FLANN library, and the feature points of the multi-view ground-based cloud image are matched.
4. The irradiance prediction method based on multi-view ground cloud map according to claim 1 is characterized in that: The basic matrix is expressed as: ; In the formula, is the three-dimensional coordinate of the spatial point P under the left-view foundation cloud map; is the basic matrix; is the three-dimensional coordinate of the spatial point P under the right-view foundation cloud map; for The x-axis coordinate of for The y-axis coordinate of for The x-axis coordinate of for The y-axis coordinate of .
5. The irradiance prediction method based on multi-view ground cloud map according to claim 1 is characterized in that: The steps of calculating the cloud base height include: A left-view fisheye camera A and a right-view fisheye camera B at the same height are used to respectively shoot a left-view ground cloud image I1 and a right-view ground cloud image I2, and a left feature point M on the left-view ground cloud image I1, a right feature point N on the right-view ground cloud image I2, and an intersection point P between a line connecting the left-view fisheye camera A and the left feature point M and a line connecting the right-view fisheye camera B and the right feature point N are respectively selected using a basic matrix; The intersection point between the line connecting the left-view fisheye camera A and the right-view fisheye camera B and the left-view ground cloud image I1 is taken as the left pole E, and the intersection point between the line connecting the left-view fisheye camera A and the right-view fisheye camera B and the right-view ground cloud image I2 is taken as the right pole F; the line connecting the left feature point M on the left-view ground cloud image I1 and the left pole E is taken as the left pole line L1, and the line connecting the right feature point N on the right-view ground cloud image I2 and the right pole F is taken as the right pole line L2; The motion relationship from the left-view ground foundation cloud image I1 to the right-view ground foundation cloud image I2 is obtained by using the left polar line L1 and the right polar line L2, and the three-dimensional coordinates of the intersection point P are calculated according to the motion relationship; The difference between the z-axis coordinate of the three-dimensional coordinates of the intersection point P and the height of the fisheye camera is used as the cloud bottom height.
6. The irradiance prediction method based on multi-view ground cloud map according to claim 1 is characterized in that: Training the irradiance prediction model using mean absolute error, root mean square error and coefficient of determination includes: ; ; ; In the formula, is the mean absolute error; is the root mean square error; is the coefficient of determination; is the number of irradiance feature points; is the predicted value of irradiance; is the true value of irradiance; is the average value of the predicted irradiance.
7. An irradiance prediction system based on multi-view ground cloud images, characterized in that: include: A ground-based cloud image acquisition module is used to acquire multi-view ground-based cloud images; A cloud image parameter extraction module, used to extract cloud image parameters of the multi-view ground-based cloud image; A cloud base height calculation module is used to identify and match the feature points of the multi-view ground-based cloud image, and calculate the cloud base height using the feature points of the matched multi-view ground-based cloud image and a basic matrix; Inputting the cloud image parameters and cloud bottom height into a pre-built irradiance prediction model, and outputting the irradiance prediction result; Wherein, the construction of the irradiance prediction model includes: The multiple XGB models are used as base learners and the LGB model is used as a meta-learner, and a model stacking method is adopted to construct an irradiance prediction model.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the irradiance prediction method based on multi-view ground-based cloud images described in any one of claims 1 to 6 are implemented.
9. A computer device, characterized in that: include: Memory, for storing computer instructions; A processor is used to execute the computer instructions to implement the steps of the irradiance prediction method based on multi-view ground-based cloud images described in any one of claims 1 to 6.