Disclosure of Invention
The invention aims to solve the technical problem of providing a product quality end-edge-cloud collaborative forecasting method under an industrial big data environment aiming at the defects of the prior art.
In order to solve the technical problems, the technical scheme adopted by the invention is as follows:
the invention provides a product quality end-edge-cloud collaborative forecasting method under an industrial big data environment, which comprises the following steps:
step 1: acquiring actual production process data of a product in an actual industrial field by using a sensor in the actual industrial field;
step 2: removing abnormal data samples and data samples containing missing values in the collected production process data by using a data cleaning algorithm to form an initial sample data set; data preprocessing is carried out on data in the initial sample data set by using a data complementing algorithm, all data dimensions are the same, and the preprocessed sample data is stored in an edge end database; establishing a cloud database on a cloud server, synchronizing sample data in the edge database into the cloud database when the number of samples in the edge database is more than n, and emptying data samples in the edge database;
and step 3: judging whether the total number of data in the cloud database is more than H, if not, executing the step 1, if so, selecting an intelligent modeling method aiming at the characteristics of the production process and the production process data of the product on a cloud server, and establishing a forecasting model of the product quality;
respectively establishing w forecasting models on a cloud server according to w quality indexes of the product to form a model library; the method comprises the following steps of establishing a forecasting model aiming at the ith quality index as follows:
wherein I represents the preprocessed sample data input by the forecasting model,
a prediction value f representing the i-th quality index
i(. The) represents the structure of the established prediction model, θ
iA set of parameters representing the established prediction model;
according to the industrial production process, the data characteristics of the model input data and the analysis of the correlation between the input data of the forecasting model and the quality index, the theta is further determined
iDivided into three sets of parameters, i.e.
And 4, step 4: according to the actual production sequence of the product, extracting the latest K sample data from the cloud database to form a training set D, and simultaneously recording that the total number of the data samples in the cloud database is S; respectively training all parameters in each forecast model in the model library by using sample data in the training set D, and recording the trained forecast model library as
Wherein F
i cA forecasting model representing the ith quality index;
taking the production process data of the sample as input data, taking the ith quality index data of the sample as tag data, and wearing the sample in a cloudOn the server, training the prediction model of the ith quality index to obtain F
i c(ii) a I.e. training the parameter set in step 3
All of the parameters in (1);
and 5: forecast model library FcThe method comprises the steps that the cloud server transmits the prediction model to an edge server, the edge server puts different prediction models to different terminal servers for operation, and a user predicts different quality indexes of a product through the prediction models in the terminal servers;
step 6: acquiring input data of a forecasting model after data cleaning and data preprocessing are carried out on actual production process data acquired from a sensor in an industrial field, transmitting the input data to all terminal servers, forecasting each quality index of a product on each terminal server by using the forecasting model respectively, and transmitting a forecasting result to a user;
and 7: when the production process of the product is finished, maintaining the corresponding parameter set of the forecasting model on each terminal server
Wherein i ∈ {1,2, …, w }, and using actual production process data of the product to perform parameter set on each forecasting model
The parameters in the model are corrected in real time to obtain a new forecasting model F
i tAnd replacing the original forecast model in the terminal server at the moment, using forecast model F
i tForecasting the subsequent products; the real-time correction is to adopt different correction methods to the parameter set according to different industrial fields and modeling algorithms
Correcting the parameters in (1);
and 8: storing the actual production data and the quality index data of the product into a historical database of the edge terminal; judging the number of all samples in the historical database of the edge end at the moment, if the number of the samples at the moment is less than n, turning to the step 6, and continuing to forecast the quality index of the subsequent product; if the number of the samples is more than n, turning to step 9;
and step 9: extracting the production data of n products from the historical database of the edge end as a new training set d, and aiming at each forecasting model in the forecasting model base, on the edge end server, utilizing the sample data in the training set d to carry out parameter set treatment on the model
Correcting in real time to obtain a prediction model F
i eAll the corrected forecasting models are combined into a new forecasting model library
Step 10: using edge server, FeThe forecasting models in the system are respectively downloaded to corresponding terminal servers and replace the original forecasting models; calling the retrained forecasting model by a user through different terminal servers, and forecasting the product data in a new round; synchronizing the data samples in the edge database to the cloud database, emptying data information in the edge database, and storing product data of a new round of production into the edge database;
step 11: judging the number of samples in the cloud database at the moment, judging whether the total number of the samples in the cloud database is increased by N samples compared with S or not, wherein N is larger than N, if yes, returning to the step 4, counting the total number S of the samples in the cloud database again to be S + N, and retraining FcThe predictive model of (1); if not, returning to the step 6, and forecasting the product quality by using the forecasting model on the terminal server.
Said step 3
Parameter set
The method is used for describing the change rule of the data samples produced in a large batch; parameter set
The data characteristic of the data sample is changed in different small batch production processes; parameter set
Is used for describing the specific data characteristics included in each data sample; wherein the number of the products produced in the industrial production process of the large batch is M, each large batch is divided into r small batches, and the number of the products produced in each small batch is M.
Adopt the produced beneficial effect of above-mentioned technical scheme to lie in: according to the product quality end-edge-cloud collaborative forecasting method under the industrial big data environment, the parameters of the established forecasting model can be divided into parameters sensitive to the change of a large number of data samples; parameters sensitive to changes in a small number of data samples; and parameters sensitive to the change of a single data sample are classified into three types, and the parameters in the forecasting model are continuously trained and updated by an end-edge-cloud collaborative forecasting method. Meanwhile, the invention can effectively utilize real-time data generated in the production process and continuously correct parameters in the forecasting model, so that the forecasting model can adapt to the real-time change of the product, thereby continuously improving the forecasting precision of the model and improving the production benefit.
Detailed Description
The following detailed description of embodiments of the present invention is provided in connection with the accompanying drawings and examples. The following examples are intended to illustrate the invention but are not intended to limit the scope of the invention.
As shown in fig. 2, the method of the present embodiment is as follows.
The invention provides a product quality end-edge-cloud collaborative forecasting method under an industrial big data environment, which is characterized in that a forecasting model is trained on a cloud server by utilizing industrial big data, and related parameters in the forecasting model are continuously corrected on an edge end server and a terminal server at the same time, as shown in figure 1, so that the result of the forecasting model is more accurate. The method for intelligently forecasting the quality of the steel plate product in the embodiment comprises the following steps:
step 1: acquiring actual production process data of a steel plate product in an industrial field by using a sensor in the industrial field of the steel plate;
step 2: removing abnormal data samples and data samples containing missing values in the collected production process data by using a data cleaning algorithm to form an initial sample data set; then, data preprocessing is carried out on data in the initial sample data set by using a data complementing algorithm according to the difference of the sample data dimensions caused by different types of the steel plates to obtain sample data with the same data dimensions, and the preprocessed sample data is stored in an edge end database; the preprocessed sample data is used as input data of a product quality forecasting model, the final quality label data of the product is used as output data of the product quality forecasting model, the model is used for constructing the product quality forecasting model, useless data are added around the input data, the final forecasting result is not affected, and meanwhile the input data dimensions of all samples are unified. And a cloud database is established on the cloud server and used for storing all the preprocessed sample data, so that the data in the industrial production process can be analyzed and modeled conveniently. When the number of the samples in the edge end database is more than n, synchronizing the sample data in the edge end database to the cloud end database, and emptying the data samples in the edge end database; and the edge end database on the edge end server is used for storing sample data generated in the small-batch production process.
And step 3: judging whether the total number of data in the cloud database is greater than H, if not, executing the step 1, and if so, selecting a proper intelligent modeling method, such as a convolutional neural network, a graph neural network, a random forest and other intelligent modeling methods, aiming at the characteristics of the steel plate production process and the steel plate production process data on a cloud server; in the embodiment, a model building method of mechanism and data is selected to build a forecasting model of product quality;
as 5 quality evaluation indexes are provided for describing whether the steel plate product is qualified or not, the indexes are respectively the size, the surface, the shape, the internal quality and the performance of the steel plate. Therefore, on the cloud server, a forecasting model needs to be established respectively for each quality index to form a model library.
The method comprises the following steps of establishing a forecasting model aiming at the ith quality index as follows:
wherein I represents the preprocessed sample data input by the forecasting model,
a prediction value representing the i-th quality index given by the prediction model, f
i(. The) represents the structure of the established prediction model, θ
iA set of parameters representing the established prediction model;
according to the production process of the steel plate, the data characteristics of the model input data and the analysis of the correlation between the input data of the forecasting model and the quality index, the theta is further determined
iDivided into three sets of parameters, i.e.
In the industrial production process, the number of the products produced in a large batch is M,dividing each large batch into r small batches, wherein the number of the products produced in each small batch is m; the parameter set
The method is used for describing the change rule of the data samples produced in a large batch; parameter set
The data characteristic of the data sample is changed in different small batch production processes; parameter set
Is used for describing the specific data characteristics included in each data sample;
the analysis method in the embodiment may be that a typical correlation analysis algorithm has mic, pearson correlation coefficient, and the like;
parameter set
The parameters in (1) are mainly used for describing the change rule of input data of products produced in a large batch, and are used for mining the characteristics implied in a large data sample, and are the main parameters in the forecasting model. The input data corresponding to the partial parameters are often too complex, more data samples and complex model structures are needed as supports to dig out the implicit characteristics, and the partial parameters are not obviously changed along with the passage of time in the production process for a long time, such as the temperature change rule of the steel plate in the production process, the equipment information of the steel plate in the production process, and the like.
Parameter set
The parameters in (1) are mainly used for describing slight changes of data characteristics of input data in different small batch production processes. The part of the parameters are not changed in the production process of a large batch, but are changed along with the part of the parametersThe partial parameters are usually suitable for the data samples in a small batch, but not necessarily suitable for the data samples in other batches. For example, the type of steel plate, the production mode, the heating temperature of the heating furnace, the gas supply amount, etc. in a small lot.
Parameter set
The parameters in (1) are mainly used for describing the specific data characteristics contained in each data sample, the partial parameters are sensitive to the change of the data sample and can change along with the change of the data sample, and the corresponding input data is often specific to one data sample. For example, information on the amount of wear of rolls during production of a steel sheet, the temperature of cooling water during cooling, and the like.
And 4, step 4: according to the actual production sequence of the product, extracting the nearest K (15000) sample data from the cloud database to form a training set D, and simultaneously recording the total number of the data samples in the cloud database as S (28700); the first training is based on the model base which is established in the step 3 and comprises 5 forecasting models, each forecasting model in the model base is respectively trained by utilizing sample data in the training set D aiming at each forecasting model, and then the forecasting model base aiming at each quality index is obtained and recorded as
Wherein F
i cA forecasting model representing the ith quality index;
taking the production process data of the sample as input data, taking the ith quality index data of the sample as tag data, and training a forecasting model of the ith quality index on a cloud server to obtain F
i c(ii) a I.e. training the parameter set in step 3
The parameter (1) of (1);
and 5: forecast model library FcFrom cloud server to edgeThe edge server downloads different forecasting models to different terminal servers for operation, and the user forecasts different quality indexes of the product through the forecasting models in the terminal servers;
step 6: acquiring input data of a forecasting model after data cleaning and data preprocessing are carried out on actual production process data acquired from a sensor in an iron plate production industrial field, transmitting the input data to all terminal servers, forecasting each quality index of a product on each terminal server by using the forecasting model corresponding to the product, transmitting the forecasting result to a user, and making a decision on the production process by the user according to the forecasting result so as to improve the qualification rate of the product;
and 7: when the production process of the steel plate is finished, maintaining the corresponding parameter set of the forecasting model on each terminal server
Wherein i ∈ {1,2, …, w }, and using actual production process data of the product to perform parameter set on each forecasting model
The parameters in the model are corrected in real time to obtain a new forecasting model F
i tAnd replacing the original forecast model in the terminal server at the moment, using forecast model F
i tForecasting the subsequent products; the real-time correction is to adopt different correction methods to the parameter set according to different industrial fields and modeling algorithms
Correcting the parameters in (1);
and 8: storing the actual production data and the quality index data of the steel plate into a historical database of the edge end; judging the number of all samples in the historical database of the edge end at the moment, if the number of the samples at the moment is less than n and is 1000, turning to the step 6, and continuing to forecast the quality index of the subsequent product; if the number of the samples is larger than n, which is 1000, the step is switched to step 9;
and step 9: extracting the production data of 1000 products from the historical database of the edge end as a new training set d, and aiming at each forecast model in the forecast model base, on the edge end server, utilizing the sample data in the training set d to carry out the parameter set in the model
Correcting in real time to obtain a prediction model F
i eAll the corrected forecasting models are combined into a new forecasting model library
Due to the parameter set
The parameters in (1) do not change due to the change of the small batch data samples in the production process, so the parameter set in the fixed prediction model
Correcting parameter set in each prediction model on edge end server by using data sample in training set d
Thereby obtaining a new forecasting model F
i eAnd then a new forecasting model library is formed. F
i eCompared with F
i cOnly the parameter set is changed
And the number of samples in the training set D is much smaller than the number of samples in the training set D, so the model F is predicted
i eThe training process can save more computing resources, the training speed is faster, and the time is saved.
Step 10: using edge server, FeThe forecasting models in the system are respectively downloaded to corresponding terminal servers and replace the original forecasting models; calling the retrained forecasting model by a user through different terminal servers, and forecasting the product data in a new round; synchronizing the data samples in the edge database to the cloud database, emptying data information in the edge database, and storing product data of a new round of production into the edge database;
step 11: judging the number of samples in the cloud database at the moment, judging whether the total number of the samples in the cloud database is increased by N to 10000 samples (N is far more than N) compared with S, if so, returning to the step 4, counting the total number of the samples in the cloud database again, namely S + N, and retraining FcThe predictive model of (1); if not, returning to the step 6, and forecasting the product quality by using a forecasting model on the terminal server;
finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; such modifications and substitutions do not depart from the spirit of the corresponding technical solutions and scope of the present invention as defined in the appended claims.