This study aimed to compare the performance of the Gated Recurrent Unit (GRU) and Attention-Based GRU models in predicting daily rainfall based on historical weather parameters, including average temperature, relative humidity, sunshine duration, and wind speed. The data used were daily data from the Meteorology, Climatology, and Geophysics Agency (BMKG) for the period 2000–2023. The research steps included data preprocessing, feature selection, model training, and performance evaluation using the Root Mean Square Error (RMSE) metric. The results showed that the GRU model produced an RMSE of 0.5984, while the Attention-Based GRU model provided better and more stable performance with an RMSE of 0.5604. The integration of attention mechanisms has been shown to improve prediction accuracy, model stability, and resilience to overfitting, thus contributing to climate change adaptation strategies and decision-making in the agricultural sector. Keywords: Extreme Weather, Rainfall, Deep Learning, Early Warning, Weather Prediction.
Copyrights © 2026