CN115700691A - Order quantity prediction method and system - Google Patents

Order quantity prediction method and system Download PDF

Info

Publication number
CN115700691A
CN115700691A CN202110837134.9A CN202110837134A CN115700691A CN 115700691 A CN115700691 A CN 115700691A CN 202110837134 A CN202110837134 A CN 202110837134A CN 115700691 A CN115700691 A CN 115700691A
Authority
CN
China
Prior art keywords
order quantity
data
quantity data
historical
order
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
CN202110837134.9A
Other languages
Chinese (zh)
Inventor
林晓列
松森正树
殷颖
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hitachi Ltd
Original Assignee
Hitachi 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 Hitachi Ltd filed Critical Hitachi Ltd
Priority to CN202110837134.9A priority Critical patent/CN115700691A/en
Publication of CN115700691A publication Critical patent/CN115700691A/en
Pending legal-status Critical Current

Links

Images

Abstract

The invention provides a method and a system for predicting order quantity, wherein the method comprises the following steps: acquiring historical order quantity data of a target merchant, wherein the historical order quantity data comprises daily historical sales of each commodity; analyzing and processing the historical order quantity data by utilizing the historical epidemic situation information of the area where the target merchant is located, the potential law of the historical order quantity data, abnormal data in the historical order quantity data and the commodity type to obtain the historical order quantity data of each commodity; respectively training to obtain order prediction models corresponding to the commodities by utilizing historical order quantity data of each commodity; and predicting the order quantity of the corresponding commodity by using the order prediction model obtained by training. The embodiment of the invention considers the influence of accidental factors, improves the accuracy of order quantity prediction, can respectively predict different commodity types, is favorable for planning resources such as manpower, equipment, capacity and the like of a warehouse/merchant in advance, and realizes the maximization of efficiency.

Description

Order quantity prediction method and system
Technical Field
The invention relates to the technical field of data acquisition and processing, in particular to a method and a system for predicting order quantity.
Background
In modern warehouse planning and operation, the future outbound order quantity of the warehouse needs to be accurately predicted so as to plan resources such as manpower, equipment and capacity of the warehouse in advance, thereby realizing efficiency maximization.
An order quantity prediction method commonly adopted in the prior art is to predict future order quantity by using a plurality of order quantity historical data. Another order quantity prediction method in the prior art specifically includes: when the order quantity of the target warehouse in the historical statistical period and the transaction amount meet preset relevant conditions, acquiring the transaction amount of the target warehouse in a future statistical period by using the transaction amount of the target warehouse in a plurality of historical statistical periods, and determining the order quantity corresponding to the transaction amount as the first channel forecast quantity of the target warehouse in the future statistical period; acquiring the order quantity of the target warehouse in the future statistical period by using the order quantity of the target warehouse in the plurality of historical statistical periods, and determining the order quantity as the second channel forecast quantity of the target warehouse in the future statistical period; and fusing the first channel prediction quantity and the second channel prediction quantity to obtain an order quantity prediction result of the target warehouse in the future statistical period.
In the method in the prior art, the change possibly caused by the influence of accidental factors in the historical data information of the order quantity/transaction amount is not considered, so that the accuracy of prediction is difficult to ensure.
Disclosure of Invention
The technical problem to be solved by the embodiment of the invention is to provide an order quantity prediction method and system, which can improve the accuracy of order quantity prediction, facilitate the advance planning of resources such as manpower, equipment and capacity of warehouses/merchants and realize the maximization of efficiency.
In order to solve the above technical problem, a method for predicting an order amount provided in an embodiment of the present invention includes:
acquiring historical order quantity data of a target merchant, wherein the historical order quantity data comprises daily historical sales of each commodity;
analyzing and processing the historical order quantity data by utilizing the historical epidemic situation information of the area where the target merchant is located, the potential law of the historical order quantity data, abnormal data in the historical order quantity data and the commodity type to obtain the historical order quantity data of each commodity;
respectively training to obtain order prediction models corresponding to the commodities by utilizing historical order quantity data of each commodity;
and predicting the order quantity of the corresponding commodity by using the order prediction model obtained by training.
Optionally, the analyzing and processing the historical order quantity data includes:
and acquiring historical epidemic situation information of the area where the target merchant is located, determining the historical epidemic situation period, and correcting the first order quantity data of the epidemic situation period.
Optionally, the modifying the first order quantity data of the epidemic situation period includes:
judging whether the first order quantity data is abnormal or not;
under the condition that the first order quantity data are abnormal, searching second order quantity data meeting the following conditions: the order quantity data is at the same time position of a preset time period as the first order quantity data and is order quantity data of non-epidemic time;
and replacing the first order quantity data with the second order quantity data, and updating the historical order quantity data.
Optionally, the second order amount data further meets the following condition: a second time period to which the second order quantity data belongs is adjacent to a first time period to which the first order quantity data belongs;
the replacing the first order quantity data with the second order quantity data includes:
replacing the first order amount data with second order amount data of a subsequent time period adjacent to the first time period in a case where there is second order amount data of two preceding and succeeding time periods adjacent to the first time period;
in the absence of the second order amount data, the first order amount data is replaced with an average value of order amount data over a time period.
Optionally, analyzing and processing the historical order quantity data, further includes:
and under the condition that the historical order quantity data comprises order quantity data of at least two time periods, determining an order quantity fluctuation point between the at least two time periods and a calendar attribute corresponding to the order quantity fluctuation point, and marking the fluctuation date according to the calendar attribute corresponding to the order quantity fluctuation point.
Optionally, analyzing and processing the historical order quantity data, further includes:
determining residual historical order quantity data, wherein the residual historical order quantity data is the residual data except the order quantity data of the epidemic situation period and the order quantity data of the order quantity fluctuation point in the historical order quantity data;
carrying out abnormal data analysis on the residual historical order quantity data to determine abnormal points;
receiving a judgment result of the user on the abnormal point:
under the condition that the judgment result shows that the abnormal point is not artificially wrong, reserving the abnormal point;
and under the condition that the judgment result shows that the abnormal point is a human error, replacing the order quantity data corresponding to the abnormal point by using the order quantity data at the same time position as the abnormal point in the adjacent time period, and updating the historical order quantity data.
Optionally, analyzing and processing the historical order quantity data, further comprising:
and grouping the updated historical order quantity data according to the commodity types to obtain the historical order quantity data of each commodity.
Optionally, the respectively training to obtain the order prediction model corresponding to each commodity by using the historical order quantity data of each commodity includes:
and performing model training by using the historical order quantity data of each commodity and a Prophet time series algorithm to obtain an order prediction model corresponding to each commodity.
Optionally, the predicting the order quantity of the corresponding commodity by using the trained order prediction model includes:
acquiring current epidemic situation information of the area where the target merchant is located;
under the condition that the current epidemic situation information shows that no epidemic situation exists, predicting the order quantity of the corresponding commodity by using an order prediction model obtained by training;
and under the condition that the current epidemic situation information indicates that the epidemic situation exists, predicting the order quantity of the commodity according to the epidemic situation risk level.
Optionally, after the amount of the order of the goods is predicted, the method further includes:
taking a time axis and the order quantity as coordinates, and carrying out visual display on the predicted order quantity of the commodity;
and/or the presence of a gas in the gas,
the predicted results of the order quantity for a future period of time are aggregated.
The embodiment of the invention also provides a prediction system of order quantity, which comprises:
the data acquisition module is used for acquiring historical order quantity data of a target merchant, and the historical order quantity data comprises daily historical sales of each commodity;
the data processing module is used for analyzing and processing the historical order quantity data by utilizing the historical epidemic situation information of the area where the target merchant is located, the potential law of the historical order quantity data, abnormal data in the historical order quantity data and the commodity type to obtain the historical order quantity data of each commodity;
the model training module is used for respectively training to obtain order prediction models corresponding to the commodities by utilizing the historical order quantity data of each commodity;
and the prediction module is used for predicting the order quantity of the corresponding commodity by using the order prediction model obtained by training.
Optionally, the data processing module is further configured to acquire historical epidemic situation information of an area where the target merchant is located, determine the historical epidemic situation period, and perform modification processing on the first order quantity data of the epidemic situation period.
Optionally, the data processing module is further configured to determine whether the first order quantity data is abnormal; under the condition that the first order quantity data is abnormal, searching second order quantity data meeting the following conditions: the order quantity data is at the same time position of a preset time period as the first order quantity data and is order quantity data of non-epidemic time; and replacing the first order quantity data with the second order quantity data, and updating the historical order quantity data.
Optionally, the second order amount data further meets the following condition: a second time period to which the second order quantity data belongs is adjacent to a first time period to which the first order quantity data belongs;
the data processing module is further configured to replace the first order quantity data with second order quantity data of a next time period adjacent to the first time period when second order quantity data of two previous and next time periods adjacent to the first time period exists; in the absence of the second order amount data, the first order amount data is replaced with an average value of order amount data over a time period.
Optionally, the data processing module is further configured to, when the historical order quantity data includes order quantity data of at least two time periods, determine an order quantity fluctuation point between the at least two time periods and a calendar attribute corresponding to the order quantity fluctuation point, and mark the fluctuation date according to the calendar attribute corresponding to the order quantity fluctuation point.
Optionally, the data processing module is further configured to determine remaining historical order quantity data, where the remaining historical order quantity data is remaining data of the historical order quantity data, except for the order quantity data of the epidemic situation period and the order quantity data of the order quantity fluctuation point; carrying out abnormal data analysis on the residual historical order quantity data to determine abnormal points; receiving a judgment result of the user on the abnormal point: under the condition that the judgment result shows that the abnormal point is not artificially wrong, reserving the abnormal point; and under the condition that the judgment result shows that the abnormal point is a human error, replacing the order quantity data corresponding to the abnormal point by using the order quantity data at the same time position as the abnormal point in the adjacent time period, and updating the historical order quantity data.
The data processing module is further used for grouping the updated historical order quantity data according to the commodity types to obtain the historical order quantity data of each commodity.
Optionally, the model training module is further configured to perform model training by using a Prophet time series algorithm according to the historical order quantity data of each commodity, so as to obtain an order prediction model corresponding to each commodity.
Optionally, the prediction module is further configured to obtain current epidemic situation information of an area where the target merchant is located; under the condition that the current epidemic situation information shows that no epidemic situation exists, predicting the order quantity of the corresponding commodity by using an order prediction model obtained by training; and under the condition that the current epidemic situation information shows that the epidemic situation exists, predicting the order quantity of the commodities according to the epidemic situation risk level.
Optionally, the system further includes:
the output reporting module is used for taking the time axis and the order quantity as coordinates after the order quantity of the commodity is obtained through prediction, and performing visual display on the predicted order quantity of the commodity; and/or aggregating the predicted outcome of the order volume over a future period of time.
According to another aspect of the present invention, at least one embodiment provides an order quantity prediction system, including: a processor, a memory and a program stored on the memory and executable on the processor, which when executed by the processor implements the steps of the method as described above.
According to another aspect of the invention, at least one embodiment provides a computer readable storage medium having a program stored thereon, which when executed by a processor, performs the steps of the method as described above.
Compared with the prior art, the order quantity prediction method and the order quantity prediction system provided by the embodiment of the invention can be used for simultaneously carrying out safe isolation on the data of the client and the data of the server on the premise of not increasing the development and maintenance cost.
As can be seen from the above, the order quantity prediction system provided in the embodiment of the present invention fully considers the influence of incidental factors before training the order quantity prediction model, analyzes and processes the historical data of the order quantity, and trains the relevant model by using the analyzed and processed historical data, thereby improving the accuracy of order quantity prediction.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments of the present invention will be briefly introduced below, and it is obvious that the drawings in the description below are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a flow chart illustrating a method for predicting an order amount according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart of the epidemic situation data analysis according to the embodiment of the present invention;
FIG. 3 is a schematic flow chart of outlier analysis according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of a system for predicting an order quantity according to an embodiment of the present invention;
FIG. 5 is a diagram illustrating the prediction steps of the prediction module according to an embodiment of the present invention;
FIG. 6 is a schematic diagram of another structure of the order quantity forecasting system according to the embodiment of the present invention;
fig. 7 is another schematic structural diagram of an order quantity prediction system according to an embodiment of the present invention.
Detailed Description
To make the technical problems, technical solutions and advantages of the present invention more apparent, the following detailed description is given with reference to the accompanying drawings and specific embodiments. In the following description, specific details such as specific configurations and components are provided only to help the full understanding of the embodiments of the present invention. Thus, it will be apparent to those skilled in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the invention. In addition, descriptions of well-known functions and constructions are omitted for clarity and conciseness.
It should be appreciated that reference throughout this specification to "one embodiment" or "an embodiment" means that a particular feature, structure or characteristic described in connection with the embodiment is included in at least one embodiment of the present invention. Thus, the appearances of the phrases "in one embodiment" or "in an embodiment" in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, the particular features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
In various embodiments of the present invention, it should be understood that the sequence numbers of the following processes do not mean the execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
As discussed in the background, the order size may be affected by certain factors. For example, in the case of an epidemic, the purchasing behavior of the customer is affected by the restrictions and sealing measures; during holidays, orders for some merchants may suddenly increase or decrease in quantity. According to the order quantity prediction method provided by the embodiment of the invention, before the relevant model is trained, the historical data of the order quantity is analyzed and processed, the influence of various accidental factors is fully considered, and then the model training is carried out based on the analyzed and processed data, so that the accuracy of order quantity prediction is improved, resources such as manpower, equipment and capacity of a warehouse/a merchant can be planned in advance, and the efficiency is maximized. The method of the embodiment of the present invention will be described in detail below.
Referring to fig. 1, a method for predicting an order amount according to an embodiment of the present invention includes:
and 11, acquiring historical order quantity data of the target merchant, wherein the historical order quantity data comprises the daily historical sales quantity of each commodity.
Here, the target merchant is a merchant that needs to make order amount prediction according to the embodiment of the present invention. The merchant may be a main body of a certain mall, a restaurant, a supermarket, and the like, and the order of the merchant may be a commodity order sold by the merchant, such as an order of various commodities sold in the mall and the supermarket, an order of various food sold in the restaurant, and the like. These orders may include orders generated through an Application (APP), orders ordered by telephone, orders purchased on-site by a customer, and so on. Historical order quantity data, which may typically be obtained from the target merchant's transaction records, includes historical daily sales information for each item.
And step 12, analyzing and processing the historical order quantity data by utilizing the historical epidemic situation information of the area where the target merchant is located, the potential law of the historical order quantity data, abnormal data in the historical order quantity data and the commodity type to obtain the historical order quantity data of each commodity.
And analyzing and processing the historical order quantity data by utilizing the historical epidemic situation information of the region where the target merchant is located, the potential rule of the historical order quantity data, abnormal data in the historical order quantity data and the commodity type, and correcting the historical order quantity data to obtain the historical order quantity data of each commodity.
And step 13, respectively training to obtain order prediction models corresponding to the commodities by utilizing the historical order quantity data of each commodity.
Here, the order prediction model corresponding to each commodity is trained using the historical order amount data of the commodity, so that each commodity can correspond to one order prediction model. In the embodiment of the invention, a Prophet time series algorithm can be used for model training to obtain the order prediction model corresponding to each commodity.
And step 14, predicting the order quantity of the corresponding commodity by using the order prediction model obtained by training.
Here, when predicting the order quantity of a certain commodity, the embodiment of the present invention first obtains the current epidemic situation information of the area where the target merchant is located. And under the condition that the current epidemic situation information indicates that no epidemic situation exists locally, predicting the order quantity of the corresponding commodity by directly using the order prediction model obtained by training. And under the condition that the current epidemic situation information shows that the epidemic situation exists, the order quantity of the commodities is predicted according to the epidemic situation risk level.
Under the condition that there is the epidemic situation, the target trade company probably receives the influence of closing the business place or restricting the flow of people who gets into the business place, therefore, according to epidemic situation risk level, predicts the order volume of commodity, specifically can be: and determining the remaining closing/flow limiting days of the target merchant corresponding to the current epidemic situation risk level, and determining that the predicted value of the order quantity in the remaining closing/flow limiting days is 0 or a certain smaller numerical value, wherein the smaller numerical value can be set by referring to the order quantity of the commodity in the historical order data under the same epidemic situation risk level.
In addition, in order to facilitate the intuitive understanding of the prediction result of the order quantity in a future period of time, in the embodiment of the present invention, after the order quantity of the commodity is predicted, the predicted order quantity of the commodity may be displayed visually by using the time axis and the order quantity as coordinates, for example, by displaying the change of the order quantity with time in the form of a dynamic graph or a bar graph. Further, the embodiments of the present invention may also aggregate the predicted result of the order amount in a future period of time and display the result, for example, aggregate the order amount/total order amount of each commodity in future each week, month or year, etc.
Through the method, the historical order quantity data are analyzed and processed before the model is trained, and the influence of relevant accidental factors is considered, so that the prediction accuracy of the trained model is improved. The following describes the analysis processing of the historical order amount data in detail in the embodiment of the present invention.
In step 12, in the embodiment of the present invention, historical epidemic situation information of the area where the target merchant is located may be obtained, the historical epidemic situation period may be determined, and the first order quantity data of the epidemic situation period may be modified.
As shown in fig. 2, the modifying the first order quantity data of the epidemic situation period specifically includes:
step 1211, determining whether the first order quantity data is abnormal.
Here, the determining whether the first order quantity data is abnormal may be comparing the first order quantity data with an average value of order quantities for a preset time period (e.g., one year, one month, or one week), and when a degree of difference from the average value exceeds a predetermined threshold, it is determined to be abnormal, otherwise, it is determined to be normal. For example, the first order quantity data is lower than 50% of the average value, and it is considered abnormal.
Step 1212, in a case that the first order quantity data is abnormal, searching for second order quantity data meeting the following conditions: the order quantity data is at the same time position of a preset time period as the first order quantity data and is order quantity data of non-epidemic time.
Step 1213, replacing the first order quantity data with the second order quantity data, and updating the historical order quantity data.
And when the first order quantity data is normal, no correction processing is needed. When the first order quantity data is abnormal, the first order quantity data can be replaced by order quantity data which is at the same time position of a preset time period as the first order quantity data and is at non-epidemic time. For example, assume that the preset time period is one year, assume that 1/6/2019-15/2019 are epidemic situations, and the order quantity in the epidemic situations is abnormal; and the 1 st 6 th 2018 th 6 th 15 th 2018 th year is a non-epidemic situation period and is at the same time position in one year as the epidemic situation period (namely, 1 st 6 th 15 th 6 th), so that the order quantity data of the 1 st 6 th 2018 th 6 th 15 th 2018 th 6 th can be adopted to replace the order quantity data of the 1 st 2019 th 6 th 15 th 2019 th 6 th 15 th year, thereby correcting the historical order quantity data.
In addition, in consideration of timeliness of data, the embodiment of the present invention preferentially replaces the first order quantity data with normal data at the same time position in adjacent time periods. At this time, the second order amount data further satisfies the following condition: and the second time period to which the second order quantity data belongs is adjacent to the first time period to which the first order quantity data belongs. That is, only data in a time period before or after the first time period is used in the data correction. Further, in a case where there is second order amount data of two preceding and succeeding time periods adjacent to the first time period, replacing the first order amount data with second order amount data of one succeeding time period adjacent to the first time period; and in the absence of the second order amount data, replacing the first order amount data with an average value of order amount data over a period of time. Still illustrated by the above example:
if the 1 st 6 th 2018 th to 15 th 6 th 2018 th 6 th are in non-epidemic situations and the 1 st 6 th 2020 nd 1 st 2020 nd to 15 th 2020 nd 6 th are in non-epidemic situations, the embodiment of the present invention preferentially replaces the first order quantity data with the second order quantity data of the next time period, that is, replaces the first order quantity data with the second order quantity data of the 15 th 6 th 2020 th to 6 th 2020 nd 1 st 2020 nd.
Replacing the first order quantity data with second order quantity data from 1 st 2018 th 6 th to 15 th 2018 th 6 th 15 th 2018 if there is only a non-epidemic period from 1 st 2018 th 6 th to 15 th 2018 th 6 th.
If there is only a non-epidemic period of 6/1/2020 to 6/15/2020, the first order quantity data is replaced with second order quantity data of 6/1/2020 to 6/15/2020.
If 1/6/2020 to 15/6/2020 are epidemic periods, and 6/1/2020 to 15/6/2020 are also epidemic periods, the average data of the order amount for a certain period of time (here, one year) may be used for the replacement, for example, the average data of the order amount for the entire year in 2020 may be used for the replacement.
The order quantity data usually has a regular change characteristic, and there may be order quantity fluctuation points corresponding to each other between at least two time periods, and the order quantity values of these order quantity fluctuation points usually have a large change. The specific variation amplitude can be set at the outlier detection algorithm. The above-described mutually corresponding order quantity fluctuation points generally occur on the same holiday in different time periods. The time positions of the same holiday in different time periods may be the same or different, for example, the time position of the New year's day is fixed on the day of the gregorian year, while the time position of the lunar holiday, such as the mid-autumn festival, the spring festival, etc., is not fixed on the day of the gregorian year.
After the correction processing is performed in step 12, the following analysis processing may be performed: and under the condition that the historical order quantity data comprises order quantity data of at least two time periods, determining an order quantity fluctuation point between the at least two time periods and a calendar attribute corresponding to the order quantity fluctuation point, and marking the fluctuation date according to the calendar attribute corresponding to the order quantity fluctuation point. Here, the calendar attribute refers to a holiday attribute corresponding to the fluctuation date, such as a new year, mid-autumn, spring festival, and the like. Here, the order quantity fluctuation point determination method may be implemented by detecting an outlier detection algorithm, determining a calendar attribute of each outlier after detecting the outlier in each time period, and then using the outlier having the same calendar attribute between the at least two time periods as the order quantity fluctuation point.
In addition, if the history order amount data includes only order amount data for 1 time period, the analysis process of the fluctuation point described above may be skipped.
After the above processing, the embodiment of the present invention may further process the abnormal data in step 12, specifically, as shown in fig. 3, the method includes:
step 1221, determining remaining historical order quantity data, wherein the remaining historical order quantity data is the remaining data of the historical order quantity data except the order quantity data of the epidemic situation period and the order quantity data of the order quantity fluctuation point.
And 1222, performing abnormal data analysis on the remaining historical order quantity data to determine an outlier.
Here, outliers in the remaining historical order quantity data may be detected by an outlier detection algorithm.
And 1223, receiving a judgment result of the user on the abnormal point.
Since the outliers may be the wrong order volume resulting from manual entry data errors, and may also be the real order volume that exists objectively. The embodiment of the invention introduces a manual judgment mode to judge the order quantity data of the abnormal point and input a manual judgment result to indicate whether the abnormal point is caused by manual error.
Step 1224, if the determination result indicates that the outlier is not artificially incorrect, retaining the outlier.
And 1225, when the judgment result shows that the abnormal point is a human error, replacing the order quantity data corresponding to the abnormal point by using the order quantity data at the same time position as the abnormal point in the adjacent time period, and updating the historical order quantity data.
The fluctuation point and the abnormal point described above refer to the order amount of a certain statistical period (for example, a certain day) in the order amount data.
Through the above processing, the embodiment of the present invention updates the history order amount data. Finally, the embodiment of the present invention may further group the updated historical order quantity data according to the types of the commodities to obtain historical order quantity data of each commodity, so as to perform the training of the relevant model by using the historical order quantity data of each commodity in step 13.
Fig. 4 provides an example of an application of the method according to the embodiment of the present invention, taking the order number of the meal at various prices of a certain dining hall as an example. In this example, unexpected data due to an epidemic situation in historical order quantity data is processed, then a model is trained based on the processed data, and an order quantity in a future period is predicted based on the trained model and a current epidemic situation risk level.
In the example, by acquiring the historical records of the meal ordering information of the dining room, and based on the historical records of the meal ordering information, the weekly meal ordering number in the future month to year is predicted for meals with different prices (namely different types of meals), so that the dining room and related structures can grasp the meal ordering scale of the dining room in advance, reasonable food material purchasing is made, normal supply of the meals is ensured, and waste of food materials is reduced.
In this example, the customer can make a meal reservation within the range of the next week by means of APP, telephone, on-site, etc., and reservation information is stored in the meal reservation information database. In fig. 4:
the data acquisition module can acquire the historical record of the order information from the order information database. The history here includes the following data items: the order staff number, the order date, the package type, the package price and the canteen number.
The data processing module can analyze and process the meal ordering historical record according to epidemic situation data, abnormal data, potential rule data, price data (namely meal types) and the like to obtain processed meal ordering amount historical data.
1) And (3) analyzing the epidemic situation influence:
and analyzing the influence degree of the outbreak period of the epidemic situation on the meal ordering amount so as to make reference for predicting the meal ordering amount under the condition that the epidemic situation exists in the future.
And (4) using the abnormal data caused by the epidemic situation in the next year (if the epidemic situation exists at the same time point in the next year or if no data exists, filling the abnormal data with the data at the same time point in the previous year) so as to predict the future situation without the epidemic situation by using the normal data.
2) Latent rule analysis
The method comprises the steps of analyzing potential rules of data, extracting rule nodes (for example, data fluctuation caused by the influence of spring festival, mid-autumn festival, labor festival and other major holidays), and defining rule effects so as to improve prediction accuracy by using predefined effects on prediction of future meal ordering amount.
3) Anomaly data analysis
For outlier data, reason analysis needs to be performed in combination with actual business, including human error analysis (such as human input error, program logic error, etc.), and objective business analysis (actual business phenomenon).
4) Price impact analysis
And grouping the data according to the order price, and analyzing the influence of different prices on the order quantity so as to predict different prices in the future.
And the model training module is used for respectively training the meal ordering amount prediction model according to each price (different prices correspond to different meal types) based on the processed meal ordering amount historical data. Here, model training may be performed using a Prophet time series algorithm based on the data after the analysis processing.
And the prediction module predicts the meal ordering amount from one month to one year in the future according to different prices by using the trained meal ordering amount model. For example, local epidemic situation risk levels are crawled from related servers, and prediction is carried out according to the epidemic situation levels:
1) If no epidemic situation exists, the trained model is directly used for prediction
2) If the epidemic situation exists, the trained model is used, and the influence degree of the epidemic situation in the data analysis module is combined to predict.
In addition, the prediction result is displayed in a visualized manner, for example, by using a time axis and an order quantity axis as coordinates, and displaying the future prediction result by using a dynamic graph.
The output report module can output a summary description, including the contents for reference of the canteen and the related units, specifically including the total meal order amount and the total meal order amount of each price predicted in the future. For example, the summary forecast results include the total amount of orders and the total number of orders reported for each price in the next year, month, and week for the relevant units.
Fig. 5 shows the prediction steps of the prediction module in the above example, including:
step 501, the generated prediction module is obtained, including all models grouped according to price.
Step 502, configuring relevant parameters of the model for predicting the meal ordering amount, including prediction according to price classification, wherein the prediction time length is one year in the future, the prediction time granularity is one week, and the prediction content is the meal ordering amount.
Step 503, obtaining the current epidemic situation risk level from the relevant server, such as high, medium, and low.
And step 504, executing different treatments according to the epidemic situation risk level. When the risk level is low, normal prediction is executed by utilizing the model; when the risk level is middle, predicting that the meal ordering amount in future 2 weeks is 0; when the risk level is high, the predicted meal size in future 3 weeks is 0.
And 505, performing visualization processing according to the predicted ordering amount result, wherein the grouping parameters are ordering price, Y-axis is ordering amount, and X-axis is time (which can be expressed by year, month and day).
Based on the above abnormal data detection method, an embodiment of the present invention further provides a prediction system for an order quantity, as shown in fig. 6, where the prediction system includes:
the data acquisition module 61 is used for acquiring historical order quantity data of a target merchant, wherein the historical order quantity data comprises the daily historical sales quantity of each commodity;
the data processing module 62 is configured to analyze and process the historical order quantity data by using the historical epidemic situation information of the area where the target merchant is located, the potential law of the historical order quantity data, the abnormal data in the historical order quantity data, and the commodity type, so as to obtain historical order quantity data of each commodity;
the model training module 63 is configured to respectively train to obtain order prediction models corresponding to the commodities by using historical order quantity data of each commodity;
and the prediction module 64 is used for predicting the order quantity of the corresponding commodity by using the order prediction model obtained by training.
Optionally, the data processing module is further configured to acquire historical epidemic situation information of an area where the target merchant is located, determine the historical epidemic situation period, and perform modification processing on the first order quantity data of the epidemic situation period.
Optionally, the data processing module is further configured to determine whether the first order quantity data is abnormal; under the condition that the first order quantity data is abnormal, searching second order quantity data meeting the following conditions: the order quantity data is at the same time position of a preset time period as the first order quantity data and is order quantity data of non-epidemic time; and replacing the first order quantity data with the second order quantity data, and updating the historical order quantity data.
Optionally, the second order amount data further meets the following condition: a second time period to which the second order quantity data belongs is adjacent to a first time period to which the first order quantity data belongs;
the data processing module is further configured to replace the first order quantity data with second order quantity data of a next time period adjacent to the first time period when second order quantity data of two previous and next time periods adjacent to the first time period exists; in the absence of the second order amount data, the first order amount data is replaced with an average value of order amount data over a time period.
Optionally, the data processing module is further configured to determine an order quantity fluctuation point between at least two time periods and a calendar attribute corresponding to the order quantity fluctuation point when the historical order quantity data includes order quantity data of at least two time periods, and mark the fluctuation date according to the calendar attribute corresponding to the order quantity fluctuation point.
Optionally, the data processing module is further configured to determine remaining historical order quantity data, where the remaining historical order quantity data is remaining data of the historical order quantity data, except for the order quantity data of the epidemic situation period and the order quantity data of the order quantity fluctuation point; carrying out abnormal data analysis on the residual historical order quantity data to determine abnormal points; receiving a judgment result of the user on the abnormal point: under the condition that the judgment result shows that the abnormal point is not artificially wrong, reserving the abnormal point; and under the condition that the judgment result shows that the abnormal point is a human error, replacing the order quantity data corresponding to the abnormal point by using the order quantity data at the same time position as the abnormal point in the adjacent time period, and updating the historical order quantity data.
The data processing module is further used for grouping the updated historical order quantity data according to the commodity types to obtain the historical order quantity data of each commodity.
Optionally, the model training module is further configured to perform model training by using a Prophet time series algorithm according to the historical order quantity data of each commodity, so as to obtain an order prediction model corresponding to each commodity.
Optionally, the prediction module is further configured to obtain current epidemic situation information of an area where the target merchant is located; under the condition that the current epidemic situation information shows that no epidemic situation exists, predicting the order quantity of the corresponding commodity by using an order prediction model obtained by training; and under the condition that the current epidemic situation information shows that the epidemic situation exists, predicting the order quantity of the commodities according to the epidemic situation risk level.
Optionally, the method further includes:
the output reporting module is used for taking the time axis and the order quantity as coordinates after the order quantity of the commodity is obtained through prediction, and performing visual display on the predicted order quantity of the commodity; and/or aggregating the predicted outcome of the order volume over a future period of time.
Through the units, the accuracy of order quantity prediction is improved, prediction can be performed respectively according to different commodity types, resources such as manpower, equipment and capacity of a warehouse/merchant can be planned in advance, and efficiency maximization is achieved.
Referring to fig. 7, another structural diagram of the order quantity forecasting system 700 according to the embodiment of the present invention includes: a processor 701, a transceiver 702, a memory 703 and a bus interface, wherein:
in the embodiment of the present invention, the prediction system 700 for order quantity further includes: a program stored on the memory 703 and executable on the processor 701, which when executed by the processor 701, performs the steps of:
acquiring historical order quantity data of a target merchant, wherein the historical order quantity data comprises daily historical sales of each commodity;
analyzing and processing the historical order quantity data by utilizing the historical epidemic situation information of the region where the target merchant is located, the potential rule of the historical order quantity data, abnormal data in the historical order quantity data and the commodity type to obtain the historical order quantity data of each commodity;
respectively training to obtain order prediction models corresponding to the commodities by utilizing historical order quantity data of each commodity;
and predicting the order quantity of the corresponding commodity by using the order prediction model obtained by training.
It can be understood that, in the embodiment of the present invention, when being executed by the processor 701, the computer program can implement the processes of the method for predicting an order quantity shown in fig. 1, and can achieve the same technical effect, and in order to avoid repetition, the description thereof is omitted here.
In fig. 7, the bus architecture may include any number of interconnected buses and bridges, with one or more processors, represented by processor 701, and various circuits, represented by memory 703, being linked together. The bus architecture may also link together various other circuits such as peripherals, voltage regulators, power management circuits, and the like, which are well known in the art, and therefore, will not be described any further herein. The bus interface provides an interface. The transceiver 702 may be a number of elements including a transmitter and a receiver that provide a means for communicating with various other apparatus over a transmission medium.
The processor 701 is responsible for managing the bus architecture and general processing, and the memory 703 may store data used by the processor 701 in performing operations.
It should be noted that the terminal in this embodiment is a device corresponding to the method shown in fig. 3, and the implementation manners in the above embodiments are all applicable to the embodiment of the terminal, and the same technical effects can be achieved. In the device, the transceiver 702 and the memory 703, and the transceiver 702 and the processor 701 may be communicatively connected through a bus interface, the function of the processor 701 may also be implemented by the transceiver 702, and the function of the transceiver 702 may also be implemented by the processor 701. It should be noted that the apparatus provided in the embodiment of the present invention can implement all the method steps implemented by the method embodiment, and can achieve the same technical effects, and detailed descriptions of the same parts and beneficial effects as the method embodiment in this embodiment are omitted here.
In some embodiments of the invention, there is also provided a computer readable storage medium having a program stored thereon, which when executed by a processor, performs the steps of:
acquiring historical order quantity data of a target merchant, wherein the historical order quantity data comprises daily historical sales of each commodity;
analyzing and processing the historical order quantity data by utilizing the historical epidemic situation information of the area where the target merchant is located, the potential law of the historical order quantity data, abnormal data in the historical order quantity data and the commodity type to obtain the historical order quantity data of each commodity;
respectively training to obtain order prediction models corresponding to the commodities by utilizing historical order quantity data of each commodity;
and predicting the order quantity of the corresponding commodity by using the order prediction model obtained by training.
When executed by the processor, the program can implement all the implementation manners in the order quantity prediction method, and can achieve the same technical effect, and for avoiding repetition, the description is omitted here.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the technical solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one type of logical functional division, and other divisions may be realized in practice, for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment of the present invention.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
While the invention has been described with reference to specific embodiments, the invention is not limited thereto, and various equivalent modifications and substitutions can be easily made by those skilled in the art within the technical scope of the invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (11)

1. A method for predicting an order amount, comprising:
acquiring historical order quantity data of a target merchant, wherein the historical order quantity data comprises daily historical sales of each commodity;
analyzing and processing the historical order quantity data by utilizing the historical epidemic situation information of the area where the target merchant is located, the potential law of the historical order quantity data, abnormal data in the historical order quantity data and the commodity type to obtain the historical order quantity data of each commodity;
respectively training to obtain order prediction models corresponding to the commodities by utilizing historical order quantity data of each commodity;
and predicting the order quantity of the corresponding commodity by using the order prediction model obtained by training.
2. The method of claim 1, wherein analyzing the historical order quantity data comprises:
acquiring historical epidemic situation information of the area where the target merchant is located, determining the historical epidemic situation period, and correcting the first order quantity data of the epidemic situation period.
3. The method of claim 1, wherein modifying the first order quantity data for the epidemic situation time comprises:
judging whether the first order quantity data is abnormal or not;
under the condition that the first order quantity data is abnormal, searching second order quantity data meeting the following conditions: the order quantity data is at the same time position of a preset time period as the first order quantity data and is order quantity data of non-epidemic time;
and replacing the first order quantity data with the second order quantity data, and updating the historical order quantity data.
4. The method of claim 3, wherein the second order volume data further satisfies the following condition: a second time period to which the second order quantity data belongs is adjacent to a first time period to which the first order quantity data belongs;
the replacing the first order quantity data with the second order quantity data includes:
replacing the first order amount data with second order amount data of a subsequent time period adjacent to the first time period in a case where there is second order amount data of two preceding and succeeding time periods adjacent to the first time period;
in a case where the second order amount data does not exist, the first order amount data is replaced with an average value of order amount data for one time period.
5. The method of any of claims 2 to 4, wherein analyzing the historical order volume data further comprises:
and under the condition that the historical order quantity data comprises order quantity data of at least two time periods, determining an order quantity fluctuation point between the at least two time periods and a calendar attribute corresponding to the order quantity fluctuation point, and marking the fluctuation date according to the calendar attribute corresponding to the order quantity fluctuation point.
6. The method of claim 5, wherein analyzing the historical order volume data further comprises:
determining residual historical order quantity data, wherein the residual historical order quantity data is the residual data except the order quantity data of the epidemic situation period and the order quantity data of the order quantity fluctuation point in the historical order quantity data;
carrying out abnormal data analysis on the residual historical order quantity data to determine abnormal points;
receiving a judgment result of the user on the abnormal point:
under the condition that the judgment result shows that the abnormal point is not artificially wrong, reserving the abnormal point;
and under the condition that the judgment result shows that the abnormal point is a human error, replacing the order quantity data corresponding to the abnormal point by using the order quantity data at the same time position as the abnormal point in the adjacent time period, and updating the historical order quantity data.
7. The method of claim 6, wherein analyzing the historical order volume data further comprises:
and grouping the updated historical order quantity data according to the commodity types to obtain the historical order quantity data of each commodity.
8. The method of claim 1, wherein the using the historical order quantity data of each commodity to respectively train and obtain the order prediction model corresponding to the commodity comprises:
and performing model training by using the historical order quantity data of each commodity and a Prophet time series algorithm to obtain an order prediction model corresponding to each commodity.
9. The method of claim 1, wherein predicting the order quantity for the corresponding item using the trained order prediction model comprises:
acquiring current epidemic situation information of the region where the target merchant is located;
under the condition that the current epidemic situation information shows that no epidemic situation exists, predicting the order quantity of the corresponding commodity by using an order prediction model obtained by training;
and under the condition that the current epidemic situation information shows that the epidemic situation exists, predicting the order quantity of the commodities according to the epidemic situation risk level.
10. The method of claim 1, wherein after predicting the order quantity for the good, the method further comprises:
taking a time axis and the order quantity as coordinates, and carrying out visual display on the predicted order quantity of the commodity;
and/or the presence of a gas in the gas,
the predicted results of the order quantity for a future period of time are aggregated.
11. A system for forecasting an order quantity, comprising:
the data acquisition module is used for acquiring historical order quantity data of a target merchant, and the historical order quantity data comprises daily historical sales of each commodity;
the data processing module is used for analyzing and processing the historical order quantity data by utilizing the historical epidemic situation information of the area where the target merchant is located, the potential law of the historical order quantity data, abnormal data in the historical order quantity data and the commodity type to obtain the historical order quantity data of each commodity;
the model training module is used for respectively training to obtain order prediction models corresponding to the commodities by utilizing the historical order quantity data of each commodity;
and the prediction module is used for predicting the order quantity of the corresponding commodity by using the order prediction model obtained by training.
CN202110837134.9A 2021-07-23 2021-07-23 Order quantity prediction method and system Pending CN115700691A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110837134.9A CN115700691A (en) 2021-07-23 2021-07-23 Order quantity prediction method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110837134.9A CN115700691A (en) 2021-07-23 2021-07-23 Order quantity prediction method and system

Publications (1)

Publication Number Publication Date
CN115700691A true CN115700691A (en) 2023-02-07

Family

ID=85120524

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110837134.9A Pending CN115700691A (en) 2021-07-23 2021-07-23 Order quantity prediction method and system

Country Status (1)

Country Link
CN (1) CN115700691A (en)

Similar Documents

Publication Publication Date Title
Yang et al. Integrated multi-period dynamic inventory classification and control
Cooper et al. The promise-and peril-of integrated cost systems
US9773250B2 (en) Product role analysis
CN102346880B (en) Enterprise Resources Planning computer system and method
US20060167704A1 (en) Computer system and method for business data processing
CN111401777B (en) Enterprise risk assessment method, enterprise risk assessment device, terminal equipment and storage medium
US20050256760A1 (en) System, method, and software for short term forecasting using predictive indicators
US20120284086A1 (en) Fuel store profit optimization
US20170098257A1 (en) System and Method for Optimizing Retail Fuel Stores
US20200104771A1 (en) Optimized Selection of Demand Forecast Parameters
Rekik et al. Exploring inventory systems sensitive to shrinkage–analysis of a periodic review inventory under a service level constraint
Qi et al. Developing supply chain resilience through integration: An empirical study on an e‐commerce platform
WO2022221461A1 (en) Orchestrated intelligent supply chain optimizer
Tsai The impact of cost structure on supply chain cash flow risk
US20120330724A1 (en) Fuel pricing
JP2004021364A (en) Management intention decision support system
Giri et al. Integrated model for an imperfect production-inventory system with a generalised shipment policy, errors in quality inspection and ordering cost reduction
Morgan et al. Using SPC to measure a national supermarket chain's suppliers' performance
Andry et al. Supply chain disruptions mitigation plan using six sigma method for sustainable technology infrastructure
Moynihan et al. Decision support system for strategic logistics planning
Chehrazi et al. Inventory record inaccuracy explains price rigidity in perishable groceries
US20160092892A1 (en) Computer-Aided System for Improving Return on Assets
Mehra et al. A simulation-based comparison of batch sizes in a continuous processing industry
CN115700691A (en) Order quantity prediction method and system
KR101334891B1 (en) System for providing financiail risk management service in software as a service

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication