Capacity prediction model training method, capacity prediction method, device and equipment
By combining business and capacity data and text information samples, the capacity prediction model is trained, and the attention weight of the scaled capacity classification model is used to solve the problem of inaccurate capacity prediction in the prior art, achieving higher prediction accuracy and better capacity management.
Patent Information
- Application Number
- CN202010870600.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-08-26
- Publication Date
- 2025-04-29
- Estimated Expiration
- 2040-08-26
AI Technical Summary
The prior art relies on human experience in capacity prediction, and the considerations are not comprehensive enough, resulting in the prediction results being inaccurate enough.
The capacity prediction model is trained by combining the own data of the business and capacity and the corresponding text information such as the business capacity plan. The preset expansion and classification model is used to analyze the text information samples, and the attention weight is incorporated to enrich the data samples and weights of the model training.
Improve the accuracy of the capacity prediction model, optimize capacity management, and reduce time, manpower and resource costs.
Smart Images

Figure CN114116417B_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of computer technology, and in particular, relates to a capacity prediction model training method, a capacity prediction method, an apparatus, a device, and a computer storage medium. Background Art
[0002] In daily operations, capacity management is a management method that ensures that business loads meet customer needs and service levels by tracking and controlling the capacity of application systems. In capacity management, how to effectively predict the capacity status of business application systems is the focus of industry research.
[0003] Existing related technologies include management methods that passively perceive capacity status through alarm information, and capacity prediction using performance test results, etc. However, these related technologies still have some defects, such as relying on human experience and incomplete consideration of factors, which leads to inaccurate prediction results. Summary of the invention
[0004] The embodiments of the present application provide a training method for a capacity prediction model, a capacity prediction method, an apparatus, a device, and a computer storage medium, which can train the capacity prediction model by using training samples that combine text information such as business and capacity data and corresponding business capacity plans, thereby enriching the data samples and weights for model training and improving the accuracy of the capacity prediction model.
[0005] In a first aspect, an embodiment of the present application provides a method for training a capacity prediction model, the method comprising:
[0006] Obtaining business data samples, capacity data samples, and text information samples describing business and capacity;
[0007] Inputting the text information sample into a preset scaling classification model to determine a first attention weight corresponding to the text information sample;
[0008] The capacity prediction model to be trained is iteratively trained according to the business data samples, the capacity data samples and the first attention weight to obtain a target capacity prediction model.
[0009] Optionally, inputting the text information sample into a preset scaling classification model to determine a first attention weight corresponding to the text information sample includes:
[0010] Inputting the text information sample into a preset scaling classification model to obtain a scaling classification result;
[0011] A first attention weight corresponding to a preset time period is calculated based on the expansion and contraction classification result and preset conditions.
[0012] Optionally, iteratively training the capacity prediction model to be trained according to the business data sample, the capacity data sample and the first attention weight to obtain a target capacity prediction model includes:
[0013] According to a preset networking architecture, the business data sample, the capacity data sample and the text information sample are aggregated to obtain a first data sample;
[0014] Extracting capacity characteristic information that meets a preset capacity condition from the first data sample;
[0015] The capacity prediction model to be trained is iteratively trained using the first data sample, capacity feature information and the first attention weight to obtain a target capacity prediction model.
[0016] Optionally, the iterative training of the capacity prediction model to be trained according to the business data sample, the capacity data sample and the first attention weight to obtain the target capacity prediction model includes:
[0017] Using a preset inverse algorithm, the input first attention weight is added to the second attention weight of the capacity prediction model to be trained to form a third attention weight;
[0018] Based on the business data samples, capacity data samples and the third attention weight, the capacity prediction model to be trained is iteratively trained to obtain a target capacity prediction model.
[0019] Optionally, before iteratively training the capacity prediction model to be trained according to the business data sample, the capacity data sample and the first attention weight to obtain the target capacity prediction model, the method further includes:
[0020] At least one preprocessing operation of data association, data deduplication, data completion, and data normalization is performed on the business data samples and the capacity data samples.
[0021] Optionally, the first data sample includes multiple business time series, a first capacity time series, and a second capacity time series.
[0022] Optionally, the text information sample includes text information of the service plan and time information of service expansion and contraction.
[0023] In a second aspect, an embodiment of the present application provides a method for capacity prediction, the method comprising:
[0024] Obtain the business data and capacity data to be predicted;
[0025] The business data and capacity data are input into the target capacity prediction model trained according to the first aspect and the optional method of the first aspect to obtain a corresponding capacity prediction result.
[0026] In a third aspect, an embodiment of the present application provides a training device for a capacity prediction model, the device comprising:
[0027] An acquisition module, used to acquire business data samples, capacity data samples, and text information samples describing business and capacity;
[0028] A determination module, configured to input the text information sample into a preset scaling classification model to determine a first attention weight corresponding to the text information sample;
[0029] The training module is used to iteratively train the capacity prediction model to be trained according to the business data samples, the capacity data samples and the first attention weight to obtain a target capacity prediction model.
[0030] In a fourth aspect, an embodiment of the present application provides a device for a prediction model, the device comprising:
[0031] An acquisition module, used to acquire business data and capacity data to be predicted;
[0032] A prediction module is used to input the business data and capacity data into the target capacity prediction model trained using the method described in the first aspect and the optional method described in the first aspect to obtain a corresponding capacity prediction result.
[0033] In a fifth aspect, an embodiment of the present application provides a capacity prediction model training device, the device comprising: a processor and a memory storing computer program instructions;
[0034] When the processor executes the computer program instructions, the training method of the capacity prediction model as described in the first aspect and the optional aspect of the first aspect is implemented.
[0035] In a sixth aspect, an embodiment of the present application provides a device for capacity prediction, the device comprising: a processor and a memory storing computer program instructions;
[0036] When the processor executes the computer program instructions, the method for capacity prediction as described in the second aspect is implemented.
[0037] In the seventh aspect, an embodiment of the present application provides a computer storage medium having computer program instructions stored thereon, wherein the computer program instructions, when executed by a processor, implement the training method for the capacity prediction model as described in the first aspect and as an option of the first aspect, and / or the capacity prediction method as described in the second aspect.
[0038] The training method, capacity prediction method, device, equipment and computer storage medium of the capacity prediction model of the embodiment of the present application can combine business data samples, capacity data samples and corresponding text information samples of business and capacity descriptions to train and determine the target capacity prediction model. When training the model, the training samples take into account the text information such as the business and capacity data and the corresponding business capacity plan, and use the preset expansion and contraction classification model to analyze the text information samples, and incorporate the analysis results as attention weights into the trained capacity prediction model to enrich the data samples and weights of the model training. In this way, the accuracy of the capacity prediction model can be improved, thereby optimizing capacity management. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] In order to more clearly illustrate the technical solution of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0040] Figure 1 It is a flowchart of a method for training a capacity prediction model provided by an embodiment of the present application;
[0041] Figure 2 is a flow chart of a method for training a capacity prediction model provided by another embodiment of the present application;
[0042] Figure 3 is a schematic diagram of first attention weights corresponding to multiple time periods provided by an embodiment of the present application;
[0043] Figure 4 is a flow chart of a capacity prediction method provided by an embodiment of the present application;
[0044] Figure 5 It is a structural schematic diagram of a training device for a capacity prediction model provided by an embodiment of the present application;
[0045] Figure 6 It is a structural schematic diagram of a capacity prediction device provided by an embodiment of the present application;
[0046] Figure 7 It is a schematic diagram of the hardware structure of a training device for a capacity prediction model provided by an embodiment of the present application;
[0047] Figure 8 It is a schematic diagram of the hardware structure of a prediction model device provided by an embodiment of the present application. DETAILED DESCRIPTION
[0048] The features and exemplary embodiments of various aspects of the present application will be described in detail below. In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only configured to explain the present application and are not configured to limit the present application. For those skilled in the art, the present application can be implemented without the need for some of these specific details. The following description of the embodiments is only to provide a better understanding of the present application by illustrating the examples of the present application.
[0049] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the statement "include..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0050] At present, the methods of capacity management include passive perception and active management. The passive perception capacity management method is mainly for newly launched systems that have not yet established a capacity management system. It ensures the health of the system by designing specified thresholds for application server hardware resources and storage, and alerting operators to clean up or expand capacity when the threshold is reached. However, capacity management is performed entirely in a passive way through alarms. If the alarm threshold is reached, the operator will clean up or expand the data as needed, but the setting of the threshold depends entirely on the operator's experience. If the threshold is set too low, the risk of frequent system changes and labor costs will increase. It will also be difficult to fully utilize the resources for a long time after the resources are expanded, resulting in a large waste of resources; if the threshold is set too high, it is likely to cause untimely expansion, and in serious cases, business processing failure.
[0051] Active management mainly includes two methods: First, perform performance testing on applications according to business models, and use testing tools and methods to simulate production systems to obtain system capacity. And estimate future capacity based on certain proportions and linear models based on multiple simulation results. Second, for storage-intensive devices, the system capacity trend can be roughly estimated by monitoring the growth rate of historical data and logs.
[0052] However, the method of using performance test results to predict capacity in active management requires the construction of a mirror environment that is one-to-one with the actual production environment, which requires huge investment in manpower, hardware resources, and time. Moreover, it still relies on the experience of business personnel or operation personnel, which is not suitable for the actual production situation and the prediction results are not accurate enough.
[0053] The method of using the storage logs and data growth rates of storage-intensive devices for estimation in active management also has certain limitations: First, the prediction range is small. It only includes storage conditions such as databases and shared storage. However, in actual production, the scope of capacity management also includes the capacity prediction of central processing unit (CPU)-intensive devices, specifically including the use of the host's central processing unit, input / output (I / O), memory, etc.; second, it is not sufficiently related to the business. The storage of the database is not only related to its own growth rate, but also to the actual production business situation. Only analyzing the growth rate of logs and historical data cannot capture the changing relationship between business and capacity; third, capacity prediction is based only on internal factors such as business data and capacity data, ignoring some external market and business policy factors that are strongly related to capacity management. The above limitations may lead to inaccurate capacity prediction results.
[0054] In order to solve the problems of the prior art, the training method, capacity prediction method, device, equipment and computer storage medium of the capacity prediction model provided in the embodiments of the present application can combine business data samples, capacity data samples and corresponding text information samples of business and capacity descriptions to train and determine the target capacity prediction model. When training the model, the training samples take into account the text information such as the business and capacity data and the corresponding business capacity plan, and use the preset expansion and contraction classification model to analyze the text information samples, and incorporate the analysis results as attention weights into the trained capacity prediction model to enrich the data samples and weights of the model training. In this way, the accuracy of the capacity prediction model can be improved, thereby optimizing capacity management.
[0055] The following describes the training method of the capacity prediction model, the capacity prediction method, device, equipment and computer storage medium provided according to the embodiments of the present application in conjunction with the accompanying drawings. It should be noted that these embodiments are not intended to limit the scope of the present application.
[0056] The following first introduces the training method of the capacity prediction model provided in the embodiment of the present application.
[0057] In the embodiments of the present application, Figure 1 As shown, Figure 1 1 is a flow chart of a method for training a capacity prediction model provided by an embodiment of the present application. The method for training a capacity prediction model is specifically implemented as follows:
[0058] S101: Obtain business data samples, capacity data samples, and text information samples describing business and capacity.
[0059] The business data sample may include a variety of business indicators. Business indicators are indicators for evaluating the business development in the target scenario. Exemplarily, business indicators may include the peak value of transaction processing volume per second (TPS) within a preset collection period, the total order volume and call volume within a preset collection period, etc.
[0060] The capacity data sample may include a plurality of hardware resource indicators, which may include at least one of a host resource indicator capacity indicator, a network resource capacity indicator, and a database resource capacity indicator.
[0061] The text information sample includes text information of the business plan and time information of business expansion and contraction. For example, the text information sample may include official documents, emails and meeting minutes of the office automation (OA) system, and text information such as development goals or plans of the business department or marketing department in terms of business development.
[0062] S102: Input the text information sample into a preset scaling classification model to determine a first attention weight corresponding to the text information sample.
[0063] In some embodiments, the preset scaling classification model may include a natural language processing (Natural Language Processing, NLP) model, etc.
[0064] S103: Iteratively train the capacity prediction model to be trained according to the business data samples, the capacity data samples and the first attention weight to obtain a target capacity prediction model.
[0065] In some embodiments, the capacity prediction model may include a recurrent neural network model such as a Long Short-Term Memory (LSTM) model.
[0066] In some embodiments, first, a preset inverse algorithm can be used to add the input first attention weight to the second attention weight of the capacity prediction model to be trained to form a third attention weight. Then, based on the business data sample, the capacity data sample and the third attention weight, the capacity prediction model to be trained is iteratively trained to obtain a target capacity prediction model.
[0067] In summary, in the embodiments of the present application, the method for training the capacity prediction model can combine business data samples, capacity data samples, and corresponding text information samples describing the business and capacity to train and determine the target capacity prediction model. When training the model, the training samples take into account the business and capacity data and the corresponding text information such as the business capacity plan, and use the preset expansion and contraction classification model to analyze the text information samples, and incorporate the analysis results as attention weights into the trained capacity prediction model to enrich the data samples and weights of the model training. In this way, the accuracy of the capacity prediction model can be improved, thereby optimizing capacity management.
[0068] In order to better understand the method of the present application, the training method of the capacity prediction model provided in the embodiment of the present application is introduced in detail below.
[0069] In the embodiments of the present application, Figure 2 As shown, Figure 2 : is a flow chart of a method for training a capacity prediction model provided by another embodiment of the present application. The method for training a capacity prediction model is specifically implemented as follows:
[0070] S201: Obtain business data samples, capacity data samples, and text information samples describing business and capacity.
[0071] The business data samples and capacity data samples may be obtained from the relevant business system. Specifically, the corresponding business data samples and capacity data samples may be obtained according to a preset time period. The business data samples and capacity data samples may be regarded as internal data in the business capacity management system. The business data samples may include multiple business indicators. The capacity data samples may include multiple hardware resource indicators.
[0072] In some embodiments, a collection task may be deployed in each host and application node of the service capacity management system to collect internal data at a certain period. Exemplarily, the collected internal data related information may be shown in the following Table 1:
[0073]
[0074] Table 1
[0075] Among them, among the hardware resource indicators, the host resource indicator capacity indicators include but are not limited to CPU utilization, memory utilization, I / O utilization; network resource capacity indicators include but are not limited to network card bandwidth utilization, host port occupancy, etc.; database resource capacity indicators include but are not limited to table space usage and utilization rate, etc.
[0076] The networking architecture rules can determine the cluster deployment rules and application data flow so that associations can be established between single machines and clusters, and between network elements.
[0077] For the text information sample describing the business and capacity, the text information sample may include official documents, emails, meeting minutes and other text information of the OA system, and development goals or plan text information of the business department or marketing department in terms of business development.
[0078] Optionally, these text information samples are pre-labeled. Exemplarily, the labeled text information samples are shown in Table 2 below:
[0079]
[0080] Table 2
[0081] S202: Input the text information sample into a preset scaling classification model to obtain a scaling classification result.
[0082] In some embodiments, the preset scaling classification model may include an NLP model. Exemplarily, the NLP model may be a BERT model.
[0083] In some embodiments, for text information sample processing, relevant OA files, emails, meeting minutes, provincial business target information, etc. can be appropriately summarized to ensure that the length of each item does not exceed 512 bytes. Based on historical records, the real and clear time points of expansion or reduction are also recorded and classified and labeled.
[0084] In some embodiments, first, the NLP model can be pre-trained and determined. Based on text information samples such as OA documents, emails, meeting minutes, and provincial business goals, the size of a sentence in the text information does not exceed 512 bytes, and the NLP model is trained and fine-tuned in the form of sentence 1 + sentence 2 as input.
[0085] Then, the trained NLP model is used for prediction and recognition. The text information such as OA files, emails, or meeting minutes to be predicted is input into the trained NLP model to predict the classification results. The prediction results can include expansion, unchanged, and reduction.
[0086] S203: Calculate a first attention weight corresponding to a preset time period according to the expansion and contraction classification result and preset conditions.
[0087] In some embodiments, the first attention weight of the future time step is calculated according to the expansion and contraction classification results and preset conditions. Exemplarily, for the expansion and contraction classification results of the NLP model, the expansion and contraction classification results are reversely mapped to the various time moments of the multi-layer LSTM model according to the historically accurate expansion time. For example, the expansion was implemented on March 27, and the result of the NLP expansion and contraction classification prediction was expansion. The preset time period can be the time interval t=7 from the planned time to the actual implementation of the expansion. Then, during this time period, the first attention weight increases linearly to a certain extent and then decreases linearly. The eigenvalue of the text information sample can be initialized to 0.00001 first. The first attention weights corresponding to multiple time periods are shown in Table 3 below:
[0088]
[0089] Table 3
[0090] Here, if Figure 3 As shown, Figure 3 This is a schematic diagram of the first attention weights corresponding to multiple time periods provided by an embodiment of the present application. Using the first attention weights, some periodic or human-induced data can be effectively excluded. For example, interference factors such as expansion and contraction caused by human adjustment or online upgrade, scheduled tasks, or changes in internal data caused by human deletion of database tables.
[0091] It is understandable that other existing technical means may also be used to determine the first attention weight corresponding to the preset time period, for example, key time points in the text information may be directly screened to determine the weight. No specific limitation is made here.
[0092] S204: Preprocessing the business data samples and capacity data samples.
[0093] Perform at least one preprocessing operation of data association, data deduplication, data completion, and data normalization on the business data samples and the capacity data samples.
[0094] In some embodiments, the time periods of business data samples and capacity data samples can be kept consistent through data association processing. It is understandable that in actual production, the collection periods of various businesses, hardware resource indicators, etc. are not the same. Therefore, business data samples and capacity data samples need to be aggregated according to a unified time period. For example, if the collection period of business data samples, that is, the business indicator, is the maximum TPS within 1 hour, the corresponding CPU usage rate also needs to be aggregated as the maximum CPU usage rate within this 1 hour.
[0095] In some embodiments, when performing data deduplication on business data samples and capacity data samples, linear interpolation can be used to fill missing values. Linear interpolation fills in unknown quantities by establishing a linear function connecting two known quantities before and after the unknown quantity. Compared with other interpolation methods, it is simpler and more intuitive.
[0096] In some embodiments, when performing noise data processing on business data samples and capacity data samples, a box plot can be used to depict the discreteness of the data and quickly identify data outside the upper and lower quartiles. Thus, the relevant data is analyzed to see if it is abnormal, and it is decided whether to repair, retain or discard it. Illegal characters, duplicates, meaningless characters, etc. can be removed based on the analysis results.
[0097] In some embodiments, when performing data normalization on business data samples and capacity data samples, the data can be mapped within the range of [0,1] to convert dimensional data into dimensionless data, so as to improve the convergence speed and accuracy of the capacity prediction model.
[0098] S205: According to a preset networking architecture, aggregate the business data sample, the capacity data sample and the text information sample to obtain a first data sample.
[0099] In some embodiments, the acquired internal data also includes a preset networking architecture, which can determine cluster deployment rules and application data flow, so that a relationship can be established between a single machine and a cluster, and between network elements. The business data sample includes business indicators, and the capacity data sample includes hardware resource indicators.
[0100] For example, business indicators and hardware resource indicators are often collected according to the host nodes in the cluster, but the data flow between different network elements is not a single-to-single connection, but a cluster-to-cluster connection. Therefore, hardware resource indicators and business indicators need to be aggregated and calculated according to the networking architecture, and transformed from single-machine capacity business indicators to cluster capacity business indicators. The combination method varies depending on the cluster load method. Here, a balanced load method can be used.
[0101] For ratio indicators, such as CPU utilization and I / O utilization, they can be calculated using the following formula (1):
[0102] Cluster performance index = ∑ single machine performance index ÷ number of machines (1)
[0103] For order-related business indicators, they can be calculated using the following formula (2):
[0104] Cluster order index = (batch business volume × user volume + real-time business volume) ÷ time period (2)
[0105] For the call bill service indicators, they can be calculated using the following formula (3):
[0106] Cluster call bill index = ∑ single machine call bill index (3)
[0107] The database resource capacity index, i.e., the storage-intensive index, can be calculated using the following formula (4):
[0108] Cluster capacity index = single machine capacity × number of machines (4)
[0109] For text information sample processing, relevant OA documents, emails, meeting minutes, provincial business target information, etc. can be appropriately summarized to ensure that the length of each item does not exceed 512 bytes. Based on historical records, the real and clear time points of expansion or reduction are also recorded and classified and labeled.
[0110] Through the above processing, the business data sample, the capacity data sample and the text information sample can be aggregated to obtain a first data sample.
[0111] S206: Extracting capacity feature information that meets a preset capacity condition from the first data sample.
[0112] Here, since different clusters have different bottlenecks when using capacity, it is necessary to extract the corresponding capacity feature information according to the characteristics of the cluster. For example, for a CPU-intensive cluster, the capacity data will tend to focus on whether the CPU usage rate becomes a bottleneck first, and the capacity feature information related to the CPU usage rate can be extracted; for a storage-type cluster, the first bottleneck in the capacity is the table space usage or I / O usage rate, and the capacity feature information of the table space usage or I / O usage rate is extracted accordingly.
[0113] S207: Using the first data sample, the capacity feature information and the first attention weight, iteratively train the capacity prediction model to be trained to obtain a target capacity prediction model.
[0114] In some embodiments, the first data sample may include a plurality of business time series, a first capacity time series, and a second capacity time series.
[0115] In some embodiments, the service time series, the first capacity time series, and the second capacity time series can construct data samples of three capacity prediction scenarios. The three scenarios can include network element capacity prediction scenario, service capacity strong correlation prediction scenario, and service multi-network element strong correlation prediction scenario.
[0116] For example, in the network element capacity prediction scenario, based on the historical N time periods, the data of the future M periods are predicted. N and M are both positive integers. The first capacity time series CT = [c1, c2, c3, c4, c5, c6, c7], N = 3, M = 1, as shown in Table 4 below:
[0117]
[0118] Table 4
[0119] In the scenario of strong correlation prediction of business capacity, based on the historical N time periods, the data of the future M periods are predicted. N and M are both positive integers. The business time series BT = [b1, b2, b3, b4, b5, b6, b7], the first capacity time series CT = [c1, c2, c3, c4, c5, c6, c7], N = 3, M = 1, as shown in Table 5 below:
[0120]
[0121] Table 5
[0122] In the scenario of strong correlation prediction of multiple network elements of services, the data of the next M periods are predicted based on the historical N time periods. N and M are both positive integers.
[0123] The business time series BT = [b1, b2, b3, b4, b5, b6, b7], the first capacity time series CT = [c1, c2, c3, c4, c5, c6, c7], the second capacity time series DT = [d1, d2, d3, d4, d5, d6, d7], N = 3, M = 1, as shown in Table 6 below:
[0124]
[0125] Table 6
[0126] Here, the first capacity time series may be a preceding application capacity time series, and the second capacity time series may be an application capacity time series.
[0127] In some embodiments, the capacity prediction model may be a multi-layer LSTM model.
[0128] Exemplarily, the network setting of the multi-layer LSTM model specifically includes:
[0129] LSTM layer: The main training layer, each layer has multiple LSTM units. In different scenarios, the constructed input data samples need to be reshaped according to the following format through the reshape function. The input data format is [batchs, time_steps, input_dim], where batches indicates the number of samples; time_steps indicates the number of input moments; input_dim indicates the dimension of the input vector at each moment. For example, in the network element capacity prediction scenario, the input is [batchs, 3, 1].
[0130] Random inactivation DropOut layer: DropOut is applied to the middle of multiple hidden layers, and masks of different lengths are used to randomly discard the neurons of the trained model, so that LSTM can benefit from regularization while maintaining its memory capacity. It organizes the "co-adaptation" of incorrectly updating parameters to achieve global optimality by assuming that other hidden units are unreliable. The general parameter is a drop rate of 0.2 or 0.5.
[0131] Fully connected Dense layer: The Dense layer can be regarded as a "firewall" for the model's representation capabilities. Especially when there is a large difference between the source domain and the target domain, it can maintain a large model capacity, thereby ensuring the migration of capabilities.
[0132] The loss function can be the mean squared error (MSE), which is calculated by the following formula (5):
[0133]
[0134] The optimization function can be Adam, which can calculate the adaptive learning rate of each parameter, which not only maintains the exponential decay mean of the past loss function gradient, but also performs deviation verification on the gradient through momentum. Optionally, different neuron layers can be combined and superimposed as needed.
[0135] Optionally, during model training, epochs is the number of iterations of the entire training set, and the number of training times reaches 5,000-10,000, generating a capacity prediction model, and the MSE of the model on the validation set is 35.849656. Compared with other network models, the multi-layer LSTM model can achieve better results.
[0136] It is understandable that in actual use, when the capacity prediction model determined by the above steps is trained, i.e., the target capacity prediction model, and actual prediction is performed, historical data will increase over time, and these newly added historical data can be put into the model to update and train the model to reduce the prediction error. The specific implementation method is the same as the above steps and will not be repeated here.
[0137] In some embodiments, first, a preset inverse algorithm can be used to add the input first attention weight to the second attention weight of the capacity prediction model to be trained to obtain a third attention weight.
[0138] Exemplarily, the first attention weight can be used as input data of a multi-layer LSTM model and input into a feature column of the second attention weight of the LSTM model to form a third attention weight.
[0139] Then, based on the first data sample, the capacity feature information and the third attention weight, the capacity prediction model to be trained is iteratively trained to obtain a target capacity prediction model.
[0140] In summary, the training method of the capacity prediction model in the embodiment of the present application can combine business data samples, capacity data samples and corresponding text information samples of business and capacity descriptions to train and determine the target capacity prediction model. When training the model, the training samples take into account the text information such as the business and capacity data and the corresponding business capacity plan, and use the preset expansion and contraction classification model to analyze the text information samples, and incorporate the analysis results as attention weights into the trained capacity prediction model to enrich the data samples and weights of the model training. In this way, the accuracy of the capacity prediction model can be improved, thereby optimizing capacity management.
[0141] The capacity prediction method provided in the embodiment of the present application is described in detail below.
[0142] Figure 4 FIG. 1 is a flow chart of a method for capacity prediction provided by an embodiment of the present application. Figure 4 As shown, in an embodiment of the present application, the capacity prediction method may include the following steps:
[0143] S401: Acquire business data and capacity data to be predicted.
[0144] In some embodiments, the service data and capacity data may include at least one of own network element capacity data, service capacity strongly correlated data, and service multi-network element strongly correlated data.
[0145] S402: Inputting the business data and capacity data into the capacity prediction model to obtain corresponding capacity prediction results.
[0146] Here, the capacity prediction model may be a target capacity prediction model trained by the capacity prediction model training method in the above embodiment. Whether the service capacity needs to be expanded or reduced is predicted based on the target capacity prediction model.
[0147] In some embodiments, the target capacity prediction model can support capacity prediction including self-network element capacity prediction scenarios, service capacity strong correlation prediction scenarios and service multi-network element strong correlation prediction scenarios. That is, the self-network element capacity data, service capacity strong correlation data, and / or service multi-network element strong correlation data can be input into the target capacity prediction model, and the corresponding service capacity needs to be expanded or reduced. The prediction identification results are output respectively.
[0148] In summary, the capacity prediction method of the embodiment of the present application can use the target capacity prediction model to predict whether the business capacity needs to be expanded or reduced, which can improve the accuracy of capacity prediction identification, thereby optimizing capacity management, reducing time, manpower, and resource costs, and reducing costs and increasing efficiency.
[0149] Based on the training method of the capacity prediction model provided in the above embodiment, the present application also provides a specific implementation of the training device of the capacity prediction model. Please refer to the following embodiment.
[0150] In one embodiment of the present application, Figure 5 As shown, Figure 5 : is a schematic diagram of the structure of a training device for a capacity prediction model provided by another embodiment of the present application, wherein the training device for a capacity prediction model specifically comprises:
[0151] An acquisition module 501 is used to acquire service data samples, capacity data samples, and text information samples describing services and capacities;
[0152] A determination module 502, configured to input the text information sample into a preset scaling classification model to determine a first attention weight corresponding to the text information sample;
[0153] The training module 503 is used to iteratively train the capacity prediction model to be trained according to the business data samples, the capacity data samples and the first attention weight to obtain a target capacity prediction model.
[0154] In summary, in the embodiments of the present application, the training device of the capacity prediction model can execute the method of training the capacity prediction model in the above embodiments, and can combine the business data samples, capacity data samples and the corresponding text information samples of the business and capacity descriptions to train and determine the target capacity prediction model. When training the model, the training samples take into account the text information such as the business and capacity data and the corresponding business capacity plan, and use the preset expansion and contraction classification model to analyze the text information samples, and incorporate the analysis results as attention weights into the trained capacity prediction model, enriching the data samples and weights of the model training. In this way, the accuracy of the capacity prediction model can be improved, thereby optimizing capacity management.
[0155] Understandably, Figure 5Each module / unit in the training device of the pet health model shown has the function of realizing Figure 1 , Figure 2 The functions of each step in the process can achieve the corresponding technical effects, which will not be described in detail here for the sake of brevity.
[0156] Based on the capacity prediction method provided in the above embodiment, the present application also provides a specific implementation of the capacity prediction device. Please refer to the following embodiment.
[0157] In one embodiment of the present application, Figure 6 As shown, Figure 6 : is a schematic diagram of the structure of a capacity prediction device provided by another embodiment of the present application, and the capacity prediction device specifically includes:
[0158] An acquisition module 601 is used to acquire the business data and capacity data to be predicted;
[0159] The prediction module 602 is used to input the business data and capacity data into the target capacity prediction model trained by the method described in the above embodiment to obtain the corresponding capacity prediction result.
[0160] In summary, the capacity prediction device of the embodiment of the present application can execute the capacity prediction method in the above embodiment, and can use the target capacity prediction model to predict whether the business capacity needs to be expanded or reduced, thereby improving the accuracy of capacity prediction identification, thereby optimizing capacity management, reducing time, manpower, and resource costs, and reducing costs and increasing efficiency.
[0161] Based on the capacity prediction model training method and capacity prediction method provided in the above embodiments, the present application also provides a specific hardware structure description of the capacity prediction model training device and the capacity prediction device. Please refer to the following embodiments.
[0162] Figure 7 It is a schematic diagram of the hardware structure of the training device of the capacity prediction model provided in the embodiment of the present application.
[0163] The training device for the capacity prediction model may include a processor 701 and a memory 702 storing computer program instructions.
[0164] Specifically, the processor 701 may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of the embodiments of the present application.
[0165] The memory 702 may include a large capacity memory for data or instructions. By way of example and not limitation, the memory 702 may include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive or a combination of two or more of these. In appropriate cases, the memory 702 may include a removable or non-removable (or fixed) medium. In appropriate cases, the memory 702 may be inside or outside the integrated gateway disaster recovery device. In a specific embodiment, the memory 702 is a non-volatile solid-state memory. In a specific embodiment, the memory 702 includes a read-only memory (ROM). In appropriate cases, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically rewritable ROM (EAROM) or a flash memory or a combination of two or more of these.
[0166] The processor 701 implements any one of the capacity prediction model training methods in the above embodiments by reading and executing computer program instructions stored in the memory 702 .
[0167] In one example, the training device for the capacity prediction model may further include a communication interface 703 and a bus 710. Figure 7 As shown, the processor 701, the memory 702, and the communication interface 703 are connected via a bus 710 and communicate with each other.
[0168] The communication interface 703 is mainly used to implement communication between various modules, devices, units and / or equipment in the embodiments of the present application.
[0169] Bus 710 includes hardware, software or both, and the parts of the training equipment of the capacity prediction model are coupled to each other. For example, but not limitation, the bus may include accelerated graphics port (AGP) or other graphics bus, enhanced industrial standard architecture (EISA) bus, front-side bus (FSB), hypertransport (HT) interconnection, industrial standard architecture (ISA) bus, infinite bandwidth interconnection, low pin count (LPC) bus, memory bus, micro channel architecture (MCA) bus, peripheral component interconnection (PCI) bus, PCI-Express (PCI-X) bus, serial advanced technology attachment (SATA) bus, video electronics standard association local (VLB) bus or other suitable bus or two or more of these combinations. In appropriate cases, bus 710 may include one or more buses. Although the present application embodiment describes and shows a specific bus, the present application considers any suitable bus or interconnection.
[0170] The training device of the capacity prediction model can execute the training method of the capacity prediction model in the embodiment of the present application, thereby realizing the combination of Figure 1 and Figure 2 Describe the training method of the capacity prediction model.
[0171] Figure 8 It is a schematic diagram of the hardware structure of the prediction model device provided in the embodiment of the present application.
[0172] The device for capacity prediction may include a processor 801 and a memory 802 storing computer program instructions.
[0173] Specifically, the processor 801 may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of the embodiments of the present application.
[0174] The memory 802 may include a large capacity memory for data or instructions. By way of example and not limitation, the memory 802 may include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive or a combination of two or more of these. In appropriate cases, the memory 802 may include a removable or non-removable (or fixed) medium. In appropriate cases, the memory 802 may be inside or outside the integrated gateway disaster recovery device. In a specific embodiment, the memory 802 is a non-volatile solid-state memory. In a specific embodiment, the memory 802 includes a read-only memory (ROM). In appropriate cases, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically rewritable ROM (EAROM) or a flash memory or a combination of two or more of these.
[0175] The processor 801 implements any one of the capacity prediction methods in the above embodiments by reading and executing computer program instructions stored in the memory 802 .
[0176] In one example, the device for capacity prediction may further include a communication interface 803 and a bus 810. Figure 8 As shown, the processor 801, the memory 802, and the communication interface 803 are connected via a bus 810 and communicate with each other.
[0177] The communication interface 803 is mainly used to implement communication between various modules, devices, units and / or equipment in the embodiments of the present application.
[0178] Bus 810 includes hardware, software or both, and the parts of the equipment of capacity prediction are coupled to each other. For example, but not limitation, bus may include accelerated graphics port (AGP) or other graphics bus, enhanced industrial standard architecture (EISA) bus, front side bus (FSB), hypertransport (HT) interconnection, industrial standard architecture (ISA) bus, infinite bandwidth interconnection, low pin count (LPC) bus, memory bus, micro channel architecture (MCA) bus, peripheral component interconnection (PCI) bus, PCI-Express (PCI-X) bus, serial advanced technology attachment (SATA) bus, video electronics standard association local (VLB) bus or other suitable bus or two or more of these combinations. In appropriate cases, bus 810 may include one or more buses. Although the present application embodiment describes and shows a specific bus, the present application considers any suitable bus or interconnection.
[0179] The capacity prediction device can execute the capacity prediction method in the embodiment of the present application, thereby realizing the combination Figure 4 Describe the method of capacity forecasting.
[0180] In addition, in combination with the training method for capacity prediction in the above embodiments, the embodiments of the present application may provide a computer storage medium for implementation. The computer storage medium stores computer program instructions; when the computer program instructions are executed by a processor, any one of the training methods for capacity prediction models in the above embodiments is implemented.
[0181] In addition, in combination with the capacity prediction method in the above embodiment, the embodiment of the present application can provide a computer storage medium for implementation. The computer storage medium stores computer program instructions; when the computer program instructions are executed by a processor, any one of the capacity prediction methods in the above embodiment is implemented.
[0182] It should be clear that the present application is not limited to the specific configuration and processing described above and shown in the figures. For the sake of simplicity, a detailed description of the known method is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present application is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between the steps after understanding the spirit of the present application.
[0183] The functional blocks shown in the above-described block diagram can be implemented as hardware, software, firmware or a combination thereof. When implemented in hardware, it can be, for example, an electronic circuit, an application specific integrated circuit (ASIC), appropriate firmware, a plug-in, a function card, etc. When implemented in software, the elements of the present application are programs or code segments that are used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link by a data signal carried in a carrier wave. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, optical fiber media, radio frequency (RF) links, etc. The code segment can be downloaded via a computer network such as the Internet, an intranet, etc.
[0184] It should also be noted that the exemplary embodiments mentioned in this application describe some methods or systems based on a series of steps or devices. However, this application is not limited to the order of the above steps, that is, the steps can be performed in the order mentioned in the embodiment, or in a different order from the embodiment, or several steps can be performed simultaneously.
[0185] Aspects of the present disclosure are described above with reference to the flowchart and / or block diagram of the method, device (system) and computer program product according to the embodiment of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device to produce a machine so that these instructions executed by the processor of the computer or other programmable data processing device enable the implementation of the function / action specified in one or more boxes of the flowchart and / or block diagram. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor, or a field programmable logic circuit. It can also be understood that each box in the block diagram and / or flowchart and the combination of boxes in the block diagram and / or flowchart can also be implemented by dedicated hardware that performs a specified function or action, or can be implemented by a combination of dedicated hardware and computer instructions.
[0186] The above is only a specific implementation of the present application. Those skilled in the art can clearly understand that for the convenience and simplicity of description, the specific working processes of the systems, modules and units described above can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here. It should be understood that the protection scope of the present application is not limited to this. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed in this application, and these modifications or replacements should be included in the protection scope of this application.
Claims
1. A method for training a capacity prediction model, characterized in that: include: Obtain business data samples, capacity data samples, and text information samples describing business and capacity; Inputting the text information sample into a preset scaling classification model to determine a first attention weight corresponding to the text information sample; Iteratively training the capacity prediction model to be trained according to the business data sample, the capacity data sample and the first attention weight to obtain a target capacity prediction model; The step of inputting the text information sample into a preset scaling classification model to determine a first attention weight corresponding to the text information sample includes: Inputting the text information sample into a preset scaling classification model to obtain a scaling classification result; A first attention weight corresponding to a preset time period is calculated based on the expansion and contraction classification result and preset conditions.
2. The method according to claim 1, characterized in that According to the business data sample, the capacity data sample and the first attention weight, the capacity prediction model to be trained is iteratively trained to obtain a target capacity prediction model, including: According to a preset networking architecture, the business data sample, the capacity data sample and the text information sample are aggregated to obtain a first data sample; Extracting capacity characteristic information that meets a preset capacity condition from the first data sample; The capacity prediction model to be trained is iteratively trained using the first data sample, capacity feature information and the first attention weight to obtain a target capacity prediction model.
3. The method according to claim 1, characterized in that The method of iteratively training the capacity prediction model to be trained according to the business data sample, the capacity data sample and the first attention weight to obtain the target capacity prediction model includes: Using a preset inverse algorithm, the input first attention weight is added to the second attention weight of the capacity prediction model to be trained to form a third attention weight; Based on the business data samples, capacity data samples and the third attention weight, the capacity prediction model to be trained is iteratively trained to obtain a target capacity prediction model.
4. The method according to any one of claim 1, characterized in that: Before the iterative training of the capacity prediction model to be trained according to the business data sample, the capacity data sample and the first attention weight to obtain the target capacity prediction model, the method further includes: At least one preprocessing operation of data association, data deduplication, data completion, and data normalization is performed on the business data samples and the capacity data samples.
5. The method according to claim 2, characterized in that: The first data sample includes a plurality of business time series, a first capacity time series, and a second capacity time series.
6. The method according to claim 1, characterized in that The text information sample includes text information of the business plan and time information of business expansion and contraction.
7. A capacity prediction method, characterized in that: The method comprises: Obtain the business data and capacity data to be predicted; The business data and capacity data are input into the target capacity prediction model trained by the method according to any one of claims 1 to 6 to obtain a corresponding capacity prediction result.
8. A training device for a capacity prediction model, characterized in that: The device comprises: An acquisition module, used to acquire business data samples, capacity data samples, and text information samples describing business and capacity; A determination module, configured to input the text information sample into a preset scaling classification model to determine a first attention weight corresponding to the text information sample; A training module, used for iteratively training the capacity prediction model to be trained according to the business data sample, the capacity data sample and the first attention weight, to obtain a target capacity prediction model; The determination module is further used to input the text information sample into a preset scaling classification model to obtain a scaling classification result; and calculate a first attention weight corresponding to a preset time period based on the scaling classification result and preset conditions.
9. A device for capacity prediction, characterized in that: The device comprises: An acquisition module, used to acquire business data and capacity data to be predicted; A prediction module is used to input the business data and capacity data into the target capacity prediction model trained by the method according to any one of claims 1 to 6 to obtain a corresponding capacity prediction result.
10. A training device for a capacity prediction model, characterized in that: The device comprises: a processor and a memory storing computer program instructions; When the processor executes the computer program instructions, the training method of the capacity prediction model according to any one of claims 1 to 6 is implemented.
11. A device for capacity prediction, characterized in that: The device comprises: a processor and a memory storing computer program instructions; When the processor executes the computer program instructions, the method for capacity prediction according to claim 7 is implemented.
12. A computer storage medium, characterized in that: The computer storage medium stores computer program instructions, which, when executed by a processor, implement the capacity prediction model training method according to any one of claims 1 to 6, and / or the capacity prediction method according to claim 7.
Citation Information
Patent Citations
Capacity resource prediction method and device
CN110445939A
Network element load balancing method and network equipment
CN111082954A
Traffic–based capacity expansion method and apparatus
WO2018000684A1