A lead-zinc grade prediction method based on LIBS spectrum

By constructing a multi-smoothing unit and a multi-head attention fusion module, the problem of balancing detection accuracy and real-time performance in LIBS spectral detection technology was solved, achieving high-precision, real-time lead-zinc grade prediction and improving the robustness and stability of the system.

CN122448825APending Publication Date: 2026-07-24CHANGSHA RES INST OF MINING & METALLURGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHANGSHA RES INST OF MINING & METALLURGY CO LTD
Filing Date
2026-06-25
Publication Date
2026-07-24

AI Technical Summary

Technical Problem

Existing LIBS spectral detection technology suffers from a trade-off between detection accuracy and real-time performance in industrial settings. Characteristic peaks are easily submerged by noise, feature extraction is unreliable, and the large number of parameters in deep learning models leads to excessively long inference times, failing to meet the real-time requirements of online mineral processing detection. Furthermore, the lack of a robust industrial-grade fault-tolerance and closed-loop control mechanism results in predictive anomalies that can lead to excessive or insufficient addition of mineral processing reagents, reducing concentrate recovery rates and increasing reagent costs.

Method used

A first smoothing unit is constructed to suppress low-frequency matrix interference in the spectrum and maintain the spectral waveform, and a second smoothing unit is constructed to remove high-frequency noise in the spectrum. A fusion unit is constructed based on dynamic weight allocation with physical constraints. Spectral parameters are extracted by combining traditional branching and deep branching. A prediction model is constructed by using a multi-head attention fusion module and a weak peak weighting module. The robustness of the system is improved by objective function and consistency constraint closed-loop control.

Benefits of technology

It improves the spectral signal-to-noise ratio, achieves high-precision lead-zinc grade prediction, meets the real-time requirements of industrial control, enhances the system's stability and anti-interference ability, reduces the spectral anomaly rate, and improves the prediction accuracy under high matrix ore conditions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122448825A_ABST
    Figure CN122448825A_ABST
Patent Text Reader

Abstract

The present application relates to the online detection technology field of the ore dressing industry, and discloses a lead-zinc grade prediction method based on LIBS spectrum. It comprises the following steps: constructing a first smoothing unit and a second smoothing unit, constructing a fusion unit based on dynamic weight distribution of physical constraints, constructing a pretreatment module based on the first smoothing unit, the second smoothing unit and the fusion unit; constructing a traditional branch, constructing a deep branch based on multi-scale convolution, constructing a multi-head fusion module by taking the traditional branch as a query branch and taking the deep branch as a key branch and a value branch, constructing a weak peak weighting module based on the weak peak region in the industrial calibrated lead-zinc spectrum, and constructing a prediction model based on the traditional branch, the deep branch, the multi-head fusion module, the weak peak weighting module and a multilayer perception mechanism; inputting the lead-zinc spectrum after being processed by the pretreatment module into the prediction model to obtain the lead-zinc grade prediction result corresponding to the lead-zinc spectrum. The problem that the detection accuracy and real-time performance of the existing lead-zinc grade prediction model cannot be considered simultaneously is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of online detection technology in the mineral processing industry, and in particular to a method for predicting lead and zinc grades based on laser-induced breakdown spectroscopy. Background Technology

[0002] In mineral processing plants, online detection of lead and zinc grades is crucial for precise process control, improved concentrate recovery, and reduced reagent costs. While LIBS spectroscopy is widely used in the industry, its industrial applications suffer from several structural technical flaws that compromise both accuracy and real-time performance, making it difficult to meet the demands of industrial production.

[0003] 1. Industrial LIBS spectra are affected by matrix effects, plasma fluctuations, etc., resulting in low signal-to-noise ratio of the original spectrum. Characteristic peaks (especially weak Pb / Zn peaks) are easily submerged by noise, leading to unreliable feature extraction. 2. Existing detection methods use a single smoothing technique, which cannot simultaneously achieve peak shape fidelity and noise suppression. A single smoothing method either leads to peak shape distortion or fails to effectively suppress high-frequency noise. 3. The feature extraction process uses a single model (traditional linear / nonlinear model or deep learning model), which cannot simultaneously adapt to the linear and nonlinear mapping relationship between Pb / Zn grade and spectral characteristics, resulting in large prediction errors; 4. Deep learning models have a large number of parameters and take too long to inference, which cannot meet the real-time requirements of online mineral processing detection; the Pb / Zn feature peaks overlap, and existing methods are unable to achieve feature decoupling, which further aggravates the prediction error. 5. The lack of a sound industrial-grade fault-tolerance and closed-loop control mechanism makes it easy for predicted anomalies to lead to excessive or insufficient addition of mineral processing reagents, reducing concentrate recovery rate and increasing reagent costs; While existing technologies have attempted to combine traditional models with deep learning models, these are merely simple splicing together, failing to form a synergistic and complementary structural system. Furthermore, they lack specific structures designed to address the needs of industrial environments, such as spectral interference, real-time requirements, and anomaly tolerance, thus failing to fundamentally resolve the aforementioned technical shortcomings. Simultaneously, existing methods do not design objective functions that are tied to industrial indicators, making it impossible to achieve synergistic optimization of accuracy, real-time performance, and industrial constraints, further limiting the effectiveness of industrial applications. Summary of the Invention

[0004] This invention provides a lead-zinc grade prediction method based on LIBS spectroscopy to solve the problem that existing lead-zinc grade prediction models cannot simultaneously achieve both detection accuracy and real-time performance.

[0005] To achieve the above objectives, the present invention employs the following technical solution: This invention provides a method for predicting lead and zinc grades based on LIBS spectroscopy, comprising the following steps: Step 1: Construct a first smoothing unit that suppresses low-frequency matrix interference and preserves the spectral waveform; construct a second smoothing unit that removes high-frequency noise from the spectrum; construct a fusion unit based on physical constraints and dynamic weight allocation to fuse the output spectra of the first and second smoothing units; and construct a preprocessing module based on the first smoothing unit, the second smoothing unit, and the fusion unit. Step 2: Construct a traditional branch for extracting the linear and nonlinear relationships between spectral parameters and target grade; construct a deep branch based on multi-scale convolution to extract peak shape features in the spectrum; use the output of the traditional branch as the query branch of multi-head attention; use the output of the deep branch as the key branch and value branch of multi-head attention to construct a multi-head fusion module; construct a weak peak weighting module based on weak peak regions in the lead-zinc spectrum after industrial calibration and attention weighting; and construct a prediction model based on the traditional branch, deep branch, multi-head fusion module, weak peak weighting module, and multilayer perceptron. Step 3: Obtain the lead-zinc spectrum from the industrial site, and smooth the lead-zinc spectrum through the preprocessing module to obtain the first spectrum, signal-to-noise ratio, and dynamic weights. Input the first spectrum, signal-to-noise ratio, and dynamic weights into the prediction model to obtain the lead-zinc grade prediction results corresponding to the lead-zinc spectrum.

[0006] Furthermore, it also includes a verification unit, which sets constraints on the parameters of each unit and module in the preprocessing module and the prediction model based on industrial functions, calibrates the preprocessing module and the prediction model based on the constraints to obtain a first parameter set, and covers the corresponding parameters of the preprocessing module and the prediction model with the first parameter set. The parameters of the preprocessing module include the smoothing window size parameter; The parameters of the prediction model include the number of multi-head attention heads and dropout rate of the multi-head fusion module, the number of principal components that extract the linear relationship between spectral parameters and grade from the traditional branch, and the constraints on the hidden layer dimensions of the multilayer perceptron.

[0007] Furthermore, the first smoothing unit employs a local polynomial fitting operator to suppress low-frequency matrix interference in the spectrum and maintain the spectral waveform. The second smoothing unit uses a multi-scale decomposition operator combined with a wavelet basis to remove high-frequency spectral noise.

[0008] Furthermore, in step 1, the dynamic weight allocation based on physical constraints includes: designing dynamic weight allocation based on the signal-to-noise ratio of the output spectra of the first smoothing unit and the second smoothing unit.

[0009] Furthermore, the preprocessing module also includes a constraint unit and an anomaly spectrum fault-tolerant unit; The constraint unit performs amplitude consistency constraints and baseline correction on the fused spectrum output by the fusion unit; The abnormal spectrum fault-tolerant unit performs signal-to-noise ratio validity verification on the fused spectrum output by the constraint unit.

[0010] Furthermore, the traditional branch extracts the intensity, width, and area of ​​the characteristic peaks of lead and zinc in the lead-zinc spectrum as spectral parameters, and uses linear and nonlinear mapping to obtain the linear and nonlinear features of the spectral parameters and grade. The linear and nonlinear features are then spliced ​​together and their dimensions are unified to obtain the query features.

[0011] Furthermore, the depth branch uses convolutional layers with different kernel sizes to extract peak features at different scales in the lead-zinc spectrum, and splices and adds the peak features at different scales to obtain multi-scale features. The multi-scale features are then compressed and reduced in dimensionality and linearly mapped to obtain value features and bond features.

[0012] Furthermore, the weak peak weighting module generates a peak weight mask based on the weak peak region in the lead-zinc spectrum after industrial calibration, and performs weak peak enhancement weighting on the features corresponding to the weak peaks in the fusion features output by the multi-head fusion module based on the peak weight mask.

[0013] Furthermore, the weak peak regions in the industrially calibrated lead-zinc spectrum are defined as follows: the weak peak wavelength of lead is between 400.7 nm and 410 nm, and the weak peak wavelength of zinc is between 329.5 nm and 339.5 nm.

[0014] Furthermore, an objective function is constructed based on the prediction error between the lead-zinc grade prediction results and the actual grade, the spectral quality score, and the feature effectiveness. This objective function is expressed by the following formula: ; in, This represents the total value of the objective function; Indicates prediction error; Indicates the spectral quality score; Indicates feature validity; This represents the corresponding weighting coefficient.

[0015] Through the above design, the prediction accuracy, spectral quality, and feature effectiveness are synergistically optimized, and all parameters are adapted to industrial field conditions; a multi-module consistency constraint closed-loop control system is constructed to improve the industrial robustness and stability of the system.

[0016] Furthermore, constraints are set for the objective function in multiple dimensions, and the minimum value of the objective function is obtained under the constraints. The multiple dimensions include: prediction error, spectral quality score, feature validity, single model inference time, weight coefficients, window size parameters of the preprocessing module, and the number of multi-head attention heads in the multi-head fusion module.

[0017] Furthermore, the spectral quality score is obtained by weighted fusion calculation of the signal-to-noise ratio score and the elemental peak quality score; The signal-to-noise ratio score is obtained based on the spectral signal-to-noise ratio combined with normalization calculation; The elemental peak quality score is the average of the single peak quality scores for lead and zinc elements. The single peak quality score is calculated based on the intensity, area, and full width at half maximum (FWHM) of the single element characteristic peak.

[0018] Furthermore, the validity of the features is obtained by calculating the correlation between the fused features output by the multi-head fusion module and the real labels.

[0019] Furthermore, it also includes a consistency constraint closed-loop control module. When the prediction error or spectral quality score does not meet the constraint conditions, the consistency constraint closed-loop control module performs parameter recalibration of the preprocessing module and the prediction model, obtains a second parameter set, and adjusts the corresponding parameters of the preprocessing module and the prediction model based on the second parameter set.

[0020] Furthermore, the recalibration of parameters in the preprocessing module and the prediction model when the prediction error and spectral quality score do not meet the constraints includes: If the predicted lead and zinc grades exceed the preset reasonable range, the parameters of the prediction model will be recalibrated through the verification unit. If the spectral quality is lower than the preset value, the parameters of the preprocessing module are recalibrated through the verification unit.

[0021] Beneficial effects: This invention provides a lead-zinc grade prediction method based on LIBS spectroscopy. The dual smoothing physical synergy of the preprocessing module resolves the contradiction between peak shape preservation and noise suppression, and improves the spectral signal-to-noise ratio to ≥30dB. By dividing the extraction work between traditional branches and deep branches, complementary fusion of linear and nonlinear features and peak-shaped features is achieved; by combining industrial calibration and multi-head attention fusion, the ability to characterize weak peak features is enhanced to meet the high-precision requirements of industrial control. Meanwhile, constraints were designed for scenarios with high matrix content, further improving the prediction accuracy for challenging scenarios. Attached Figure Description

[0022] Figure 1 This is a schematic flowchart of a lead-zinc grade prediction method based on LIBS spectroscopy according to an embodiment of the present invention. Detailed Implementation

[0023] The technical solution of the present invention will be clearly and completely described below. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0024] Unless otherwise defined, the technical or scientific terms used in this invention shall have the ordinary meaning understood by one of ordinary skill in the art to which this invention pertains. The terms "first," "second," and similar terms used in this invention do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Similarly, the terms "an" or "a" and similar terms do not indicate a quantity limitation, but rather indicate the presence of at least one. The terms "connected" or "linked" and similar terms are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. "Up," "down," "left," "right," etc., are used only to indicate relative positional relationships; when the absolute position of the described object changes, the relative positional relationship also changes accordingly.

[0025] Please see Figure 1 This application provides a method for predicting lead and zinc grades based on LIBS spectroscopy, comprising the following steps: Step 1: Construct a first smoothing unit that suppresses low-frequency matrix interference and preserves the spectral waveform; construct a second smoothing unit that removes high-frequency noise from the spectrum; construct a fusion unit based on physical constraints and dynamic weight allocation to fuse the output spectra of the first and second smoothing units; and construct a preprocessing module based on the first smoothing unit, the second smoothing unit, and the fusion unit. The first smoothing unit uses a local polynomial fitting operator to suppress low-frequency matrix interference and preserve the spectral waveform. The local polynomial fitting operator can be Savitzky-Golay (SG) smoothing or other smoothing algorithms with peak shape preservation capabilities. Its core physical mechanism is to preserve physical parameters such as amplitude and width of characteristic peaks through local polynomial fitting, thereby avoiding peak distortion. This is a unique physical function of this type of operator, which cannot be achieved by other noise suppression smoothing operators. The second smoothing unit uses a multi-scale decomposition operator combined with a wavelet basis to remove high-frequency noise in the spectrum. Here, the preferred wavelet basis is the db series wavelet, while the multi-scale decomposition operator can be implemented using wavelet threshold smoothing or other smoothing algorithms with high-frequency noise suppression capabilities. Its core physical mechanism is to separate high-frequency noise from low-frequency peak signals through multi-scale decomposition and specifically remove high-frequency noise. This is a unique physical function of the operator, which cannot be achieved by peak-preserving smoothing operators. The physical constraints described in the fusion unit refer to the dynamic weight allocation based on the signal-to-noise ratio of the output spectra of the first and second smoothing units, which achieves physical synergistic optimization of peak shape preservation and noise suppression, rather than simple numerical weighting. The synergistic mechanism is as follows: peak shape preservation smoothing provides the "physical basis of true peak shape", and noise suppression smoothing provides the "low noise spectral environment". The two must be fused in this way to obtain high-quality spectra with "true peak shape and low noise" at the same time.

[0026] The preprocessing module is constructed here by a first smoothing unit, a second smoothing unit, and a fusion unit. In this embodiment, the preprocessing module also includes a constraint unit and an abnormal spectrum fault-tolerant unit. The constraint unit performs amplitude consistency constraints and baseline correction on the fused spectrum output by the fusion unit. The amplitude consistency constraint on the fused spectrum eliminates the differences in spectral amplitude caused by different ore matrices, and achieves physical consistency of spectral amplitude, providing a unified amplitude benchmark for subsequent feature extraction, rather than simply numerical standardization. Then, baseline interference is removed through baseline correction. The baseline correction here can adopt the adaptive iterative reweighted penalized least squares method or other industrially adapted baseline correction methods. The abnormal spectrum fault-tolerant unit performs signal-to-noise ratio validity verification on the fused spectrum output by the constraint unit. The validity verification here is performed in the form of a threshold, removing abnormally low signal-to-noise ratio spectra and retaining spectra with a signal-to-noise ratio greater than the preset value.

[0027] Step 2: Construct a traditional branch for extracting the linear and nonlinear relationships between spectral parameters and target grade; construct a deep branch based on multi-scale convolution to extract peak shape features in the spectrum; use the output of the traditional branch as the query branch of multi-head attention; use the output of the deep branch as the key branch and value branch of multi-head attention to construct a multi-head fusion module; construct a weak peak weighting module based on weak peak regions in the lead-zinc spectrum after industrial calibration and attention weighting; and construct a prediction model based on the traditional branch, deep branch, multi-head fusion module, weak peak weighting module, and multilayer perceptron. In this method, the intensity, width, and area of ​​the characteristic peaks of lead and zinc in the lead-zinc spectrum after preprocessing by the traditional branch extraction module are used as spectral parameters. The extracted spectral parameters of lead and zinc respectively achieve decoupling of overlapping peaks, eliminate feature confusion caused by peak overlap, and provide a physical basis for the subsequent extraction of linear and nonlinear features. The traditional branch normalizes the amplitude of spectral parameters to eliminate the differences in peak parameter scale and avoid the drift of the amplitude of the special vibration. Then, it uses linear mapping to obtain the linear characteristics of spectral parameters and grade, and uses nonlinear mapping to obtain the linear and nonlinear characteristics of spectral parameters and grade. The linear and nonlinear characteristics are then spliced ​​together and the dimensions are unified to obtain the query features. The deep branch uses convolutional layers with different kernel sizes to extract peak features at different scales in the lead-zinc spectrum. The peak features at different scales are then concatenated and added to obtain multi-scale features. Peak feature compression and dimensionality reduction and linear mapping are then performed on the multi-scale features to obtain value features and key features. It should be noted that the value features and key features here are obtained after the multi-scale features are compressed, reduced in dimensionality and linearly mapped. That is, the value features and key features are essentially the same. The distinction is only made here for the subsequent multi-head fusion module.

[0028] Therefore, based on the traditional branch to obtain query features, it carries the "grade mapping prior" to extract the linear / nonlinear mapping relationship between peak parameters and grade, and has the ability to accurately query "grade-related features". If the output of the deep branch is used as the query feature, since it does not have the "grade mapping prior", it cannot accurately locate the effective features related to grade, which will cause the fused features to deviate from the grade prediction target and the prediction error to increase significantly. Based on the deep branch to obtain value features and key features; The value features and key features obtained by the deep branch carry the "physical prior of peak shape". Only the deep branch can extract multi-scale peak shape details and has the ability to provide "effective peak shape support" for query features. If the output of the traditional branch is used as key / value features, it will not be able to match the query requirements of the query features due to its lack of peak shape details. This will result in weak peak features not being recognized and the fusion effect will be greatly reduced. The collaborative division of labor between traditional branches and deep branches realizes the complete logic of "grade mapping prior query - peak shape physical prior support", forming an irreplaceable synergistic effect.

[0029] After the multi-head fusion module merges the query features, value features, and key features, the weak peak weighting module then applies weak peak weighting to the merged features to form the final merged features. The weak peak weighting process of the weak peak weighting module includes: generating a peak weight mask based on the weak peak region in the lead-zinc spectrum after industrial calibration, and performing weak peak enhancement weighting on the features corresponding to the weak peaks in the fusion features output by the multi-head fusion module based on the peak weight mask; After industrial calibration, the weak peak regions in the lead-zinc spectrum are defined as the weak peak wavelengths of lead between 400.7 nm and 410 nm, and the weak peak wavelengths of zinc between 329.5 nm and 339.5 nm. The definition of the weak peak regions is based on the physical laws of lead-zinc spectra and cannot be replaced by conventional attention weighting. Therefore, this method cannot be transferred to the prediction of the spectral grade of other elements such as copper and iron.

[0030] The final fused features, after weak peak weighting, are input into a multilayer perceptron for prediction, thereby obtaining the lead-zinc grade prediction results.

[0031] The objective function is constructed based on the prediction error between the predicted lead-zinc grade output of the prediction model and the actual grade, the spectral quality score, and the effectiveness of the features. The objective function is expressed by the following formula: ; in, This represents the total value of the objective function; Indicates prediction error; Indicates the spectral quality score; Indicates feature validity; This represents the corresponding weighting coefficient.

[0032] Constraints are set for the objective function in multiple dimensions, and the minimum value of the objective function is obtained under the constraints. The constraints here are in the form of thresholds, set values, and formula restrictions. Specifically, thresholds are set for prediction error, spectral quality score, feature validity, and single model inference time. Formula restrictions are set for weight coefficients, and value ranges are set for the window size parameter of the preprocessing module and the number of multi-head attention heads of the multi-head fusion module. In this embodiment, the prediction error is set to less than or equal to 0.1%, the spectral quality score is set to greater than 0.8, the feature validity is set to greater than or equal to 0.85, and the single model inference time is set to less than or equal to 100ms. Weighting coefficients are set to ,and Greater than or equal to 0.6; Window size parameters in parameter set The value is taken from the parameter set, and the number of multi-head attention heads is within the parameter set. Take the value from the middle.

[0033] In other embodiments, when the ore matrix accounts for more than 50%, it is considered a complex working condition, and the prediction error can be further constrained to less than or equal to 0.08%.

[0034] The objective function design achieves synergistic constraints on prediction accuracy, spectral quality, feature effectiveness, and online real-time performance, solving the problem of mismatch between traditional single-objective optimization and industrial scenarios. It significantly improves the operational stability, anti-interference ability, and engineering application value of the online detection system under high matrix ore conditions.

[0035] In the objective function and the set constraints, the spectral quality score is obtained by a weighted fusion calculation of the signal-to-noise ratio score and the elemental peak quality score, as expressed by the following formula: ; in, Represents the spectrum Spectral quality score; Represents the spectrum Signal-to-noise ratio score; Indicates the elemental peak quality score; The signal-to-noise ratio score is obtained based on the spectral signal-to-noise ratio combined with normalization calculation, and is expressed by the following formula: ; in, Indicates the spectral signal-to-noise ratio; and These represent the maximum and minimum values ​​of the spectral signal-to-noise ratio, respectively. The spectral signal-to-noise ratio is calculated using the following formula: ; in, Commonly used logarithms to the base 10; The average intensity of the characteristic peak, This represents the baseline noise standard deviation.

[0036] The elemental peak quality score is the average of the single peak quality scores for lead and zinc, expressed by the following formula: ; in, Represents the spectrum Element peak quality score; This indicates the single-peak quality score for lead. This indicates the single-peak quality score for zinc. The single-peak quality score for any element is calculated based on the intensity, area, and full width at half maximum (FWHM) of the characteristic peak of that element. Here, we take the single-peak quality score of lead as an example and calculate it using the following formula: ; in, Represents the spectrum Characteristic peak intensity of lead in medium concentration; Represents the spectrum Peak area of ​​lead in the middle octane; Represents the spectrum The full width at half maximum (FWHM) of the characteristic peaks of lead in medium-sized elements; This represents the corresponding weighting coefficient.

[0037] Feature validity is calculated based on the correlation between the fused features output by the multi-head fusion module and the true labels, and is expressed by the following formula: ; in, For the first Dimensional fusion features For accurate labeling of lead and zinc grades. For the correlation coefficient function, To integrate the total dimension of features.

[0038] It also includes a verification unit, which sets constraints on the parameters of each unit and module in the preprocessing module and the prediction model based on industrial functions, calibrates the preprocessing module and the prediction model based on the constraints to obtain a first parameter set, and covers the corresponding parameters of the preprocessing module and the prediction model with the first parameter set. The parameters of the preprocessing module include the smoothing window size parameter; The parameters of the prediction model include the number of multi-head attention heads and dropout rate of the multi-head fusion module, the number of principal components that extract the linear relationship between spectral parameters and grade from the traditional branch, and the constraints on the hidden layer dimensions of the multilayer perceptron.

[0039] It should be noted that the constraints are also set in the form of thresholds and value sets. The specific settings are based on industrial adaptation, but they need to be set under the constraints corresponding to the objective function. This achieves a dual parameter verification effect, that is, calibration is performed by the verification unit before model training, and then the parameters are determined under the constraints of the objective function.

[0040] The consistency constraint closed-loop control module performs parameter recalibration of the preprocessing module and the prediction model when the prediction error or spectral quality score does not meet the constraint conditions, obtains a second parameter set, and adjusts the corresponding parameters of the preprocessing module and the prediction model based on the second parameter set. When the prediction error and spectral quality score do not meet the constraints, the parameters of the preprocessing module and the prediction model are recalibrated, including: If the predicted lead and zinc grades exceed the preset reasonable range, the parameters of the prediction model will be recalibrated through the verification unit. If the spectral quality is lower than the preset value, the parameters of the preprocessing module will be recalibrated through the verification unit. Here, closed-loop parameter calibration is implemented from the verification unit (before training) - the constraint conditions of the objective function (during training) - the consistency constraint closed-loop control (during training) - the verification unit (during training) to ensure the accuracy of the lead-zinc grade prediction output by the final prediction model.

[0041] In the final deployment phase, the parameters are set as follows: Industrial parameter verification: smoothing window size Attention count , principal component number Hidden layer dimensions dropout rate ; Preprocessing module: SG smoothing polynomial order small wavelet Wavelet decomposition layer number The threshold mode is a soft threshold, and the signal-to-noise ratio adaptively fuses the weights. , Dynamic allocation, baseline correction threshold Spectral effectiveness threshold ; Statistical Branch and Depth Branch: Deconvolution Kernel The characteristic wavelength of Pb is calibrated using a Gaussian kernel (variance 0.5). Zn characteristic peak calibration wavelength Feature unification dimension Multi-scale convolution kernel size set Number of output channels ; Multi-head fusion module: Weak peak weighting enhancement coefficient The weak peak characteristic region of Pb is from 400.7 nm to 410.7 nm, and the weak peak characteristic region of Zn is from 329.5 nm to 339.5 nm.

[0042] Step 3: Obtain the lead-zinc spectrum from the industrial site, and smooth the lead-zinc spectrum through the preprocessing module to obtain the first spectrum, signal-to-noise ratio, and dynamic weights. Input the first spectrum, signal-to-noise ratio, and dynamic weights into the prediction model to obtain the lead-zinc grade prediction results corresponding to the lead-zinc spectrum.

[0043] In this embodiment, a control module can also be set up for the lead-zinc grade prediction results output by the prediction model. This control module is used to realize functions such as closed-loop feedback of feedback instructions, generation of log records, industrial-grade format conversion of instructions, permission verification, and multi-interface adaptation, so as to ensure that the prediction results can be connected to the PLC control system and data detection platform of the mining industry site, and realize the full-process industrial implementation of prediction-control-operation and maintenance.

[0044] To verify the technical advantages of the lead-zinc grade prediction method, preprocessing module, and prediction model based on LIBS spectroscopy proposed in this application, the following two sets of existing technical solutions are proposed: Existing Solution 1: It adopts a single SG smoothing preprocessing + a single traditional partial least squares regression model, without a double-branch feature extraction structure, without a multi-head attention fusion module, and without multi-module consistency constraint closed-loop control; Existing Solution 2: It adopts SG+wavelet simple splicing smoothing preprocessing + dual-branch simple splicing fusion + conventional multi-head attention mechanism, without industrial spectral prior embedding and without multi-module consistency constraint closed-loop control; Based on the two existing solutions mentioned above, respectively, the accuracy of lead and zinc grade prediction ( ), spectral anomaly rate, process error rate, prediction accuracy for high matrix content scenarios, and model prediction coefficient of determination ( Using as the core evaluation indicator, and employing a unified environment and data for testing, the following comparison table was obtained: Table 1: Comparison results between this application and existing solutions.

[0045]

[0046] Prediction accuracy and fit verification: The test results show that the average error of the lead / zinc grade prediction in this invention is... Satisfying the industrial-grade objective function Constraints, Model Prediction Determination Coefficient =0.992, close to 1, indicating that the predicted value has a very high degree of fit with the actual ore grade. In contrast, Scheme 1, due to its single model, cannot adapt to the linear-nonlinear mapping relationship between lead-zinc grade and spectral characteristics. The accuracy was only 0.821, with a prediction error of ±0.52%. In contrast, Scheme 2 lacked a physical coordination mechanism for double smoothing and industrial prior embedding for feature fusion, resulting in weak peak features not being effectively enhanced. =0.897, prediction error ±0.35%.

[0047] Spectral anomaly rate verification: The spectral anomaly rate of this invention is only 0.3%, far lower than that of comparative scheme 1 (3.8%) and comparative scheme 2 (1.5%). This result is attributed to the anomaly spectral fault-tolerant unit and consistency constraint closed-loop control module of this invention. The anomaly spectral fault-tolerant unit can accurately eliminate invalid spectra with a signal-to-noise ratio of less than 20dB, and the consistency constraint closed-loop control module can perform real-time calibration of the anomaly prediction results, effectively blocking the propagation and influence of anomaly spectra. In contrast, all comparative schemes lack a complete anomaly tolerance and closed-loop calibration mechanism, resulting in a persistently high spectral anomaly rate, which cannot meet the continuous and stable detection requirements in industrial settings.

[0048] Objective function constraint satisfaction verification: All test results of this invention satisfy the constraints of the industrial-grade objective function, including the spectral quality score. The average value is 0.92, and the feature effectiveness coefficient is... The average value is 0.91, which is higher than... , The constraint thresholds demonstrate that the objective function design of this invention can effectively guide the optimization of parameters of each structural unit, achieving a synergistic improvement in prediction accuracy, spectral quality, and feature effectiveness. In contrast, the comparative schemes did not adopt the industrial-grade objective function of this invention, and thus could not achieve synergistic optimization of multiple industrial indicators, with some indicators failing to meet industrial control requirements.

[0049] 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 method for predicting lead-zinc grade based on LIBS spectroscopy, characterized in that, Includes the following steps: Step 1: Construct a first smoothing unit that suppresses low-frequency matrix interference and preserves the spectral waveform; construct a second smoothing unit that removes high-frequency noise from the spectrum; construct a fusion unit based on physical constraints and dynamic weight allocation to fuse the output spectra of the first and second smoothing units; and construct a preprocessing module based on the first smoothing unit, the second smoothing unit, and the fusion unit. Step 2: Construct a traditional branch for extracting the linear and nonlinear relationships between spectral parameters and target grade; construct a deep branch based on multi-scale convolution to extract peak shape features in the spectrum; use the output of the traditional branch as the query branch of multi-head attention; use the output of the deep branch as the key branch and value branch of multi-head attention to construct a multi-head fusion module; construct a weak peak weighting module based on weak peak regions in the lead-zinc spectrum after industrial calibration and attention weighting; and construct a prediction model based on the traditional branch, deep branch, multi-head fusion module, weak peak weighting module, and multilayer perceptron. Step 3: Obtain the lead-zinc spectrum from the industrial site, and smooth the lead-zinc spectrum through the preprocessing module to obtain the first spectrum, signal-to-noise ratio, and dynamic weights. Input the first spectrum, signal-to-noise ratio, and dynamic weights into the prediction model to obtain the lead-zinc grade prediction results corresponding to the lead-zinc spectrum.

2. The method for predicting lead and zinc grades based on LIBS spectroscopy according to claim 1, characterized in that, It also includes a verification unit, which sets constraints on the parameters of each unit and module in the preprocessing module and the prediction model based on industrial functions, calibrates the preprocessing module and the prediction model based on the constraints to obtain a first parameter set, and covers the corresponding parameters of the preprocessing module and the prediction model with the first parameter set. The parameters of the preprocessing module include the smoothing window size parameter; The parameters of the prediction model include the number of multi-head attention heads and dropout rate of the multi-head fusion module, the number of principal components that extract the linear relationship between spectral parameters and grade from the traditional branch, and the constraints on the hidden layer dimensions of the multilayer perceptron.

3. The method for predicting lead and zinc grades based on LIBS spectroscopy according to claim 1, characterized in that, The first smoothing unit uses a local polynomial fitting operator to suppress low-frequency matrix interference in the spectrum and maintain the spectral waveform; The second smoothing unit uses a multi-scale decomposition operator combined with a wavelet basis to remove high-frequency spectral noise.

4. The method for predicting lead and zinc grades based on LIBS spectroscopy according to claim 1, characterized in that, In step 1, the dynamic weight allocation based on physical constraints includes: designing dynamic weight allocation based on the signal-to-noise ratio of the output spectra of the first smoothing unit and the second smoothing unit.

5. The method for predicting lead-zinc grade based on LIBS spectroscopy according to any one of claims 1-4, characterized in that, The preprocessing module also includes a constraint unit and an abnormal spectrum fault-tolerant unit; The constraint unit performs amplitude consistency constraints and baseline correction on the fused spectrum output by the fusion unit; The abnormal spectrum fault-tolerant unit performs signal-to-noise ratio validity verification on the fused spectrum output by the constraint unit.

6. The method for predicting lead and zinc grades based on LIBS spectroscopy according to claim 1, characterized in that, The traditional branch extracts the intensity, width, and area of ​​the characteristic peaks of lead and zinc in the lead-zinc spectrum as spectral parameters, and uses linear and nonlinear mapping to obtain the linear and nonlinear features of the spectral parameters and grade. The linear and nonlinear features are then spliced ​​together and their dimensions are unified to obtain the query features.

7. The method for predicting lead and zinc grades based on LIBS spectroscopy according to claim 1, characterized in that, The deep branch uses convolutional layers with different kernel sizes to extract peak features at different scales in the lead-zinc spectrum, and splices and adds the peak features at different scales to obtain multi-scale features. The multi-scale features are then compressed and reduced in dimensionality and linearly mapped to obtain value features and bond features.

8. The method for predicting lead and zinc grades based on LIBS spectroscopy according to claim 1, characterized in that, The weak peak weighting module generates a peak weight mask based on the weak peak region in the lead-zinc spectrum after industrial calibration, and performs weak peak enhancement weighting on the features corresponding to the weak peaks in the fusion features output by the multi-head fusion module based on the peak weight mask.

9. The method for predicting lead and zinc grades based on LIBS spectroscopy according to claim 1, characterized in that, The weak peak regions in the industrially calibrated lead-zinc spectra are defined as follows: the weak peak wavelength of lead is between 400.7 nm and 410 nm, and the weak peak wavelength of zinc is between 329.5 nm and 339.5 nm.

10. The method for predicting lead and zinc grades based on LIBS spectroscopy according to claim 2, characterized in that, An objective function is constructed based on the prediction error between the lead-zinc grade prediction results and the actual grade, the spectral quality score, and the feature effectiveness. The objective function is expressed by the following formula: ; in, This represents the total value of the objective function; Indicates prediction error; Indicates the spectral quality score; Indicates feature validity; This represents the corresponding weighting coefficient.

11. The method for predicting lead and zinc grades based on LIBS spectroscopy according to claim 10, characterized in that, Set constraints on the objective function in multiple dimensions, and find the minimum value of the objective function under the constraints; The multiple dimensions include: prediction error, spectral quality score, feature validity, single model inference time, weight coefficients, window size parameters of the preprocessing module, and the number of multi-head attention heads in the multi-head fusion module.

12. The method for predicting lead-zinc grade based on LIBS spectroscopy according to claim 10 or 11, characterized in that, The spectral quality score is obtained by weighted fusion calculation of signal-to-noise ratio score and elemental peak quality score; The signal-to-noise ratio score is obtained based on the spectral signal-to-noise ratio combined with normalization calculation; The elemental peak quality score is the average of the single peak quality scores for lead and zinc elements. The single peak quality score is calculated based on the intensity, area, and full width at half maximum (FWHM) of the single element characteristic peak.

13. The method for predicting lead-zinc grade based on LIBS spectroscopy according to claim 10 or 11, characterized in that, The validity of the features is obtained by calculating the correlation between the fused features output by the multi-head fusion module and the real labels.

14. The method for predicting lead-zinc grade based on LIBS spectroscopy according to claim 13, characterized in that, It also includes a consistency constraint closed-loop control module. When the prediction error or spectral quality score does not meet the constraint conditions, the consistency constraint closed-loop control module performs parameter recalibration of the preprocessing module and the prediction model, obtains a second parameter set, and adjusts the corresponding parameters of the preprocessing module and the prediction model based on the second parameter set.

15. The method for predicting lead-zinc grade based on LIBS spectroscopy according to claim 14, characterized in that, The recalibration of parameters in the preprocessing module and the prediction model when the prediction error and spectral quality score do not meet the constraints includes: If the predicted lead and zinc grades exceed the preset reasonable range, the parameters of the prediction model will be recalibrated through the verification unit. If the spectral quality is lower than the preset value, the parameters of the preprocessing module are recalibrated through the verification unit.