CN111242284A - Prediction method and device - Google Patents

Prediction method and device Download PDF

Info

Publication number
CN111242284A
CN111242284A CN202010024231.1A CN202010024231A CN111242284A CN 111242284 A CN111242284 A CN 111242284A CN 202010024231 A CN202010024231 A CN 202010024231A CN 111242284 A CN111242284 A CN 111242284A
Authority
CN
China
Prior art keywords
moment
transaction amount
predicted
time
prediction
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
CN202010024231.1A
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.)
Alipay Hangzhou Information Technology Co Ltd
Original Assignee
Alipay Hangzhou Information Technology 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 Alipay Hangzhou Information Technology Co Ltd filed Critical Alipay Hangzhou Information Technology Co Ltd
Priority to CN202010024231.1A priority Critical patent/CN111242284A/en
Publication of CN111242284A publication Critical patent/CN111242284A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • 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/044Recurrent networks, e.g. Hopfield networks
    • 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
    • G06N3/084Backpropagation, e.g. using gradient descent
    • 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
    • G06Q10/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • 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
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Economics (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Biomedical Technology (AREA)
  • Mathematical Physics (AREA)
  • Artificial Intelligence (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Strategic Management (AREA)
  • Biophysics (AREA)
  • General Business, Economics & Management (AREA)
  • Human Resources & Organizations (AREA)
  • Development Economics (AREA)
  • Finance (AREA)
  • Marketing (AREA)
  • Accounting & Taxation (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Tourism & Hospitality (AREA)
  • Quality & Reliability (AREA)
  • Operations Research (AREA)
  • Game Theory and Decision Science (AREA)
  • Technology Law (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiment of the specification provides a prediction method and a prediction device, wherein the prediction method comprises the steps of obtaining historical transaction amount of a shop at the t-th time and variables of the shop; inputting the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount of each moment in a time interval from the t +1 th moment to the t + i th moment, wherein i is a positive integer; inputting the predicted transaction amount of each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount of each moment; according to the prediction method, after the predicted transaction amount of the shop at each time in the time interval from the t +1 th time to the t + i th time in the future is predicted through the prediction model, the predicted transaction data of the predicted future time are corrected through a statistical time sequence prediction algorithm and a machine learning time sequence algorithm, and the predicted transaction amount of the shop at the future time is more accurate through a method of combining the machine learning prediction model and the time sequence prediction algorithm.

Description

Prediction method and device
Technical Field
The embodiment of the specification relates to the technical field of computers, in particular to a prediction method. One or more embodiments of the present specification also relate to a prediction apparatus, a computing device, and a computer-readable storage medium.
Background
With the development of data technology, in order to reduce operation risk, in many trading scenarios, future trading data needs to be predicted to perform profit-and-loss control.
In the conventional technology, prediction is usually performed by using a time-series prediction method, which has a poor effect on long-term prediction and non-periodic category (such as food, clothing, etc.), so that it is required to provide a more accurate prediction method of transaction amount.
Disclosure of Invention
In view of this, the embodiments of the present disclosure provide a prediction method. One or more embodiments of the present disclosure are also directed to a prediction apparatus, a computing device, and a computer-readable storage medium, which solve the technical problems of the prior art.
According to a first aspect of embodiments herein, there is provided a prediction method, including:
acquiring historical transaction amount of a shop at the t-th moment and variables of the shop;
inputting the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount of each moment in a time interval from the t +1 th moment to the t + i th moment, wherein i is a positive integer;
and inputting the predicted transaction amount at each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount at each moment.
Optionally, after acquiring the historical transaction amount of the store at the time t and the variables of the store, the method further includes:
and calculating by a preset linear recursion algorithm based on the historical transaction amount to obtain the calculated and predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment.
Optionally, after the predicted transaction amount at each time is input into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount at each time, the method further includes:
and obtaining a target predicted trading amount by an exponential smoothing method based on each predicted trading amount, the corrected predicted trading amount of each predicted trading amount at the corresponding moment and the calculated predicted trading amount.
Optionally, the obtaining the historical transaction amount of the shop at the time t includes:
and acquiring historical transaction amount of the shop at the t-th time and historical transaction amount of the shop at the t-th time.
Optionally, the preset linear recursion algorithm includes a same-proportion algorithm;
the calculating based on the historical transaction amount through a preset linear recursion algorithm, and the obtaining of the calculated predicted transaction amount at each moment in the time interval from the t +1 th moment to the t + i th moment comprises:
determining a transaction comparably increased value at a t-th moment based on a historical transaction amount at the t-th moment of the store and a historical transaction amount at the t-th moment of the history;
and obtaining the calculated and predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction comparability increment value at the t th moment.
Optionally, the obtaining the historical transaction amount of the shop at the time t includes:
and acquiring the historical transaction amount of the shop at the t-1 moment.
Optionally, the preset linear recursion algorithm includes a loop ratio algorithm;
the calculating based on the historical transaction amount through a preset linear recursion algorithm, and the obtaining of the calculated predicted transaction amount at each moment in the time interval from the t +1 th moment to the t + i th moment comprises:
determining a transaction ring ratio increment value of each moment in a time interval from the t +1 th moment to the t + i th moment based on the historical transaction amount of the shop at the t-1 th moment;
and obtaining the calculated predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction ring ratio increment value.
Optionally, the preset prediction model comprises a long-term and short-term memory network model;
inputting the historical transaction amount and the variable into a preset prediction model to obtain the predicted transaction amount at each moment in a time interval from the t +1 th moment to the t + i th moment, wherein the step of obtaining the predicted transaction amount at each moment comprises the following steps:
and inputting the historical transaction amount and the variable into the long-short term memory network model to obtain the predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment.
Optionally, the preset time sequence prediction algorithm includes a kalman filtering algorithm;
inputting the predicted transaction amount of each moment into a preset time sequence prediction algorithm to obtain the corrected predicted transaction amount of each moment comprises the following steps:
and inputting the predicted transaction amount at each moment into a preset Kalman filtering algorithm to obtain the corrected predicted transaction amount at each moment.
Optionally, after obtaining the target predicted transaction amount by an exponential smoothing method based on each predicted transaction amount and the corrected predicted transaction amount of each predicted transaction amount at the corresponding time, the calculating the predicted transaction amount further includes:
and adjusting the item amount of the shop based on the target predicted transaction amount.
According to a second aspect of embodiments herein, there is provided a prediction apparatus comprising:
the data acquisition module is configured to acquire historical transaction amount of a shop at the t-th moment and the variable of the shop;
the data prediction module is configured to input the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount at each moment in a time interval from a t +1 th moment to a t + i th moment, wherein i is a positive integer;
and the data correction module is configured to input the predicted transaction amount at each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount at each moment.
Optionally, the apparatus further includes:
and the data calculation module is configured to calculate through a preset linear recursion algorithm based on the historical transaction amount to obtain a calculated and predicted transaction amount at each moment in a time interval from the t +1 th moment to the t + i th moment.
Optionally, after the apparatus, the apparatus further includes:
and the target data determination module is configured to obtain a target predicted transaction amount through an exponential smoothing method based on each predicted transaction amount, the corrected predicted transaction amount of each predicted transaction amount at the corresponding moment and the calculated predicted transaction amount.
Optionally, the data obtaining module is further configured to:
and acquiring historical transaction amount of the shop at the t-th time and historical transaction amount of the shop at the t-th time.
Optionally, the preset linear recursion algorithm includes a same-proportion algorithm;
the data prediction module further configured to:
determining a transaction comparably increased value at a t-th moment based on a historical transaction amount at the t-th moment of the store and a historical transaction amount at the t-th moment of the history;
and obtaining the calculated and predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction comparability increment value at the t th moment.
Optionally, the data obtaining module is further configured to:
and acquiring the historical transaction amount of the shop at the t-1 moment.
Optionally, the preset linear recursion algorithm includes a loop ratio algorithm;
the data prediction module further configured to:
determining a transaction ring ratio increment value of each moment in a time interval from the t +1 th moment to the t + i th moment based on the historical transaction amount of the shop at the t-1 th moment;
and obtaining the calculated predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction ring ratio increment value.
Optionally, the preset prediction model comprises a long-term and short-term memory network model;
the data prediction module further configured to:
and inputting the historical transaction amount and the variable into the long-short term memory network model to obtain the predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment.
Optionally, the preset time sequence prediction algorithm includes a kalman filtering algorithm;
the data modification module is further configured to:
and inputting the predicted transaction amount at each moment into a preset Kalman filtering algorithm to obtain the corrected predicted transaction amount at each moment.
Optionally, the apparatus further includes:
and the quota adjusting module is configured to adjust the project quota of the shop based on the target predicted transaction amount.
According to a third aspect of embodiments herein, there is provided a computing device comprising:
a memory and a processor;
the memory is to store computer-executable instructions, and the processor is to execute the computer-executable instructions to:
acquiring historical transaction amount of a shop at the t-th moment and variables of the shop;
inputting the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount of each moment in a time interval from the t +1 th moment to the t + i th moment, wherein i is a positive integer;
and inputting the predicted transaction amount at each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount at each moment.
According to a fourth aspect of embodiments herein, there is provided a computer-readable storage medium storing computer-executable instructions that, when executed by a processor, implement the steps of the prediction method.
The embodiment of the specification provides a prediction method and a prediction device, wherein the prediction method comprises the steps of obtaining historical transaction amount of a shop at the t-th time and variables of the shop; inputting the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount of each moment in a time interval from the t +1 th moment to the t + i th moment, wherein i is a positive integer; inputting the predicted transaction amount of each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount of each moment;
according to the prediction method, after the predicted transaction amount of the shop at each time in the time interval from the t +1 th time to the t + i th time in the future is predicted through the prediction model, the predicted transaction data of the predicted future time are corrected through a statistical time sequence prediction algorithm and a machine learning time sequence algorithm, and the predicted transaction amount of the shop at the future time is more accurate through a method of combining the machine learning prediction model and the time sequence prediction algorithm.
Drawings
FIG. 1 is a flow chart of a prediction method provided by one embodiment of the present description;
FIG. 2 is a schematic diagram of a KF long period prediction method provided in one embodiment of the present description;
FIG. 3 is a diagram illustrating the KF long period prediction results provided in one embodiment of the present description;
fig. 4 is a schematic diagram illustrating a correction of a KF long period prediction method of a prediction method according to an embodiment of the present disclosure;
FIG. 5 is a schematic flow chart of a prediction method according to an embodiment of the present disclosure;
FIG. 6 is a schematic diagram illustrating the accuracy of a prediction result of a prediction method according to an embodiment of the present disclosure;
FIG. 7 is a schematic diagram illustrating stability of predicted results of a prediction method according to an embodiment of the present disclosure;
FIG. 8 is a graphical illustration of a TMAE indicator in the prediction result of a prediction method according to an embodiment of the disclosure;
fig. 9 is a diagram illustrating SMAPE indicators in the prediction result of a prediction method according to an embodiment of the present disclosure;
FIG. 10 is a schematic structural diagram of a prediction apparatus according to an embodiment of the present disclosure;
fig. 11 is a block diagram of a computing device according to an embodiment of the present disclosure.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present description. This description may be embodied in many different forms and should not be construed as limited to the embodiments set forth herein, as those skilled in the art will be able to make and use the present disclosure without departing from the spirit and scope of the present disclosure.
The terminology used in the description of the one or more embodiments is for the purpose of describing the particular embodiments only and is not intended to be limiting of the description of the one or more embodiments. As used in one or more embodiments of the present specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used in one or more embodiments of the present specification refers to and encompasses any and all possible combinations of one or more of the associated listed items.
It will be understood that, although the terms first, second, etc. may be used herein in one or more embodiments to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, a first can also be referred to as a second and, similarly, a second can also be referred to as a first without departing from the scope of one or more embodiments of the present description. The word "if" as used herein may be interpreted as "at … …" or "when … …" or "in response to a determination", depending on the context.
First, the noun terms to which one or more embodiments of the present specification relate are explained.
KF: english is called as a whole: kalman Filter, Chinese full name: kalman filter, an adaptive signal filtering algorithm.
LSTM: english is called as a whole: long-shorttermmemory, chinese full name: a long-short term memory model, an open sequence deep learning algorithm, is a special RNN model and is provided for solving the problem of gradient diffusion of the RNN model.
LR: english is called as a whole: logistic Regression, Chinese full name: logistic regression is a classification model in traditional machine learning.
GBDT: english is called as a whole: the Gradient Boosting Decision Tree is named in Chinese: gradient Boosting iterative decision tree, GBDT is also one of Boosting algorithms, and GBDT model is an integrated model.
RNN: english is called as a whole: the Chinese full name is as follows: a recurrent neural network, a disclosed sequence deep learning algorithm, is a neural network that can predict the future (to some extent), and can be used to analyze time series data.
ARIMA: english is called as a whole: autoregrictive Integrated Moving Average model, full name of Chinese: the method comprises the following steps of a differential integration moving average autoregressive model, a regression-based signal filtering algorithm and one of time series prediction analysis methods.
TMAE: english is called as a whole: total Mean Absolute Error, a prediction accuracy assessment method based on a global Error assessment curve.
SMAPE: english is called as a whole: symmetry Mean Absolute percent Percentage Error, Chinese full name: symmetric mean absolute percentage error, a method for estimating prediction accuracy based on a single point error estimation curve.
Comparing: the year-to-year ratio is generally the ratio of the nth month of this year to the nth month of the last year, and the calculation formula is as follows: the concordant development speed is the development level of the current stage/the concordant level of the last year multiplied by 100 percent; the growth rate of year-on-year is (development level of this stage-year-on-year level)/year-on-year level x 100%.
In the present specification, a prediction method is provided, and the present specification relates to a prediction apparatus, a computing device, and a computer-readable storage medium, which are described in detail in the following embodiments one by one.
Referring to fig. 1, fig. 1 shows a flowchart of a prediction method provided according to an embodiment of the present disclosure, including steps 102 to 106.
Step 102: acquiring historical transaction amount of a shop at the t-th time and the variable of the shop.
Where time may represent hours, days, months, etc., the tth time may be understood as hours, days, months, etc. In the embodiments of the present specification, the time t is expressed as the month of the current year in the present specification for the purpose of combining with practical applications, but does not affect that in other specific applications, the time t needs to be understood as the hour of the day or the day of the month, and the like, and is not limited herein.
In the case that the time t can represent the 5 th month of the current year, acquiring the historical trading volume of the shop at the time t can be understood as acquiring the trading volume of the shop at the 5 th month of the current year and all the trading volumes of the shop before the 5 th month; for example, if the month 5 of the current year is month 5 of 2019, and the store is open in month 3 of 2018, then the historical transaction amount at the time t of the store is obtained, and the historical transaction amount of each month from month 5 of 2019 to month 3 of 2018 of the store is obtained. The stores include, but are not limited to, any type of stores with any attribute, such as an online store, an offline store, a store selling clothes, a store selling foods, and the like.
In practical applications, the variables of the store include, but are not limited to, basic attributes of the store, transaction conditions of the store, evaluation conditions of the store, complaints of the store, penalties of the store, operation conditions of the store, and the like, wherein,
the basic attributes of the store include, but are not limited to, the business hours of the store, etc.; the transaction condition of the shop includes but is not limited to the number of monthly copies of the shop with transaction amount in the last N months, transaction number, transaction volume per transaction, the average amount of purchased commodities of each customer, and the like; the evaluation conditions of the stores comprise but are not limited to the number, proportion and the like of good scores/bad scores of the stores laid in the last N months; the complaint condition of the shop comprises but is not limited to the complaint number of the shop in the last N months and the like; the penalty condition of the shop comprises but is not limited to the number of penalties and the penalty amount of the shop in the last N months; the operation conditions of the shop include, but are not limited to, the number of advertisement investments in the last N months of the shop, the amount of each advertisement, the average amount of each advertisement and the like.
For example, if the store is store a and the time t is month 5 of the year, the historical transaction amount of the store at the time t and the variable of the store are obtained, and all the historical transaction amounts of the store a from business days to 5 months before the current year and the variable of all the dimensions of the store a are obtained.
Step 104: and inputting the historical transaction amount and the variable into a preset prediction model to obtain the predicted transaction amount of each moment in a time interval from the t +1 th moment to the t + i th moment, wherein i is a positive integer.
In particular, the predetermined prediction model may be any predictable machine learning model, such as an LSTM model, an LR model, or a GBDT model.
In the embodiment of the specification, the i machine learning models are obtained by training and are used for predicting the predicted transaction amount at each time within a time interval from the t +1 th time to the t + i th time in the future.
Optionally, in this embodiment of the present specification, the preset prediction model includes a long-short term memory network model, i.e. an LSTM model, and specifically, in the case that the preset prediction model includes a long-short term memory network model,
inputting the historical transaction amount and the variable into a preset prediction model to obtain the predicted transaction amount at each moment in a time interval from the t +1 th moment to the t + i th moment, wherein the step of obtaining the predicted transaction amount at each moment comprises the following steps:
and inputting the historical transaction amount and the variable into the long-short term memory network model to obtain the predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment.
And the historical trading volume is the historical trading volume of each month from business day to the tth moment of the current year of the shop. For example, store a is officially open in month 3 of 2018, and the time t is month 5 of 2019, then the historical trading volume of store a is the historical trading volume of store a in each month from month 5 of 2019 to month 3 of 2018 of the last year.
When the t-th time is 2019, month 5, each time in a time interval from the t +1 th time to the t + i th time represents each time of adding i in the 2019, month 5;
for example, if i is 2, each time in the time interval from the t +1 th time to the t + i th time is denoted as 6 months in 2019 and 7 months in 2019, and in an actual application, the value of i may be set according to the actual application, which is not limited herein.
For example, when the t-th time is 2019, month 5 and i is 6, the historical transaction amount and the variable are input into the long-short term memory network model, and the predicted transaction amount at each time in a time interval from the t +1 th time to the t + i th time is obtained; it can be understood that the historical trading volume of each month from the 5 th month in 2019 to the 3 rd month in the last year of the A store and the variables of the A store are input into the LSTM model, and the predicted trading volume of each month in the future 6 th months from the 6 th month in 2019 to the 11 th month in 2019 of the A store is obtained, namely, the predicted trading volume of the 6 th month in 2019, the predicted trading volume of the 7 th month in 2019, the predicted trading volume of the 8 th month in 2019, the predicted trading volume of the 9 th month in 2019, the predicted trading volume of the 10 th month in 2019 and the predicted trading volume of the 11 th month in 2019.
In practical applications, the predicted transaction amount of the shop at the t +1 th time may be predicted, or the predicted transaction amount of the shop at each time in a time interval from the t +1 th time to the t + i th time may be predicted. In practical application, the LSTM can predict only one value at a time, namely, only GMV (Gross Merchandis Volume) of one month in the future of the shop, for example, only the predicted transaction amount of the shop at the t +1 th moment; the GMV of the store in the future of i months can also be predicted, namely the predicted transaction amount of the store in the time interval from the t +1 th time to the t + i th time at each time can be predicted; however, when the trading volume of the future month of the store is predicted based on the LSTM, the longer the future month of the store is, the larger the error is, and the lower the accuracy is, and in order to ensure a more accurate predicted trading volume of the store in the future month, generally, it is appropriate to predict the predicted trading volume of the future month of the store, that is, i is preferably 6.
Step 106: and inputting the predicted transaction amount at each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount at each moment.
Specifically, the preset time sequence prediction algorithm includes, but is not limited to, a kalman filter algorithm, that is, KF is an algorithm for performing optimal estimation on a system state by outputting observation data through system input by using a linear system state equation. The optimal estimation can also be seen as a filtering process, since the observed data includes the effects of noise and interference in the system. The optimal estimation refers to the estimation that the data solved by the KF algorithm is infinitely close to the true value, and the posterior probability estimation is infinitely close to the true value by using the mathematical expression. The Kalman filtering algorithm has the core idea of prediction and measurement feedback and consists of two parts, wherein the first part is a linear system state prediction equation, and the second part is a linear system observation equation.
In the embodiment of the present specification, in the case that the preset time sequence prediction algorithm includes a kalman filtering algorithm,
inputting the predicted transaction amount of each moment into a preset time sequence prediction algorithm to obtain the corrected predicted transaction amount of each moment comprises the following steps:
and inputting the predicted transaction amount at each moment into a preset Kalman filtering algorithm to obtain the corrected predicted transaction amount at each moment.
With the adoption of the embodiment, after the predicted transaction amount of each time in the time interval from the t +1 th time to the t + i th time is obtained based on the LSTM model, the predicted transaction amount of each time is used as an observation value and is input into the Kalman filtering algorithm, so that the statistics-based time sequence algorithm, namely the Kalman filtering algorithm, is combined with the machine learning-based time sequence algorithm, namely the LSTM, and the combination is corrected mutually, so that the transaction amount of the shop at the future time is more accurately obtained through prediction.
In practical application, the recursive update of the predicted transaction amount obtained by the KF through the machine learning model comprises two processes of state update and observation update:
wherein the state update is obtained by the following equation:
Figure BDA0002361860040000131
Pn|n-1=APn-1|n-1*AT+Q
the observation update is obtained by the following equation:
Figure BDA0002361860040000132
Kn=Pn|n-1H(HPn|n-1HT+R)-1
Figure BDA0002361860040000133
Pn|n=(I-KnH)Pn|n-1
firstly, the estimation value of the observation value is calculated in advance from the state value, then the Kalman gain of the estimation value is calculated, finally the real state value is deduced backwards according to the real observation value, and the purpose of the formula is to correct YnSo that the predicted transaction amount is closer to the real transaction amount Xn
In the embodiments of the present specification, in the above formula
Figure BDA0002361860040000141
Indicating the predicted transaction amount at the nth time at the nth-1 moment;
Figure BDA0002361860040000142
indicates that at the n-1 th time point, based on
Figure BDA0002361860040000143
Another transaction amount deduced, A being represented by Xn-1|n-1Presume Xn|n-1The coefficient of time, H, is represented by Xn|n-1Presume Yn|n-1Coefficient of time, XnIndicating the final corrected transaction amount, YnRepresents a predicted transaction amount predicted by a machine learning model, and X is the current time at the time nnNot observable, but YnCan be predicted, and then can pass YnReverse update of XnThe value of (c).
Wherein, Pn|n-1Is represented by Xn-1|n-1Presume Xn|n-1The covariance of this method, Q denotes the variance of the random term σ (n), R denotes the variance of the random term v (n), KnIs represented by YnBack push back XnThe coefficient of (a).
KF is to calculate the estimation value of the observation value in advance from the state value, then calculate the Kalman gain of the estimation value, and finally reverse the real state value according to the real observation value.
When the KF algorithm is used alone to budget the transaction amount, the KF algorithm has an excellent result in predicting the transaction amount at the time t +1 under the condition of acquiring the transaction amount at the time t, namely the transaction amount at the time t is known, and the KF algorithm is best under the condition of predicting the transaction amount at the time t + 1. However, as can be seen from the observation equation, the KF needs to update the state value with the observation value in the case of predicting t +1 to 6 (i.e. from time t +1 to time t + 6), and in the actual case, there is only the true value at the last time, so that the KF can rapidly decline the performance of the KF in the case of predicting the transaction amount with longer period, and as a result, see fig. 2 and 3, fig. 2 is a schematic diagram of the KF long period prediction method, and fig. 3 is a schematic diagram of the KF long period prediction result, in the practical application, the KF can well capture the transition situation of the sequence, but lack of the observation value in the case of performing long-term prediction, and the performance declines rapidly, it can be seen from fig. 3 that the shop count ratio within an error of 30% increases with the prediction period, the performance declines, at time t +1, the shop count ratio within an error of 30% can also reach about 75%, and at time t +6, the shop count ratio within an error of 30% has declined to about 55, therefore, in the embodiment of the present specification, the advantages of machine learning and KF are compensated, and more accurate transaction amount of the store at the time t +1 to 6 can be predicted, the specific principle is shown in fig. 4, fig. 4 is a correction schematic diagram of the kalman filter wavelength cycle prediction method, by adding a new observation value new, and by combining the kalman filter algorithm and the LSTM, the predicted transaction amounts of each other are mutually corrected, so that the predicted transaction amount is corrected, more accurate predicted transaction amount at the future time is obtained, that is, the predicted transaction amount is corrected, and the update state of the observation equation of the KF is modified as follows:
Figure BDA0002361860040000151
in the embodiment of the specification, the prediction method obtains an initial predicted transaction amount through a machine learning prediction model by using historical transaction data of a t-th moment of a store and variables of the store, and then obtains a more accurate corrected predicted transaction amount of the store after correcting the predicted transaction amount based on the mutual combination of KF and LSTM models.
In another embodiment of the present specification, after acquiring the historical transaction amount of the store at the time t and the variables of the store, the method further includes:
and calculating by a preset linear recursion algorithm based on the historical transaction amount to obtain the calculated and predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment.
Wherein the preset linear recursion algorithm comprises a same-ratio algorithm or a ring-ratio algorithm.
When the method is specifically implemented, a same-ratio algorithm or a ring-ratio algorithm is specifically adopted to calculate the historical transaction amount, and the historical transaction amount is also required to be set according to actual needs.
If the acquired historical transaction amount of the shop at the t time comprises the historical transaction amount of the shop at the t time and the historical transaction amount of the shop at the t time,
the calculating based on the historical transaction amount by a preset linear recursion algorithm to obtain the calculated predicted transaction amount at each time within the time interval from the t +1 th time to the t + i th time specifically comprises:
determining a transaction comparably increased value at a t-th moment based on a historical transaction amount at the t-th moment of the store and a historical transaction amount at the t-th moment of the history;
and obtaining the calculated and predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction comparability increment value at the t th moment.
For example, the t-th time is 2019, year 5, then the historical t-th time is the t-th time of the last year, that is, 2018, year 5.
Namely, under the condition that the historical transaction amount of the shop at the t-th time in the last year can be obtained, the accuracy of calculation by adopting the same-proportion algorithm is higher than that of calculation by adopting the ring-proportion algorithm.
Specifically, when the t-th time is 2019, year 5 and month 5, and the historical t-th time is 2018, the specific steps of calculating by using the same-proportion algorithm are as follows:
firstly, comparing the trading volume of the shop in 2019 and 5 months with the trading volume in 2018 and 5 months, determining how much the trading volume of the shop in 2019 and 5 months is increased than the trading volume in 2018 and 5 months, namely, a trading parity increase value, then similarly considering that the trading volume of the shop in 2019 and 6 months is increased to the trading volume of the shop in each month in 2019 and i months is increased by the same trading parity increase value, and calculating the calculated predicted trading volume of the shop in each month in 2019 and 6 months to 2019 and i months by adopting the parity method.
And if the shop is a shop with short business hours and the transaction amount of the shop at the t-th time in the last year cannot be obtained, calculating by adopting a ring ratio algorithm to obtain the calculated predicted transaction amount of each time in the time interval from the t + 1-th time to the t + i-th time.
Specifically, the obtaining of the historical transaction amount of the shop at the time t includes:
and acquiring the historical transaction amount of the shop at the t-1 moment.
Under the condition that the historical transaction amount of the shop at the t-1 moment is obtained, the preset linear recursion algorithm comprises a ring ratio algorithm;
the calculating based on the historical transaction amount by a preset linear recursion algorithm to obtain the calculated predicted transaction amount at each time within the time interval from the t +1 th time to the t + i th time specifically comprises:
determining a transaction ring ratio increment value of each moment in a time interval from the t +1 th moment to the t + i th moment based on the historical transaction amount of the shop at the t-1 th moment;
and obtaining the calculated predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction ring ratio increment value.
In specific implementation, firstly, the historical transaction amount of the shop at the t-1 th moment is obtained, then the increase percentage of the historical transaction amount of the shop at the t-1 th moment compared with the historical transaction amount at the t-1 th moment is compared, namely the transaction cycle ratio increase value, then the transaction amount of the shop at each moment in the time interval from the t +1 th moment to the t + i th moment is considered to be increased by the same percentage, and the calculation predicted transaction amount at each moment in the time interval from the t +1 th moment to the t + i th moment is calculated by adopting the cycle ratio method.
In another embodiment of the present specification, after the correcting each predicted transaction amount based on the preset time sequence prediction algorithm to obtain a corrected predicted transaction amount, the method further includes:
and obtaining a target predicted trading amount by an exponential smoothing method based on each predicted trading amount, the corrected predicted trading amount of each predicted trading amount at the corresponding moment and the calculated predicted trading amount.
Namely, the target predicted trading value is obtained by carrying out weighted average on each predicted trading value, the corrected predicted trading value of each predicted trading value at the corresponding moment and the calculated predicted trading value by an exponential smoothing method.
Referring to fig. 5, fig. 5 is a schematic flowchart of a scheme of a prediction method provided in an embodiment of the present disclosure.
The method comprises the following steps: firstly, inputting x [ n ] into an LSTM model to obtain an observed value, namely the predicted transaction amount of the embodiment;
step two: substituting the observed value into a Kalman filtering equation, updating and correcting the state value based on the observed value, and calculating a better corrected predicted transaction amount, namely y [ n | n ], by means of calculating a new observed value from the state value and the like;
step three: and performing error fusion based on exponential smoothing on the predicted transaction amount obtained by prediction through the LSTM model, the corrected predicted transaction amount obtained by KF correction and the calculated predicted transaction amount obtained by calculation through a homonymy algorithm to obtain the optimal predicted transaction amount at the future moment.
Specifically, the first step and the second step are based on an algorithm, a machine learning model and a KF algorithm are combined to conduct fusion correction on predicted transaction amount obtained through prediction, and the third step is based on an exponential smoothing error fusion mode, and the predicted transaction amount obtained through prediction of an LSTM model, the corrected predicted transaction amount obtained through correction of the KF and the calculated predicted transaction amount obtained through calculation of a proportional algorithm are further optimized.
In practical application, in order to solve the problem that the combination model of the LSTM and the KF is inaccurate in predicting the non-seasonal transaction amount, error fusion is carried out on the predicted transaction amount at the future time by means of weighted averaging of the corrected predicted transaction amount of the combination model of the LSTM and the predicted transaction amount of the LSTM model, and the results of the corrected predicted transaction amount and the predicted transaction amount of the LSTM model are further optimized. In specific implementation, a same-ratio/ring-ratio method can be added, and weighted average is carried out on the results of the same-ratio/ring-ratio method and the results of the same-ratio/ring-ratio method, so that the transaction amount of the shop at the future moment is further optimized.
Specifically, the method is realized by the following equation:
Figure BDA0002361860040000181
wherein i represents different methods, i.e. different prediction modes such as LSTM, KF, same ratio, ring ratio, etc., M represents the total number of methods, n represents time, and λ represents the weight of different methods; f. ofiDenotes the result of the prediction of the ith method at time n, ynRepresents the output result of the fusion of a plurality of methods at n time, lambdai,nReference coefficients representing the ith method at time n.
Figure BDA0002361860040000182
Figure BDA0002361860040000183
Figure BDA0002361860040000191
Wherein the above equation is to update λ at time n +1, where εi,nError representing the ith method at time n, ai,nIs expressed according to epsiloni,nAn intermediate value of the calculation, ZnRepresenting the median value, λ, calculated at time n according to the error weightingi,n+1The reference coefficient representing the ith method at the time n +1 is prepared for the next time.
In the embodiment of the specification, the prediction method includes the steps of firstly obtaining a predicted transaction amount of each time in a time interval from a t +1 th time to a t + i th time which is obtained through prediction based on a machine learning model, correcting the predicted transaction amount of each time through a KF model, and calculating the calculated predicted transaction amount of each time through a same-ratio algorithm/ring-ratio algorithm, then carrying out error fusion on the predicted transaction amount based on an exponential smoothing method, further optimizing the result, and obtaining a more accurate target predicted transaction amount of a shop in the future time.
In another embodiment of the present specification, after obtaining the target predicted transaction amount by an exponential smoothing method based on each of the predicted transaction amounts and the corrected predicted transaction amount and the calculated predicted transaction amount at the corresponding time, the method further includes:
and adjusting the item amount of the shop based on the target predicted transaction amount.
Wherein the items include, but are not limited to, loan items.
In practical application, after the target predicted transaction amount of the shop within a more accurate future time is obtained, the future sales trend of the shop can be determined according to the transaction amount of the shop at the future time so as to judge whether loan improvement can be performed on the shop, so that the preparation of the shop for a busy season is improved, and the shop experience is improved.
During specific implementation, the amount of the quota aiming at the shop can be specifically judged based on the target predicted transaction amount, and the system friendliness of the shop is further improved.
In the embodiment of the present specification, the prediction method provided by the present specification is evaluated, and the specific evaluation result is as follows:
the prediction method adopts three indexes of accuracy, TMAE and SMAPE for evaluation, and specifically comprises the following steps:
the accuracy index is calculated by the following formula:
Figure BDA0002361860040000201
namely, the category ratio of the error accuracy within x% is considered, and the single prediction performance is measured.
Referring to fig. 6, fig. 6 is a schematic diagram illustrating accuracy of a prediction result of the prediction method provided in the embodiment of the present specification, for example, 1000 stores are predicted, errors of transaction amounts at a future time of each store are different, and accounts of the stores with errors within 10% and 30% are counted in fig. 6.
As can be seen from fig. 6, the accuracy of the prediction result obtained by the prediction method provided in the embodiment of the present specification in the future of the store within 3 months is optimal for the transaction amount at the future time of the store with an error of 10% or less and 30% or less. The Hybrid Model is a Model obtained based on the prediction method provided in the embodiments of the present specification, i.e., a mixed Model of LSTM-KF and LSTM or a mixed Model of LSTM-KF, LSTM and same ratio/ring ratio.
Referring to fig. 7, fig. 7 is a schematic diagram illustrating the stability of the prediction result of the prediction method, in fig. 7, by combining the t +1 to 3 th times and combining the t +1 to 6 th times, the total prediction error of the transaction amount of the future 3 months and 6 months can be estimated, and it can be seen that the error of the transaction amount prediction of the future 3 months is obviously less than 6 months, and meanwhile, the prediction result is stable.
The TMAE index is calculated as follows:
Figure BDA0002361860040000202
i.e. the total error of the total category, and the overall prediction performance of the prediction method is measured.
Referring to fig. 8, fig. 8 is a schematic diagram of the TMAE index in the prediction result of the prediction method, and fig. 8 shows that the total error of the total category of the store is the smallest when the transaction amount of the store in the future 3 months is predicted by using the prediction method of the present specification.
The SMAPE index is calculated as follows:
Figure BDA0002361860040000211
referring to fig. 9, fig. 9 is a schematic diagram of the SMAPE index in the prediction result of the prediction method, and fig. 9 shows that when the prediction method in the embodiment of the present specification is used to predict the transaction amount of the store in the future 3 months, the weighted average error of all categories of the store is the smallest, and the single prediction performance is the best.
Corresponding to the above method embodiment, the present specification further provides a prediction apparatus embodiment, and fig. 10 shows a schematic structural diagram of a prediction apparatus provided in an embodiment of the present specification. As shown in fig. 10, the apparatus includes:
a data acquisition module 1002 configured to acquire a historical transaction amount of a store at a time t and a variable of the store;
the data prediction module 1004 is configured to input the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount at each moment in a time interval from a t +1 th moment to a t + i th moment, wherein i is a positive integer;
and the data correction module 1006 is configured to input the predicted transaction amount at each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount at each moment.
Optionally, the apparatus further includes:
and the data calculation module is configured to calculate through a preset linear recursion algorithm based on the historical transaction amount to obtain a calculated and predicted transaction amount at each moment in a time interval from the t +1 th moment to the t + i th moment.
Optionally, after the apparatus, the apparatus further includes:
and the target data determination module is configured to obtain a target predicted transaction amount through an exponential smoothing method based on each predicted transaction amount, the corrected predicted transaction amount of each predicted transaction amount at the corresponding moment and the calculated predicted transaction amount.
Optionally, the data obtaining module 1002 is further configured to:
and acquiring historical transaction amount of the shop at the t-th time and historical transaction amount of the shop at the t-th time.
Optionally, the preset linear recursion algorithm includes a same-proportion algorithm;
the data prediction module 1004 is further configured to:
determining a transaction comparably increased value at a t-th moment based on a historical transaction amount at the t-th moment of the store and a historical transaction amount at the t-th moment of the history;
and obtaining the calculated and predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction comparability increment value at the t th moment.
Optionally, the data obtaining module 1002 is further configured to:
and acquiring the historical transaction amount of the shop at the t-1 moment.
Optionally, the preset linear recursion algorithm includes a loop ratio algorithm;
the data prediction module 1004 is further configured to:
determining a transaction ring ratio increment value of each moment in a time interval from the t +1 th moment to the t + i th moment based on the historical transaction amount of the shop at the t-1 th moment;
and obtaining the calculated predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction ring ratio increment value.
Optionally, the preset prediction model comprises a long-term and short-term memory network model;
the data prediction module 1004 is further configured to:
and inputting the historical transaction amount and the variable into the long-short term memory network model to obtain the predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment.
Optionally, the preset time sequence prediction algorithm includes a kalman filtering algorithm;
the data modification module 1006 is further configured to:
and inputting the predicted transaction amount at each moment into a preset Kalman filtering algorithm to obtain the corrected predicted transaction amount at each moment.
Optionally, the apparatus further includes:
and the quota adjusting module is configured to adjust the project quota of the shop based on the target predicted transaction amount.
The above is a schematic scheme of a prediction apparatus of the present embodiment. It should be noted that the technical solution of the prediction apparatus and the technical solution of the prediction method described above belong to the same concept, and details of the technical solution of the prediction apparatus, which are not described in detail, can be referred to the description of the technical solution of the prediction method described above.
FIG. 11 illustrates a block diagram of a computing device 1100 provided in accordance with one embodiment of the present description. The components of the computing device 1100 include, but are not limited to, memory 1110 and a processor 1120. The processor 1120 is coupled to the memory 1110 via a bus 1130 and the database 1150 is used to store data.
The computing device 1100 also includes an access device 1140, the access device 1140 enabling the computing device 1100 to communicate via one or more networks 1160. Examples of such networks include a public switched telephone network (PSNN), a Local Area Network (LAN), a Wide Area Network (WAN), a Personal Area Network (PAN), or a combination of communication networks such as the internet. The access device 1140 may include one or more of any type of network interface, e.g., a network interface card (NNC), wired or wireless, such as a NEEE802.11 Wireless Local Area Network (WLAN) wireless interface, a worldwide interoperability for microwave access (Wn-MAX) interface, an ethernet interface, a Universal Serial Bus (USB) interface, a cellular network interface, a bluetooth interface, a Near Field Communication (NFC) interface, and so forth.
In one embodiment of the present description, the above-described components of computing device 1100, as well as other components not shown in FIG. 11, may also be connected to each other, such as by a bus. It should be understood that the block diagram of the computing device architecture shown in FIG. 11 is for purposes of example only and is not limiting as to the scope of the present description. Those skilled in the art may add or replace other components as desired.
Computing device 1100 can be any type of stationary or mobile computing device, including a mobile computer or mobile computing device (e.g., tablet, personal digital assistant, laptop, notebook, netbook, etc.), mobile phone (e.g., smartphone), wearable computing device (e.g., smartwatch, smartglasses, etc.), or other type of mobile device, or a stationary computing device such as a desktop computer or PC. Computing device 1100 can also be a mobile or stationary server.
Wherein, the processor 1120 is configured to execute the following computer-executable instructions:
acquiring historical transaction amount of a shop at the t-th moment and variables of the shop;
inputting the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount of each moment in a time interval from the t +1 th moment to the t + i th moment, wherein i is a positive integer;
and inputting the predicted transaction amount at each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount at each moment.
The above is an illustrative scheme of a computing device of the present embodiment. It should be noted that the technical solution of the computing device and the technical solution of the prediction method belong to the same concept, and details that are not described in detail in the technical solution of the computing device can be referred to the description of the technical solution of the prediction method.
An embodiment of the present specification also provides a computer readable storage medium storing computer instructions which, when executed by a processor, implement the steps of the prediction method.
The above is an illustrative scheme of a computer-readable storage medium of the present embodiment. It should be noted that the technical solution of the storage medium belongs to the same concept as the technical solution of the prediction method, and details that are not described in detail in the technical solution of the storage medium can be referred to the description of the technical solution of the prediction method.
The foregoing description has been directed to specific embodiments of this disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
The computer instructions comprise computer program code which may be in the form of source code, object code, an executable file or some intermediate form, or the like. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
It should be noted that, for the sake of simplicity, the foregoing method embodiments are described as a series of acts, but those skilled in the art should understand that the present embodiment is not limited by the described acts, because some steps may be performed in other sequences or simultaneously according to the present embodiment. Further, those skilled in the art should also appreciate that the embodiments described in this specification are preferred embodiments and that acts and modules referred to are not necessarily required for an embodiment of the specification.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
The preferred embodiments of the present specification disclosed above are intended only to aid in the description of the specification. Alternative embodiments are not exhaustive and do not limit the invention to the precise embodiments described. Obviously, many modifications and variations are possible in light of the above teaching. The embodiments were chosen and described in order to best explain the principles of the embodiments and the practical application, to thereby enable others skilled in the art to best understand and utilize the embodiments. The specification is limited only by the claims and their full scope and equivalents.

Claims (15)

1. A prediction method, comprising:
acquiring historical transaction amount of a shop at the t-th moment and variables of the shop;
inputting the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount of each moment in a time interval from the t +1 th moment to the t + i th moment, wherein i is a positive integer;
and inputting the predicted transaction amount at each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount at each moment.
2. The prediction method according to claim 1, further comprising, after acquiring the historical transaction amount of the store at the time t and the variables of the store:
and calculating by a preset linear recursion algorithm based on the historical transaction amount to obtain the calculated and predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment.
3. The forecasting method according to claim 2, wherein the step of inputting the forecasted transaction amount at each time into a preset time-series forecasting algorithm to obtain a corrected forecasted transaction amount at each time further comprises:
and obtaining a target predicted trading amount by an exponential smoothing method based on each predicted trading amount, the corrected predicted trading amount of each predicted trading amount at the corresponding moment and the calculated predicted trading amount.
4. The forecasting method of claim 3, the obtaining historical transaction amounts for the time t of the store comprising:
and acquiring historical transaction amount of the shop at the t-th time and historical transaction amount of the shop at the t-th time.
5. The prediction method of claim 4, the preset linear recursion algorithm comprising a geometric algorithm;
the calculating based on the historical transaction amount through a preset linear recursion algorithm, and the obtaining of the calculated predicted transaction amount at each moment in the time interval from the t +1 th moment to the t + i th moment comprises:
determining a transaction comparably increased value at a t-th moment based on a historical transaction amount at the t-th moment of the store and a historical transaction amount at the t-th moment of the history;
and obtaining the calculated and predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction comparability increment value at the t th moment.
6. The prediction method of claim 2, the obtaining the historical transaction amount at time t of the store comprising:
and acquiring the historical transaction amount of the shop at the t-1 moment.
7. The prediction method of claim 6, the preset linear recursion algorithm comprising a loop ratio algorithm;
the calculating based on the historical transaction amount through a preset linear recursion algorithm, and the obtaining of the calculated predicted transaction amount at each moment in the time interval from the t +1 th moment to the t + i th moment comprises:
determining a transaction ring ratio increment value of each moment in a time interval from the t +1 th moment to the t + i th moment based on the historical transaction amount of the shop at the t-1 th moment;
and obtaining the calculated predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment based on the transaction ring ratio increment value.
8. The prediction method according to claim 6, wherein the preset prediction model comprises a long-term and short-term memory network model;
inputting the historical transaction amount and the variable into a preset prediction model to obtain the predicted transaction amount at each moment in a time interval from the t +1 th moment to the t + i th moment, wherein the step of obtaining the predicted transaction amount at each moment comprises the following steps:
and inputting the historical transaction amount and the variable into the long-short term memory network model to obtain the predicted transaction amount of each moment in the time interval from the t +1 th moment to the t + i th moment.
9. The prediction method according to claim 1, the preset time series prediction algorithm comprising a kalman filter algorithm;
inputting the predicted transaction amount of each moment into a preset time sequence prediction algorithm to obtain the corrected predicted transaction amount of each moment comprises the following steps:
and inputting the predicted transaction amount at each moment into a preset Kalman filtering algorithm to obtain the corrected predicted transaction amount at each moment.
10. The prediction method according to claim 3, further comprising, after obtaining the target predicted transaction amount by exponential smoothing based on each of the predicted transaction amounts and the corrected predicted transaction amount and the calculated predicted transaction amount at the corresponding time, the predicted transaction amount calculated based on the corrected predicted transaction amount and the calculated predicted transaction amount, the target predicted transaction amount obtained by exponential smoothing:
and adjusting the item amount of the shop based on the target predicted transaction amount.
11. A prediction apparatus, comprising:
the data acquisition module is configured to acquire historical transaction amount of a shop at the t-th moment and the variable of the shop;
the data prediction module is configured to input the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount at each moment in a time interval from a t +1 th moment to a t + i th moment, wherein i is a positive integer;
and the data correction module is configured to input the predicted transaction amount at each moment into a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount at each moment.
12. The prediction apparatus of claim 11, the apparatus further comprising:
and the data calculation module is configured to calculate through a preset linear recursion algorithm based on the historical transaction amount to obtain a calculated and predicted transaction amount at each moment in a time interval from the t +1 th moment to the t + i th moment.
13. The prediction device of claim 12, the device thereafter further comprising:
and the target data determination module is configured to obtain a target predicted transaction amount through an exponential smoothing method based on each predicted transaction amount, the corrected predicted transaction amount of each predicted transaction amount at the corresponding moment and the calculated predicted transaction amount.
14. A computing device, comprising:
a memory and a processor;
the memory is to store computer-executable instructions, and the processor is to execute the computer-executable instructions to:
acquiring historical transaction amount of a shop at the t-th moment and variables of the shop;
inputting the historical transaction amount and the variable into a preset prediction model to obtain a predicted transaction amount of each moment in a time interval from the t +1 th moment to the t + i th moment, wherein i is a positive integer;
and correcting each predicted transaction amount based on a preset time sequence prediction algorithm to obtain a corrected predicted transaction amount.
15. A computer readable storage medium storing computer instructions which, when executed by a processor, carry out the steps of the prediction method of any one of claims 1 to 10.
CN202010024231.1A 2020-01-10 2020-01-10 Prediction method and device Pending CN111242284A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010024231.1A CN111242284A (en) 2020-01-10 2020-01-10 Prediction method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010024231.1A CN111242284A (en) 2020-01-10 2020-01-10 Prediction method and device

Publications (1)

Publication Number Publication Date
CN111242284A true CN111242284A (en) 2020-06-05

Family

ID=70865145

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010024231.1A Pending CN111242284A (en) 2020-01-10 2020-01-10 Prediction method and device

Country Status (1)

Country Link
CN (1) CN111242284A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112015778A (en) * 2020-08-19 2020-12-01 上海满盛信息技术有限公司 Water fingerprint prediction algorithm
CN113139686A (en) * 2021-04-25 2021-07-20 中国工商银行股份有限公司 Transaction amount dynamic threshold monitoring method and device
CN113806981A (en) * 2021-09-16 2021-12-17 浙江衡玖医疗器械有限责任公司 Water temperature prediction method and device for hemispherical ultrasonic imaging system and electronic equipment

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112015778A (en) * 2020-08-19 2020-12-01 上海满盛信息技术有限公司 Water fingerprint prediction algorithm
CN113139686A (en) * 2021-04-25 2021-07-20 中国工商银行股份有限公司 Transaction amount dynamic threshold monitoring method and device
CN113806981A (en) * 2021-09-16 2021-12-17 浙江衡玖医疗器械有限责任公司 Water temperature prediction method and device for hemispherical ultrasonic imaging system and electronic equipment

Similar Documents

Publication Publication Date Title
CN111242284A (en) Prediction method and device
CN111563706A (en) Multivariable logistics freight volume prediction method based on LSTM network
CN108710905B (en) Spare part quantity prediction method and system based on multi-model combination
Crépey et al. Gaussian process regression for derivative portfolio modeling and application to CVA computations
Gao et al. Forecasting with model selection or model averaging: a case study for monthly container port throughput
CN111160968A (en) SKU-level commodity sales prediction method and device
Hwang et al. A new measure for assessing the efficiency of hydrological data-driven forecasting models
CN111105265A (en) Prediction method and device based on customer information, computer equipment and storage medium
CN114549046A (en) Sales prediction method, system, device and storage medium based on fusion model
CN110175689A (en) A kind of method of probabilistic forecasting, the method and device of model training
CN114519610A (en) Information prediction method and device
CN114491263A (en) Recommendation model training method and device, and recommendation method and device
CN114581119A (en) Flow prediction method and device
CN114066405A (en) Data processing method and device
Li et al. Feature-based intermittent demand forecast combinations: accuracy and inventory implications
Tehrani et al. A heuristic approach to explore: The value of perfect information
WO2021103571A1 (en) Method and apapratus for generating asset investment suggestion information and readable storage medium
Miok Estimation of prediction intervals in neural network-based regression models
Agarwal et al. Prediction of bitcoin, litecoin and ethereum trends using state-of-art algorithms
CN115563568A (en) Abnormal data detection method and device, electronic device and storage medium
CN110633971A (en) Method and device for estimating loss
Zheng et al. Estimating dynamic stochastic decision models: explore the generalized maximum entropy alternative
Boumezoued et al. Mortality data correction in the absence of monthly fertility records
CN111160662A (en) Risk prediction method, electronic equipment and storage medium
Qi et al. Incremental data-driven topology learning for time-varying graph signals

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

Application publication date: 20200605

RJ01 Rejection of invention patent application after publication