Exploiting Inter-Day Weather Dynamics for Improved Day-Ahead Solar Irradiance Forecasting
Abstract
1. Introduction
- Specialized training by weather transition: A novel forecasting framework is proposed that trains dedicated deep learning models for each of nine day-to-day sky condition transitions, allowing the models to become experts on specific weather dynamics.
- Synergistic feature integration: The effective use of a feature set that combines historical ground-based data with forward-looking cloud cover forecasts to improve predictive accuracy.
- Dual-attention transformer (DAT) for solar forecasting: An encoder-only, dual-attention transformer that efficiently models both temporal and cross-feature dependencies in the multimodal data.
- Systematic performance evaluation: A rigorous benchmarking of the specialized framework against baselines across a wide range of weather scenarios.
- Probabilistic forecast generation: The adaptation of the deterministic model to provide calibrated probabilistic forecasts using quantile regression, enabling the quantification of forecast uncertainty through prediction intervals.
2. Dataset
2.1. Time Series
2.2. Pre- and Postprocessing
3. Methodology
3.1. Persistent Model
3.2. Dual-Attention Transformer
- Query ()—determines what the model is looking for,
- Key ()—contains information that may be relevant to a query,
- Value ()—the actual content to be aggregated or passed through.
- Multi-head self-attention (to capture contextual relationships), and
- Position-wise feed forward network (to model feature interactions independently at each time step)
3.3. Probabilistic Forecasting by Quantiles
- When ω = 0.5, the model penalizes over- and under-predictions equally, yielding the median forecast.
- If ω > 0.5, the model penalizes under-predictions more heavily, pushing more observations above the forecast line.
- Conversely, if ω < 0.5, over-predictions are penalized more, resulting in more points below the forecast.
3.4. Implementation
3.5. Evaluation Metrics
4. Results
4.1. Deterministic Forecasting
4.2. Probabilistic Forecasting
- If the actual GHI variation is fully contained within the 80% prediction interval, the narrowest possible interval that still captures all the GHI values is selected by adjusting the upper and lower quantiles accordingly.
- If the GHI occasionally exceeds the 90th quantile but remains above the 10th, the upper bound is fixed at the 90th quantile, while the lower bound is selected as the quantile that closely contains the lower range of GHI variation.
- Similarly, if the GHI occasionally drops below the 10th quantile but stays below the 90th, the lower bound is fixed at the 10th quantile, and the upper bound is selected based on the upper range of the observed GHI.
- If the GHI values fall outside both the 10th and 90th quantiles, the full 80% interval is retained without modification.
5. Conclusions
Author Contributions
Funding
Data Availability Statement
Conflicts of Interest
Nomenclature
| Abbreviations | |
| AA | Solar azimuth angle [°] |
| AI | Artificial intelligence |
| AIW | Average interval width |
| ANN | Artificial neural network |
| ARMA | Autoregressive moving average |
| AT | Ambient temperature [°C] |
| C | Clear |
| CC | Cloud cover |
| CNN | Convolutional neural network |
| CrossViVit | Cross Vision Video Transformer |
| CS GHI | Clear sky global horizontal irradiance [W/m2] |
| CSI | Clear sky index |
| DAT | Dual-attention transformer |
| DHI | Diffuse horizontal irradiance [W/m2] |
| DN | Day number |
| DNI | Direct normal irradiance [W/m2] |
| DP | Dew point temperature [°C] |
| ECMWF | European Centre for Medium-Range Weather Forecasts |
| FFT | Fast Fourier transform |
| GELU | Gaussian Error Linear Unit |
| GFS | Global Forecast System |
| GHI | Global horizontal irradiance [W/m2] |
| HH | Hour of the day |
| IC | Interval coverage [%] |
| JMA GSM | Japan Meteorological Agency Global Spectral Model |
| LSTM | Long short-term memory |
| MAE | Mean absolute error |
| MA | Moving average |
| MLP | Multilayer perceptron |
| MSE | Mean square error |
| NWP | Numerical weather prediction |
| O | Overcast |
| PC | Partly cloudy |
| PCA | Principal component analysis |
| PV | Photovoltaic |
| RH | Relative humidity [%] |
| RMSE | Root mean square error |
| RNN | Recurrent neural network |
| SARIMA | Seasonal autoregressive integrated moving average |
| SVM | Support vector machine |
| VP | Vapor pressure [hPa] |
| WD | Wind direction [°] |
| WRF | Weather Research and Forecasting |
| WS | Wind speed [m/s] |
| ZA | Solar zenith angle [°] |
| Notations | |
| daily mean clear sky index | |
| number of consecutive daily records | |
| predicted GHI for hour on day | |
| measured GHI for hour on the previous day | |
| true and predicted values | |
| input sequence | |
| input sequence after embedding | |
| weights for the embedding layer, projection into query, key, value matrices, and final output | |
| bias for the embedding layer | |
| batch size | |
| number of time steps | |
| number of features | |
| dimensions of the model, key/query, and value vectors | |
| Query vector | |
| Key vector | |
| Value vector | |
| number of attention heads | |
| numbering of the attention head | |
| number of encoder stacks | |
| input to residual connection and layer normalization | |
| pinball loss | |
| quantile level | |
| number of evaluated days | |
References
- Antonanzas, J.; Osorio, N.; Escobar, R.; Urraca, R.; Martinez-de-Pison, F.J.; Antonanzas-Torres, F. Review of photovoltaic power forecasting. Sol. Energy 2016, 136, 78–111. [Google Scholar] [CrossRef]
- Yang, D.; Wang, W.; Gueymard, C.A.; Hong, T.; Kleissl, J.; Huang, J.; Perez, M.J.; Perez, R.; Bright, J.M.; Xia, X.; et al. A review of solar forecasting, its dependence on atmospheric sciences and implications for grid integration: Towards carbon neutrality. Renew. Sustain. Energy Rev. 2022, 161, 112348. [Google Scholar] [CrossRef]
- Das, U.K.; Tey, K.S.; Seyedmahmoudian, M.; Mekhilef, S.; Idris, M.Y.I.; Van Deventer, W.; Horan, B.; Stojcevski, A. Forecasting of photovoltaic power generation and model optimization: A review. Renew. Sustain. Energy Rev. 2018, 81, 912–928. [Google Scholar] [CrossRef]
- Kumari, P.; Toshniwal, D. Deep learning models for solar irradiance forecasting: A comprehensive review. J. Clean. Prod. 2021, 318, 128566. [Google Scholar] [CrossRef]
- Takamatsu, T.; Ohtake, H.; Oozeki, T.; Nakaegawa, T.; Honda, Y.; Kazumori, M. Regional solar irradiance forecast for kanto region by support vector regression using forecast of meso-ensemble prediction system. Energies 2021, 14, 3245. [Google Scholar] [CrossRef]
- Konstantinou, T.; Hatziargyriou, N. Day-Ahead Parametric Probabilistic Forecasting of Wind and Solar Power Generation Using Bounded Probability Distributions and Hybrid Neural Networks. IEEE Trans. Sustain. Energy 2023, 14, 2109–2120. [Google Scholar] [CrossRef]
- Badosa, J.; Gobet, E.; Grangereau, M.; Kim, D. Day-Ahead Probabilistic Forecast of Solar Irradiance: A Stochastic Differential Equation Approach. Springer Proc. Math. Stat. 2018, 254, 73–93. [Google Scholar] [CrossRef]
- Barhmi, K.; Heynen, C.; Golroodbari, S.; van Sark, W. A Review of Solar Forecasting Techniques and the Role of Artificial Intelligence. Solar 2024, 4, 99–135. [Google Scholar] [CrossRef]
- Takamatsu, T.; Ohtake, H.; Oozeki, T. Support Vector Quantile Regression for the Post-Processing of Meso-Scale Ensemble Prediction System Data in the Kanto Region: Solar Power Forecast Reducing Overestimation. Energies 2022, 15, 1330. [Google Scholar] [CrossRef]
- Fonseca, J.G.D.S.; Uno, F.; Ohtake, H.; Oozeki, T.; Ogimoto, K. Enhancements in day-ahead forecasts of solar irradiation with machine learning: A novel analysis with the Japanese mesoscale model. J. Appl. Meteorol. Climatol. 2020, 59, 1011–1028. [Google Scholar] [CrossRef]
- Verbois, H.; Rusydi, A.; Thiery, A. Probabilistic forecasting of day-ahead solar irradiance using quantile gradient boosting. Sol. Energy 2018, 173, 313–327. [Google Scholar] [CrossRef]
- Husein, M.; Chung, I.Y. Day-ahead solar irradiance forecasting for microgrids using a long short-term memory recurrent neural network: A deep learning approach. Energies 2019, 12, 1856. [Google Scholar] [CrossRef]
- Qing, X.; Niu, Y. Hourly day-ahead solar irradiance prediction using weather forecasts by LSTM. Energy 2018, 148, 461–468. [Google Scholar] [CrossRef]
- Hong, Y.Y.; Martinez, J.J.F.; Fajardo, A.C. Day-Ahead Solar Irradiation Forecasting Utilizing Gramian Angular Field and Convolutional Long Short-Term Memory. IEEE Access 2020, 8, 18741–18753. [Google Scholar] [CrossRef]
- Çevik Bektaş, S.; Altaş, I.H. DWT-BILSTM-based models for day-ahead hourly global horizontal solar irradiance forecasting. Neural Comput. Appl. 2024, 36, 13243–13253. [Google Scholar] [CrossRef]
- Rathore, A.; Gupta, P.; Sharma, R.; Singh, R. Day ahead solar forecast using long short term memory network augmented with Fast Fourier transform-assisted decomposition technique. Renew. Energy 2025, 247, 123021. [Google Scholar] [CrossRef]
- Vaswani, A.; Shazeer, N.; Parmar, N.; Uszkoreit, J.; Jones, L.; Gomez, A.N.; Kaiser, Ł.; Polosukhin, I. Attention Is All You Need. arXiv 2017. [Google Scholar] [CrossRef]
- Bentsen, L.Ø.; Warakagoda, N.D.; Stenbro, R.; Engelstad, P. Spatio-temporal wind speed forecasting using graph networks and novel Transformer architectures. Appl. Energy 2023, 333, 120565. [Google Scholar] [CrossRef]
- Ji, J.; He, J.; Lei, M.; Wang, M.; Tang, W. Spatio-Temporal Transformer Network for Weather Forecasting. IEEE Trans. Big Data 2024, 11, 372–387. [Google Scholar] [CrossRef]
- Zhang, Y.; Yan, J. Crossformer: Transformer Utilizing Cross-Dimension Dependency for Multivariate Time Series Forecasting. In Proceedings of the 11th International Conference on Learning Representations ICLR 2023, Kigali, Rwanda, 1–5 May 2023; Volume 1, pp. 1–21. [Google Scholar]
- Ding, M.; Xiao, B.; Codella, N.; Luo, P.; Wang, J.; Yuan, L. DaViT: Dual Attention Vision Transformers. In Proceedings of the 17th European Conference on Computer Vision, ECCV 2022, Tel Aviv, Israel, 23–27 October 2022; Volume 13684, pp. 74–92. [Google Scholar] [CrossRef]
- Boussif, O.; Boukachab, G.; Assouline, D.; Massaroli, S.; Yuan, T.; Benabbou, L.; Bengio, Y. Improving day-ahead Solar Irradiance Time Series Forecasting by Leveraging Spatio-Temporal Context. arXiv 2023. [Google Scholar] [CrossRef]
- Zhang, Z.; Huang, X.; Li, C.; Cheng, F.; Tai, Y. CRAformer: A cross-residual attention transformer for solar irradiation multistep forecasting. Energy 2025, 320, 135214. [Google Scholar] [CrossRef]
- Yang, Y.; Tang, Z.; Li, Z.; He, J.; Shi, X.; Zhu, Y. Dual-Path Information Fusion and Twin Attention-Driven Global Modeling for Solar Irradiance Prediction. Sensors 2023, 23, 7469. [Google Scholar] [CrossRef]
- Erdmann, N.; Bentsen, L.O.; Stenbro, R.; Riise, H.N.; Warakagoda, N.; Engelstad, P. Deep and Probabilistic Solar Irradiance Forecast at the Arctic Circle. In Proceedings of the 2024 IEEE 52nd Photovoltaic Specialist Conference (PVSC), Seattle, WA, USA, 9–14 June 2024; pp. 1599–1606. [Google Scholar] [CrossRef]
- Huang, H.H.; Huang, Y.H. Probabilistic forecasting of regional solar power incorporating weather pattern diversity. Energy Rep. 2024, 11, 1711–1722. [Google Scholar] [CrossRef]
- Bayasgalan, O.; Adiyabat, A.; Otani, K.; Hashimoto, J.; Akisawa, A. A High-Resolution Satellite-Based Solar Resource Assessment Method Enhanced with Site Adaptation in Arid and Cold Climate Conditions. Energies 2024, 17, 6433. [Google Scholar] [CrossRef]
- Holmgren, F.W.; Hansen, W.C.; Mikofski, A.M. pvlib python: A python package for modeling solar energy systems. J. Open Sour. Softw. 2018, 3, 884. [Google Scholar] [CrossRef]
- ERA5 Hourly Data on Single Levels from 1940 to Present. Available online: https://cds.climate.copernicus.eu/datasets/reanalysis-era5-single-levels?tab=overview (accessed on 12 June 2025).
- Global Forecast System (GFS)|National Centers for Environmental Information (NCEI). Available online: https://www.ncei.noaa.gov/products/weather-climate-models/global-forecast (accessed on 24 October 2025).
- Forecasts|ECMWF. Available online: https://www.ecmwf.int/en/forecasts (accessed on 24 October 2025).











| Model | Advantage | Disadvantage | Error |
|---|---|---|---|
| NWP (WRF, GFS, ECMWF, JMA GSM, etc.) | Simulates atmospheric states through physics, capturing large-scale weather phenomena without historical training data. | Highly dependent on accurate initial and boundary conditions. Coarse spatiotemporal resolution can miss localized cloud effects. | Medium to high |
| Statistical (Persistent, MA, ARMA, SARIMA, etc.) | Simple to implement, computationally efficient, and effective for stable, clear-sky conditions. | Fails to capture complex, non-linear atmospheric dynamics, especially during rapidly changing weather. | High |
| AI-based (ANN, SVM, etc.) | Can learn complex non-linear patterns directly from historical data. | Requires large amounts of high-quality training data and can be computationally expensive. | Medium |
| Hybrid | Combines the strengths of multiple models (e.g., NWP and AI) for improved accuracy. | Complexity increases, making the model more difficult to implement, train, and interpret. | Low |
| Our approach | Combines a state-of-the-art deep learning architecture (Dual-attention transformer) with an improved ‘cluster-then-forecast’ strategy based on weather transitions. | Needs a preliminary forecast to classify the next day’s sky class. | Will be reported in this study. |
| Weather Parameter | Measuring Device | Specifications | Resolution |
|---|---|---|---|
| Wind speed and direction | Young CYG-5103, R. M. Young Company, Traverse City, MI, USA | vane anemometer | 0.098 (m/s)/Hz |
| Ambient temperature | C-PT-10, R. M. Young Company, Traverse City, MI, USA | resistance temperature detector | 10 Ω at 0 °C |
| Relative humidity | CVS-HMP155D, R. M. Young Company, Traverse City, MI, USA | capacitive thin film humidity sensor | 0–1 Vdc for 0–100% |
| Global horizontal irradiance | Hukseflux CHF-SR11, R. M. Young Company, Traverse City, MI, USA | class B pyranometer | 10–40 mV/(kW/m2) |
| Previous Day Features | Forecast Day Features | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| WS | WD | AT | RH | VP | DP | GHI | CC | HH | DN | CS GHI | ZA | AA |
| 0.23 | 0.04 | 0.51 | −0.26 | 0.34 | 0.42 | 0.68 | −0.12 | −0.08 | −0.10 | 0.77 | −0.76 | −0.05 |
| Sky Condition | Persistent | DAT (Generalized) | DAT (Specialized 3 Class) | DAT (Specialized 9 Class) | ||||
|---|---|---|---|---|---|---|---|---|
| MAE | RMSE | MAE | RMSE | MAE | RMSE | MAE | RMSE | |
| C-C | 47.55 | 84.50 | 45.19 ± 1.80 | 73.74 ± 1.37 | 41.22 ± 1.69 | 64.26 ± 3.13 | 37.25 ± 0.68 | 59.52 ± 0.47 |
| C-PC | 155.95 | 223.56 | 109.14 ± 1.06 | 154.88 ± 1.66 | 115.30 ± 3.64 | 149.95 ± 2.53 | 107.08 ± 0.82 | 144.71 ± 0.69 |
| C-O | 280.59 | 330.48 | 140.92 ± 6.74 | 184.03 ± 5.96 | 76.07 ± 2.20 | 98.28 ± 1.28 | 72.82 ± 0.52 | 94.52 ± 0.87 |
| PC-C | 168.03 | 233.43 | 72.01 ± 2.25 | 105.59 ± 2.36 | 57.61 ± 3.40 | 86.48 ± 2.70 | 53.70 ± 2.74 | 82.36 ± 0.83 |
| PC-PC | 154.39 | 215.15 | 116.09 ± 1.14 | 162.26 ± 1.68 | 122.73 ± 4.22 | 157.58 ± 4.23 | 114.81 ± 0.62 | 150.25 ± 0.51 |
| PC-O | 155.93 | 208.56 | 142.33 ± 5.88 | 187.24 ± 6.25 | 92.62 ± 1.66 | 127.80 ± 1.18 | 86.52 ± 1.70 | 122.37 ± 0.95 |
| O-C | 310.72 | 377.78 | 88.90 ± 3.51 | 124.40 ± 4.21 | 74.21 ± 11.99 | 98.13 ± 8.52 | 63.47 ± 4.15 | 92.77 ± 3.18 |
| O-PC | 234.88 | 300.31 | 141.77 ± 1.57 | 182.04 ± 2.17 | 139.56 ± 2.24 | 176.21 ± 3.71 | 136.85 ± 1.44 | 171.49 ± 1.22 |
| O-O | 103.38 | 145.65 | 114.37 ± 3.84 | 150.48 ± 2.67 | 82.51 ± 3.05 | 104.46 ± 0.70 | 81.81 ± 2.58 | 104.35 ± 1.05 |
| All-sky | 124.87 | 195.43 | 82.03 ± 0.98 | 125.57 ± 0.72 | 75.69 ± 2.38 | 111.75 ± 2.25 | 70.36 ± 0.50 | 106.84 ± 0.21 |
| Sky Condition | MAE, W/m2 | RMSE, W/m2 | IC, % | AIW, W/m2 |
|---|---|---|---|---|
| C-C | 36.14 ± 0.21 | 61.59 ± 1.11 | 91.52 ± 0.98 | 153.80 ± 5.62 |
| C-PC | 106.84 ± 0.74 | 146.11 ± 0.68 | 87.75 ± 2.33 | 376.62 ± 18.36 |
| C-O | 69.00 ± 0.96 | 92.98 ± 1.78 | 97.86 ± 1.58 | 324.00 ± 16.73 |
| PC-C | 51.32 ± 0.46 | 86.39 ± 0.58 | 93.17 ± 0.30 | 237.31 ± 4.65 |
| PC-PC | 114.78 ± 0.62 | 151.71 ± 0.71 | 87.81 ± 0.92 | 413.02 ± 10.08 |
| PC-O | 89.33 ± 1.04 | 128.99 ± 2.68 | 88.39 ± 1.59 | 333.62 ± 19.22 |
| O-C | 62.37 ± 4.82 | 93.81 ± 3.28 | 95.22 ± 0.89 | 362.19 ± 17.66 |
| O-PC | 137.07 ± 3.29 | 172.54 ± 2.94 | 88.61 ± 1.35 | 499.28 ± 18.33 |
| O-O | 78.34 ± 1.23 | 104.25 ± 0.63 | 92.22 ± 1.43 | 333.14 ± 13.95 |
| All-sky | 69.39 ± 0.30 | 108.71 ± 0.38 | 90.71 ± 0.27 | 273.22 ± 3.20 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Bayasgalan, O.; Adiyabat, A.; Akisawa, A. Exploiting Inter-Day Weather Dynamics for Improved Day-Ahead Solar Irradiance Forecasting. Solar 2025, 5, 54. https://doi.org/10.3390/solar5040054
Bayasgalan O, Adiyabat A, Akisawa A. Exploiting Inter-Day Weather Dynamics for Improved Day-Ahead Solar Irradiance Forecasting. Solar. 2025; 5(4):54. https://doi.org/10.3390/solar5040054
Chicago/Turabian StyleBayasgalan, Onon, Amarbayar Adiyabat, and Atsushi Akisawa. 2025. "Exploiting Inter-Day Weather Dynamics for Improved Day-Ahead Solar Irradiance Forecasting" Solar 5, no. 4: 54. https://doi.org/10.3390/solar5040054
APA StyleBayasgalan, O., Adiyabat, A., & Akisawa, A. (2025). Exploiting Inter-Day Weather Dynamics for Improved Day-Ahead Solar Irradiance Forecasting. Solar, 5(4), 54. https://doi.org/10.3390/solar5040054

