Sales prediction model generation method and device, electronic equipment and storage medium

By calculating the average and standard deviation of historical sales data, modifying abnormal data, and optimizing the training process of sales prediction model, the problem of low sales prediction accuracy in the existing technology is solved, and more accurate sales prediction is achieved.

CN119151587APending Publication Date: 2024-12-17BEIJING XIAOMI MOBILE SOFTWARE CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310706028.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-06-14
Publication Date
2024-12-17

AI Technical Summary

Technical Problem

When the existing sales forecast model deals with discrete sales forecast values, the prediction accuracy is poor when the frequency is extremely high, especially when a certain model of product has sales volume in only 10 days within 30 days, resulting in a sales volume of 0 in 20 days. Causes high or inaccurate predictions.

Method used

By obtaining historical sales data, calculating the mean and standard deviation of sales data, determining the abnormal data, and modifying it into a more balanced data set, which is used to train sales prediction models, thereby improving prediction accuracy. Specific steps include: determining the abnormal data threshold based on the mean value and standard deviation, randomly replacing the abnormal data, adjusting the grid parameters to avoid overfitting, splitting the data set for training and verification, and optimizing the model parameters.

Benefits of technology

Improve the accuracy and accuracy of sales forecasts, ensuring the stability and reliability of the model under different sales data distributions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119151587A_ABST
    Figure CN119151587A_ABST
Patent Text Reader

Abstract

The invention relates to a sales prediction model generation method and device, electronic equipment and a storage medium, and belongs to the technical field of data processing. The method comprises the steps that a historical sales data set is acquired, the historical sales data set comprises a plurality of pieces of historical sales data, and the historical sales data comprises historical sales volume data; determining an average value and a standard deviation of the historical sales volume data; determining abnormal data in the historical sales volume data according to the average value and the standard deviation; modifying the abnormal data according to non-abnormal data in the historical sales volume data; and training a to-be-trained sales volume prediction model according to the modified historical sales data set to obtain a trained sales volume prediction model. According to the embodiment of the invention, the abnormal data in the historical sales volume data is modified, so that the accuracy of sales volume prediction is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of data processing technology, and in particular to a method, device, electronic device and storage medium for generating a sales forecasting model. Background Art

[0002] In the sales field, the prediction of product sales can help stores formulate appropriate replenishment plans to avoid excessive allocation of goods, which may cause capital pressure, or insufficient allocation of goods, which may cause sales losses due to shortages. At present, the prediction of product sales is mainly carried out through sales forecasting models. However, in the case where the sales forecast values ​​are discrete and the frequency of sales forecast values ​​is very high, for example, a certain model of goods may have only 10 days of sales in the past 30 days, and there are 20 days with zero sales, the sales forecast model is used to directly predict sales, and the prediction accuracy is poor. Summary of the invention

[0003] The present disclosure provides a method, device, electronic device and storage medium for generating a sales forecast model, so as to at least solve the problem of poor sales forecast accuracy in the related art.

[0004] The technical solution of the present disclosure is as follows:

[0005] According to a first aspect of an embodiment of the present disclosure, there is provided a method for generating a sales prediction model, comprising: obtaining a historical sales data set, wherein the historical sales data set includes a plurality of historical sales data, wherein the historical sales data includes historical sales data; determining a mean value and a standard deviation of the historical sales data; determining abnormal data in the historical sales data based on the mean value and the standard deviation; modifying the abnormal data based on non-abnormal data in the historical sales data; and training a sales prediction model to be trained based on the modified historical sales data set to obtain a trained sales prediction model.

[0006] In one embodiment of the present disclosure, determining the abnormal data in the historical sales data based on the mean value and the standard deviation includes: determining an abnormal sales data threshold based on the mean value and the standard deviation; and determining that the historical sales data greater than the abnormal sales data threshold is abnormal data.

[0007] In one embodiment of the present disclosure, determining the abnormal sales data threshold based on the mean value and the standard deviation includes: determining the product value of the standard deviation and a preset multiple; determining the sum value of the mean value and the product value; and using the sum value as the abnormal sales data threshold.

[0008] In one embodiment of the present disclosure, the modifying the abnormal data according to the non-abnormal data in the historical sales data includes: randomly selecting one of the non-abnormal data to replace the abnormal data.

[0009] In one embodiment of the present disclosure, the sales forecast model to be trained is trained according to the modified historical sales data set to obtain the trained sales forecast model, including: determining multiple groups of grid parameters of the sales forecast model to be trained, the grid parameters being parameters used to evaluate whether a sub-model in the sales forecast model to be trained can be built, and for determining the quantile during data splitting and the quantile used when the sub-model cannot be built; for each group of the grid parameters, obtaining a sales forecast value corresponding to the modified historical sales data set based on the sales forecast model to be trained; determining whether the sales forecast model to be trained is overfitting according to the prediction accuracy of the sales forecast value and a preset overfitting parameter; if the sales forecast model to be trained is overfitting, updating the multiple groups of grid parameters, and returning to the step of obtaining the sales forecast value corresponding to the modified historical sales data set based on the sales forecast model to be trained for each group of grid parameters; if the sales forecast model to be trained is not overfitting, determining the group of grid parameters with the highest prediction accuracy as the parameters of the trained sales forecast model.

[0010] In one embodiment of the present disclosure, for each group of the grid parameters, obtaining the sales forecast value corresponding to the modified historical sales data set based on the sales forecast model to be trained, includes: splitting the modified historical sales data set into a second data set, a third data set and a fourth data set; using the second data set as a training set, the third data set as a validation set, and the fourth data set as a test set; for each group of the grid parameters, obtaining the sales forecast value corresponding to the second data set, the third data set and the fourth data set based on the sales forecast model to be trained.

[0011] In one embodiment of the present disclosure, splitting the modified historical sales data set into a second data set, a third data set, and a fourth data set includes: taking the data in the modified historical sales data set whose sales time is before the set sales time as the first data set; randomly extracting a first proportion of data in the first data set as the second data set; taking the data in the first data set except the second data set as the third data set; and taking the data in the modified historical sales data set whose sales time is after the set sales time as the fourth data set.

[0012] In one embodiment of the present disclosure, the overfitting parameter includes a first overfitting parameter and a second overfitting parameter, and determining whether the sales prediction model to be trained is overfitting based on the prediction accuracy of the sales prediction value and the preset overfitting parameter includes: determining a first absolute value of precision difference, the first absolute value of precision difference is the absolute value of the precision difference between the prediction accuracy of the sales prediction value corresponding to the second data set and the prediction accuracy of the sales prediction value corresponding to the third data set; determining a second absolute value of precision difference, the second absolute value of precision difference is the absolute value of the precision difference between the prediction accuracy of the sales prediction value corresponding to the second data set and the prediction accuracy of the sales prediction value corresponding to the fourth data set; if there is at least one group of the grid parameters whose corresponding absolute value of the first precision difference is less than the first overfitting parameter, and whose corresponding absolute value of the second precision difference is less than the second overfitting parameter, then it is judged that the sales prediction model to be trained is not overfitting; if the absolute value of the first precision difference corresponding to any group of the grid parameters is equal to or greater than the first overfitting parameter, or the corresponding absolute value of the second precision difference is equal to or greater than the second overfitting parameter, then it is judged that the sales prediction model to be trained is overfitting.

[0013] In one embodiment of the present disclosure, determining the set of grid parameters with the highest prediction accuracy as the parameters of the trained sales prediction model includes: determining the set of grid parameters with the highest prediction accuracy corresponding to the fourth data set as the parameters of the trained sales prediction model.

[0014] In one embodiment of the present disclosure, the method of obtaining sales forecast values ​​corresponding to the second data set, the third data set, and the fourth data set based on the sales forecast model to be trained includes: determining whether the conditions for building a classification model are met; if it is determined that the conditions for building a classification model are met, then building a sales classification model, and obtaining sales classification forecast values ​​corresponding to the training set, the validation set, and the test set based on the sales classification model; determining the sales classification forecast value quantile corresponding to the training set according to the sales classification forecast value corresponding to the training set and the probability quantile preset in the grid parameter; and dividing the sales classification forecast values ​​in the training set, the validation set, and the test set by the sales classification forecast value that is less than the sales classification forecast value quantile. as the first training set, the first validation set and the first test set respectively, and take the data in the training set, the validation set and the test set whose sales classification prediction values ​​are equal to or greater than the sales classification prediction value quantiles as the second training set, the second validation set and the second test set; determine whether the conditions for building a regression model are met; if it is determined that the conditions for building a regression model are met, then build a sales regression model with the sales prediction value corresponding to the first training set as the dependent variable, and obtain the sales prediction values ​​corresponding to the first training set, the first validation set and the first test set based on the sales regression model; if the second training set is empty, output the sales prediction values ​​corresponding to the first training set, the first validation set and the first test set.

[0015] In one embodiment of the present disclosure, it also includes: if it is determined that the conditions for building a classification model are not met, the actual sales value quantile corresponding to the training set is determined based on the actual sales value corresponding to the training set and the quantile preset in the grid parameter, and the actual sales value quantile is used as the sales prediction value corresponding to the training set, the validation set and the test set; and the sales prediction values ​​corresponding to the training set, the validation set and the test set are output.

[0016] In one embodiment of the present disclosure, it also includes: if it is determined that the conditions for building a regression model are not met, the actual sales value quantile corresponding to the training set is determined based on the actual sales value corresponding to the training set and the quantile preset in the grid parameter, and the actual sales value quantile is used as the sales prediction value corresponding to the training set, the validation set and the test set; and the sales prediction values ​​corresponding to the training set, the validation set and the test set are output.

[0017] In one embodiment of the present disclosure, it also includes: if the second training set is not empty, the second training set is used as the training set, the second validation set is used as the validation set, the second test set is used as the test set, and the step of determining whether the condition for building a classification model is met is returned.

[0018] In one embodiment of the present disclosure, the conditions for building a classification model include: the actual sales value corresponding to the training set is a non-single value, and the number of historical sales data in the training set is equal to or greater than the first quantity threshold preset in the grid parameter, and the actual sales value corresponding to the training set has an actual sales value whose cumulative frequency ratio is greater than the preset cumulative frequency ratio threshold.

[0019] In one embodiment of the present disclosure, constructing a sales classification model includes: taking the second smallest actual sales value whose cumulative frequency share is greater than the cumulative frequency share threshold among the actual sales values ​​corresponding to the training set as the classification threshold of the actual sales value; recording the actual sales classification value corresponding to the actual sales value in the training set that is greater than the classification threshold of the actual sales value as 1, and recording the actual sales classification value corresponding to the actual sales value in the training set that is equal to or less than the classification threshold of the actual sales value as 0; and constructing the sales classification model according to the actual sales classification values ​​of the training set.

[0020] According to a second aspect of an embodiment of the present disclosure, there is provided a device for generating a sales prediction model, comprising: an acquisition module, configured to acquire a historical sales data set, wherein the historical sales data set includes multiple historical sales data, wherein the historical sales data includes historical sales data; a first determination module, configured to determine an average value and a standard deviation of the historical sales data; a second determination module, configured to determine abnormal data in the historical sales data based on the average value and the standard deviation; a modification module, configured to modify the abnormal data based on non-abnormal data in the historical sales data; and a training module, configured to train a sales prediction model to be trained based on the modified historical sales data set to obtain a trained sales prediction model.

[0021] According to a third aspect of an embodiment of the present disclosure, there is provided an electronic device, comprising: a device for generating a sales forecasting model as described in the second aspect of an embodiment of the present disclosure.

[0022] According to the fourth aspect of an embodiment of the present disclosure, there is provided an electronic device, comprising: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to execute the instructions to implement the method for generating a sales forecast model as described in the first aspect of an embodiment of the present disclosure.

[0023] According to the fifth aspect of an embodiment of the present disclosure, a computer-readable storage medium is provided. When the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device can execute the method for generating a sales forecast model as described in the first aspect of an embodiment of the present disclosure.

[0024] The technical solution provided by the embodiments of the present disclosure brings at least the following beneficial effects:

[0025] The method for generating a sales forecast model in the disclosed embodiment obtains a historical sales data set including multiple historical sales data, determines the average value and standard deviation of the historical sales data in the historical sales data, determines the abnormal data in the historical sales data according to the average value and standard deviation, modifies the abnormal data according to the non-abnormal data in the historical sales data, and trains the sales forecast model to be trained according to the modified historical sales data set to obtain a trained sales forecast model. The disclosed embodiment determines the average value and standard deviation to determine the abnormal data in the historical sales data, and modifies the abnormal data according to the non-abnormal data in the historical sales data, so that the values ​​of the modified historical sales data are more balanced, thereby making the prediction accuracy of the trained sales forecast model more accurate, thereby improving the accuracy of sales forecast.

[0026] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] The drawings herein are incorporated into and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the description are used to explain the principles of the present disclosure, and do not constitute improper limitations on the present disclosure.

[0028] Figure 1 The diagram is a schematic diagram of a scenario showing a method for generating a sales forecasting model according to an exemplary embodiment.

[0029] Figure 2 The present invention is a flowchart of a method for generating a sales forecasting model according to another exemplary embodiment.

[0030] Figure 3 The present invention is a flowchart of a method for generating a sales forecasting model according to another exemplary embodiment.

[0031] Figure 4 The present invention is a flowchart of a method for generating a sales forecasting model according to another exemplary embodiment.

[0032] Figure 5 The present invention is a flowchart of a method for generating a sales forecasting model according to another exemplary embodiment.

[0033] Figure 6 The present invention is a flowchart of a method for generating a sales forecasting model according to another exemplary embodiment.

[0034] Figure 7 The present invention is a flowchart of a method for generating a sales forecasting model according to another exemplary embodiment.

[0035] Figure 8 is a flowchart of a method for generating a sales forecasting model according to another exemplary embodiment.

[0036] Fig. 9 It is a block diagram of a device for generating a sales forecasting model according to an exemplary embodiment.

[0037] Fig.10 It is a block diagram of an electronic device according to an exemplary embodiment.

[0038] Fig.11 is a block diagram of an electronic device according to another exemplary embodiment. DETAILED DESCRIPTION

[0039] In order to enable ordinary persons in the art to better understand the technical solutions of the present disclosure, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the accompanying drawings.

[0040] It should be noted that the terms "first", "second", etc. in the specification and claims of the present disclosure and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present disclosure described herein can be implemented in an order other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.

[0041] In the related art, when the sales forecast value is discrete and the frequency of the sales forecast value is very high, for example, a certain model of goods may have sales only for 10 days in the past 30 days, and there are 20 days with zero sales. If the sales forecast model is used to directly forecast the sales, the forecast accuracy is poor. Therefore, this application proposes a method for generating a sales forecast model.

[0042] Figure 1 FIG. 1 is a schematic diagram of an application scenario of the method for generating a sales forecast model according to an embodiment of the present disclosure. Figure 1As shown in the figure, the goods in the warehouse are transported to the sales stores, and the stores sell the goods to users. This process mainly includes three aspects of work: 1. Sales forecast, generate a replenishment plan based on the sales forecast value; 2. Submit a replenishment application to the warehouse according to the replenishment plan; 3. The warehouse transports the corresponding number of goods to the store. Sales forecast can be applied to the following scenarios: 1) Store replenishment, use the sales forecast of the front-end store to make a store-level replenishment application. 2) Sales plan formulation, conduct sales forecasts at the store level, and summarize the forecast results to the headquarters for sales plan formulation.

[0043] The technical solutions in the embodiments of the present disclosure are further described clearly and completely below in conjunction with the accompanying drawings.

[0044] Figure 2 FIG. 1 is a flow chart showing a method for generating a sales forecasting model according to another exemplary embodiment. Figure 2 As shown, the method for generating the sales forecast model of the embodiment of the present disclosure may include the following steps:

[0045] S201, obtaining a historical sales data set, where the historical sales data set includes multiple pieces of historical sales data, and the historical sales data includes historical sales volume data.

[0046] It should be noted that the sales forecast model generation method of the embodiment of the present disclosure is performed by the sales forecast model generation device provided by the embodiment of the present disclosure, and the device can be set in an electronic device to perform the sales forecast model generation method of the embodiment of the present disclosure. The electronic device can be a smart terminal device such as a mobile phone or a computer.

[0047] In the disclosed embodiment, historical sales data refers to sales data before the current time. For example, multiple historical sales data within a set time period, such as within the past month, can be obtained, and the collection of these historical sales data is used as a historical sales data set. Each piece of historical sales data may specifically include but is not limited to historical sales data, store data, product model (sku) data, date, weather data, store daily customer flow data, store grade data, store city grade data, store city gross domestic product (GDP) data, store city population, store promotion data and competitive product data, etc.

[0048] In the embodiment of the present disclosure, the historical sales data can be filtered to retain only data of some dimensions and spliced ​​into the historical sales data set shown in Table 1:

[0049] Table 1 Filtered historical sales data set

[0050] Stores sku_id date Sales Store level sku first level category sku secondary category S001 G001 20210101 10 Category I P1001 P2001 S001 G002 20210101 20 Category I P1001 P2001 S003 G005 20210102 5 Category II P1001 P2002 S004 G001 20210103 6 Three categories P1001 P2001

[0051] S202, determining the mean and standard deviation of historical sales data.

[0052] In the embodiment of the present disclosure, in order to ensure the accuracy of the prediction, the historical sales data in the historical sales data set needs to be cleaned. Specifically, the average value μ and standard deviation σ of multiple historical sales data in the historical sales data set can be calculated.

[0053] S203, determining abnormal data in the historical sales data according to the mean value and the standard deviation.

[0054] In the embodiment of the present disclosure, for the case where the sales forecast value is discrete and the sales forecast value has a very high frequency of a certain value, for example, a certain model of goods may have sales only for 10 days in the past 30 days, so there are 20 days with zero sales. In the related art, because the predicted variable, that is, the sales forecast value, takes a value of 0 very often, unless the sales forecast value is predicted to be 0, the prediction for the sales forecast value of 0 will be predicted as a positive value, and the overall prediction is too high. Therefore, in the embodiment of the present disclosure, based on the average value and standard deviation calculated in step S102, each historical sales data is determined to be abnormal data. If the historical sales data is determined to be too large based on the average value and standard deviation, the historical sales data is determined to be abnormal data, otherwise it is determined to be non-abnormal data.

[0055] S204, modifying the abnormal data according to the non-abnormal data in the historical sales data.

[0056] In the embodiment of the present disclosure, historical sales data determined as abnormal data is modified based on historical sales data determined as non-abnormal data to achieve data cleaning.

[0057] S205, training the sales forecasting model to be trained according to the modified historical sales data set to obtain a trained sales forecasting model.

[0058] In the disclosed embodiment, the sales forecast model to be trained is trained based on the modified historical sales data set, that is, the parameters of the sales forecast model are adjusted and optimized to obtain the trained sales forecast model.

[0059] It should be noted here that before model training, it is necessary to perform feature engineering on historical sales data to construct the independent variables of the model, that is, the input variables of the model. The historical sales data can be aggregated mainly by using time slices such as the past 7 days, 14 days, and 28 days, and different dimensions such as store data, store level data, and sku data. The specific examples are as follows:

[0060] 1) Use time slices to construct historical sales data, such as sales data for the past 7 days, sales data for the past 14 days, sales data for the past 30 days, etc.;

[0061] 2) Use store-level data and time slices to construct historical sales data, such as sales data for a type of store in the past 7 days;

[0062] 3) Use store data, sku data and time slices to build historical sales data, such as the sales data of the store and the sku in the past 7 days;

[0063] 4) Onehot encoding is performed on categorical data such as store levels.

[0064] In addition, before training the model, it is also necessary to determine the label of the model to construct the dependent variable (also called the target variable) of the model, that is, the output variable of the model, such as determining the predicted sales data for the next N days. The label can be determined specifically according to the business scenario. For example, in the scenario of store replenishment, we need to replenish the goods once in the future to meet the demand for the next N days, so we need to determine the sales data and values ​​of the next N days as the predicted values. For example, based on the historical sales data set in Table 2, it is currently necessary to predict the sales data and values ​​of the goods in store S001 and sku_id G001 in the next 7 days on 2022-01-01. Then we need to sum the sales data of the sku_id of the store from 2022-01-02 to 2022-01-08 to obtain the variable value to be predicted as 10+20+30=60.

[0065] Table 2 Historical sales data set

[0066] Stores sku_id date Sales S001 G001 20220101 5 S001 G001 20220103 10 S001 G001 20220104 20 S001 G001 20220107 30 S001 G001 20220112 5

[0067] In summary, the method for generating a sales forecast model provided by the embodiment of the present disclosure obtains a historical sales data set including multiple historical sales data, determines the mean value and standard deviation of the historical sales data in the historical sales data, determines the abnormal data in the historical sales data based on the mean value and standard deviation, and modifies the abnormal data based on the non-abnormal data in the historical sales data, and trains the sales forecast model to be trained based on the modified historical sales data set to obtain a trained sales forecast model. The embodiment of the present disclosure determines the abnormal data in the historical sales data by determining the mean value and standard deviation, and modifies the abnormal data based on the non-abnormal data in the historical sales data, so that the values ​​of the modified historical sales data are more balanced, thereby making the prediction accuracy of the trained sales forecast model more accurate, thereby improving the accuracy of sales forecast.

[0068] Figure 3 FIG. 1 is a flow chart showing a method for generating a sales forecasting model according to another exemplary embodiment. Figure 3 As shown, based on the above embodiment, the method for generating a sales forecast model in the embodiment of the present disclosure may include the following steps:

[0069] S301, obtaining a historical sales data set, where the historical sales data set includes multiple pieces of historical sales data, and the historical sales data includes historical sales volume data.

[0070] S302, determining the mean and standard deviation of historical sales data.

[0071] In the embodiment of the present disclosure, the specific process of steps S301-S302 can refer to the relevant description of steps S201-S202 in the above embodiment, which will not be repeated here.

[0072] In the above embodiment, step S203 "determining abnormal data in historical sales data according to the mean value and standard deviation" may specifically include the following steps S303-S304.

[0073] S303, determining the abnormal sales data threshold according to the mean value and the standard deviation.

[0074] In the embodiment of the present disclosure, the abnormal sales data threshold is a threshold used to determine whether the historical sales data is abnormal data. The embodiment of the present disclosure can calculate the abnormal sales data threshold according to the average value μ and standard deviation σ of the historical sales data obtained in step S302.

[0075] As a feasible implementation method, the abnormal sales data threshold can be determined in the following way: determine the product value of the standard deviation σ and a preset multiple, determine the sum of the average value μ and the product value, and use the sum as the abnormal sales data threshold. For example, μ+3σ can be used as the abnormal sales data threshold.

[0076] S304: Determine that historical sales data that is greater than an abnormal sales data threshold is abnormal data.

[0077] In the embodiment of the present disclosure, if the historical sales data is greater than the abnormal sales data threshold, it is determined that the historical sales data is too large, and then the historical sales data is determined to be abnormal data. If the historical sales data is equal to or less than the abnormal sales data threshold, it is determined that the historical sales data is non-abnormal data.

[0078] The step S204 of "modifying abnormal data according to non-abnormal data in historical sales data" in the above embodiment may specifically include the following step S305.

[0079] S305: randomly select one of the non-abnormal data to replace the abnormal data.

[0080] In the embodiments of the present disclosure, a variety of methods can be used to modify abnormal data, such as a method of determining the average value of non-abnormal data, a method of determining the median of non-abnormal data, a method of randomly selecting non-abnormal data, etc. Among them, the method of determining the average value of non-abnormal data is as follows: calculate the average value of non-abnormal data in historical sales data, and replace the historical sales data determined as abnormal data according to the average value. The method of determining the median of non-abnormal data: calculate the median of non-abnormal data in historical sales data, and replace the historical sales data determined as abnormal data according to the median. The method of randomly selecting non-abnormal data is as follows: use the non-abnormal data in the historical sales data as a sample pool, randomly screen a non-abnormal data, and replace the historical sales data determined as abnormal data.

[0081] In the above embodiment, step S205 "training the sales prediction model to be trained according to the modified historical sales data set to obtain a trained sales prediction model" may specifically include the following steps S306-S310.

[0082] S306, determining multiple groups of grid parameters of the sales forecasting model to be trained.

[0083] In the disclosed embodiment, the grid parameter is a parameter used to evaluate whether a sub-model (such as a classification model, a regression model) in the sales forecast model to be trained can be built, and to determine the quantile when the data is split and the quantile used when the sub-model cannot be built. Determine multiple groups of grid parameters in the parameters of the sales forecast model to be trained, such as m groups of grid parameters, and initialize these m groups of grid parameters. The grid parameters can be represented by the i-th group of grid parameters (i takes the value of 1, 2, 3, ..., m). For example, the i-th group of grid parameters is determined as shown in Table 3 below, including the first quantity threshold gt_num i , the second quantity threshold n i , probability quantile Q i , quantile qti and cumulative frequency ratio threshold positive_ratio i .

[0084] Table 3 Grid parameters

[0085]

[0086] S307: For each set of grid parameters, obtain the sales forecast value corresponding to the modified historical sales data set based on the sales forecast model to be trained.

[0087] In the embodiment of the present disclosure, the following operation is performed once for each group of grid parameters: based on the sales prediction model to be trained, the sales prediction value corresponding to the modified historical sales data set is obtained. For example, after performing the above operation for the first group of grid parameters, the above operation is performed for the second group of grid parameters, and after completion, the above operation is performed for the third group of grid parameters, ..., and the above operation is performed for the mth group of grid parameters.

[0088] S308: Determine whether the sales prediction model to be trained is overfitting according to the prediction accuracy of the sales prediction value and a preset overfitting parameter.

[0089] In the disclosed embodiments, overfitting means that the model performs very well on the training set, but performs very poorly on the validation set and the test set, that is, the generalization ability of the model is very poor. An overfitting parameter is set in advance. The overfitting parameter is a parameter used to determine whether the model is overfitted. It is a pre-set fixed value and can be set according to user needs. For example, the overfitting parameter may include a first overfitting parameter and a second overfitting parameter. The first overfitting parameter is a pre-set upper limit threshold of the absolute value of the difference between the prediction accuracy of the training set TrainData and the validation set ValiadteData. The second overfitting parameter is a pre-set upper limit threshold of the absolute value of the difference between the prediction accuracy of the training set TrainData and the test set TestData. Determine the prediction accuracy of the sales forecast value, and determine whether the sales forecast model to be trained is overfitted by comparing the prediction accuracy and the overfitting parameter.

[0090] S309, if the sales forecast model to be trained is overfitted, multiple groups of grid parameters are updated, and the step of obtaining the sales forecast value corresponding to the modified historical sales data set based on the sales forecast model to be trained for each group of grid parameters is returned.

[0091] In the disclosed embodiment, if it is determined that the sales forecast model to be trained is overfitted, it is necessary to continue model training: update multiple groups of grid parameters, and return to continue executing step S307.

[0092] S310: If the sales forecast model to be trained is not overfitted, a set of grid parameters with the highest prediction accuracy is determined as parameters of the trained sales forecast model.

[0093] In the embodiment of the present disclosure, if it is determined that the sales prediction model to be trained is not overfitting (not overfitting), there is no need to continue model training, and a set of grid parameters with the highest prediction accuracy is determined as the parameters of the trained sales prediction model, thereby obtaining the trained sales prediction model.

[0094] In some embodiments, Figure 4As shown, the above step S307 "for each set of grid parameters, obtaining the sales forecast value corresponding to the modified historical sales data set based on the sales forecast model to be trained" may specifically include the following steps S401-S403:

[0095] S401, splitting the modified historical sales data set into a second data set, a third data set and a fourth data set.

[0096] In the embodiment of the present disclosure, the modified historical sales data set may be split into three data sets: a second data set Data2, a third data set Data3, and a fourth data set Data4.

[0097] As a feasible implementation method, the modified historical sales data set may be evenly split into three data sets in chronological order.

[0098] As another feasible implementation, a set sales time T can be set in advance, and the data in the modified historical sales data whose sales time is before the set sales time T is used as the first data set Data1, a first proportion, for example 80%, of the data is randomly extracted from the first data set Data1 as the second data set Data2, and the remaining 20% ​​of the data in the first data set Data1 is used as the third data set Data3, that is, the data in the first data set Data1 except the second data set Data2 is used as the third data set Data3, and the data in the modified historical sales data set whose sales time is after the set sales time T is used as the fourth data set Data4.

[0099] S402: Use the second data set as a training set, the third data set as a validation set, and the fourth data set as a test set.

[0100] In the embodiment of the present disclosure, the second data set Data2 is used as the training set TrainData, that is, TrainData = Data2. The third data set Data3 is used as the validation set ValidateData, that is, ValidateData = Data3. The fourth data set Data4 is used as the test set TestData, that is, TestData = Data4.

[0101] S403: For each set of grid parameters, obtain sales forecast values ​​corresponding to the second data set, the third data set, and the fourth data set based on the sales forecast model to be trained.

[0102] In the embodiment of the present disclosure, the following operation is performed once for each set of grid parameters: based on the sales prediction model to be trained, the sales prediction values ​​corresponding to the second data set Data2, the third data set Data3 and the fourth data set Data4 are obtained. For example, after performing the above operation on the first set of grid parameters, the above operation is performed on the second set of grid parameters, and after completion, the above operation is performed on the third set of grid parameters, ..., and the above operation is performed on the mth set of grid parameters.

[0103] In some embodiments, the overfitting parameters include a first overfitting parameter Diff1_threshold and a second overfitting parameter Diff2_threshold. Figure 5 As shown, the above step S307 "determining whether the sales forecast model to be trained is overfitting according to the prediction accuracy of the sales forecast value and the preset overfitting parameter" may specifically include the following steps S501-S504:

[0104] S501, determining a first absolute value of the precision difference, where the first absolute value of the precision difference is the absolute value of the precision difference between the prediction precision of the sales volume prediction value corresponding to the second data set and the prediction precision of the sales volume prediction value corresponding to the third data set.

[0105] In the disclosed embodiment, the prediction accuracies Data2_Pred_stat_i, Data3_Pred_stat_i and Data4_Pred_stat_i of the second data set Data2, the third data set Data3 and the fourth data set Data4 corresponding to the i-th group of grid parameters are calculated. The first absolute value Diff1_i of the difference in accuracy between the prediction accuracy Data2_Pred_stat_i of the second data set Data2 and the prediction accuracy Data3_Pred_stat_i of the third data set Data3 corresponding to the i-th group of grid parameters is calculated, where: Diff1_i=abs(Data2_Pred_stat_i-Data3_Pred_stat_i).

[0106] S502, determining a second absolute value of the precision difference, where the second absolute value of the precision difference is the absolute value of the precision difference between the prediction precision of the sales volume prediction value corresponding to the second data set and the prediction precision of the sales volume prediction value corresponding to the fourth data set.

[0107] In the disclosed embodiment, a second absolute value Diff2_i of the difference in precision between the prediction precision Data2_Pred_stat_i of the second data set Data2 and the prediction precision Data4_Pred_stat_i of the fourth data set Data4 corresponding to the i-th set of grid parameters is calculated, where: Diff2_i=abs(Data2_Pred_stat_i−Data4_Pred_stat_i).

[0108] In S503, if there is at least one set of grid parameters for which the absolute value of the first accuracy difference is less than the first overfitting parameter and the absolute value of the corresponding second accuracy difference is less than the second overfitting parameter, then it is determined that the sales prediction model to be trained is not overfitting.

[0109] In the embodiments of the present disclosure, the first overfitting parameter is the upper threshold of the absolute value of the difference in prediction accuracy between the pre-set training set TrainData and the validation set ValiadteData, that is, the absolute value of the first accuracy difference. The second overfitting parameter is the upper threshold of the absolute value of the difference in prediction accuracy between the pre-set training set TrainData and the test set TestData, that is, the absolute value of the second accuracy difference.

[0110] If there is at least one set of grid parameters, for example, the i-th set of grid parameters, for which the absolute value of the first accuracy difference is less than the first overfitting parameter, i.e., Diff1_i < Diff1_threshold, and the absolute value of the corresponding second accuracy difference is less than the second overfitting parameter, i.e., Diff2_i < Diff2_threshold, then it is determined that the sales prediction model to be trained is not overfitting.

[0111] In S504, if the absolute value of the first accuracy difference corresponding to any set of grid parameters is equal to or greater than the first overfitting parameter, or the absolute value of the corresponding second accuracy difference is equal to or greater than the second overfitting parameter, then it is determined that the sales prediction model to be trained is overfitting.

[0112] In the embodiments of the present disclosure, if there is no set of grid parameters for which the absolute value of the first accuracy difference is less than the first overfitting parameter and the absolute value of the corresponding second accuracy difference is less than the second overfitting parameter, then it is determined that the sales prediction model to be trained is not overfitting. That is, if the absolute value of the first accuracy difference corresponding to any set of grid parameters, for example, the i-th set of grid parameters (i ranges from 1 to m), is equal to or greater than the first overfitting parameter, i.e., Diff1_i ≥ Diff1_threshold, or the absolute value of the corresponding second accuracy difference is equal to or greater than the second overfitting parameter Diff2_i ≥ Diff2_threshold, then it is determined that the sales prediction model to be trained is overfitting.

[0113] In some embodiments, the step of "determining the set of grid parameters with the highest prediction accuracy as the parameters of the trained sales prediction model" in step 310 of the above embodiments may specifically include the following steps: determining the set of grid parameters with the highest prediction accuracy corresponding to the fourth data set Data4 as the parameters of the trained sales prediction model, thereby obtaining the trained sales prediction model.

[0114] In some embodiments, such as Figure 6As shown, the above step S403 of "obtaining sales forecast values ​​corresponding to the second data set, the third data set and the fourth data set based on the sales forecast model to be trained" may specifically include the following steps S601-S611:

[0115] S601, determining whether the conditions for building a classification model are met.

[0116] In the embodiment of the present disclosure, it is determined whether the conditions for building a classification model are met, wherein the conditions for building a classification model may specifically include: the actual sales value corresponding to the training set is a non-single value (that is, the number of values ​​of the actual sales value is greater than 1), and the number of historical sales data in the training set is equal to or greater than the first quantity threshold gt_num in the preset grid parameter i , and the actual sales value corresponding to the training set has a cumulative frequency ratio greater than the cumulative frequency ratio threshold positive_ratio in the preset grid parameter i The actual sales value.

[0117] S602: If it is determined that the conditions for building a classification model are met, a sales classification model is constructed, and sales classification prediction values ​​corresponding to the training set, the validation set, and the test set are obtained based on the sales classification model.

[0118] In the embodiment of the present disclosure, if the conditions for building a classification model are met, a sales classification model is built. The specific process can be as follows: Figure 7 As shown, the following steps S701-S703 are included:

[0119] S701: Among the actual sales values ​​corresponding to the training set, the second smallest actual sales value whose cumulative frequency ratio is greater than the cumulative frequency ratio threshold is used as the classification threshold of the actual sales value.

[0120] In the embodiment of the present disclosure, the cumulative frequency ratio of the actual sales value y corresponding to the training set TrainData is calculated, and an example is shown in the following Table 4:

[0121] Table 4 Cumulative frequency ratio of actual sales value y

[0122] y Frequency of occurrence in the training set Cumulative frequency The total number of training sets Cumulative frequency ratio 13 4 4 10 4 / 10 17 2 6 10 6 / 10 18 3 9 10 9 / 10 20 1 10 10 10 / 10

[0123] If there is an actual sales value in the cumulative frequency ratio of the actual sales value y corresponding to the training set that is greater than the cumulative frequency ratio threshold positive_ratioi in the grid parameter, then the minimum value of y (i.e., the second minimum value) corresponding to it after removing the minimum value of y is taken as the classification threshold Sale of the actual sales value iFor example, if the cumulative frequency ratio threshold positive_ratioi is set to 0.35, then according to Table 4 above, the actual sales values ​​that meet the cumulative frequency ratio>positive_ratioi are 13, 17, and 18. Since 13 is the minimum value, this value is removed, leaving 17 and 18. The minimum value 17 is taken as the classification threshold Salei of the actual sales value. Among them, the classification threshold Salei of the actual sales value is the threshold for splitting the 0 and 1 sales classification prediction values ​​in the classification model.

[0124] S702, the actual sales classification value corresponding to the actual sales value in the training set that is greater than the classification threshold of the actual sales value is recorded as 1, and the actual sales classification value corresponding to the actual sales value in the training set that is equal to or less than the classification threshold of the actual sales value is recorded as 0.

[0125] In the embodiment of the present disclosure, the label (dependent variable) y1 of the classification model is defined as follows: In the training set TrainData, the actual sales value y is greater than the classification threshold Sale of the actual sales value i The actual sales value corresponding to the sales classification actual value is defined as 1, and the actual sales value y is equal to or less than the classification threshold Sale of the sales forecast value. i The actual sales value of the sales category corresponding to the actual sales value is defined as 0.

[0126] S703: Build a sales volume classification model according to the actual sales volume classification values ​​of the training set.

[0127] In the disclosed embodiment, a sales classification model is constructed for the actual sales classification values ​​of the training set TrainData, wherein the dependent variable, i.e., the predictor variable, of the sales classification model is a binary variable y1.

[0128] The constructed sales classification model is used to predict the training set TrainData, the validation set ValiadteData and the test set TestData to obtain the corresponding sales classification prediction values.

[0129] S603, determining the sales classification prediction value quantile corresponding to the training set according to the sales classification prediction value corresponding to the training set and the probability quantile preset in the grid parameters.

[0130] In the embodiment of the present disclosure, according to the sales classification prediction value corresponding to the training set TrainData and the probability quantile Q in the grid parameter i , calculate the sales classification prediction value quantile qty_i corresponding to the training set TrainData.

[0131] S604, the data whose sales classification prediction values ​​in the training set, validation set and test set are less than the sales classification prediction value quantile are used as the first training set, the first validation set and the first test set respectively, and the data whose sales classification prediction values ​​in the training set, validation set and test set are equal to or greater than the sales classification prediction value quantile are used as the second training set, the second validation set and the second test set respectively.

[0132] In the embodiment of the present disclosure, the sales classification prediction value quantile qty_i calculated in step S603 is used to split the data: the data in the training set TrainData whose sales classification prediction value is less than the sales classification prediction value quantile qty_i is used as the first training set TrainData1, and the data in the training set TrainData whose sales classification prediction value is equal to or greater than the sales classification prediction value quantile qty_i is used as the second training set TrainData2; the data in the validation set ValiadteData whose sales classification prediction value is less than the sales classification prediction value quantile qty_i is used as the first validation set ValiadteData1, and the data in the validation set ValiadteData whose sales classification prediction value is equal to or greater than the sales classification prediction value quantile qty_i is used as the second validation set ValiadteData2; the data in the test set TestData whose sales classification prediction value is less than the sales classification prediction value quantile qty_i is used as the first test set TestData1, and the data in the test set TestData whose sales classification prediction value is equal to or greater than the sales classification prediction value quantile qty_i is used as the second test set TestData2.

[0133] S605, determining whether the conditions for building a regression model are met.

[0134] In the embodiment of the present disclosure, it is determined whether the condition for building a regression model is met, and the condition for building a regression model includes that the number of historical sales data in the first training set is equal to or greater than the second number threshold n in the preset grid parameter. i If the conditions for building a regression model are met, a regression model is built.

[0135] S606, if it is determined that the conditions for building a regression model are met, a sales regression model is constructed with the sales forecast value corresponding to the first training set as the dependent variable, and sales forecast values ​​corresponding to the first training set, the first validation set and the first test set are obtained based on the sales regression model.

[0136] In the embodiment of the present disclosure, if the amount of historical sales data in the first training set is equal to or greater than the second amount threshold n in the preset grid parameter i, then use the first training set to take the sales forecast value y as the dependent variable (i.e., the predictor variable, output variable, and target variable) to build a sales regression model, and use the sales regression model to predict the first training set, the first validation set, and the first test set to obtain the corresponding sales forecast value.

[0137] S607, determining whether the second training set is empty.

[0138] In the disclosed embodiment, it is determined whether the second training set TrainData2 is empty, that is, it is determined whether there is historical sales data in the second training set TrainData2.

[0139] S608: If the second training set is empty, the sales forecast values ​​corresponding to the first training set, the first validation set and the first test set are output.

[0140] In the disclosed embodiment, if the second training set TrainData2 is empty, data splitting and sales prediction will no longer be performed, and the sales prediction values ​​corresponding to the first training set TrainData1, the first validation set ValiadteData1 and the first test set TestData1 will be directly output.

[0141] S609, if it is determined that the conditions for building a classification model are not met, the actual sales value quantile corresponding to the training set is determined based on the actual sales value corresponding to the training set and the quantile preset in the grid parameters, and the actual sales value quantile is used as the sales prediction value corresponding to the training set, validation set and test set, and the sales prediction value corresponding to the training set, validation set and test set is output.

[0142] In the embodiment of the present disclosure, if it is determined in step S601 that the conditions for building a classification model are not met, the classification model cannot be built. Therefore, the actual sales value corresponding to the training set and the quantile qt preset in the grid parameter can be used to calculate the classification model. i Determine the actual sales value qt corresponding to the training set i quantile, and the actual sales value qt i The quantiles are used as the sales forecast values ​​corresponding to the training set TrainData, the validation set ValiadteData, and the test set TestData. And the sales forecast values ​​corresponding to the training set TrainData, the validation set ValiadteData, and the test set TestData are output.

[0143] S610, if it is determined that the conditions for building a regression model are not met, the actual sales value quantile corresponding to the training set is determined based on the actual sales value corresponding to the training set and the quantile preset in the grid parameters, the actual sales value quantile is used as the sales prediction value corresponding to the training set, validation set and test set, and the sales prediction value corresponding to the training set, validation set and test set is output.

[0144] In the embodiment of the present disclosure, if it is determined in step S605 that the condition for building a regression model is not met, the regression model cannot be built. Therefore, the actual sales value corresponding to the training set and the quantile qt preset in the grid parameter can be used to calculate the regression model. i Determine the sales forecast value qt corresponding to the training set i Quantile, and the qt of the sales forecast value i The quantiles are used as the sales forecast values ​​corresponding to the training set TrainData, the validation set ValiadteData, and the test set TestData. And the sales forecast values ​​corresponding to the training set TrainData, the validation set ValiadteData, and the test set TestData are output.

[0145] S611, if the second training set is not empty, the second training set is used as the training set, the second validation set is used as the validation set, the second test set is used as the test set, and the process returns to the step of determining whether the condition for building a classification model is met.

[0146] In the embodiment of the present disclosure, if it is determined in step S607 that the second training set is not empty, it is necessary to continue to split the data and sales forecast. Therefore, the second training set TrainData2 is used as a new training set, the second validation set ValiadteData2 is used as a new validation set, and the second test set TestData2 is used as a new test set, and return to step S601 to determine whether the conditions for building a classification model are met.

[0147] In summary, the method for generating a sales forecast model provided by the embodiment of the present disclosure obtains a historical sales data set including multiple historical sales data, determines the mean value and standard deviation of the historical sales data in the historical sales data, determines the abnormal data in the historical sales data according to the mean value and standard deviation, and modifies the abnormal data according to the non-abnormal data in the historical sales data, and trains the sales forecast model to be trained according to the modified historical sales data set to obtain the trained sales forecast model. The embodiment of the present disclosure determines the abnormal data in the historical sales data by determining the mean value and standard deviation, and modifies the abnormal data according to the non-abnormal data in the historical sales data, so that the values ​​of the modified historical sales data are more balanced, thereby making the prediction accuracy of the trained sales forecast model more accurate, and improving the accuracy of sales forecast. In addition, when the conditions for building a classification model and a regression model are met, the classification model and the regression model are built to predict sales. When the conditions for building a classification model and a regression model are not met, the quantile of the actual sales value of the training set is used as the sales forecast value of the training set, the validation set and the test set, which further improves the accuracy of sales forecast compared to using a single type of model.

[0148] To clearly illustrate the method for generating the sales forecast model in the embodiment of the present disclosure, Figure 8 An exemplary implementation of the method for generating a sales forecasting model according to an embodiment of the present disclosure is described. Figure 8 As shown, the method for generating the sales forecast model of the embodiment of the present disclosure includes:

[0149] S801, obtaining a historical sales data set, where the historical sales data set includes multiple pieces of historical sales data, and the historical sales data includes historical sales volume data.

[0150] S802, perform data cleaning on the historical sales data set: determine μ and standard deviation σ of the historical sales data, determine the historical sales data that is greater than the abnormal sales data threshold μ+3σ as abnormal data, and randomly select one of the non-abnormal data in the historical sales data to replace the abnormal data.

[0151] S803, splitting the modified historical sales data set into a second data set Data2, a third data set Data3 and a fourth data set Data4.

[0152] S804, determining the current i-th group of grid parameters corresponding to the sales forecast model to be trained, where the grid parameters include the first quantity threshold gt_num i , the second quantity threshold n i , probability quantile Q i , quantile qt i And the cumulative frequency ratio threshold positive_ratio i .

[0153] S805, let the training set TrainData = the second data set Data2, the validation set ValidateData = the third data set Data3, and the test set TestData = the fourth data set Data4.

[0154] S806, determine whether the actual sales value corresponding to the training set TrainData is a single value. If so, execute step S820; if not, execute step S807.

[0155] S807: Determine whether the number of historical sales data in the training set TrainData is equal to or greater than the first number threshold gt_num in the grid parameter i If not, execute step S820; if so, execute step S808.

[0156] S808, determine whether there is a cumulative frequency ratio in the training set TrainData that is greater than the cumulative frequency ratio threshold positive_ratio in the grid parameter iIf not, execute step S820; if yes, execute step S809.

[0157] S809: Set the cumulative frequency ratio in the training set TrainData to be greater than the cumulative frequency ratio threshold positive_ratio i The second smallest actual sales value is used as the classification threshold of the actual sales value Sale i .

[0158] S810, define a new label y1: set the classification threshold Sale in the training set TrainData that is greater than the actual sales value i The actual sales value corresponding to the sales classification actual value is recorded as 1, and the classification threshold Sale in the training set TrainData that is equal to or less than the actual sales value is recorded as 1. i The actual sales value of the sales category corresponding to the actual sales value is recorded as 0.

[0159] S811, building a sales classification model according to the actual sales classification values ​​of the training set TrainData.

[0160] S812, perform probability prediction on the training set TrainData, the validation set ValiadteData and the test set TestData to obtain corresponding sales classification prediction values.

[0161] S813, based on the sales classification prediction value and probability quantile Q corresponding to the training set TrainData i , determine the sales classification prediction value quantile qty_i corresponding to the training set TrainData.

[0162] S814, split the data: use the data in the training set TrainData, validation set ValiadteData and test set TestData whose sales classification prediction value is less than the sales classification prediction value quantile qty_i as the first training set TrainData1, the first validation set ValiadteData1 and the first test set TestData1 respectively, and use the remaining data as the second training set TrainData2, the second validation set ValiadteData2 and the second test set TestData2.

[0163] S815, determining whether the number of historical sales data in the first training set TrainData1 is equal to or greater than the second number threshold n in the grid parameter i If not, execute step S820; if so, execute step S816.

[0164] S816, building a sales regression model with the sales prediction value y of the sales prediction model corresponding to the first training set TrainData1 as the dependent variable, and obtaining the sales prediction values ​​corresponding to the first training set TrainData1, the first validation set ValiadteData1 and the first test set TestData1 based on the sales regression model.

[0165] S817, determine whether the second training set TrainData2 is empty. If not, execute step S818. If yes, execute step S819.

[0166] S818, let TrainData=TrainData2, ValiadteData=ValiadteData2, TestData=TestData2. Return to step S806.

[0167] S819, output the sales forecast values ​​corresponding to the first training set TrainData1, the first validation set ValiadteData1 and the first test set TestData1.

[0168] S820, the actual sales value corresponding to the training set TrainData is qt i The quantiles are used as sales prediction values ​​corresponding to the training set TrainData, the validation set ValiadteData, and the test set TestData.

[0169] S821, record the sales forecast values ​​of all times.

[0170] S822, determine whether the execution number i is equal to m. If not, execute step S804 to re-determine the current i-th group of grid parameters. If yes, execute step S823.

[0171] S823, determining the prediction accuracies Data2_Pred_stat_i, Data3_Pred_stat_i and Data4_Pred_stat_i of the second data set Data2, the third data set Data3 and the fourth data set Data4 corresponding to the i-th group of grid parameters.

[0172] S824, determine the first absolute value of the precision difference Diff1_i=abs(Data2_Pred_stat_i-Data3_Pred_stat_i).

[0173] S825, determine whether there is at least one set of grid parameters where Diff1_i<the first overfitting parameter Diff1_threshold. If not, update the m sets of grid parameters and return to step S804 to re-determine the current i-th set of grid parameters. If yes, execute step S826.

[0174] S826 , determine the second absolute value of the accuracy difference Diff2_i=abs(Data2_Pred_stat_i−Data4_Pred_stat_i).

[0175] S827, determine whether there is at least one set of grid parameters where Diff2_i<the second overfitting parameter Diff2_threshold. If not, update the m sets of grid parameters, and return to step S804 to re-determine the current i-th set of grid parameters. If yes, execute step S828.

[0176] S828, determining a group of grid parameters with the highest prediction accuracy corresponding to the fourth data set Data4 as parameters of the trained sales prediction model, and obtaining the trained sales prediction model.

[0177] Fig. 9 FIG. 1 is a block diagram of a device for generating a sales forecast model according to an exemplary embodiment. Fig. 9 As shown, the sales prediction model generation device 900 of the embodiment of the present disclosure includes: an acquisition module 901, a first determination module 902, a second determination module 903, a modification module 904 and a training module 905.

[0178] The acquisition module 901 is configured to acquire a historical sales data set, where the historical sales data set includes multiple historical sales data, and the historical sales data includes historical sales volume data.

[0179] The first determination module 902 is configured to determine the average value and standard deviation of the historical sales data.

[0180] The second determination module 903 is configured to determine abnormal data in the historical sales data according to the average value and the standard deviation.

[0181] The modification module 904 is configured to modify the abnormal data according to the non-abnormal data in the historical sales data.

[0182] The training module 905 is configured to train the sales forecasting model to be trained according to the modified historical sales data set to obtain a trained sales forecasting model.

[0183] In one embodiment of the present disclosure, the second determination module 903 is further configured to: determine an abnormal sales data threshold based on the average value and the standard deviation; and determine that historical sales data greater than the abnormal sales data threshold is abnormal data.

[0184] In one embodiment of the present disclosure, the second determination module 903 is further configured to: determine the product value of the standard deviation and a preset multiple; determine the sum of the average value and the product value; and use the sum as the abnormal sales data threshold.

[0185] In one embodiment of the present disclosure, the modification module 904 is further configured to randomly select one of the non-abnormal data to replace the abnormal data.

[0186] In one embodiment of the present disclosure, the training module 905 is further configured to: determine multiple groups of grid parameters of the sales prediction model to be trained, the grid parameters being parameters used to evaluate whether a sub-model in the sales prediction model to be trained can be built, and for determining the quantile during data splitting and the quantile used when the sub-model cannot be built; for each group of grid parameters, obtain a sales prediction value corresponding to a modified historical sales data set based on the sales prediction model to be trained; determine whether the sales prediction model to be trained is overfit according to the prediction accuracy of the sales prediction value and a preset overfitting parameter; if the sales prediction model to be trained is overfit, update the multiple groups of grid parameters, and return to the step of obtaining the sales prediction value corresponding to the modified historical sales data set based on the sales prediction model to be trained for each group of grid parameters; if the sales prediction model to be trained is not overfit, determine the group of grid parameters with the highest prediction accuracy as the parameters of the trained sales prediction model.

[0187] In one embodiment of the present disclosure, the training module 905 is further configured to: split the modified historical sales data set into a second data set, a third data set and a fourth data set; use the second data set as a training set, the third data set as a validation set, and the fourth data set as a test set; for each set of grid parameters, obtain sales prediction values ​​corresponding to the second data set, the third data set and the fourth data set based on the sales prediction model to be trained.

[0188] In one embodiment of the present disclosure, the training module 905 is further configured to: use the data in the modified historical sales data set whose sales time is before the set sales time as the first data set; randomly extract a first proportion of data in the first data set as the second data set; use the data in the first data set except the second data set as the third data set; use the data in the modified historical sales data set whose sales time is after the set sales time as the fourth data set.

[0189] In one embodiment of the present disclosure, the overfitting parameters include a first overfitting parameter and a second overfitting parameter, and the training module 905 is further configured to: determine a first absolute value of precision difference, which is the absolute value of the precision difference between the prediction precision of the sales prediction value corresponding to the second data set and the prediction precision of the sales prediction value corresponding to the third data set; determine a second absolute value of precision difference, which is the absolute value of the precision difference between the prediction precision of the sales prediction value corresponding to the second data set and the prediction precision of the sales prediction value corresponding to the fourth data set; if there is at least one group of grid parameters whose corresponding first absolute value of precision difference is less than the first overfitting parameter, and whose corresponding second absolute value of precision difference is less than the second overfitting parameter, then it is judged that the sales prediction model to be trained is not overfitted; if the absolute value of the first precision difference corresponding to any group of grid parameters is equal to or greater than the first overfitting parameter, or the corresponding second absolute value of precision difference is equal to or greater than the second overfitting parameter, then it is judged that the sales prediction model to be trained is overfitted.

[0190] In one embodiment of the present disclosure, the training module 905 is further configured to: determine a group of grid parameters with the highest prediction accuracy corresponding to the fourth data set as parameters of the trained sales prediction model.

[0191] In one embodiment of the present disclosure, the training module 905 is further configured to: determine whether the conditions for building a classification model are met; if it is determined that the conditions for building a classification model are met, then build a sales classification model, and obtain the sales classification prediction values ​​corresponding to the training set, the validation set and the test set based on the sales classification model; determine the sales classification prediction value quantile corresponding to the training set according to the sales classification prediction value corresponding to the training set and the probability quantile preset in the grid parameter; use the data in the training set, the validation set and the test set whose sales classification prediction values ​​are less than the sales classification prediction value quantile as the first training set, the first validation set and the first test set respectively, and use the data in the training set, the validation set and the test set whose sales classification prediction values ​​are equal to or greater than the sales classification prediction value quantile as the second training set, the second validation set and the second test set; determine whether the conditions for building a regression model are met; if it is determined that the conditions for building a regression model are met, then build a sales regression model with the sales prediction value corresponding to the first training set as the dependent variable, and obtain the sales prediction values ​​corresponding to the first training set, the first validation set and the first test set based on the sales regression model; if the second training set is empty, output the sales prediction values ​​corresponding to the first training set, the first validation set and the first test set.

[0192] In one embodiment of the present disclosure, the training module 905 is further configured to: if it is determined that the conditions for building a classification model are not met, determine the actual sales value quantile corresponding to the training set based on the actual sales value corresponding to the training set and the quantile preset in the grid parameters, use the actual sales value quantile as the sales prediction value corresponding to the training set, the validation set and the test set, and output the sales prediction value corresponding to the training set, the validation set and the test set.

[0193] In one embodiment of the present disclosure, the training module 905 is further configured to: if it is determined that the conditions for building a regression model are not met, determine the actual sales value quantile corresponding to the training set based on the actual sales value corresponding to the training set and the quantile preset in the grid parameter, use the actual sales value quantile as the sales prediction value corresponding to the training set, the validation set and the test set, and output the sales prediction value corresponding to the training set, the validation set and the test set.

[0194] In one embodiment of the present disclosure, the training module 905 is further configured to: if the second training set is not empty, use the second training set as the training set, use the second validation set as the validation set, use the second test set as the test set, and return to determine whether the conditional step for building a classification model is met.

[0195] In one embodiment of the present disclosure, the conditions for building a classification model include: the actual sales value corresponding to the training set is a non-single value, and the number of historical sales data in the training set is equal to or greater than the first quantity threshold preset in the grid parameter, and there are actual sales values ​​in the actual sales value corresponding to the training set whose cumulative frequency ratio is greater than the preset cumulative frequency ratio threshold.

[0196] In one embodiment of the present disclosure, the training module 905 is further configured to: take the second smallest actual sales value whose cumulative frequency share is greater than the cumulative frequency share threshold among the actual sales value corresponding to the training set as the classification threshold of the actual sales value; record the sales classification actual value corresponding to the actual sales value in the training set that is greater than the classification threshold of the actual sales value as 1, and record the sales classification actual value corresponding to the actual sales value in the training set that is equal to or less than the classification threshold of the actual sales value as 0; and construct a sales classification model based on the sales classification actual values ​​of the training set.

[0197] In the embodiments of the present disclosure, the specific manner in which each module in the device of the above embodiments performs operations has been described in detail in the embodiments of the method, and will not be repeated here.

[0198] In summary, the generation device of the sales prediction model provided by the embodiment of the present disclosure obtains a historical sales data set including multiple historical sales data, determines the mean value and standard deviation of the historical sales data in the historical sales data, determines the abnormal data in the historical sales data according to the mean value and standard deviation, and modifies the abnormal data according to the non-abnormal data in the historical sales data, and trains the sales prediction model to be trained according to the modified historical sales data set to obtain the trained sales prediction model. The embodiment of the present disclosure determines the abnormal data in the historical sales data by determining the mean value and standard deviation, and modifies the abnormal data according to the non-abnormal data in the historical sales data, so that the values ​​of the modified historical sales data are more balanced, thereby making the prediction accuracy of the trained sales prediction model more accurate, and improving the accuracy of sales prediction. In addition, when the conditions for building a classification model and a regression model are met, the classification model and the regression model are built to predict sales. When the conditions for building a classification model and a regression model are not met, the quantile of the actual sales value of the training set is used as the sales prediction value of the training set, the validation set and the test set, which further improves the accuracy of sales prediction compared to using a single type of model.

[0199] In order to implement the above embodiment, Fig.10 As shown, the embodiment of the present disclosure further proposes an electronic device 1000, including a device 900 for generating the above-mentioned sales prediction model.

[0200] The electronic device of the disclosed embodiment obtains a historical sales data set including a plurality of historical sales data, determines the mean value and standard deviation of the historical sales data in the historical sales data, determines the abnormal data in the historical sales data according to the mean value and standard deviation, modifies the abnormal data according to the non-abnormal data in the historical sales data, and trains the sales prediction model to be trained according to the modified historical sales data set to obtain the trained sales prediction model. The disclosed embodiment determines the abnormal data in the historical sales data by determining the mean value and standard deviation, and modifies the abnormal data according to the non-abnormal data in the historical sales data, so that the values ​​of the modified historical sales data are more balanced, thereby making the prediction accuracy of the trained sales prediction model more accurate, and improving the accuracy of sales prediction. In addition, when the conditions for building a classification model and a regression model are met, the classification model and the regression model are built to predict sales. When the conditions for building a classification model and a regression model are not met, the quantile of the actual sales value of the training set is used as the sales prediction value of the training set, the validation set and the test set, which further improves the accuracy of sales prediction compared to using a single type of model.

[0201] Fig.11 is a block diagram of an electronic device 1000 according to an exemplary embodiment.

[0202] like Fig.11 As shown, the electronic device 1000 includes:

[0203] The memory 1101 and the processor 1102, a bus 1103 connecting different components (including the memory 1101 and the processor 1102), the memory 1101 stores a computer program, and when the processor 1102 executes the program, the method for generating the sales forecast model of the embodiment of the present disclosure is implemented.

[0204] Bus 1103 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor or a local bus using any of a variety of bus structures. For example, these architectures include but are not limited to Industry Standard Architecture (ISA) bus, Micro Channel Architecture (MAC) bus, Enhanced ISA bus, Video Electronics Standards Association (VESA) local bus and Peripheral Component Interconnect (PCI) bus.

[0205] The electronic device 1100 typically includes a variety of electronic device readable media. These media can be any available media that can be accessed by the electronic device 1100, including volatile and non-volatile media, removable and non-removable media.

[0206] The memory 1101 may also include computer system readable media in the form of volatile memory, such as random access memory (RAM) 1104 and / or cache memory 1105. The electronic device 1100 may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, the storage system 1106 may be used to read and write non-removable, non-volatile magnetic media ( Fig.11 not shown, usually called a "hard drive"). Although Fig.11 Not shown in the figure, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk"), and an optical disk drive for reading and writing to a removable non-volatile optical disk (e.g., a CD-ROM, a DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to the bus 1103 via one or more data medium interfaces. The memory 1101 may include at least one program product having a set (e.g., at least one) of program modules that are configured to perform the functions of the various embodiments of the present disclosure.

[0207] A program / utility 1108 having a set (at least one) of program modules 1107 may be stored, for example, in the memory 1101. Such program modules 1107 include, but are not limited to, an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment. The program modules 1107 generally perform the functions and / or methods of the embodiments described in the present disclosure.

[0208] The electronic device 1100 may also communicate with one or more external devices 1109 (e.g., keyboard, pointing device, display 1111, etc.), one or more devices that enable a user to interact with the electronic device 1100, and / or any device that enables the electronic device 1100 to communicate with one or more other computing devices (e.g., network card, modem, etc.). Such communication may be performed through an input / output (I / O) interface 1112. Furthermore, the electronic device 1100 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) through a network adapter 1113. Fig.11 As shown, the network adapter 1113 communicates with other modules of the electronic device 1100 via the bus 1103. It should be understood that, although not shown in the figure, other hardware and / or software modules can be used in conjunction with the electronic device 1100, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.

[0209] The processor 1102 executes the programs stored in the memory 1101 to perform various functional applications and data processing.

[0210] It should be noted that the implementation process and technical principles of the electronic device of this embodiment can be found in the aforementioned explanation of the method for generating the sales forecast model of the embodiment of the present disclosure, and will not be repeated here.

[0211] The electronic device provided by the embodiment of the present disclosure obtains a historical sales data set including multiple historical sales data, determines the average value and standard deviation of the historical sales data in the historical sales data, determines the abnormal data in the historical sales data according to the average value and standard deviation, modifies the abnormal data according to the non-abnormal data in the historical sales data, and trains the sales prediction model to be trained according to the modified historical sales data set to obtain the trained sales prediction model. The embodiment of the present disclosure determines the abnormal data in the historical sales data by determining the average value and standard deviation, and modifies the abnormal data according to the non-abnormal data in the historical sales data, so that the values ​​of the modified historical sales data are more balanced, thereby making the prediction accuracy of the trained sales prediction model more accurate, and improving the accuracy of sales prediction. In addition, when the conditions for building a classification model and a regression model are met, the classification model and the regression model are built to predict sales. When the conditions for building a classification model and a regression model are not met, the quantile of the actual sales value of the training set is used as the sales prediction value of the training set, the validation set and the test set, which further improves the accuracy of sales prediction compared to using a single type of model.

[0212] In order to implement the above embodiments, the present disclosure also proposes a computer-readable storage medium.

[0213] When the instructions in the computer-readable storage medium are executed by the processor of the electronic device, the electronic device can execute the method for generating the sales forecast model as described above. Optionally, the computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0214] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses or adaptations of the present disclosure that follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The description and examples are to be considered exemplary only, and the true scope and spirit of the present disclosure are indicated by the following claims.

[0215] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims

1. A method for generating a sales forecast model, characterized in that: include: Acquire a historical sales data set, wherein the historical sales data set includes multiple historical sales data, and the historical sales data includes historical sales volume data; Determining the mean and standard deviation of the historical sales data; Determine abnormal data in the historical sales data according to the mean value and the standard deviation; Modifying the abnormal data according to the non-abnormal data in the historical sales data; The sales volume prediction model to be trained is trained according to the modified historical sales data set to obtain a trained sales volume prediction model.

2. The generation method according to claim 1, characterized in that: The determining of abnormal data in the historical sales data according to the mean value and the standard deviation includes: Determine an abnormal sales data threshold value based on the mean value and the standard deviation; Determine that the historical sales data that is greater than the abnormal sales data threshold is abnormal data.

3. The generation method according to claim 2, characterized in that: The determining of the abnormal sales data threshold according to the mean value and the standard deviation includes: Determine a product value of the standard deviation and a preset multiple; determining a sum of the average value and the product value; The sum is used as the abnormal sales data threshold.

4. The generation method according to claim 1, characterized in that: The modifying the abnormal data according to the non-abnormal data in the historical sales data includes: One of the non-abnormal data is randomly selected to replace the abnormal data.

5. The generation method according to claim 1, characterized in that: The training of the sales forecasting model to be trained according to the modified historical sales data set to obtain the trained sales forecasting model includes: Determine multiple groups of grid parameters of the sales forecast model to be trained, wherein the grid parameters are parameters used to evaluate whether a sub-model in the sales forecast model to be trained can be built, and to determine the quantile when splitting data and the quantile used when the sub-model cannot be built; For each group of the grid parameters, obtaining a sales forecast value corresponding to the modified historical sales data set based on the sales forecast model to be trained; Determining whether the sales forecast model to be trained is overfitting according to the forecast accuracy of the sales forecast value and a preset overfitting parameter; If the sales forecast model to be trained is overfitted, the multiple groups of grid parameters are updated, and the step of obtaining the sales forecast value corresponding to the modified historical sales data set based on the sales forecast model to be trained for each group of grid parameters is returned; If the sales forecast model to be trained is not overfitted, a group of the grid parameters with the highest prediction accuracy is determined as the parameters of the trained sales forecast model.

6. The generation method according to claim 5, characterized in that: The step of obtaining, for each group of the grid parameters, a sales volume forecast value corresponding to the modified historical sales data set based on the sales volume forecast model to be trained includes: Splitting the modified historical sales data set into a second data set, a third data set and a fourth data set; Using the second data set as a training set, using the third data set as a validation set, and using the fourth data set as a test set; For each set of the grid parameters, sales forecast values ​​corresponding to the second data set, the third data set and the fourth data set are obtained based on the sales forecast model to be trained.

7. The generation method according to claim 6, characterized in that: The step of splitting the modified historical sales data set into a second data set, a third data set, and a fourth data set includes: The data in the modified historical sales data set whose sales time is before the set sales time is used as the first data set; Randomly extracting a first proportion of data from the first data set as the second data set; taking the data in the first data set except the second data set as the third data set; The data in the modified historical sales data set whose sales time is after the set sales time is used as the fourth data set.

8. The generation method according to claim 6, characterized in that: The overfitting parameter includes a first overfitting parameter and a second overfitting parameter, and determining whether the sales forecast model to be trained is overfitting according to the prediction accuracy of the sales forecast value and the preset overfitting parameter includes: Determine a first absolute value of the precision difference, where the first absolute value of the precision difference is the absolute value of the precision difference between the prediction precision of the sales volume prediction value corresponding to the second data set and the prediction precision of the sales volume prediction value corresponding to the third data set; Determine a second absolute value of the precision difference, where the second absolute value of the precision difference is the absolute value of the precision difference between the prediction precision of the sales volume prediction value corresponding to the second data set and the prediction precision of the sales volume prediction value corresponding to the fourth data set; If there is at least one set of the grid parameters whose corresponding absolute value of the first precision difference is smaller than the first overfitting parameter, and whose corresponding absolute value of the second precision difference is smaller than the second overfitting parameter, it is determined that the sales forecast model to be trained is not overfitted; If the absolute value of the first precision difference corresponding to any group of the grid parameters is equal to or greater than the first overfitting parameter, or the corresponding absolute value of the second precision difference is equal to or greater than the second overfitting parameter, it is determined that the sales forecast model to be trained is overfitting.

9. The generation method according to claim 6, characterized in that: The step of determining a group of grid parameters with the highest prediction accuracy as parameters of the trained sales prediction model includes: A set of the grid parameters with the highest prediction accuracy corresponding to the fourth data set is determined as the parameters of the trained sales forecasting model.

10. The generation method according to claim 6, characterized in that: The acquiring sales forecast values ​​corresponding to the second data set, the third data set, and the fourth data set based on the sales forecast model to be trained includes: Determine whether the conditions for building a classification model are met; If it is determined that the conditions for building a classification model are met, a sales classification model is constructed, and sales classification prediction values ​​corresponding to the training set, the validation set, and the test set are obtained based on the sales classification model; Determine the sales classification prediction value quantile corresponding to the training set according to the sales classification prediction value corresponding to the training set and the probability quantile preset in the grid parameter; The data in the training set, the validation set and the test set whose sales classification prediction values ​​are less than the sales classification prediction value quantile are respectively used as the first training set, the first validation set and the first test set, and the data in the training set, the validation set and the test set whose sales classification prediction values ​​are equal to or greater than the sales classification prediction value quantile are used as the second training set, the second validation set and the second test set; Determine whether the conditions for building a regression model are met; If it is determined that the conditions for building a regression model are met, a sales regression model is constructed with the sales forecast value corresponding to the first training set as a dependent variable, and sales forecast values ​​corresponding to the first training set, the first validation set, and the first test set are obtained based on the sales regression model; If the second training set is empty, the sales forecast values ​​corresponding to the first training set, the first validation set and the first test set are output.

11. The generation method according to claim 10, characterized in that: Also includes: If it is determined that the conditions for building a classification model are not met, the actual sales value quantile corresponding to the training set is determined based on the actual sales value corresponding to the training set and the quantile preset in the grid parameter, and the actual sales value quantile is used as the sales forecast value corresponding to the training set, the validation set and the test set, and the sales forecast value corresponding to the training set, the validation set and the test set is output.

12. The generation method according to claim 10, characterized in that: Also includes: If it is determined that the conditions for building a regression model are not met, the actual sales value quantile corresponding to the training set is determined according to the actual sales value corresponding to the training set and the quantile preset in the grid parameter, the actual sales value quantile is used as the sales prediction value corresponding to the training set, the validation set and the test set, and the sales prediction value corresponding to the training set, the validation set and the test set is output.

13. The generation method according to claim 10, characterized in that: Also includes: If the second training set is not empty, the second training set is used as the training set, the second validation set is used as the validation set, the second test set is used as the test set, and the step of determining whether the condition for building a classification model is met is returned.

14. The generation method according to claim 10, characterized in that: The conditions for building the classification model include: the actual sales value corresponding to the training set is a non-single value, and the number of the historical sales data in the training set is equal to or greater than the first quantity threshold preset in the grid parameter, and the actual sales value corresponding to the training set has a cumulative frequency ratio greater than a preset cumulative frequency ratio threshold.

15. The generation method according to claim 14, characterized in that: The constructing of the sales volume classification model includes: Among the actual sales values ​​corresponding to the training set, the second smallest actual sales value whose cumulative frequency ratio is greater than the cumulative frequency ratio threshold is used as the classification threshold of the actual sales value; The sales classification actual value corresponding to the sales actual value in the training set that is greater than the classification threshold of the sales actual value is recorded as 1, and the sales classification actual value corresponding to the sales actual value in the training set that is equal to or less than the classification threshold of the sales actual value is recorded as 0; The sales volume classification model is constructed according to the actual sales volume classification values ​​of the training set.

16. A device for generating a sales forecast model, characterized in that: include: An acquisition module is configured to acquire a historical sales data set, wherein the historical sales data set includes a plurality of historical sales data, and the historical sales data includes historical sales volume data; A first determination module is configured to determine the average value and standard deviation of the historical sales data; A second determination module is configured to determine abnormal data in the historical sales data according to the average value and the standard deviation; A modification module, configured to modify the abnormal data according to the non-abnormal data in the historical sales data; The training module is configured to train the sales forecasting model to be trained according to the modified historical sales data set to obtain a trained sales forecasting model.

17. An electronic device, characterized in that: include: A device for generating a sales forecast model as described in claim 16.

18. An electronic device, characterized in that: include: processor; a memory for storing executable instructions for the processor; Wherein, the processor is configured to execute the instructions to implement the method for generating a sales forecasting model as described in any one of claims 1-15.

19. A computer-readable storage medium, characterized in that: When the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the method for generating a sales forecast model as described in any one of claims 1-15.