A machine learning based computer system energy consumption optimization method and system

CN122945791APending Publication Date: 2026-10-20LHASA KUANDU CULTURE TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611141943.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-30
Publication Date
2026-10-20

AI Technical Summary

Technical Problem

[0005]本发明为了至少部分解决现有技术中计算机系统能耗控制依赖固定阈值或单一功率指标,难以准确评估不同控制动作实际节能效果的问题,现有技术通常根据当前资源利用率直接执行处理器降频、核心关闭或任务迁移等控制动作,导致控制动作的节能收益预测准确性较低,而提出的一种基于机器学习的计算机系统能耗优化方法、系统、电子设备及存储介质

Benefits of technology

[0054]一、本发明通过对计算机系统运行数据进行状态分段,并基于状态片段构建基准运行样本和动作响应样本,使不同负载阶段和不同控制动作对应的数据边界更加清晰,有利于提高训练样本的一致性和可追溯性,便于后续对模型进行更新、校正和维护。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure FT_1
    Figure FT_1
  • Figure FT_2
    Figure FT_2
Patent Text Reader

Abstract

This invention relates to the field of energy consumption optimization technology, and in particular to a method and system for optimizing the energy consumption of computer systems based on machine learning. The method includes acquiring computer system operating data and segmenting it into states to form a set of state segments; constructing state samples from the set of state segments; building a baseline response prediction model and a control action response model using the state samples; generating candidate control actions based on the current operating state and comparing and extrapolating using the models to obtain prediction results for the candidate actions; then selecting target control actions, executing the target control actions, and collecting actual energy consumption responses and actual performance responses; and maintaining the target control actions or restoring the control state to its state before execution based on the actual responses. This invention can reduce the interference of natural fluctuations in business load on the judgment of energy-saving effects, while balancing actual energy-saving benefits with system performance security, thus improving the accuracy and reliability of computer system energy consumption optimization.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of energy consumption optimization, and in particular to a method, system, electronic device, and storage medium for optimizing the energy consumption of a computer system based on machine learning. Background Technology

[0002] With the development of cloud computing, edge computing, and artificial intelligence technologies, computer systems are widely used in enterprise private clouds, edge computing centers, and small and medium-sized data centers. The same computer system or server cluster usually runs multiple online and offline services simultaneously. Because online services have high requirements for response latency and service continuity, while offline services continuously occupy processor, memory, storage, and network resources, the load structure, task queue, and hardware operating status of the computer system are constantly changing. There are common problems such as mismatch between resource allocation and actual load demand, high system energy consumption, and energy-saving control easily affecting business performance.

[0003] Existing computer system energy consumption optimization methods typically employ fixed threshold control or power consumption prediction based on historical operating data, and adjust processor frequency, number of active cores, and task deployment location according to processor utilization, task load, or predicted power consumption.

[0004] However, existing technologies still have significant limitations in practical applications: On the one hand, existing machine learning methods typically make predictions based on the statistical relationship between the current system state and subsequent power consumption, making it difficult to distinguish between power consumption changes caused by natural load variations and actual energy consumption changes caused by control actions, resulting in inaccurate predictions of the actual energy-saving benefits and performance impact of candidate control actions; on the other hand, existing systems typically control adjustment actions separately, which can easily lead to frequent frequency reduction and increase during load fluctuations, causing resource control oscillations and making the energy-saving benefits gained from short-term power reduction offset by subsequent additional energy consumption. Summary of the Invention

[0005] In order to at least partially solve the problem that the energy consumption control of computer systems in the prior art relies on fixed thresholds or single power indicators, making it difficult to accurately evaluate the actual energy-saving effect of different control actions, the present invention proposes a computer system energy consumption optimization method, system, electronic device and storage medium based on machine learning.

[0006] To achieve the above objectives, in a first aspect, this invention proposes a machine learning-based method for optimizing the energy consumption of computer systems, comprising:

[0007] Acquire computer system operating data and segment it into states to form a set of state segments;

[0008] State samples are constructed from the set of state fragments, and response relationships are learned from the state samples to obtain a baseline response prediction model and a control action response model.

[0009] Candidate control actions are generated based on the current operating status. The candidate control actions are compared and deduced using the baseline response prediction model and the control action response model to obtain the candidate action prediction results. The candidate action prediction results include predicted energy consumption response and predicted performance response.

[0010] The candidate action prediction results are screened and evaluated based on preset performance constraints to determine the target control action;

[0011] The target control action is executed and the actual response is collected. The control state is adjusted according to the actual response to obtain the energy consumption optimization result of the computer system.

[0012] Preferably, the candidate action prediction results are screened and evaluated based on preset performance constraints to determine the target control action, including:

[0013] The predicted performance response of each candidate control action is screened for performance risk to obtain executable control actions.

[0014] Determine the predicted net energy savings and performance safety margins for each executable control action;

[0015] Each executable control action is evaluated based on the predicted net energy savings and performance safety margin to determine the target control action.

[0016] Preferably, determining the predicted net energy saving benefit and performance safety margin corresponding to each executable control action includes:

[0017] The baseline energy consumption response when no control action is performed is determined using the baseline response prediction model. The predicted energy savings are obtained by time-series difference between the baseline energy consumption response and the predicted energy consumption response when each executable control action is performed.

[0018] Based on the resource switching process and task processing changes corresponding to each executable control action, determine the action execution cost and recovery compensation energy consumption;

[0019] The predicted energy savings are deducted from the energy consumption of the action execution cost and the energy consumption of recovery compensation to obtain the predicted net energy saving benefit.

[0020] A safety margin sequence is constructed for the predicted performance response corresponding to each executable control action, and the performance safety margin is determined.

[0021] Preferably, the execution cost and recovery compensation energy consumption are determined based on the resource switching process and task processing changes corresponding to each executable control action, including:

[0022] Determine the corresponding resource switching energy consumption based on each executable control action;

[0023] The energy consumption of data transmission and state recovery during the task migration process is statistically analyzed to obtain the task migration energy consumption.

[0024] The energy consumption of resource switching and task migration are summarized to obtain the action execution cost;

[0025] The amount of newly added backlogged tasks is determined based on the differences in task processing before and after each executable control action, and the additional energy consumption required to complete the newly added backlogged tasks is determined based on the amount of newly added backlogged tasks, thus obtaining the recovery compensation energy consumption.

[0026] Preferably, a safety margin sequence is constructed for the predicted performance response corresponding to each executable control action, and the performance safety margin is determined, including:

[0027] Extract the predicted values ​​of each performance index within the prediction period from the predicted performance response corresponding to each executable control action, and determine the difference between the predicted value of each performance index and the corresponding performance limit.

[0028] Normalize the difference between the predicted value of each performance index and the corresponding performance limit to obtain the safety margin sequence for each performance index.

[0029] Based on the minimum value and trend of each safety margin sequence, determine the performance safety margin corresponding to each executable control action.

[0030] Preferably, each executable control action is evaluated based on the predicted net energy saving benefit and performance safety margin to determine the target control action, including:

[0031] The predicted net energy saving benefit and performance safety margin corresponding to each executable control action are normalized to obtain the energy saving benefit evaluation value and safety margin evaluation value.

[0032] The evaluation weights corresponding to the energy-saving benefit evaluation value and the safety margin evaluation value are determined based on the current operating status of the computer system, and a weighted calculation is performed to obtain the comprehensive evaluation value corresponding to each executable control action.

[0033] The executable control action with the highest comprehensive evaluation value and that reaches the preset action execution threshold is identified as the target control action.

[0034] Preferably, the target control action is executed and the actual response is collected. The control state is adjusted according to the actual response to obtain the computer system energy consumption optimization result, including:

[0035] Execute the target control action and collect the actual response after the target control action is executed, wherein the actual response includes the actual energy consumption response and the actual performance response;

[0036] Energy consumption deviation analysis and performance constraint analysis are performed on the actual response to determine the actual execution state of the target control action;

[0037] Based on the actual execution state, the target control action is maintained, or the control state before the target control action was executed is reverted to obtain the computer system energy consumption optimization result.

[0038] Preferably, energy consumption deviation analysis and performance constraint analysis are performed on the actual response to determine the actual execution state of the target control action, including:

[0039] A difference analysis is performed on the actual energy consumption response and the predicted energy consumption response corresponding to the target control action to obtain the energy consumption response deviation of the target control action;

[0040] The actual performance response is compared with the preset performance constraints to determine the performance constraint state corresponding to the target control action.

[0041] Based on the energy consumption response deviation and performance constraint status, a joint determination is made to determine the actual execution status corresponding to the target control action, including the action hold state or the action rollback state.

[0042] Preferably, the actual execution state corresponding to the target control action is determined by jointly judging the energy consumption response deviation and performance constraint state, including:

[0043] The energy consumption response deviation is compared with a preset deviation threshold to obtain the energy-saving effect status.

[0044] When the energy-saving effect meets expectations and the performance constraint does not exceed the limit, the actual execution state corresponding to the target control action is determined to be the action holding state.

[0045] When the energy-saving effect does not meet expectations or the performance constraint exceeds the limit, the actual execution state corresponding to the target control action is determined to be the action rollback state.

[0046] Secondly, the present invention also provides a computer system energy consumption optimization system based on machine learning, comprising:

[0047] The state segmentation module is used to acquire computer system operating data and segment it into states to form a set of state segments;

[0048] The model building module is used to construct state samples from the set of state fragments and learn response relationships from the state samples to obtain a baseline response prediction model and a control action response model.

[0049] The candidate action generation module is used to generate candidate control actions based on the current operating state, and to compare and deduce the candidate control actions using the baseline response prediction model and the control action response model to obtain the candidate action prediction results.

[0050] The control action selection module is used to filter and evaluate the prediction results of candidate actions based on preset performance constraints, and determine the target control action.

[0051] The response adjustment module is used to execute the target control action and collect the actual response, adjust the control state according to the actual response, and obtain the computer system energy consumption optimization result.

[0052] Thirdly, the present invention provides an electronic device including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the method in the first aspect.

[0053] Fourthly, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the method in the first aspect. Compared with the prior art, the present invention has the following beneficial effects:

[0054] I. This invention segments the computer system's operational data into states and constructs baseline operational samples and action response samples based on these state segments. This makes the data boundaries corresponding to different load stages and different control actions clearer, which helps improve the consistency and traceability of training samples and facilitates subsequent model updates, corrections, and maintenance.

[0055] Second, by constructing a baseline response prediction model and a control action response model respectively, this invention distinguishes between the natural operating response of the computer system when no control action is executed and the additional response caused by the control action, and compares and extrapolates the candidate control actions. This can reduce the interference of natural fluctuations in business load on the judgment of energy-saving effect of actions and improve the accuracy of predicting the energy consumption response and performance response of candidate control actions.

[0056] Third, by incorporating the execution cost of actions, recovery compensation energy consumption, and performance safety margin into the evaluation of candidate control actions, and by maintaining or rolling back actions based on actual energy consumption response and actual performance response, this invention further reduces the interference of natural load fluctuations, control action switching overhead, and performance exceeding limits on energy consumption optimization decisions, thereby making the energy consumption optimization of computer systems more accurate, safe, and stable. Attached Figure Description

[0057] Figure 1 A flowchart of a machine learning-based computer system energy consumption optimization method provided in an embodiment of the present invention;

[0058] Figure 2 This is a system architecture diagram of a computer system energy consumption optimization based on machine learning, provided as an embodiment of the present invention. Detailed Implementation

[0059] To make the technical means, creative features, objectives, and effects of this invention easier to understand, the invention is further described below with reference to specific embodiments. However, the following embodiments are merely preferred embodiments of this invention and not all of them. Other embodiments obtained by those skilled in the art based on the embodiments described herein without creative effort are all within the protection scope of this invention.

[0060] Example 1:

[0061] To achieve the above objectives, please refer to Figure 1 This invention provides a machine learning-based method for optimizing the energy consumption of a computer system, comprising:

[0062] S1. Obtain computer system operation data and segment it into states to form a set of state segments.

[0063] In this embodiment, the computer system can be a single computing device or a computer cluster consisting of multiple servers. It collects multi-source operating data generated during the operation of the computer system according to a preset sampling period. The preset sampling period can be set according to the load change rate and resource control response rate of the computer system, for example, it can be set to 1 second to 30 seconds.

[0064] Computer system operation data includes load status data, hardware status data, thermal status data, energy consumption status data, business performance data, and control action data;

[0065] Among them, the load status data is used to characterize the current task structure and task changes of the computer system, including processor utilization, processor run queue length, task arrival rate, task completion rate, online task ratio, batch task ratio, number of containers, number of virtual machines, and task type; the hardware status data is used to characterize the current resource configuration and resource usage of the computer system, including processor frequency, number of active cores, memory usage, storage read / write rate, network throughput, and accelerator card utilization.

[0066] Thermal status data includes processor temperature, motherboard temperature, intake air temperature, fan speed, and temperature change rate; power consumption status data includes total power consumption, processor power consumption, memory power consumption, and accelerator card power consumption; business performance data includes average request response latency, 95th percentile response latency, number of task timeouts, request error rate, and remaining batch processing tasks; control action data includes processor frequency adjustment actions, core start / stop actions, task migration actions, batch processing task delay actions, and corresponding action execution time, action magnitude, and action execution result.

[0067] It should be added that, since the computer system operation data comes from different acquisition interfaces, the computer system operation data is timestamped and then time-aligned and field-collected according to a preset sampling period to obtain system operation records arranged in chronological order; short-term missing data in the system operation records is imputed, and system operation records with continuous missing time exceeding a preset missing period are marked as invalid records, so as to obtain valid operation data for state segmentation.

[0068] Furthermore, state change analysis is performed on the system operation records to identify load switching events, control action events, and performance anomaly events.

[0069] Among them, the load switching event is used to characterize a significant change in the task structure or load intensity carried by the computer system, including the task arrival rate exceeding the historical fluctuation range of the corresponding load type, the online task ratio changing by a preset magnitude, and the batch processing tasks starting or ending in a concentrated manner. Specifically, the load change magnitude can be determined based on the difference in task arrival rates between adjacent time windows, and the load change magnitude is compared with the historical fluctuation limit of the corresponding load type. When the load change magnitude exceeds the historical fluctuation limit, the load switching event is determined to have occurred at the corresponding time position.

[0070] Control action events include processor frequency adjustment, active core count adjustment, task migration, and batch task delay; performance anomaly events include the 95th percentile response latency exceeding the service latency limit, continuous growth of the task queue, and processor temperature exceeding the temperature warning value. For the task queue, when the number of tasks arriving is greater than the number of tasks completed and the task queue length continues to increase within multiple consecutive time windows, the corresponding time position is determined to be the occurrence of a performance anomaly event in the task queue.

[0071] The occurrence times of load switching events, control action events, and performance anomaly events are determined as state segment boundaries. The system operation records are divided according to adjacent state segment boundaries to obtain multiple operation state segments. Each operation state segment includes continuously arranged computer system operation data within the corresponding time range. The multiple operation state segments are organized in chronological order to form a state segment set.

[0072] S2. Construct state samples from the set of state fragments. The state samples include baseline running samples and action response samples. Learn the response relationship from the state samples to obtain the baseline response prediction model and the control action response model.

[0073] In this embodiment, segment attribute identification is performed on each running state segment in the state segment set to determine whether there is a control action in each running state segment. Based on the identification result, the running state segment is divided into a baseline running segment and an action response segment. The baseline running segment is used to characterize the natural running process of the computer system when no new control action is executed, and the action response segment is used to characterize the state change process of the computer system after executing the control action.

[0074] Specifically, the system selects running state segments from the set of state segments that have not performed processor frequency adjustment, core start / stop, task migration, or batch task delay actions during a continuous observation period; at the same time, the task type composition, task arrival rate, and hardware running status within the running state segments are required to be within a preset stable range; and then the running state segments that meet the above conditions are determined as the baseline running segments.

[0075] For each benchmark operation segment, the load status, hardware status, and thermal status are extracted in continuous time sequence, and the energy consumption status and service performance status in the corresponding subsequent time periods are used as prediction targets to construct benchmark operation samples.

[0076] The operational state segment containing control actions is taken as the action response segment. Taking the execution time of the control action as the time reference, the state data before the action is executed and the response data after the action is executed are extracted respectively. The state data before the action is executed includes the load status, hardware status, thermal status and service performance status within a preset period before the action is executed; the response data after the action is executed includes the changes in power, temperature, task queue and service latency over time.

[0077] Action sample inputs are constructed based on the state data before action execution, the type of control action, and the amplitude of the control action. The state data before action execution is input into the baseline response prediction model to obtain the baseline response when the corresponding control action is not executed. The actual response after action execution is time-series differencing is performed between the actual response and the baseline response to obtain the independent response sequence corresponding to the control action. The independent response sequence is used as the action response label to obtain the action response sample. The control action type includes processor frequency adjustment, active core number adjustment, task migration, and batch task delay. The control action amplitude is used to characterize the frequency adjustment level, the number of cores started / stopped, the scale of the migration task, or the duration of the task delay.

[0078] Furthermore, response relationships are learned from the baseline operating samples to obtain a baseline response prediction model, which specifically includes:

[0079] The system operation records of multiple consecutive systems are arranged in chronological order to form a time-series input window, which is then input into a long short-term memory network for time-series feature extraction. Based on the correspondence between time-series features and load type and hardware configuration status, regression prediction is performed on the baseline response sequence in the future prediction period. Gradient boosting trees can also be used to supplement the learning of non-continuous features such as task type and resource configuration.

[0080] Based on action response samples, action response relationships are learned according to the type of control action to establish a control action response model, which specifically includes:

[0081] Based on the change time and recovery status of each response index in the action response sample, the time series prediction model is trained so that the time series prediction model learns the relationship between the changes in power, temperature, task queue and service delay at different time offset positions after the execution of the control action, thus obtaining the control action response model.

[0082] The time-series prediction model is trained using action response samples to obtain the control action response model.

[0083] S3. Generate candidate control actions based on the current operating status, and use the baseline response prediction model and control action response model to compare and deduce the candidate control actions to obtain the candidate action prediction results. The candidate action prediction results include predicted energy consumption response and predicted performance response.

[0084] In this embodiment, the current operating state of the computer system is extracted from the newly formed operating state fragment. The current operating state includes the current load state, control state, hardware temperature state, energy consumption state, and business performance state, which are used to characterize the computer system's task processing requirements, resource utilization, and performance risk level at the current moment.

[0085] Candidate control actions are generated based on the current operating status. These candidate control actions include one of the following: processor frequency adjustment, active core count adjustment, task migration, and batch task delay.

[0086] For each control action, one or more action amplitudes are set according to the preset action adjustment range. For example, candidate control actions corresponding to reducing the frequency by one level and reducing the frequency by two levels are generated based on the current processor frequency, or candidate control actions corresponding to shutting down one processor core and shutting down two processor cores are generated based on the current number of active cores.

[0087] When generating candidate control actions, preliminary restrictions are imposed based on the resource configuration boundaries of the computer system and the applicable conditions of the actions. For example, if the number of active cores has reached a preset lower limit, no candidate control actions to reduce the number of active cores will be generated; if the available resources of the target computing node are insufficient, no candidate control actions to migrate tasks to the target computing node will be generated. The generation and boundary judgment of candidate control actions can be implemented using preset action rules.

[0088] Furthermore, the candidate control actions are compared and deduced using the aforementioned baseline response prediction model and control action response model, specifically including:

[0089] S31. Input the current operating state into the baseline response prediction model to predict the natural operating result of the computer system during the prediction period while maintaining the current resource configuration and without executing new control actions, and obtain the baseline energy consumption response and the baseline performance response. The baseline energy consumption response includes the baseline power value arranged in chronological order; the baseline performance response includes the baseline hardware temperature value, the baseline task queue length, and the baseline service latency value.

[0090] S32. Input the current operating status, the action type and action amplitude of each candidate control action into the control action response model to obtain the independent response change of each candidate control action at different time offset positions within the prediction period. The independent response change includes power change, hardware temperature change, task queue change and service latency change.

[0091] It should be noted that the output of the control action response model is the additional change caused by the candidate control action relative to the natural operating state of the system. By using independent response change, the interference of natural load changes during the prediction period on the judgment of the effect of candidate control actions can be reduced, and the power decline or performance change of the computer system itself can be incorrectly attributed to the candidate control action.

[0092] S33. According to the same time offset position, the independent response changes corresponding to each candidate control action are superimposed on the reference energy consumption response and the reference performance response respectively to obtain the action deduction results when executing each candidate control action.

[0093] Specifically, the power change at each time offset position is superimposed with the corresponding reference power value to obtain the predicted power sequence corresponding to the candidate control action; the hardware temperature change, task queue change, and service delay change are superimposed with the corresponding reference performance response to obtain the predicted temperature sequence, predicted task queue sequence, and predicted service delay sequence corresponding to the candidate control action.

[0094] The time offset positions within the prediction period are processed sequentially in the manner described above to form the predicted energy consumption response and the predicted performance response corresponding to the candidate control action. The predicted energy consumption response includes the predicted power sequence and the predicted energy consumption obtained by accumulating the predicted power sequence over time. The predicted performance response includes the predicted temperature sequence, the predicted task queue sequence, and the predicted service delay sequence.

[0095] It should be further explained that the baseline energy consumption response and baseline performance response when no new control action is executed are used as the baseline extrapolation results, and the predicted energy consumption response and predicted performance response when each candidate control action is executed are used as the action extrapolation results, and corresponding comparisons are made according to the same prediction period.

[0096] S34. Establish a correspondence between the action type, action amplitude, predicted energy consumption response and predicted performance response of each candidate control action to obtain the candidate action prediction results. The candidate action prediction results are used to screen out candidate control actions with performance risks according to preset performance constraints, and to evaluate the energy-saving benefits of candidate control actions that meet the performance requirements.

[0097] This invention predicts the natural operating results of a computer system when it does not perform control actions and the independent response changes generated by candidate control actions, and then combines the two in a time sequence. This allows for comparative simulation of multiple candidate control actions under the same current operating state and the same prediction period, reducing the impact of natural load fluctuations on the prediction of action effects and improving the accuracy of predicting the energy consumption benefits and performance risks of candidate control actions.

[0098] S4. Based on preset performance constraints, the prediction results of candidate actions are screened and evaluated to determine the target control action.

[0099] In this embodiment, preset performance constraints are pre-set based on the service requirements of the computer system carrying the business and the hardware security operation requirements, including service latency limits, hardware temperature limits, and task queue limits. Performance risk screening is performed on the predicted performance responses corresponding to each candidate control action, and the predicted net energy saving benefits and performance safety margins of the screened control actions are comprehensively evaluated to determine the target control action. Specifically, this includes the following steps:

[0100] S41. Based on the predicted performance response corresponding to each candidate control action, the performance risk is screened to obtain the executable control action.

[0101] Specifically, the predicted performance index values ​​for the prediction period are extracted from the predicted performance responses corresponding to each candidate control action, including the service delay sequence, hardware temperature sequence, and task queue sequence, and are compared with the corresponding service delay limit, hardware temperature limit, and task queue limit, respectively.

[0102] If the predicted value of any performance indicator corresponding to a candidate control action exceeds the corresponding performance limit, the candidate control action is determined to have a risk of exceeding the performance limit and is removed from the candidate control actions; if the predicted values ​​of each performance indicator do not exceed the corresponding performance limit during the prediction period, the candidate control action is determined to be an executable control action.

[0103] It should be noted that performance risk screening is performed on the predictive performance response generated continuously within the prediction period, rather than judging based on a single performance value at the end of the prediction period, in order to avoid missing temporary business latency, hardware temperature or task queue overruns that occur after control actions take effect.

[0104] S42. Determine the predicted net energy saving benefits and performance safety margins corresponding to each executable control action.

[0105] S421. The baseline energy consumption response when no control action is performed is determined using the baseline response prediction model, and the predicted energy consumption response when each executable control action is performed is time-differed to obtain the predicted energy saving.

[0106] Specifically, the baseline power sequence when no new control action is executed is extracted from the baseline energy consumption response output by the baseline response prediction model, and the predicted power sequence when the corresponding control action is executed is extracted from the predicted energy consumption response corresponding to each executable control action.

[0107] Based on the same time offset position, the difference between the reference power sequence and the predicted power sequence corresponding to each executable control action is calculated to obtain the energy-saving power difference corresponding to each time offset position.

[0108] It should be added that, for the i-th time offset position within the prediction period, the energy-saving power difference can be expressed as: energy-saving power difference = base power value - predicted power value when executing executable control action; when the energy-saving power difference is greater than zero, it means that the corresponding control action produces an energy-saving effect at the time offset position; when the energy-saving power difference is less than zero, it means that the corresponding control action produces additional energy consumption at the time offset position.

[0109] The energy-saving power difference within the prediction period is accumulated over time based on the sampling period to obtain the predicted energy saving corresponding to each executable control action. The predicted energy saving not only reflects the immediate power decrease after the control action is executed, but also reflects the continuous energy saving effect at each time position within the prediction period.

[0110] S422. Based on the resource switching process and task processing changes corresponding to each executable control action, determine the action execution cost and recovery compensation energy consumption, and deduct the predicted energy saving from the predicted energy saving to obtain the predicted net energy saving benefit.

[0111] Specifically, based on the type and magnitude of the control action, the additional power and duration of the same control action during execution are extracted from historical action samples, and the additional power is accumulated over time to obtain the energy consumption for resource switching.

[0112] For task migration, the additional power of the source computing node and the target computing node during the migration period relative to the stable power before migration is determined and accumulated over time to obtain data transmission energy consumption and state recovery energy consumption. Then, the data transmission energy consumption and state recovery energy consumption are statistically analyzed to obtain task migration energy consumption. State recovery energy consumption is used to characterize the additional energy consumption generated by reloading the task running state, cached data, or associated resources after the task is migrated to the target computing node.

[0113] The energy consumption of resource switching and task migration corresponding to the executable control actions are summarized to obtain the corresponding action execution cost. The action execution cost is used to characterize the additional energy consumption generated by the computer system switching from the current control state to the control state corresponding to the candidate control action. For control actions that do not involve task migration, their task migration energy consumption can be set to zero. The control state is used to characterize the control state currently adopted by the computer system, including at least one of the following: processor frequency, number of active cores, task deployment location, and task scheduling state.

[0114] Furthermore, the recovery compensation energy consumption corresponding to each executable control action is determined.

[0115] It should be explained that while control actions may reduce processor frequency, decrease the number of active cores, or delay some batch processing tasks, they may also reduce the computer system's task processing capacity during the corresponding period and create new backlog tasks. Therefore, calculating predicted energy savings solely based on predicted power reduction may overestimate the actual energy-saving effect of control actions.

[0116] Specifically, control actions may reduce task processing capacity during the prediction period and create new backlog tasks. Therefore, the recovery compensation energy consumption required to complete the new backlog tasks is determined based on the amount of new backlog tasks and the unit task processing energy consumption under the restored resource state. The amount of new backlog tasks can be determined based on the difference between the baseline task completion amount and the predicted task completion amount when the executable control action is executed; or it can be determined based on the number of tasks that the task queue increases relative to the baseline performance response in the predicted performance response.

[0117] The energy consumption per unit task can be determined by the ratio of the energy consumption generated by the computer system processing a preset number of historical tasks under normal resource configuration to the corresponding number of tasks.

[0118] It should be noted that when the predicted energy consumption response has fully covered the new backlog task processing phase, the recovery compensation energy consumption only counts the additional energy consumption corresponding to the new backlog tasks that have not been processed after the prediction period ends, so as to avoid deducting the energy consumption of the same recovery phase repeatedly.

[0119] S423. Based on the cost of action execution and the energy consumption for recovery compensation, the predicted energy saving is deducted to obtain the predicted net energy saving benefit.

[0120] Specifically, the predicted net energy saving benefit is obtained by subtracting the action execution cost and recovery compensation energy consumption from the predicted energy saving corresponding to each executable control action, that is: predicted net energy saving benefit = predicted energy saving - action execution cost - recovery compensation energy consumption.

[0121] When the predicted net energy saving benefit is greater than zero, it means that the corresponding executable control action can still produce actual energy saving effect after considering the control state switching and subsequent task recovery processing; when the predicted net energy saving benefit is not greater than zero, it means that the surface energy saving generated by the corresponding control action is insufficient to compensate for the additional energy consumption generated by the action execution and task recovery.

[0122] S424. Construct a safety margin sequence for the predicted performance response corresponding to each executable control action to obtain the performance safety margin.

[0123] Specifically, the predicted values ​​of each performance index within the prediction period are extracted from the predicted performance response corresponding to each executable control action, and the difference between the predicted value of each performance index and the corresponding performance limit is determined.

[0124] For performance metrics such as business latency, hardware temperature, and task queue, the higher the value, the higher the performance risk. The safety margin of the metrics is the corresponding performance limit minus the predicted value of the performance metric. Since different performance metrics have different units of measurement, the ratio of the safety margin of each metric to the corresponding performance limit is calculated to obtain the normalized safety margin, and then arranged in chronological order to form the safety margin sequence corresponding to each performance metric.

[0125] Based on the minimum value and changing trend of each safety margin sequence, determine the performance safety margin corresponding to each executable control action.

[0126] Minimum values ​​are extracted from the safety margin sequences corresponding to each performance index to obtain the basic safety margin for each performance index. Linear trend fitting is performed on each safety margin sequence to obtain the slope of the safety margin change. When the slope of the safety margin change is less than zero, the trend correction amount is determined based on the slope of the safety margin change and the length of the prediction period. The trend correction amount can be determined by multiplying the absolute value of the slope of the safety margin change, the length of the prediction period, and the preset trend correction coefficient. The trend correction coefficient is used to adjust the degree of influence of the downward trend of the safety margin on the performance safety margin.

[0127] Subtract the trend correction from the basic safety margin to obtain the corrected safety margin; when the calculation result is less than zero, the corresponding corrected safety margin is set to zero, and the basic safety margin is used as the corrected safety margin.

[0128] S43. Evaluate each executable control action based on the predicted net energy saving benefit and performance safety margin, and determine the target control action.

[0129] The predicted net energy saving benefit and performance safety margin corresponding to each executable control action are normalized to obtain the energy saving benefit evaluation value and the safety margin evaluation value. The normalization process is used to eliminate the numerical range difference between the predicted net energy saving benefit and the performance safety margin. It can be achieved by range normalization or preset benchmark value normalization.

[0130] The evaluation weights corresponding to the energy-saving benefit evaluation value and the safety margin evaluation value are determined based on the current operating status of the computer system, and a weighted calculation is performed to obtain the comprehensive evaluation value corresponding to each executable control action.

[0131] Specifically, the ratio of the current service latency to the service latency limit is determined as the latency pressure value, the ratio of the current hardware temperature to the hardware temperature limit is determined as the temperature pressure value, the ratio of the current task queue length to the task queue limit is determined as the queue pressure value, and the ratio of the current task queue growth rate to the task queue growth rate limit is determined as the queue growth pressure value.

[0132] The maximum value among the time delay pressure value, temperature pressure value, queue pressure value, and queue growth pressure value is determined as the performance risk level, so that the importance of performance safety can be increased when any performance indicator approaches the corresponding limit.

[0133] The performance priority corresponding to the current running status is obtained by weighting the proportion of online tasks and the degree of performance risk. The weight can be calibrated based on the performance exceedance of online business during the execution of historical control actions.

[0134] The evaluation weight corresponding to the safety margin evaluation value is determined based on the performance priority, specifically expressed as: Safety margin evaluation weight = lower limit of safety weight + performance priority × (upper limit of safety weight - lower limit of safety weight). For example, the lower limit of safety weight is set to 0.3, and the upper limit of safety weight is set to 0.8. Then, the difference between 1 and the safety margin evaluation weight is determined as the evaluation weight corresponding to the energy saving benefit evaluation value.

[0135] At this point, the comprehensive evaluation value can be expressed as: Comprehensive evaluation value = Evaluation weight corresponding to energy saving benefit evaluation value × Energy saving benefit evaluation value + Evaluation weight corresponding to safety margin evaluation value × Safety margin evaluation value;

[0136] The executable control action with the highest comprehensive evaluation value and that reaches the preset action execution threshold is identified as the target control action.

[0137] Specifically, executable control actions whose comprehensive evaluation value reaches the preset action execution threshold are determined as effective control actions, and the control action with the highest comprehensive evaluation value among the effective control actions is determined as the target control action;

[0138] If no valid control action exists, the current control state of the computer system will be maintained, and no new control action will be executed.

[0139] As one implementation method:

[0140] Assume a computer system is a private cloud computing cluster of an enterprise consisting of 24 servers. Set the 95th percentile response latency limit for online services to 120 milliseconds, the upper limit for processor safe temperature to 82°C, and the task queue limit to 8% per minute; set the data sampling period to 5 seconds, the control decision period to 60 seconds, and the prediction period to 5 minutes.

[0141] At a certain control decision moment, server S 08 The processor utilization rate was 58%, the proportion of online tasks was 72%, the proportion of batch tasks was 28%, the processor frequency was 2.8GHz, the number of active cores was 48, the processor temperature was 69℃, the 95th percentile response latency was 86 milliseconds, and the task queue length was 124.

[0142] For server S 08 The following candidate control actions are generated:

[0143] Action A: Reduce the processor frequency from 2.8GHz to 2.4GHz;

[0144] Action B: Shut down 8 low-utilization cores;

[0145] Action C: Migrate the two batch containers to server S15.

[0146] For action A, the predicted average power decreases to 371 watts, the 95th percentile response latency increases to 114 milliseconds, the task queue length increases to 143, and the processor temperature decreases to 66°C after approximately 50 seconds. Since the predicted service latency is below the 120 millisecond service latency limit and the task queue growth does not exceed the corresponding limit, action A is determined to be an executable control action. After deducting the energy consumption for frequency switching and recovery compensation, the predicted net energy saving benefit is 0.0045 kWh.

[0147] For action B, the predicted average power drops to 356 watts. Although the power drop is greater than that of action A, the predicted 95th percentile response latency increases to 132 milliseconds, and the task queue growth rate reaches 11% per minute, which exceeds the service latency limit and the task queue limit, respectively. Therefore, action B is identified as an unexecutable control action and is removed.

[0148] For action C, the average power of server S08 is predicted to decrease to 382 watts, the average power of server S15 is predicted to increase by 27 watts, and the task migration and container state recovery consume 0.00012 kWh. After comprehensively considering the increase in target server power and the cost of task migration, the predicted net energy saving benefit of the cluster is about 0.0015 kWh, which is lower than action A.

[0149] A comprehensive evaluation of the predicted net energy saving benefits and performance safety margins of actions A and C was conducted. Action A had the highest comprehensive evaluation value and reached the preset action execution threshold. Therefore, action A was determined as the target control action.

[0150] S5. Execute the target control action and collect the actual response. Adjust the control state according to the actual response to obtain the computer system energy consumption optimization result.

[0151] In this embodiment, the target control action is sent to the corresponding computing node, and the actual energy consumption response and actual performance response are continuously collected during the verification period after the target control action is executed. The method is used to determine whether the target control action achieves the expected energy-saving effect and whether it causes performance to exceed limits. The specific steps include:

[0152] S51. Execute the target control action and collect the actual response after the target control action is executed, wherein the actual response includes the actual energy consumption response and the actual performance response.

[0153] Control commands are generated based on the action type and amplitude of the target control action, executed through the resource management interface of the computer system, and the execution time of the action is recorded.

[0154] Using the execution time of the target control action as the starting point for verification, and following the same sampling period and verification time as the candidate action prediction results, the actual response after the execution of the target control action is continuously collected. The actual response includes the actual energy consumption response and the actual performance response. The actual energy consumption response includes the actual power sequence after the execution of the target control action and the actual energy consumption determined based on the actual power sequence. The actual performance response includes the actual service latency sequence, the actual hardware temperature sequence, and the actual task queue sequence.

[0155] For task migration actions, the energy consumption and performance status of the source computing node and the target computing node are also collected simultaneously to avoid judging the actual energy-saving effect of the task migration action based solely on the power reduction of the source computing node.

[0156] S52. Perform energy consumption deviation analysis and performance constraint analysis on the actual response to determine the actual execution state of the target control action.

[0157] S521. Perform a difference analysis on the actual energy consumption response and the predicted energy consumption response corresponding to the target control action to obtain the energy consumption response deviation of the target control action.

[0158] Specifically, the actual power sequence within the verification period is extracted from the actual energy consumption response, and the actual power sequence is accumulated over time according to the sampling period to obtain the actual energy consumption; the predicted energy consumption within the same verification period is extracted from the predicted energy consumption response corresponding to the target control action.

[0159] When the actual energy consumption is higher than the predicted energy consumption, the energy consumption response deviation is determined based on the ratio of the difference between the actual energy consumption and the predicted energy consumption to the predicted energy consumption, that is: Energy consumption response deviation = (actual energy consumption - predicted energy consumption) / predicted energy consumption.

[0160] When the actual energy consumption is not higher than the predicted energy consumption, the energy consumption response deviation is set to zero, indicating that the actual energy consumption effect of the target control action reaches or exceeds the predicted result.

[0161] By comparing the actual energy consumption response with the predicted energy consumption response within the same verification period, it can be determined whether the energy consumption change after the target control action is executed reaches the model prediction result, and provide a basis for judgment on whether to maintain or roll back the subsequent action.

[0162] S522. Compare the actual performance response with the preset performance constraints to determine the performance constraint state corresponding to the target control action.

[0163] Extract the actual service latency sequence, actual processor temperature sequence, and actual task queue sequence within the verification period from the actual performance response, and compare them with the preset service latency limit, processor temperature limit, and task queue limit, respectively. Specifically, this includes:

[0164] When the actual business latency, actual processor temperature, and actual task queue do not exceed the corresponding performance limits during the verification period, the performance constraint state corresponding to the target control action is determined as the non-limit-over state.

[0165] When any actual performance index exceeds the corresponding performance limit, the performance constraint state corresponding to the target control action is determined as an over-limit state.

[0166] S523. Based on the energy consumption response deviation and performance constraint status, a joint determination is made to determine the actual execution status corresponding to the target control action, including the action holding state or the action rollback state.

[0167] The energy consumption response deviation is compared with a preset deviation threshold. When the energy consumption response deviation does not exceed the preset deviation threshold, it is determined that the energy-saving effect of the target control action meets expectations. When the energy consumption response deviation exceeds the preset deviation threshold, it is determined that the energy-saving effect of the target control action does not meet expectations. The preset deviation threshold can be set according to the energy consumption response deviation distribution of historical effective action samples.

[0168] Furthermore, when the energy-saving effect meets expectations and the performance constraint is not exceeded, the actual execution state of the target control action is determined to be the action holding state.

[0169] When the energy-saving effect does not meet expectations, or the performance constraint is in an out-of-limit state, the actual execution state of the target control action is determined to be the action rollback state.

[0170] Among them, the performance constraint state has a priority determination function. Even if the actual net energy saving generated by the target control action reaches the predicted result, as long as the actual business latency, processor temperature or task queue exceeds the limit, the actual execution state will still be determined as the action rollback state.

[0171] By jointly determining the energy consumption response deviation and performance constraint status, we can avoid continuously executing control actions with insufficient actual energy-saving effect based solely on the fact that the performance has not exceeded the limit, and we can also avoid ignoring the impact of control actions on online business performance simply because the energy-saving effect is high.

[0172] S53. Maintain the target control action according to the actual execution state, or revert to the control state before executing the target control action, to obtain the computer system energy consumption optimization result.

[0173] When the actual execution state is the action hold state, the control state corresponding to the target control action is maintained, and the maintained control state and the corresponding actual energy consumption response and actual performance response are determined as the computer system energy consumption optimization result.

[0174] When the actual execution state is the action rollback state, the control state is restored to the state before the target control action was executed, and the control state after rollback and the corresponding actual energy consumption response and actual performance response are determined as the computer system energy consumption optimization result.

[0175] Read the control state recorded before executing the target control action, and perform the corresponding reverse recovery operation according to the action type of the target control action.

[0176] Specifically, when the target control action is a processor frequency reduction action, the processor is restored to the frequency before the action was executed; when the target control action is a core shutdown action, the shut-down processor core is re-enabled; when the target control action is a task migration action, the migrated task is restored to the original server or to a server that meets the original operating conditions; when the target control action is a batch processing task delay action, the delayed execution status of the corresponding task is canceled.

[0177] As one implementation method:

[0178] For action A, server S 08 The processor frequency was reduced from 2.8GHz to 2.4GHz. After the action was executed, the actual average power collected during the 5-minute verification period was 374 watts, the 95th percentile response latency was 111 milliseconds, the maximum task queue length was 140, the processor temperature dropped to 66.5℃, and the actual net energy saving was 0.0043 kWh.

[0179] The predicted net energy saving benefit corresponding to action A is 0.068 kWh. The predicted energy consumption is calculated as: 371×5÷60÷1000≈0.0309 kWh; the actual energy consumption is: 374×5÷60÷1000≈0.0312 kWh; the energy consumption response deviation is about 0.8%, which does not exceed the preset deviation threshold.

[0180] Meanwhile, the 95th percentile response latency did not exceed the service latency limit of 120 milliseconds, and the processor temperature and task queue did not exceed the limits. Therefore, it was determined that the energy-saving effect of action A met expectations, the performance constraint status was not exceeded, and the actual execution status of action A was determined to be the action hold status, continuing to maintain the processor frequency of 2.4 GHz.

[0181] In another running window, after the processor frequency reduction action is executed, the online request arrival rate suddenly increases by 35%, and the actual 95th percentile response latency rises to 127 milliseconds, exceeding the 120 millisecond service latency limit. At this time, regardless of whether the actual power decreases, the performance constraint state is determined to be in an over-limit state, and the actual execution state is determined to be in an action rollback state. Then, the processor frequency is restored to 2.8GHz within one control cycle.

[0182] After the rollback operation is completed, the processor frequency, number of active cores, task deployment location, and task scheduling status are reread to confirm the control status after the rollback. The control status after the rollback and the corresponding actual energy consumption response and actual performance response are used as the results of the computer system energy consumption optimization.

[0183] This step utilizes the actual energy consumption response and actual performance response after the target control action is executed to re-verify the predicted energy-saving effect and performance safety. When the actual result deviates from the predicted result or the performance exceeds the limit, the original control state is restored, thus forming a closed-loop control process of action prediction, action execution, actual verification, and state maintenance or rollback.

[0184] This invention also provides a computer system energy consumption optimization system based on machine learning, such as... Figure 2 As shown, it includes:

[0185] The state segmentation module is used to acquire computer system operating data and segment it into states to form a set of state segments;

[0186] The model building module is used to construct state samples from the set of state fragments and learn response relationships from the state samples to obtain a baseline response prediction model and a control action response model.

[0187] The candidate action generation module is used to generate candidate control actions based on the current operating state, and to compare and deduce the candidate control actions using the baseline response prediction model and the control action response model to obtain the candidate action prediction results.

[0188] The control action selection module is used to filter and evaluate the prediction results of candidate actions based on preset performance constraints, and determine the target control action.

[0189] The response adjustment module is used to execute the target control action and collect the actual response, adjust the control state according to the actual response, and obtain the computer system energy consumption optimization result.

[0190] Based on the foregoing description in conjunction with the accompanying drawings, those skilled in the art will understand that the embodiments of this application can also be implemented by software programs. Therefore, this application also provides a computer-readable storage medium. This computer-readable storage medium stores computer-readable instructions thereon, which, when executed by one or more processors, implement the method described above in conjunction with the accompanying drawings.

[0191] It should also be understood that the terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to limit the application. As used in this specification and claims, the singular forms “a,” “an,” and “the” are intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used in this specification and claims refers to any combination and all possible combinations of one or more of the associated listed items, and includes such combinations.

[0192] Although the embodiments of this application are as described above, the content is merely an example adopted for the purpose of facilitating understanding of this application and is not intended to limit the scope and application scenarios of this application. Any person skilled in the art described in this application may make any modifications and changes in the form and details of the implementation without departing from the spirit and scope disclosed in this application, but the scope of patent protection of this application shall still be determined by the scope defined in the appended claims.

Claims

1. A machine learning-based method for optimizing the energy consumption of a computer system, characterized in that, include: Acquire computer system operating data and segment it into states to form a set of state segments; State samples are constructed from the set of state fragments, and response relationships are learned from the state samples to obtain a baseline response prediction model and a control action response model. Candidate control actions are generated based on the current operating status. The candidate control actions are compared and deduced using the baseline response prediction model and the control action response model to obtain the candidate action prediction results, which include predicted energy consumption response and predicted performance response. The candidate action prediction results are screened and evaluated based on preset performance constraints to determine the target control action; The target control action is executed and the actual response is collected. The control state is adjusted according to the actual response to obtain the energy consumption optimization result of the computer system.

2. The computer system energy consumption optimization method according to claim 1, characterized in that, Based on preset performance constraints, the prediction results of candidate actions are screened and evaluated to determine the target control actions, including: The predicted performance response of each candidate control action is screened for performance risk to obtain executable control actions. Determine the predicted net energy savings and performance safety margins for each executable control action; Each executable control action is evaluated based on the predicted net energy savings and performance safety margin to determine the target control action.

3. The computer system energy consumption optimization method according to claim 2, characterized in that, Determine the predicted net energy savings and performance safety margins for each executable control action, including: The baseline energy consumption response when no control action is performed is determined using the baseline response prediction model. The predicted energy savings are obtained by time-series difference between the baseline energy consumption response and the predicted energy consumption response when each executable control action is performed. Based on the resource switching process and task processing changes corresponding to each executable control action, determine the action execution cost and recovery compensation energy consumption; The predicted energy savings are deducted from the energy consumption of the action execution cost and the energy consumption of recovery compensation to obtain the predicted net energy saving benefit. A safety margin sequence is constructed for the predicted performance response corresponding to each executable control action, and the performance safety margin is determined.

4. The computer system energy consumption optimization method according to claim 3, characterized in that, Based on the resource switching process and task processing changes corresponding to each executable control action, determine the action execution cost and recovery compensation energy consumption, including: Determine the corresponding resource switching energy consumption based on each executable control action; The energy consumption of data transmission and state recovery during the task migration process is statistically analyzed to obtain the task migration energy consumption. The energy consumption of resource switching and task migration are summarized to obtain the action execution cost; The amount of newly added backlogged tasks is determined based on the differences in task processing before and after each executable control action, and the additional energy consumption required to complete the newly added backlogged tasks is determined based on the amount of newly added backlogged tasks, thus obtaining the recovery compensation energy consumption.

5. The computer system energy consumption optimization method according to claim 3, characterized in that, A safety margin sequence is constructed for the predicted performance response corresponding to each executable control action, and the performance safety margin is determined, including: Extract the predicted values ​​of each performance index within the prediction period from the predicted performance response corresponding to each executable control action, and determine the difference between the predicted value of each performance index and the corresponding performance limit. Normalize the difference between the predicted value of each performance index and the corresponding performance limit to obtain the safety margin sequence for each performance index. Based on the minimum value and trend of each safety margin sequence, determine the performance safety margin corresponding to each executable control action.

6. The computer system energy consumption optimization method according to claim 2, characterized in that, Each executable control action is evaluated based on the predicted net energy savings and performance safety margin to determine the target control action, including: The predicted net energy saving benefit and performance safety margin corresponding to each executable control action are normalized to obtain the energy saving benefit evaluation value and safety margin evaluation value. The evaluation weights corresponding to the energy-saving benefit evaluation value and the safety margin evaluation value are determined based on the current operating status of the computer system, and a weighted calculation is performed to obtain the comprehensive evaluation value corresponding to each executable control action. The executable control action with the highest comprehensive evaluation value and that reaches the preset action execution threshold is identified as the target control action.

7. The computer system energy consumption optimization method according to claim 1, characterized in that, Execute the target control action and collect the actual response, adjust the control state according to the actual response, and obtain the computer system energy consumption optimization results, including: Execute the target control action and collect the actual response after the target control action is executed, wherein the actual response includes the actual energy consumption response and the actual performance response; Energy consumption deviation analysis and performance constraint analysis are performed on the actual response to determine the actual execution state of the target control action; Based on the actual execution state, the target control action is maintained, or the control state before the target control action was executed is reverted to obtain the computer system energy consumption optimization result.

8. The computer system energy consumption optimization method according to claim 7, characterized in that, Energy consumption deviation analysis and performance constraint analysis are performed on the actual response to determine the actual execution state of the target control action, including: A difference analysis is performed on the actual energy consumption response and the predicted energy consumption response corresponding to the target control action to obtain the energy consumption response deviation of the target control action; The actual performance response is compared with the preset performance constraints to determine the performance constraint state corresponding to the target control action. Based on the energy consumption response deviation and performance constraint status, a joint determination is made to determine the actual execution status corresponding to the target control action, including the action hold state or the action rollback state.

9. The computer system energy consumption optimization method according to claim 8, characterized in that, Based on a joint determination of the energy consumption response deviation and performance constraint status, the actual execution state corresponding to the target control action is determined, including: The energy consumption response deviation is compared with a preset deviation threshold to obtain the energy-saving effect status. When the energy-saving effect meets expectations and the performance constraint does not exceed the limit, the actual execution state corresponding to the target control action is determined to be the action holding state. When the energy-saving effect does not meet expectations or the performance constraint exceeds the limit, the actual execution state corresponding to the target control action is determined to be the action rollback state.

10. A computer system energy consumption optimization system based on machine learning, used to execute the computer system energy consumption optimization method as described in any one of claims 1-9, characterized in that, include: The state segmentation module is used to acquire computer system operating data and segment it into states to form a set of state segments; The model building module is used to construct state samples from the set of state fragments and learn response relationships from the state samples to obtain a baseline response prediction model and a control action response model. The candidate action generation module is used to generate candidate control actions based on the current operating state, and to compare and deduce the candidate control actions using the baseline response prediction model and the control action response model to obtain the candidate action prediction results. The control action selection module is used to filter and evaluate the prediction results of candidate actions based on preset performance constraints, and determine the target control action. The response adjustment module is used to execute the target control action and collect the actual response, adjust the control state according to the actual response, and obtain the computer system energy consumption optimization result.