E-commerce enterprise inventory demand prediction method
By performing DB1 wavelet decomposition and grouping training on historical demand data, an exponential prediction model was established, which solved the problem of high complexity of the LSTM network model and achieved accurate prediction of inventory demand.
Patent Information
- Application Number
- CN202411450822.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-17
- Publication Date
- 2025-02-07
AI Technical Summary
The existing LSTM network has high model complexity during inventory prediction, requires a large number of data sets to be trained, and needs to be retrained when the inventory model changes.
DB1 wavelet is used to decompose the historical demand data in one layer, and the decomposed sequences are grouped. The prediction model is trained using the grouping training data. The model is in the form of an exponential function, and the parameters are initialized through random assignment.
It reduces the complexity of the inventory prediction model, does not require a large amount of training data, and can effectively predict inventory demand, with low errors between the predicted value and the actual value.
Smart Images

Figure CN119398664A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of inventory forecasting, and in particular to a method for forecasting inventory demand of an e-commerce enterprise. Background Art
[0002] In the fierce market competition, inventory management can enhance the competitiveness of enterprises. Reasonable inventory management level can effectively improve customer management level. Reasonable inventory management can reduce enterprise costs. By reasonably predicting inventory demand and improving supply chain management level, enterprises can avoid excessive inventory pressure, reduce inventory and warehousing costs, and optimize enterprise capital allocation.
[0003] Reasonable inventory management helps to reduce supply chain pressure. By accurately predicting inventory demand and replenishing in time, the risk of out-of-stock in the enterprise warehouse can be reduced, market changes can be improved, the enterprise inventory turnover rate can be improved, and the enterprise's operating efficiency can be improved. Unreasonable inventory purchases will cause the number of warehouse products to exceed the actual demand, resulting in product inventory backlogs, increased inventory pressure, and increased capital pressure, which is not conducive to enterprise operations. Unreasonable inventory purchases may cause the number of warehouse products to be less than the actual demand, resulting in out-of-stock and inability to ship, affecting consumers' shopping experience and causing losses to the company. At present, there are few publicly available documents and patents, and the enterprise inventory demand prediction methods are relatively few and the accuracy is not high, and it is impossible to accurately predict changes in enterprise inventory demand.
[0004] The patent publication number is CN118429000A. It obtains the demand time series data of a preset time period and constructs the original demand matrix; performs differential processing to obtain a new data matrix; constructs an LSTM neural network model, outputs the prediction results, and performs corresponding processing to obtain the final output results. Predictions are made by constructing an LSTM neural network, but the neural network model requires a large amount of data sets for training. When the inventory model changes, the model needs to be retrained, and the neural network model is highly complex. Summary of the invention
[0005] In view of the shortcomings of the existing methods, the present invention solves the problem of high model complexity when the existing LSTM network is used for inventory forecasting.
[0006] The technical solution adopted by the present invention is: a method for predicting inventory demand of an e-commerce enterprise comprises the following steps:
[0007] Step 1: Collect the historical demand data of the enterprise warehouse and decompose the historical demand data;
[0008] As a preferred implementation of the present invention, the historical demand data is decomposed by using DB1 wavelet to perform one-layer decomposition.
[0009] Step 2: Group the decomposed sequences to obtain group training data;
[0010] As a preferred implementation of the present invention, grouping training data is to divide the decomposed sequence into several groups of data, each group of data contains several data.
[0011] Step 3: Use the group training data and the corresponding historical demand data to train the prediction model to obtain the training parameters of the prediction model, input the data to be predicted into the trained prediction model to obtain the prediction result;
[0012] As a preferred embodiment of the present invention, the formula of the prediction model is:
[0013]
[0014] Among them, ω i , β i and θ i is the parameter of the prediction model, g() is the exponential function, t is the number of days to be predicted, z i Enter the data to be predicted.
[0015] As a preferred embodiment of the present invention, the formula of the exponential function is:
[0016]
[0017] Among them, x is the independent variable.
[0018] As a preferred embodiment of the present invention, i , β i A random number between -1 and 1.
[0019] As a preferred embodiment of the present invention, an inventory demand forecasting system for an e-commerce enterprise includes: a memory for storing instructions executable by a processor; and a processor for executing the instructions to implement an inventory demand forecasting method for an e-commerce enterprise.
[0020] As a preferred embodiment of the present invention, a computer-readable medium stores computer program code, and the computer program code implements an e-commerce enterprise inventory demand forecasting method when executed by a processor.
[0021] Beneficial effects of the present invention:
[0022] 1. The warehouse historical demand data is decomposed into a sequence by DB1 wavelet analysis, and then the processed data and historical data are respectively trained to determine the prediction model. Then the trained prediction model is used to predict the inventory demand of the enterprise, which can more accurately predict the warehouse demand and has certain social benefits.
[0023] 2. The prediction model is an exponential model. On the basis of the exponential model, the summation model is used to effectively predict the inventory data. The error between the predicted value and the actual value is low. Compared with the LTSM network model, it does not require a large amount of training data and the complexity is significantly reduced, which can effectively predict the inventory. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] Figure 1 It is a flow chart of the inventory demand forecasting method for e-commerce enterprises of the present invention. DETAILED DESCRIPTION
[0025] The present invention is further described below in conjunction with the accompanying drawings and embodiments. This figure is a simplified schematic diagram, which only illustrates the basic structure of the present invention in a schematic manner, and therefore it only shows the components related to the present invention.
[0026] like Figure 1 As shown, a method for predicting inventory demand of an e-commerce enterprise includes the following steps:
[0027] The experimental data is the daily demand data of a product in a certain e-commerce warehouse of a certain company. The data was measured continuously for four weeks, totaling 28 days, and a total of 28 data were measured. The 28 measured data are listed in Table 1.
[0028] Table 1 Historical demand data
[0029]
[0030] The present invention will be further described below in conjunction with the accompanying drawings and embodiments.
[0031] Step 1: Get the historical demand data of the enterprise warehouse for the previous 28 days i =[y1,y2,...y i ], i = 1, 2, 3, ..., 28, as training data, the historical demand data is decomposed by DB1 wavelet, and the sequence d is obtained by DB1 decomposition. i =[d1,d2,...d i ],i=1,2,3,...,28; other data decomposition methods may also be used, such as COIF1, DB3 and DB4 wavelets.
[0032] In this example, the outbound data of a product of a certain company is used as the model training data, and the historical outbound data y of the enterprise warehouse for 28 days is taken. i =[563,635,418,389,632,356,431,552,289,815,785,325,286,330,741,531,863,462,334,612,695,330,299,417,469,596,665,397], as training data, the sequence is obtained after DB1 wavelet 1 layer decomposition
[0033] d i =[847.1139239,570.6351724,698.6214998,695.0859659,780.6458864,784.8885271,435.5777772,899.4398257,936.9164851,668.923015,724.7844507,506.2884553,753.068722,750.9474016,-50 .91168825,20.50609665,195.1614716,-85.55992052,-371.9381669,325.2691193,-31.11269837,148.492424,283.5498193,-196.5756852,258.0939751,-83.43860018,-89.80256121,189.5046174].
[0034] Step 2: Decompose the sequence d in step 1 i =[d1,d2,...d i ], i = 1, 2, 3, ..., 28, grouping, 28 data into 21 groups, each group contains 7 data, get the group training data x during training j,f , and the sequence y i =[y1,y2,...y i ], i = 1, 2, 3, ..., 28, the first 21 data are used as the corresponding model training output data t j , j is the group number, j = 1, 2, ..., 21, f is the number of the data in each group f = 1, 2, ..., 7;
[0035] In this embodiment, the 28 data d obtained by DB1 wavelet 1 layer decomposition are i =[d1,d2,...d i ], divided into 21 prediction model training groups, where the 2nd to 8th data are used as the first group of input data for model training, x 1,f =[570.6351724,698.6214998,…,899.4398257],f=1,2,…,7, with sequence y i =[y1,y2,...y i ] is used as the corresponding output value t1=563 in the training process, with d i =[d1,d2,...d iThe 3rd to 9th data in the sequence are used as the second set of input data for model training, x 2,f =[698.6214998,695.0859659,…,,936.9164851],f=1,2,…,7, with sequence y i =[y1,y2,...y i ] is used as the corresponding output value t2=635 in the training process, and so on. i =[d1,d2,...d i ] The 22nd to 28th data in the sequence are used as the 21st group of input data for model training, x 21,f =[148.492424,283.5498193,…,,6121,189.5046174],f=1,2,…,7, with sequence y i =[y1,y2,...y i ] is used as the corresponding output value t in the training process. 21 =695.
[0036] Step 3: Group training data x obtained in step 2 j,f And t are input into the prediction model for training and the parameters of the prediction model are determined: ω i ,θ i , β i , i=1,2,…,7, where the training model is:
[0037]
[0038] In the prediction model of formula (3) above β i ,ω i and θ i ,i=1,2,3,…,7, are the parameters of the prediction model; x j,f , j = 1, 2, 3, ..., 21, f = 1, 2, ..., 7, are the corresponding group input data in the training process; t j , j = 1, 2, 3, ..., 21, is the corresponding output comparison data in the training process; first, the parameter ω i and θ i Assign a random number between -1 and 1, save it, and then j,f ,t j ,ω i and θ i Substitute into formula (1) to determine the parameter β i , then we get the ω corresponding to the prediction model i ,θ i and β i The value of i ,θi and β i They are all put in the following table:
[0039] Table 2ω i Parameters
[0040] Serial number 1 2 3 4 5 6 7 Numeric 0.93261 -0.12638 0.20069 -0.12541 -0.46122 0.602516 0.021357
[0041] Table 3θ i Parameters
[0042] Serial number 1 2 3 4 5 6 7 Numeric 0.268157 0.833622 0.991852 -0.484136 0.263325 -0.579361 0.502587
[0043] Since the parameter ω i , b i Randomly assign values to initialize the values as shown in the table above, and finally train to obtain β i The values are shown in the following table:
[0044] Table 4β i Parameters
[0045] Serial number 1 2 3 4 5 6 7 Numeric -0.61251 0.9352 2.35615 3.27861 -0.26354 0.89501 4.40812
[0046] Step 4: Use the prediction model trained in step 3 to predict e-commerce warehouse demand.
[0047] The enterprise inventory demand data y1, y2, ..., y7 for the 7 days before the forecast are decomposed by db1 wavelet 1 layer to obtain z1, z2, ..., z7 as input data, and z1, z2, ..., z7 are input into the trained forecast model for forecasting. The forecast expression is:
[0048]
[0049] Among them, ω i , β i and θ i are the parameters of the prediction model, t is the number of days to be predicted, z i is the input data to be predicted, in this embodiment, t=7, as shown in the following table:
[0050] Table 5 Enterprise inventory demand data display
[0051] Serial number <![CDATA[y1]]> <![CDATA[y2]]> <![CDATA[y3]]> <![CDATA[y4]]> <![CDATA[y5]]> <![CDATA[y6]]> <![CDATA[y7]]> 1 591 687 423 396 628 718 639 2 541 591 687 423 396 628 718 3 434 541 591 687 423 396 628 4 393 434 541 591 687 423 396 5 288 393 434 541 591 687 423
[0052] Table 6 Display of input values, predicted values, and actual values
[0053]
[0054]
[0055] It can be seen from the experimental results that each predicted value is relatively close to the actual value, indicating that this method can be used to predict the inventory demand of e-commerce enterprises, verifying the effectiveness of the method used in the present invention.
[0056] Based on the above ideal embodiments of the present invention, the relevant staff can make various changes and modifications without departing from the technical concept of the present invention through the above description. The technical scope of the present invention is not limited to the contents of the specification, and its technical scope must be determined according to the scope of the claims.
Claims
1. A method for predicting inventory demand of an e-commerce enterprise, characterized in that: The following steps are involved: Step 1: Collect the historical demand data of the enterprise warehouse and decompose the historical demand data; Step 2: Group the decomposed sequences to obtain group training data; Step 3: Use the grouped training data and the corresponding historical demand data to train the prediction model to obtain the training parameters of the prediction model, input the data to be predicted into the trained prediction model to obtain the prediction result.
2. The method for predicting inventory demand of an e-commerce enterprise according to claim 1, characterized in that: The formula of the prediction model is: Among them, ω i , β i and θ i is the parameter of the prediction model, g() is the exponential function, t is the number of days to be predicted, z i Enter the data to be predicted.
3. The method for predicting inventory demand of an e-commerce enterprise according to claim 2, characterized in that: The formula for the exponential function is: Among them, x is the independent variable.
4. The method for predicting inventory demand of an e-commerce enterprise according to claim 2, characterized in that: ω i , β i A random number between -1 and 1.
5. The method for predicting inventory demand of an e-commerce enterprise according to claim 1, characterized in that: The historical demand data is decomposed using DB1 wavelet for 1-layer decomposition.
6. The method for predicting inventory demand of an e-commerce enterprise according to claim 1, characterized in that: Grouping training data is to divide the decomposed sequence into several groups of data, each group of data contains several data.
7. E-commerce enterprise inventory demand forecasting system, characterized by: include: a memory for storing instructions executable by a processor; A processor, configured to execute instructions to implement the method for predicting inventory demand of an e-commerce enterprise as described in any one of claims 1 to 6.
8. A computer readable medium storing a computer program code, characterized in that: When the computer program code is executed by a processor, the method for predicting inventory demand of an e-commerce enterprise as described in any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Intelligent inventory prediction method, system, device and medium
CN118429000A