## 4 Results
### Machine Learning Results
However, the low accuracy is due to the shape classes being overlapped in the frequency feature space. The LSTM has low accuracy because it interprets a false causal relation between frequencies. The CNNs AlexNet, VGG-16, ResNet, and Inception have many parameters that codify many feature maps during propagation with irrelevant information and properties for shape classification. **Quality classification:** The NIIM classifies calibration pieces into normal and defect-calibration pieces. For task classification, the feature vector \(r_{d,\beta}(n)\) has a size of 508, and the feature vectors \(M_{d,\beta}(k)\) and \(D_{\Delta,\beta}(k)\) have a size of 168 because, according to our experiments, the frequencies \(2<k<170\) are enough to represent the quality of the contour profile in the frequency domain. The contour profile signature was selected because, according to [41], profile quality defects and form deviations affect wear resistance, tolerance accuracy, shape deformation, fatigue resistance, corrosion resistance, and fluid passage in the milling part. An expert generates the ground truths for task classification by dividing the dataset considering the geometric dimension and tolerances according to ASME Y14.5.1M and ISO 213 for machine learning purposes. Concerning the metrics of the experiments and results, we add the F-measure (F1) metric because it is used in many works, e.g., in [13; 14], and is defined as the harmonic mean between precision and recall in binary classifications. The NIIM considers the true positive when a normal piece is classified as normal. The networks rFFNN, mFFNN, and kFFNN have 48 neurons in the hidden layers, and they were tested with five validation experiments. Regarding converging epochs, rFFNN requires 69, mFFNN 100, kFFNN 110, CNNG 32, and CNNP 32. CNNG and CNNP require fewer epochs to converge than the other networks, but after 32 epochs, they cannot improve the accuracy. SVM, LSTM, AlexNet, VGG-16, ResNet, and Inception networks require 300 epochs. Table 8 shows the results of the experiments in quality classification, where kFFNN presents the best performance and computational cost because \(D_{\Delta,\beta}(k)\) describes the form deviation generated by the machined process. rFFNN and mFFNN had low performance in the test and training because the input feature vectors of \(r_{\alpha,\beta}(n)\) and \(M_{d,\beta}(k)\) concentrate most of their energy on shape features. Hence, these vectors feed the ANN with few form deviation features. The CNN networks had good accuracy during the training, but the accuracy during the test decreased significantly. This performance is because of overfitting generated by many features unrelated to the contour profile error [44]. Figures 33 and 34 show the second layer activation maps of CNNG and CNNP trained considering the normal and defective classes, where the features learned are focused on the \begin{table}
\begin{tabular}{c c c c c c} \hline \hline
**Network** & **Tacc** & **F1** & **Pacc** & **FPS** & **NPam** \\ \hline kFFNN & 95.2\% & 94.6\% & 97\% & 9000 & 8066 \\ mFFNN & 73.8\% & 74.5\% & 83\% & 8000 & 8067 \\ rFFNN & 71.1\% & 69.1\% & 87\% & 421 & 24,386 \\ CNNG & 100\% & 80.1\% & 87\% & 30 & 8,256,104 \\ CNNP & 95.1\% & 78.5\% & 88\% & 32 & 8,256,104 \\ SVM & 75\% & 72\% & 73\% & 300 & 753 \\ LSTM & 78\% & 69\% & 74\% & 5500 & 1250 \\ AlexNet & 58\% & 55\% & 41\% & 2 & 62,378,344 \\ VGG-16 & 54\% & 52\% & 39\% & 0.11 & 138,357,544 \\ ResNet-18 & 53\% & 52\% & 34\% & 4 & 11,174,362 \\ Inception-V3 & 53\% & 50\% & 35\% & 4 & 21,776,508 \\ \hline \hline \end{tabular}
\end{table} 
Table 8: Average results of the quality contour profile classification. shape properties. Then, rFFNN, mFFNN, CNNG, and CNNP process shape rather than form deviation features because the energy of the features is mainly concentrated in shape features. kFFNN achieves good results and has the lowest computational cost because it only has deviation features that describe the milling process in the piece.