CN114066510A - Method and device for predicting commodity sales, computer equipment and storage medium - Google Patents

Method and device for predicting commodity sales, computer equipment and storage medium Download PDF

Info

Publication number
CN114066510A
CN114066510A CN202111290485.9A CN202111290485A CN114066510A CN 114066510 A CN114066510 A CN 114066510A CN 202111290485 A CN202111290485 A CN 202111290485A CN 114066510 A CN114066510 A CN 114066510A
Authority
CN
China
Prior art keywords
data
influence factor
factor
sub
inputting
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111290485.9A
Other languages
Chinese (zh)
Inventor
丁永兵
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Chuangyou Digital Technology Guangdong Co Ltd
Original Assignee
Chuangyou Digital Technology Guangdong Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Chuangyou Digital Technology Guangdong Co Ltd filed Critical Chuangyou Digital Technology Guangdong Co Ltd
Priority to CN202111290485.9A priority Critical patent/CN114066510A/en
Publication of CN114066510A publication Critical patent/CN114066510A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0201Market modelling; Market analysis; Collecting market data
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0201Market modelling; Market analysis; Collecting market data
    • G06Q30/0202Market predictions or forecasting for commercial activities

Abstract

The application relates to an article sales prediction method, an article sales prediction device, computer equipment and a storage medium. The method comprises the following steps: acquiring data of each influence factor in a plurality of influence factors influencing the commodity sales prediction; acquiring historical sales data of the articles; inputting historical sales data and data of each influence factor into a trained time sequence prediction model to obtain predicted sales data of the articles output by the time sequence prediction model; the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting predicted sales data based on the time sequence correlation, the data of each influence factor and historical sales data. By adopting the method, the accuracy of the goods sales prediction can be improved.

Description

Method and device for predicting commodity sales, computer equipment and storage medium
Technical Field
The present application relates to the technical field of commodity sales processing, and in particular, to a commodity sales prediction method, apparatus, computer device, and storage medium.
Background
In a large-scale article management system, it is necessary to manage article type data, sales data, discount data, stock data, and the like of each article. Meanwhile, in the article management system, it is also necessary to predict sales of each article.
Conventionally, methods of predicting item sales include time series prediction methods and machine learning algorithms. The conventional time sequence prediction method is represented by single sequence prediction algorithms such as ARIMA (automated Integrated Moving Average Autoregressive model) and exponential smoothing algorithm, and multiple sequence prediction algorithms such as VAR9 (vector Autoregressive algorithm). The time sequence prediction method is essentially based on the recent historical data of each time point to build a simple linear model, and when the time sequence prediction method is adopted to predict the sales volume of an article, the prediction accuracy rate is difficult to guarantee.
The traditional machine learning algorithm is represented by an XGBoost (XGBoost is a lifting tree model, which integrates many tree models together to form a strong classifier) integrated tree model, and the like. In this type of machine learning algorithm, each time point of each data sequence is used as a sample, and each sample generally refers to the time sequence prediction method algorithm, so that the hysteresis information is processed into features, and simultaneously, the article attribute information and the like can be combined, so as to learn the influence of the category attribute on the article sales volume. However, such algorithms mainly convert the time series prediction problem into a common machine learning problem, and when the input data series are very many and the data amount is very large, such machine learning algorithms cannot be well fitted, so that the goods sales prediction result is inaccurate. In addition, due to the limitation of sample input, the original data sequence is easily lost by the machine learning algorithm, and the final product sales prediction result is inaccurate.
Disclosure of Invention
In view of the above, it is desirable to provide a method, an apparatus, a computer device, and a storage medium for predicting an item sales amount, which can improve the accuracy of the item sales amount prediction.
An item sales prediction method comprising: acquiring data of each influence factor in a plurality of influence factors influencing the commodity sales prediction; acquiring historical sales data of the articles; inputting historical sales data and data of each influence factor into a trained time sequence prediction model to obtain predicted sales data of the articles output by the time sequence prediction model; the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting predicted sales data based on the time sequence correlation, the data of each influence factor and historical sales data.
In one embodiment, the time sequence prediction model is a transformer model, the transformer model comprises an encoding layer and a decoding layer, and the transformer model is used for determining time sequence correlation among data of each influence factor through the encoding layer and the decoding layer and outputting predicted sales data based on the time sequence correlation, the data of each influence factor and historical sales data.
In one embodiment, inputting the historical sales data and the data of each influence factor into a trained time sequence prediction model comprises: if the data of a first target influence factor in the plurality of influence factors contains data of a future time point, respectively inputting the data of the first target influence factor into an encoding layer and a decoding layer of a transformer model; if the data of a second target influence factor in the plurality of influence factors does not contain the data of a future time point, inputting the data of the second target influence factor and historical sales data into an encoding layer of a transformer model; and if the data of the third target influence factor in the plurality of influence factors is a fixed value, inputting the data of the third target influence factor into a decoding layer of the transform model.
In one embodiment, the plurality of influence factors include a first influence factor, a second influence factor and a third influence factor, data of the first influence factor changes with time and includes data at a future time point, data of the second influence factor changes with time and does not include data at the future time point, and data of the third influence factor is a fixed value; inputting historical sales data and data of each influence factor into a trained time sequence prediction model, wherein the method comprises the following steps: inputting the data of the first influence factor into an encoding layer and a decoding layer of a transformer model respectively; inputting the data of the second influence factor and the historical sales data into an encoding layer of a transform model; the data of the third influencing factor is input to a decoding layer of the transformer model.
In one embodiment, the first influencing factor includes a first sub-influencing factor and a second sub-influencing factor, the first sub-influencing factor is a continuous variable, the second sub-influencing factor is a discrete variable, and the inputting of the first data of the first influencing factor into the coding layer and the decoding layer respectively includes: inputting the data of the first sub-influence factor into an encoding layer and a decoding layer respectively; and converting the data of the second sub-influence factor into vectors, and respectively inputting the converted vectors into the coding layer and the decoding layer.
In one embodiment, the second influencing factor includes a third sub-influencing factor and a fourth sub-influencing factor, the third sub-influencing factor is a continuous variable, the fourth sub-influencing factor is a discrete variable, and the inputting of the data of the second influencing factor to the coding layer of the transform model includes: splicing the data of the third sub-influence factor and the historical sales data, and inputting the spliced data into a coding layer; and converting the data of the fourth sub-influence factor into a vector, and inputting the converted vector into the coding layer.
In one embodiment, the third influencing factor includes a fifth sub-influencing factor and a sixth sub-influencing factor, the fifth sub-influencing factor is a continuous variable, the sixth sub-influencing factor is a discrete variable, and the inputting of the data of the third influencing factor to the decoding layer of the transform model includes: activating the data of the fifth sub-influence factor into a vector, and inputting the activated vector into a decoding layer; and converting the data of the sixth sub-influence factor into a vector, and inputting the obtained vector into a decoding layer.
An article sales predicting apparatus comprising: the system comprises a first acquisition module, a second acquisition module and a third acquisition module, wherein the first acquisition module is used for acquiring data of each influence factor in a plurality of influence factors influencing the goods sales prediction; the second acquisition module is used for acquiring historical sales data of the articles; the acquisition module is used for inputting the historical sales data and the data of each influence factor into the trained time sequence prediction model and acquiring the predicted sales data of the articles output by the time sequence prediction model; the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting predicted sales data based on the time sequence correlation, the data of each influence factor and historical sales data.
A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the method of any of the above embodiments when executing the computer program.
A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method of any of the above embodiments.
The method, the device, the computer equipment and the storage medium for predicting the commodity sales amount acquire data of each influence factor in a plurality of influence factors influencing commodity sales amount prediction, acquire historical sales amount data of commodities, input the historical sales amount data and the data of each influence factor into a trained time sequence prediction model, and acquire predicted sales amount data of commodities output by the time sequence prediction model, wherein the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting the predicted sales amount data based on the time sequence correlation, the data of each influence factor and the historical sales amount data.
The time sequence prediction model can learn the time sequence correlation among the input data of each influence factor, has stronger generalization capability, and overcomes the problem of low accuracy of commodity sales prediction caused by a mode that a simple linear model is built based on recent historical data of each time point in the traditional time sequence prediction method. In addition, the time sequence prediction model can output predicted sales data based on time sequence correlation among data of all the influence factors, the data of all the influence factors and historical sales data, and the technical problem that the goods sales prediction is inaccurate due to the data fitting problem and the original data sequence loss problem of the traditional machine learning algorithm is solved, so that the goods sales prediction accuracy is improved.
Drawings
FIG. 1 is a diagram illustrating an exemplary embodiment of a method for predicting sales of an item;
FIG. 2 is a flow diagram illustrating a method for predicting sales of an item, according to one embodiment;
FIG. 3 is a diagram of data time windows for historical time points and future time points, in accordance with an embodiment;
FIG. 4 is a schematic representation of the transformer model in one embodiment;
FIG. 5 is a block diagram of an article sales forecasting apparatus according to an embodiment;
FIG. 6 is a diagram illustrating an internal structure of a computer device according to an embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
The method for predicting the commodity sales amount can be applied to the application environment shown in fig. 1. The database 104 stores data of each of a plurality of influence factors that influence the prediction of the sales amount of the item, such as the item type, the item price, and the item discount. Alternatively, the trained time series prediction model may be stored in the database 104. Alternatively, the timing prediction model is stored in the server cluster 102. The server cluster 102 acquires data of each influence factor in a plurality of influence factors influencing the commodity sales prediction from the database 104, acquires historical sales data of commodities, inputs the historical sales data and the data of each influence factor into a trained time sequence prediction model, and acquires the predicted sales data of commodities output by the time sequence prediction model; the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting predicted sales data based on the time sequence correlation, the data of each influence factor and historical sales data. The time series prediction model may be a transformer model. The time sequence prediction model can learn the time sequence correlation among the input data of each influence factor, has stronger generalization capability, and overcomes the problem of low accuracy of commodity sales prediction caused by a mode that a simple linear model is built based on recent historical data of each time point in the traditional time sequence prediction method. The server cluster 104 may be implemented by a single server or a server cluster composed of a plurality of servers.
In one embodiment, as shown in fig. 2, an item sales forecasting method is provided, which is illustrated by applying the method to the server cluster 104 in fig. 1, and includes the following steps:
s202, data of each influence factor in a plurality of influence factors influencing the goods sales prediction are obtained.
In this embodiment, the article may be a commodity. The influence factor refers to a factor that influences the item sales amount, which is referred to in predicting the item sales amount. The plurality of impact factors may include item categories, item sales prices, item discounts, and the like. If the article is a commodity, the data of each influence factor may include one or more of commodity category data, discount strength data of the commodity, commodity inventory data, holiday data, data on whether the commodity is out of stock, and price data of the commodity.
And S204, acquiring historical sales data of the articles.
In this embodiment, the database stores historical sales data of the articles. The historical sales data may be sales data of the items at any one time point in the historical time period, or sales data of the items at each time point in the historical time periods.
S206, inputting the historical sales data and the data of each influence factor into the trained time sequence prediction model to obtain the predicted sales data of the articles output by the time sequence prediction model; the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting predicted sales data based on the time sequence correlation, the data of each influence factor and historical sales data.
In this embodiment, the trained time sequence prediction model refers to a time sequence prediction model which is obtained by training a preset model by using sample data and can be used for predicting commodity sales. The model training step of the time sequence prediction model comprises the following steps: the method comprises the steps of obtaining sample data of each influence factor in a plurality of influence factors influencing sample article sales volume prediction and sample historical sales volume data of a sample article, obtaining sample predicted sales volume data of the sample article, and conducting model training on a time sequence prediction model by adopting the sample data of each influence factor, the sample historical sales volume data and the sample predicted sales volume data. The sample historical sales data refers to the historical time point as a reference time point, the sales data of the sample articles before the reference time point is used as the sample historical sales data, and the sales data of the sample articles after the reference time point is used as the sample predicted sales data. Therefore, the time-series prediction model obtained after training can be applied to the commodity sales prediction. It should be noted that the sample article may be the same as the article sales prediction object of the present application, that is, the time sequence prediction model is model-trained by using the historical data of the same article. The sample article and the article sales prediction object of the present application may be different, but the sample article and the article sales prediction object of the present application are of the same category, that is, the article of the same category is used for model training of the time sequence prediction model.
The time sequence prediction model adopted by the embodiment is used for determining the time sequence correlation among the data of each influence factor and outputting the predicted sales data based on the time sequence correlation, the data of each influence factor and the historical sales data. The time-series correlation between the data of the respective influence factors may be a time-series correlation of the data between the respective influence factors and/or a time-series correlation between the data of the same influence factor. The time-series correlation may be a time-series relationship of the sequences of data of each influence factor and/or a sequence time-series correlation of the sequences of data of each influence factor.
The time sequence prediction model can learn the time sequence correlation among the input data of each influence factor, has stronger generalization capability, and overcomes the problem of low accuracy of commodity sales prediction caused by a mode that a simple linear model is built based on recent historical data of each time point in the traditional time sequence prediction method. In addition, the time sequence prediction model can output predicted sales data based on time sequence correlation among data of all the influence factors, the data of all the influence factors and historical sales data, and the technical problem that the goods sales prediction is inaccurate due to the data fitting problem and the original data sequence loss problem of the traditional machine learning algorithm is solved, so that the goods sales prediction accuracy is improved.
In one embodiment, the time-series prediction model is a transformer model, the transformer model includes an encoding layer and a decoding layer, and the transformer model is used for determining time-series correlation among data of each influence factor through the encoding layer and the decoding layer and outputting predicted sales data based on the time-series correlation, the data of each influence factor and historical sales data.
In this embodiment, the transform model is a translation model based on the self-attention mechanism, and the transform model does not use methods and modules of CNN (convolutional neural network) and RNN (neural network model), and creatively constructs the attention mechanism as a core of an encoding layer and a decoding layer to execute translation operation. The coding layer is stacked by a plurality of identical layers, each having two sub-layers. The first sub-layer is a Multi-Head Self-Attention mechanism and the second sub-layer is a simple Feed Forward network. Both sub-layers add a residual result and a normalization operation. The decoding layer is stacked by a plurality of identical layers, but with a slightly different structure from each of the encoding layers. For each layer of the decoding layer, besides two sub-layers Multi-Head Self-orientation and Feed Forward, a sub-layer Masked Multi-Head Self-orientation is also included. the structure of the coding layer and the structure of the decoding layer of the transform model can both learn the time-series relationship between input data, however, some conventional model structures, such as CNN (convolutional neural network) and RNN (neural network model), do not pay attention to the time-series relationship between data during data processing, so that more characteristics of data with multiple influencing factors can be paid attention to by using the transform model. In addition, in the data information processing field of the item sales amount prediction, the closer to the data at the current time point or the predicted time, the more valuable the item sales amount prediction is. When the future sales of the articles are predicted, if the time sequence of the data can be introduced, the final sales prediction result is more accurate. In this embodiment, the time-series correlation of the input data can be learned by using the transform model, and therefore the accuracy of the item sales prediction can be improved by using the transform model.
In one embodiment, the inputting the historical sales data and the data of each influence factor into the trained time-series prediction model includes: if the data of a first target influence factor in the plurality of influence factors contains data of a future time point, respectively inputting the data of the first target influence factor into an encoding layer and a decoding layer of a transformer model; if the data of a second target influence factor in the plurality of influence factors does not contain the data of a future time point, inputting the data of the second target influence factor and historical sales data into an encoding layer of a transformer model; and if the data of the third target influence factor in the plurality of influence factors is a fixed value, inputting the data of the third target influence factor into a decoding layer of the transform model.
In this embodiment, during data processing, the data of the first target influence factor is input to the encoding layer and the decoding layer of the transform model, respectively. In a possible implementation manner, the data of the first target influence factor includes data of a historical time point and data of a future time point, the data of the historical time point of the first target influence factor is input into the encoding layer, and the data of the future time point of the first target influence factor is input into the decoding layer. And inputting the data of the second target influence factor and the historical sales data into an encoding layer of the transform model, specifically, splicing the data of the second target influence factor and the historical sales data, and inputting the spliced data into the encoding layer of the transform model. The data of the third target impact factor is input to the decoding layer of the transformer model.
In the prediction of the sales amount of the article, the closer to the data of the current time point or the prediction time, the more valuable the prediction of the sales amount of the article is. In the embodiment, the data of the historical time point of the first target influence factor, the data of the second target influence factor and the historical sales data are all the data of the historical time point, the data of the second target influence factor and the historical sales data are spliced and input into an encoding layer of a transform model, the encoding layer fuses the historical data to obtain feature information of the fused historical data, the integrated feature information is output to a decoding layer, and the decoding layer analyzes the integrated feature information, the data of the future time in the first target influence factor and the data of the third target influence factor to obtain an article sales prediction result. At this time, when the decoding layer performs data processing to analyze the prediction of the commodity sales amount, the decoding layer does not need to pay attention to each historical data, and the overall characteristics of the historical data are taken as the whole of the analysis reference, so that the influence of the long-history data on the prediction analysis can be avoided, and the accuracy of the commodity sales amount prediction can be improved.
In addition, considering that the data of the third target influence factor is a fixed value, that is, the third target influence factor does not change with time, the data of the third target influence factor may be directly input to the decoding layer of the transformer model to perform the feature learning, instead of being input to the encoding layer of the transformer model as history data to perform the feature learning, and the calculation amount of the encoding layer may be reduced. In addition, the third target influence factor does not change along with the change of time, has historical time characteristics and future time characteristics, and is input into a decoding layer for feature learning, so that the accuracy of a final result is not influenced.
In one embodiment, the plurality of influence factors includes a first influence factor, a second influence factor, and a third influence factor, data of the first influence factor varies with time and includes data at a future time point, data of the second influence factor varies with time and does not include data at the future time point, and data of the third influence factor is a fixed value. The inputting of the historical sales data and the data of each influence factor into the trained time sequence prediction model includes: inputting the data of the first influence factor into an encoding layer and a decoding layer of a transformer model respectively; inputting the data of the second influence factor and the historical sales data into an encoding layer of a transform model; the data of the third influencing factor is input to a decoding layer of the transformer model.
In this embodiment, the first influence factor, the second influence factor, and the third influence factor are respectively different influence factors of the plurality of influence factors. In the above example, the data of the first target influence factor includes data of a future time point, the data of the first influence factor varies with time and includes data of the future time point, so that the first target influence factor and the first influence factor refer to the same, or the first target influence factor includes the first influence factor. Similarly, the second target impact factor and the second impact factor refer to the same, or the second target impact factor includes the second impact factor. The third target impact factor and the third impact factor refer to the same.
The data of the first influence factor changes with time and comprises data of a future time point, and the data of the first influence factor are respectively input into an encoding layer and a decoding layer of the transformer model. In a possible implementation, the data of the first impact factor comprises data of historical time points and data of future time points. For example, the historical time points and the future time points are shown in fig. 3. When a window of how many future time points in the future is predicted, the parameter f is used for representing the single-cycle sales prediction when f is equal to 1, and representing the multi-cycle sales prediction when f is larger than 1. In addition, a window of how many historical time points need to be used for prediction is represented by a parameter h. Data at a historical time point of the first influence factor is input into the encoding layer, and data at a future time point of the first influence factor is input into the decoding layer. Where t in fig. 3 represents a time variable, and f and h are both positive integers. The data of the second influence factor changes with time and does not include data of a future time point, and the data of the second influence factor and the historical sales data are input into an encoding layer of the transform model. And inputting the data of the third influence factor into a decoding layer of the transformer model.
In the prediction of the sales amount of the article, the closer to the data of the current time point or the prediction time, the more valuable the prediction of the sales amount of the article is. In the embodiment, the data of the historical time point of the first influence factor, the data of the second influence factor and the data of the historical sales volume are all the data of the historical time point, the data of the second influence factor and the data of the historical sales volume are spliced and input into a coding layer of a transform model, the coding layer fuses the historical data to obtain feature information of the fused historical data, the integrated feature information is output to a decoding layer, and the decoding layer analyzes the integrated feature information, the data of the future time in the first influence factor and the data of the third influence factor to obtain an article sales volume prediction result. At this time, when the decoding layer performs data processing to analyze the prediction of the commodity sales amount, the decoding layer does not need to pay attention to each historical data, and the overall characteristics of the historical data are taken as the whole of the analysis reference, so that the influence of the long-history data on the prediction analysis can be avoided, and the accuracy of the commodity sales amount prediction can be improved.
In addition, considering that the data of the third influence factor is a fixed value, that is, the third influence factor does not change with time, the data of the third influence factor can be directly input to the decoding layer of the transform model for feature learning, but not input to the coding layer of the transform model for feature learning as historical data, and the calculation amount of the coding layer can be reduced. In addition, the third influence factor does not change along with the change of time, has historical time characteristics and future time characteristics, and is input into the decoding layer for feature learning, so that the accuracy of a final result is not influenced.
In one embodiment, the inputting the first data of the first influencing factor into the coding layer and the decoding layer respectively includes: inputting the data of the first sub-influence factor into an encoding layer and a decoding layer respectively; and converting the data of the second sub-influence factor into vectors, and respectively inputting the converted vectors into the coding layer and the decoding layer.
In this embodiment, the first sub-influence factor is a continuous variable that changes over time and is known in the future, e.g., the data of the first sub-influence factor includes discount strength data of the item. The second sub-influence factor is a discrete variable that changes over time and is known in the future, e.g. the data of the second sub-influence factor comprises holiday data of the item. The first sub-influence factor and the second sub-influence factor both comprise data at a historical time point and data at a future time point, the data at the historical time point of the first sub-influence factor and the data at the historical time point of the second sub-influence factor are respectively input into an encoding layer of the transform model, and the data at the future time point of the first sub-influence factor and the data at the future time point of the second sub-influence factor are respectively input into a decoding layer of the transform model.
For example, the transformer model is shown in fig. 4. As shown in fig. 4, Encoder represents an encoding layer or Encoder of a transform model, and Encoder input represents an input of the encoding layer. The Decoder represents a decoding layer or Decoder of a transform model, the Decoder input represents the input of the decoding layer, and the Decoder output represents the output of the decoding layer. t-h +1, t-2 and t-1 … … t represent the time point information of the data input by the Encoder, i.e. the input data are respectively corresponding to the time points of t-h +1, t-2 and t-1 … … t. t +1 and t +2 … … t + f represent time point information of data inputted and outputted by the Decoder, that is, the inputted and outputted data are respectively corresponding to t +1 and t +2 … … t + ff. Wherein t represents a current time point or a historical time point, data input into the encoding layer of the transform model is data of the historical time point, and data input into the decoding layer of the transform model is data of a future time point. In this embodiment, the Encoder input inputs data of historical time points, and data corresponding to h time points in fig. 3. The Decoder input inputs data at future time points, corresponding to the f time points in fig. 3.
And inputting the data of h historical time points into an encoding layer of a transform model and inputting the data of f future time points into a decoding layer of the transform model from the data of the h + f time window related to the first sub-influence factor. In the data of the h + f time window related to the second sub-influence factor, the data of h historical time points are converted into vectors by using embedding (a mode of converting discrete variables into continuous vectors) and then input into the coding layer of the transform model, and the data of f future time points are converted into vectors by using embedding and then input into the decoding layer of the transform model. The data of the first influencing factor can be input into the transform model to predict the commodity sales amount, and therefore, the data of the discrete variable can be input into the transform model by converting the data of the second sub-influencing factor into the vector.
In one embodiment, the inputting the data of the second influence factor to the coding layer of the transform model includes: splicing the data of the third sub-influence factor and the historical sales data, and inputting the spliced data into a coding layer; and converting the data of the fourth sub-influence factor into a vector, and inputting the converted vector into the coding layer.
In this embodiment, the third sub-impact factor is a continuous variable that changes over time and is not known in the future, e.g., the data of the third sub-impact factor includes item inventory data. The fourth sub-influence factor is a discrete variable that changes over time and is unknown in the future, e.g., the data of the fourth sub-influence factor includes data that characterizes whether the item is out of stock. Referring to fig. 4, the data of h time windows related to the third sub-influence factor and the historical sales data are spliced, and the spliced data is input into the coding layer of the transform model. And converting the data of h time windows related to the fourth sub-influence factor into vectors by using embedding, and inputting the vectors into a coding layer of a transformer model. Whether the second influence factor is a continuous variable or a discrete variable, the data of the second influence factor can be input into the transform model to predict the commodity sales amount, so that the data of the discrete variable can be input into the transform model by converting the data of the fourth sub-influence factor into a vector, the limitation that the transform model can only input continuous variable data is overcome, the application of the transform model is expanded, and the accuracy of commodity sales amount prediction by the transform model can be improved.
In one embodiment, the inputting the data of the third influencing factor into the decoding layer of the transform model includes: activating the data of the fifth sub-influence factor into a vector, and inputting the activated vector into a decoding layer; and converting the data of the sixth sub-influence factor into a vector, and inputting the obtained vector into a decoding layer.
In this embodiment, the fifth sub-influence factor is a continuous variable that does not change with time and is always a fixed value, e.g., the data of the fifth sub-influence factor includes price data of the item. The sixth sub-influence factor is a discrete variable that does not change with time and is always a fixed value, e.g., the data of the sixth sub-influence factor includes data of item type. Referring to fig. 4, the data of the fifth sub-influence factor is input to the decoding layer of the transform model after being activated into a vector by a neuron. And converting the data of the sixth sub-influence factor into a one-dimensional vector through embedding, and inputting the one-dimensional vector to a decoding layer of the transformer model. Whether the third influence factor is a continuous variable or a discrete variable, the data of the third influence factor can be input into the transform model to predict the commodity sales amount, so that the data of the discrete variable can be input into the transform model by converting the data of the sixth sub-influence factor into a vector, the limitation that the transform model can only input continuous variable data is overcome, the application of the transform model is expanded, and the accuracy of commodity sales amount prediction by using the transform model can be improved.
The method for predicting the commodity sales volume effectively uses all available factors which have influences on commodity sales volume prediction, can be suitable for various prediction scenes such as single-cycle or multi-cycle, and is higher in accuracy rate and wider in application range of prediction results obtained by the method for predicting the commodity sales volume, so that the intelligent level of a supply chain can be improved.
For the above method for predicting commodity sales, taking a commodity as an example, a specific implementation scenario is given below, and specifically includes the steps of data arrangement, model parameter determination, model construction, model prediction and the like.
Data arrangement: the data is fundamental to any algorithmic model. In the implementation scenario, in combination with the actual retail condition, the data affecting sales volume prediction are classified into the following categories according to whether the data changes with time, whether the data is known in the future, and whether the data is discrete or continuous:
a type: continuous variables that change over time and are known in the future, such as discount strength data for the goods;
b type: continuous variables that change over time and are unknown in the future, such as inventory data for goods;
class C: discrete variables that change over time and are known in the future, such as holiday data;
and D type: discrete variables that change over time and are unknown in the future, such as data on whether goods are out of stock;
and E type: continuous variables which are not changed along with time and are always fixed values, such as price data of commodities;
and F: the data are not changed along with time and are discrete variables of fixed values, such as commodity class data.
Determining model parameters: in addition to the parameters such as the common network size and the learning rate, the size of the time window related to model prediction is also determined in the implementation scenario. As shown in fig. 3, there are mainly two parameters. First, a window of how many time points in the future is predicted, which is expressed by a parameter f, and when f is 1, the prediction is performed for the single-cycle sales amount, and when f is greater than 1, the prediction is performed for the multi-cycle sales amount. Second, how many history windows are used for prediction per sample is represented by a parameter h.
Building a model: and after finishing data sorting and model parameter determination, building a model. Here, modeling is performed based on a transform model that is currently prevailing in the field of NLP (Natural Language Processing), and the overall model architecture is shown in fig. 4. The collected data are sorted and input into a transform model according to the following modes:
inputting data of h + f time windows related to variables of the A class into an Encoder input and a Decoder input of a transform model respectively;
inputting the data of h time windows related to the variables of the B type and historical sales data into an Encoder input;
thirdly, converting the data of the h + f time window related to the variable of the C type into vectors by using embedding, and then respectively inputting the vectors into an Encoder input and a Decoder input;
fourthly, converting the data of h time windows related to the D-type variable into vectors by using embedding, and then respectively inputting the vectors into an Encoder input;
activating a fixed value of an E-type variable into a vector through a neuron and inputting the vector into each Decoder input;
sixthly, converting the variable of the F type into a one-dimensional vector through embedding, and inputting the one-dimensional vector into each Decoder input.
Model prediction: and aiming at the sales prediction of each commodity in f future time periods, related data of the commodity are collected in a traversal mode according to the data sorting mode, the collected data are input into a model according to the model building mode, and the commodity sales prediction data of f future time points output by the model can be obtained.
In conclusion, the article sales prediction method based on the transform deep learning prediction algorithm is provided for the commodity sales prediction scene of the supply chain, and the accuracy of commodity sales prediction can be greatly improved. According to the article sales forecasting method, a unified commodity sales forecasting framework is constructed, the method can be applied to various scenes of commodity sales forecasting of single-cycle and multi-cycle, unified modeling and multi-place reuse are achieved, and the method can be very conveniently implemented and applied in industrial practice. In addition, factors influencing sales prediction are effectively classified, and deep relationships are fully excavated based on the current deep learning technology, so that no important information is lost.
It should be understood that, although the steps in the flowchart are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least a portion of the steps in the flowchart may include multiple sub-steps or multiple stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of performing the sub-steps or stages is not necessarily sequential, but may be performed alternately or alternately with other steps or at least a portion of the sub-steps or stages of other steps.
In one embodiment, as shown in fig. 5, an article sales prediction apparatus is provided, comprising a first obtaining module 502, a second obtaining module 504, and a obtaining module 506, wherein: a first obtaining module 502, configured to obtain data of each impact factor in a plurality of impact factors that affect the prediction of the commodity sales; a second obtaining module 504, configured to obtain historical sales data of the item; an obtaining module 506, configured to input the historical sales data and the data of each impact factor into the trained time sequence prediction model, and obtain predicted sales data of the article output by the time sequence prediction model; the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting predicted sales data based on the time sequence correlation, the data of each influence factor and historical sales data.
In one embodiment, the time-series prediction model is a transformer model, the transformer model includes an encoding layer and a decoding layer, and the transformer model is used for determining time-series correlation among data of each influence factor through the encoding layer and the decoding layer and outputting predicted sales data based on the time-series correlation, the data of each influence factor and historical sales data.
In one embodiment, inputting historical sales data and data for each impact factor to a trained time series prediction model comprises: if the data of a first target influence factor in the plurality of influence factors contains data of a future time point, respectively inputting the data of the first target influence factor into an encoding layer and a decoding layer of a transformer model; if the data of a second target influence factor in the plurality of influence factors does not contain the data of a future time point, inputting the data of the second target influence factor and historical sales data into an encoding layer of a transformer model; and if the data of the third target influence factor in the plurality of influence factors is a fixed value, inputting the data of the third target influence factor into a decoding layer of the transform model.
In one embodiment, the plurality of influence factors include a first influence factor, a second influence factor, and a third influence factor, data of the first influence factor varies with time and includes data at a future time point, data of the second influence factor varies with time and does not include data at the future time point, and data of the third influence factor is a fixed value; inputting historical sales data and data of each influence factor into a trained time sequence prediction model, wherein the method comprises the following steps: inputting the data of the first influence factor into an encoding layer and a decoding layer of a transformer model respectively; inputting the data of the second influence factor and the historical sales data into an encoding layer of a transform model; the data of the third influencing factor is input to a decoding layer of the transformer model.
In one embodiment, the first influencing factor includes a first sub-influencing factor and a second sub-influencing factor, the first sub-influencing factor is a continuous variable, the second sub-influencing factor is a discrete variable, and the inputting of the first data of the first influencing factor into the coding layer and the decoding layer respectively includes: inputting the data of the first sub-influence factor into an encoding layer and a decoding layer respectively; and converting the data of the second sub-influence factor into vectors, and respectively inputting the converted vectors into the coding layer and the decoding layer.
In one embodiment, the second influencing factor includes a third sub-influencing factor and a fourth sub-influencing factor, the third sub-influencing factor is a continuous variable, the fourth sub-influencing factor is a discrete variable, and the inputting of the data of the second influencing factor to the coding layer of the transform model includes: splicing the data of the third sub-influence factor and the historical sales data, and inputting the spliced data into a coding layer; and converting the data of the fourth sub-influence factor into a vector, and inputting the converted vector into the coding layer.
In one embodiment, the third influencing factor includes a fifth sub-influencing factor and a sixth sub-influencing factor, the fifth sub-influencing factor is a continuous variable, the sixth sub-influencing factor is a discrete variable, and the inputting of the data of the third influencing factor to a decoding layer of the transform model includes: activating the data of the fifth sub-influence factor into a vector, and inputting the activated vector into a decoding layer; and converting the data of the sixth sub-influence factor into a vector, and inputting the obtained vector into a decoding layer.
For the specific definition of the article sales prediction apparatus, reference may be made to the above definition of the article sales prediction method, which is not described herein again. The modules in the article sales predicting apparatus may be implemented in whole or in part by software, hardware, or a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as shown in fig. 6. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The database of the computer device is used for storing data of each influence factor in a plurality of influence factors influencing the goods sales prediction and historical sales data. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a method of item sales prediction.
Those skilled in the art will appreciate that the architecture shown in fig. 6 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In one embodiment, a computer device is provided, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, the processor implementing the following steps when executing the computer program: acquiring data of each influence factor in a plurality of influence factors influencing the commodity sales prediction; acquiring historical sales data of the articles; inputting historical sales data and data of each influence factor into a trained time sequence prediction model to obtain predicted sales data of the articles output by the time sequence prediction model; the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting predicted sales data based on the time sequence correlation, the data of each influence factor and historical sales data.
In one embodiment, the time-series prediction model is a transformer model, the transformer model includes an encoding layer and a decoding layer, and the transformer model is used for determining time-series correlation among data of each influence factor through the encoding layer and the decoding layer and outputting predicted sales data based on the time-series correlation, the data of each influence factor and historical sales data.
In one embodiment, when the processor executes the computer program to implement the above step of inputting the historical sales data and the data of each influence factor into the trained time series prediction model, the following steps are specifically implemented: if the data of a first target influence factor in the plurality of influence factors contains data of a future time point, respectively inputting the data of the first target influence factor into an encoding layer and a decoding layer of a transformer model; if the data of a second target influence factor in the plurality of influence factors does not contain the data of a future time point, inputting the data of the second target influence factor and historical sales data into an encoding layer of a transformer model; and if the data of the third target influence factor in the plurality of influence factors is a fixed value, inputting the data of the third target influence factor into a decoding layer of the transform model.
In one embodiment, the plurality of influence factors include a first influence factor, a second influence factor, and a third influence factor, data of the first influence factor varies with time and includes data at a future time point, data of the second influence factor varies with time and does not include data at the future time point, and data of the third influence factor is a fixed value; when the processor executes the computer program to realize the step of inputting the historical sales data and the data of each influence factor into the trained time sequence prediction model, the following steps are specifically realized: inputting the data of the first influence factor into an encoding layer and a decoding layer of a transformer model respectively; inputting the data of the second influence factor and the historical sales data into an encoding layer of a transform model; the data of the third influencing factor is input to a decoding layer of the transformer model.
In an embodiment, the first impact factor includes a first sub-impact factor and a second sub-impact factor, the first sub-impact factor is a continuous variable, the second sub-impact factor is a discrete variable, and when the processor executes the computer program to implement the above step of inputting the first data of the first impact factor into the coding layer and the decoding layer, the following steps are specifically implemented: inputting the data of the first sub-influence factor into an encoding layer and a decoding layer respectively; and converting the data of the second sub-influence factor into vectors, and respectively inputting the converted vectors into the coding layer and the decoding layer.
In an embodiment, the second influence factor includes a third sub-influence factor and a fourth sub-influence factor, the third sub-influence factor is a continuous variable, and the fourth sub-influence factor is a discrete variable, and when the processor executes the computer program to implement the above step of inputting the data of the second influence factor into the encoding layer of the transform model, the following steps are specifically implemented: splicing the data of the third sub-influence factor and the historical sales data, and inputting the spliced data into a coding layer; and converting the data of the fourth sub-influence factor into a vector, and inputting the converted vector into the coding layer.
In an embodiment, the third influencing factor includes a fifth sub-influencing factor and a sixth sub-influencing factor, the fifth sub-influencing factor is a continuous variable, the sixth sub-influencing factor is a discrete variable, and when the processor executes the computer program to implement the above step of inputting the data of the third influencing factor into the decoding layer of the transform model, the following steps are specifically implemented: activating the data of the fifth sub-influence factor into a vector, and inputting the activated vector into a decoding layer; and converting the data of the sixth sub-influence factor into a vector, and inputting the obtained vector into a decoding layer.
In one embodiment, a computer-readable storage medium is provided, having a computer program stored thereon, which when executed by a processor, performs the steps of: acquiring data of each influence factor in a plurality of influence factors influencing the commodity sales prediction; acquiring historical sales data of the articles; inputting historical sales data and data of each influence factor into a trained time sequence prediction model to obtain predicted sales data of the articles output by the time sequence prediction model; the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting predicted sales data based on the time sequence correlation, the data of each influence factor and historical sales data.
In one embodiment, the time-series prediction model is a transformer model, the transformer model includes an encoding layer and a decoding layer, and the transformer model is used for determining time-series correlation among data of each influence factor through the encoding layer and the decoding layer and outputting predicted sales data based on the time-series correlation, the data of each influence factor and historical sales data.
In one embodiment, when the computer program is executed by the processor to implement the above-mentioned step of inputting the historical sales data and the data of each influence factor into the trained time series prediction model, the following steps are implemented: if the data of a first target influence factor in the plurality of influence factors contains data of a future time point, respectively inputting the data of the first target influence factor into an encoding layer and a decoding layer of a transformer model; if the data of a second target influence factor in the plurality of influence factors does not contain the data of a future time point, inputting the data of the second target influence factor and historical sales data into an encoding layer of a transformer model; and if the data of the third target influence factor in the plurality of influence factors is a fixed value, inputting the data of the third target influence factor into a decoding layer of the transform model.
In one embodiment, the plurality of influence factors include a first influence factor, a second influence factor, and a third influence factor, data of the first influence factor varies with time and includes data at a future time point, data of the second influence factor varies with time and does not include data at the future time point, and data of the third influence factor is a fixed value; when the computer program is executed by the processor to realize the step of inputting the historical sales data and the data of each influence factor into the trained time sequence prediction model, the following steps are realized: inputting the data of the first influence factor into an encoding layer and a decoding layer of a transformer model respectively; inputting the data of the second influence factor and the historical sales data into an encoding layer of a transform model; the data of the third influencing factor is input to a decoding layer of the transformer model.
In one embodiment, the first influencing factor includes a first sub-influencing factor and a second sub-influencing factor, the first sub-influencing factor is a continuous variable, the second sub-influencing factor is a discrete variable, and when the computer program is executed by the processor to implement the above-mentioned step of inputting the first data of the first influencing factor into the coding layer and the decoding layer, the following steps are specifically implemented: inputting the data of the first sub-influence factor into an encoding layer and a decoding layer respectively; and converting the data of the second sub-influence factor into vectors, and respectively inputting the converted vectors into the coding layer and the decoding layer.
In one embodiment, the second influencing factor includes a third sub-influencing factor and a fourth sub-influencing factor, the third sub-influencing factor is a continuous variable, and the fourth sub-influencing factor is a discrete variable, and when the computer program is executed by the processor to implement the above-mentioned step of inputting the data of the second influencing factor into the coding layer of the transform model, the following steps are specifically implemented: splicing the data of the third sub-influence factor and the historical sales data, and inputting the spliced data into a coding layer; and converting the data of the fourth sub-influence factor into a vector, and inputting the converted vector into the coding layer.
In one embodiment, the third influencing factor includes a fifth sub-influencing factor and a sixth sub-influencing factor, the fifth sub-influencing factor is a continuous variable, the sixth sub-influencing factor is a discrete variable, and when the computer program is executed by the processor to implement the above-mentioned step of inputting the data of the third influencing factor into the decoding layer of the transform model, the following steps are specifically implemented: activating the data of the fifth sub-influence factor into a vector, and inputting the activated vector into a decoding layer; and converting the data of the sixth sub-influence factor into a vector, and inputting the obtained vector into a decoding layer.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in the embodiments provided herein may include non-volatile and/or volatile memory, among others. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (10)

1. A method of item sales prediction, the method comprising:
acquiring data of each influence factor in a plurality of influence factors influencing the goods sales prediction;
acquiring historical sales data of the articles;
inputting the historical sales data and the data of each influence factor into a trained time sequence prediction model to obtain the predicted sales data of the articles output by the time sequence prediction model;
the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting the predicted sales data based on the time sequence correlation, the data of each influence factor and the historical sales data.
2. The method of claim 1, wherein the time-series prediction model is a transformer model, the transformer model comprising an encoding layer and a decoding layer, the transformer model configured to determine a time-series correlation between data of each of the impact factors by the encoding layer and the decoding layer and output the predicted sales data based on the time-series correlation, the data of each of the impact factors and the historical sales data.
3. The method of claim 2, wherein inputting the historical sales data and the data for each of the impact factors into a trained time series predictive model comprises:
if the data of a first target influence factor in the plurality of influence factors comprises data of a future time point, inputting the data of the first target influence factor into an encoding layer and a decoding layer of the transformer model respectively;
if the data of a second target influence factor in the plurality of influence factors does not contain data of a future time point, inputting the data of the second target influence factor and the historical sales data into an encoding layer of the transformer model;
and if the data of a third target influence factor in the plurality of influence factors is a fixed value, inputting the data of the third target influence factor into a decoding layer of the transformer model.
4. The method of claim 2, wherein the plurality of impact factors includes a first impact factor, a second impact factor, and a third impact factor, wherein data of the first impact factor varies with time and includes data at a future time point, wherein data of the second impact factor varies with time and does not include data at the future time point, and wherein data of the third impact factor is a fixed value;
inputting the historical sales data and the data of each influence factor into a trained time sequence prediction model, wherein the method comprises the following steps:
inputting the data of the first influence factor into an encoding layer and a decoding layer of the transformer model respectively;
inputting the data of the second influence factor and the historical sales data into an encoding layer of the transform model;
inputting data of the third influencing factor to a decoding layer of the transformer model.
5. The method of claim 4, wherein the first influencing factor comprises a first sub-influencing factor and a second sub-influencing factor, the first sub-influencing factor is a continuous variable, the second sub-influencing factor is a discrete variable, and the inputting the first data of the first influencing factor into the coding layer and the decoding layer respectively comprises:
inputting the data of the first sub-influence factor into the coding layer and the decoding layer respectively;
and converting the data of the second sub-influence factor into vectors, and respectively inputting the converted vectors into the coding layer and the decoding layer.
6. The method according to claim 4, wherein the second influence factor comprises a third sub-influence factor and a fourth sub-influence factor, the third sub-influence factor is a continuous variable, and the fourth sub-influence factor is a discrete variable, and the inputting the data of the second influence factor to the coding layer of the transform model comprises:
splicing the data of the third sub-influence factor and the historical sales data, and inputting the spliced data into the coding layer;
and converting the data of the fourth sub-influence factor into a vector, and inputting the converted vector into the coding layer.
7. The method of claim 4, wherein the third impact factor comprises a fifth sub-impact factor and a sixth sub-impact factor, the fifth sub-impact factor is a continuous variable, the sixth sub-impact factor is a discrete variable, and the inputting the data of the third impact factor to a decoding layer of the transform model comprises:
activating the data of the fifth sub-influence factor into a vector, and inputting the vector obtained by activation into the decoding layer;
and converting the data of the sixth sub-influence factor into a vector, and inputting the obtained vector into the decoding layer.
8. An article sales predicting apparatus, comprising:
the system comprises a first acquisition module, a second acquisition module and a third acquisition module, wherein the first acquisition module is used for acquiring data of each influence factor in a plurality of influence factors influencing the goods sales prediction;
the second acquisition module is used for acquiring historical sales data of the articles;
the obtaining module is used for inputting the historical sales data and the data of each influence factor into a trained time sequence prediction model and obtaining the predicted sales data of the articles output by the time sequence prediction model;
the time sequence prediction model is used for determining time sequence correlation among the data of each influence factor and outputting the predicted sales data based on the time sequence correlation, the data of each influence factor and the historical sales data.
9. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the steps of the method of any of claims 1 to 7 are implemented when the computer program is executed by the processor.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
CN202111290485.9A 2021-11-02 2021-11-02 Method and device for predicting commodity sales, computer equipment and storage medium Pending CN114066510A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111290485.9A CN114066510A (en) 2021-11-02 2021-11-02 Method and device for predicting commodity sales, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111290485.9A CN114066510A (en) 2021-11-02 2021-11-02 Method and device for predicting commodity sales, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114066510A true CN114066510A (en) 2022-02-18

Family

ID=80236543

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111290485.9A Pending CN114066510A (en) 2021-11-02 2021-11-02 Method and device for predicting commodity sales, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114066510A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115829611A (en) * 2022-12-05 2023-03-21 杭州登卓科技有限公司 Performance management method and system based on data processing
CN116843378A (en) * 2023-09-01 2023-10-03 阳信东泰精密金属有限公司 Hardware fitting supply prediction method and system based on deep learning

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180300737A1 (en) * 2017-04-17 2018-10-18 Nexosis, Inc. Methods and apparatus for self-adaptive time series forecasting engine
CN109886747A (en) * 2019-02-22 2019-06-14 网易(杭州)网络有限公司 Method for Sales Forecast method, medium, device and calculating equipment
CN111080032A (en) * 2019-12-30 2020-04-28 成都数之联科技有限公司 Load prediction method based on Transformer structure
CN112925271A (en) * 2019-12-06 2021-06-08 阿里巴巴集团控股有限公司 Data processing method, automatic control method and device
CN113313316A (en) * 2021-06-11 2021-08-27 北京明略昭辉科技有限公司 Method and device for outputting prediction data, storage medium and electronic equipment
CN113554450A (en) * 2020-04-24 2021-10-26 阿里巴巴集团控股有限公司 Data model training and data processing method, device, equipment and storage medium

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180300737A1 (en) * 2017-04-17 2018-10-18 Nexosis, Inc. Methods and apparatus for self-adaptive time series forecasting engine
CN109886747A (en) * 2019-02-22 2019-06-14 网易(杭州)网络有限公司 Method for Sales Forecast method, medium, device and calculating equipment
CN112925271A (en) * 2019-12-06 2021-06-08 阿里巴巴集团控股有限公司 Data processing method, automatic control method and device
CN111080032A (en) * 2019-12-30 2020-04-28 成都数之联科技有限公司 Load prediction method based on Transformer structure
CN113554450A (en) * 2020-04-24 2021-10-26 阿里巴巴集团控股有限公司 Data model training and data processing method, device, equipment and storage medium
CN113313316A (en) * 2021-06-11 2021-08-27 北京明略昭辉科技有限公司 Method and device for outputting prediction data, storage medium and electronic equipment

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
XINYUAN QI ET AL.: ""From Known to Unknown: Knowledge-guided Transformer for Time-Series Sales Forecasting in Alibaba", 《ARXIV》 *
XINYUAN QI ET AL.: ""From Known to Unknown: Knowledge-guided Transformer for Time-Series Sales Forecasting in Alibaba", 《ARXIV》, 22 September 2021 (2021-09-22), pages 1 - 11 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115829611A (en) * 2022-12-05 2023-03-21 杭州登卓科技有限公司 Performance management method and system based on data processing
CN116843378A (en) * 2023-09-01 2023-10-03 阳信东泰精密金属有限公司 Hardware fitting supply prediction method and system based on deep learning

Similar Documents

Publication Publication Date Title
CN109165664B (en) Attribute-missing data set completion and prediction method based on generation of countermeasure network
US20150254554A1 (en) Information processing device and learning method
CN108876044B (en) Online content popularity prediction method based on knowledge-enhanced neural network
CN114066510A (en) Method and device for predicting commodity sales, computer equipment and storage medium
Pirani et al. A comparative analysis of ARIMA, GRU, LSTM and BiLSTM on financial time series forecasting
JP6971514B1 (en) Information processing equipment, information processing methods and programs
CN114971748B (en) Prediction data generation method, model training method, computer device, and storage medium
CN111950810B (en) Multi-variable time sequence prediction method and equipment based on self-evolution pre-training
CN112884230A (en) Power load prediction method and device based on multivariate time sequence and related components
CN115545300B (en) Method and device for predicting user behavior based on graph neural network
CN111127104A (en) Commodity sales prediction method and system
Zhu et al. Parallel interaction spatiotemporal constrained variational autoencoder for soft sensor modeling
CN116897356A (en) Operator scheduling run time comparison method, device and storage medium
CN115983497A (en) Time sequence data prediction method and device, computer equipment and storage medium
CN114037139A (en) Freight vehicle warehouse stay time length prediction method based on attention mechanism
JPH06337852A (en) Time series prediction method by neural network
CN117422306A (en) Cross-border E-commerce risk control method and system based on dynamic neural network
Jadli et al. A Novel LSTM-GRU-Based Hybrid Approach for Electrical Products Demand Forecasting.
CN115374284B (en) Data mining method and server based on artificial intelligence
CN116051160A (en) Prediction method, prediction device and storage medium for accessory demand
CN115809928A (en) Project investment decision-making method and system
CN116051159A (en) Prediction method, prediction device and storage medium for accessory demand
CN111782802B (en) Method and system for obtaining commodity corresponding to national economy manufacturing industry based on machine learning
CN116109339A (en) Prediction method, prediction device and storage medium for accessory demand
CN114897274A (en) Method and system for improving time sequence prediction effect

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20220218