Machine Learning Based Weather Prediction Model for Short Term Weather Prediction in Sri Lanka


  • K.M.S.A. Hennayake Faculty of Engineering, University of Sri Jayewardenepura
  • R. Dinalankara Department of Computer Engineering, Faculty of Engineering, University of Sri Jayewardenepura
  • D.Y. Mudunkotuwa Department of Mechanical Engineering, Faculty of Engineering, University of Sri Jayewardenepura


Weather forecasting is the field of making predictions of the future state of the atmosphere of a certain location by analyzing initial values of relevant atmospheric characteristics which are obtained by meteorological observations. Since weather prediction has substantial effect in economic sectors such as agriculture, health, aviation, hydro power generation and even in daily lives of people, issuing accurate weather forecasts is a major responsibility of meteorological authorities across the world. Even though forecasting weather in mid-latitudes is uncomplicated and reliable, weather prediction in a tropical country like Sri Lanka is notoriously difficult as sudden changes of convective tropical weather phenomena are quite difficult to be predicted by prevailing Numerical Weather Prediction (NWP) methods. Therefore, the current research aims to present machine learning based weather prediction models for Sri Lanka for making short term forecasts for the most significant weather attributes such as temperature and precipitation. This paper discusses on implementing two multivariate Long Short-Term Memory Network models (LSTM) to make predictions on temperature and precipitation separately for a selected weather station in Sri Lanka and review the applicability of machine learning to solve highly nonlinear and complex weather problems. The prediction performances of the implemented LSTM models are evaluated using standard evaluation techniques such as Root Mean Squared Error (RMSE) and Mean Absolute Error (MAE). The results show that two LSTM models have made predictions with least RMSE and MAE values, evidencing the successful applicability of machine learning for solving complex and nonlinear patterns of past observational weather data and making accurate weather forecasts.

KEYWORDS: Weather Prediction, Neumerical Weather Prediction, Artificial Neural Network, LSTM