## 3 Results
Now moving on to the training-validation graphs concerning the number of epochs, only for the model with the best performance without considering training time (up-sampling, LSTM, MSE), did the training process generate four graphs (loss function value, and the other loss functions). Even though the parameters were changed only due to the loss function, keeping track of different metrics also helps to diagnose better how well the model is adapting to the training dataset, and the generalization process that it is following on the validation dataset, as it would be helpful later on the testing dataset. For the best performing model, the MAE function graph of 4, 8, and 16 neurons is in Figure 7. Although the loss function is MSE, the MAE plot shows more clearly how the model was over-fitting when using 4 and 16 neurons, as the validation curve tends to be higher than the training curve; that it is to say that when using \(n_{epoch}=\infty\), the trend of \(MAE_{validation}>MAE_{training}\) would most likely still be present. On the other hand, when using eight neurons, it seems to converge on similar MAE values for both validation and training datasets \(MAE_{validation}\approx MAE_{training}\); this would then represent an ideal fit rather than over-fit of the training dataset, and thus validates the use of eight neurons, based on \(f(x)=2^{x}\) to draw possible neuron values. Based on the previously mentioned descriptions, Figure 7 would be ideal because both training and validation loss converged to a similar loss when considering 25 epochs, even though validation loss was lower than training loss when \(n_{epochs}<5\). The under-fit behavior was corrected in the following epochs because the neural network learned from the training dataset, lowering the training loss while still lowering the validation loss at a  
Figure 7: Training and validation MAE curves when using 4 (black), 8 (red), and 16 (green) neurons on the second layer (LSTM, GRU, Simple). These curves correspond to the best performing model, which used down-sampled data, LSTM as the type of layer, and MSE as the loss function. In the cases of using 4 and 16 neurons, the validation curve (dotted line) tends to be above the training curve (straight line), leading to over-fit, whereas the use of 8 neurons shows an ideal fit, as both training and validation curves are similar when \(n_{epoch}>5\). similar rate to not over-fit the dataset. Most of the models created showed a similar trend, which validates the models, as they fitted the training dataset ideally and thus are capable of predicting. To visually evaluate predictions done by the best performing model (up-sampling, LSTM, MSE), a line plot for each force dimension (\(F_{x}\), \(F_{y}\), \(F_{z}\)) contrasting the measured and predicted values is shown in Figure 8. It comprises three plots with scaled force values (\(N\)) on each vertical axis, and the horizontal axis represents time in seconds (s). In this case, a plot of 500 s was enough to show a pattern and how well the model was performing at predicting each force. Based on predictions and measured values in Figure 8, force predictions are close to measured values on \(F_{x}\) and \(F_{y}\). This might be because measured values behave cyclically, and thus an RNN with a specific sequence size can detect the trend and adapt their parameters more quickly than when no movement is present. Moreover, predicted values in \(F_{y}\) reached values \(<0\); this is an impossible value for scaled forces, as the min-max scaler changes value's domain to be between 0 and 1, this would only create faulty, impossible  
Figure 8: Scaled forces (N), reference (straight line) and predicted (dotted line) values for each dimension: \(F_{x}\) (**top**), \(F_{y}\) (**middle**), \(F_{z}\) (**bottom**). The best performing model (up-sampling, MSE, LSTM) according to Figure 6 and Table 4 was used to predict the values using the testing dataset.