Predicting the Tool Wear of a Drilling Process Using Novel Machine Learning XGBoost-SDA

Tool wear negatively impacts the quality of workpieces produced by the drilling process. Accurate prediction of tool wear enables the operator to maintain the machine at the required level of performance. This research presents a novel hybrid machine learning approach for predicting the tool wear in a drilling process. The proposed approach is based on optimizing the extreme gradient boosting algorithm’s hyperparameters by a spiral dynamic optimization algorithm (XGBoost-SDA). Simulations were carried out on copper and cast-iron datasets with a high degree of accuracy. Further comparative analyses were performed with support vector machines (SVM) and multilayer perceptron artificial neural networks (MLP-ANN), where XGBoost-SDA showed superior performance with regard to the method. Simulations revealed that XGBoost-SDA results in the accurate prediction of flank wear in the drilling process with mean absolute error (MAE) = 4.67%, MAE = 5.32%, and coefficient of determination R2 = 0.9973 for the copper workpiece. Similarly, for the cast iron workpiece, XGBoost-SDA resulted in surface roughness predictions with MAE = 5.25%, root mean square error (RMSE) = 6.49%, and R2 = 0.975, which closely agree with the measured values. Performance comparisons between SVM, MLP-ANN, and XGBoost-SDA show that XGBoost-SDA is an effective method that can ensure high predictive accuracy about flank wear values in a drilling process.


Introduction
Production companies are attempting to boost product quality as well as to reduce operating costs. Online real-time control and monitoring of drilling processes was proposed as an effective method to minimize manufacturing costs [1]. The drilling process is one of the most used processes in manufacturing across various industries such as automotive and aerospace sectors [2]. The drilling process is produced by drilling and boring of material removal and is related to conventional drill bits geometry. One of the common problems across processes such as drilling, milling, and turning is the tool wear [3,4]. The worn tools lower the production quality and result in drilling holes and may lead to damage to both the workpiece and the machine. In addition, it may result in increasing the cutting force that results in raising the temperature and accelerate the tool wear [5,6].
There exist various types of drill tool wear such as flank wear, chisel edge wear, margin and crater wear [7]. Numerous investigations of tool wear in drilling processes exists in literature. Wang et al. [8] investigated the wear on three different drills (uncoated, diamond coated and AlTiN coated carbide) used in the drilling of carbon fiber reinforced composites (CFRP). Imran et al. [9] perceptron ANN (MLP-ANN). In the next section, the methodology of the proposed XGBoost-SDA approach is outlined with the nomenclature presented in Table 1. The simulation results present the predicted results and highlight the prediction accuracy of XGBoost-SDA when compared with the SVM and MLP-ANN approaches.

Extreme Gradient Boosting (XGBoost) Algorithm
XGBoost is a supervised machine learning algorithm developed by [28], which has caught the interest of researchers in various fields [29][30][31][32] due to its performance in terms of speed and accuracy. The algorithm has yielded state-of-the-art results on many benchmark problems due to its scalability, speed, distributed computing features and its ability to handle sparse data. XGBoost is an ensemble algorithm that aggregates weak learners, classification, and regression trees (CART), to build a powerful meta-learner for boosting performance. Let D = (x i , y i ) define a dataset with n samples and m features |D| = n, x i R m , y i R; the XGBoost algorithm ensembles K additive functions to predict the outputs as:ŷ in which the space of regression trees is denoted by F as: with q as the tree structure, T and ω representing the number of leaf nodes and associated weights respectively. To minimize the prediction error, we defined the regularized objective function as: with l as a differentiable convex loss function that defines the error between the actual and predicted values whereas Ω presents the penalization function defined as: The selection of hyperparameters of the XGBoost greatly impacts the model's predictive accuracy. Table 2 presents the hyperparameters of the XGBoost algorithm. Finding the optimal balance between these parameters by trial and error could be challenging. To overcome this challenge, we propose a novel XGBoost-SDA model to predict the tool wear of a drilling process. In the next section, the spiral dynamic optimization algorithm is introduced and the integration with XGBoost to optimize the hyperparameters is presented.

Spiral Dynamics Optimisation Algorithm (SDA)
A spiral dynamic algorithm (SDA) is a metaheuristic algorithm, which was developed by Tamura and Yasuda [33] and is inspired by the spiral phenomena in nature. SDA was proven to outperform many metaheuristic search algorithms in its convergence speed and accuracy, due to its diversification and intensification search approach. In diversification it searches for good solutions within the search space while intensification is used to search for the optimal values around the best solutions. Table 3 presents the nomenclature of the SDA parameters. Algorithm 1 presents the SDA steps to obtain the optimal solution. Assuming R is a rotation matrix for the n-dimension SDA algorithm where it is defined as The n-dimension spiral dynamic model is expressed using the rotational matrix as: Materials 2020, 13, 4952 The n-dimension SDA optimization algorithm is then written as Algorithm 1: Spiral dynamics optimization algorithm Step 0: Preparation Select the number of search points m ≥ 2 0 ≤ θ < 2π , 0 < r < 1 of S n (r, θ) and maximum number of iterations k max Step 1: Initialization Set initial points x i (0) R n , i = 1, 2, . . . , m in the feasible region randomly and centered x * with Step 2: Update x Step 3: Update x * Step 4: Check for the termination criteria If k = k max then terminate; otherwise set k = k + 1 and return to Step 2. In this research, we propose a novel hybrid XGBoost-SDA algorithm for predicting the tool wear. Figure 1 illustrates the proposed XGBoost-SDA flowchart.
The n-dimension SDA optimization algorithm is then written as
In this research, we propose a novel hybrid XGBoost-SDA algorithm for predicting the tool wear. Figure 1 illustrates the proposed XGBoost-SDA flowchart. The process starts by splitting the dataset into training and testing datasets. The training dataset presents 70% of the data to train the algorithm, while the remaining 30% are used for testing and The process starts by splitting the dataset into training and testing datasets. The training dataset presents 70% of the data to train the algorithm, while the remaining 30% are used for testing and validating the algorithm for the prediction performance and accuracy. An initial XGBoost algorithm is trained by the training data and the hyperparameters and the prediction accuracy is evaluated by calculating the root mean square error (RMSE). The hyperparameters are then fed into the SDA algorithm to find the best hyperparameter values with those that correspond to the lowest RMSE value. The optimal hyperparameters are then used to initialize a new XGBoost algorithm, referred to as XGBoost-SDA, to predict the tool wear values of the testing data set with the lowest RMSE.

Results and Discussion
In this section, the analyzed performance of the XGBoost -SDA algorithm enabled tool wear prediction model for drill wear prediction is reported. Tables 4-6 present the experimental dataset, performance metrics of XGBoost-SDA and the prediction results of the flank wear for a copper workpiece respectively with 49 experimental trials. While Tables 7-9 present the experimental dataset, performance metrics of the XGBoost-SDA and the flank wear prediction results of a cast iron workpiece respectively with 63 experimental trials.
The various trials provides combination of input parameters of spindle speed, drill diameter, feed rate, thrust force, and torque. Figure 2 presents the pair-wise relationship between the various inputs and the flank wear of the drilling process. It can be observed that the thrust force and torque have a linear relationship with the flank wear output variable; whereas the drill diameter, feed rate and spindle speed are in a non-linear relationship with the flank wear output variable.   High speed steel drill bits with different diameters (5, 7.5, and 10 mm) were used for drilling holes in the mild steel and copper workpieces. The spindle speed was incremented in six equally spaced intervals from 315 to 1000 rpm. Similarly, the feed rate was also varied in six steps from 0.13 to 0.71 mm/rpm. However, the type of wear in this machining process is adhesion due to its predominant wear factor in the drill cutting edges [34].
Different combinations of input parameters of spindle speed, feed rate and drill diameter were used to perform 49 trials of drilling process. The spindle speed values are within the range between 250-500 rpm and were varied in four steps. In addition, the feed rate was varied from 0.13 to 0.36 mm/rev in four steps. The drill diameter values were of 9, 10, 11, and 12 mm and were used to drill 15 mm thickness of cast iron workpiece. These three process parameters were used in 63 different combinations, and the corresponding output of the experimental setup noted in terms of thrust force, torque, and flank wear.
A comparison between the results of the proposed method (XGBoost-SDA) with SVM and MLP-ANN is provided in Tables 5 and 8. The comparison highlights the statistical performance metrics of each method such as mean absolute error (MAE), root mean square error (RMSE) and the coefficient of determination (R 2 ). In order to demonstrate the performance of XGBoost-SDA algorithm for tool wear prediction, two illustrative cases (copper and cast-iron workpiece), with datasets acquired from [17], were used in this simulation and its performance was compared with results and methods of the SVM and a MLP-ANN.  High speed steel drill bits with different diameters (5, 7.5, and 10 mm) were used for drilling holes in the mild steel and copper workpieces. The spindle speed was incremented in six equally spaced intervals from 315 to 1000 rpm. Similarly, the feed rate was also varied in six steps from 0.13 to 0.71 mm/rpm. However, the type of wear in this machining process is adhesion due to its predominant wear factor in the drill cutting edges [34].
Different combinations of input parameters of spindle speed, feed rate and drill diameter were used to perform 49 trials of drilling process. The spindle speed values are within the range between 250-500 rpm and were varied in four steps. In addition, the feed rate was varied from 0.13 to 0.36 mm/rev in four steps. The drill diameter values were of 9, 10, 11, and 12 mm and were used to drill 15 mm thickness of cast iron workpiece. These three process parameters were used in 63 different combinations, and the corresponding output of the experimental setup noted in terms of thrust force, torque, and flank wear.
A comparison between the results of the proposed method (XGBoost-SDA) with SVM and MLP-ANN is provided in Tables 5 and 8. The comparison highlights the statistical performance metrics of each method such as mean absolute error (MAE), root mean square error (RMSE) and the coefficient of determination (R 2 ). In order to demonstrate the performance of XGBoost-SDA algorithm for tool wear prediction, two illustrative cases (copper and cast-iron workpiece), with datasets acquired from [17], were used in this simulation and its performance was compared with results and methods of the SVM and a MLP-ANN.  Tables 6 and 9 present a comparison of the predicted values from the XGBoost-SDA, SVM, and MLP with the experimental values of the copper and cast iron workpieces, respectively. The results show that the predicted tool wear obtained by XGBoost-SDA closely matches the actual values of the measured tool wear compared to the SVM and MLP methods, which visually confirmed how well the XGBoost-SDA fitted the validation dataset.  However, as can be seen in Tables 5 and 8 all of the algorithms performed well, with slight performance measures, in predicting the flank wear values of the drilling process. It should be noted that XGBoost-SDA showed considerably better predictive performance, which outperformed SVM, and MLP-ANN in terms of the three performance indicators. Moreover, in the case of the copper workpiece, to ensure the reliability and efficiency of the XGBoost-SDA compared to the SVM and MLP-ANN methods, it should be noted that the model resulted in a mean absolute error (MAE) of 4.67% that reflected the efficacy of the XGBoost-SDA model to predict the flank wear values to a credible extent. In addition, the RMSE (Root Mean Square Error) value was 5.32% and the coefficient of determination R 2 was 0.9973 for the copper workpiece. For the cast iron workpiece, the results were 5.25% for RMS, 6.49% for MAE, and 0.9756 for R 2 , which reflects the good fit of the predicted values against the measured flank wear values.  Figure 4 presents a comparison of the errors in predicting flank wear for the XGBoost-SDA compared with the SVM and MLP-ANN for the copper workpiece. In predicting flank wear, the error with the XGBOOST-SDA model was the lowest (4.67%). It was found that the predictive XGBoost-SDA model was capable of better predictions of tool flank wear in the drilling process than the SVM and MLP-ANN models if they had been trained within the range. Additionally, it is noted that MLP-ANN resulted in higher prediction errors due to the fact that MLP-ANN requires tuning the number of layers as well as the number of neurons per layer. However, as can be seen in Tables 5 and 8 all of the algorithms performed well, with slight performance measures, in predicting the flank wear values of the drilling process. It should be noted that XGBoost-SDA showed considerably better predictive performance, which outperformed SVM, and MLP-ANN in terms of the three performance indicators. Moreover, in the case of the copper workpiece, to ensure the reliability and efficiency of the XGBoost-SDA compared to the SVM and MLP-ANN methods, it should be noted that the model resulted in a mean absolute error (MAE) of 4.67% that reflected the efficacy of the XGBoost-SDA model to predict the flank wear values to a credible extent. In addition, the RMSE (Root Mean Square Error) value was 5.32% and the coefficient of determination R 2 was 0.9973 for the copper workpiece. For the cast iron workpiece, the results were 5.25% for RMS, 6.49% for MAE, and 0.9756 for R 2 , which reflects the good fit of the predicted values against the measured flank wear values.  Figure 4 presents a comparison of the errors in predicting flank wear for the XGBoost-SDA compared with the SVM and MLP-ANN for the copper workpiece. In predicting flank wear, the error with the XGBOOST-SDA model was the lowest (4.67%). It was found that the predictive XGBoost-SDA model was capable of better predictions of tool flank wear in the drilling process than the SVM and MLP-ANN models if they had been trained within the range. Additionally, it is noted that MLP-ANN resulted in higher prediction errors due to the fact that MLP-ANN requires tuning the number of layers as well as the number of neurons per layer.     Figure 7 shows the comparison of errors in predicting flank wear for the XGBoost-SDA compared with the SVM and MLP-ANN for the cast iron workpiece. In predicting flank wear the error with the XGBOOST-SDA model was the lowest (5.25%). It was found that the predictive XGBoost-SDA model was capable of better predictions of tool flank wear in the drilling process than the SVM and MLP-ANN models if they had been trained within the range.     Figure 7 shows the comparison of errors in predicting flank wear for the XGBoost-SDA compared with the SVM and MLP-ANN for the cast iron workpiece. In predicting flank wear the error with the XGBOOST-SDA model was the lowest (5.25%). It was found that the predictive XGBoost-SDA model was capable of better predictions of tool flank wear in the drilling process than the SVM and MLP-ANN models if they had been trained within the range.  Figure 7 shows the comparison of errors in predicting flank wear for the XGBoost-SDA compared with the SVM and MLP-ANN for the cast iron workpiece. In predicting flank wear the error with the XGBOOST-SDA model was the lowest (5.25%). It was found that the predictive XGBoost-SDA model was capable of better predictions of tool flank wear in the drilling process than the SVM and MLP-ANN models if they had been trained within the range.

Conclusions
In this research we have presented a novel hybrid XGBoost-SDA prediction model for the flank wear of a drilling process. The strengths of XGBoost combined with the fast and accurate SDA showed superior performance in terms of the accurate prediction of flank wear for copper and cast-

Conclusions
In this research we have presented a novel hybrid XGBoost-SDA prediction model for the flank wear of a drilling process. The strengths of XGBoost combined with the fast and accurate SDA showed superior performance in terms of the accurate prediction of flank wear for copper and cast-

Conclusions
In this research we have presented a novel hybrid XGBoost-SDA prediction model for the flank wear of a drilling process. The strengths of XGBoost combined with the fast and accurate SDA showed superior performance in terms of the accurate prediction of flank wear for copper and cast-iron datasets. Simulations showed that XGBoost-SDA outperformed the state-of-the-art SVM and MLP-ANN models in terms of MAE, RMSE and the coefficient of determination R 2 . These characteristics are important for estimating flank wear with a given set of machine parameters and experimental trials. The predicted flank wear values were matched with the measured values in order to demonstrate the efficiency of the XGBoost-SDA. The predicted outcomes were found to be in close agreement with the experimental values. In the drilling of the copper workpiece, the MAE between experimental and predicted surface roughness values was 4.67%, while for the cast iron workpiece the MAE was 5.25%. A comparison of prediction accuracy between SVM, MLP-ANN, and the proposed XGBoots-SDA was carried out; it showed that the XGBoost-SDA resulted in greater accuracy in terms of the performance values in the drilling processes.