Resource load prediction method based on amsp-affirm framework

By combining adaptive multi-scale modules and the Affirm backbone network, the shortcomings of fixed-slice strategies in data center resource load prediction are addressed, enabling more efficient multi-scale information processing and improving prediction accuracy and computational efficiency.

CN122346641APending Publication Date: 2026-07-07QINGHAI UNIV FOR NATITIES +1

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
QINGHAI UNIV FOR NATITIES
Filing Date
2026-04-10
Publication Date
2026-07-07

Smart Images

  • Figure CN122346641A_ABST
    Figure CN122346641A_ABST
Patent Text Reader

Abstract

The application discloses a resource load prediction method based on an AMSP-Affirm framework, and belongs to the field of resource load prediction.The method comprises the following steps: obtaining a resource load sequence, inputting the resource load sequence into an adaptive multi-scale module to generate a semantic token sequence; and inputting the semantic token sequence into an Affirm model to output a prediction of future load.The prediction framework proposed by the application adopts an adaptive multi-scale division method, adaptively determines a segmentation boundary according to the local variation degree of the sequence, and generates variable-length segments; then, the variable-length segments are mapped into a unified representation through scale-invariant embedding, and are input into the Affirm to complete feature extraction and multi-step prediction.The method can automatically adjust the observation scale according to the change rhythm of different sections of the sequence, thereby simultaneously improving the description ability of peak intervals and the maintenance ability of long-term trends, and solving the problem that the uniform scale slicing method of the prior art limits the prediction accuracy and reasoning efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of resource load forecasting, specifically relating to a resource load forecasting method based on the AMSP-Affirm framework. Background Technology

[0002] In data center resource scheduling research, resource load forecasting is considered a crucial element supporting capacity planning and online scheduling decisions. With the continuous development of generative artificial intelligence and cloud services, the computing power demand of data centers is constantly increasing, and resource utilization fluctuations are becoming more frequent and significant. When the load fluctuates rapidly, the system is prone to uneven distribution of computing resources, leading to longer request queues, increased task waiting times, and ultimately, increased response latency and decreased service quality. If the scheduling system lacks reliable predictions of future load changes, common practices include either reserving excessive resources in advance to cope with uncertainty, or temporarily expanding capacity and migrating tasks when response latency increases. The former results in idle resources and additional energy consumption, while the latter may fail to alleviate congestion in a timely manner during critical periods due to delayed adjustments. Therefore, constructing accurate and efficient resource load forecasting methods is a fundamental step in improving data center operational efficiency and service stability.

[0003] Currently, scholars both domestically and internationally have conducted extensive research on load forecasting and achieved certain results. Early methods relied heavily on statistical regularities and were suitable for sequences with relatively stable changes and fixed patterns. However, these methods often struggled to cope reliably when business switching was frequent or sudden increases in tasks occurred. Subsequently, deep learning methods, with their stronger expressive power, performed better in complex load forecasting and were able to learn more complex patterns of change from historical data. In recent years, a common practice has been to divide long sequences into several equal-length segments and then model these segments. This approach has been widely adopted because it typically achieves good results with manageable computational overhead. Simultaneously, some more efficient long sequence modeling structures have emerged, enabling models to utilize longer historical information for prediction without incurring excessive computational burden.

[0004] However, existing research still faces a significant challenge in its model data input methods. Most methods default to a fixed-length slicing strategy, but resource load varies at different time periods. Load sequences often exhibit rapid changes in certain segments, with sudden and short-lived peaks, while other segments change more slowly, showing a stable and continuous overall trend. Fixed slice lengths often struggle to adapt to the multi-scale variation characteristics of load sequences. When slices are long, sudden peaks and sharp local fluctuations are easily smoothed out, resulting in insufficient prominence of key change information in the representation. Conversely, when slices are short, the number of segments increases significantly, leading to higher computational and storage costs, while long-term trends are over-segmented, making it difficult to stably model continuous dependencies across time periods. Therefore, using a uniform slicing approach typically fails to simultaneously capture peak characteristics and maintain trends, limiting further improvements in prediction accuracy and inference efficiency, thus becoming a pressing issue.

[0005] Meanwhile, novel and efficient modeling structures for long-sequence prediction offer new solutions to these contradictions. For example, models like Affirm, while maintaining low computational costs, can more effectively handle information over long timeframes and accommodate both stable changes and local fluctuations, making them suitable for data center load forecasting tasks. However, if fixed-length slices are still used as input, the model struggles to proactively adapt to the changing rhythm of load across different segments. In other words, even if the backbone model is sufficiently efficient, an inappropriate input segmentation method can weaken the model's sensitivity to critical fluctuations or increase unnecessary computational burden. Therefore, simply changing the prediction model is insufficient; a more reasonable segmentation method needs to be redesigned at the input level. Summary of the Invention

[0006] To address the aforementioned shortcomings in existing technologies, the resource load prediction method based on the AMSP-Affirm framework provided by this invention solves the problem that the use of a uniform-scale slicing method in existing technologies limits prediction accuracy and inference efficiency.

[0007] To achieve the above-mentioned objectives, the technical solution adopted by this invention is: a resource load prediction method based on the AMSP-Affirm framework, comprising the following steps:

[0008] S1. Obtain the resource load sequence and input it into the adaptive multi-scale module to generate a semantic token sequence;

[0009] S2. Input the semantic token sequence into the Affirm model and output a prediction of future load.

[0010] Furthermore: In S1, the workflow of the adaptive multi-scale module is as follows:

[0011] S11. Perform time-frequency analysis on the resource load sequence using continuous wavelet transform, and calculate the wavelet coefficients of the resource load sequence;

[0012] S12. Calculate the segmentation score sequence based on the wavelet coefficients of the resource load sequence, as an indicator to characterize the strength of local nonstationarity;

[0013] S13. The segmentation score sequence is used as the segmentation score at each time step within the window, and the segmentation threshold of the window is calculated using an adaptive threshold mechanism based on window statistics.

[0014] S14. Dynamically segment the fragments using a sequential scanning strategy based on the window's segmentation threshold;

[0015] S15. Input all fragments into the scale-invariant embedding layer to obtain the semantic token sequence.

[0016] The beneficial effects of the above-mentioned further scheme are as follows: Unlike the preset multiple sets of fixed segment lengths, the adaptive multi-scale module AMSP measures local signal features and adaptively determines segment boundaries, so that segments with more violent fluctuations can obtain finer-grained segment representations, while longer segments are used in relatively stable segments to preserve continuous context and reduce unnecessary computational overhead; then it is combined with an efficient backbone network to carry out multi-step prediction, thereby achieving a more reliable improvement in overall error and peak characterization stability.

[0017] Furthermore: In S11, the resource load sequence is calculated. In scale ,time wavelet coefficients The specific expression is:

[0018]

[0019] In the formula, For the mother wavelet function, For the complex conjugate of the mother wavelet function, This is the integration variable, used to iterate over the signal across the entire time axis. .

[0020] Furthermore: In S12, the segmentation scoring sequence is calculated based on the wavelet coefficients of the resource load sequence. The specific expression is:

[0021]

[0022] In the formula, The sign of the partial derivative. It is the Frobenius norm.

[0023] Furthermore: In S13, the method using an adaptive threshold mechanism based on window statistics is as follows:

[0024] Let the set of time indices corresponding to the current input window be . The segmentation score at each time point within the window is recorded as follows: The mean and standard deviation of the ratings within the window are calculated, and then the window segmentation threshold is set. ;

[0025]

[0026] In the formula, This represents the average score within the window. The standard deviation of the scores within the window. This is a sensitivity coefficient used to adjust the aggressiveness of the segmentation;

[0027]

[0028] .

[0029] The beneficial effects of the above-mentioned further scheme are as follows: In order to avoid poor fit between different sequences due to the use of a fixed threshold, the present invention introduces an adaptive threshold mechanism based on window statistics. The calculated window segmentation threshold will be automatically updated with the average level and fluctuation amplitude of the score within the window, so that the model can adaptively identify the positions of obvious changes in the sequence in sequences with different fluctuation intensities.

[0030] Furthermore: S14 specifically refers to:

[0031] S141. Starting from the beginning of the resource load sequence, scan to the right and expand the current segment. Let the starting point of the current segment be... The current segment length is and set the minimum length and maximum length Constrain fragment length;

[0032] S142. Continuously expand the current segment and update the current segment length. In response to a segmentation score higher than the segmentation threshold of the current window and the current segment length... Not less than the minimum length If a significant structural change is detected at that location, segmentation is performed; in response to the current segment length... Reaching maximum length If so, then the splitting will be performed;

[0033] S143. After segmentation, output the current segment and update the starting point of the next segment to... At the same time, reset the current segment length. Repeat the method in S142 to continuously generate fragments until the resource load sequence is scanned.

[0034] The beneficial effects of the above-mentioned further scheme are as follows: the segmentation strategy generates a set of segments with variable lengths, wherein the segment length is adaptively adjusted according to the local changes in the sequence. This segmentation strategy enables earlier truncation in regions with high change intensity to improve the ability to characterize local structures, while in regions with slower changes, it tends to form longer segments to retain more contextual information, thereby obtaining a patch sequence with variable length characteristics.

[0035] Furthermore: S15 specifically refers to:

[0036] Input all fragments into a scale-invariant embedding layer to obtain a semantic token sequence. ;

[0037]

[0038] In the formula, The fixed-dimensional representation of the first segment mapping. The fixed-dimensional representation of the second segment mapping. Let K be the fixed-dimensional representation of the Kth segment, where K is the number of segments. Each segment is mapped to a fixed-dimensional representation through a scale-invariant embedding layer, where the i-th segment... Fixed-dimensional representation of the mapping The specific expression is:

[0039]

[0040] In the formula, For linear projection or one-dimensional convolution encoders, It is an adaptive pooling operator in the time dimension.

[0041] The beneficial effects of the above-mentioned further scheme are as follows: The Affirm backbone network requires a fixed-dimensional token sequence as input. This invention introduces a scale-invariant embedding layer to map each variable-length segment to a fixed-dimensional representation. Specifically, the embedding process first performs projection encoding of the multi-channel sequence within the segment using shared parameters, and then performs pooling compression in the time dimension to eliminate length differences and obtain a fixed-length vector.

[0042] Furthermore: In S2, the backbone network of the Affirm model consists of N stacked network layers, each of which includes interconnected adaptive Fourier filter modules and interactive dual Mamba modules;

[0043] The workflow of the Affirm model is as follows: the semantic token sequence is input into N network layers in sequence. During the feature extraction process of each layer, the adaptive Fourier filter module highlights the periodic and trend components in the frequency domain, realizing deep feature interaction and filtering across channels. The interactive dual Mamba module models multi-scale contextual dependencies in the time domain, and captures rapidly changing details and slowly changing backgrounds through a dual-branch structure. After feature extraction through N network layers, the output features are obtained. The prediction head restores the output features to the target time axis and outputs the prediction of future load.

[0044] Furthermore, the specific workflow of the adaptive Fourier filter module is as follows:

[0045] A1. Perform a Fast Fourier Transform on the input features of the adaptive Fourier filter module to obtain the first feature;

[0046] A2. Adaptive high-pass and low-pass filtering is performed on the first feature using a learnable threshold to obtain the high-pass filtered feature and the low-pass filtered feature.

[0047] A3. Input the first feature, the high-pass filtered feature, and the low-pass filtered feature into three parallel lightweight linear layers respectively, learn the global, high-frequency and low-frequency filtering weights, and perform element-wise multiplication to obtain the second feature.

[0048] Among them, the calculation of the second feature The specific expression is:

[0049]

[0050] In the formula, As the first feature, These are the features after high-pass filtering. These are the features after low-pass filtering. For element-wise multiplication, It is a globally learnable frequency domain filter. It is a locally learnable frequency domain filter;

[0051] A4. Perform an inverse fast Fourier transform on the second feature to obtain the output feature of the adaptive Fourier filter module.

[0052] Furthermore, the workflow of the interactive dual Mamba module is as follows:

[0053] The input features of the interactive dual Mamba module are fed in parallel into two Mamba blocks with different causal convolution kernel sizes. The branches of the two Mamba blocks respectively characterize the more fine-grained and more coarse-grained temporal patterns. Then, multi-scale contextual information is fused through gating mechanisms or element-wise multiplication to generate the output features of the interactive dual Mamba module.

[0054] The beneficial effects of this invention are as follows: This invention provides a resource load prediction method based on the AMSP-Affirm framework. Data center resource load sequences often exhibit sudden peaks and long-term trends, accompanied by significant multi-scale fluctuations. This makes it difficult for prediction methods based on fixed-length slices to simultaneously capture two types of key information: excessively long slices weaken peak changes, while excessively short slices easily fragment contextual information. To address this, this invention designs an adaptive multi-scale prediction framework, AMSP Affirm, for green computing scenarios. The core idea of ​​this framework is to adjust the slice length according to data changes, rather than keeping it fixed. Specifically, when load changes drastically, fluctuates frequently, and has obvious peaks, shorter slices are used to capture key fluctuations more precisely; when load changes are relatively stable and trend-driven, longer slices are used to retain more complete long-term information and reduce computational burden. Subsequently, slices of different lengths are converted into a unified input representation format and then fed into an efficient prediction network for feature learning and multi-step prediction. In this way, the model can automatically adjust the observation scale according to the changing rhythm of different segments of the sequence, thereby simultaneously improving the ability to characterize peak intervals and maintain long-term trends. Compared with the prior art, the present invention has the following advantages:

[0055] (1) Design an adaptive multi-scale module. This module can automatically determine the slice boundary based on the degree of local change in the input sequence and generate dynamic segments of variable length. This allows the model to capture mutation information more meticulously in volatile segments and retain long-term trends more completely in relatively stable segments.

[0056] (2) An AMSP Affirm prediction framework for computing power scenarios is proposed, which combines adaptive multi-scale dynamic slicing with the efficient Affirm backbone model to improve the prediction effect of resource load sequences.

[0057] (3) Experimental results on real cluster datasets show that AMSP Affirm significantly reduces the MSE and MAE of the two evaluation metrics compared with the fixed slice strategy. This shows that introducing adaptive multi-scale slices and combining them with an efficient backbone network can effectively improve the accuracy of resource load prediction. Attached Figure Description

[0058] Figure 1 This is a flowchart of the resource load prediction method based on the AMSP-Affirm framework of the present invention.

[0059] Figure 2 This is a schematic diagram of the AMSP-Affirm framework of the present invention.

[0060] Figure 3 This is a schematic diagram of multi-scale patch partitioning. Detailed Implementation

[0061] The specific embodiments of the present invention are described below to enable those skilled in the art to understand the present invention. However, it should be understood that the present invention is not limited to the scope of the specific embodiments. For those skilled in the art, various changes are obvious as long as they are within the spirit and scope of the present invention as defined and determined by the appended claims. All inventions utilizing the concept of the present invention are protected.

[0062] like Figure 1 As shown, in one embodiment of the present invention, the resource load prediction method based on the AMSP-Affirm framework includes the following steps:

[0063] S1. Obtain the resource load sequence and input it into the Adaptive Multi-Scale (AMSP) module to generate a semantic token sequence;

[0064] S2. Input the semantic token sequence into the Affirm model and output a prediction of future load.

[0065] like Figure 2 As shown in this embodiment, the AMSP-Affirm framework is designed for high-precision prediction of multivariate time series. Its overall structure follows a dynamic divide-and-conquer approach. At the input layer, the multidimensional resource load sequence is first normalized and lightly denoised. Then, an innovative adaptive multi-scale module performs adaptive "semantic segmentation" on non-stationary signals in the time domain based on local fluctuation intensity and change patterns. This automatically determines segment boundaries, recombines the original long sequence into a short sequence composed of variable-length patches, and maps it to a token representation of uniform length through a scale-invariant embedding layer. The resulting semantic token sequence is fed into the efficient Affirm backbone network: on one hand, the Adaptive Fourier Filter Block (AFFB) highlights periodic and trend components in the frequency domain, enabling deep feature interaction and filtering across channels; on the other hand, the Interactive Dual Mamba Module (IDMB) models multi-scale contextual dependencies in the time domain, capturing rapidly changing details and gradually changing backgrounds through a dual-branch structure. Finally, the prediction head restores the target time axis, outputting a prediction of future loads, achieving a fine depiction of key peaks, troughs, and overall trends.

[0066] In S1, to balance the long-term trend and local burst characteristics in the data center load sequence, this embodiment designs an adaptive multi-scale module in the input layer. This module automatically adjusts the patch length based on the local non-stationarity of the sequence, representing stable segments with long patches and finely characterizing drastically fluctuating segments with short patches, thereby improving the model's ability to perceive multi-scale structures without significantly increasing computational overhead. The specific workflow of the adaptive multi-scale module is as follows:

[0067] S11. Perform time-frequency analysis on the resource load sequence using continuous wavelet transform, and calculate the wavelet coefficients of the resource load sequence;

[0068] S12. Calculate the segmentation score sequence based on the wavelet coefficients of the resource load sequence, as an indicator to characterize the strength of local nonstationarity;

[0069] S13. The segmentation score sequence is used as the segmentation score at each time step within the window, and the segmentation threshold of the window is calculated using an adaptive threshold mechanism based on window statistics.

[0070] S14. Dynamically segment the fragments using a sequential scanning strategy based on the window's segmentation threshold;

[0071] S15. Input all fragments into the scale-invariant embedding layer to obtain the semantic token sequence;

[0072] In this embodiment, the adaptive multi-scale module is the core innovative module of the present invention. In data center scenarios, resource load sequences often exhibit two typical characteristics simultaneously: on the one hand, medium- to long-term patterns such as daily and weekly cycles, dominated by human work and rest schedules and business patterns, give the load obvious periodicity and stability over a long time scale; on the other hand, short-term peaks and localized drastic fluctuations caused by sudden requests and concentrated task submissions exhibit strong non-stationarity over minute or even second-level time scales. Traditional fixed-period strategies face a dilemma: if a longer time window (e.g., 1 hour) is used to characterize the periodic trend of the load, short-term peaks will inevitably be "smoothed out," weakening the model's perception of key fluctuation segments; if a shorter time window (e.g., 5 minutes) is used to finely describe local changes, the sequence length will be significantly increased, increasing the computational overhead of Mamba or Transformer and weakening the modeling ability for long-term dependencies. To alleviate this problem, the present invention designs an adaptive multi-scale module AMSP with adaptive multi-scale partitioning, the partitioning diagram of which is shown below. Figure 3 As shown.

[0073] In S11, to quantify the local nonstationarity of the resource load sequence at different time points, this embodiment first uses continuous wavelet transform (CWT) to perform time-frequency analysis on the original sequence and calculate the resource load sequence. In scale ,time wavelet coefficients The specific expression is:

[0074]

[0075] In the formula, For the mother wavelet function, For the complex conjugate of the mother wavelet function, This is the integration variable, used to iterate over the signal across the entire time axis. Among them, scale By controlling the frequency, the shift parameter corresponds to the time position. Continuous wavelet transform can simultaneously characterize the local trend and high-frequency disturbances of the load signal.

[0076] In S12, to quantify the intensity of the time-frequency representation's change over time, this invention defines the segmentation scoring sequence as the norm of the rate of change of the time-frequency coefficients with respect to time, and calculates the segmentation scoring sequence based on the wavelet coefficients of the resource load sequence. The specific expression is:

[0077]

[0078] In the formula, The sign of the partial derivative. It is the Frobenius norm. Intuitively, if in time... If a mutation or mode switch occurs in a nearby sequence, its time-frequency structure will change significantly, leading to... The amplitude increases, thus If the value is large, then...; conversely, if the sequence is relatively stationary within this interval, then... It will remain at a low level. Therefore, It can serve as an indicator of the strength of local nonstationarity and provide a basis for subsequent patch boundary detection.

[0079] In S13, to avoid poor fit between different sequences due to the use of a fixed threshold, this invention introduces an adaptive threshold mechanism based on window statistics. The specific method of the adaptive threshold mechanism based on window statistics is as follows:

[0080] Let the set of time indices corresponding to the current input window be . The segmentation score at each time point within the window is recorded as follows: The mean and standard deviation of the ratings within the window are calculated, and then the window segmentation threshold is set. ;

[0081]

[0082] In the formula, This represents the average score within the window. The standard deviation of the scores within the window. This is a sensitivity coefficient used to adjust the aggressiveness of the segmentation;

[0083]

[0084] .

[0085] In this embodiment, the calculated window segmentation threshold is automatically updated according to the average level and fluctuation amplitude of the scores within the window, enabling the model to adaptively identify positions of significant change in the sequence with different fluctuation intensities.

[0086] S14 specifically refers to:

[0087] S141. Starting from the beginning of the resource load sequence, scan to the right and expand the current segment. Let the starting point of the current segment be... The current segment length is and set the minimum length and maximum length Constrain fragment length;

[0088] S142. Continuously expand the current segment and update the current segment length. In response to a segmentation score higher than the segmentation threshold of the current window and the current segment length... Not less than the minimum length If a significant structural change is detected at that location, segmentation is performed; in response to the current segment length... Reaching maximum length If so, then segmentation will be performed to avoid excessively long fragments;

[0089] S143. After segmentation, output the current segment and update the starting point of the next segment to... At the same time, reset the current segment length. Repeat the method in S142 to continuously generate fragments until the resource load sequence is scanned.

[0090] In this embodiment, the principle of dynamically segmenting segments using a sequential scanning strategy based on the segmentation threshold of the window is as follows: when the segmentation score is higher than the segmentation threshold of the current window and the segment length has reached the preset minimum length, it is determined that there is a significant structural change and truncation is performed; if the above conditions are not met, when the segment length grows to the preset maximum length, forced truncation is performed to avoid the segment from being too long.

[0091] This segmentation strategy generates a set of segments of variable length, where the segment length adaptively adjusts with local changes in the sequence. This segmentation strategy enables earlier truncation in regions with high intensity of change to improve the ability to characterize local structures, while in regions with gentler changes, it tends to form longer segments to retain more contextual information, thus obtaining a patch sequence with variable length characteristics.

[0092] S15 specifically refers to:

[0093] All segments are input into a scale-invariant embedding layer to obtain a semantic token sequence. This semantic token sequence allows the sequence length to adaptively change with the segmentation result while maintaining a fixed token dimension. It can be directly used as input to the subsequent Affirm backbone network. The specific expression is:

[0094]

[0095] In the formula, The fixed-dimensional representation of the first segment mapping. The fixed-dimensional representation of the second segment mapping. Let K be the fixed-dimensional representation of the Kth segment, where K is the number of segments, and each segment is mapped to a fixed-dimensional representation through a scale-invariant embedding layer;

[0096] In this embodiment, the Affirm backbone network requires a fixed-dimensional token sequence as input. This invention introduces a scale-invariant embedding layer to map each variable-length segment to a fixed-dimensional representation. Specifically, the embedding process first performs projection encoding on the multi-channel sequence within the segment using shared parameters, and then performs pooling compression in the time dimension to eliminate length differences and obtain a fixed-length vector. The i-th segment... Fixed-dimensional representation of the mapping The specific expression is:

[0097]

[0098] In the formula, For linear projection or one-dimensional convolution encoders, It is an adaptive pooling operator in the time dimension.

[0099] The semantic token sequence output by the adaptive multi-scale module is fed into the L-layer encoder backbone network based on the Affirm model. Each layer of the backbone network consists of an Adaptive Fourier Filter Block (AFFB) and an Interactive Dual Mamba Block (IDMB).

[0100] In S2, the backbone network of the Affirm model consists of N stacked network layers, each of which includes an interconnected adaptive Fourier filter module AFFB and an interactive dual Mamba module IDMB.

[0101] The workflow of the Affirm model is as follows: the semantic token sequence is input into N network layers in sequence. During the feature extraction process of each layer, the adaptive Fourier filter module highlights the periodic and trend components in the frequency domain, realizing deep feature interaction and filtering across channels. The interactive dual Mamba module models multi-scale contextual dependencies in the time domain, and captures rapidly changing details and slowly changing backgrounds through a dual-branch structure. After feature extraction through N network layers, the output features are obtained. The prediction head restores the output features to the target time axis and outputs the prediction of future load.

[0102] For the adaptive Fourier filter module, this module replaces the self-attention mechanism in the Transformer and completes global information exchange in the frequency domain. There is a strong synergy between AMSP and AFFB: AMSP cleanses the signal through dynamic segmentation in the time domain, isolating non-stationary abrupt changes into independent short patch tokens. Based on this, AFFB can more easily separate clear periodic components from noise components in the frequency domain because sudden changes (usually manifested as high-frequency noise) are locally encapsulated by AMSP without affecting the spectral representation of the entire sequence. The specific workflow of the adaptive Fourier filter module is as follows:

[0103] A1. Perform a Fast Fourier Transform (FFT) on the input features of the adaptive Fourier filter module to obtain the first feature;

[0104] A2. Adaptive high-pass (HPF) and low-pass (LPF) filtering is applied to the first feature using a learnable threshold to obtain the high-pass filtered feature and the low-pass filtered feature.

[0105] A3. Input the first feature, the high-pass filtered feature, and the low-pass filtered feature into three parallel lightweight linear layers respectively, learn the global, high-frequency and low-frequency filtering weights, and perform element-wise multiplication to obtain the second feature.

[0106] Among them, the calculation of the second feature The specific expression is:

[0107]

[0108] In the formula, As the first feature, These are the features after high-pass filtering. These are the features after low-pass filtering. For element-wise multiplication, It is a globally learnable frequency domain filter. It is a locally learnable frequency domain filter;

[0109] A4. Perform an inverse fast Fourier transform on the second feature to obtain the output feature of the adaptive Fourier filter module.

[0110] For the interactive dual Mamba module, this module replaces the feedforward network in the Transformer to capture local and global temporal dependencies in the patch token sequence. Following Affirm's design, IDMB employs a dual-branch Mamba structure: input from AFFB... Two Mamba blocks with different causal kernel sizes are fed in parallel. The two branches respectively characterize finer-grained and coarser-grained temporal patterns, and then multi-scale contextual information is fused through gating mechanisms or element-wise multiplication. The specific workflow of the interactive dual-Mamba module is as follows:

[0111] The input features of the interactive dual Mamba module are fed in parallel into two Mamba blocks with different causal convolution kernel sizes. The branches of the two Mamba blocks respectively characterize the more fine-grained and more coarse-grained temporal patterns. Then, multi-scale contextual information is fused through gating mechanisms or element-wise multiplication to generate the output features of the interactive dual Mamba module.

[0112] Overall, the AMSP-Affirm framework achieves end-to-end multi-scale processing: dynamic multi-scale segmentation based on signal non-stationarity is performed at the input end (AMSP); static multi-scale feature extraction is performed at the feature end (IDMB) based on the Mamba convolution kernel size. This dual multi-scale design has better robustness than a single multi-scale strategy.

[0113] To verify the effectiveness of this invention, experiments were conducted on real cluster datasets. The prediction results are shown in Tables 1 and 2. The experimental results on the Google Cluster Tracking and Alibaba Cluster Tracking datasets show that AMSP-Affirm achieves a performance improvement compared to the state-of-the-art baseline PatchTST algorithm: the average MSE values ​​on the two datasets decreased by 4.0% and 4.2%, respectively. The results indicate that AMSP-Affirm can better balance peak fluctuations and trend information in prediction tasks, and is suitable for resource load prediction tasks in green computing scenarios.

[0114] Table 1. Prediction results from the Google dataset

[0115]

[0116] Table 2. Prediction Results from Alibaba Dataset

[0117]

[0118] In the description of this invention, the above are merely preferred embodiments and are not intended to limit the scope of protection of this invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this invention should be included within the scope of protection of this invention.

Claims

1. A resource load forecasting method based on the AMSP-Affirm framework, characterized in that, Includes the following steps: S1. Obtain the resource load sequence and input it into the adaptive multi-scale module to generate a semantic token sequence; S2. Input the semantic token sequence into the Affirm model and output a prediction of future load.

2. The resource load forecasting method based on the AMSP-Affirm framework according to claim 1, characterized in that, In S1, the workflow of the adaptive multi-scale module is as follows: S11. Perform time-frequency analysis on the resource load sequence using continuous wavelet transform, and calculate the wavelet coefficients of the resource load sequence; S12. Calculate the segmentation score sequence based on the wavelet coefficients of the resource load sequence, as an indicator to characterize the strength of local nonstationarity; S13. The segmentation score sequence is used as the segmentation score at each time step within the window, and the segmentation threshold of the window is calculated using an adaptive threshold mechanism based on window statistics. S14. Dynamically segment the fragments using a sequential scanning strategy based on the window's segmentation threshold; S15. Input all fragments into the scale-invariant embedding layer to obtain the semantic token sequence.

3. The resource load forecasting method based on the AMSP-Affirm framework according to claim 2, characterized in that, In S11, the resource load sequence is calculated. In scale ,time wavelet coefficients The specific expression is: In the formula, For the mother wavelet function, For the complex conjugate of the mother wavelet function, This is the integration variable, used to iterate over the signal across the entire time axis. .

4. The resource load forecasting method based on the AMSP-Affirm framework according to claim 3, characterized in that, In S12, the segmentation scoring sequence is calculated based on the wavelet coefficients of the resource load sequence. The specific expression is: In the formula, The sign of the partial derivative. It is the Frobenius norm.

5. The resource load forecasting method based on the AMSP-Affirm framework according to claim 4, characterized in that, In S13, the method using an adaptive threshold mechanism based on window statistics is as follows: Let the set of time indices corresponding to the current input window be . The segmentation score at each time point within the window is recorded as follows: The mean and standard deviation of the ratings within the window are calculated, and then the window segmentation threshold is set. ; In the formula, This represents the average score within the window. The standard deviation of the scores within the window. This is a sensitivity coefficient used to adjust the aggressiveness of the segmentation; 。 6. The resource load forecasting method based on the AMSP-Affirm framework according to claim 5, characterized in that, S14 specifically refers to: S141. Starting from the beginning of the resource load sequence, scan to the right and expand the current segment. Let the starting point of the current segment be... The current segment length is and set the minimum length and maximum length Constrain fragment length; S142. Continuously expand the current segment and update the current segment length. In response to a segmentation score higher than the segmentation threshold of the current window and the current segment length... Not less than the minimum length If so, it is determined that there is a significant structural change at that location and a segmentation is performed; Responding to the current fragment length Reaching maximum length If so, then the splitting will be performed; S143. After segmentation, output the current segment and update the starting point of the next segment to... At the same time, reset the current segment length. Repeat the method in S142 to continuously generate fragments until the resource load sequence is scanned.

7. The resource load forecasting method based on the AMSP-Affirm framework according to claim 6, characterized in that, S15 specifically refers to: Input all fragments into a scale-invariant embedding layer to obtain a semantic token sequence. ; In the formula, The fixed-dimensional representation of the first segment mapping. The fixed-dimensional representation of the second segment mapping. Let K be the fixed-dimensional representation of the Kth segment, where K is the number of segments. Each segment is mapped to a fixed-dimensional representation through a scale-invariant embedding layer, where the i-th segment... Fixed-dimensional representation of mapping The specific expression is: In the formula, For linear projection or one-dimensional convolution encoders, It is an adaptive pooling operator in the time dimension.

8. The resource load forecasting method based on the AMSP-Affirm framework according to claim 6, characterized in that, In S2, the backbone network of the Affirm model consists of N stacked network layers, each of which includes an interconnected adaptive Fourier filter module and an interactive dual Mamba module. The workflow of the Affirm model is as follows: the semantic token sequence is input into N network layers in sequence. During the feature extraction process of each layer, the adaptive Fourier filter module highlights the periodic and trend components in the frequency domain, realizing deep feature interaction and filtering across channels. The interactive dual Mamba module models multi-scale contextual dependencies in the time domain, and captures rapidly changing details and slowly changing backgrounds through a dual-branch structure. After feature extraction through N network layers, the output features are obtained. The prediction head restores the output features to the target time axis and outputs the prediction of future load.

9. The resource load forecasting method based on the AMSP-Affirm framework according to claim 8, characterized in that, The workflow of the adaptive Fourier filter module is as follows: A1. Perform a Fast Fourier Transform on the input features of the adaptive Fourier filter module to obtain the first feature; A2. Adaptive high-pass and low-pass filtering is performed on the first feature using a learnable threshold to obtain the high-pass filtered feature and the low-pass filtered feature. A3. Input the first feature, the high-pass filtered feature, and the low-pass filtered feature into three parallel lightweight linear layers respectively, learn the global, high-frequency and low-frequency filtering weights, and perform element-wise multiplication to obtain the second feature. Among them, the calculation of the second feature The specific expression is: In the formula, As the first feature, These are the features after high-pass filtering. These are the features after low-pass filtering. For element-wise multiplication, It is a globally learnable frequency domain filter. It is a locally learnable frequency domain filter; A4. Perform an inverse fast Fourier transform on the second feature to obtain the output feature of the adaptive Fourier filter module.

10. The resource load forecasting method based on the AMSP-Affirm framework according to claim 8, characterized in that, The workflow of the interactive dual Mamba module is as follows: The input features of the interactive dual Mamba module are fed in parallel into two Mamba blocks with different causal convolution kernel sizes. The branches of the two Mamba blocks respectively characterize the more fine-grained and more coarse-grained temporal patterns. Then, multi-scale contextual information is fused through gating mechanisms or element-wise multiplication to generate the output features of the interactive dual Mamba module.