Granularity prediction model training method and resource occupation prediction method and device

By collecting and analyzing resource usage data from node devices and using a prediction model to automatically select the optimal time granularity, the problem of low efficiency in existing technologies is solved, and efficient and accurate resource usage prediction is achieved.

CN116861980BActive Publication Date: 2025-11-18CHINA TELECOM CORP LTD TECHNOLOGY INNOVATION CENTER +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310842618.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-07-10
Publication Date
2025-11-18
Estimated Expiration
2043-07-10

AI Technical Summary

Technical Problem

The current technology for determining time granularity is inefficient, requires a lot of expertise and has high labor costs, resulting in poor accuracy and efficiency in resource utilization prediction.

Method used

By collecting sample resource usage data from node devices, sampling is performed according to multiple candidate time granularities. The target resource usage prediction data is determined using a resource usage prediction model, and the neural network parameters of the model to be trained are updated to obtain a granular prediction model.

Benefits of technology

The optimal time granularity can be selected without requiring extensive professional knowledge, reducing labor costs, improving the efficiency of determining the time granularity, ensuring the accuracy of prediction results, and preserving information on local and long-term changes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116861980B_ABST
    Figure CN116861980B_ABST
Patent Text Reader

Abstract

The present disclosure relates to the technical field of computer, in particular to a granularity prediction model training method, a resource occupation prediction method, a granularity prediction model training device, a resource occupation prediction device, a storage medium and equipment. The above method comprises: obtaining a sample resource occupation time sequence; sampling the sample resource occupation time sequence to obtain a plurality of sets of sample resource occupation time sequence data; inputting the plurality of sets of sample resource occupation time sequence data into a resource occupation prediction model to obtain resource occupation prediction data corresponding to the plurality of sets of sample resource occupation time sequence data; taking a candidate time granularity corresponding to the target resource occupation prediction data as a target time granularity; inputting the sample resource occupation time sequence into a to-be-trained model to obtain a predicted granularity; and updating neural network parameters of the to-be-trained model through the predicted granularity and the target time granularity. Through the technical scheme of the embodiment of the present disclosure, the problem of poor efficiency in determining the time granularity in the related art can be solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of computer technology, and more specifically, to a granular prediction model training method, a resource occupancy prediction method, a granular prediction model training device, a resource occupancy prediction device, a computer-readable storage medium, and an electronic device. Background Technology

[0002] With the rapid development of software and hardware, network clusters are becoming increasingly larger. In some scenarios, it is necessary to accurately predict the resource usage of nodes in the network cluster in order to make advance resource allocation, improve network resource utilization, and ensure the normal operation of services.

[0003] In related technologies, a time granularity can be determined, and resource usage data can be sampled using this granularity to predict future resource usage. The choice of time granularity is crucial; too large a granularity leads to the loss of local changes, while too small a granularity results in the loss of long-term changes. Both situations result in poor accuracy and low efficiency in the predicted resource usage.

[0004] Currently, time granularity is typically determined manually. This method requires extensive expertise and validation of multiple candidate time granularities to determine the optimal one. Determining time granularity manually is costly and inefficient.

[0005] It should be noted that the information disclosed in the background section above is only used to enhance the understanding of the background of this disclosure, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention

[0006] The purpose of this disclosure is to provide a granular prediction model training method, a resource occupancy prediction method, a granular prediction model training device, a resource occupancy prediction device, a computer-readable storage medium, and an electronic device, which can solve the problem of poor efficiency in determining time granularity in related technologies.

[0007] Other features and advantages of this disclosure will become apparent from the following detailed description, or may be learned in part from practice of this disclosure.

[0008] According to a first aspect of this disclosure, a method for training a granular prediction model is provided, comprising: collecting sample resource occupancy data of node devices to obtain a sample resource occupancy time series; sampling the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data; inputting the multiple sets of sample resource occupancy time series data into a resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data; determining target resource occupancy prediction data from the multiple sets of resource occupancy prediction data, and using the candidate time granularity corresponding to the target resource occupancy prediction data as the target time granularity; inputting the sample resource occupancy time series into the model to be trained to obtain the prediction granularity; and updating the neural network parameters of the model to be trained by using the prediction granularity and the target time granularity to obtain a granular prediction model.

[0009] In one exemplary embodiment of this disclosure, based on the aforementioned scheme, obtaining a sample resource occupancy time series by collecting sample resource occupancy data of node devices includes: collecting sample resource occupancy data of node devices at a preset frequency to obtain a sample resource occupancy time series.

[0010] In one exemplary embodiment of this disclosure, based on the aforementioned scheme, determining the target resource usage prediction data from multiple sets of resource usage prediction data includes: obtaining the actual resource usage data of the node device; comparing the multiple sets of resource usage prediction data with the actual resource usage data to obtain the matching degree between each set of resource usage prediction data and the actual resource usage data; and determining the resource usage prediction data with the highest matching degree as the target resource usage prediction data.

[0011] In an exemplary embodiment of this disclosure, based on the aforementioned scheme, inputting the sample resource occupancy time series into the model to be trained to obtain the prediction granularity includes: calculating the time-domain features corresponding to the sample resource occupancy time series; calculating the frequency-domain features corresponding to the sample resource occupancy time series based on the time-domain features; and inputting the time-domain features and the frequency-domain features corresponding to the sample resource occupancy time series into the model to be trained to obtain the prediction granularity.

[0012] In one exemplary embodiment of this disclosure, multiple candidate time granularities are determined according to an exponential interval based on the aforementioned scheme.

[0013] According to a second aspect of this disclosure, a resource occupancy prediction method is provided, comprising: collecting resource occupancy data of node devices at a preset frequency to obtain a resource occupancy time series; inputting the resource occupancy time series into a granularity prediction model to obtain an optimal time granularity; wherein the granularity prediction model is trained using a granularity prediction model training method as described above; sampling the resource occupancy time series according to a target time granularity to obtain resource occupancy time series data; and inputting the resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data of node devices.

[0014] According to a third aspect of this disclosure, a granular prediction model training device is provided, comprising: a time series acquisition module for acquiring sample resource occupancy data of node devices to obtain a sample resource occupancy time series; a time series data acquisition module for sampling the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data; an occupancy data prediction module for inputting the multiple sets of sample resource occupancy time series data into a resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data; a granularity determination module for determining target resource occupancy prediction data from the multiple sets of resource occupancy prediction data, and using the candidate time granularity corresponding to the target resource occupancy prediction data as the target time granularity; and a model training module for inputting the sample resource occupancy time series into the model to be trained to obtain the prediction granularity, and updating the neural network parameters of the model to be trained by using the prediction granularity and the target time granularity to obtain a granular prediction model.

[0015] According to a fourth aspect of this disclosure, a resource occupancy prediction device is provided, comprising: an occupancy data acquisition module, configured to acquire resource occupancy data of node devices at a preset frequency to obtain a resource occupancy time series; an optimal time granularity prediction module, configured to input the resource occupancy time series into a granularity prediction model to obtain an optimal time granularity; wherein the granularity prediction model is trained using a granularity prediction model training method as described above; an optimal time granularity sampling module, configured to sample the resource occupancy time series according to a target time granularity to obtain resource occupancy time series data; and a resource occupancy prediction module, configured to input the resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data of node devices.

[0016] According to a fifth aspect of this disclosure, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the granular prediction model training method of the first aspect or the resource occupancy prediction method of the second aspect as described in the above embodiments.

[0017] According to a sixth aspect of this disclosure, an electronic device is provided, comprising:

[0018] One or more processors; and

[0019] A storage device for storing one or more programs, which, when executed by one or more processors, cause the one or more processors to implement the granular prediction model training method of the first aspect or the resource occupancy prediction method of the second aspect as described in the above embodiments.

[0020] The technical solutions provided in this disclosure may have the following beneficial effects:

[0021] In one embodiment of this disclosure, a granular prediction model training method is provided. Sample resource occupancy data from node devices is collected to obtain a sample resource occupancy time series. This time series is then sampled according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data. These multiple sets of sample resource occupancy time series data are input into a resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data. A target resource occupancy prediction data is determined from these multiple sets of prediction data. The candidate time granularity corresponding to the target resource occupancy prediction data is used as the target time granularity. The sample resource occupancy time series is then input into the model to be trained to obtain the prediction granularity. The neural network parameters of the model to be trained are updated using the prediction granularity and the target time granularity to obtain the granular prediction model. On the one hand, the optimal time granularity can be selected without requiring extensive professional knowledge, reducing labor costs. Furthermore, the optimal time granularity can be obtained without multiple verifications, resulting in high efficiency and good reusability in determining the time granularity. On the other hand, because a suitable time granularity is determined, local and long-term change information can be fully preserved when predicting resource occupancy, leading to higher accuracy in the predicted resource occupancy.

[0022] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description

[0023] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure. It is obvious that the drawings described below are merely some embodiments of this disclosure, and those skilled in the art can obtain other drawings based on these drawings without any inventive effort. In the drawings:

[0024] Figure 1 The illustration shows a schematic diagram of an exemplary system architecture for a granular prediction model training method in an exemplary embodiment of the present disclosure;

[0025] Figure 2A flowchart illustrating a granular prediction model training method in an exemplary embodiment of this disclosure is shown schematically.

[0026] Figure 3 This schematically illustrates a flowchart in an exemplary embodiment of the present disclosure, in which the resource usage prediction data with the highest degree of matching is determined as the target resource usage prediction data;

[0027] Figure 4 This schematically illustrates a flowchart in an exemplary embodiment of the present disclosure, in which the time-domain features corresponding to the sample resource occupancy time series and the frequency-domain features corresponding to the sample resource occupancy time series are input into the model to be trained to obtain the prediction granularity.

[0028] Figure 5 A flowchart illustrating a resource occupancy prediction method in an exemplary embodiment of this disclosure is shown schematically.

[0029] Figure 6 A flowchart illustrating another resource occupancy prediction method in an exemplary embodiment of this disclosure is shown schematically.

[0030] Figure 7 This schematic diagram illustrates a resource usage prediction system according to an exemplary embodiment of the present disclosure;

[0031] Figure 8 This schematic diagram illustrates the composition of a granular prediction model training apparatus in an exemplary embodiment of the present disclosure.

[0032] Figure 9 This schematic diagram illustrates the composition of a resource occupancy prediction device according to an exemplary embodiment of the present disclosure;

[0033] Figure 10 The schematic diagram illustrates a structural schematic of a computer system suitable for implementing an electronic device according to exemplary embodiments of the present disclosure. Detailed Implementation

[0034] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, these exemplary embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, they are provided so that this disclosure will be more comprehensive and complete, and will fully convey the concept of the exemplary embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. Furthermore, the described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of embodiments of this disclosure. However, those skilled in the art will recognize that the technical solutions of this disclosure can be practiced without one or more of the specific details, or other methods, components, apparatuses, steps, etc., may be employed. In other instances, well-known structures, methods, apparatuses, implementations, materials, or operations are not shown or described in detail to avoid obscuring various aspects of this disclosure.

[0035] The block diagrams shown in the accompanying drawings are merely functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities can be implemented in software, or in one or more software-hardened modules, or in different network and / or processor devices and / or microcontroller devices.

[0036] Figure 1 A schematic diagram of an exemplary system architecture for which the granular prediction model training method of embodiments of the present disclosure can be applied is shown.

[0037] like Figure 1 As shown, system architecture 1000 may include one or more of terminal devices 1001, 1002, and 1003, network 1004, and server 1005. Network 1004 is used as a medium to provide a communication link between terminal devices 1001, 1002, and 1003 and server 1005. Network 1004 may include various connection types, such as wired or wireless communication links or fiber optic cables, etc.

[0038] It should be understood that Figure 1 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included. For example, server 1005 could be a server cluster composed of multiple servers.

[0039] Users can use terminal devices 1001, 1002, and 1003 to interact with server 1005 via network 1004 to receive or send messages, etc. Terminal devices 1001, 1002, and 1003 can be various electronic devices with displays, including but not limited to smartphones, tablets, laptops, and desktop computers. Additionally, server 1005 can be a server providing various services.

[0040] In one embodiment, the execution entity of the granular prediction model training method or resource occupancy prediction method of this disclosure can be a server 1005. The server 1005 can obtain the location of the scanning terminal sent by the terminal devices 1001, 1002, and 1003, and the signal characteristics of the target tracking terminal obtained by the scanning terminal at the location. The location of the target tracking terminal is determined by the location of at least two scanning terminals and the signal characteristics of the target tracking terminal obtained at each location.

[0041] Furthermore, the granular prediction model training method of this disclosure can also be executed through terminal devices 1001, 1002, 1003, etc., to achieve the following: collecting sample resource occupancy data from the node device to obtain sample resource occupancy time series; sampling the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data; inputting the multiple sets of sample resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data; determining the target resource occupancy prediction data from the multiple sets of resource occupancy prediction data; using the candidate time granularity corresponding to the target resource occupancy prediction data as the target time granularity; inputting the sample resource occupancy time series into the model to be trained to obtain the prediction granularity; and updating the neural network parameters of the model to be trained by using the prediction granularity and the target time granularity to obtain the granular prediction model.

[0042] The resource occupancy prediction method disclosed herein can also be executed through terminal devices 1001, 1002, 1003, etc., to achieve the following process: collecting sample resource occupancy data of node devices at a preset frequency to obtain sample resource occupancy time series; inputting the sample resource occupancy time series into a granularity prediction model to obtain the optimal time granularity; sampling the sample resource occupancy time series according to the optimal time granularity to obtain sample resource occupancy time series data; and inputting the sample resource occupancy time series data into a resource occupancy prediction model to obtain resource occupancy prediction data of node devices.

[0043] Furthermore, the granular prediction model training method disclosed herein can also be implemented jointly by terminal devices 1001, 1002, and 1003 and server 1005. For example, terminal devices 1001, 1002, and 1003 can collect sample resource occupancy data from node devices to obtain sample resource occupancy time series. They can then sample the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data. These multiple sets of sample resource occupancy time series data are then sent to server 1005, allowing server 1005 to input the multiple sets of sample resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data. From these multiple sets of resource occupancy prediction data, target resource occupancy prediction data is determined. The candidate time granularity corresponding to the target resource occupancy prediction data is used as the target time granularity. The sample resource occupancy time series is input into the model to be trained to obtain the prediction granularity. The neural network parameters of the model to be trained are updated using the prediction granularity and the target time granularity to obtain the granular prediction model.

[0044] The resource occupancy prediction method disclosed herein can also be implemented jointly by terminal devices 1001, 1002, 1003 and server 1005. For example, terminal devices 1001, 1002, and server 1005...

[0045] 1003 can collect sample resource occupancy data of node devices at a preset frequency to obtain sample resource occupancy time series, input the sample resource occupancy time series into the granularity prediction model to obtain the target time granularity, and then send the obtained target time granularity to server 1005 so that server 1005 can sample the sample resource occupancy time series according to the target time granularity to obtain sample resource occupancy time series data, and input the sample resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data of node devices.

[0046] With the rapid development of software and hardware, network clusters are becoming increasingly larger. In some scenarios, it is necessary to accurately predict the resource usage of nodes in the network cluster in order to make advance resource allocation, improve network resource utilization, and ensure the normal operation of services.

[0047] In related technologies, a time granularity can be determined, and sample resource occupancy data can be sampled using this time granularity to predict future resource occupancy. The choice of time granularity is crucial; too large a granularity leads to the loss of local change information, while too small a granularity leads to the loss of long-term change information. Both situations result in poor accuracy and low prediction efficiency for the predicted resource occupancy.

[0048] Currently, time granularity is typically determined manually. This method requires extensive expertise and validation of multiple candidate time granularities to determine the optimal one. The manual cost of determining time granularity is high, and the efficiency is poor. According to the granularity prediction model training method provided in this exemplary embodiment, sample resource occupancy data from node devices can be collected to obtain sample resource occupancy time series. These sample resource occupancy time series are then sampled according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data. These multiple sets of sample resource occupancy time series data are input into the resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data. Target resource occupancy prediction data is determined from these multiple sets of resource occupancy prediction data. The candidate time granularity corresponding to the target resource occupancy prediction data is used as the target time granularity. The sample resource occupancy time series is input into the model to be trained to obtain the prediction granularity. The neural network parameters of the model to be trained are updated using the prediction granularity and the target time granularity to obtain the granularity prediction model. Figure 2 As shown, the training method for this granular prediction model may include the following steps:

[0049] Step S210: Collect sample resource occupancy data from node devices to obtain the sample resource occupancy time series;

[0050] Step S220: Sample the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data;

[0051] Step S230: Input multiple sets of sample resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data;

[0052] Step S240: Determine the target resource usage prediction data from multiple sets of resource usage prediction data, and use the candidate time granularity corresponding to the target resource usage prediction data as the target time granularity.

[0053] Step S250: Input the sample resource occupancy time series into the model to be trained to obtain the prediction granularity. Update the neural network parameters of the model to be trained by the prediction granularity and the target time granularity to obtain the granularity prediction model.

[0054] In one embodiment of this disclosure, a granular prediction model training method is provided. Sample resource occupancy data from node devices is collected to obtain a sample resource occupancy time series. This time series is then sampled according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data. These multiple sets of sample resource occupancy time series data are input into a resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data. A target resource occupancy prediction data is determined from these multiple sets of prediction data. The candidate time granularity corresponding to the target resource occupancy prediction data is used as the target time granularity. The sample resource occupancy time series is then input into the model to be trained to obtain the prediction granularity. The neural network parameters of the model to be trained are updated using the prediction granularity and the target time granularity to obtain the granular prediction model. On the one hand, the optimal time granularity can be selected without requiring extensive professional knowledge, reducing labor costs. Furthermore, the optimal time granularity can be obtained without multiple verifications, resulting in high efficiency and good reusability in determining the time granularity. On the other hand, because a suitable time granularity is determined, local and long-term change information can be fully preserved when predicting resource occupancy, leading to higher accuracy in the predicted resource occupancy.

[0055] The steps S210 to S250 of the granularity prediction model training method in this exemplary embodiment will now be described in more detail with reference to the accompanying drawings and embodiments.

[0056] Step S210: Collect sample resource occupancy data from node devices to obtain the sample resource occupancy time series;

[0057] In one example embodiment of this disclosure, sample resource usage data from node devices can be collected to obtain a sample resource usage time series. Specifically, node devices can include devices in a computer network that connect, forward, and manage data flows. For example, node devices can include network switches, routers, gateways, firewalls, and other devices. Node devices are an important component of the network; they can perform functions such as data distribution, routing, filtering, and security, ensuring the stable and secure operation of the network.

[0058] It should be noted that this disclosure does not impose any special restrictions on the specific types of node devices.

[0059] In one exemplary embodiment of this disclosure, sample resource usage data of a node device can be used to indicate the resource usage of the node device; that is, the sample resource usage data of a node device can refer to the computing and storage resources occupied by the node device during operation. Specifically, the higher the resource usage of a node device, the higher its resource load; conversely, the lower the resource usage of a node device, the lower its resource load.

[0060] For example, the sample resource usage data of node devices may include CPU usage, memory usage, disk usage, network bandwidth usage, etc.

[0061] It should be noted that this disclosure does not impose any special restrictions on the specific types of sample resource usage data for node devices.

[0062] In one example embodiment of this disclosure, the sample resource occupancy time series can be used to collect sample resource occupancy data over a period of time, and the sample resource occupancy time series can be used to indicate the resource occupancy status of node devices over a period of time.

[0063] In one example embodiment of this disclosure, the sample resource occupancy time series is discrete data, which is a set of data sequences arranged in chronological order. In the sample resource occupancy time series, each data point corresponds to a time point.

[0064] It should be noted that this disclosure does not impose any special restrictions on the specific method for obtaining the time series of sample resource occupancy data from the data acquisition node devices.

[0065] In one example embodiment of this disclosure, multiple candidate time granularities can be determined according to exponential intervals. Specifically, determining multiple candidate time granularities according to exponential intervals means determining multiple candidate time granularities using exponential intervals as time division points for determining candidate time granularities.

[0066] For example, multiple candidate time granularities can be determined in the form of 2s, 4s, 8s, 16s, etc.

[0067] Step S220: Sample the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data;

[0068] In one example embodiment of this disclosure, after obtaining the sample resource occupancy time series through the above steps, multiple candidate time granularities can be obtained. Specifically, the time granularity can be used to indicate the time interval between data points in the time series, and multiple candidate time granularities can be determined within a preset range. For example, the candidate time granularities can be 1s, 2s, 1min, 2min, etc.

[0069] It should be noted that this disclosure does not impose any special limitations on the time corresponding to the candidate time granularity.

[0070] In one example embodiment of this disclosure, multiple sets of sample resource occupancy time series data can be obtained by sampling the sample resource occupancy time series according to multiple candidate time granularities. Specifically, obtaining sample resource occupancy time series data by sampling the sample resource occupancy time series according to candidate time granularities means dividing the data points in the time series into corresponding candidate time granularities.

[0071] In one example embodiment of this disclosure, a set of sample resource occupation time series data can be obtained by sampling the sample resource occupation time series according to the candidate time granularity. Since there are multiple time granularities, multiple sets of sample resource occupation time series data can be obtained by sampling the sample resource occupation time series according to the multiple candidate time granularities.

[0072] Specifically, different candidate time granularities can be used to sample the sample resource occupancy time series to obtain multiple sets of sample resource occupancy time series data corresponding to different candidate time granularities.

[0073] For example, if the candidate time granularities obtained through the above steps are 5 min, 10 min, and 20 min, then we can sample the sample resource occupancy time series according to 5 min to obtain a set of sample resource occupancy time series data, then sample the sample resource occupancy time series according to 10 min to obtain a set of sample resource occupancy time series data, and then sample the sample resource occupancy time series according to 20 min to obtain a set of sample resource occupancy time series data, and so on to obtain multiple sets of sample resource occupancy time series data.

[0074] It should be noted that this disclosure does not impose any special limitations on the specific method of sampling the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data.

[0075] Step S230: Input multiple sets of sample resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data;

[0076] In one exemplary embodiment of this disclosure, after obtaining multiple sets of sample resource occupancy time-series data through the above steps, the multiple sets of sample resource occupancy time-series data can be input into a resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time-series data. Specifically, each set of sample resource occupancy time-series data can be input into the resource occupancy prediction model to obtain resource occupancy prediction data corresponding to each set of sample resource occupancy time-series data.

[0077] The resource occupancy prediction model refers to the model used to perform the task of predicting resource occupancy. The resource occupancy prediction task is to predict the resource occupancy of node devices (including continuous and discrete data) over a future period. The resource occupancy prediction model can be a trained neural network model, which may include multiple hidden layers, such as convolutional layers, normalization layers, and activation layers. Sample resource occupancy time-series data can be input into the multiple hidden layers of the resource occupancy prediction model to obtain the hidden layer calculation results. The predicted resource occupancy data corresponding to the sample resource occupancy time-series data is then obtained from the hidden layer calculation results.

[0078] It should be noted that this disclosure does not impose any special restrictions on the specific structure of the resource occupancy prediction model.

[0079] Step S240: Determine the target resource usage prediction data from multiple sets of resource usage prediction data, and use the candidate time granularity corresponding to the target resource usage prediction data as the target time granularity.

[0080] In one exemplary embodiment of this disclosure, after obtaining resource usage prediction data corresponding to multiple sets of sample resource usage time series data through the above steps, target resource usage prediction data can be determined from the multiple sets of resource usage prediction data, and the candidate time granularity corresponding to the target resource usage prediction data is used as the target time granularity. Specifically, since the multiple sets of resource usage prediction data are different, the target resource usage prediction data can be determined from the multiple sets of resource usage prediction data. Among them, the sample resource usage time series data obtained by sampling the sample resource usage time series according to the target time granularity can retain local change information and long-term change information, and the effect of using the sample resource usage time series data for resource usage prediction is the best.

[0081] In one example embodiment of this disclosure, a scoring result can be calculated for multiple sets of resource usage prediction data, and a target resource usage prediction data can be determined from the multiple sets of resource usage prediction data based on the scoring result.

[0082] In one example embodiment of this disclosure, the actual resource usage data of node devices can be monitored, and multiple sets of predicted resource usage data can be compared with the actual resource usage data. The predicted resource usage data with high similarity can be determined as the target sample resource usage data.

[0083] It should be noted that this disclosure does not impose any special limitations on the specific method for determining the target resource usage prediction data from multiple sets of resource usage prediction data.

[0084] Step S250: Input the sample resource occupancy time series into the model to be trained to obtain the prediction granularity. Update the neural network parameters of the model to be trained by the prediction granularity and the target time granularity to obtain the granularity prediction model.

[0085] In one exemplary embodiment of this disclosure, after obtaining the target time granularity through the above steps, the sample resource occupancy time series can be input into the model to be trained to obtain the prediction granularity. Specifically, the model to be trained refers to the model used to perform the time granularity selection task. The time granularity selection task refers to the task of determining the time granularity based on the sample resource occupancy time series. By sampling the sample resource occupancy time series using this time granularity to obtain sample resource occupancy time series data, and inputting the sample resource occupancy time series data into the resource occupancy prediction model, the accuracy of the node device resource occupancy prediction data is relatively high.

[0086] In one example embodiment of this disclosure, the model to be trained can be a trained neural network model, which may include multiple hidden layers, such as convolutional layers, normalization layers, and activation layers. The time series of sample resource usage can be input into the multiple hidden layers of the model to be trained to obtain the hidden layer calculation results, and the prediction granularity can be obtained through these results.

[0087] It should be noted that this disclosure does not impose any special restrictions on the specific structure of the model to be trained.

[0088] In one exemplary embodiment of this disclosure, after obtaining the predicted granularity through the above steps, the neural network parameters of the model to be trained can be updated using the predicted granularity and the target temporal granularity to obtain a granularity prediction model. Specifically, the target temporal granularity can be used as a label during the training process to update the neural network parameters of the model to be trained, thereby obtaining the granularity prediction model.

[0089] Specifically, the granular prediction model can be used to determine the target time granularity to achieve resource usage prediction. Here, the predicted granularity is the predicted value, and the aforementioned target time granularity is used as a label. This label indicates the target time granularity for sampling the sample resource usage time series when predicting the resource usage of node devices. Then, the predicted granularity (predicted value) is compared with the target time granularity (true value) to obtain the prediction difference. The neural network parameters of the model to be trained are updated based on this prediction difference to obtain the granular prediction model.

[0090] Specifically, the neural network parameters of the model to be trained may include the number of model layers, the number of feature vector channels, and the learning rate. When updating the neural network parameters of the model to be trained based on the prediction difference, the number of model layers, the number of feature vector channels, and the learning rate of the model to be trained can be updated to train a granular prediction model.

[0091] In one example embodiment of this disclosure, the neural network parameters of the model to be trained can be updated using the backpropagation algorithm, and a granular prediction model can be obtained after training.

[0092] It should be noted that this disclosure does not impose any special limitations on the specific method of updating the neural network parameters of the model to be trained according to the target time granularity and the prediction granularity.

[0093] In one exemplary embodiment of this disclosure, the neural network parameters of the model to be trained can be updated according to the target time granularity and the prediction granularity. When the model to be trained meets the convergence condition, it is determined to be a granular prediction model. Specifically, meeting the convergence condition means that the prediction accuracy of the model to be trained is high and it can be applied. For example, the convergence condition may include the number of training iterations, such as ending training after the model to be trained N times; or the convergence condition may include the training duration, such as ending training after the model to be trained for a duration T.

[0094] It should be noted that this disclosure does not impose any special limitations on the specific content of the convergence conditions. By applying convergence conditions to the model, the training process of the model to be trained can be better controlled, the problem of overtraining of neural networks can be avoided, and the training efficiency of the model to be trained can be improved.

[0095] In one example embodiment of this disclosure, sample resource occupancy data of node devices can be collected at a preset frequency to obtain a sample resource occupancy time series. Specifically, a time interval can be set as the collection frequency, such as per second or per minute, and at each collection time point, the sample resource occupancy data of the node devices is recorded to obtain a sample resource occupancy time series.

[0096] When determining the preset frequency, it can be adjusted according to the business scenario. If the preset frequency is too high, it may lead to excessive data accumulation and storage of sample resources, while if the preset frequency is too low, some important sample resource data may be lost, thus affecting subsequent analysis and decision-making.

[0097] It should be noted that this disclosure does not impose any special limitations on the specific method for obtaining the sample resource occupancy time series by collecting sample resource occupancy data from node devices at a preset frequency.

[0098] In one example embodiment of this disclosure, actual resource usage data of the node device is obtained. Multiple sets of predicted resource usage data are compared with the actual resource usage data to obtain the degree of matching between each predicted resource usage data and the actual resource usage data. The predicted resource usage data with the highest degree of matching is determined as the target predicted resource usage data. (Refer to...) Figure 3 As shown, determining the resource usage prediction data with the highest matching degree as the target resource usage prediction data may include the following steps S310 to S330:

[0099] Step S310: Obtain the actual resource usage data of the node device;

[0100] In one example embodiment of this disclosure, after obtaining multiple sets of sample resource usage time-series data through the above steps, the actual resource usage data of the node devices can be obtained. Specifically, the resource usage prediction data obtained through the resource usage prediction model refers to the predicted resource usage of the node devices over a future period, while the actual resource usage data of the node devices refers to the actual resource usage of the node devices during that period (i.e., the future period corresponding to the resource usage prediction data). That is, after making a prediction through the resource usage prediction model, the actual resource usage data of the node devices can continue to be recorded.

[0101] Step S320: Compare multiple sets of resource usage prediction data with actual resource usage data to obtain the degree of matching between each set of resource usage prediction data and actual resource usage data;

[0102] In one example embodiment of this disclosure, after obtaining the actual resource usage data of the node device through the above steps, multiple sets of predicted resource usage data can be compared with the actual resource usage data to obtain the degree of matching between each predicted resource usage data and the actual resource usage data. Specifically, the degree of matching between the predicted resource usage data and the actual resource usage data can be used to indicate the similarity between the predicted resource usage data and the actual resource usage data.

[0103] In one example embodiment of this disclosure, the degree of matching between each resource usage prediction data and the actual resource usage data can be determined by comparing the specific values ​​of each resource usage prediction data with the specific values ​​of the actual resource usage data.

[0104] For example, if the difference between the predicted resource usage data and the actual resource usage data is small at each time point, it can be determined that the predicted resource usage data matches the actual resource usage data to a high degree.

[0105] Furthermore, multiple sets of resource usage prediction data can be compared with actual resource usage data to obtain a comparison score for each set of resource usage prediction data and actual resource usage data, so as to determine the degree of matching between each set of resource usage prediction data and actual resource usage data based on the comparison score.

[0106] It should be noted that this disclosure does not impose any special limitations on the specific method of comparing multiple sets of resource usage prediction data with actual resource usage data to obtain the degree of matching between each set of resource usage prediction data and actual resource usage data.

[0107] Step S330: The resource usage prediction data with the highest matching degree is determined as the target resource usage prediction data.

[0108] In one example embodiment of this disclosure, after obtaining the matching degree between each resource usage prediction data and the actual resource usage data through the above steps, the resource usage prediction data with the highest matching degree can be determined as the target resource usage prediction data. Specifically, the resource usage prediction data with the highest matching degree indicates that the resource usage prediction data has the highest similarity to the actual resource usage data. This means that the resource usage prediction data predicted by the sample resource usage time series data obtained by sampling the candidate time granularity corresponding to the resource usage prediction data is the most accurate. At this time, the resource usage prediction data can be determined as the target resource usage prediction data, and the candidate time granularity corresponding to the target resource usage prediction data can be used as the target time granularity.

[0109] Through the above steps S310 to S330, the actual resource usage data of the node device can be obtained. The multiple sets of resource usage prediction data are compared with the actual resource usage data to obtain the matching degree between each resource usage prediction data and the actual resource usage data. The resource usage prediction data with the highest matching degree is determined as the target resource usage prediction data.

[0110] In one example embodiment of this disclosure, the time-domain features corresponding to the sample resource occupancy time series can be calculated, and the frequency-domain features corresponding to the sample resource occupancy time series can be calculated based on the time-domain features. The time-domain features and frequency-domain features corresponding to the sample resource occupancy time series are then input into the model to be trained to obtain the prediction granularity. (Refer to...) Figure 4 As shown, inputting the time-domain features corresponding to the sample resource occupancy time series and the frequency-domain features corresponding to the sample resource occupancy time series into the model to be trained to obtain the prediction granularity may include the following steps S410~S420:

[0111] Step S410: Calculate the time-domain features corresponding to the sample resource occupancy time series, and calculate the frequency-domain features corresponding to the sample resource occupancy time series based on the time-domain features.

[0112] Step S420: Input the time-domain features corresponding to the sample resource occupancy time series and the frequency-domain features corresponding to the sample resource occupancy time series into the model to be trained to obtain the prediction granularity.

[0113] In one exemplary embodiment of this disclosure, after obtaining the sample resource occupancy time series through the above steps, the corresponding time-domain features can be calculated. Specifically, the time-domain features corresponding to the sample resource occupancy time series can be used to indicate the changes in the sample resource occupancy time series over time. The time-domain features corresponding to the sample resource occupancy time series can provide instantaneous, average, and periodic characteristic information about the sample resource occupancy time series, and can be used to analyze the dynamic characteristics of the sample resource occupancy time series.

[0114] For example, the temporal characteristics corresponding to the time series of sample resource occupancy can be calculated by methods such as calculating the window mean, window extrema, and variance.

[0115] It should be noted that this disclosure does not impose any special limitations on the specific method for calculating the time-domain characteristics corresponding to the time series of sample resource occupancy.

[0116] In one exemplary embodiment of this disclosure, after obtaining the time-domain characteristics corresponding to the sample resource occupancy time series, the frequency-domain characteristics corresponding to the sample resource occupancy time series can be calculated based on these time-domain characteristics. Specifically, the frequency-domain information can be used to indicate the frequency variation of the sample resource occupancy time series, that is, the frequency characteristics of the sample resource occupancy time series. The frequency-domain information corresponding to the sample resource occupancy time series can provide characteristic information such as the frequency, harmonics, and energy distribution of the sample resource occupancy time series, and can be used to analyze the static characteristics of the sample resource occupancy time series.

[0117] Specifically, after obtaining the time-domain features corresponding to the sample resource occupancy time series, a Fourier transform can be performed on the time-domain features corresponding to the sample resource occupancy time series to obtain the frequency-domain information corresponding to the sample resource occupancy time series.

[0118] It should be noted that this disclosure does not impose any special limitations on the specific method for calculating the frequency domain characteristics corresponding to the sample resource occupancy time series based on the time domain characteristics corresponding to the sample resource occupancy time series.

[0119] Through the steps S410-S420 described above, the temporal features corresponding to the sample resource occupancy time series can be calculated. Based on these temporal features, the frequency domain features corresponding to the sample resource occupancy time series are then calculated. These temporal and frequency domain features are input into the model to be trained to obtain the prediction granularity. The scheme in this embodiment can obtain both the temporal and frequency domain features corresponding to the sample resource occupancy time series. When predicting the prediction granularity, it can fully consider the temporal and frequency variations of the sample resource occupancy time series, thereby improving the accuracy of the prediction.

[0120] In one exemplary embodiment of this disclosure, a resource usage prediction method is also provided, such as... Figure 5 As shown, the granular prediction model training method may include the following steps S510 to S540:

[0121] Step S510: Collect resource usage data of node devices at a preset frequency to obtain a resource usage time series;

[0122] In one example embodiment of this disclosure, resource usage data of node devices can be collected at a preset frequency to obtain a resource usage time series. Specifically, node devices may include devices in a computer network that connect, forward, and manage data streams. The resource usage data of node devices can be used to indicate the resource usage status of node devices, specifically referring to the computing and storage resources occupied by the node devices during operation.

[0123] In one example embodiment of this disclosure, the resource occupancy time series can be used to collect resource occupancy data over a period of time, and the resource occupancy time series can be used to indicate the resource occupancy status of node devices over a period of time.

[0124] It should be noted that this disclosure does not impose any special limitations on the specific method for obtaining the resource usage time series by collecting resource usage data of node devices at a preset frequency.

[0125] Step S520: Input the resource occupancy time series into the granularity prediction model to obtain the optimal time granularity;

[0126] In one example embodiment of this disclosure, after obtaining the resource usage time series through the above steps, the resource usage time series can be input into a granularity prediction model to obtain the optimal time granularity. The granularity prediction model is trained using the granularity prediction model training method described in any of the above embodiments. Specifically, the granularity prediction model refers to a model used to perform the time granularity selection task. The time granularity selection task refers to the task of determining the time granularity based on the resource usage time series. By sampling the resource usage time series using this time granularity to obtain resource usage time-series data, and inputting this data into the resource usage prediction model, the accuracy of the node device's resource usage prediction data is relatively high.

[0127] Step S530: Sample the resource occupancy time series according to the optimal time granularity to obtain resource occupancy time series data;

[0128] In one exemplary embodiment of this disclosure, after obtaining the optimal time granularity through the above steps, the resource occupancy time series can be sampled according to the optimal time granularity to obtain resource occupancy time series data. Specifically, obtaining resource occupancy time series data by sampling the resource occupancy time series according to the optimal time granularity means dividing the data points in the time series into the corresponding optimal time granularity to obtain resource occupancy time series data.

[0129] It should be noted that this disclosure does not impose any special restrictions on the specific method of sampling the resource occupancy time series according to the optimal time granularity to obtain resource occupancy time series data.

[0130] Step S540: Input the resource occupancy time series data into the resource occupancy prediction model to obtain the resource occupancy prediction data of the node devices.

[0131] In one example embodiment of this disclosure, after obtaining the resource usage time-series data through the above steps, the resource usage time-series data can be input into a resource usage prediction model to obtain the resource usage prediction data of the node devices. Specifically, the resource usage prediction model refers to a model used to perform the resource usage prediction task. The resource usage prediction task refers to the task of predicting the resource usage of node devices over a future period of time. After inputting the resource usage time-series data into the resource usage prediction model, the resource usage prediction data of the node devices can be obtained, that is, the resource usage of the node devices over a future period of time (including continuous data and discrete data).

[0132] Through the above steps S510 to S540, resource occupancy data of node devices can be collected at a preset frequency to obtain a resource occupancy time series. The resource occupancy time series is then input into a granularity prediction model to obtain the optimal time granularity. The resource occupancy time series is sampled according to the optimal time granularity to obtain resource occupancy time series data. The resource occupancy time series data is then input into a resource occupancy prediction model to obtain resource occupancy prediction data of node devices.

[0133] In one exemplary embodiment of this disclosure, such as Figure 6 The diagram shown is a flowchart of a resource occupancy prediction method, which may include the following parts:

[0134] Time-series data sampling: Collect sample resource usage data from node devices to obtain sample resource usage time series, and sample the sample resource usage time series according to multiple candidate time granularities to obtain multiple sets of sample resource usage time series data; collect resource usage data from node devices to obtain resource usage time series, and sample the resource usage time series according to the optimal time granularity to obtain resource usage time series data.

[0135] Constructing the training dataset involves determining candidate time granularities and determining the target time granularity. Specifically, determining candidate time granularities involves identifying multiple candidate time granularities at exponential intervals. Determining the target time granularity involves inputting multiple sets of sample resource occupancy time-series data into the resource occupancy prediction model to obtain resource occupancy prediction data corresponding to these multiple sets of data. From these multiple sets of prediction data, the target resource occupancy prediction data is determined, and the candidate time granularity corresponding to this data is used as the target time granularity.

[0136] Granularity prediction model: Time domain analysis, frequency domain analysis, and target time granularity prediction. Specifically, time domain analysis calculates the time domain features corresponding to the sample resource occupancy time series; frequency domain analysis calculates the frequency domain features corresponding to the sample resource occupancy time series based on the time domain features; and time granularity prediction inputs both the time domain and frequency domain features corresponding to the sample resource occupancy time series into the model to be trained to obtain the predicted granularity.

[0137] Model training: The neural network parameters of the model to be trained are updated by predicting the granularity and the target time granularity to obtain a granular prediction model.

[0138] Time series data preprocessing: Preprocessing the sample resource usage time series data;

[0139] Resource occupancy prediction: Input the resource occupancy time series into the granularity prediction model to obtain the optimal time granularity, and input the resource occupancy time series data obtained by sampling through the optimal time granularity into the resource occupancy prediction model to obtain the resource occupancy prediction data of the node device.

[0140] In one exemplary embodiment of this disclosure, such as Figure 7 The image shows a resource usage prediction system, which may include the following modules:

[0141] The time-series data sampling module 710 is used to collect sample resource occupancy data of node devices to obtain sample resource occupancy time series, and to sample the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data; to collect resource occupancy data of node devices to obtain resource occupancy time series, and to sample the resource occupancy time series according to the optimal time granularity to obtain resource occupancy time series data.

[0142] The training dataset construction module 720 is used to determine multiple candidate time granularities according to exponential intervals; input multiple sets of sample resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data corresponding to multiple sets of sample resource occupancy time series data; determine the target resource occupancy prediction data from the multiple sets of resource occupancy prediction data; and use the candidate time granularity corresponding to the target resource occupancy prediction data as the target time granularity.

[0143] The time granularity prediction module 730 is used to calculate the time-domain features corresponding to the sample resource occupancy time series, and to calculate the frequency-domain features corresponding to the sample resource occupancy time series based on the time-domain features. The time-domain features and frequency-domain features corresponding to the sample resource occupancy time series are input into the model to be trained to obtain the prediction granularity. The neural network parameters of the model to be trained are updated using the predicted granularity and the target time granularity to obtain the granularity prediction model.

[0144] The time series data preprocessing module 740 is used to preprocess the sample resource occupancy time series data / resource occupancy time series data.

[0145] The resource occupancy prediction module 750 is used to input the resource occupancy time series into the granularity prediction model to obtain the optimal time granularity, and input the resource occupancy time series data obtained by sampling through the optimal time granularity into the resource occupancy prediction model to obtain the resource occupancy prediction data of the node device.

[0146] In one embodiment of this disclosure, a granular prediction model training method is provided. Sample resource occupancy data from node devices is collected to obtain a sample resource occupancy time series. This time series is then sampled according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data. These multiple sets of sample resource occupancy time series data are input into a resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data. A target resource occupancy prediction data is determined from these multiple sets of prediction data. The candidate time granularity corresponding to the target resource occupancy prediction data is used as the target time granularity. The sample resource occupancy time series is then input into the model to be trained to obtain the prediction granularity. The neural network parameters of the model to be trained are updated using the prediction granularity and the target time granularity to obtain the granular prediction model. On the one hand, the optimal time granularity can be selected without requiring extensive professional knowledge, reducing labor costs. Furthermore, the optimal time granularity can be obtained without multiple verifications, resulting in high efficiency and good reusability in determining the time granularity. On the other hand, because a suitable time granularity is determined, local and long-term change information can be fully preserved when predicting resource occupancy, leading to higher accuracy in the predicted resource occupancy.

[0147] It should be noted that the above figures are merely illustrative of the processes included in the method according to exemplary embodiments of this disclosure, and are not intended to be limiting. It is readily understood that the processes shown in the above figures do not indicate or limit the temporal order of these processes. Furthermore, it is readily understood that these processes may be executed synchronously or asynchronously, for example, in multiple modules.

[0148] Furthermore, in an exemplary embodiment of this disclosure, a granular prediction model training apparatus is also provided. (Refer to...) Figure 8 As shown, a granularity prediction model training device 800 includes: a time series acquisition module 810, a time series data acquisition module 820, an occupancy data prediction module 830, a granularity determination module 840, and a model training module 850.

[0149] The system comprises the following modules: a time series acquisition module for collecting sample resource occupancy data from node devices to obtain a sample resource occupancy time series; a time series data acquisition module for sampling the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data; an occupancy data prediction module for inputting multiple sets of sample resource occupancy time series data into a resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data; a granularity determination module for determining the target resource occupancy prediction data from multiple sets of resource occupancy prediction data and using the candidate time granularity corresponding to the target resource occupancy prediction data as the target time granularity; and a model training module for inputting the sample resource occupancy time series into the model to be trained to obtain the prediction granularity, and updating the neural network parameters of the model to be trained by using the prediction granularity and the target time granularity to obtain a granularity prediction model.

[0150] In an exemplary embodiment of this disclosure, based on the aforementioned scheme, sample resource occupancy data of the collected node devices are used to obtain a sample resource occupancy time series. The apparatus further includes: a sample resource occupancy time series acquisition unit, used to collect sample resource occupancy data of the node devices at a preset frequency to obtain a sample resource occupancy time series.

[0151] In an exemplary embodiment of this disclosure, based on the aforementioned scheme, a target resource usage prediction data is determined from multiple sets of resource usage prediction data. The apparatus further includes: an actual resource usage data acquisition unit, used to acquire the actual resource usage data of the node device; a matching degree acquisition unit, used to compare the multiple sets of resource usage prediction data with the actual resource usage data to obtain the matching degree between each resource usage prediction data and the actual resource usage data; and a target resource usage prediction data determination unit, used to determine the resource usage prediction data with the highest matching degree as the target resource usage prediction data.

[0152] In an exemplary embodiment of this disclosure, based on the aforementioned scheme, the sample resource occupancy time series is input into the model to be trained to obtain the prediction granularity. The apparatus further includes: a time-domain feature calculation unit, used to calculate the time-domain features corresponding to the sample resource occupancy time series, and calculate the frequency-domain features corresponding to the sample resource occupancy time series based on the time-domain features; and a prediction granularity acquisition unit, used to input the time-domain features corresponding to the sample resource occupancy time series and the frequency-domain features corresponding to the sample resource occupancy time series into the model to be trained to obtain the prediction granularity.

[0153] In one exemplary embodiment of this disclosure, based on the foregoing scheme, the apparatus further includes: an exponential interval determination unit, configured to determine a plurality of candidate time granularities according to an exponential interval.

[0154] Since the functional modules of the granularity prediction model training device in the example embodiments of this disclosure correspond to the steps of the example embodiments of the granularity prediction model training method described above, for details not disclosed in the device embodiments of this disclosure, please refer to the embodiments of the granularity prediction model training method described above.

[0155] Furthermore, in an exemplary embodiment of this disclosure, a resource usage prediction apparatus is also provided. (Refer to...) Figure 9 As shown, a resource occupancy prediction device 900 includes: an occupancy data acquisition module 910, an optimal time granularity prediction module 920, an optimal time granularity sampling module 930, and a resource occupancy prediction module 940.

[0156] The system includes: a resource occupancy data acquisition module, used to collect resource occupancy data of node devices at a preset frequency to obtain a resource occupancy time series; an optimal time granularity prediction module, used to input the resource occupancy time series into a granularity prediction model to obtain the optimal time granularity; wherein, the granularity prediction model is trained using any of the above-mentioned granularity prediction model training methods; an optimal time granularity sampling module, used to sample the resource occupancy time series according to the target time granularity to obtain resource occupancy time series data; and a resource occupancy prediction module, used to input the resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data of node devices.

[0157] Since the functional modules of the resource usage prediction device in the example embodiments of this disclosure correspond to the steps of the example embodiments of the resource usage prediction method described above, for details not disclosed in the device embodiments of this disclosure, please refer to the embodiments of the resource usage prediction method described above.

[0158] It should be noted that although several modules or units for the device used to perform actions have been mentioned in the detailed description above, this division is not mandatory. In fact, according to embodiments of this disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.

[0159] Furthermore, in an exemplary embodiment of this disclosure, an electronic device capable of implementing the above-described granular prediction model training method or resource occupancy prediction method is also provided.

[0160] Those skilled in the art will understand that various aspects of this disclosure can be implemented as a system, method, or program product. Therefore, various aspects of this disclosure can be embodied in the following forms: a completely hardware embodiment, a completely software embodiment (including firmware, microcode, etc.), or an embodiment combining hardware and software aspects, collectively referred to herein as a "circuit," "module," or "system."

[0161] The following reference Figure 10 To describe an electronic device 10000 according to such an embodiment of the present disclosure. Figure 10 The electronic device 10000 shown is merely an example and should not impose any limitations on the functionality and scope of use of the embodiments disclosed herein.

[0162] like Figure 10 As shown, the electronic device 10000 is manifested in the form of a general-purpose computing device. The components of the electronic device 10000 may include, but are not limited to: at least one processing unit 1010, at least one storage unit 1020, a bus 1030 connecting different system components (including storage unit 1020 and processing unit 1010), and a display unit 1040.

[0163] The storage unit stores program code, which can be executed by the processing unit 1010 to perform the steps described in the "Exemplary Methods" section of this specification according to various exemplary embodiments of this disclosure. For example, the processing unit 1010 can perform actions such as... Figure 2 The steps S210 and S220 are as follows: First, sample resource occupancy data of node devices is collected to obtain a sample resource occupancy time series. Second, the sample resource occupancy time series is sampled according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time series data. Third, the multiple sets of sample resource occupancy time series data are input into a resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data. Fourth, the target resource occupancy prediction data is determined from the multiple sets of resource occupancy prediction data, and the candidate time granularity corresponding to the target resource occupancy prediction data is used as the target time granularity. Fifth, the sample resource occupancy time series is input into the model to be trained to obtain the prediction granularity. The neural network parameters of the model to be trained are updated using the prediction granularity and the target time granularity to obtain a granularity prediction model. For example, the processing unit 1010 can perform the following steps: Figure 5The steps shown are as follows: Step S510: Collect resource occupancy data of node devices at a preset frequency to obtain resource occupancy time series; Step S520: Input the resource occupancy time series into the granularity prediction model to obtain the optimal time granularity; Step S530: Sample the resource occupancy time series according to the optimal time granularity to obtain resource occupancy time series data; Step S540: Input the resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data of node devices.

[0164] Storage unit 1020 may include a readable medium in the form of a volatile storage unit, such as a random access memory unit (RAM) 1021 and / or a cache memory unit 1022, and may further include a read-only memory unit (ROM) 1023.

[0165] Storage unit 1020 may also include a program / utility 1024 having a set (at least one) program module 1025, such program module 1025 including but not limited to: operating system, one or more application programs, other program modules and program data, each or some combination of these examples may include an implementation of a network environment.

[0166] Bus 1030 can represent one or more of several types of bus structures, including a memory cell bus or memory cell controller, a peripheral bus, a graphics acceleration open port, a processing unit, or a local bus using any of the multiple bus structures.

[0167] Electronic device 10000 can also communicate with one or more external devices 1070 (e.g., keyboard, pointing device, Bluetooth device, etc.), one or more devices that enable a user to interact with electronic device 10000, and / or any device that enables electronic device 10000 to communicate with one or more other computing devices (e.g., router, modem, etc.). This communication can be performed via input / output (I / O) interface 1050. Furthermore, electronic device 10000 can also communicate with one or more networks (e.g., local area network (LAN), wide area network (WAN), and / or public networks, such as the Internet) via network adapter 1060. As shown, network adapter 1060 communicates with other modules of electronic device 10000 via bus 1030. It should be understood that, although not shown in the figures, other hardware and / or software modules can be used in conjunction with electronic device 10000, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.

[0168] From the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware. Therefore, the technical solutions according to the embodiments of this disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, external hard drive, etc.) or on a network, including several instructions to cause a computing device (such as a personal computer, server, terminal device, or network device, etc.) to execute the methods according to the embodiments of this disclosure.

[0169] In exemplary embodiments of this disclosure, a computer-readable storage medium is also provided, on which a program product capable of implementing the methods described above is stored. In some possible embodiments, various aspects of this disclosure may also be implemented as a program product including program code that, when the program product is run on a terminal device, causes the terminal device to perform the steps described in the "Exemplary Methods" section of this specification according to various exemplary embodiments of this disclosure.

[0170] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A readable signal medium may also be any readable medium other than a readable storage medium, capable of sending, propagating, or transmitting programs for use by or in conjunction with an instruction execution system, apparatus, or device.

[0171] The program code contained on the readable medium may be transmitted using any suitable medium, including but not limited to wireless, wired, optical fiber, RF, etc., or any suitable combination thereof.

[0172] Program code for performing the operations of this disclosure can be written in any combination of one or more programming languages, including object-oriented programming languages ​​such as Java and C++, and conventional procedural programming languages ​​such as C or similar languages. The program code can execute entirely on the user's computing device, partially on the user's computing device, as a standalone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server. In cases involving remote computing devices, the remote computing devices can be connected to the user's computing device via any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computing device (e.g., via the Internet using an Internet service provider).

[0173] Furthermore, the above figures are merely illustrative of the processes included in the method according to exemplary embodiments of this disclosure and are not intended to be limiting. It is readily understood that the processes shown in the above figures do not indicate or limit the temporal order of these processes. Additionally, it is readily understood that these processes may be executed synchronously or asynchronously, for example, in multiple modules.

[0174] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein. The specification and embodiments are to be considered exemplary only, and the true scope and spirit of this disclosure are indicated by the claims.

Claims

1. A method for training a granular prediction model, characterized in that, The method includes: The time series of sample resource usage is obtained by collecting sample resource usage data from the node devices. Multiple sets of sample resource occupancy time series data are obtained by sampling the sample resource occupancy time series according to multiple candidate time granularities; Inputting multiple sets of sample resource occupancy time series data into the resource occupancy prediction model yields resource occupancy prediction data corresponding to multiple sets of sample resource occupancy time series data. Among the multiple sets of resource occupancy prediction data, target resource occupancy prediction data is determined, and the candidate time granularity corresponding to the target resource occupancy prediction data is taken as the target time granularity. The step of determining the target resource usage prediction data from the multiple sets of resource usage prediction data includes: Obtain the actual resource usage data of the node device; The degree of matching between each set of predicted resource occupancy data and the actual resource occupancy data is obtained by comparing the predicted resource occupancy data with the actual resource occupancy data. The resource usage prediction data with the highest matching degree is determined as the target resource usage prediction data; The sample resource occupancy time series is input into the model to be trained to obtain the prediction granularity. The neural network parameters of the model to be trained are updated using the prediction granularity and the target time granularity to obtain the granularity prediction model.

2. The method according to claim 1, characterized in that, The sample resource occupancy data from the acquisition node device is used to obtain a sample resource occupancy time series, including: The time series of sample resource occupancy is obtained by collecting sample resource occupancy data from node devices at a preset frequency.

3. The method according to claim 1, characterized in that, The step of inputting the sample resource occupancy time series into the model to be trained to obtain the prediction granularity includes: Calculate the time-domain features corresponding to the sample resource occupancy time series, and calculate the frequency-domain features corresponding to the sample resource occupancy time series based on the time-domain features. The time-domain features and frequency-domain features corresponding to the sample resource occupancy time series are input into the model to be trained to obtain the prediction granularity.

4. The method according to claim 1, characterized in that, The method further includes: Multiple candidate time granularities are determined based on exponential intervals.

5. A resource occupancy prediction method, characterized in that, The method includes: Resource usage data of node devices are collected at a preset frequency to obtain a resource usage time series. The optimal time granularity is obtained by inputting the resource occupancy time series into the granularity prediction model; wherein, the granularity prediction model is trained by the granularity prediction model training method as described in any one of claims 1-4; Resource occupancy time series data are obtained by sampling the resource occupancy time series according to the target time granularity; The resource usage time series data is input into the resource usage prediction model to obtain the resource usage prediction data of the node device.

6. A granularity prediction model training device, characterized in that, The device includes: The time series acquisition module is used to collect sample resource usage data from node devices to obtain the sample resource usage time series. The time-series data acquisition module is used to sample the sample resource occupancy time series according to multiple candidate time granularities to obtain multiple sets of sample resource occupancy time-series data; The resource occupancy prediction module is used to input multiple sets of sample resource occupancy time series data into the resource occupancy prediction model to obtain resource occupancy prediction data corresponding to the multiple sets of sample resource occupancy time series data. The granularity determination module is used to determine the target resource occupancy prediction data from the multiple sets of resource occupancy prediction data, and to take the candidate time granularity corresponding to the target resource occupancy prediction data as the target time granularity. The granularity determination module is used to obtain the actual resource usage data of the node device; The degree of matching between each set of predicted resource occupancy data and the actual resource occupancy data is obtained by comparing the predicted resource occupancy data with the actual resource occupancy data. The resource usage prediction data with the highest matching degree is determined as the target resource usage prediction data. The model training module is used to input the sample resource occupancy time series into the model to be trained to obtain the prediction granularity, and update the neural network parameters of the model to be trained by the prediction granularity and the target time granularity to obtain the granularity prediction model.

7. A resource occupancy prediction device, characterized in that, The device includes: The resource occupancy data acquisition module is used to collect resource occupancy data of node devices at a preset frequency to obtain a resource occupancy time series. The optimal time granularity prediction module is used to input the resource occupancy time series into the granularity prediction model to obtain the optimal time granularity; wherein, the granularity prediction model is trained by the granularity prediction model training method as described in any one of claims 1-4; The optimal time granularity sampling module is used to sample the resource occupancy time series according to the target time granularity to obtain resource occupancy time series data; The resource occupancy prediction module is used to input the resource occupancy time-series data into the resource occupancy prediction model to obtain the resource occupancy prediction data of the node device.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the method as described in any one of claims 1 to 5.

9. An electronic device, characterized in that, include: One or more processors; as well as A memory for storing one or more programs, which, when executed by one or more processors, cause the one or more processors to implement the method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Server resource prediction method and device, computer equipment and storage medium

    CN110059858A

  • Training method and prediction method of time sequence prediction model and related equipment

    CN115310689A