In the last decade, machine learning is increasingly attracting researchers in several scientific areas and, in particular, in the additive manufacturing field. Meanwhile, this technique remains as a black box technique for many researchers. Indeed, it allows obtaining novel insights to overcome the limitation of classical methods, such as the finite element method, and to take into account multi-physical complex phenomena occurring during the manufacturing process. This work presents a comprehensive study for implementing a machine learning technique (artificial neural network) to predict the thermal field evolution during the direct energy deposition of 316L stainless steel and tungsten carbides. The framework consists of a finite element thermal model and a neural network. The influence of the number of hidden layers and the number of nodes in each layer was also investigated. The results showed that an architecture based on 3 or 4 hidden layers and the rectified linear unit as the activation function lead to obtaining a high fidelity prediction with an accuracy exceeding 99%. The impact of the chosen architecture on the model accuracy and CPU usage was also highlighted. The proposed framework can be used to predict the thermal field when simulating multi-layer deposition.