## 3 Signal Processing While Drilling  
### Data Preprocessing  
To predict the strength of coal and rock masses based on drilling signals, it is essential to preprocess the collected raw data to extract information that effectively reflects the strength characteristics of these materials. The host device is connected to the computer using the provided USB cable, and the data are imported into the analysis software for viewing and analysis. The results of raw data collection from various drilling signals are illustrated in Figure 2.  
The process of utilizing a drilling rig to create holes for anchor rod and cable support in underground coal mines can be categorized as the \"rod installation, rising, drilling, lowering, and rod installation\" stage, with the drilling process occurring cyclically. Based on six types of logging while drilling (LWD) signal data--namely, rotating speed, pressure, torque, vibration, dip angle, and speed--collected during field drilling, the characteristics of certain torque signals gathered in the time domain are illustrated in Figure 3. In practice, the operational process can be divided into three sections: the shutdown section, the preparation section, and the drilling section. The shutdown period refers to the cessation of drilling rig operations for rod installation and unloading. The preparation stage occurs when the drilling rig ascends to the rock surface and then descends to the bottom. The drilling section pertains to the rock-breaking process, during which the drilling rig makes contact with the rock surface through rotation and pressurization. A crucial step in establishing an intelligent prediction model for the strength of surrounding rock is analyzing the interaction data between coal and rock generated during the contact process between the drilling rig and the coal rock. Consequently, this article first eliminates data from the shutdown and preparation stages of the original dataset, retaining only the data from the drilling section. \begin{table}
\begin{tabular}{c c} \hline \hline
**Lithology** & **Average Uniaxial Compressive Strength/MPa** \\ \hline Coal & 9.7 \\ Silstone & 22.1 \\ Medium-grained sandstone & 38.6 \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Rock uniaxial compressive strength. Figure 3: Raw data of drilling signals. Figure 2: Raw data of drilling signals. (**a**) Rotational speed signal; (**b**) pressure signal. (**c**) torque signal; (**d**) vibration signal; (**e**) inclination angle signal; (**f**) speed signal. To delete the preparation and shutdown section data within the excavation section, this article selects the drilling section data based on on-site drilling protocols for subsequent data processing and database establishment. Additionally, the drilling rig is subjected to harsh working environments and equipment failures during the drilling process, which can result in the collection of abnormal data. These anomalies do not represent true values and may interfere with and reduce the accuracy of models during subsequent training. Therefore, it is essential to remove these abnormal data points. A statistical analysis method is employed to identify these outliers. In engineering applications, the Pauta criterion is frequently utilized to distinguish abnormal data values. For a set of collected data points (X\({}_{1}\), X\({}_{2}\),..., X\({}_{n}\)), abnormal values are eliminated using the Pauta criterion as follows:  
Calculate the arithmetic mean for the data of each drilling section first. \[\overline{X}=\frac{1}{n}\sum_{i=1}^{n}x_{i} \tag{1}\]  
Then calculate the residual error \(v_{i}=X_{i}-\overline{X}\), and calculate the root mean square deviation using the Bessel method again:  
\[\sigma=\sqrt{\frac{\sum v_{i}^{2}}{n-1}} \tag{2}\]  
The criteria for discrimination are as follows: it is assumed that the measurement column follows a normal distribution. \(\left|X_{i}-\overline{X}\right|>3\sigma\), \(X_{i}\) represents a gross error and should be discarded.