Computing power task execution method and device, computer equipment, readable storage medium and program product
By using the Long Short-Term Memory-Transformer model and a multi-factor selection model to screen suitable computing power clusters, the problem of resource waste in existing technologies is solved, and efficient resource utilization and cost savings are achieved.
Patent Information
- Application Number
- CN202511328851.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-17
- Publication Date
- 2026-01-13
AI Technical Summary
Existing computing power scheduling schemes have failed to effectively avoid the waste of computing and power resources, resulting in low resource utilization efficiency during the execution of computing tasks.
By acquiring task description data and requirement data for the target computing power task, the resource requirements are predicted using the Long Short-Term Memory-Transformer model. Based on the multi-factor selection model, the most suitable target computing power cluster is selected from multiple initial computing power clusters for task allocation. Resource optimization is carried out in combination with electricity unit price and carbon emission constraints.
It maximizes the utilization of computing and power resources, reduces costs and carbon emissions, and optimizes the resource allocation process.
Smart Images

Figure CN121328620A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the cross-technical field of cloud computing resource scheduling and energy management, and in particular to a computing power task execution method, apparatus, computer equipment, readable storage medium, and program product. Background Technology
[0002] With the large-scale deployment of AI inference tasks, the demand for heterogeneous computing power on GPUs (Graphics Processing Units) has surged. Existing computing power scheduling schemes only consider whether the computing task can be completed, without taking into account the potential waste of computing and power resources during the execution of the task. Summary of the Invention
[0003] Therefore, it is necessary to provide a computing task execution method, apparatus, computer equipment, readable storage medium, and program product that can avoid resource waste in order to address the above-mentioned technical problems.
[0004] Firstly, this application provides a method for executing computing power tasks, the method comprising:
[0005] Obtain the task description data and task requirement data of the target computing power task, and obtain the available computing power resources of any initial computing power cluster at the current time and at multiple times after the current time; wherein, the task description data includes task attribute parameters, input data feature parameters, task operation rule parameters and precision filtering parameters, and the task requirement data includes latency requirement data, cost constraints and carbon emission constraints.
[0006] The task description data is input into the Long Short-Term Memory-Transformer model, which outputs the computing resource requirements, predicted execution time range, and predicted power consumption of the target computing task.
[0007] Based on the task description data, the task requirement data, the computing power resource requirement data, the predicted execution duration range, the predicted power consumption, and the available computing power resources, at least one intermediate computing power cluster is determined from multiple initial computing power clusters, and the predicted execution period for the intermediate computing power cluster to execute the target computing power task is determined.
[0008] A target computing power cluster is selected from the at least one intermediate computing power cluster, and the target computing power task is assigned to the target computing power cluster during the corresponding prediction execution period of the target computing power cluster.
[0009] In one embodiment, the step of determining at least one intermediate computing power cluster from multiple initial computing power clusters based on the task description data, the task requirement data, the computing power resource requirement data, the predicted execution duration range, the predicted power consumption, and the available computing power resources, and the predicted execution period for the intermediate computing power cluster to execute the target computing power task, includes:
[0010] Obtain the identifier of any initial computing cluster;
[0011] The task description data, task requirement data, computing resource requirement data, predicted execution duration range, predicted power consumption, available computing resources, and the identifier of the initial computing cluster are input into the multi-factor selection model, and the identifier of the intermediate computing cluster and the predicted execution period are output.
[0012] In one embodiment, selecting a target computing power cluster from the at least one intermediate computing power cluster includes:
[0013] For any intermediate computing power cluster, obtain the electricity unit price within the corresponding prediction execution period of the intermediate computing power cluster;
[0014] Based on the electricity unit price and the corresponding duration of the predicted execution period, determine the total cost of the intermediate computing power cluster executing the target computing power task;
[0015] The intermediate computing power cluster with the lowest total cost is identified as the target computing power cluster.
[0016] In one embodiment, the method further includes:
[0017] Obtain the static basic data of the target computing power cluster, and during the execution of the target computing power task on the target computing power cluster, obtain the computing power resource status data of the target computing power cluster in real time;
[0018] After the target computing power task is completed, obtain the actual power consumption of the target computing power task.
[0019] The task description data, the static basic data, the computing power resource status data, and the predicted and actual consumption of electricity resources are input into the Long Short-Term Memory-Transformer model to obtain the trained Long Short-Term Memory-Transformer model.
[0020] In one embodiment, the step of inputting the task description data, the static basic data, the computing resource status data, and the predicted and actual consumption of electricity resources into the Long Short-Term Memory-Transformer model to obtain the trained Long Short-Term Memory-Transformer model includes:
[0021] For any training epoch in the training process of the Long Short-Term Memory-Transformer model, if the loss values of the training epoch and the corresponding loss values of the preset number of historical training epochs before the training epoch are all within the preset loss value range, the Long Short-Term Memory-Transformer model obtained in the training epoch will be determined as the trained Long Short-Term Memory-Transformer model.
[0022] In one embodiment, the method further includes:
[0023] For the execution end time of the target computing power task, obtain the load data of the power grid in multiple time periods after the execution end time;
[0024] The period with the least amount of data load is identified as the target period, and the training task of the Long Short-Term Memory-Transformer model is performed within the target period.
[0025] Secondly, this application also provides a computing power task execution device, the device comprising:
[0026] The acquisition module is used to acquire task description data and task requirement data of the target computing power task, and to acquire the available computing power resources of any initial computing power cluster at the current time and at multiple times after the current time; wherein, the task description data includes task attribute parameters, input data feature parameters, task operation rule parameters and precision filtering parameters, and the task requirement data includes latency requirement data, cost constraints and carbon emission constraints.
[0027] The input module is used to input the task description data into the Long Short-Term Memory-Transformer model and output the computing resource requirements data, predicted execution time range, and predicted power consumption of the target computing task.
[0028] The determination module is used to determine at least one intermediate computing power cluster from multiple initial computing power clusters, and the predicted execution period for the intermediate computing power cluster to execute the target computing power task, based on the task description data, the task requirement data, the computing power resource requirement data, the predicted execution duration range, the predicted power consumption, and the available computing power resources.
[0029] The filtering module is used to select a target computing power cluster from the at least one intermediate computing power cluster, and to allocate the target computing power task to the target computing power cluster within the corresponding prediction execution period of the target computing power cluster.
[0030] Thirdly, this application also provides a computer device. The computer device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the steps of the methods in any of the above embodiments.
[0031] Fourthly, this application also provides a computer-readable storage medium. The computer-readable storage medium stores a computer program thereon, which, when executed by a processor, implements the steps of the methods in any of the above embodiments.
[0032] Fifthly, this application also provides a computer program product. The computer program product includes a computer program that, when executed by a processor, implements the steps of the methods in any of the above embodiments.
[0033] The aforementioned computing power task execution method, apparatus, computer equipment, readable storage medium, and program product acquire task description data and task requirement data of the target computing power task, and acquire the available computing power resources of any initial computing power cluster at the current time and at multiple times after the current time. The task description data includes task attribute parameters, input data feature parameters, task operation rule parameters, and precision filtering parameters; the task requirement data includes latency requirement data, cost constraints, and carbon emission constraints. The task description data is input into a Long Short-Term Memory-Transformer model, which outputs the computing power resource requirement data, predicted execution duration range, and predicted power consumption of the target computing power task. Based on the task description data, task requirement data, computing power resource requirement data, predicted execution duration range, predicted power consumption, and available computing power resources, at least one intermediate computing power cluster and the predicted execution period for the target computing power task are determined from multiple initial computing power clusters. A target computing power cluster is selected from the at least one intermediate computing power cluster, and the target computing power task is allocated to the target computing power cluster within its corresponding predicted execution period. The method provided in this application selects target computing clusters for executing target computing tasks based on task description data, task requirement data, computing resource requirement data, predicted execution duration range, predicted power consumption, and available computing resources. This method schedules target computing tasks to target computing clusters, which can minimize the waste of computing and power resources, save costs as much as possible, and reduce carbon emissions. Attached Figure Description
[0034] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0035] Figure 1 This is a flowchart illustrating a computing task execution method in one embodiment;
[0036] Figure 2 This is a flowchart illustrating a method for determining intermediate computing power clusters in one embodiment;
[0037] Figure 3 This is a flowchart illustrating the computing task execution method in another embodiment;
[0038] Figure 4 This is a structural block diagram of a computing task execution device in one embodiment;
[0039] Figure 5 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation
[0040] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0041] It should be noted that the terms "first," "second," etc., used in this application can be used to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from the second element. The terms "comprising" and "having," and any variations thereof, used in this application, are intended to cover non-exclusive inclusion. The term "multiple" used in this application refers to two or more. The term "and / or" used in this application refers to one of the embodiments, or any combination of multiple embodiments.
[0042] In one embodiment, such as Figure 1 As shown, a method for executing computing tasks is provided. This embodiment illustrates the application of this method to a terminal. It is understood that this method can also be applied to a server, and further to a system including both a terminal and a server, and is implemented through interaction between the terminal and the server. In this embodiment, the method includes the following steps:
[0043] S102. Obtain the task description data and task requirement data of the target computing power task, and obtain the available computing power resources of any initial computing power cluster at the current time and at multiple times after the current time; wherein, the task description data includes task attribute parameters, input data feature parameters, task operation rule parameters and precision filtering parameters, and the task requirement data includes latency requirement data, cost constraints and carbon emission constraints.
[0044] The task description data refers to a set of structured information that fully defines the technical attributes, operating logic, and core features of the target computing power task. The task attribute parameters may include, but are not limited to, the algorithm name, underlying model, parameter scale, number of neural network layers, and number of hidden layers of the algorithm that executes the target computing power task. The input data feature parameters may include, but are not limited to, the size of the algorithm dataset and the input resolution. The task operation rule parameters may include, but are not limited to, the time window size, decay rate, and number of anchor boxes. The precision screening parameters may include, but are not limited to, the confidence threshold.
[0045] The latency requirements may include, but are not limited to, real-time requirements, batch processing requirements, and sensitivity requirements. Real-time requirements refer to the need for the target computing power task to complete processing and return results in a very short time, emphasizing "instant response." Batch processing requirements refer to the need for the target computing power task to not require an instant response, allowing multiple similar tasks or data to be accumulated to a certain amount before being processed in batches. Sensitivity requirements refer to the degree to which a task is sensitive to latency, i.e., the degree to which the magnitude of latency affects the task's effectiveness or value. Cost constraints may include, but are not limited to, electricity unit price and computing power cost thresholds. The computing power cost threshold refers to the maximum cost that a user or system can accept during the deployment of the target computing power task, and is a key economic indicator used to constrain the execution cost of the task. Carbon emission constraints include carbon emission indicators and carbon emission coefficients. Carbon emission indicators refer to the maximum allowable carbon emission limit for completing a specific computing power task, and are a binding indicator for the task in terms of carbon emissions. Carbon emission coefficients refer to the carbon emissions corresponding to a unit of energy consumption, used to quantify the carbon emission intensity of different energy sources or equipment.
[0046] Optionally, the initial computing power cluster may be executing other computing power tasks. Therefore, by analyzing the computing power tasks currently being executed by the initial computing power cluster, the available computing power resources that the initial computing power cluster can provide for the target computing power task can be determined.
[0047] S104. Input the task description data into the Long Short-Term Memory-Transformer model, and output the computing resource requirements of the target computing task, the predicted execution time range, and the predicted power consumption.
[0048] Among them, the Long Short Short-Term Memory (LSTM)-Transformer model is a hybrid deep learning model that combines the advantages of the Long Short Short-Term Memory network and the Transformer architecture, and is mainly used to process sequential data; the computing resource requirements data may include, but are not limited to, the GPU model, CPU model, memory capacity and storage configuration required during the execution of the target computing task.
[0049] Optionally, in order to make the obtained computing power resource demand data, predicted execution time range and predicted power consumption more accurate, in addition to inputting the task description data into the Long Short-Term Memory-Transformer model, it is also necessary to input the algorithm complexity of the algorithm used to execute the target computing power task, the data volume of the target computing power task, and the energy efficiency ratio of historical computing power tasks into the Long Short-Term Memory-Transformer model.
[0050] S106. Based on task description data, task requirement data, computing power resource requirement data, predicted execution duration range, predicted power consumption, and available computing power resources, determine at least one intermediate computing power cluster from multiple initial computing power clusters, and the predicted execution period for the intermediate computing power cluster to execute the target computing power task.
[0051] Optionally, in order to balance the impact of different factors on the selection process of computing power clusters, and to ensure that the intermediate computing power clusters selected by the selection process can execute the target computing power task, the target computing power task can simultaneously meet the requirements of computing power resources, electricity costs, resource utilization, and carbon emissions. Therefore, it is necessary to select an appropriate weight value for each of the task description data, task requirement data, computing power resource requirement data, predicted execution duration range, predicted electricity consumption, and available computing power resources, and select intermediate computing power clusters and corresponding predicted execution periods through the corresponding weight values.
[0052] S108. Select a target computing power cluster from at least one intermediate computing power cluster, and allocate the target computing power task to the target computing power cluster within the corresponding prediction execution period of the target computing power cluster.
[0053] Optionally, the execution cost of using each intermediate computing power cluster to execute the target computing power task can be predicted first, and the intermediate computing power cluster with the lowest execution cost can be determined as the target computing power cluster.
[0054] In the aforementioned method for executing computing power tasks, the task description data and task requirement data of the target computing power task are obtained, and the available computing power resources of any initial computing power cluster at the current time and at multiple times after the current time are obtained. The task description data includes task attribute parameters, input data feature parameters, task operation rule parameters, and precision filtering parameters; the task requirement data includes latency requirement data, cost constraints, and carbon emission constraints. The task description data is input into a Long Short-Term Memory-Transformer model, which outputs the computing power resource requirement data, predicted execution duration range, and predicted power consumption of the target computing power task. Based on the task description data, task requirement data, computing power resource requirement data, predicted execution duration range, predicted power consumption, and available computing power resources, at least one intermediate computing power cluster and the predicted execution period for the target computing power task are determined from multiple initial computing power clusters. A target computing power cluster is selected from the at least one intermediate computing power cluster, and the target computing power task is allocated to the target computing power cluster within its corresponding predicted execution period. The method provided in this application selects target computing clusters for executing target computing tasks based on task description data, task requirement data, computing resource requirement data, predicted execution duration range, predicted power consumption, and available computing resources. This method schedules target computing tasks to target computing clusters, which can minimize the waste of computing and power resources, save costs as much as possible, and reduce carbon emissions.
[0055] In some embodiments, such as Figure 2 As shown, based on task description data, task requirement data, computing resource requirement data, predicted execution duration range, predicted power consumption, and available computing resources, at least one intermediate computing cluster is determined from multiple initial computing clusters, along with the predicted execution period for the intermediate computing cluster to execute the target computing task, including:
[0056] S202. Obtain the identifier of any initial computing power cluster.
[0057] S204. Input the task description data, task requirement data, computing resource requirement data, predicted execution duration range, predicted power consumption, available computing resources, and the identifier of the initial computing cluster into the multi-factor selection model, and output the identifier of the intermediate computing cluster and the predicted execution period.
[0058] Among them, the multi-factor selection model is a decision-making model that comprehensively considers multiple key factors to evaluate, screen and match computing power clusters. Its core function is to select the most suitable cluster from available computing power resources based on the various characteristics and requirements of the task, and predict the execution period of the task.
[0059] In this embodiment, task description data, task requirement data, computing resource requirement data, predicted execution duration range, predicted power consumption, available computing resources, and the identifier of the initial computing cluster are input into the multi-factor selection model. The model outputs the identifier of the intermediate computing cluster and the predicted execution period, so that the target computing task can be executed by the selected intermediate computing cluster, which can simultaneously meet the target computing task's requirements for computing resources, electricity costs, resource utilization, and carbon emissions.
[0060] In some embodiments, selecting a target computing power cluster from at least one intermediate computing power cluster includes: for any intermediate computing power cluster, obtaining the electricity unit price within the corresponding predicted execution period of the intermediate computing power cluster; determining the total cost of the intermediate computing power cluster executing the target computing power task based on the electricity unit price and the corresponding duration of the predicted execution period; and determining the intermediate computing power cluster with the lowest corresponding total cost as the target computing power cluster.
[0061] Optionally, by comparing the electricity unit price of different intermediate computing power clusters during the corresponding predicted execution period, the intermediate computing power cluster with the lowest electricity cost can be selected to execute the target computing power task.
[0062] In this embodiment, the total cost is calculated based on the electricity unit price and execution time. The cluster with the lowest cost is selected first, which directly optimizes the execution cost of computing tasks and reduces economic investment.
[0063] In some embodiments, the method further includes: acquiring static basic data of the target computing power cluster, and acquiring computing resource status data of the target computing power cluster in real time during the execution of the target computing power task; acquiring the actual power consumption of the target computing power task after the execution of the target computing power task; and inputting the task description data, static basic data, computing resource status data, and the predicted and actual power consumption into the Long Short-Term Memory-Transformer model to obtain the trained Long Short-Term Memory-Transformer model.
[0064] Optionally, static basic data may include, but is not limited to, cluster name, cluster monitoring address and port, cluster version, node name, node model, pod (the smallest deployment and scheduling unit in the cluster) name, pod address, CPU model, number of CPU cores, memory size, GPU model, and video memory size.
[0065] Optionally, the computing resource status data may include, but is not limited to, CPU utilization, memory utilization, temporary storage utilization, GPU utilization, video memory utilization, GPU power consumption, GPU temperature, and CPU power consumption.
[0066] In this embodiment, the Long Short-Term Memory-Transformer model is trained based on task description data, static basic data, computing resource status data, and the predicted and actual consumption of power resources, which enables more accurate optimization of the model.
[0067] In some embodiments, task description data, static basic data, computing resource status data, and predicted and actual power consumption are input into a Long Short-Term Memory-Transformer model to obtain a trained Long Short-Term Memory-Transformer model. This includes: for any training epoch in the training process of the Long Short-Term Memory-Transformer model, if the loss values of the training epoch and the predetermined number of historical training epochs before the training epoch are all within a predetermined loss value range, the Long Short-Term Memory-Transformer model obtained in the training epoch is determined as the trained Long Short-Term Memory-Transformer model.
[0068] Optionally, the Long Short-Term Memory-Transformer model includes an input layer, a multi-source data fusion module, a positional encoding enhancement module, an LSTM module, a Transformer module, and an output layer arranged sequentially. The input layer is used to input multi-dimensional time series data of real-time performance (CPU / GPU utilization, power consumption, etc.) and task specification data (such as parameter count and number of layers). The multi-source data fusion module integrates multi-dimensional temporal features of task specification data (such as algorithm parameter scale and neural network layer count), runtime environment data (such as GPU model and memory size), and real-time performance data (such as CPU / GPU utilization). The positional encoding enhancement module generates positional encoding using sine / cosine functions to address the Transformer's insensitivity to temporal position. The LSTM module captures temporal dependencies and extracts short-term dynamic features. The Transformer module captures long-term dependencies through a self-attention mechanism to enhance global feature interaction. The output layer predicts power consumption values for future time steps.
[0069] Optionally, the Long Short-Term Memory-Transformer model is configured with a loss function, an optimizer, and hyperparameters; wherein the loss function is mean squared error (MSE), the optimizer is AdamW (Adam with Weight Decay, a deep learning optimization algorithm based on the Adam optimizer) (initial learning rate 1e-4, weight decay 1e-5), and the hyperparameters include the time window length (e.g., 60 minutes), the hidden layer dimension (256), the number of attention heads (8), and the Dropout (a regularization technique) rate (0.1).
[0070] In this embodiment, if the loss values of the training rounds and the preset number of historical training rounds before the training rounds are all within the preset loss value range, the long short-term memory-transformer model obtained in the training rounds will be determined as the trained long short-term memory-transformer model, which can accurately determine whether the model has converged.
[0071] In some embodiments, the method further includes: acquiring load data of the power grid in multiple time periods after the execution end time of the target computing task; determining the time period with the minimum load data as the target time period; and performing the training task of the Long Short-Term Memory-Transformer model within the target time period.
[0072] Optionally, the Long Short-Term Memory-Transformer model can be trained when the grid load is at its lowest, by using the principle of peak shaving and valley filling.
[0073] In this embodiment, the period with the minimum load data is determined as the target period, and the training task of the Long Short-Term Memory-Transformer model is performed within the target period, which can achieve coordinated optimization of computing power consumption and power grid load.
[0074] In one exemplary embodiment, such as Figure 3 As shown, another method for executing computing power tasks is provided, including the following:
[0075] Module 1: Task Feature Parsing Module. Function: Parses the requirements into structured feature vectors.
[0076] Input source: Computing power application platform.
[0077] Input content: Deployment requirements for computing power tasks, including:
[0078] Task description data includes: algorithm name, algorithm base model, algorithm parameter scale, algorithm dataset size, number of neural network layers, number of hidden layers, decay rate, time window size, input resolution, number of anchor boxes, confidence threshold, etc.
[0079] Task four-dimensional requirements:
[0080] Computing power requirements: GPU / CPU / Memory / Storage.
[0081] Latency characteristics: Real-time / Batch processing / Sensitivity.
[0082] Economic constraints: Electricity unit price / computing power cost threshold.
[0083] Carbon emission requirements: carbon emission indicators, carbon emission coefficients.
[0084] Output: The driving multi-factor selection algorithm.
[0085] Module 2: Requirements and Configuration Data Acquisition Module. Function: Responsible for collecting static data such as task specifications and runtime environment data. It interfaces with the task feature parsing module and can obtain data through message interface listening or log files. The requirements module only needs to acquire task description data, while the configuration data is the actual runtime configuration of the task obtained from the computing power execution module.
[0086] Runtime environment data: After matching computing resources with application requirements, the computing power scheduling platform allocates them to specific computing power nodes and launches the application image. Runtime environment data mainly consists of static hardware and software environment data, including cluster name, cluster monitoring address and port, cluster version, node name, node model, pod name, pod address, CPU model, number of CPU cores, memory size, GPU model, and video memory size.
[0087] Module 3: Task Calculation Submodule. Its main function is to predict the resource usage time required for a task, which serves as the input for a multi-factor algorithm.
[0088] {Resource estimation} = {Algorithm complexity} * {Data volume} / {Historical energy efficiency ratio}
[0089] The original LSTM-Transformer model is invoked to predict the duration of resource usage.
[0090] The task calculation submodule and the AI learning and training module perform inference and prediction after completing the training model and prediction request.
[0091] Module 4: Multi-factor selection algorithm. Function: Through a dynamic weighted scoring model, it intelligently selects the globally optimal computing cluster for computing tasks while meeting diverse task requirements.
[0092] {Cluster Score} = alpha{Cost} + beta{Latency} + {Carbon Footprint} where α, β, and γ are dynamic weights that are adaptive to the task features.
[0093] Module 5: Real-time runtime data acquisition module. Function: Responsible for collecting real-time data during task execution, and connecting through the Promethues data interface. The cluster reports real-time runtime data of the node where the task is located during task execution to the task feature learning and prediction module through the cluster monitoring address and port. This includes CPU utilization, memory utilization, temporary storage utilization, GPU utilization, video memory utilization, GPU power consumption, GPU temperature, and CPU power consumption.
[0094] Module Six: Data Preprocessing Module. Function: Responsible for data cleaning and characterization operations. Data sources are primarily the computing power scheduling platform and the computing power clusters actually running the tasks. The computing power scheduling platform refers to any business platform that receives application requests and deploys the application images provided by the requesting party to the computing power cluster. The computing power cluster refers to a single or cascaded Kubernetes cluster. Data cleaning and characterization:
[0095] Multi-source data integration and entity alignment: Constructing a unified feature view across data sources to solve the problem of heterogeneous data association. Key operations: Entity identification and matching: Establishing a full lifecycle tracking link for tasks by associating user requirements (data source 1) with scheduling results through task_id (task identifier) (data source 2). Aligning hardware resource allocation and real-time monitoring data based on pod_name (container group name) and cluster_node (cluster node) (data sources 2, 3) to verify resource usage consistency. Time-series data alignment: Aggregating Prometheus second-level sampled data (data source 3) with minute-level records from the scheduling module (data source 2) through time windows to generate minute-level features (such as avg_power_consumption (average power consumption)).
[0096] Further, data transformation and feature engineering are performed, with the goal of converting the raw data into numerical features suitable for model training. Key operations include: normalization of numerical fields; GPU computing power related fields: performing heterogeneous chip computing power equivalence conversion on nvidia_gpu and huawei_ascend_gpu (e.g., 1 A100 = 3 Ascend910s); and using Z-score normalization to process cpu_usage and memory_usage to eliminate the impact of hardware configuration differences.
[0097] Quality Control and Iterative Optimization: Objective: Establish an automated monitoring and feedback mechanism for the preprocessing workflow. Key Operations: Data Quality Indicators: Define thresholds for completeness (missing rate <5%), consistency (entity matching accuracy >98%), and timeliness (data latency <1 minute). Use data lineage tracing technology to mark abnormal data processing paths, supporting source tracing and correction. Online Learning Adaptation: Trigger dynamic updates of feature-equivalent computing power parameters when hardware models are upgraded (e.g., adding a new GPU type). Recalculate standardized parameters (e.g., the mean and variance of Z-score) using a sliding window mechanism to adapt to data distribution drift. Heterogeneous Data Fusion: Solve the correlation problem of multi-source data (structured requirement data, semi-structured scheduling logs, time-series monitoring data) through entity alignment and time window aggregation. Energy Efficiency Feature Construction: Introduce composite indicators such as energy_efficiency_ratio to quantify the coupling relationship between hardware energy efficiency and task characteristics, improving the interpretability of the prediction model.
[0098] Module 7: AI Learning and Training Module. Function: Initial training of the model is achieved by running an LSTM-Transformer joint model. Incremental training is performed after accumulating sufficient new data over a fixed period. Model optimization is then conducted based on user feedback. The trained model is output to the task evaluation submodule for task evaluation. Overall training method: LSTM-Transformer prediction model configuration:
[0099] 1. Algorithm Objective
[0100] Predict power consumption during task execution to optimize computing resource allocation and energy costs.
[0101] 2. Model Architecture
[0102] Input layer: Multidimensional time series of real-time performance data (CPU / GPU utilization, power consumption, etc.) and task specification data (such as parameter quantity, number of layers).
[0103] Multi-source data fusion: The input layer integrates multi-dimensional time-series features of task specification data (such as algorithm parameter scale and number of neural network layers), runtime environment data (such as GPU model and memory size), and real-time performance data (such as CPU / GPU utilization).
[0104] Enhanced Positional Encoding: Positional encoding is generated using sine / cosine functions to address the Transformer's insensitivity to temporal position.
[0105] LSTM module: Captures temporal dependencies and extracts short-term dynamic features.
[0106] The Transformer module captures long-term dependencies through a self-attention mechanism, enhancing global feature interactions.
[0107] Output layer: The regression layer predicts the power consumption value at future time steps.
[0108] 3. Key Configurations
[0109] Loss function: Mean Squared Error (MSE).
[0110] Optimizer: AdamW (initial learning rate 1e-4, weight decay 1e-5).
[0111] Hyperparameters: Time window length (e.g., 60 minutes), hidden layer dimension (256), number of attention heads (8), Dropout rate (0.1).
[0112] 4. Model Training: The training and validation sets are divided into an 8:2 ratio, and early stopping (patience=10) is used to prevent overfitting. The LSTM module extracts local temporal features (e.g., short-term power fluctuations). The Transformer module captures long-term dependencies (e.g., periodic power patterns) through a self-attention mechanism. A fusion layer (e.g., concatenation or weighted summation) combines the two types of features, and the predicted value is output through a fully connected layer. Backpropagation and parameter update:
[0113] Gradient calculation: The gradient of the model parameters is calculated using the backpropagation algorithm to determine the loss value.
[0114] Input: Model predictions and true labels.
[0115] Model predictions ( ): Generated by the LSTM-Transformer network, output: loss value (Loss).
[0116] True label (Y): The true observation value at the future time step extracted from the training data, with the same dimension as the predicted value (e.g., a scalar for single-step prediction and a vector for multi-step prediction).
[0117] Calculation method: The objective function quantifies the difference between the predicted value and the true value.
[0118]
[0119] Module 8: Computing Power Execution Module. Function: Based on the selection scheme generated by the core scheduling algorithm (including specified clusters and resource requirements such as computing power requirements), the module actually deploys tasks to the corresponding computing power clusters, thereby achieving efficient task execution and resource scheduling. This module is the terminal link of the architecture, directly obtaining the decision results from the scheduling algorithm to ensure that tasks are correctly allocated and run on the target cluster.
[0120] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages in other steps. It is understood that the steps in different embodiments can be freely combined as needed, and all non-contradictory solutions formed by such combinations are within the scope of protection of this application.
[0121] Based on the same inventive concept, this application also provides a computing power task execution device for implementing the computing power task execution method described above. The solution provided by this device is similar to the solution described in the above method. Therefore, the specific limitations of one or more computing power task execution device embodiments provided below can be found in the limitations of the computing power task execution method above, and will not be repeated here.
[0122] In one exemplary embodiment, such as Figure 4 As shown, a computing task execution device 400 is provided, including: an acquisition module 401, an input module 402, a determination module 403, and a filtering module 404, wherein:
[0123] The acquisition module 401 is used to acquire the task description data and task requirement data of the target computing power task, and to acquire the available computing power resources of any initial computing power cluster at the current time and at multiple times after the current time; wherein, the task description data includes task attribute parameters, input data feature parameters, task operation rule parameters and precision filtering parameters, and the task requirement data includes latency requirement data, cost constraints and carbon emission constraints.
[0124] The input module 402 is used to input the task description data into the Long Short-Term Memory-Transformer model and output the computing resource requirements data, predicted execution time range, and predicted power consumption of the target computing task.
[0125] The determination module 403 is used to determine at least one intermediate computing power cluster from multiple initial computing power clusters, and the predicted execution period for the intermediate computing power cluster to execute the target computing power task, based on the task description data, the task requirement data, the computing power resource requirement data, the predicted execution duration range, the predicted power consumption, and the available computing power resources.
[0126] The filtering module 404 is used to filter out a target computing power cluster from the at least one intermediate computing power cluster, and allocate the target computing power task to the target computing power cluster within the corresponding prediction execution period of the target computing power cluster.
[0127] In some embodiments, the determining module 403 is further configured to obtain the identifier of any initial computing power cluster; input the task description data, the task requirement data, the computing power resource requirement data, the predicted execution duration range, the predicted power consumption, the available computing power resources, and the identifier of the initial computing power cluster into the multi-factor selection model, and output the identifier of the intermediate computing power cluster and the predicted execution period.
[0128] In some embodiments, the filtering module 404 is further configured to, for any intermediate computing power cluster, obtain the electricity unit price within the corresponding predicted execution period of the intermediate computing power cluster; determine the total cost of the intermediate computing power cluster executing the target computing power task based on the electricity unit price and the corresponding duration of the predicted execution period; and determine the intermediate computing power cluster with the lowest corresponding total cost as the target computing power cluster.
[0129] In some embodiments, the computing power task execution device 400 is specifically used to acquire static basic data of the target computing power cluster, and acquire computing power resource status data of the target computing power cluster in real time during the execution of the target computing power task by the target computing power cluster; after the execution of the target computing power task is completed, acquire the actual power consumption of the target computing power task; and input the task description data, the static basic data, the computing power resource status data, and the predicted and actual power consumption into the Long Short-Term Memory-Transformer model to obtain the trained Long Short-Term Memory-Transformer model.
[0130] In some embodiments, the computing power task execution device 400 is further configured to, for any training epoch in the training process of the Long Short-Term Memory-Transformer model, determine the Long Short-Term Memory-Transformer model obtained in the training epoch as the trained Long Short-Term Memory-Transformer model if the loss values of the training epoch and the corresponding loss values of a preset number of historical training epochs before the training epoch are all within a preset loss value range.
[0131] In some embodiments, the computing power task execution device 400 is further configured to acquire load data of the power grid in multiple time periods after the execution end time of the target computing power task; determine the time period with the minimum load data as the target time period; and execute the training task of the Long Short-Term Memory-Transformer model in the target time period.
[0132] Each module in the aforementioned computing task execution device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of a computer device in hardware form or independent of it, or stored in the memory of a computer device in software form, so that the processor can call and execute the operations corresponding to each module.
[0133] In one exemplary embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 5As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, Near Field Communication (NFC), or other technologies. When the computer program is executed by the processor, it implements a computing task execution method.
[0134] Those skilled in the art will understand that Figure 5 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0135] In one embodiment, a computer device is also provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above method embodiments.
[0136] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon that, when executed by a processor, implements the steps in the above method embodiments.
[0137] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.
[0138] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.
[0139] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.
[0140] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0141] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. A method for executing computing tasks, characterized in that, The method includes: Obtain the task description data and task requirement data of the target computing power task, and obtain the available computing power resources of any initial computing power cluster at the current time and at multiple times after the current time; wherein, the task description data includes task attribute parameters, input data feature parameters, task operation rule parameters and precision filtering parameters, and the task requirement data includes latency requirement data, cost constraints and carbon emission constraints. The task description data is input into the Long Short-Term Memory-Transformer model, which outputs the computing resource requirements, predicted execution time range, and predicted power consumption of the target computing task. Based on the task description data, the task requirement data, the computing power resource requirement data, the predicted execution duration range, the predicted power consumption, and the available computing power resources, at least one intermediate computing power cluster is determined from multiple initial computing power clusters, and the predicted execution period for the intermediate computing power cluster to execute the target computing power task is determined. A target computing power cluster is selected from the at least one intermediate computing power cluster, and the target computing power task is assigned to the target computing power cluster during the corresponding prediction execution period of the target computing power cluster.
2. The method according to claim 1, characterized in that, The step of determining at least one intermediate computing power cluster from multiple initial computing power clusters based on the task description data, the task requirement data, the computing power resource requirement data, the predicted execution duration range, the predicted power consumption, and the available computing power resources, and the predicted execution period for the intermediate computing power cluster to execute the target computing power task, includes: Obtain the identifier of any initial computing cluster; The task description data, task requirement data, computing resource requirement data, predicted execution duration range, predicted power consumption, available computing resources, and the identifier of the initial computing cluster are input into the multi-factor selection model, and the identifier of the intermediate computing cluster and the predicted execution period are output.
3. The method according to claim 1, characterized in that, Selecting a target computing power cluster from the at least one intermediate computing power cluster includes: For any intermediate computing power cluster, obtain the electricity unit price within the corresponding prediction execution period of the intermediate computing power cluster; Based on the electricity unit price and the corresponding duration of the predicted execution period, determine the total cost of the intermediate computing power cluster executing the target computing power task; The intermediate computing power cluster with the lowest total cost is identified as the target computing power cluster.
4. The method according to claim 1, characterized in that, The method further includes: Obtain the static basic data of the target computing power cluster, and during the execution of the target computing power task on the target computing power cluster, obtain the computing power resource status data of the target computing power cluster in real time; After the target computing power task is completed, obtain the actual power consumption of the target computing power task. The task description data, the static basic data, the computing power resource status data, and the predicted and actual consumption of electricity resources are input into the Long Short-Term Memory-Transformer model to obtain the trained Long Short-Term Memory-Transformer model.
5. The method according to claim 4, characterized in that, The step of inputting the task description data, the static basic data, the computing resource status data, and the predicted and actual consumption of electricity resources into the Long Short-Term Memory-Transformer model to obtain the trained Long Short-Term Memory-Transformer model includes: For any training epoch in the training process of the Long Short-Term Memory-Transformer model, if the loss values of the training epoch and the corresponding loss values of the preset number of historical training epochs before the training epoch are all within the preset loss value range, the Long Short-Term Memory-Transformer model obtained in the training epoch will be determined as the trained Long Short-Term Memory-Transformer model.
6. The method according to claim 5, characterized in that, The method further includes: For the execution end time of the target computing power task, obtain the load data of the power grid in multiple time periods after the execution end time; The period with the least amount of data load is identified as the target period, and the training task of the Long Short-Term Memory-Transformer model is performed within the target period.
7. A computing task execution device, characterized in that, The device includes: The acquisition module is used to acquire task description data and task requirement data of the target computing power task, and to acquire the available computing power resources of any initial computing power cluster at the current time and at multiple times after the current time; wherein, the task description data includes task attribute parameters, input data feature parameters, task operation rule parameters and precision filtering parameters, and the task requirement data includes latency requirement data, cost constraints and carbon emission constraints. The input module is used to input the task description data into the Long Short-Term Memory-Transformer model and output the computing resource requirements data, predicted execution time range, and predicted power consumption of the target computing task. The determination module is used to determine at least one intermediate computing power cluster from multiple initial computing power clusters, and the predicted execution period for the intermediate computing power cluster to execute the target computing power task, based on the task description data, the task requirement data, the computing power resource requirement data, the predicted execution duration range, the predicted power consumption, and the available computing power resources. The filtering module is used to select a target computing power cluster from the at least one intermediate computing power cluster, and to allocate the target computing power task to the target computing power cluster within the corresponding prediction execution period of the target computing power cluster.
8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.
10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.
Citation Information
Cited By
Cross-hardware performance prediction method for black box task in computing power platform and related equipment
CN121958055A