Mine gas emission quantity prediction method based on deep learning
Through the VMD-WTC-PatchTST combined model based on deep learning, the problems of nonlinear and multidimensional data processing in mine gas emission prediction are solved, the prediction accuracy and stability are improved, and it is suitable for the accurate prediction of mine gas emission.
Patent Information
- Application Number
- CN202510943529.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-08
- Publication Date
- 2025-10-28
AI Technical Summary
Existing methods for predicting mine gas outbursts cannot effectively handle nonlinear characteristics and large-scale multidimensional data. Shallow learning models are highly complex and require specialized knowledge, resulting in poor prediction performance.
A VMD-WTC-PatchTST combination model based on deep learning is adopted. VMD is used to decompose the data, and PatchTST and WTC are combined for feature extraction and prediction. The Pearson correlation coefficient and the maximum mutual information number are used to determine the main control elements, and a Transformer encoder is constructed for self-attention mechanism prediction.
The prediction performance is improved, the fit is increased by 2.6%, and the RMSE and MAE are reduced. It can better capture the linear and nonlinear relationship of gas emission, reduce the influence of irrelevant features, and provide a solid data foundation.
Smart Images

Figure CN120852083A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the technical field of mine gas emission prediction, and in particular to a deep learning-based method for predicting mine gas emission. Background Technology
[0002] Mine gas emission prediction is a crucial technology for safe mine production. Currently, common gas emission prediction methods fall into five categories: traditional prediction methods, mathematical model prediction methods based on gas geological formulas, grey systems, machine learning prediction methods, and combined model methods. Traditional prediction methods are included in industry standards, using gas geological formulas to calculate gas emission. Mathematical model prediction methods are improvements on traditional methods, still based on gas geological formulas to build corresponding mathematical models, such as the patent with authorization announcement number CN113723026B, which describes a method for estimating gas emission from coal seams ahead of tunnel faces. Both traditional and mathematical model prediction methods have the drawback of failing to consider nonlinear characteristics or undiscovered patterns. Grey systems address this shortcoming by no longer relying on specific gas geological formulas, but they cannot handle large-scale data and multidimensional problems, and the performance of the established mathematical models is affected by the sensitivity of assumptions. Based on this, machine learning prediction methods are further improved by using learning models to handle multivariate data. Learning models include shallow learning models and deep learning models. Combinatorial models are prediction methods based on mathematical models, supplemented by grey systems, machine learning, or a combination of both. Existing combinatorial models mostly utilize shallow learning models, such as the gas emission prediction method based on the WT-KPCA-SVR coupled model in patent CN104794550B. In this method, the model is a numerical model, grey relational analysis is a grey system, and support vector machine regression (SVR) is a shallow learning model within machine learning prediction methods. However, shallow learning models are relatively simple and cannot handle predictions with large datasets and complex tasks. Furthermore, they require users to have advanced professional knowledge to assist in feature extraction. Therefore, combinatorial models based on deep learning models have become a popular direction for predicting mine gas emission. Summary of the Invention
[0003] The purpose of this invention is to solve the above-mentioned problems and provide a method for predicting mine gas outburst based on deep learning.
[0004] The technical solution of this invention is: a method for predicting mine gas emission based on deep learning, comprising the following steps:
[0005] ① Dataset preparation
[0006] The existing daily data of the mine is statistically analyzed and compiled into a dataset. The daily data includes the mine's daily reports, production tables, progress schedules, and workers' daily records. The dataset records the data of various related elements in terms of time.
[0007] ② Perform correlation analysis on the dataset to determine the main controlling elements of mine gas emission.
[0008] To determine the form of the main controlling elements of mine gas emission, filter out those elements that have little impact on mine gas emission, reduce the amount of subsequent data processing, and improve the prediction speed;
[0009] ③ Construct a VMD-WTC-PatchTST combined model based on the time series data of the main controlling elements of mine gas emission.
[0010] VMD, short for Variational Mode Decomposition, is a noise reduction method in which the number of modal components can be manually set.
[0011] PatchTST, short for Patch Time Series Transformer, is a time series prediction model based on Transformer.
[0012] WTC stands for Wavelet Transform Convolution.
[0013] Combining WTC with PatchTST can improve detail recognition capabilities and accurately capture low-frequency and high-frequency information;
[0014] 3.1 Preprocessing the time series data of the main control elements of mine gas emission
[0015] The purpose of preprocessing is to make the time-series data of the master elements more suitable for model training, improve the model's performance, speed and stability, and at the same time deal with various problems in the data to ensure that the model can learn effective patterns.
[0016] 3.1.1 Check for missing values in the time series data of the main control elements of mine gas emission; missing value checking is a necessary step in data preprocessing. Missing data may cause the model to make incorrect estimates of the data distribution, resulting in model bias, reduced model generalization ability, and inability to adapt to new data.
[0017] 3.1.2 Improving the data after checking for missing values based on VMD method 3.1.3 Extract time features from the time series data of the improved master control element; The time series data of the improved master control element is time series data, which usually has time dependence, such as seasonality, periodicity, trend, etc. Extracting time features can transmit these periodic patterns to the model, enabling the model to better understand the data and more easily capture the patterns, thereby improving the model's generalization ability.
[0018] 3.1.4 Divide the time-series data of the improved master control element into datasets.
[0019] The time series data corresponding to the improved master control element is divided into training set and test set;
[0020] 3.1.5 Perform data normalization on the timing data of the improved master control element.
[0021] Since different elements have different numerical ranges, directly inputting them into the model will reduce the model's performance. Therefore, data normalization is needed to adjust the numerical range to a uniform scale, thereby improving the model's performance and stability.
[0022] 3.2 Establishment of the Preliminary VMD-WTC-PatchTST Combined Model
[0023] Select the existing PathTST model with proven predictive performance; smoothly stitch WTC with the PathTST model; Haar wavelet transform: decompose the original gas time series data using high-pass and low-pass filters to generate low-frequency (LL) and high-frequency (H) subbands; for a sequence of length L, X = [x0, x1, ..., x...], ... L-1 The formulas for the approximation coefficients (low frequencies) and detail coefficients (high frequencies) formed by high-pass and low-pass filters are as follows:
[0024]
[0025] In the formula, a i d is the approximation coefficient; i These are the detail coefficients, i = 0, 1, ... (L-1) / 2;
[0026] Next, depthwise separable convolutions are applied independently to each sub-band, while parameters are shared to reduce computational cost. Finally, the results of each sub-band are merged through IWT to retain cross-scale features. IWT, short for Inverse Wavelet Transform, is a method that extracts different frequency components of the time series through wavelet transform and combines convolution operations to extract key features, thereby enhancing the model's ability to capture short-term fluctuations and long-term trends.
[0027] The PathTST model is divided into two parts: channel independence and Transformer backbone. The channel independence approach can effectively capture the characteristics of each signal, which helps to better reflect the detailed changes in each channel when processing multi-dimensional time series data.
[0028] Time series data is divided into multiple small blocks or patches, allowing PatchTST to capture local temporal features in the data. This enables the model to more accurately capture short-term temporal dependencies, avoiding overly smoothing or neglecting local information that may occur in traditional global modeling. The input time series is padded into multiple small blocks, which are then sent to the encoder of the Transformer backbone to compute the self-attention among these blocks. For the input sequence x... (i) ∈R L In other words, its block division formula is as follows:
[0029]
[0030] In the formula, N is the number of blocks, which is an integer; P is the length of the block; and S is the step size.
[0031] Next, through the learnable mapping matrix W P ∈R D×N Each block is mapped to an embedding space of dimension D, and the resulting projection is added to the position encoding matrix W. pos ∈R D×N It is the time sequence of the coded blocks, and the formula is as follows:
[0032]
[0033] Where, This is the projection result of the i-th block; For the i-th block; W P W is a learnable mapping matrix; pos This is the position encoding matrix;
[0034] After entering the Transformer encoder, in the multi-head self-attention mechanism, each head h = (1, 2, ..., H) projects its results through three different weight matrices. Multiply to calculate Query(query vector, Key (key vector) ) and Value (value vector, Next, the dot product between the Query and the Key is calculated to obtain the attention score. Then, the Softmax function is applied to the attention score to obtain the attention weight. Finally, the attention weights are used to perform a weighted summation of the Values to obtain the final output. The formula is as follows:
[0035]
[0036] In the formula, d k The dimension of the key is used for normalization to prevent the dot product value from becoming too large;
[0037] The output is flattened after passing through a feedforward neural network and residual connections to obtain the final prediction result.
[0038] 3.3 Hyperparameter Settings
[0039] Model hyperparameters are set manually at the start of training. They typically control the model structure and training, and are categorized into training parameters and structural parameters. Training parameters control the training process and directly affect the optimization process and learning behavior, while structural parameters determine the model's architecture and performance. Their settings must consider task requirements, model complexity, and other factors.
[0040] 3.4 Obtaining the final VMD-WTC-PatchTST combined model
[0041] The VMD-WTC-PatchTST combined model output is calculated using forward propagation on the training set, and gradients are calculated and updated via backpropagation. The entire training process is continuously optimized to minimize the loss function until a predetermined convergence criterion is reached, allowing the VMD-WTC-PatchTST combined model to learn the inherent patterns and features of the normalized training set, forming the final VMD-WTC-PatchTST combined model. The test set serves as a new dataset for the model, accurately reflecting its performance in real-world applications. Test set data is imported into the final VMD-WTC-PatchTST combined model, using the earlier test set data to predict the later test set data. The predicted data and the actual data on the test set are then denormalized. Finally, the denormalized predicted data is compared with the actual data to evaluate the predictive performance of the final VMD-WTC-PatchTST combined model.
[0042] ④ Use the final VMD-WTC-PatchTST combined model for prediction.
[0043] The time series data of the newly statistically analyzed master control elements are input into the final VMD-WTC-PatchTST combined model for prediction in a form that meets the requirements of the model hyperparameters.
[0044] Preferably, in step ②, the Pearson correlation coefficient (PCC) and the maximum mutual information number (MIC) are used to perform correlation analysis on the dataset to determine the main controlling characteristics of mine gas emission as temperature, burial depth, original gas content of the mining layer, tunneling footage, coal seam dip angle, and working face length. The Pearson correlation coefficient (PCC) is a commonly used indicator to measure the linear correlation between two variables, but it cannot capture nonlinear relationships. The maximum mutual information number (MIC), on the other hand, can identify and quantify various forms of relationships, including nonlinear and periodic relationships. Combining the two allows for a comprehensive consideration of both linear and nonlinear relationships in the dataset.
[0045] Furthermore, in step 3.1.2, the data after checking for missing values is decomposed layer by layer into K modal components u. k (t), where K is the number of modes, and each u k (t) is the IMF; IMF stands for Intrinsic Mode Function; as a component of the signal, the IMF has a finite bandwidth, and its spectrum can be concentrated within a certain frequency band; VMD can make the sum of each mode close to f(t), while requiring the sum of the bandwidths near the center frequency of each mode to be minimized; the mode bandwidth is minimized through variational optimization methods; the bandwidth of each IMF is as independent and as small as possible, thus effectively decomposing the original signal; K=3; VMD can achieve the best noise reduction effect.
[0046] Preferably, in step 3.1.3, timeenc is used to encode the time features into the range of [-0.5, 0.5], and the freq parameter is D, which represents extracting time features at a daily frequency. This helps to capture the complete periodic changes in gas outflow. In addition to the daily time frequency, there are also weekly, weekday, and other time frequency extraction methods.
[0047] Preferably, in step 3.1.4, the ratio of the training set to the test set is 4:1.
[0048] Preferably, in step 3.1.5, the data is normalized using Min-Max to scale the data to the range [0, 1]. The specific formula is as follows:
[0049]
[0050] In the formula, X norm X represents the normalized data; X represents the original data; X min X is the minimum value in the data column; max This represents the maximum value in the data column. After scaling the data, the weights assigned to each feature during subsequent model training will avoid abnormal weight allocation caused by range differences.
[0051] Preferably, the evaluation metric for the prediction model is the coefficient of determination R.2 The root mean square error (RMSE) and the mean absolute error (MAE) are calculated using the following formulas:
[0052]
[0053] In the formula, y i The actual value; This is a predicted value; is the average of the true values; n is the total number of samples.
[0054] Preferably, the evaluation index for the prediction model is to visually show the magnitude and distribution of the difference between the model's predicted value and the actual value through the residual distribution. Generally speaking, the closer the residual distribution histogram is to a normal distribution, the better the model's performance and the absence of systematic bias. The residual is the difference between the actual value and the predicted value.
[0055] Furthermore, the deep learning-based method for predicting mine gas emission also includes step ⑤, set between steps ③ and ④, to construct a PatchTST model based on the time-series data of the main control elements of mine gas emission.
[0056] 5.1 Extract time features from the data after checking for missing values in step 3.1.1.
[0057] 5.2 Divide the dataset after checking for missing values in step 3.1.1.
[0058] 5.3 Normalize the data after checking for missing values in step 3.1.1.
[0059] 5.4 Hyperparameter Settings
[0060] 5.5 Select an existing PathTST model with proven predictive performance; compute the PatchTST model output using forward propagation on the training set, and update the PatchTST model parameters by calculating the gradient through backpropagation; continuously optimize the entire training process, aiming to minimize the loss function until a predetermined convergence criterion is reached, enabling the PatchTST model to learn the inherent patterns and features in the normalized training set, forming the final PatchTST model; the test set is equivalent to a new set of data for the model, which can truly reflect the model's performance in practical applications; import the test set into the final PatchTST model for prediction, and then evaluate the prediction performance of the final PatchTST model; compare the prediction performance of the PatchTST model with the VMD-WTC-PatchTST combined model.
[0061] The beneficial effects of this invention are as follows: The deep learning-based method for predicting mine gas emission has the following advantages:
[0062] (1) This invention improves the data and model through error analysis, and the final prediction performance evaluation result of the VMD-WTC-PatchTST model is R. 2 The model achieved a performance score of 0.894, an RMSE of 1.80, and a MAE of 1.38. Compared to the original PatchTST model, its fit improved by 2.6%. Since PatchTST is also suitable for long-term prediction, theoretically, the model's performance is expected to improve further as data is continuously added.
[0063] (2) This invention uses PCC and MIC correlation analysis methods, comprehensively considering linear and nonlinear relationships, to effectively reduce the dimensionality of gas emission data and reduce the influence of irrelevant features. It also explores the interrelationships among factors influencing gas emission, and finally selects six highly correlated factors from the factors affecting mine gas emission as model inputs, providing a solid data foundation for subsequent experimental model establishment and prediction.
[0064] (3) This invention compares the predictive performance of the single model Informer and the combined model TCN-PatchTST, using the coefficient of determination R... 2 The order from highest to lowest is VMD-WTC-PatchTST > TCN-PatchTST > Informer. Attached Figure Description
[0065] Figure 1 This is a partial data table of the Lutaishan dataset;
[0066] Figure 2 It is a graph showing the change in mine gas emission over time;
[0067] Figure 3 This is the PCC analysis result of the gas emission data set from the Lutaishan coal mine in Example 1;
[0068] Figure 4 This is the MIC analysis result of the gas emission data set from the Lutaishan coal mine in Example 1;
[0069] Figure 5 This is the correlation strength grading table in Example 1;
[0070] Figure 6 This is a partial data table of gas emission volume after dimensionality reduction in Example 1;
[0071] Figure 7 This is the VMD decomposition and frequency component distribution diagram in Example 1;
[0072] Figure 8 yes Figure 7 Partial data;
[0073] Figure 9 This is the backbone diagram of the PatchTST model Transformer in Example 1;
[0074] Figure 10 This is a comparison chart of the predicted and actual data of mine gas emission from the VMD-WTC-PatchTST model in Example 1.
[0075] Figure 11 The evaluation metric R of the VMD-WTC-PatchTST model in Example 1 is... 2 Visualization chart;
[0076] Figure 12 This is a graph showing the prediction results of the final VMD-WTC-PatchTST model in Example 1;
[0077] Figure 13 This is a comparison chart of the training losses of the PatchTST model, WTC-PatchTST model, and VMD-WTC-PatchTST model in Example 2;
[0078] Figure 14 This is a histogram comparison of the residual distributions of the PatchTST model, WTC-PatchTST model, and VMD-WTC-PatchTST model in Example 2.
[0079] Figure 15 This is a comparison table of optimized data and combined model evaluation indicators in Example 2;
[0080] Figure 16 This is the Kendall analysis result of the gas emission data set from the Lutaishan coal mine in Example 3;
[0081] Figure 17 This is the DCOR analysis result of the gas emission data set from the Lutaishan coal mine in Example 4. Detailed Implementation
[0082] Example 1: See Figure 1-12 This study focuses on the No. 2 coal seam of the Lutaishan Coal Mine, located in Zhangcun Township, southwest of Qinshui County, at the southern end of the Taihang Mountains. The minefield spans 1.5–2.0 km east to west and 2.6 km north to south, covering an area of 5.7001 km². 2The entire mining area is divided into two levels. Level 1, at an elevation of +799.9m, is used for mining the No. 2 coal seam. Level 2, at an elevation of +683m, is used for mining the No. 15 coal seam, which will be mined as a successor to the No. 2 coal seam. The maximum burial depth of the No. 2 coal seam is 356m. Lutaishan Coal Mine is a high-gas mine with a designed production capacity of 600,000 tons per year. The mine uses inclined shaft development, with a total of three shafts: a main inclined shaft, a secondary inclined shaft, and a return air inclined shaft. The main inclined shaft, located at the bottom of the No. 2 coal seam, is 5.0m wide, has an inclination angle of 16.5°, and a length of 572m. It is responsible for coal transportation and personnel access, and also serves as an intake air shaft. The secondary inclined shaft, also located at the bottom of the No. 2 coal seam, is 5.5m wide, has an inclination angle of 19.5°, and a length of 442m. It is responsible for auxiliary transportation and intake air. The return air inclined shaft has a net diameter of 3.2m and a cross-section of 8.56m. 2 It is 270m long and is responsible for the return air of the mine.
[0083] The mine uses a central, split-type ventilation system with two main ventilation fans, model FBCDZ-No.28, employing a mechanical exhaust ventilation method. The total mine air intake is 6570 m³ / h. 3 / min, with an equal volume aperture area of 2.94m² 2 Ventilation difficulty is rated as easy. The longwall retreat fully mechanized mining method with single-pass full-height mining is employed, and the roof management utilizes the caving method. The working face recovery rate is 95%, with an average daily output of 2000 t / d. The haulage roadway has a cross-section of 8.64m. 2 The return air roadway has a cross-section of 8.16m. 2 Based on gas content test data during geological exploration and actual underground gas content data, the gas content of the raw coal in coal seam No. 2 varies from 5.50 to 15.18 m³. 3 Between / t, the average is 9.46m 3 / t. As of December 2024, the 2202, 2203, and 2205 working faces have been completed, the 2206 longwall mining face is about to complete its mining task, and the 2207 longwall mining face will take over. The tunneling face advances from south to north, and the mining face advances from north to south.
[0084] A deep learning-based method for predicting mine gas emission includes the following steps:
[0085] ① Dataset preparation
[0086] See also Figure 1 The existing daily data of the mine is statistically analyzed and compiled into a dataset. The daily data includes the mine's daily reports, production reports, progress reports, and workers' daily records. The dataset records the data of various related elements in terms of time.
[0087] The dataset spans from May 1, 2022 to August 31, 2024. However, due to significant data gaps and a small proportion of data from September 26, 2022 to November 25, 2022, these two months were deleted, resulting in a total of 793 records and 14 columns. The first column represents the time, the middle 12 columns contain features such as temperature and atmospheric pressure, and the last column represents the predicted mine gas emission. See [link to relevant documentation] Figure 2 The dataset was converted into a curve showing the change of mine gas emission over time. Analysis of the mine gas emission revealed a highly complex pattern with no obvious regularity or periodicity. The nonlinearity and non-stationarity issues are problems that traditional prediction models cannot handle. Furthermore, the dataset contains noise and high dimensionality interference; high-dimensional data increases model complexity, leading to longer training times and potentially overfitting.
[0088] ② Perform correlation analysis on the dataset to determine the main controlling elements of mine gas emission.
[0089] To determine the main controlling elements of mine gas emission, elements with little impact on mine gas emission are screened out to reduce subsequent data processing and improve prediction speed. In this embodiment, the main controlling elements of mine gas emission are temperature, burial depth, original gas content of the mining layer, tunneling footage, coal seam dip angle, and working face length. The data obtained can be found in [reference needed]. Figure 6 ;
[0090] ③ Construct a VMD-WTC-PatchTST combined model based on the time series data of the main controlling elements of mine gas emission.
[0091] VMD, short for Variational Mode Decomposition, is a noise reduction method in which the number of modal components can be manually set.
[0092] PatchTST, short for Patch Time Series Transformer, is a time series prediction model based on Transformer.
[0093] WTC stands for Wavelet Transform Convolution.
[0094] Combining WTC with PatchTST can improve detail recognition capabilities and accurately capture low-frequency and high-frequency information;
[0095] 3.1 Preprocessing the time series data of the main control elements of mine gas emission
[0096] The purpose of preprocessing is to make the time-series data of the master elements more suitable for model training, improve the model's performance, speed and stability, and at the same time deal with various problems in the data to ensure that the model can learn effective patterns.
[0097] 3.1.1 Check for missing values in the time series data of the main control elements of mine gas emission; missing value checking is a necessary step in data preprocessing. Missing data may cause the model to make incorrect estimates of the data distribution, resulting in model bias, reduced model generalization ability, and inability to adapt to new data.
[0098] 3.1.2 Improving the data after checking for missing values based on VMD method
[0099] 3.1.3 Extract time features from the time series data of the improved master control element; The time series data of the improved master control element is time series data, which usually has time dependence, such as seasonality, periodicity, trend, etc. Extracting time features can transmit these periodic patterns to the model, enabling the model to better understand the data and more easily capture the patterns, thereby improving the model's generalization ability.
[0100] 3.1.4 Divide the time-series data of the improved master control element into datasets.
[0101] The time series data corresponding to the improved master control element is divided into training set and test set;
[0102] 3.1.5 Perform data normalization on the timing data of the improved master control element.
[0103] Since different elements have different numerical ranges, directly inputting them into the model will reduce the model's performance. Therefore, data normalization is needed to adjust the numerical range to a uniform scale, thereby improving the model's performance and stability.
[0104] 3.2 Establishment of the Preliminary VMD-WTC-PatchTST Combined Model
[0105] See also Figure 9 We selected the existing PathTST model, which has been validated for its predictive performance; we smoothly stitched the WTC model with the PathTST model; Haar wavelet transform: we decomposed the original gas time series data using high-pass and low-pass filters to generate low-frequency (LL) and high-frequency (H) subbands; for a sequence of length L, X = [x0, x1, ..., x...], we performed the following: L-1 The formulas for the approximation coefficients (low frequencies) and detail coefficients (high frequencies) formed by high-pass and low-pass filters are as follows:
[0106]
[0107] In the formula, a id is the approximation coefficient; i These are the detail coefficients, i = 0, 1, ... (L-1) / 2;
[0108] Next, depthwise separable convolutions are applied independently to each sub-band, while parameters are shared to reduce computational cost. Finally, the results of each sub-band are merged through IWT to retain cross-scale features. IWT, short for Inverse Wavelet Transform, is a method that extracts different frequency components of the time series through wavelet transform and combines convolution operations to extract key features, thereby enhancing the model's ability to capture short-term fluctuations and long-term trends.
[0109] The PathTST model is divided into two parts: channel independence and Transformer backbone. The channel independence approach can effectively capture the characteristics of each signal, which helps to better reflect the detailed changes in each channel when processing multi-dimensional time series data.
[0110] Time series data is divided into multiple small blocks or patches, allowing PatchTST to capture local temporal features in the data. This enables the model to more accurately capture short-term temporal dependencies, avoiding overly smoothing or neglecting local information that may occur in traditional global modeling. The input time series is padded into multiple small blocks, which are then sent to the encoder of the Transformer backbone to compute the self-attention among these blocks. For the input sequence x... (i) ∈R L In other words, its block division formula is as follows:
[0111]
[0112] In the formula, N is the number of blocks, which is an integer; P is the length of the block; and S is the step size.
[0113] Next, through the learnable mapping matrix W P ∈R D×N Each block is mapped to an embedding space of dimension D, and the resulting projection is added to the position encoding matrix W. pos ∈R D×N It is the time sequence of the coded blocks, and the formula is as follows:
[0114]
[0115] Where, This is the projection result of the i-th block; For the i-th block; W P W is a learnable mapping matrix; pos This is the position encoding matrix;
[0116] After entering the Transformer encoder, in the multi-head self-attention mechanism, each head h = (1, 2, ..., H) projects its results through three different weight matrices. Multiply to calculate Query(query vector, Key (key vector) ) and Value (value vector, Next, the dot product between the Query and the Key is calculated to obtain the attention score. Then, the Softmax function is applied to the attention score to obtain the attention weight. Finally, the attention weights are used to perform a weighted summation of the Values to obtain the final output. The formula is as follows:
[0117]
[0118] In the formula, d k The dimension of the key is used for normalization to prevent the dot product value from becoming too large;
[0119] The output is flattened after passing through a feedforward neural network and residual connections to obtain the final prediction result.
[0120] 3.3 Hyperparameter Settings
[0121] Model hyperparameters are set manually at the start of training. They typically control the model structure and training, and are categorized into training parameters and structural parameters. Training parameters control the training process and directly affect the optimization process and learning behavior, while structural parameters determine the model's architecture and performance. Their settings must consider task requirements, model complexity, and other factors.
[0122] 3.4 Obtaining the final VMD-WTC-PatchTST combined model
[0123] The output of the VMD-WTC-PatchTST combined model is calculated using forward propagation on the training set, and the gradient is calculated through backpropagation to update the parameters of the VMD-WTC-PatchTST combined model. The entire training process is continuously optimized with the goal of minimizing the loss function until the predetermined convergence criterion is reached, so that the VMD-WTC-PatchTST combined model learns the inherent rules and features of the normalized training set, forming the final VMD-WTC-PatchTST combined model.
[0124] The test set is equivalent to a new set of data for the model, which can truly reflect the model's performance in real-world applications. The test set is imported into the final VMD-WTC-PatchTST combined model in chronological order, using the earlier test set data to predict the later test set data. The predicted data and the actual data on the test set are then subjected to data denormalization. The denormalized predicted data and the actual data are compared to evaluate the predictive performance of the final VMD-WTC-PatchTST combined model.
[0125] Figure 10 This is a comparison chart of the predicted and actual data of the gas emission from the VMD-WTC-PatchTST model in the mine. The VMD-WTC-PatchTST model has basically completed the task of predicting the gas emission from the Lutaishan mine.
[0126] ④ Use the final VMD-WTC-PatchTST combined model for prediction.
[0127] The time series data of the newly statistically analyzed master control elements are input into the final VMD-WTC-PatchTST combined model for prediction in a form that meets the requirements of the model hyperparameters.
[0128] See also Figure 12 The final VMD-WTC-PatchTST model was used to predict the mine gas emission; the predicted amount is the result after inverse normalization.
[0129] In step ②, the Pearson correlation coefficient (PCC) and maximum mutual information number (MIC) are used to perform correlation analysis on the dataset to determine the main controlling characteristics of mine gas emission as temperature, burial depth, original gas content of the mining layer, tunneling footage, coal seam dip angle, and working face length. While the Pearson correlation coefficient (PCC) is a commonly used indicator to measure the linear correlation between two variables, it cannot capture nonlinear relationships. The maximum mutual information number (MIC), on the other hand, can identify and quantify various forms of relationships, including nonlinear and periodic relationships. Combining these two methods allows for a comprehensive consideration of both linear and nonlinear relationships within the dataset.
[0130] Let the two variables be X and Y. The covariance of the two variables divided by their standard deviation is the Pearson correlation coefficient. The specific calculation formula is as follows:
[0131]
[0132] In the formula, r is the Pearson correlation coefficient; X i and Y i These are the observed values of two variables, X and Y, respectively. and These are the means of variables X and Y, respectively.
[0133] The r-value ranges from -1 to 1. An r-value of 1 indicates a perfectly positive linear correlation; a r-value of -1 indicates a perfectly negative linear correlation; and an r-value of 0 indicates no linear relationship between the two variables. In feature selection and feature engineering, the Pearson correlation coefficient helps assess the correlation between different features. The calculation method of the Pearson correlation coefficient is simple and intuitive, suitable for quickly analyzing linear relationships between variables. See the PCC analysis results for the Lutaishan coal mine gas emission dataset. Figure 3 .
[0134] Suppose we have two variables, X and Y. First, we discretize X and Y, converting their continuous values into discrete intervals. Then, we map the discretized X and Y onto corresponding grid cells, constructing their probability distribution matrix. Here, each cell represents the joint frequency of X and Y values. The mutual information formula is as follows:
[0135]
[0136] In the formula, p(x, y) is the joint probability distribution of X and Y; p(x) and p(y) are the marginal probability distributions of X and Y, respectively.
[0137] MIC calculates the mutual information value under different mesh partitioning methods. Simply put, MIC tries various mesh partitioning methods to find the mesh size and partitioning method that maximizes the mutual information between X and Y. The MIC calculation formula is as follows:
[0138]
[0139] In the formula, a and b are the number of grid cells in the x and y directions, respectively; B is a variable, typically the 0.6 power of the data volume. The MIC analysis results of the Lutaishan coal mine gas emission dataset are as follows: Figure 4 As shown in the figure. The mutual information coefficient (MIC) ranges from 0 to 1, with values closer to 1 indicating a stronger relationship between the two variables. In the graph, darker colors indicate a stronger correlation between the two variables. For example, the maximum mutual information number (MIN) between daily output and advance footage is 1, indicating a perfect correlation; the maximum MIN between daily output and working face length is 0.99, indicating a high degree of correlation. The advantage of MIC is that it is more powerful than the traditional Pearson correlation coefficient in capturing complex nonlinear relationships between variables, and can capture complex patterns. In time series analysis, MIC can capture complex nonlinear trends and periodic relationships in time series. Both PCC and MIC are commonly used correlation analysis methods, with their coefficients falling within the 0-1 range after taking their absolute values. Correlation strength is typically graded according to... Figure 3The analysis results show a very weak correlation between advance footage, daily output, and gas emission, and a weak correlation between coal seam thickness and gas emission. This indicates that these features have a weak linear relationship with the target variable and may not significantly improve the performance of the prediction model. These features can be considered for rejection to reduce model complexity and computation time.
[0140] according to Figure 4 The analysis results show that the correlation coefficients between atmospheric pressure, interbedded rock thickness, coal seam thickness, coal seam dip angle, working face recovery rate, working face length, and gas emission are not significantly different, indicating a weak correlation. Among these, the correlation coefficients between coal seam dip angle and working face length are higher than those of other characteristics in the PCC analysis. Therefore, atmospheric pressure, interbedded rock thickness, coal seam thickness, and working face recovery rate can be discarded.
[0141] Both PCC and MIC are commonly used correlation analysis methods. Their coefficients, when taken as absolute values, fall within the range of 0 to 1. For typical correlation strength grading, please refer to [link to relevant documentation]. Figure 5 .
[0142] In step 3.1.2, the data after checking for missing values is decomposed layer by layer into K modal components u. k (t), where K is the number of modes, and each u k (t) is the IMF; IMF stands for Intrinsic Mode Function; as a component of the signal, the IMF has a finite bandwidth, and its spectrum can be concentrated within a certain frequency band; VMD can make the sum of each mode close to f(t), while requiring the sum of the bandwidths near the center frequency of each mode to be minimized; the mode bandwidth is minimized through variational optimization methods; the bandwidth of each IMF is as independent and as small as possible, thus effectively decomposing the original signal; K=3; VMD can achieve the best noise reduction effect.
[0143] See also Figure 7 VMD was used to decompose the gas outburst data of Lutaishan into three IMFs. The decomposition details and frequency components of each IMF are described below. (See also...) Figure 8 Partial data after decomposition by the three IMFs.
[0144] In step 3.1.3, timeenc is used to encode the time features into the range of [-0.5, 0.5]. The freq parameter is D, which means that the time features are extracted according to the daily frequency. This helps to capture the complete periodic changes in gas outflow. In addition to the daily time frequency, there are also weekly, weekday and other time frequency extraction methods.
[0145] In step 3.1.4, the ratio of the training set to the test set is 4:1.
[0146] In step 3.1.5, the data is normalized using Min-Max, scaling it to the range [0, 1]. The specific formula is as follows:
[0147]
[0148] In the formula, X norm X represents the normalized data; X represents the original data; X min X is the minimum value in the data column; max This represents the maximum value in the data column. After scaling the data, the weights assigned to each feature during subsequent model training will avoid abnormal weight allocation caused by range differences.
[0149] The evaluation metric for the prediction model is the coefficient of determination R. 2 The root mean square error (RMSE) and the mean absolute error (MAE) are calculated using the following formulas:
[0150]
[0151]
[0152] In the formula, y i The actual value; This is a predicted value; is the average of the true values; n is the total number of samples.
[0153] Figure 11 The R-value is the result of comparing the prediction test set and the actual test set of the VMD-WTC-PatchTST model. 2 The visualization can quantify the prediction accuracy of the VMD-WTC-PatchTST model.
[0154] Example 2: See Figure 13-15 Example 2 is basically the same as Example 1, and the similarities will not be repeated. The difference is that the deep learning-based method for predicting mine gas outbursts also includes step 5, which is set between steps ③ and ④, to construct a PatchTST model based on the time-series data of the main control elements of mine gas outbursts.
[0155] 5.1 Extract time features from the data after checking for missing values in step 3.1.1.
[0156] 5.2 Divide the dataset after checking for missing values in step 3.1.1.
[0157] 5.3 Normalize the data after checking for missing values in step 3.1.1.
[0158] 5.4 Hyperparameter Settings
[0159] 5.5 Select an existing PathTST model with proven predictive performance; compute the PatchTST model output using forward propagation on the training set, and update the PatchTST model parameters by calculating the gradient through backpropagation; continuously optimize the entire training process, aiming to minimize the loss function until a predetermined convergence criterion is reached, enabling the PatchTST model to learn the inherent patterns and features in the normalized training set, forming the final PatchTST model; the test set is equivalent to a new set of data for the model, which can truly reflect the model's performance in practical applications; import the test set into the final PatchTST model in chronological order, enabling the final PatchTST model to predict the test set, and evaluate the predictive performance of the final PatchTST model; compare the predictive performance of the PatchTST model with the VMD-WTC-PatchTST combined model.
[0160] Figure 13 The blue line represents the training loss of the VMD-WTC-PatchTST model per epoch, while the red line represents the training loss of the PatchTST model per epoch. Smoothing refers to applying an exponentially weighted average to smooth the training losses of each model, making the results more intuitive. Comparing the training losses of the two models, we found that the VMD-WTC-PatchTST model's training loss begins to fall below that of the PatchTST model after 200 epochs, only stabilizing after 300 epochs, and its fluctuation range is smaller than that of the PatchTST model. The VMD-WTC-PatchTST model's final training loss is approximately 0.0026, significantly stronger than that of the PatchTST model.
[0161] Figure 14 This is a histogram comparing the residual distributions of the PatchTST, WTC-PatchTST, and VMD-WTC-PatchTST models. For a comparison of the evaluation metrics of the optimized data and combined models, see [link to relevant documentation]. Figure 15 . Figure 13 The residual range of the VMD-WTC-PatchTST model is significantly smaller than that of the original PatchTST model, approximately within the range of [-5, 5]. Furthermore, the overall distribution shape is more consistent with a normal distribution, demonstrating enhanced generalization ability and improved fitting performance. The optimization scheme utilizing VMD denoising and WTConv to improve model detail capture is effective.
[0162] The evaluation metric for a prediction model is to visually observe the magnitude and distribution of the difference between the model's predicted values and the actual values through the residual distribution. Generally speaking, the closer the residual distribution histogram is to a normal distribution, the better the model's performance and the absence of systematic bias. The residual is the difference between the actual value and the predicted value.
[0163] Example 3: Example 3 is basically the same as Example 1, and the similarities will not be repeated. The differences are: see [link to example]. Figure 16 In step ②, Kendall correlation coefficient was used to perform correlation analysis on the dataset to determine that temperature was the main controlling characteristic of mine gas outburst.
[0164] In step 3.1.3, time features are extracted using a conventional time feature extraction method based on pandas.
[0165] Suppose you have a datetime column df['date'], you can easily extract the following features using pandas.dt:
[0166] df['year']=df['date'].dt.year
[0167] df['month']=df['date'].dt.month
[0168] df['day'] = df['date'].dt.day
[0169] df['weekday']=df['date'].dt.weekday#Day of the week, 0=Monday
[0170] df['hour']=df['date'].dt.hour
[0171] df['minute']=df['date'].dt.minute
[0172] df['dayofyear']=df['date'].dt.dayofyear
[0173] df['weekofyear']=df['date'].dt.isocalendar().week
[0174] Simple and straightforward, suitable for traditional machine learning, LSTM, Transformer, and other models. No additional libraries required, allowing for flexible combination and use.
[0175] In step 3.1.5, the data is normalized using maximum value normalization, scaling the data to the range [0, 1]. The specific formula is as follows:
[0176]
[0177] In the formula, X norm X represents the normalized data; X represents the original data; X maxThis represents the maximum value in the data column.
[0178] Example 4: Example 4 is basically the same as Example 1, and the similarities will not be repeated. The differences are: see [link to example]. Figure 17 In step ②, the distance correlation coefficient (DCOR) is used to perform correlation analysis on the dataset to determine that the main controlling characteristics of mine gas outburst are temperature and working face length.
[0179] In step 3.1.3, a time embedding method based on natural language processing (NLP) is used to extract time features.
[0180] Convert the timestamps into “text” labels, then process them using an Embedding layer (neural networks only).
[0181] df['hour']=df['date'].dt.hour
[0182] #Then input it into the model as a classification feature, or convert it into a vector using an embedding layer.
[0183] Used in models such as TabTransformer and FT-Transformer; timestamps are embedded as part of the category encoding.
Claims
1. A method for predicting mine gas emission based on deep learning, characterized in that, Includes the following steps: ① Dataset preparation ② Perform correlation analysis on the dataset to determine the main controlling elements of mine gas emission. ③ Construct a VMD-WTC-PatchTST combined model based on the time series data of the main controlling elements of mine gas emission. 3.1 Preprocessing the time series data of the main control elements of mine gas emission 3.1.1 Check for missing values in the time series data of the main control elements of mine gas emission. 3.1.2 Improving the data after checking for missing values based on VMD method 3.1.3 Extracting time features from the time-series data of the improved master control element. 3.1.4 Divide the time-series data of the improved master control element into datasets. The time series data corresponding to the improved master control element is divided into training set and test set; 3.1.5 Perform data normalization on the timing data of the improved master control element. 3.2 Establishment of the Preliminary VMD-WTC-PatchTST Combined Model Select an existing PathTST model whose prediction performance has been verified; smoothly stitch WTC with the PathTST model; 3.3 Hyperparameter Settings 3.4 Obtaining the final VMD-WTC-PatchTST combined model The output of the VMD-WTC-PatchTST combined model is calculated using forward propagation on the training set, and the gradient is calculated and the parameters of the VMD-WTC-PatchTST combined model are updated through backpropagation. The entire training process is continuously optimized with the goal of minimizing the loss function until a predetermined convergence criterion is reached, forming the final VMD-WTC-PatchTST combined model. The predictive performance of the final VMD-WTC-PatchTST combined model is evaluated. ④ The final VMD-WTC-PatchTST combined model is used for prediction.
2. The method for predicting mine gas outbursts based on deep learning according to claim 1, characterized in that: In step ②, the Pearson correlation coefficient (PCC) and maximum mutual information number (MIC) are used to perform correlation analysis on the dataset to determine the main controlling characteristics of mine gas outburst as temperature, burial depth, original gas content of the mining layer, tunneling footage, coal seam dip angle, and working face length.
3. The method for predicting mine gas outbursts based on deep learning according to claim 2, characterized in that: In step 3.1.2, the data after checking for missing values is decomposed layer by layer into K modal components u. k (t), where K is the number of modes, and each u k (t) is the IMF; the IMF, as a component of the signal, has a limited bandwidth, and its spectrum can be concentrated within a certain frequency band; VMD can make the sum of each mode close to f(t), while requiring the sum of the bandwidths near the center frequency of each mode to be minimized; the mode bandwidth is minimized by variational optimization method; the bandwidth of each IMF is as independent as possible and as small as possible; K=3.
4. The method for predicting mine gas outbursts based on deep learning according to claim 1, characterized in that: In step 3.1.3, timeenc is used to encode the time features into the range of [-0.5, 0.5], and the freq parameter is D, which means that the time features are extracted at a daily frequency.
5. The method for predicting mine gas outbursts based on deep learning according to claim 1, characterized in that: In step 3.1.4, the ratio of the training set to the test set is 4:
1.
6. The method for predicting mine gas outbursts based on deep learning according to claim 1, characterized in that: In step 3.1.5, the data is normalized using Min-Max, scaling it to the range [0, 1]. The specific formula is as follows: In the formula, X norm X represents the normalized data; X represents the original data; X min X is the minimum value in the data column; max This represents the maximum value in the data column. After scaling the data, the weights assigned to each feature during subsequent model training will avoid abnormal weight allocation caused by range differences.
7. The method for predicting mine gas outbursts based on deep learning according to claim 1, characterized in that: The evaluation metric for the prediction model is the coefficient of determination R. 2 The root mean square error (RMSE) and the mean absolute error (MAE) are calculated using the following formulas: In the formula, y i The actual value; This is a predicted value; is the average of the true values; n is the total number of samples.
8. The method for predicting mine gas outbursts based on deep learning according to claim 1, characterized in that: The evaluation metric for the prediction model is to visually demonstrate the magnitude and distribution of the difference between the model's predicted values and the actual values through the residual distribution.
9. The deep learning-based method for predicting mine gas outbursts according to claim 7 or 8, characterized in that: It also includes step ⑤, which is set between steps ③ and ④, to construct the PatchTST model based on the time-series data of the main control elements of mine gas emission. 5.1 Extract time features from the data after checking for missing values in step 3.1.
1. 5.2 Divide the dataset after checking for missing values in step 3.1.
1. 5.3 Normalize the data after checking for missing values in step 3.1.
1. 5.4 Hyperparameter Settings 5.5 Select an existing PathTST model with proven predictive performance; calculate the PatchTST model output using forward propagation on the training set, and calculate the gradient through backpropagation to update the PatchTST model parameters; continuously optimize the entire training process, aiming to minimize the loss function until the predetermined convergence criterion is reached, forming the final PatchTST model; import the test set into the final PatchTST model for prediction, and then evaluate the prediction performance of the final PatchTST model.
Citation Information
Patent Citations
Gas emission prediction method based on WT-KPCA-SVR coupling model
CN104794550B
A method for estimating gas emission from coal seams in front of tunnel face
CN113723026B
Cited By
Method and device for predicting content of dissolved gas in transformer oil
CN121388473A
Gas emission quantity prediction method based on time sequence self-attention network
CN121638124A