A multi-source data fusion control method for a fertilizer batching process
By using a multi-source data fusion control method, the problem of decreased prediction capability caused by unbalanced data distribution during fertilizer batching was solved, improving the prediction accuracy for special working conditions and the stability of the control system, and achieving efficient and reliable control of the fertilizer batching process.
Patent Information
- Application Number
- CN202611182994.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-05
- Publication Date
- 2026-11-06
AI Technical Summary
In existing fertilizer formulation processes, the model's predictive ability decreases when facing low-frequency special operating conditions due to the uneven distribution of data, making it difficult to ensure the stability and reliability of the control system. Conventional data augmentation methods are also unable to take into account the spatial distribution of data, temporal dynamic characteristics, and actual physical mechanisms.
By constructing a multi-source data fusion control method, process parameters and quality label data are obtained, and sample sets are divided into majority and minority classes. Data augmentation is performed on the minority class sample set, prediction uncertainty and process state similarity are calculated, augmented samples that meet process physical thresholds and material conservation constraints are generated, the sample sets are merged to train the control model, and the output control signal controls the fertilizer batching actuator.
It improves the prediction accuracy and generalization ability for low-frequency special working conditions, reduces the risk of control deviation, and ensures the stability and reliability of fertilizer formulation process.
Smart Images

Figure CN123049113A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of control, and in particular relates to a multi-source data fusion control method for fertilizer batching process. Background Technology
[0002] Fertilizer batching is a core step in fertilizer production, and the precision of its proportioning control directly affects product quality, nutrient content, and overall production efficiency. With the development of industrial data acquisition and intelligent control technologies, data-driven process control methods have been widely applied to fertilizer batching systems. In actual production, control systems typically collect a large amount of process parameters and corresponding quality label data to build predictive and control models, and then issue intelligent adjustment commands to the batching execution mechanism accordingly. Because the actual production process operates under normal and stable conditions for extended periods, production states that can cause specific quality fluctuations or correspond to special operating conditions occur infrequently. This results in a significant imbalance in the distribution of historical operating data, with a large number of samples in the majority class and an insufficient number of samples reflecting the critical few operating conditions.
[0003] If unbalanced operating data is directly used for model training, the model is prone to bias towards the majority class samples, which have a numerical advantage. This makes it difficult to fully identify and learn the key process features contained in the minority class samples, thus reducing the predictive ability of the control system under abnormal or special operating conditions, and even causing the output of control signals that deviate from actual needs, affecting the stability of the batching process. Although data sampling or data augmentation methods can compensate for the lack of minority class samples in terms of quantity, the fertilizer batching process has clear industrial constraints. There are strong coupling relationships between the process parameters, and it is subject to strict process physical boundaries and material conservation conditions. Conventional sample generation methods cannot simultaneously consider the spatial distribution of data, temporal dynamic characteristics, and actual physical mechanisms, easily generating invalid samples that do not conform to the real process constraints. This reduces the reliability of the process control model and makes it difficult to ensure the stable and reliable control of the fertilizer batching actuator. Summary of the Invention
[0004] To improve the adaptability of data-driven fertilizer batching control systems to low-frequency special operating conditions, one or more embodiments of the present invention provide a multi-source data fusion control method for the fertilizer batching process, comprising the following steps:
[0005] Obtain operational data containing process parameters and quality labels, and divide the data into majority and minority sample sets based on the labels; The minority class sample set data is augmented, a prediction model is constructed to integrate and calculate the prediction uncertainty of each minority class sample, and normalize it to relative uncertainty. The average feature importance of process parameters is extracted, and at least two key process parameters are selected accordingly. The process state similarity is calculated by combining the first-order time derivative of the key process parameters within a preset time window and the spatial geometric distance between samples. The number of nearest neighbors proportional to the relative uncertainty is determined. Nearby samples are selected for the sample based on the process state similarity. The covariance matrix is calculated based on the distribution of the nearest neighbors in the dimensionless parameter space. The feature vectors are randomly combined to generate a probabilistic augmentation direction. The number of augmented samples to be generated is determined according to the relative uncertainty. Initial augmented samples are generated in the dimensionless parameter space along the line connecting the sample and the nearest neighbor samples, and translated and corrected along the probabilistic augmentation direction. After inverse dimensionlessization, the batching component parameters under a unified quality benchmark and a unified sampling period are subjected to boundary-based proportional scaling projection to satisfy the process physical threshold and material conservation constraints, resulting in a new augmented sample set. The majority class sample set, minority class sample set, and newly added augmented sample set are merged to obtain a balanced dataset, which is used to train the batching process control model. The model is then used to output control signals to control the fertilizer batching actuator based on the current process parameters.
[0006] One or more embodiments of the present invention also provide a multi-source data fusion control system for a fertilizer formulation process, comprising the following modules: The acquisition module is used to acquire operational data containing process parameters and quality labels, and divides the data into majority and minority sample sets according to the labels. The calculation module is used to augment the minority class sample set data, construct a prediction model to integrate and calculate the prediction uncertainty of each minority class sample, normalize it to relative uncertainty, extract the average feature importance of process parameters, select at least two key process parameters accordingly, combine the first-order time derivative of the key process parameters within a preset time window and the spatial geometric distance between samples to calculate the process state similarity, determine the number of nearest neighbors proportional to the relative uncertainty, select nearest neighbor samples for the sample based on the process state similarity, calculate the covariance matrix based on the distribution of the nearest neighbor samples in the dimensionless parameter space, randomly combine their feature vectors to generate a probabilistic augmentation direction, determine the number of augmented samples to be generated based on the relative uncertainty, generate initial augmented samples in the dimensionless parameter space along the line connecting the sample and the nearest neighbor samples, and translate and correct along the probabilistic augmentation direction. After inverse dimensionlessization, perform boundary-based proportional scaling projection on the batching component parameters under a unified quality benchmark and a unified sampling period to satisfy the process physical threshold and material conservation constraints, and obtain a new augmented sample set. The control module is used to merge the majority class sample set, minority class sample set and newly added augmented sample set to obtain a balanced dataset, train the batching process control model, and output control signals to control the fertilizer batching actuator according to the current process parameters.
[0007] This invention constructs a model to integrate and calculate the prediction uncertainty of minority class samples, and combines the temporal variation trend and spatial distance of key process parameters to evaluate the similarity of process states, ensuring that the selection depth of nearest neighbor samples closely matches the actual physical laws of chemical processes. The relative uncertainty is used to directionally determine the number of nearest neighbors and augmented samples, tilting the focus of data generation towards samples that are difficult to predict. Probabilistic augmentation directions are generated based on the eigenvectors of the covariance matrix and translated for correction, enriching the diversity of sample distribution. Boundary-constrained projection using process physical threshold boundaries and material conservation constraints reduces the probability of generating invalid samples that do not conform to the actual batching mechanism and objective conditions. The above process yields a higher-quality balanced dataset, improving the prediction accuracy and generalization ability of the batching control model for low-frequency special operating conditions, and reducing the risk of control deviation caused by uneven sample distribution. Attached Figure Description
[0008] Figure 1 A flowchart of a multi-source data fusion control method for a fertilizer formulation process; Figure 2 This is a schematic diagram showing the distribution of nearest neighbor samples and the direction of augmentation. Figure 3 This is a schematic diagram of sample translation correction. Detailed Implementation
[0009] It should be understood that, when used in this application specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or a collection thereof.
[0010] It should also be understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0011] In the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0012] References to "one embodiment" or "some embodiments" as described in this application specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in another embodiment," "in yet another embodiment," etc., appearing in different parts of this application specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof all mean "including but not limited to," unless otherwise specifically emphasized.
[0013] This specification provides one or more embodiments of a multi-source data fusion control method for a fertilizer formulation process, such as... Figure 1 As shown, it includes the following steps: S1: Obtain operational data containing process parameters and quality labels, and divide the data into majority and minority sample sets according to the labels.
[0014] Historical fertilizer production data is read from a programmable logic controller (PLC), a field flow meter and electronic batching scale, a quality inspection system, and a production management system. The PLC provides target signals for reactor temperature, stirring speed, and batching actuator control. The field flow meter and electronic batching scale provide liquid ammonia flow rate, phosphate flow rate, and potassium salt feed rate. The quality inspection system provides at least one continuous quality test value among product moisture content and total nitrogen content. The production management system provides production batch number, target total feed rate, and formula standard data. The above data are associated with the same sample record based on the production batch number and sampling timestamp, and different... Data from the sampling frequency is resampled to a unified time axis. When multiple sources record the same process parameter, conflicting values are selected according to the priority of field metering instruments, programmable logic controllers, and production management systems, or a weighted average is used for fusion when the difference is less than a preset allowable deviation. Historical data is loaded into a data frame format. Process parameters include reaction tank temperature, stirring speed, liquid ammonia flow rate, phosphoric acid flow rate, and potassium salt feed rate. These process parameters include parameters of the batching components that participate in material conservation constraints and parameters of non-batching components that do not participate in material conservation constraints. The batching component parameters include liquid ammonia flow rate, phosphoric acid flow rate, and potassium salt feed rate. Quality labels include at least one continuous quality detection value of product moisture content and total nitrogen content, as well as a qualified or unqualified product category mark obtained by comparing the continuous quality detection value with a preset quality standard. The operating data also includes the control target signal of the batching actuator corresponding to the historical samples. Missing values in the historical data are repaired using the mean-filling method. An isolated forest algorithm model is used to identify and remove outlier data points. Based on the conditional filtering function of the data frame, and combined with quality labels, formula change records, and historical correction records, data sample rows marked as qualified products and belonging to normal stable operating conditions are divided into a majority class sample set. Data sample rows corresponding to quality boundary conditions, special formula change conditions, or low-frequency conditions with historical non-conformities but effective correction records are divided into a minority class sample set. The minority class samples are used to characterize low-frequency special operating conditions, and their original historical control target signals are not directly used as the desired control behavior.
[0015] S2, augment the minority class sample set data, construct a prediction model to integrate and calculate the prediction uncertainty of each minority class sample, and normalize it to relative uncertainty. Extract the average feature importance of process parameters, select at least two key process parameters accordingly, combine the first-order time derivative of the key process parameters within a preset time window and the spatial geometric distance between samples to calculate the process state similarity, determine the number of nearest neighbors proportional to the relative uncertainty, select nearest neighbor samples for the sample based on the process state similarity, calculate the covariance matrix based on the distribution of the nearest neighbor samples in the dimensionless parameter space, randomly combine their feature vectors to generate probabilistic augmentation directions, and determine the number of augmented samples to be generated based on the relative uncertainty. Generate initial augmented samples in the dimensionless parameter space along the line connecting the sample and the nearest neighbor samples, and translate and correct along the probabilistic augmentation direction. After inverse dimensionlessization, perform boundary-based proportional scaling projection on the batching component parameters under a unified quality benchmark and a unified sampling period to satisfy the process physical threshold and material conservation constraints, and obtain the new augmented sample set.
[0016] For the minority class sample set, a prediction model ensemble containing 50 decision tree-based learners is constructed using random forest regression. The model ensemble is then used to perform leave-one-out cross-validation prediction on the minority class samples. At least one continuous quality detection value among product moisture content and total nitrogen content is used as the regression prediction target. The variance of the prediction results of the 50 base learners is calculated. When the regression prediction target includes both product moisture content and total nitrogen content, the prediction variance of each continuous quality detection value in the output results of each base learner is calculated separately. The prediction variances are then normalized and weighted according to the preset quality index weights to obtain a single prediction uncertainty. The prediction variance of a single objective or the result of a weighted fusion of multiple objectives is used as the prediction uncertainty for each minority class sample. The range normalization of the prediction uncertainties for all minority class samples yields the relative uncertainty. The feature importance attributes of each base learner are then used to calculate the average feature importance of the fifty base learners on each process parameter. These are then sorted from largest to smallest average feature importance value, and key process parameters are selected based on an importance threshold. In a specific example, the top three process parameters are selected as key process parameters. Figure 2 As shown, the black arrows correspond to the interpolation direction, and the light gray arrows correspond to the data augmentation direction. All parameters are mapped to a dimensionless parameter plane, and the two types of directions originate from the same point, forming vectors with different directions in space.
[0017] Calculate the first-order time derivative of each key process parameter within a preset time window consisting of five past sampling points. The first-order time derivative is obtained by dividing the parameter difference between adjacent sampling points by the corresponding sampling time interval. First, the process parameters of the sample and other samples are dimensionless. Then, the Euclidean distance between the sample and other samples in the feature space is calculated as the spatial geometric distance. The first-order time derivatives of each sample are combined into a time derivative vector. The cosine similarity between the time derivative vectors of the sample and other samples is calculated and mapped to the non-negative interval. At the same time, the reciprocal of the Euclidean distance is normalized. The non-negative cosine similarity and the normalized reciprocal of the Euclidean distance are weighted and summed according to preset weights to obtain the process state similarity between the sample and other samples. Set the baseline value of the number of nearest neighbors to 3 and the adjustment coefficient to 7. Add the product of the adjustment coefficient and the relative uncertainty of the sample to the baseline value and round down to determine the number of nearest neighbors of the sample.
[0018] Sort the samples in descending order of process state similarity. Compare the calculated number of nearest neighbors with the number of available samples in the minority class sample set excluding the current sample, and take the minimum of the two as the actual number of nearest neighbors. Extract the index position corresponding to the actual number of nearest neighbors and use the corresponding sample as the nearest neighbor sample. Perform zero-mean unit variance standardization on the process parameters of the sample and its nearest neighbors, mapping them to a dimensionless parameter space. Calculate the covariance matrix of the nearest neighbors in the dimensionless parameter space, perform eigenvalue decomposition on the covariance matrix to obtain all eigenvectors, and use the normal function to generate random numbers following a standard normal distribution as... The weights are calculated by multiplying each random weight by the square root of its corresponding eigenvalue and using the result as the weighting coefficient of the eigenvector. A linear weighted combination is then applied to all eigenvectors to generate probabilistic augmentation directions. The target augmentation amount is determined based on the difference between the number of majority class samples and the number of minority class samples. When the prediction uncertainty of all minority class samples is the same or the range is zero, the relative uncertainty of each minority class sample is set to the same preset value, and the number of augmented samples to be generated is evenly distributed according to the number of minority class samples. When there are differences in prediction uncertainty, the number of augmented samples to be generated is distributed according to the proportion of the relative uncertainty of each minority class sample, generating random interpolation coefficients between 0 and 1.
[0019] In the dimensionless parameter space, the parameter vector of the target nearest neighbor sample is subtracted from the parameter vector of the target sample to obtain the direction vector of the line connecting the target nearest neighbor sample. The direction vector of the line is multiplied by a random interpolation coefficient and added to the parameter vector of the target sample to generate an initial augmented sample. The translation step size coefficient is set to 0.1. The relative uncertainty is multiplied by the translation step size coefficient to obtain the dimensionless translation distance. The norm of the probabilistic augmented direction vector is calculated. The probabilistic augmented direction vector is divided by the norm of the vector, normalized, and then multiplied by the translation distance. This is added to the parameter vector of the initial augmented sample to complete the translation correction. The augmented sample after translation correction is inversely transformed to restore the original physical dimensions. Based on the upper and lower limits of the reaction tank temperature and the process physical threshold composed of the flow meter range, the non-feeding component parameters are boundary-limited according to the preset process physical threshold. The system implements a bounded, proportional scaling projection on three ingredient parameters—liquid ammonia flow rate, phosphoric acid flow rate, and potassium salt feed rate—converted to the same sampling period. This ensures that each ingredient parameter satisfies material conservation constraints within its corresponding process physical threshold range. It iteratively traverses all minority class samples to generate a specified number of samples, ensuring that newly augmented samples inherit the category labels of their source minority class samples. Based on the augmented sample parameters after translation correction and constraint projection, and combined with the distance weights between the source samples and the target nearest neighbor samples, continuous quality detection values are regenerated. The control target signal of the batching execution mechanism is generated based on the formula standard data, quality deviation direction, and historical effective correction records. It does not directly inherit the original historical control target signal corresponding to the non-conforming samples. Together with the original minority class samples, these signals form the newly augmented sample set. Figure 3 As shown, the solid black line represents the translation correction process. The gray dots are the original samples, the gray squares are the initial augmented samples, and the black pentagrams are the augmented samples after the translation correction operation.
[0020] In one embodiment, the construction of the prediction model integrates the calculation of the prediction uncertainty of each minority class sample, normalizes it to a relative uncertainty, and extracts the average feature importance of process parameters, including: The samples from the minority class sample set are respectively input into the multiple base decision tree models included in the prediction model integration to obtain multiple process prediction values; Calculate the variance of the multiple process prediction values. When the process prediction value is a multidimensional continuous quality detection value, calculate the prediction variance of each dimension and normalize and weight the sum. Use the obtained scalar variance value as the prediction uncertainty of the sample. Obtain the maximum and minimum values of the prediction uncertainty of all minority class samples. When the maximum value is greater than the minimum value, use the maximum and minimum values to perform range normalization on the prediction uncertainty of the sample to obtain the relative uncertainty of the sample. When the maximum value is equal to the minimum value, set the relative uncertainty of each minority class sample to the same preset value. The process parameters of each process in each base decision tree model are used as the impurity reduction value brought about by the split node; The impurity reduction values corresponding to the same process parameter in all base decision tree models are summed, and the average value is calculated as the average feature importance of each process parameter.
[0021] Construct a base decision tree model containing a preset number, such as a random forest of CART regression trees, with 100 trees as an example, as the prediction model ensemble. For a specific sample in the minority class sample set, extract M process parameters contained in the sample, such as granulation temperature, inlet pressure, main material flow rate, and return ratio. M can be set to 15. Input these parameters in parallel into the 100 base decision tree models for inference to obtain 100 independent process prediction values for continuous quality detection values, such as process prediction values for product moisture content or total nitrogen content, for example, predicted distribution between 45.2% and 48.5%. Calculate the unbiased variance of these 100 prediction values. Use this variance value, for example, a variance of 1.25, as the prediction uncertainty of the current model for this sample. Then obtain the maximum and minimum values of the prediction uncertainty of all minority class samples, and perform range normalization on the current prediction uncertainty to obtain the relative uncertainty of the current sample.
[0022] Traverse all non-leaf nodes in the topology of each base decision tree, calculating the mean squared error reduction (MSE) when any process parameter is used as a splitting feature. For example, if the parameter "granulator inlet temperature" appears as a splitting node three times in the first tree, with each occurrence contributing an MSE reduction of 0.05, 0.03, and 0.02 respectively, the cumulative reduction for that single tree is 0.10. Sum the reduction values of this parameter across all 100 trees, assuming a total sum of 8.5, and then divide by the total number of base trees (100) to obtain an average value of 0.085. Use this value as the average feature importance of the process parameter. Repeat this process for all process parameters to construct a feature importance score vector.
[0023] In one embodiment, the selection of at least two key process parameters accordingly includes: All process parameters are sorted in descending order of their average characteristic importance. Calculate the arithmetic mean of the average characteristic importance of all process parameters as the importance threshold; After traversing and sorting the process parameters, process parameters with an average feature importance greater than the importance threshold are identified as key process parameters. When the number of process parameters greater than the importance threshold is less than two, the top two process parameters in descending order are selected as key process parameters.
[0024] After obtaining the average feature importance of all process parameters across all dimensions, assuming there are a total of 12 process parameters, these are arranged in descending order of importance, forming a monotonically decreasing ordered sequence. An example numerical sequence is [0.25, 0.18, 0.12, 0.10, 0.08, 0.07, 0.05, 0.04, 0.04, 0.03, 0.02, 0.02]. Traversing this sequence, all importance values within the sequence are linearly summed and divided by the total number of parameter dimensions (12) to calculate the arithmetic mean. Based on the example above, the arithmetic mean is approximately 0.0833, and this arithmetic mean is used as the importance threshold for subsequent feature selection.
[0025] Using a calculated threshold of 0.0833, the process parameters are iterated through in descending order. Parameters with importance values greater than this threshold (the top four in this example, with values of 0.25, 0.18, 0.12, and 0.10, respectively) are selected as critical process parameters. These parameters include variables such as the instantaneous flow rate of the main material belt scale and the secondary mixing speed. When fewer than two parameters have importance values greater than the threshold (for example, the top-ranked parameter with an importance value as high as 0.90 raises the average value, resulting in only that parameter having a value greater than the threshold), the two highest-ranking process parameters in the sorted list are selected as critical process parameters. This mechanism ensures that subsequent modules have a two-dimensional or higher parameter base when performing spatial distance measurements, maintaining the continuity of the algorithm.
[0026] In one embodiment, calculating the process state similarity by combining the first-order time derivative of the key process parameters within a preset time window and the spatial geometric distance between samples includes: After dimensionless processing of the process parameters of the sample and other samples, the Euclidean distance between the sample and other samples in the multidimensional parameter space is calculated. The historical sequence data of the key process parameters within a preset time window are obtained. The first time derivative of each key process parameter is calculated by dividing the parameter difference between adjacent sampling points by the corresponding sampling time interval. The time derivative vector of each sample is then formed by performing dimensionless processing. Calculate the cosine similarity between the time derivative vectors of the sample and other samples; After mapping the cosine similarity to a non-negative interval, a weighted sum is performed with the reciprocal of the normalized Euclidean distance to obtain the process state similarity between the sample and other samples.
[0027] For the baseline sample and any candidate sample in the minority class sample set, Z-Score standardization is used to transform all dimensions of the process parameters of the baseline sample and any candidate sample into a dimensionless feature matrix with a mean of 0 and a variance of 1. The Euclidean distance between the two samples in the multidimensional parameter feature space is calculated, for example, the straight-line distance between the two points is calculated to be 2.45. For the previously selected key process parameters, historical sequence data is obtained with a preset time window size, for example, a sequence of data points containing historical time periods of the past 1 to 3 minutes. If the frequency is 10 seconds, it corresponds to 6 to 18 sampling points. For each historical sequence, the first-order time derivative sequence is calculated by dividing the parameter difference between adjacent sampling points by the sampling time interval. After performing Z-Score standardization, the time derivative vectors are combined to generate a time derivative vector. For example, the time derivative vectors of the two samples are [0.15, -0.42, 1.03] and [0.10, -0.38, 0.95], respectively.
[0028] By calculating the cosine similarity between the time derivative vectors of two samples, assuming the calculated cosine similarity is 0.98, representing the degree of synergy in the temporal changes of the two sample conditions, a linear transformation is used to map this cosine similarity from the interval [-1,1] to the non-negative real number space [0,1], transforming the original value of 0.98 to 0.99. The dimensionless Euclidean distance is normalized using a reciprocal mapping, and weight factors are assigned to the temporal similarity and spatial distance similarity respectively. For example, an empirical allocation ratio of 0.4 for temporal similarity and 0.6 for Euclidean distance is used. The aforementioned non-negative cosine similarity and the normalized reciprocal distance are then summed according to their weights to obtain the process state similarity between the samples.
[0029] In one embodiment, determining the number of nearest neighbors proportional to the relative uncertainty includes: Preset the baseline value and adjustment coefficient for the number of nearest neighbors; Obtain the relative uncertainty of the sample; The benchmark value is added to the product of the adjustment coefficient and the relative uncertainty, and then rounded down to obtain the number of nearest neighbors of the sample. The number of nearest neighbors is compared with the number of optional samples in the minority class sample set excluding the current sample, and the minimum of the two is taken as the actual number of nearest neighbors.
[0030] During the configuration phase, a baseline value for the number of nearest neighbors is preset, for example, set to 3, and an adjustment coefficient is set, for example, set to 7. Before performing the calculation, the maximum value of the prediction uncertainty for the entire minority class sample is obtained, for example, 3.20, and the minimum value is obtained, for example, 0.80.
[0031] For the target sample, obtain the current prediction uncertainty, for example, 2.15. Apply the maximum-minimum range mapping to normalize the range of the uncertainty using the formula (current value - minimum value) / (maximum value - minimum value), resulting in a relative uncertainty in the range [0,1]. Substituting this into a specific example, we get 0.5625. Using the calculated relative uncertainty, we calculate the next nearest neighbor value using the formula: baseline value + (adjustment coefficient × relative uncertainty). This yields 6.9375. Rounding this value down, we obtain a minimum of 6 nearest neighbors for this sample. This logic ensures that samples with higher prediction uncertainty select a larger number of nearest neighbors, while samples with lower prediction uncertainty select a smaller number of nearest neighbors.
[0032] In one embodiment, the step of calculating the covariance matrix based on the distribution of the nearest neighbor samples in the dimensionless parameter space and randomly combining their eigenvectors to generate probabilistic augmentation directions includes: Calculate the mean vector of the nearest neighbor samples of the sample in the dimensionless parameter space. The local data covariance matrix is calculated using the difference vector between each nearest neighbor sample and the mean vector; The local data covariance matrix is subjected to eigenvalue decomposition to extract eigenvalues and corresponding eigenvectors; A random weight vector following a normal distribution is generated. The random weight vector is multiplied by the square root of the corresponding eigenvalue, and then a linear weighted combination is performed on all eigenvectors to generate the probabilistic augmentation direction.
[0033] Once the target sample and the number of nearest neighbors are determined (e.g., 6), the data of these 6 nearest neighbors are obtained in the dimensionless parameter space. The arithmetic mean of the values is calculated across all parameter dimensions to obtain the feature mean vector. This mean vector is then subtracted from each of the 6 nearest neighbors to obtain a deviation matrix composed of difference vectors. The deviation matrix is then multiplied on the left by its transpose and divided by an unbiased correction term (i.e., the number of nearest neighbors minus 1, in this example, divided by 5), to construct the local data covariance matrix.
[0034] Eigenvalue decomposition, such as the Jacobi iterative algorithm, is performed on the covariance matrix of the local data to extract the eigenvalues and corresponding eigenvectors. A standard normal distribution with a mean of 0 and a variance of 1 is used to generate a uniformly dimensional random weight vector. During computation, the square root of each eigenvalue is calculated and multiplied by the corresponding random weight scalar. This multiplication is used as a weighting coefficient to perform a linear combination on all extracted eigenvectors, generating a single probabilistic augmenting direction vector.
[0035] In one embodiment, the initial augmented sample is generated in the dimensionless parameter space along the line connecting the sample and its nearest neighbor, and then translated and corrected along the probabilistic augmentation direction. After inverse dimensionlessization, the ingredient component parameters under a unified quality benchmark and a unified sampling period are subjected to boundary-based proportional scaling projection to satisfy the process physical threshold and material conservation constraints, resulting in a new augmented sample set, including: Within the range of the number of augmented samples to be generated, a target nearest neighbor sample is randomly selected from the nearest neighbor samples of the number of nearest neighbors of the sample in the dimensionless parameter space; Calculate the difference vector between the sample and the target nearest neighbor sample, multiply it by a random coefficient in the range of 0 to 1, and then superimpose it onto the sample to generate the initial augmented sample; The probabilistic augmentation direction is normalized to obtain the unit augmentation direction; The dimensionless correction distance is obtained by multiplying the relative uncertainty of the sample by a preset correction ratio coefficient. The initial augmented sample is moved along the unit augmentation direction by the dimensionless correction distance. After inverse dimensionless processing, the non-ingredient component parameters are bounded according to the preset process physical threshold. The ingredient component parameters, which are uniformly converted to the same sampling period, are subjected to equal scaling projection with boundary constraints. This ensures that each ingredient component parameter satisfies the material conservation constraint within the corresponding process physical threshold range, thereby generating augmented samples. This process is repeated until the number of augmented samples to be generated is reached.
[0036] Given the requirement for a certain number of augmented samples to be generated, for example, 20 synthetic samples, a sample is randomly selected from the nearest neighbor set as the target nearest neighbor. The difference vector from this sample to the target nearest neighbor is calculated, and a random coefficient in the interval (0,1) is generated, for example, 0.35. This coefficient is multiplied by the difference vector and then superimposed on the coordinates of the sample to obtain the initial augmented sample. The values of each dimension of the probabilistic augmentation direction obtained in the previous module are divided by the L2 norm of the direction for normalization to obtain the unit augmentation direction vector.
[0037] Obtain a preset correction scaling factor, with a value between 0.01 and 0.1, for example, a value of 0.05. Multiply the relative uncertainty of the sample, such as 0.5625, by the aforementioned correction scaling factor to obtain the dimensionless correction distance, such as 0.0281 in the example. Offset the initial augmented sample by this dimensionless correction distance along the unit augmentation direction to obtain the correction value, and perform inverse dimensionless processing to restore the data to the original physical scale. In this process, before projection, the flow rates of liquid ammonia, phosphoric acid, and potassium salt are uniformly converted to the mass flow rate or mass percentage under the same sampling period, and the target total feed amount is converted to the sum of the target total mass flow rate or mass percentage under the same sampling period. First, the lower and upper limits of the process physical parameters of each ingredient component are obtained. The sum of the lower limits of all ingredient component parameters after unification of dimensions is calculated as the minimum feasible total amount, and the sum of the upper limits of all ingredient component parameters is calculated as the maximum feasible total amount. If the target total feed amount is lower than the minimum feasible total amount, the minimum feasible total amount is used as the projection target total amount. If the target total feed amount is higher than the maximum feasible total amount, the maximum feasible total amount is used as the projection target total amount. Otherwise, the target total feed amount is used as the projection target total amount. For non-ingredient component parameters, boundary constraints are directly applied according to the corresponding process physical thresholds. For ingredient component parameters, they are first scaled proportionally to the total projected quantity. If any ingredient component parameter exceeds the corresponding process physical threshold after scaling, that parameter is fixed to the threshold and removed from the set of parameters to be scaled. Then, the remaining ingredient component parameters are scaled proportionally again based on the remaining target quantity until all ingredient component parameters are within the range of their corresponding process physical thresholds and their total quantity satisfies the projected target quantity. This process is repeated until the required number of augmented samples to be generated is reached.
[0038] S3, merge the majority class sample set, minority class sample set and newly added augmented sample set to obtain a balanced dataset, train the batching process control model, and output control signals to control the fertilizer batching actuator according to the current process parameters.
[0039] The majority class sample set, the original minority class sample set, and the newly added augmented sample set are concatenated along the row direction, and the sample arrangement order is shuffled to obtain a balanced dataset. Each sample contains process parameters, quality labels, and corresponding batching actuator control target signals. The category labels of the newly added minority class augmented samples inherit the category labels of their source minority class samples. Continuous quality detection values are regenerated based on the augmented sample parameters after translation correction and constraint projection, combined with the distance weights between the source samples and the target nearest neighbor samples. The control target signals are generated based on the formula standard data, the quality deviation direction, and historical effective correction records. A batching process control model was constructed, comprising a two-layer long short-term memory network and a three-layer fully connected feedforward network. The mean squared error was set as the loss function. The control target signals of the batching execution mechanism recorded in the balanced dataset were used as the supervised training target. The network weight parameters were updated using the backpropagation algorithm on the balanced dataset for model training until the value of the loss function decreased and stabilized within a set error threshold. Process parameters such as the reaction tank temperature and instantaneous flow rates of various raw materials were collected in real time at the current sampling moment and several previous sampling periods. These parameters were then used to construct a sequence tensor in chronological order and input into the trained batching process control model. The model calculated and output control signal vectors corresponding to the liquid ammonia metering pump, phosphate metering pump, potassium salt screw feeder, and stirring mechanism through forward propagation. These control signal vectors were written into the holding register of the field-programmable logic controller (FPGA). The corresponding control quantities were output through the FPGA's analog-to-digital converter (ADC) or frequency converter module to drive the liquid ammonia metering pump, phosphate metering pump, potassium salt screw feeder, and stirring mechanism, respectively, thus completing the closed-loop control of the fertilizer batching process.
[0040] This specification also provides a multi-source data fusion control system for a fertilizer batching process, comprising the following modules: The acquisition module is used to acquire operational data containing process parameters and quality labels, and divides the data into majority and minority sample sets according to the labels. The calculation module is used to augment the minority class sample set data, construct a prediction model to integrate and calculate the prediction uncertainty of each minority class sample, normalize it to relative uncertainty, extract the average feature importance of process parameters, select at least two key process parameters accordingly, combine the first-order time derivative of the key process parameters within a preset time window and the spatial geometric distance between samples to calculate the process state similarity, determine the number of nearest neighbors proportional to the relative uncertainty, select nearest neighbor samples for the sample based on the process state similarity, calculate the covariance matrix based on the distribution of the nearest neighbor samples in the dimensionless parameter space, randomly combine their feature vectors to generate a probabilistic augmentation direction, determine the number of augmented samples to be generated based on the relative uncertainty, generate initial augmented samples in the dimensionless parameter space along the line connecting the sample and the nearest neighbor samples, and translate and correct along the probabilistic augmentation direction. After inverse dimensionlessization, perform boundary-based proportional scaling projection on the batching component parameters under a unified quality benchmark and a unified sampling period to satisfy the process physical threshold and material conservation constraints, and obtain a new augmented sample set. The control module is used to merge the majority class sample set, minority class sample set and newly added augmented sample set to obtain a balanced dataset, train the batching process control model, and output control signals to control the fertilizer batching actuator according to the current process parameters.
[0041] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. A multi-source data fusion control method for fertilizer formulation process, characterized in that, Includes the following steps: Obtain operational data containing process parameters and quality labels, and divide the data into majority and minority sample sets based on the labels; The minority class sample set data is augmented, a prediction model is constructed to integrate and calculate the prediction uncertainty of each minority class sample, and normalize it to relative uncertainty. The average feature importance of process parameters is extracted, and at least two key process parameters are selected accordingly. The process state similarity is calculated by combining the first-order time derivative of the key process parameters within a preset time window and the spatial geometric distance between samples. The number of nearest neighbors proportional to the relative uncertainty is determined. Nearby samples are selected for the sample based on the process state similarity. The covariance matrix is calculated based on the distribution of the nearest neighbors in the dimensionless parameter space. The feature vectors are randomly combined to generate a probabilistic augmentation direction. The number of augmented samples to be generated is determined according to the relative uncertainty. Initial augmented samples are generated in the dimensionless parameter space along the line connecting the sample and the nearest neighbor samples, and translated and corrected along the probabilistic augmentation direction. After inverse dimensionlessization, the batching component parameters under a unified quality benchmark and a unified sampling period are subjected to boundary-based proportional scaling projection to satisfy the process physical threshold and material conservation constraints, resulting in a new augmented sample set. The majority class sample set, minority class sample set, and newly added augmented sample set are merged to obtain a balanced dataset, which is used to train the batching process control model. The model is then used to output control signals to control the fertilizer batching actuator based on the current process parameters.
2. The method according to claim 1, characterized in that, The constructed prediction model integrates and calculates the prediction uncertainty of each minority class sample, normalizes it to a relative uncertainty, and extracts the average feature importance of process parameters, including: The samples from the minority class sample set are respectively input into the multiple base decision tree models included in the prediction model integration to obtain multiple process prediction values; Calculate the variance of the multiple process prediction values. When the process prediction value is a multidimensional continuous quality detection value, calculate the prediction variance of each dimension and normalize and weight the sum. Use the obtained scalar variance value as the prediction uncertainty of the sample. Obtain the maximum and minimum values of the prediction uncertainty of all minority class samples. When the maximum value is greater than the minimum value, use the maximum and minimum values to perform range normalization on the prediction uncertainty of the sample to obtain the relative uncertainty of the sample. When the maximum value is equal to the minimum value, set the relative uncertainty of each minority class sample to the same preset value. The process parameters of each process in each base decision tree model are used as the impurity reduction value brought about by the split node; The impurity reduction values corresponding to the same process parameter in all base decision tree models are summed, and the average value is calculated as the average feature importance of each process parameter.
3. The method according to claim 1, characterized in that, The selection of at least two key process parameters accordingly includes: All process parameters are sorted in descending order of their average characteristic importance. Calculate the arithmetic mean of the average characteristic importance of all process parameters as the importance threshold; After traversing and sorting the process parameters, process parameters with an average feature importance greater than the importance threshold are identified as key process parameters. When the number of process parameters greater than the importance threshold is less than two, the top two process parameters in descending order are selected as key process parameters.
4. The method according to claim 1 or 3, characterized in that, The calculation of process state similarity by combining the first-order time derivative of the key process parameters within a preset time window and the spatial geometric distance between samples includes: After dimensionless processing of the process parameters of the sample and other samples, the Euclidean distance between the sample and other samples in the multidimensional parameter space is calculated. The historical sequence data of the key process parameters within a preset time window are obtained. The first time derivative of each key process parameter is calculated by dividing the parameter difference between adjacent sampling points by the corresponding sampling time interval. The time derivative vector of each sample is then formed by performing dimensionless processing. Calculate the cosine similarity between the time derivative vectors of the sample and other samples; After mapping the cosine similarity to a non-negative interval, a weighted sum is performed with the reciprocal of the normalized Euclidean distance to obtain the process state similarity between the sample and other samples.
5. The method according to claim 1, characterized in that, Determining the number of nearest neighbors that is proportional to the relative uncertainty includes: Preset the baseline value and adjustment coefficient for the number of nearest neighbors; Obtain the relative uncertainty of the sample; The benchmark value is added to the product of the adjustment coefficient and the relative uncertainty, and then rounded down to obtain the number of nearest neighbors of the sample. The number of nearest neighbors is compared with the number of optional samples in the minority class sample set excluding the current sample, and the minimum of the two is taken as the actual number of nearest neighbors.
6. The method according to claim 1, characterized in that, The calculation of the covariance matrix based on the distribution of the nearest neighbor samples in the dimensionless parameter space, and the random combination of their eigenvectors to generate probabilistic augmentation directions, includes: Calculate the mean vector of the nearest neighbor samples of the sample in the dimensionless parameter space. The local data covariance matrix is calculated using the difference vector between each nearest neighbor sample and the mean vector; The local data covariance matrix is subjected to eigenvalue decomposition to extract eigenvalues and corresponding eigenvectors; A random weight vector following a normal distribution is generated. The random weight vector is multiplied by the square root of the corresponding eigenvalue, and then a linear weighted combination is performed on all eigenvectors to generate the probabilistic augmentation direction.
7. The method according to claim 1, characterized in that, The process involves generating initial augmented samples along the lines connecting the sample and its nearest neighbors within the dimensionless parameter space, and then translating and correcting them along the probabilistic augmentation direction. After inverse dimensionlessization, the ingredient component parameters under a unified quality benchmark and a unified sampling period are subjected to boundary-based proportional scaling projection to satisfy process physical thresholds and material conservation constraints, resulting in a new augmented sample set, including: Within the range of the number of augmented samples to be generated, a target nearest neighbor sample is randomly selected from the nearest neighbor samples of the number of nearest neighbors of the sample in the dimensionless parameter space; Calculate the difference vector between the sample and the target nearest neighbor sample, multiply it by a random coefficient in the range of 0 to 1, and then superimpose it onto the sample to generate the initial augmented sample; The probabilistic augmentation direction is normalized to obtain the unit augmentation direction; The dimensionless correction distance is obtained by multiplying the relative uncertainty of the sample by a preset correction ratio coefficient. The initial augmented sample is moved along the unit augmentation direction by the dimensionless correction distance. After inverse dimensionless processing, the non-ingredient component parameters are bounded according to the preset process physical threshold. The ingredient component parameters, which are uniformly converted to the same sampling period, are subjected to equal scaling projection with boundary constraints. This ensures that each ingredient component parameter satisfies the material conservation constraint within the corresponding process physical threshold range, thereby generating augmented samples. This process is repeated until the number of augmented samples to be generated is reached.
8. A multi-source data fusion control system for a fertilizer batching process, characterized in that, Includes the following modules: The acquisition module is used to acquire operational data containing process parameters and quality labels, and divides the data into majority and minority sample sets according to the labels. The calculation module is used to augment the minority class sample set data, construct a prediction model to integrate and calculate the prediction uncertainty of each minority class sample, normalize it to relative uncertainty, extract the average feature importance of process parameters, select at least two key process parameters accordingly, combine the first-order time derivative of the key process parameters within a preset time window and the spatial geometric distance between samples to calculate the process state similarity, determine the number of nearest neighbors proportional to the relative uncertainty, select nearest neighbor samples for the sample based on the process state similarity, calculate the covariance matrix based on the distribution of the nearest neighbor samples in the dimensionless parameter space, randomly combine their feature vectors to generate a probabilistic augmentation direction, determine the number of augmented samples to be generated based on the relative uncertainty, generate initial augmented samples in the dimensionless parameter space along the line connecting the sample and the nearest neighbor samples, and translate and correct along the probabilistic augmentation direction. After inverse dimensionlessization, perform boundary-based proportional scaling projection on the batching component parameters under a unified quality benchmark and a unified sampling period to satisfy the process physical threshold and material conservation constraints, and obtain a new augmented sample set. The control module is used to merge the majority class sample set, minority class sample set and newly added augmented sample set to obtain a balanced dataset, train the batching process control model, and output control signals to control the fertilizer batching actuator according to the current process parameters.
9. The system according to claim 8, characterized in that, The constructed prediction model integrates and calculates the prediction uncertainty of each minority class sample, normalizes it to a relative uncertainty, and extracts the average feature importance of process parameters, including: The samples from the minority class sample set are respectively input into the multiple base decision tree models included in the prediction model integration to obtain multiple process prediction values; Calculate the variance of the multiple process prediction values. When the process prediction value is a multidimensional continuous quality detection value, calculate the prediction variance of each dimension and normalize and weight the sum. Use the obtained scalar variance value as the prediction uncertainty of the sample. Obtain the maximum and minimum values of the prediction uncertainty of all minority class samples. When the maximum value is greater than the minimum value, use the maximum and minimum values to perform range normalization on the prediction uncertainty of the sample to obtain the relative uncertainty of the sample. When the maximum value is equal to the minimum value, set the relative uncertainty of each minority class sample to the same preset value. The process parameters of each process in each base decision tree model are used as the impurity reduction value brought about by the split node; The impurity reduction values corresponding to the same process parameter in all base decision tree models are summed, and the average value is calculated as the average feature importance of each process parameter.
10. The system according to claim 8, characterized in that, The selection of at least two key process parameters accordingly includes: All process parameters are sorted in descending order of their average characteristic importance. Calculate the arithmetic mean of the average characteristic importance of all process parameters as the importance threshold; After traversing and sorting the process parameters, process parameters with an average feature importance greater than the importance threshold are identified as key process parameters. When the number of process parameters greater than the importance threshold is less than two, the top two process parameters in descending order are selected as key process parameters.
