As is known, grain boundary (GB) energy determines the mobility of GBs and their population in metals. In this work, we study the energy of GBs in the (100) crystallographic plane and in the temperature range from 100 to 700 K. The study is carried out using both the molecular dynamic (MD) method and machine learning approach to approximate the MD data in order to obtain functional dependence in the form of a feed-forward neural network (FCNN). We consider the tilt and twist grain boundaries in the range of misorientation angles from 0 to 90°. Also, we calculate the average and minimum energy over the ensemble of GB states, since there are many stable and metastable structures with different energies even at a fixed grain misorientation. The minimum energies decrease with increasing temperature, which is consistent with the results of other studies. The scatter of GB energies in the temperature range from 100 to 700 K is obtained on the basis of MD simulation data. The obtained energy spread is in reasonable agreement with the data from other works on the values of GB energy in pure aluminum. The predictive ability of the trained FCNN as well as its ability to interpolate between the energy and temperature points from MD data are both demonstrated.