A soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM
By identifying anomalous data using the DBSCAN model and combining it with particle filters and LSTM neural networks, a DBSCAN-PF-LSTM model was constructed. This solved the problems of time delay and low accuracy in multi-component ore content measurement, and enabled more efficient and accurate prediction of multi-component ore content.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHANGHAI UNIV
- Filing Date
- 2023-11-30
- Publication Date
- 2026-06-26
AI Technical Summary
Existing methods for measuring the content of multi-component ores suffer from time delays, high costs, and poor real-time performance. Furthermore, existing models are cumbersome and have low accuracy when predicting multi-component content.
The DBSCAN model is used to identify abnormal data, combined with a particle filter to filter the data, and trained using an LSTM neural network to construct a DBSCAN-PF-LSTM model for soft measurement of the content of multi-component ores.
It improves the accuracy and robustness of multi-component ore content prediction, effectively identifies and handles outliers in the data, and provides more accurate and stable prediction results.
Smart Images

Figure CN117637055B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of multi-component ore content prediction, and in particular to a soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM. Background Technology
[0002] The content of multiple components in ores is one of the key parameters for mining enterprises to control production processes and manage product quality. Traditional methods for measuring ore content mainly employ offline testing and online analyzers, which suffer from problems such as time delays, high costs, and poor real-time performance. With the continuous development of information technology and the improvement of production automation, real-time monitoring and prediction methods for the content of multiple components in ores based on intelligent algorithms and machine learning have gradually become a focus of attention for mining enterprises.
[0003] To predict the silicon content of blast furnace hot metal, the paper "Long short-term memory based on randomforest-recursive feature eliminated for hot metal silicon content prediction of blast furnace" proposes a combined prediction model of RF-RFE-LSTM, verifying that the recursive feature elimination method under random forest (RF-RFE) can effectively improve the accuracy of the prediction model by removing some irrelevant features. To improve the prediction accuracy of alumina composition in bauxite, the paper "Research on the prediction of bauxite slurry composition based on deep learning" proposes a prediction model based on GM-RBF neural network and verifies the model's effectiveness using production data from a factory as an example. However, the methods disclosed in the above papers focus on improving the prediction accuracy of single objects or components, without considering the impact of multi-component objects on the prediction model. In actual prediction, the steps are too cumbersome, and the accuracy is relatively low. Therefore, this invention provides a soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM. Summary of the Invention
[0004] The purpose of this invention is to overcome the shortcomings of the existing technology and provide a soft measurement method for the content of multi-component ores based on DBSCAN-PF-LSTM.
[0005] The objective of this invention can be achieved through the following technical solutions:
[0006] This invention discloses a soft measurement method for the content of multi-component ores based on DBSCAN-PF-LSTM, comprising the following steps:
[0007] Step S1: Extract historical test data on the content of multiple components of ore, and establish a multidimensional data sequence based on the historical test data;
[0008] Step S2: Use the DBSCAN model to identify normal and abnormal data in the multidimensional data sequence, calculate the average value of the previous historical test data of the abnormal data, and replace the abnormal data with the average value to obtain the second historical test data.
[0009] Step S3: Use a particle filter to filter the second historical test data to obtain the third historical test data;
[0010] Step S4: Construct an LSTM neural network model. Use the third historical test data as the training dataset for the LSTM neural network model. Input the training dataset into the LSTM neural network model for training. After a set number of training iterations, obtain the LSTM neural network model.
[0011] Step S5: The multi-component ore content data to be measured is processed sequentially through steps 1 to 4, and the prediction results of the multi-component ore content are obtained through the LSTM neural network model.
[0012] Furthermore, step S1 specifically includes the following steps:
[0013] Step S11: Reorganize the historical test data by composition (rows) and time (columns) to form a multidimensional data sequence;
[0014] Step S12: Normalize the multidimensional data sequence to unify the measurement scale.
[0015] Furthermore, the multidimensional data sequence includes parameters in three dimensions: FE, CA, and S.
[0016] Further, step S2 specifically includes:
[0017] Step S21: Set the parameters R and N of the DBSCAN model, where R is the maximum neighborhood radius and N is the minimum number of neighborhood samples;
[0018] Step S22: After normalizing the multidimensional data sequence, input it into the DBSCAN model and calculate the number of samples within the maximum neighborhood radius R for each data point; if the number of samples is less than the minimum neighborhood sample number N, then mark the data point as abnormal data; otherwise, mark it as normal data.
[0019] Step S23: Delete the abnormal data and replace it with the average of its previous historical data to obtain the second historical test data.
[0020] Furthermore, the identified normal data and abnormal data are visualized, with the normal data displayed as dots and the abnormal data displayed as triangles.
[0021] Furthermore, step S3 specifically includes:
[0022] Step S31: Initialize the particle filter parameters: including setting the time step, number of particles, process noise variance, and measurement noise variance. For each particle i, sample the initial state x0 from the second historical test data x0. (i) Set the weight w0 for each particle. (i) =1 / N;
[0023] Step S32: Perform state prediction for each particle i, starting from the particle state x of the previous time step in the current time step. k-1 (i) Sampling yields x k (i) Calculate the importance weight w for each particle. k (i) The particle state x at the current time step k (i) and the corresponding weight w k (i) The weighted average of the particle states is calculated as the filter value;
[0024] Step S33: Resample all particles, retaining particles with higher weights and removing particles with lower weights;
[0025] Step S34: For each resampled particle i, set its weight to w. k (i) =1 / N;
[0026] Step S35: Repeat steps S32 to S34 until all data points in the second historical test data have been filtered to obtain the third historical test data.
[0027] Furthermore, the LSTM neural network model includes: 1 input layer, 2 hidden layers and 1 output layer, using the tanh function as the activation function, and the Adam optimizer is used in the training process.
[0028] Furthermore, 70% of the third historical test data is used as the training dataset, and 30% is used as the test dataset.
[0029] In a second aspect, the present invention discloses a computer device, including a processor, a memory, a user interface, and a network interface. The memory is used to store instructions, the user interface and the network interface are used to communicate with other devices, and the processor is used to execute the instructions stored in the memory to cause the computer device to perform any of the methods described above.
[0030] Thirdly, the present invention discloses a storage medium having a program stored thereon, wherein the program, when executed, implements the method described in any one of the above.
[0031] Compared with the prior art, the present invention has the following beneficial effects:
[0032] (1) This invention proposes a soft measurement method for the content of multi-component ores based on DBSCAN-PF-LSTM, which can measure the content of multi-component ores.
[0033] (2) The present invention utilizes density-based spatial clustering DBSCAN, which can effectively identify and process outliers in the data.
[0034] (3) The present invention uses a particle filter to further filter the data and uses the LSTM model trained by the processed data to predict the multi-component ore content of the next day, thereby improving the accuracy and robustness of the model used to predict the multi-component ore content. Attached Figure Description
[0035] Figure 1 This is a flowchart of the steps of the present invention;
[0036] Figure 2 This is a flowchart of the data sequence preprocessing in this invention;
[0037] Figure 3 This is a flowchart illustrating the use of the DBSCAN model in this invention;
[0038] Figure 4 This is a flowchart illustrating the particle filtering (PF) algorithm used in this invention;
[0039] Figure 5 This is a visualized three-dimensional spatial diagram of the clusters identified by the DBSCAN model in this invention;
[0040] Figure 6 This is a comparison chart of the second historical data value of FE content and the filtered value after using particle filtering (PF) in this invention;
[0041] Figure 7 This is a comparison chart of the second historical data value of CA content and the filtered value after using particle filtering (PF) in this invention;
[0042] Figure 8This is a comparison chart of the second historical data value of S content and the filtered value after using particle filtering (PF) in this invention;
[0043] Figure 9 This is a comparison chart of the LSTM model prediction value of FE content in this invention and the third historical data test value to be measured.
[0044] Figure 10 This is a comparison chart of the LSTM model prediction value of CA content in this invention and the test value of the third historical data to be measured.
[0045] Figure 11 This is a comparison chart of the LSTM model prediction value of S content in this invention and the third historical data test value to be measured. Detailed Implementation
[0046] The present invention will now be described in detail with reference to the accompanying drawings and specific embodiments. These embodiments are based on the technical solution of the present invention and provide detailed implementation methods and specific operating procedures. However, the scope of protection of the present invention is not limited to the following embodiments.
[0047] Example
[0048] This embodiment provides a soft measurement method for the content of multi-component ore based on DBSCAN-PF-LSTM, which specifically includes the following steps:
[0049] Step 1: In this embodiment, historical test data on the content of iron ore mined by a mining company over the past three years are extracted, totaling 1859 sets. These historical test data on iron ore content are recombined with composition as the row and time as the column to form a multidimensional data sequence with parameters of three dimensions: FE, CA, and S. The multidimensional data sequence is then normalized to unify the measurement scale.
[0050] Step 2: Use the density-based spatial clustering DBSCAN model to identify the normalized multidimensional data sequence, identify normal data and abnormal data, calculate the average of the previous historical test data of the abnormal data, replace the abnormal data with the average value, and obtain the second historical test data.
[0051] Specifically, step 21: Set the DBSCAN model parameters R = 0.05 and N = 5, where R is the maximum neighborhood radius and N is the minimum number of neighborhood samples;
[0052] Step 22: Based on the parameters set in Step 21, normalize the multidimensional data sequence and input it into the DBSCAN model for anomaly identification. Calculate the number of samples in the neighborhood of each data point. If the number of samples is less than a threshold, mark it as an anomaly; otherwise, mark it as normal data.
[0053] Step 23: Identified outlier data will be labeled as -1, and the resulting clusters will be visualized, such as... Figure 5 As shown, circles represent normal data clusters, and triangles represent identified outliers. These outliers are deleted, and the missing positions are filled with the average of the previous 5 historical data points.
[0054] Step 3: Use a particle filter to filter the second historical test data to obtain the third historical test data.
[0055] Step 31: Initialize the particle filter parameters, including setting the time step k = 0, the number of particles N = 200, and the process noise variance x. N =0.5, measurement noise variance x R =0.1. For each particle i, the initial state x0 is obtained by sampling from the second historical test data x0. (i) Set the weight w0 for each particle. (i) = 1 / N.
[0056] Step 32: Perform state prediction for each particle i, starting from the particle state x of the previous time step in the current time step. k-1 (i) Sampling yields x k (i) Calculate the importance weight w for each particle. k (i) The particle state x at the current time step k (i) and the corresponding weight w k (i) The weighted average of the states is calculated as the filter value;
[0057] Step 33: Resample all particles, retaining particles with higher weights and removing particles with lower weights;
[0058] Step 34: For each resampled particle i, set its weight to w. k (i) =1 / N;
[0059] Step 35: Repeat steps 32 to 34 until all second historical test data in the data sequence are input into the filter to obtain third historical test data, thus completing the filtering.
[0060] The filtering result is as follows Figure 6 , Figure 7 , Figure 8As shown in the figure, the third historical test data value (filtered value), represented by the dashed line, exhibits smoothness that eliminates the sharp changes and spikes present in the second historical data value, represented by the solid line. The particle filter reduces uncertainties and noise interference that may exist during the measurement process, providing smooth and stable estimation results, making the estimation results more reliable and accurate.
[0061] Step 4: Construct an LSTM neural network model. Input the data processed by the particle filter, i.e., the third historical test data, into the LSTM model for training.
[0062] Specifically, the LSTM neural network model consists of one input layer, two hidden layers, and one output layer. It uses the tanh function as the activation function and the Adam optimizer is used during the training process.
[0063] The number of hidden layer neurons is set to 50, and the learning rate is set to 1e. -2 The training iterations were performed for 8000 epochs. The third-generation historical test data, processed by the particle filter, was divided in a 7:3 ratio, with 70% used for model training and 30% used for testing. The training dataset was input into the LSTM neural network model. During training, the network parameters were continuously adjusted. Once the training iterations were completed or the optimal training curve was obtained, the LSTM neural network model training was complete. The LSTM neural network model parameters were then saved, resulting in the trained LSTM neural network model.
[0064] Step 5: Process the multi-component ore content data to be measured sequentially through steps 1 to 4, and obtain the prediction results of the multi-component ore content through the LSTM neural network model.
[0065] Specifically, the predicted content of the multi-component ore to be measured is obtained through the following method: First, the multi-component ore content data to be measured is processed: the multi-component ore content data to be measured is processed sequentially through steps 1-3 to obtain the third historical test data to be measured. Here, the dataset used in step 4 is used. The dataset is divided into 3-day time windows, shifting forward by 1 value each time. The third historical test data to be measured is input into the time window, and then the values within the time window are input into the trained LSTM neural network model. The output is the prediction result, which is the content prediction for the next day. That is, by inputting the new test data of each day into the LSTM model in the above manner, the content prediction result for the corresponding next day can be obtained.
[0066] Figure 9 , Figure 10 , Figure 11This is a schematic diagram illustrating the comparison of specific prediction results. In this embodiment, the predicted ore content for the next day is first obtained, then the test data for that day is acquired. This acquired data is then used as the third set of historical data to be measured and compared with the prediction results. For example... Figure 9 , Figure 10 , Figure 11 As shown, the solid line represents the third historical test data to be measured, processed through steps 1-3 before being input into the LSTM neural network model. This third historical test data is updated daily, including data for the next day (this is done after the data for that day is collected and used as the third historical test data to be measured). The dashed line represents the predicted values obtained based on the LSTM model, which include the predicted values for three contents: FE, CA, and S. As can be seen from the figure, there is a high degree of fit between the predicted values and the third historical test data to be measured. In the case of sudden changes or anomalies in the third historical test data to be measured, the dashed line can relatively smoothly follow the changes of the solid line, indicating that the model has a certain degree of robustness in handling anomalies. The MSE (mean squared error) of the predicted values for the three contents are 0.2024, 0.0766, and 0.0027, respectively, indicating that this method can effectively predict the contents of multi-component iron ore.
[0067] The preferred embodiments of the present invention have been described in detail above. It should be understood that those skilled in the art can make numerous modifications and variations based on the concept of the present invention without creative effort. Therefore, all technical solutions that can be obtained by those skilled in the art based on the concept of the present invention through logical analysis, reasoning, or limited experimentation on the basis of existing technology should be within the scope of protection defined by the claims.
Claims
1. A soft measurement method for the content of multi-component ore based on DBSCAN-PF-LSTM, characterized in that, Includes the following steps: Step S1: Extract historical test data on the content of multiple components of ore, and establish a multidimensional data sequence based on the historical test data; Step S2: Use the DBSCAN model to identify normal and abnormal data in the multidimensional data sequence, calculate the average value of the previous historical test data of the abnormal data, and replace the abnormal data with the average value to obtain the second historical test data. Step S3: Use a particle filter to filter the second historical test data to obtain the third historical test data; Step S4: Construct an LSTM neural network model. Use the third historical test data as the training dataset for the LSTM neural network model. Input the training dataset into the LSTM neural network model for training. After a set number of training iterations, obtain the LSTM neural network model. Step S5: The multi-component ore content data to be measured is processed sequentially through steps 1 to 4, and the prediction results of the multi-component ore content are obtained through the LSTM neural network model.
2. The soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM according to claim 1, characterized in that, Step S1 specifically includes the following steps: Step S11: Reorganize the historical test data by composition (rows) and time (columns) to form a multidimensional data sequence; Step S12: Normalize the multidimensional data sequence to unify the measurement scale.
3. The soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM according to claim 2, characterized in that, The multidimensional data sequence includes parameters in three dimensions: FE, CA, and S.
4. The soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM according to claim 1, characterized in that, Step S2 specifically includes: Step S21: Set the parameters R and N of the DBSCAN model, where R is the maximum neighborhood radius and N is the minimum number of neighborhood samples; Step S22: After normalizing the multidimensional data sequence, input it into the DBSCAN model and calculate the number of samples within the maximum neighborhood radius R for each data point; if the number of samples is less than the minimum neighborhood sample number N, then mark the data point as abnormal data; otherwise, mark it as normal data. Step S23: Delete the abnormal data and replace it with the average of its previous historical data to obtain the second historical test data.
5. The soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM according to claim 4, characterized in that, The identified normal and abnormal data are visualized, with normal data displayed as dots and abnormal data displayed as triangular dots.
6. The soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM according to claim 1, characterized in that, Step S3 specifically includes: Step S31: Initialize the particle filter parameters: including setting the time step, number of particles, process noise variance, and measurement noise variance. For each particle i, sample the initial state x0 from the second historical test data x0. (i) Set the weight w0 for each particle. (i) =1 / N; Step S32: Perform state prediction for each particle i, starting from the particle state x of the previous time step in the current time step. k-1 (i) Sample x k (i) Calculate the importance weight w for each particle. k (i) The particle state x at the current time step k (i) and the corresponding weight w k (i) The weighted average of the particle states is calculated as the filter value; Step S33: Resample all particles, retaining particles with higher weights and removing particles with lower weights; Step S34: For each resampled particle i, set its weight to w. k (i) =1 / N; Step S35: Repeat steps S32 to S34 until all data points in the second historical test data have been filtered to obtain the third historical test data.
7. The soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM according to claim 1, characterized in that, The LSTM neural network model includes: 1 input layer, 2 hidden layers and 1 output layer, using the tanh function as the activation function, and the Adam optimizer is used in the training process.
8. The soft measurement method for multi-component ore content based on DBSCAN-PF-LSTM according to claim 7, characterized in that, 70% of the third historical test data was used as the training dataset, and 30% was used as the test dataset.
9. A computer device comprising a processor, a memory, a user interface, and a network interface, wherein the memory is used to store instructions, and the user interface and network interface are used to communicate with other devices, characterized in that, The processor is configured to execute instructions stored in the memory to cause the computer device to perform the method as described in any one of claims 1-8.
10. A storage medium having a program stored thereon, characterized in that, When the program is executed, it implements the method as described in any one of claims 1-8.