Energy Consumption Prediction Using Deep Learning Technique Case Study of Computer College

—In the present era, due to technological advances, the problem of energy consumption has become one of the most important problems for its environmental and economic impact. Educational buildings are one of the highest energy consuming institutions. Therefore, one has to direct the individual and society to reach the ideal usage of energy. One of the possible methods to do that is to prediction energy consumption. This study proposes an energy consumption prediction model using deep learning algorithm. To evaluate its performance, College of Computer (CoC) at Qassim University was selected to analyze the elements in the college that affect high energy consumption and data were collected from the Saudi Electricity Company of daily for 13 years. This research applied Long short-term memory (LSTM) technique for medium-term prediction of energy consumption. The performance of the proposed model has been meas-ured by evaluation metrics and achieved low Root mean square error (RMSE) which means higher accuracy of the model compared to relative studies. Conse-quently, this research provides a recommendation for educational organizations to reach optimal energy consumption.


Introduction
At present people face an issue of energy consumption and increasing demand for electricity. Given Saudi Arabia economic and population growth, especially in the extreme weather conditions experienced by it. The demand for electricity in Saudi Arabia growing at an annual rate of nearly 8% [1]. In 2030, energy consumption will be double by reach 360 TWh [2], and the demand for electricity will increase to about 120 GW per year [1]. This is why consumers need to be aware of the optimal use of electricity. In Saudi Arabia, power plants rely on oil and natural gas [1]. Meeting the demand for electricity in the future is expected to consume 3 barrels of oil per day, caused a significant impact on the state economy by reducing the country's income from oil exports [1]. In Saudi Arabia, extreme weather is a major problem faced by society. It plays a 2 Analyzing the Problem In recent years, energy consumption has become one of the major problems because of its impact on the economic, financial spheres. In Saudi Arabia, there are many factors that cause increasing energy consumption in non-residential buildings.
In the CoC, there are many problems that cause increased consumption. Extreme weather is one of the main problems, causing summer temperature increases to increase energy consumption through repeated use of air conditioning. In winter, the heat causes increased energy consumption through repeated use of the heater [8], depending on the type, size, operation time and wattage consumed per hour. The number of devices has a large load on energy in general, the increase in the number will inevitably increase the consumption of energy [9]. In the CoC, there are many devices and servers. The growing number means increasing energy consumption. If we consider the workday, there are many lectures which mean there is excessive consumption of energy compared to the weekend. In addition to the practical examinations period, there are many uses of the devices. The presence of many cafeterias in the college is an additional reason for the increase in consumption because of the presence of a number of devices such as refrigerators, coffee makers and microwaves in each cafeteria. The presence of multiple devices around us is important and their quality is furthermore important to perform the best performance, but the low quality will not perform properly. The quality of devices in the field of electric power is very important because of the lack of quality whether it is old-fashioned or being affected by weather affects their consumption [2]. The quality of the devices affects the consumption of energy where the lower quality the greater consumption. Table 1 shows most important impacts and recommendations regarding to energy consumption. Table 1. Problem regarding to energy consumption

Recommendation Impact Problems
The use of shading devices in the building of the College of Computer to help reduce energy consumption.
Large windows and glass facades were used to allow sunlight to enter. In summer, sunlight causes a significant increase in temperature. This affects the heat inside the building and therefore leads to a negative impact on energy consumption.

1-Extreme weather
Reducing the number of devices used at the same time in order to help reduce loads and thus reduce consumption.
The types of devices used and their number has a clear and significant impact on the consumption of energy 2-Other devices It is better to use new devices that have been manufactured in recent years because of the new features and technologies that allow them to save energy while using them.
Old devices of a low quality are one of the main reasons for the excessive consumption of energy.

3-Quality of devices
Replacing the physical server with the Cloud Server that leads to less energy consumption.
The physical server leads to high energy consumption 4-Type of servers 3

Literature Review
So far, many studies have been done to build energy consumption prediction models using various machine learning techniques and algorithms.

Analytical work
Al-Mofeez (2007) [10] compared the past days to today, as the modern lifestyle has changed and developed the new buildings that need more equipment and thus increase consumption. The paper discussed energy saving and rehabilitation work for a onestory house in Dhahran. The data were compared based on the results before and after retrofitting. Data extraction techniques were used for the analytical process, and the International Performance Measurement and Verification Protocol IPMVP were used to measure the performance. The end result was a 34% reduction in peak consumption.
Another study by F.Alrashed and M.Asif (2014) [11] presented the trends in residential energy consumption in Saudi Arabia with particular reference to the Eastern Province. Saudi Arabia has the most challenging type of residential energy consumption due to its extreme weather. This study investigated some of the important factors related to residential energy consumption, i.e. weather conditions, types of dwellings, building envelopes, air conditioning (A / C) systems, and domestic appliances. The work of the study is based on an analysis of the actual monthly energy consumption of 115 dwellings in Dhahran for the year 2012. The scanned buildings include 62 apartments, 28 villas, and 25 traditional houses. The calculated annual average energy consumption for the surveyed housing was found to be 176.5 kWh/m2, a value higher than the international energy-efficiency benchmarks. It was found that the use of mini-split A / C systems, thermal insulation, and double-glazed windows could help reduce energy consumption by over 30%. In the two previous studies mentioned, the weather is similar to the weather in our study, i.e. both are extreme. But the case study in this research focuses on non-residential buildings while the previous studies focused on residential buildings.
K. Matsui (2015) [12] identified which devices consume more energy. An intelligent measurement system was used through a home sensor network in order to collect the total energy consumption, and the power lines collected the data of each electrical device. The process was applied to two houses in Japan. Sparse coding was implemented, and a new method called "0-1 coding" was proposed to improve the standard coding method for the total energy consumption of each electrical device. The data were collected every 5 minutes for one day. The result after comparing the two methods showed that the proposed method was better than the standard coding method, the accuracy increasing by about 44.8 %. Identifying which devices consume more energy helps us in the analysis part.
The study in [13] presented several issues that made it hard to store energy and necessitated the equivalence of production and consumption each time. The paper showed the preparation of appropriate data to predict future development. To analyze data, the hourly values of consumption and average monthly temperatures for the Czech Republic were used. For data preparation, the data available since 2006 from the transmission system operator CEPS published on its websites were used. The analysis was implemented in MATLAB software. The result showed that energy consumption is strongly dependent on weather changes. The study assists us in the analysis part and data preparation.
M. Hafer (2017) [14] showed that the problem of energy consumption was high in commercial buildings. This is going back on a lot of the equipment's exists this building. The study was conducted in 220 buildings on Stanford University campus, which included 110,529 pieces of component loading equipment. plug loads from these buildings consume approximately 50 million kilowatt hours per year and comprise 32% of energy consumption. The estimated power consumption assessed the total load power of the components based on the device type and the type of building. The results of this study were that some strategies could reduce energy consumption such as energy efficiency strategies in laboratories, shutting down laboratory equipment when not in use, using energy efficiency strategies for information technology such as server virtualization and computer power management, and condensing common devices such as printers, in addition to phasing out devices with a backup function such as fax machines and scanners. Because this is similar to the case study, the strategies proposed in the paper include some benefits to help reduce energy consumption.
T. Hong et al. (2013) [3] focused on the impact of weather on energy consumption. Buildings consumed more energy and the weather directly affected the thermal load, and thus the energy performance of buildings. To collect weather data, the researchers used Typical Meteorological Year (TMY) and large-scale building simulation (a total of 3162 runs) were employed to study the weather impact on peak electricity demand and energy use during 30 year (1980-2009). Actual Meteorological Year (AMY) weather data for three types of office buildings at two designed efficiency levels were used. The results of the paper included that the peak demand for electricity varied depending on the weather, and the weather impact was greater for buildings in colder climates than warmer climates. The study helps us to understand the effect of temperature on energy consumption.

Predictive work
In their study, J. Moon et al. (2017) [15] presented the problem of energy consumption on campus. Based on machine learning, Artificial neural network (ANN) and Support vector regression (SVR) algorithms were used in the prediction process. Root mean square error (RMSE) and Mean absolute error (MAE) were used to assess prediction accuracy. The study was applied to the campus in Seoul, capital of Korea, and the data were collected for 15 minutes for one year. The performance was evaluated in the algorithms used, resulting in a prediction model based on the ANN algorithm that performed better than the SVR-based model. The research is consistent with the previous research in that the studies were in a non-residential area and in an educational building.
The authors in (2018) [16] argued that due to population growth and economic development, energy consumption has furthermore increased in China and that increased usage of energy has led to severe problems. The authors developed techniques for the prediction of energy consumption and used the neural network in these techniques, specifically back-propagation (BP) neural network and Levenberg-Marquardt back-propagation (LM-BP) neural network algorithms. The case was studied in a shopping mall in China designed with input nodes from the building environment, e.g., temperature, humidity ratio, working day, weather characteristics, and wind speed, which could be used for the prediction of energy consumption. The researchers used neural networks due to their powerful learning function and also because they could rapidly predict the energy consumption of any building after inputting the requisite parameters. The results showed that the LM-BP neural network was more accurate than the BP neural network. The study was conducted to predict the consumption of energy in a non-residential building. This may help because the environment is almost similar and the inputs are similar to the methodology used.
K. Grolingera et al. (2016) [17] showed the importance of data size and the extent to which time accuracy affected consumption prediction. The study was conducted in a large entertainment venue in Canada. Data were selected and divided into three types: every day, every hour, and every 15 minutes. Two methods of machine learning, (SVR) and (ANN), were selected. ANN produced better accuracy than SVR, with more data per day than data every hour and every 15 minutes. In the research, there were factors that were similar to the factors in the previous research; they were applied to non-residential buildings, they used machine learning, and big data were used in both studies.
N.Beliaeva et al. (2010) [18] presented the importance of the ideal consumption of energy at home as a result of one of the largest consumption of electric energy in individual consumption in all European countries. The authors developed an analysis of a dataset based on energy consumption. The study was applied to one house, and a sample of data was taken for four years to try to figure out the patterns, cyclical or seasonal features, or other significant information that could allow them to predict the future demand with a certain degree of accuracy which, in turn, could help limit the demand for electricity. The researchers used a popular and widely used statistical method for time series prediction which is the ARIMA (autoregressive integrated moving average) model. The result of the research showed that the received forecast of the time-series data had a high degree of accuracy. The study provided some of the steps in various aspects that may help during the data analysis process and the preparation of data for time series data.
The study in (2018) [5] discussed the problem of increasing energy consumption in residential buildings due to improper usage; a tremendous amount of energy is wasted annually; hence, energy waste could be avoided by the efficient utilization of energy. The researchers considered energy consumption prediction very important to achieve efficient energy maintenance and reduce the environmental effect. They proposed a methodology for energy consumption prediction in residential buildings using the deep extreme learning machine (DELM) for energy consumption prediction. Further, the researchers also used the adaptive neuro-fuzzy inference system (ANFIS) and the artificial neural network (ANN) in prediction. They used different statistical measures for the performance measurements of the mean absolute error (MAE), the root mean square error (RMSE), and the mean absolute percentage error (MAPE) in order to compare between algorithms. The result showed the DELM was far better than ANFIS and ANN.

4
The Proposed Methodology In this research, energy consumption prediction will be applied in non-residential buildings and LSTM technique will be used because of the advantages of deep learning. CoC at Qassim university selected for this research and focused on four inputs the temperature C, workday (On or Off), number of devices and historical energy consumption by 13 years. The output will be medium-term prediction of energy consumption (kWh) and will apply a trial and error method to determine the optimal neural network structure. Figure 1 shows the working methodology after the data collection. Based on this prediction a recommendation will be provide to the organization. The energy consumption prediction model was Implement using Python with Keras library that using the TensorFlow backend. The dataset in the CSV file contains 5 features: date, temperature, number of devices, working days and daily energy consumption for 13 years and it has 4595 rows. The algorithm is a set of instructions to properly and effectively resolve a particular problem. Energy consumption data were collected from the Saudi Electricity Company. Weather data collected from open source, data of working days and number of devices were collected from the Computer College. In Figure 2 shows the algorithm used to develop the model.
In this research, LSTM is used to build the model and the trial and error method used to obtain the optimal network structure of the model. Before creating a network, each LSTMs require a three-dimensional form of input. Each memory cell outputs a single value as a 2D array.
Therefore, the data were divided into training (80%) and test (20%) data (X and Y) and then reshape the train and test into a three-dimensional format. The network structure has two hidden layers, an LSTM layer, and a dense layer. To pass the data into layers, sequential layer was created at the top of the form and then add the LSTM, Dropout, and Dense layers to that form. Dropout layer were added to avoid the model from overfitting and improving model performance. To make model more powerful, two dense layers have been added, first with 16 neurons with Ruel activation function and last layer with 1 neuron which is the output value with Linear activation function at the end of the model. Model compilation that means configures the model for training. Mean squared error has been used as loss function, Adam optimizer has been selected to optimize the algorithm and metrics to evaluate the accuracy of the model. Model Fit which means trains the model for a selected number of epochs and batch size, this research used 57 batch size and 512 epochs, in fit parameter the training data splitted to 10% validation and the rest to train data.

Result Analysis
The main reasons for increasing energy consumption in educational buildings were identified. Full analysis of CoC building in terms of all the factors triggering high energy consumption. Model to predict energy consumption using LSTM and got high accuracy by 94.31%. Offering a useful recommendation based on full analysis. In table 2 comparison between previous studies in predicting energy consumption which proved that this study benefited from the analysis of both factors and the current technologies and achieved better result.

Discussion and Recommendation
In this work, deep learning has been used to predict energy consumption in a nonresidential building and shows good results. This means that deep learning has shown its efficiency in prediction. The dataset contains 13 years on a daily basis and this is a historical and time series. Therefore, LSTM has proven its worth in prediction in time series. Figure 3 shows energy consumption for 2018 which has been analyzed and noticed at the beginning of the year energy consumption was in the middle and this is due to the temperature. At the beginning of the year energy consumption was low but with the increase in temperature, consumption increases significantly by about 40%. In the middle of the year from the month of 6 to the month of 9 is a summer vacation period, consumption is constant and low. It has been noticed that days before the start of the vacation, the consumption decrease 30%. This is due to the reason for the not end of staff work and furthermore after the vacation end, consumption increase 30% for same reason.

Conclusion
In this research, a predictive model of energy consumption has been developed in the building of the CoC, Qassim University using deep learning. This research developed an analysis of the building and identified the most important factors affectizzxng energy consumption and provided tips to reduce their impact. The model is designed using inputs that may affect the energy consumption in the building such as temperature, number of devices, working days and energy consumption. In this study, LSTM has been used for the development of the model for medium prediction of energy consumption with a large window size up to 35 which achieved a high accuracy by 94.31%. It was evaluated by RMSE and achieved 0.045. Consequently, a recommendation has been made to help reduce energy consumption in non-residential buildings.
In future work the proposed model can be applied either to residential or non-residential buildings. Adding another input factor such as types of devices can increase the accuracy of the result.