Academic Journal of Science and Technology ISSN: 2771-3032 | Vol. 14, No. 3, 2025 155 Prediction of TBM Roadway Surrounding Rock Grade Based on XGBoost Model Zhang Hu1, *, Zhanbiao Yang2 1Henan Polytechnic University, Jiaozuo 454000, China 2PingDingShan TianAn Coal Co.Ltd, Pingdingshan 467000, China * Corresponding author Abstract: The classification of roadway surrounding rock is a very important link in the process of TBM construction. Its main purpose is to determine the drilling parameters such as bit type and cutterhead speed used in the process of shield tunneling according to different surrounding rock characteristics, so as to ensure the safety and efficiency of construction. With the development of machine learning and artificial intelligence technology, these technologies are gradually applied to the classification of tunnel surrounding rock. This method can establish a model through a large number of data analysis, so as to quickly and accurately classify and predict different types of surrounding rock. Based on Shoushan No.1 Mine, the XGBoost model was used to classify the surrounding rock types of the selected sample tunnel sections, and the tunneling parameters affecting the classification of shield surrounding rock were analyzed. The classification model of shield tunnel surrounding rock was established and the model was preliminarily tested. The results show that thrust, rotational speed, torque and propulsion speed are the main factors affecting the grade of surrounding rock. The XGBoost model is used to identify the surrounding rock grade in real time. The samples of grade III and grade V surrounding rock are all predicted, with an accuracy rate of 100 %. The accuracy rate of grade II and grade IV surrounding rock is 90 %, and the total accuracy rate reaches 95 %. The prediction effect is good. Keywords: Excavation parameters, XGBoost model. 1. Introduction TBM-Tunnel boring machine is a large-scale comprehensive tunneling equipment. It is widely used in the construction of subsea tunnels, traffic tunnels, coal mine roadways and other projects because of its functions of tunneling [1], rock breaking, slag discharge and support, as well as its advantages of high efficiency and continuous operation, less pollution, high safety and low cost. However, due to the complex surrounding rock conditions and numerous parameter control, the coordination and interaction between ' man-machine-rock ' is a complex problem. The tunneling of TBM relies on the driver 's usual experience to control the equipment and adjust the parameters, and the equipment and the surrounding rock are interactingbelow, which may lead to the low matching degree between the machine parameter combination and the geological conditionsbelow [2], so that TBM faces problems such as jamming and tool damage, and even disasters such as surrounding rock collapse and rockburst. Therefore, in order to ensure the TBM tunneling efficiency in deep roadway engineering and reduce the possibility of construction accidents, it is necessary to establish a TBM real-time surrounding rock grade prediction model to ensure the TBM tunneling efficiency in deep roadway engineering and reduce the possibility of construction accidentsbelow [3]. Gholami et al. [4] used the index parameters of the RMR system to compare the accuracy of the RMR system with the two algorithms of relevance vector regression and support vector regression, and finally showed that the artificial intelligence algorithm had a relatively good performance. Jian et al. [5] used the Q system evaluation index parameters, and used the artificial neural network to qualitatively evaluate the rock mass quality. Sanio [6] has an in-depth observation on the failure phenomenon of TBM disc cutter in his research. He pointed out that the principal stress of rock is greater than the shear stress in the process of breaking rock, which leads to the cracking and ductile fracture of rock under stress, rather than simple shear fracture, and deduced the formula of rock breaking performance of disc cutter in different rocks to support more accurate parameter selection. Rosutami [7] proposed a simple model for evaluating the drilling capacity of rock and the performance range of TBM, which associates the machine performance with two main rock properties ( compressive strength UCS and rock mass grade RQD ) and two operating parameters ( average thrust and rotational speed of the cutting head ). This model can be used to quickly predict the performance of TBMs with different diameters under different geological conditions. Based on this, on the basis of a large number of data mining and preprocessing on the rock mass parameters and tunneling parameters of TBM tunneling roadway in Shoushan No.1 Coal Mine, the machine learning algorithm is used to establish the data model. Through the calculation of TBM tunneling speed prediction model and TBM utilization rate prediction model, the classification standard of surrounding rock of TBM coal mine roadway is obtained. Because the rock mass parameters are difficult to obtain in the actual TBM tunneling process, the geological conditions in front are difficult to detect. The tunneling parameters transmitted by the TBM cutterhead drive system are used to realize the perception of rock mass parameters, so that various parameters are integrated to perceive and identify the surrounding rock grade. A real-time prediction model of TBM surrounding rock based on XGBoost model is proposed, and compared with the single LSTM model to highlight the prediction effect of the optimization model. 156 2. Distribution Characteristics 2.1. Box line diagram principle As shown in Figure 1, the box plot is composed of a set of lower bounds, lower quantiles Q1 [8], medians Q2, upper quantiles Q3, upper bounds and outliers in the data, which can reflect the concentration trend, dispersion degree and distribution shape of a set of data. On the box plot, the median Q2 reflects the center position of the data distribution, the quartile spacing box reflects the concentrated interval of the data, and the lower and upper bounds reflect the distribution range of the data. From the box plot, we can roughly see whether the data is symmetrical. By drawing the box line diagram of a set of data in the same coordinate, the distribution characteristics and mutual differences of each group of data can be clearly displayed, which provides clues for finding problems and screening indicators. Figure 1. Google Scholar Box line diagram 2.2. Machine parameter distribution As shown in Figures 2 and 3, the distribution of the two parameters of thrust and torque is ideal, and the degree of discrimination in each grade of surrounding rock is very good, which is suitable for the classification of surrounding rock. The thrust is the highest in grade II surrounding rock, ranging from 14000 to 20000 kN, in grade III surrounding rock, the thrust is 10000-16000 kN, in grade IV surrounding rock, the thrust is 7000-12000 kN, and the thrust is the lowest in grade V surrounding rock, ranging from 2500 to 8000 kN. The torque is the highest in grade II surrounding rock, ranging from 2500-800kN · m, the torque is 1500-3000k · m in grade III surrounding rock, the thrust is 1000-2400kN in grade IV surrounding rock, and the torque is the lowest in grade V surrounding rock, ranging from 600-1300kn. Figure 2. The average thrust distribution of TBM Figure 3.TBM cutterhead torque distribution diagram From the distribution of the average rotational speed of TBM under different surrounding rock grades in Fig.4, it can be seen that the rotational speed is the highest in grade II surrounding rock, ranging from 6 to 7.5 rpm, and the rotational speed is the lowest in grade V surrounding rock, ranging from 1 to 5 rpm. This parameter is better for the distribution of surrounding rock areas of grade II, grade III and grade V, and the discrimination of surrounding rock areas of grade III and grade IV is slightly worse. On the whole, these three indicators can be used as the basis for judging the grade of surrounding rock in the prediction model. The cutterhead power refers to the power required to drive the TBM cutterhead to rotate. The cutterhead power depends on the cutterhead diameter, geological conditions, tunneling speed, torque and other factors. Figure 4.TBM cutterhead speed distribution map As shown in figure 5, the cutterhead power is the highest in grade II surrounding rock, ranging from 1200 kW to 1900 kW, and the cutterhead power is the lowest in grade V surrounding rock, ranging from 100 kW to 1600 kW. However, the cutterhead power parameters have a high coincidence degree in the four types of surrounding rock, which can not distinguish the surrounding rock grade well. 157 Figure 5. TBM cutterhead Power distribution 2.3. Distribution of tunneling performance parameters As shown in figure 6, observing the distribution of advancing speed, we can find that the net tunneling speed is the lowest in grade V surrounding rock, ranging from 18 to 42mm / min, and the net tunneling speed is the highest in grade III surrounding rock, ranging from 45 to 82mm / min. From the box diagram, it can be seen that the net speed parameters can be well distinguished for the latter three levels of surrounding rock, and there are only more overlaps in the II and IV levels of surrounding rock. Figure 6. The distribution map of TBM propulsion speed Penetration represents the depth that TBM cutter can cut into the tunnel face by rotating a circle. In general, the penetration of high-grade surrounding rock is small, and the penetration of low-grade surrounding rock is large. The penetration distribution under different surrounding rocks is shown in Fig.7.The average penetration of surrounding rock II is significantly lower than that of surrounding rock III and IV, because the strength of surrounding rock II is too high, the site can only take low penetration, high speed excavation method caused. Due to the weak rock quality, the penetration degree of grade V surrounding rock can be slightly larger during normal excavation. If the penetration degree is too large, it is easy to cause collapse accidents, so the penetration degree of grade V surrounding rock has the largest range of variation. The surrounding rock of grade III and IV is hard, the stability of surrounding rock is good, and it can withstand large engineering disturbance, so the penetration is the highest. From the box line diagram, it can be seen that the penetration degree has a high coincidence degree in the distribution of grade III, grade IV and grade V surrounding rock, and it is difficult to effectively distinguish the grade of surrounding rock. Figure 7. The distribution map of TBM propulsion speed In summary, we find that the average thrust, average speed and average torque of the machine parameters do not coincide with the distribution boundary under different surrounding rocks, which can be used as the basis for judging the grade of surrounding rock. For the average propulsion speed, it can effectively distinguish grade III, grade IV and grade V surrounding rock. For the average penetration and average cutterhead power, they have a high degree of coincidence in the four types of surrounding rock, and cannot provide effective information to distinguish the grade of surrounding rock. Moreover, due to the interference of human factors, they cannot directly reflect the rock mechanism system, so they are not suitable as the basis for judging the grade of surrounding rock. 3. Prediction Method of Surrounding Rock Grade 3.1. Introduction of XGBoost algorithm XGBoost is a high-performance machine learning algorithm based on gradient boosting framework. Compared with the traditional GBDT algorithm, XGBoost optimizes the objective function value by adding regularization term and introducing approximate greedy algorithm, thus improving the operation speed and efficiency [9] As an ensemble tree model, the XGBoost model contains multiple CART trees, each of which is a regression tree or classification tree. XGBoost uses a method similar to ensemble learning to add the prediction results of multiple CART trees to obtain the final model prediction value. The core advantages of XGBoost are : achieving the balance between speed and accuracy of efficient calculation through engineering optimization ; regularization and randomization strategies achieve strict generalization control ; the whole process from missing value processing to feature importance analysis supports end-to-end solutions. 3.2. XGBoost model construction The flow chart of the surrounding rock category prediction 158 model based on the XGBoost algorithm model is shown in Figure 8 : ( 1 ) Data preprocessing : Load the surrounding rock data from the database, preprocess the data of the extracted excavation cycle section, eliminate the data of the shutdown section, and extract the data of the working section. According to Section 5.1, the features related to the surrounding rock category are selected, and the numerical features are normalized. Then the category features are converted into numerical formats, that is, the surrounding rocks of grade II, grade III, grade IV and grade V are converted into 0, 1, 2 and 3. The 200 groups of data are divided into training set and test set, 160 groups of training set and 40 groups of test set. ( 2 ) XGBoost algorithm parameter initialization : When using XGBoost for four-classification tasks, the objective parameter is set to multi : softmax, specify the number of categories num _ class = 4, the maximum depth max _ depth of the tree is set to 6, the learning rate eta is set to 0.1, and the random seed seed is set to 42. ( 3 ) Training model : Set the number of iterations num _ round = 100, and use the xgb.train ( ) function to train the model. ( 4 ) Model evaluation : The test set is used to evaluate the performance of the model. The accuracy of the model prediction results is determined by the values of Accuracy, Precision, Recall.TPR and FPR. The model evaluation index can evaluate the accuracy of different algorithm models, and can also evaluate the accuracy of four types of surrounding rock prediction. ( 5 ) XGBoost model application : Use joblib to save the trained model for subsequent use, use the loaded _ model to load the model for prediction, and can also use the trained model to predict new data. input data set setting model parameters training model model prediction data pre-processing Historical data preservation model model evaluation End Figure 8. XGBoost algorithm flow chart 3.3. Model-evaluation index Accuracy, Precision, Recall, TPR and FPR were selected as the evaluation indexes of the model. True positive rate ( TPR ) represents sensitivity, and high sensitivity means high accuracy. False positive rate ( FPR ) indicates specificity, and low specificity leads to low misjudgment rate.               (1)   In the formula, TN indicates that the prediction is false, and the measured value is also false ; fP represents the value that the prediction is true and the measured is false ; fN indicates that the prediction is false and the measured value is true ; tP indicates that the prediction is true, and the measured value is also true. The statistical parameter is the proportion of all predicted correct numbers to the total number. (2) In the formula, TN indicates that the prediction is false, and the measured value is also false ; fP represents the value that the prediction is true and the measured is false ; fN indicates that the prediction is false and the measured value is true ; tP indicates that the prediction is true, and the measured value is also true. The statistical parameter is the proportion of all predicted correct numbers to the total number. (3) The parameters in the formula are defined as above, and the statistical parameters represent the proportion of the number of correctly predicted positives to the total number of actually positives. (4) The parameters in the formula are defined as above, and the statistical parameters represent the proportion of the number of correctly predicted positives to the total number of actually positives. (5) The parameter in the formula is defined as above, and the statistical parameter represents the proportion of the number of errors predicted as negative to the total number of actual negatives. 3.4. Model input variable screening From the statistical analysis results of Section 2.1, it can be seen that the three parameters of F, N and T have good discrimination, the discrimination of V is slightly poor, and P and CP basically do not have the ability to distinguish the surrounding rock grade. Considering that only F, N, T, V and TP TN Accuracy TP FP TN FN      TP Precision TP FP   TP Recall TP FN   TP TPR TP FN   TP FPR TN FP   159 P can be obtained directly from the main control room in real time at the construction site, in order to facilitate the field application of the real-time identification model of surrounding rock grade, these parameters should be selected as input variables as far as possible. Firstly, F, N, T and V are selected as the input variables of the multiple linear regression model, and the surrounding rock grade is taken as the output variable. The visual confusion matrix of the model is shown in Figure 9. Figure 9. Confusion matrix based on F, N, T, V The prediction accuracy of the samples is shown in Table 1. The V-level surrounding rocks are all identified. Because V and N have some of the same intervals in the II-level, III-level, and IV-level surrounding rocks, there are individual sample identification errors, and the total accuracy rate is as high as 96.25 %. It shows that the selected feature space is good, and the model training effect is good, which can be used for the prediction of the test set. Table 1. Prediction effect table based on F, N, T, V Grade Number True False Accuracy II 40 38 2 95% III 40 38 2 95% IV 40 38 2 95% V 40 40 0 100% The five parameters of F, N, T, V and P are selected as the feature space. The visual confusion matrix of the model is shown in Figure 10. The prediction accuracy of the samples is shown in Table 2. It can be seen that the recognition accuracy of grade II surrounding rock is the highest, which is 90 %. The recognition accuracy of surrounding rock of grade III is the lowest, which is 82.5 %. After adding P to the characteristic parameters, the total accuracy rate decreased to 85.63 %, which decreased by 9.62 %. Because P has a high degree of coincidence in the distribution of grade II, grade III, grade IV and grade V surrounding rock, it is difficult to effectively distinguish the grade of surrounding rock, so the prediction effect of the model decreases. Figure 10. Confusion matrix based on F,N, T, V,P Table 2. Prediction effect table based on F, N, T, P Grade Number True False Accuracy II 40 36 4 90% III 40 33 7 82.5% IV 40 34 6 85% V 40 34 6 185% Five parameters of F, N, T, V and CP are selected as the feature space. The visual confusion matrix of the model is shown in figure 11, and the prediction accuracy of the sample is shown in table 3. It can be seen that the recognition accuracy of grade II surrounding rock is the highest, which is 82.5 %. The recognition accuracy of surrounding rock of grade III is the lowest, which is 70 %. After adding CP, the total accuracy of feature parameters decreased to 77.5 %, a decrease of 18.75 %. It can be seen from the figure that the model cannot well identify grade II and III surrounding rocks, as well as grade IV and V surrounding rocks. This is because the newly added characteristic parameter CP has the same interval in these four surrounding rocks, and the model is difficult to identify. Figure 11. Confusion matrix based on F,N, T, V,CP 160 Table 3. Prediction effect table based on F, N, T, CP Grade Number True False Accuracy II 40 36 4 90% III 40 33 7 82.5% IV 40 34 6 85% V 40 34 6 185% In summary, through comparison, it can be seen that the model learning effect of selecting F, N, T, and V as the feature space is better, and it can better identify the surrounding rock of each grade. 4. Prediction of Surrounding Rock Grade in Shoushan No.1 Mine 4.1. The prediction effect of XGBoost model A total of 200 sets of representative data of Shoushan No.1 Mine were selected, including 50 sets of surrounding rocks of grade II, grade III, grade IV and grade V respectively. Each data statistics and calculation of the six indicators, including the cutterhead speed ( N ), driving speed ( V ), cutterhead thrust ( F ), cutterhead torque ( T ), penetration ( P ) and cutterhead power ( CP ). Among them, 160 sets of data were randomly selected as training samples [10], 40 sets as test samples, and 10 sets of tunneling data were randomly selected as test samples for each surrounding rock grade. The confusion matrix obtained by using the XGBoost model for the test samples is shown in Figure 12. From the prediction results of the test samples, the XGBoost model has high prediction accuracy, and the total accuracy rate reaches 95 %. Therefore, in the actual construction, as long as the F, N, T and V data displayed in the main control room in real time during the TBM tunneling process are input into the model, the recognition results of the surrounding rock grade of the tunneling face can be automatically obtained in real time, so as to guide the construction of TBM. Figure 12. XGBoost model confusion matrix 4.2. Comparison of prediction effects of different models 4.2.1. K-nearest neighbor model The K-Nearest Neighbors ( KNN ) model is an instance- based learning algorithm commonly used for classification tasks. Its basic idea is to find the nearest K training samples by calculating the distance between the test sample and other samples in the training set, and predict the results of the test sample according to the category or attribute of these neighbors. Specifically, KNN will calculate the distance between the test sample and all training samples ( such as Euclidean distance ), and then select the nearest K training samples. The prediction results are usually the most frequent categories in these K samples [11]. The advantage of the K- nearest neighbor model is simple and intuitive, and does not require a complex training process, but its computational complexity is high, especially on large data sets. The confusion matrix obtained by using the K-nearest neighbor model for the test samples is shown in Figure 13. Figure 13. K-nearest neighbor model confusion moment 4.2.2. Support vector machine model ( SVM ) Support Vector Machine ( SVM ) is a supervised learning algorithm, which is often used in classification tasks. Its core idea is to find a hyperplane, divide the data points into two categories, and make the hyperplane as far away from the data points as possible, so as to improve the generalization ability. Specifically, SVM selects the optimal hyperplane by maximizing margins, where margin is the distance from the nearest data point on both sides of the hyperplane to the hyperplane. For linearly separable data, SVM directly finds a hyperplane ; for nonlinear data, SVM maps data to high- dimensional space through Kernel Trick, so that a linear hyperplane can be found in high-dimensional spacebelow. The advantages of SVM include : efficient processing of small data sets ; it performs well in high-dimensional space ; it has good robustness to noise and outliers ; has a clear geometric explanation. The predicted results are shown in Figure 14. Figure 14. SVM model confusion matrix 161 4.2.3. Random forest model (RF) The Random Forest model is an ensemble learning algorithm based on decision tree for classification and regression tasks. Its core idea is to improve the accuracy and stability of the model by constructing multiple decision trees and combining their prediction results. Specifically, the random forest works through the following steps : Random sampling : Randomly extract multiple subsets from the training set. Constructing a decision tree : For each subset, a decision tree is constructed using a random subset of features. Voting : For the classification task, the random forest determines the final category by voting. The advantages of random forests include : high accuracy : by integrating multiple decision trees, random forests usually perform better than single decision trees. High stability : Strong robustness to noise and outliers. The prediction results are shown in Figure 15. Figure 15. Confusion matrix of RF model 4.2.4. Comparison of Model Prediction Results In Figure 16, the prediction results of four different models, XGBoost, K-nearest neighbor, SVM and RF, are compared. It can be found that compared with other grades of surrounding rock, the average accuracy of the four models for the prediction of grade IV surrounding rock is low, and the prediction accuracy of grade III surrounding rock is the highest. The XGBoost model has the best prediction effect in V-grade surrounding rock, which is much higher than other models. Among the prediction effects of II-class surrounding rock, XGBoost, SVM and RF have the best prediction effect, and the accuracy rate is 90 %. XGBoost and RF have the best prediction effect in grade III and IV surrounding rock, and all grade III surrounding rock samples are identified. SVM has the worst prediction effect in grade IV surrounding rock, which is 70 %. In the prediction effect of V-class surrounding rock, XGBoost has the best prediction effect, and K-nearest neighbor and RF have the worst prediction effect. In Figure 17, the evaluation indexes of the four models are compared. The accuracy, recall rate and true positive rate of the XGBoost model are higher than those of other models. Considering the respective evaluation indexes of surrounding rock grade identification at all levels, the XGBoost model is the best choice. Figure 16. Model prediction results Figure 17. Model evaluation index comparison 5. Conclusion In this paper, by analyzing the construction site data and inputting it and the tunneling parameter statistics as features into the machine learning model to realize the real-time prediction of TBM surrounding rock grade, the main conclusions are as follows. (1) The relationship between TBM parameters and surrounding rock grades is studied. The distribution of six parameters of TBM tunneling parameters such as thrust, torque, speed, power, and performance parameters such as tunneling speed and penetration under surrounding rock at all levels is analyzed by box diagram. The results show that thrust, speed, torque and tunneling speed have good discrimination in different grades of surrounding rock. (2) The principle of XGBoost algorithm is introduced, and the XGBoost algorithm model is established. Some evaluation indexes are used to evaluate the accuracy of the model prediction results. The accuracy rate, precision rate, recall rate, true positive rate and false positive rate can be used as the evaluation indexes of the model to compare the prediction effects of different models. Through the effect of the training set, the feature space of the model is selected, that is, F, N, T, V. References [1] Li Hongbo, Zhang Dongyue, Ge Xueyuan. Tunnel boring machine tunneling parameters prediction method based on PSO-LSSVM algorithm [J]. Science Technology and Engineering, 2023, 23( 14) : 6230-6237. [2] LIU Ruilin, MAN Ke, LIU Xiaoli, et al. Prediction of ground conditioning effect of water-rich sandy stratum based on genetic algorithm-back propagation neural network[J]. Tunnel Construction, 2023, 43(S1): 222. [3] LI Taibin, ZHANG Chong, YAN tiancheng, et al. Intelligent EarlyWarning System for Uneven Blade Opening Fault of 162 Hydraulic Turbines based on Big Data. [J]. Technology Innovation and Application, 2020, (11): 120-121. [4] Gholami R. Improved RMR Rock Mass Classification Using Artificial Intelligence Algorithms[J]. Rock Mechanics & Rock Engineering, 2013, 46 (5): 1199-1209. [5] Jian XU, Wang J, Yan MA. Rock Mass Quality Assessment Based on Bp Artificial Neural Network (ANN)——a Case Study of Borehole Bs03 inJiujing Segment of Beishan, Gansu[J]. Uranium Geology, 2007, 23 (4): 249-455. [6] Sanio H P. Prediction of the performance of disc cutters in aniso tropic rock[J]. International Journal of Rock Mechanics and Mining Sciences & Geomechanics Abstracts, 1985, 22(3): 153-161. [7] Rosutami J. A new model for performance prediction of hard rock TBMs[C]//Proceedings/1993 rapid excavation and tunneling conference. 1993. [8] Yang Yaohong, Han Xingzhong, Zhang Zhixiao, et al. The interval prediction of tunnel boring machine penetration rate under condition of mixed face ground and small diameter[J]. Science Technology and Engineering, 2023, 23(34): 14638- 14650. [9] WANG Jian, WANG Ruirui, ZHANG Xinxin, et al. Estimation of TBM Performance Parameters Based on Rock Mass Rating (RMR) System[J].Tunnel Construction, 2017, 37(6): 59–66. [10] Hassanpour J, Rostami J, Zhao J. A new hard rock TBM performance prediction model for project planning[J]. Tunnelling and Underground Space Technology, 2011, 26(5): 595-603. [11] MAN Ke, CAO Zixiang, LIU Xiaoli, et al. The prediction of TBM tunnel boring parameters based on GRU-RF model[J].Jouranal of Basic Science and Engineering, 2023, 31(06):1519-1539.