Control method and device
By determining target strategies in electronic devices and controlling power consumption, the problem of insufficient power management in the existing technology is solved, and intelligent power management of the device at critical moments is realized to ensure sufficient power to run tasks.
Patent Information
- Application Number
- CN202410704518.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-31
- Publication Date
- 2024-09-27
AI Technical Summary
Existing power control methods for mobile phones or computers rely on the user's personal experience and the device's own power management system, and cannot accurately predict and adapt to the user's specific usage needs, resulting in possible battery depletion at critical moments.
By determining the target strategy in the electronic device and controlling the power consumption based on the target strategy, it ensures that the device can run specified tasks at critical moments. For example, by adjusting the parameters of task scheduling, power consumption mode and display interface, the power usage is optimized.
It realizes intelligent power management of electronic devices at critical moments, ensuring that the device has enough power to run tasks when needed and avoids running out of power.
Smart Images

Figure CN118708046A
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of electronic equipment, and in particular to a control method and device. Background Art
[0002] In the existing technology, for power control of mobile phones or computers, users usually manually adjust the power usage settings or rely on the device's own power management system. Although these traditional methods can extend the use time of the device to a certain extent, they have obvious shortcomings. On the one hand, the manual adjustment method relies on the user's personal experience and memory, which is neither convenient nor intelligent enough; on the other hand, the device's own power management system often lacks prediction and adaptation to the user's specific usage needs, and cannot accurately control the power according to the user's actual needs, which may cause the device to run out of power at a critical moment. Summary of the invention
[0003] One aspect of the present disclosure provides a control method, including: in response to the existence of a first task in an electronic device, determining a target strategy, a first running moment of the first task satisfies a first task condition; and controlling power consumption of the electronic device based on the target strategy so that the electronic device can run the first task at the first running moment.
[0004] Optionally, in response to the existence of the first task in the electronic device, before determining the target strategy, the control method also includes: when the first parameter satisfies the first condition, if the second parameter satisfies the second condition, determining that the electronic device is in the target mode, and in response to the existence of the first task in the electronic device in the target mode; the first parameter represents the efficacy selection data input by the target object, and the second parameter represents the power supply method of the power supply component of the electronic device.
[0005] Optionally, controlling the power consumption of the electronic device based on the target policy includes: controlling the execution of at least a second task and / or a third task based on the target policy; the second task is a task currently executed by the electronic device, and the third task is a task that the electronic device is about to execute during the period from the current time to the first execution time.
[0006] Optionally, the running of at least the second task and / or the third task is controlled based on the target policy, including: if the target policy includes the first policy, controlling the second task to stop running at the second running time based on the first policy; if the target policy includes the second policy, controlling the third task to start running at the third running time and / or stop running at the fourth running time based on the second policy; if the target policy includes the third policy, adjusting the parameters of the display interface of the electronic device when the second task and / or the third task are running based on the third policy, so that the display interface of the electronic device is in the target display state.
[0007] Optionally, determining the target strategy includes: determining a target display state of a display interface of the electronic device; determining at least one second task and / or a fourth task; the fourth task being a task that the electronic device will run after the current moment, as predicted based on historical tasks that have run in the electronic device; determining a predicted running time corresponding to at least one second task and / or a fourth task; if a fourth task exists, determining a third task that meets a second condition from the fourth task; the second condition being that the third running time of the fourth task is before the first running time; and generating a target strategy based on the target display state and the predicted running time corresponding to each task.
[0008] Optionally, determining the predicted running time corresponding to at least one second task and / or fourth task includes: calculating the power consumption per unit time of at least one second task and / or fourth task, wherein, when at least one second task and / or fourth task needs to be displayed on the display interface, the power consumption per unit time is calculated when the display interface is in a target display state; predicting the predicted running time corresponding to each task based on the power consumption per unit time corresponding to each task and a first constraint condition; wherein the first constraint condition includes: when at least one second task and / or fourth task is run in the electronic device for the corresponding predicted running time, the remaining power of the electronic device at the first running time can meet the target power required to run the first task.
[0009] Optionally, before calculating the power consumption per unit time of at least one second task and / or fourth task, the control method also includes: determining whether the predicted running time of each task can be calculated; if the predicted running time of each task cannot be calculated, looping the following operations until the predicted running time of each task can be calculated: updating the target display state, wherein, for tasks that need to be displayed on the display interface, the power consumption per unit time of the tasks is less than the power consumption per unit time before the update under the updated target display state; and recalculating the power consumption per unit time of each task according to the updated target display state.
[0010] Optionally, a target strategy is generated based on the target display state and the predicted running time corresponding to each task, including: the target strategy includes a first strategy, and the first strategy is determined based on the predicted running time corresponding to the second task; the target strategy includes a second strategy, and the second strategy is determined based on the predicted running time corresponding to the third task; the target strategy includes a third strategy, and target values of display parameters of the display interface are determined based on the target display state, and the third strategy is generated based on the target values of the display parameters.
[0011] Optionally, in the process of controlling the power consumption of an electronic device based on a target strategy, the control method also includes: in response to the start of a fifth task, predicting the power consumption of the fifth task, the fifth task being a task that the electronic device is about to run between the current and first running moments and that was not predicted based on historical tasks that have run in the electronic device; determining a second constraint condition based on the power consumption of the fifth task, the second constraint condition including: before the first running moment, the electronic device can run the fifth task; redetermining the target strategy based on the second constraint condition; and controlling the power consumption of the electronic device based on the redetermined target strategy so that the electronic device can run the first task at the first running moment.
[0012] Another aspect of the present disclosure provides a control device, including: a determination module, for determining a target strategy in response to the existence of a target task in an electronic device; a target running time of the target task satisfies a first task condition; and a control module, for controlling the power consumption of the electronic device based on the target strategy, so that the electronic device can run the target task at the target running time.
[0013] Another aspect of the present disclosure provides an electronic device, comprising: at least one processor; and a memory connected to the at least one processor; wherein the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the above-mentioned control method.
[0014] Another aspect of the present disclosure provides a computer-readable storage medium storing computer-executable instructions, which are used to implement the above control method when executed.
[0015] Another aspect of the present disclosure provides a computer program, which includes computer executable instructions, and the instructions are used to implement the above control method when executed. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] The above and other objects, features and advantages of the present disclosure will become more apparent through the following description of the embodiments of the present disclosure with reference to the accompanying drawings, in which:
[0017] Figure 1 The application scenario of the control method according to the embodiment of the present disclosure is schematically shown;
[0018] Figure 2 A flow chart schematically shows a control method according to an embodiment of the present disclosure;
[0019] Figure 3 Another flow chart of the control method according to an embodiment of the present disclosure is schematically shown;
[0020] Figure 4Another flow chart of the control method according to an embodiment of the present disclosure is schematically shown;
[0021] Figure 5 Another flow chart of the control method according to an embodiment of the present disclosure is schematically shown;
[0022] Figure 6 A flowchart of determining a target strategy in a control method according to an embodiment of the present disclosure is schematically shown;
[0023] Figure 7 A flowchart for determining the predicted operating time in the control method according to an embodiment of the present disclosure is schematically shown;
[0024] Figure 8 A flowchart of updating power consumption per unit time in a control method according to an embodiment of the present disclosure is schematically shown;
[0025] Fig. 9 A flowchart of generating a target strategy in a control method according to an embodiment of the present disclosure is schematically shown;
[0026] Fig.10 Another flow chart of the control method according to an embodiment of the present disclosure is schematically shown;
[0027] Fig.11 A block diagram schematically shows a control device according to an embodiment of the present disclosure; and
[0028] Fig.12 A block diagram schematically shows an example electronic device that can be used to implement the method of the embodiment of the present disclosure. DETAILED DESCRIPTION
[0029] Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of the present disclosure. In addition, in the following description, descriptions of well-known structures and technologies are omitted to avoid unnecessary confusion of the concepts of the present disclosure.
[0030] The terms used herein are only for describing specific embodiments and are not intended to limit the present disclosure. The terms "comprise", "include", etc. used herein indicate the existence of features, steps, operations and / or components, but do not exclude the existence or addition of one or more other features, steps, operations or components.
[0031] All terms (including technical and scientific terms) used herein have the meanings commonly understood by those skilled in the art unless otherwise defined. It should be noted that the terms used herein should be interpreted as having a meaning consistent with the context of this specification and should not be interpreted in an idealized or overly rigid manner.
[0032] Some block diagrams and / or flow charts are shown in the accompanying drawings. It should be understood that some blocks or combinations thereof in the block diagrams and / or flow charts may be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that these instructions, when executed by the processor, may create a device for implementing the functions / operations described in these block diagrams and / or flow charts.
[0033] Therefore, the technology of the present disclosure can be implemented in the form of hardware and / or software (including firmware, microcode, etc.). In addition, the technology of the present disclosure can take the form of a computer program product on a computer-readable medium storing instructions, which can be used by an instruction execution system or in combination with an instruction execution system. In the context of the present disclosure, a computer-readable medium can be any medium that can contain, store, transmit, propagate, or transmit instructions. For example, a computer-readable medium can include, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, device, or propagation medium. Specific examples of computer-readable media include: magnetic storage devices, such as magnetic tape or hard disk (HDD); optical storage devices, such as compact disk (CD-ROM); memory, such as random access memory (RAM) or flash memory; and / or wired / wireless communication links.
[0034] Figure 1 The application scenario of the control method according to the embodiment of the present disclosure is schematically shown. It should be noted that: Figure 1 The examples shown are merely scenarios in which the embodiments of the present disclosure can be applied, to help those skilled in the art understand the technical content of the present disclosure, but do not mean that the embodiments of the present disclosure cannot be used in other devices, systems, environments or scenarios.
[0035] like Figure 1 As shown, in the application scenario of the control method of the embodiment of the present disclosure, a power management unit 110 is running in the electronic device 100, and the electronic device has an input unit 120 for a target object such as a user to operate, such as a touch screen button on the screen, etc. The input unit 120 can convert the user's operation into a signal recognizable by the power management unit 110. After receiving the signal, the power management unit 110 can control the electronic device to switch between multiple power management modes.
[0036] The power management mode includes at least a first mode 111 and a second mode 112. The first mode 111 refers to the electronic device being in a normal operating mode. All tasks running in the electronic device are in the default operating mode of the task in the electronic device. For example, the screen brightness is 80 and constant, task 1 keeps running in the background, and task 2 is automatically closed after the running is completed.
[0037] The second mode 112 means that the electronic device is in the performance mode, that is, in this mode, the electronic device will determine whether there is a preset first task in the electronic device that needs to be completed at the target time. If not, the actual control content of its power mode can be the same as the first mode. If so, at least one task in the electronic device is controlled to control the power consumption of the electronic device so that the electronic device can run the first task at the first operating time, such as turning off task 1, adjusting the screen brightness to 50, etc.
[0038] It should be noted that the above scenario can be when the electronic device is powered by a power source that needs to consider power consumption, such as in DC mode (Direct Current Mode), where the electronic device is not connected to an external public AC power source, but uses the battery of the electronic device itself for DC power supply. The above scenario can also be when the electronic device is in a comprehensive power supply mode, but the external power supply cannot meet the power consumption of the electronic device, and auxiliary power supply is required through the electric field of the electronic device itself.
[0039] However, the power management systems that come with existing devices often lack the ability to predict and adapt to users' specific usage needs. They cannot achieve accurate automatic management of the power of electronic devices in the above scenarios and often need to rely on users' personal experience and memory.
[0040] Based on the above problems, the present disclosure provides a control method, including determining a target strategy in response to the existence of a first task in an electronic device, so that the first running moment of the first task satisfies the first task condition; and controlling the power consumption of the electronic device based on the target strategy so that the electronic device can run the first task at the first running moment.
[0041] Figure 2 The flowchart of the control method according to the embodiment of the present disclosure is schematically shown.
[0042] like Figure 2 As shown, the control method provided by the embodiment of the present disclosure includes operations S210~S220.
[0043] In operation S210, in response to the existence of the first task in the electronic device, the target strategy is determined, and the first running time of the first task satisfies the first task condition. Specifically, the first task can be a task that the user pre-sets in the electronic device to be run at the first running time, and the first task condition is that the first running time that the first task needs to start running is a certain time in the future. For example, the current time is 12 o'clock in the morning, and the user pre-sets in the electronic device that at 5 o'clock in the afternoon, a meeting needs to be held through the electronic device, then the meeting is the first task, and the first running time is 5 o'clock in the afternoon. The target strategy represents the various strategies that the electronic device needs to execute. For example, the electronic device can control the operation mode of various tasks in the electronic device according to the target strategy. The target strategy specifies the specific strategies that the electronic device needs to execute to adapt to the task requirements. These strategies may include but are not limited to adjusting the power consumption mode of the device, optimizing task scheduling, managing background applications, etc. It can be understood that this embodiment does not limit the way to detect whether the first task exists. For example, the calendar event can be monitored to determine the first task, or the first task can be determined based on the user's daily work habits of using the electronic device.
[0044] In operation S220, the power consumption of the electronic device is controlled based on the target policy so that the electronic device can run the first task at the first running moment. From the moment when the power consumption of the electronic device is controlled based on the target policy, the electronic device controls the running mode of each task in the electronic device according to the target policy, and then controls the power consumption of the electronic device running each task, so that the electronic device has enough power to run the first task at the first running moment. Among them, the task may include at least one of a screen-on task, a standby task, a shutdown task, and a program running task. The screen-on task refers to a task that keeps the display interface lit while other tasks in the electronic device do not use it. It can be understood that if any task needs to be displayed on the display interface, then the power consumption of the screen at this time is included in the power consumption of the task.
[0045] For example, the execution time of the target policy is 12:00 am. At 5:00 pm, a meeting needs to be held through an electronic device. When the electronic device starts to run the meeting task, it needs to ensure that there is at least 10% power in the electronic device. Then, starting from 12:00 am, the power consumption of the electronic device is controlled based on the target policy, so that at 5:00 pm, the remaining power in the electronic device is greater than or equal to 10%.
[0046] According to an embodiment of the present disclosure, before operation S210, it may also include: in response to the existence of the first task in the electronic device, determining whether the electronic device can run the first task at the first running moment. Specifically, before determining the target strategy, based on the current power supply mode and power management mode of the electronic device, determine whether the remaining power of the electronic device at the first running moment meets the running requirements of the first task when the electronic device maintains the current power supply mode and power management mode to run various tasks. If yes, the solution process ends, and the electronic device maintains the current power supply mode and power management mode to run various tasks without adjusting the power. If not, determine the target strategy.
[0047] According to the embodiments of the present disclosure, the power consumption of the electronic device is controlled through the target strategy, so that the electronic device can intelligently manage various tasks in the electronic device and ensure the power of the device at critical moments.
[0048] Figure 3 Another flow chart of a control method according to an embodiment of the present disclosure is schematically shown.
[0049] like Figure 3 As shown, in Figure 2 Based on the embodiment, before operation S210, operation S310 is further included.
[0050] In operation S310, when the first parameter satisfies the first condition, if the second parameter satisfies the second condition, it is determined that the electronic device is in the target mode, and in the target mode, in response to the presence of the first task in the electronic device. The first parameter represents the efficacy selection data input by the target object, and the second parameter represents the power supply mode of the power supply component of the electronic device. Specifically, before determining the target strategy, it is necessary to determine whether the electronic device needs to control the power consumption of the electronic device according to the target strategy, and whether the electronic device has the first task.
[0051] According to an embodiment of the present disclosure, it is determined whether the first parameter satisfies the first condition. The first parameter represents the efficacy selection data input by the target object. The target object, such as a user, can input the efficacy selection data required by the user into the electronic device through an input device. The efficacy selection data can be, for example, the parameters of the power management mode in the aforementioned application scenario, and different parameters represent different power management modes; the first condition is that the first parameter is the target parameter. For example, in the first mode, the parameter of the power management mode is "Normal mode", and the efficacy management of the electronic device is performed. In the second mode, the parameter of the power management mode is "efficiency mode". Only when the parameter of the power management mode is "efficiency mode" is it necessary to execute the subsequent technical solutions of the present disclosure, and when the parameter of the power management mode is "Normal mode", the electronic device does not execute the subsequent technical solutions, that is, it does not determine whether the first task exists in the electronic device, nor does it determine the target strategy.
[0052] According to an embodiment of the present disclosure, when the first parameter satisfies the first condition, if the second parameter satisfies the second condition, it is determined that the electronic device is in the target mode. The second parameter characterizes the power supply mode of the power supply component of the electronic device. The power supply mode of the power supply component of the electronic device may include a first power supply mode, a second power supply mode, and a third power supply mode, wherein the first power supply mode is a mode in which the electronic device is powered by, for example, an external power supply that does not need to consider power consumption, such as connecting to an external power grid through a power interface and powering the external power grid; the second power supply mode is a mode in which the electronic device is powered by a power supply that needs to consider power consumption, such as a battery of the electronic device itself and / or a battery external to the electronic device; the third power supply mode is a power supply mode in which the electronic device is connected to a power supply that does not need to consider power consumption, but the power supply cannot meet the power consumption of the electronic device, and the electronic device needs to be auxiliaryly powered by a power supply such as a battery that needs to consider power consumption.
[0053] According to an embodiment of the present disclosure, the second condition may be that the power supply mode of the power supply component of the electronic device is the second power supply mode or the third power supply mode. When the second parameter satisfies the second condition, it is determined that the electronic device is in the target mode, that is, it is determined that the electronic device is in the second power supply mode or the electronic device is in the third power supply mode. When the electronic device is in the second power supply mode or the electronic device is in the third power supply mode, it is determined whether the first task exists in the electronic device. If so, the target strategy is determined. If not, the solution process ends, and the electronic device operates in the default mode under the corresponding power supply mode without adjusting the power.
[0054] According to an embodiment of the present disclosure, when the first running moment of the first task satisfies the first condition, there may be multiple target policies determined. When there are multiple target policies, the multiple policies may be displayed to the target object, such as a user, through a display interface. In response to the selection input of the target object, the policy selected by the target object is determined from the multiple target policies and the power consumption of the electronic device is controlled based on the policy selected by the target object.
[0055] Figure 4 Another flow chart of a control method according to an embodiment of the present disclosure is schematically shown.
[0056] like Figure 4 As shown, in Figure 2 Based on the embodiment, in operation S220, the execution of at least the second task and / or the third task is controlled based on the target policy, so that the electronic device can execute the first task at the first execution time.
[0057] According to an embodiment of the present disclosure, the second task is a task currently being executed by the electronic device, and the third task is a task that the electronic device is about to execute during a period from the current time to the first execution time.
[0058] According to an embodiment of the present disclosure, before operation S220, it is also necessary to determine the corresponding second task and / or third task in the target policy, wherein the second task is the task currently being run by the electronic device, and the third task is the task that the electronic device is about to run from now to the first running time. The running time of the third task is after the target policy is determined and before the first running time of the first task. For example, the execution time of the target policy is 12 o'clock in the morning, and at 5 o'clock in the afternoon, a meeting needs to be conducted through an electronic device. Then the second task can be Task 1 being executed in the electronic device at 12 o'clock, and the third task can be Task 2 that needs to be run in the electronic device at 3 o'clock in the afternoon.
[0059] On this basis, at least the operation of the second task and / or the third task is controlled based on the target policy to control the power consumption of the electronic device, for example, to reduce the power consumption of the electronic device so that the electronic device can run the first task at the first running time. For example, the execution time of the target policy is 12 o'clock in the morning, and at 5 o'clock in the afternoon, a meeting needs to be held through the electronic device. At 12 o'clock, task 1 is being executed in the electronic device, and at 3 o'clock in the afternoon, task 2 needs to be run in the electronic device. Then, the operation of task 1 can be controlled based on the target policy, or the operation of task 2 can be controlled based on the target policy, or the operation of task 1 and task 2 can be controlled simultaneously based on the target policy, so that the electronic device has enough power for the meeting at 5 o'clock in the afternoon.
[0060] Figure 5 Another flow chart of a control method according to an embodiment of the present disclosure is schematically shown.
[0061] like Figure 5 As shown, in Figure 4 Based on the embodiment, operation S220 may include one or more of operations S510 to S530.
[0062] According to an embodiment of the present disclosure, the target policy may include a first policy, a second policy, and a third policy.
[0063] In operation S510, if the target policy includes the first policy, the second task is controlled to stop running at the second running time based on the first policy. Among them, the first policy represents the policy for controlling the stopping of the second task, and the first policy can record at least one second task and the second running time corresponding to the second task, and the second running time indicates the time when the second task needs to stop running. For example, the execution time of the target policy is 12 o'clock in the morning, and at 5 o'clock in the afternoon, a meeting needs to be conducted through an electronic device. At 12 o'clock, task 1 is being executed in the electronic device, and at 3 o'clock in the afternoon, task 2 needs to be run in the electronic device. The first policy is included in the target policy, and the first policy records task 1 and the stop time corresponding to task 1 as 2 o'clock in the afternoon, then at 2 o'clock in the afternoon, the operation of task 1 is stopped. It should be noted that the second running time can be the current time, that is, the execution time of the target policy. When the second time is the current time, the electronic device immediately stops the operation of the second task.
[0064] In operation S520, if the target policy includes a second policy, the third task is controlled to start running at the third running time and / or stop running at the fourth running time based on the second policy. Among them, the second policy represents a policy for controlling the start and stop of the third task. The second policy may record at least one third task, and the third running time and / or fourth running time corresponding to the third task. The third running time indicates the time when the third task needs to start running, and the fourth running time indicates the time when the third task needs to stop running. For example, the execution time of the target policy is 12 o'clock in the morning. At 5 o'clock in the afternoon, a meeting needs to be held through an electronic device, and at 3 o'clock in the afternoon, task 2 needs to be run in the electronic device. The second policy is included in the target policy, and the second policy records task 2, the third running time corresponding to task 2 is 3 o'clock in the afternoon, and the fourth running time corresponding to task 2 is 4 o'clock in the afternoon. Then the electronic device will start running task 2 at 3 o'clock in the afternoon, and will shut down task 2 until it runs to 4 o'clock in the afternoon.
[0065] It should be noted that the running time recorded in the second strategy may only include the third running time. In the case of only including the third running time, the electronic device will start the corresponding third task at the third running time, and will not control the closing of the third task. The running time recorded in the second strategy may also only include the fourth running time. In the case of only including the third running time, the electronic device does not forcibly control the specific start time of the third task (but still needs to ensure that the start time of the third task is between the current time and the first running time), and only stops the running of the third task at the corresponding fourth running time.
[0066] It should be noted that the fourth running time is after the third running time and not after the first running time, or the fourth running time can be the same as the third running time and not after the first running time. In the case where the fourth running time is the same as the third running time, it means that the running time of the corresponding third task is zero, and when the second strategy is executed, the corresponding actual operation is to prevent the start of the third task based on the second strategy control.
[0067] In operation S530, if the target policy includes a third policy, the parameters of the display interface of the electronic device when the second task and / or the third task are running are adjusted based on the third policy, so that the display interface of the electronic device is in the target display state. Among them, the third policy characterizes the parameters of the display interface of the electronic device when the second task and / or the third task are running, and different parameters correspond to different display states of the display interface, and different display states cause different power consumption. For example, the execution time of the target policy is 12 o'clock in the morning, and at 5 o'clock in the afternoon, a meeting needs to be conducted through an electronic device. At 12 o'clock, task 1 is being executed in the electronic device, and at 3 o'clock in the afternoon, task 2 needs to be run in the electronic device. The third policy records that the brightness of the display screen of task 2 during operation is 50. Then in the case of a specific example of the second policy as in the above operation S520, the electronic device will run task 2 from 3 to 4 o'clock in the afternoon, and the brightness of the display screen is 50 when running task 2.
[0068] Figure 6 A flowchart for determining a target strategy in a control method according to an embodiment of the present disclosure is schematically shown.
[0069] like Figure 6 As shown, in Figure 5 Based on the embodiment, operation S210 may include operations S610 to S650.
[0070] In operation S610, the target display state of the display interface of the electronic device is determined. During the task execution, some tasks need to display corresponding pictures on the display interface of the electronic device. At this time, the parameters of the display interface of the electronic device are different, and the power consumption caused by running the task is also different. Therefore, it is also necessary to control the parameters of the display interface of the electronic device to control the power consumption of the electronic device. Optionally, when the target display state of the display interface of the electronic device is determined for the first time, the state of the display interface of the current electronic device can be used as the target display state, that is, the parameters of the display interface of the current electronic device are kept unchanged.
[0071] In operation S620, at least one second task and / or fourth task is determined; the fourth task is a task that is predicted to be executed by the electronic device after the current moment based on historical tasks executed in the electronic device.
[0072] Specifically, the fourth task can be determined by, for example, predicting through a preset startup prediction model. A person skilled in the art can select appropriate historical data as a sample and select an appropriate model for training to obtain a prediction model. The specific training process will not be described in detail here. Through the trained startup prediction model, it is possible to predict the fourth task that will be run by the electronic device after the current moment, and the third running time of the fourth task is at the current moment and after the current moment. For example, the execution time of the target strategy is 12 o'clock in the morning. In the historical running tasks of the electronic device, Task 2 is often started at 3 o'clock in the afternoon, Task 3 is often started at 11 o'clock in the morning, and Task 4 is often started at 6 o'clock in the afternoon. Then, through the prediction of the prediction model, Task 2 and Task 4 can be determined as the fourth task.
[0073] In operation S630, the predicted running time corresponding to at least one second task and / or fourth task is determined. Specifically, the second task and / or the fourth task can be predicted by, for example, a preset duration prediction model. Those skilled in the art can select appropriate historical data as samples, select an appropriate model for training to obtain a prediction model, and the specific training process is not described in detail here. After the trained duration prediction model, the running time of the second task and / or the fourth task in the electronic device can be predicted. For example, in the historical running tasks of the electronic device, Task 1 is often run for 1 hour, and Task 2 is often run for 2 hours. Then, through the duration prediction model, it is concluded that the predicted running time corresponding to Task 1 can be 1 hour, and the predicted running time corresponding to Task 2 can be 2 hours.
[0074] In operation S640, if there is a fourth task, a third task that satisfies the second condition is determined from the fourth tasks; the second condition is that the running time is before the first running time. For example, in the above example, Task 2 and Task 4 are the fourth tasks, and their corresponding running times are 3 pm and 6 pm respectively, and the first running time of the first task is 5 pm, then Task 2 is selected as the third task.
[0075] According to the embodiment of the present disclosure, after the second task and / or the third task are preliminarily determined, further screening can be performed, and the tasks that meet the third condition are selected from the preliminarily determined second tasks and / or third tasks as the final second tasks and / or third tasks. The third condition may be that the power consumption generated by the second task and / or the third task during the predicted running time is greater than or equal to a preset power consumption threshold. For example, the estimated running time of task 1 is 1 hour, and the estimated running time of task 2 is 2 hours. The power consumption generated by the electronic device running task 1 must be greater than or equal to 1% of the upper limit of the power of the electronic device. Then task 1 is used as the final second task or third task. If the power consumption generated by the electronic device running task 2 is less than 1% of the upper limit of the power of the electronic device, it is deemed that the power consumption of the task can be ignored, and task 2 is removed from the second task or the third task.
[0076] In other embodiments, the third condition may be that the power consumption generated by the second task and / or the third task during the preset running time is greater than or equal to the preset power consumption threshold. For example, if the power consumption generated by the electronic device running Task 1 for 24 hours is greater than or equal to 1% of the upper limit of the power of the electronic device, then Task 1 is used as the final second task or third task. It should be noted that the setting of the above thresholds is only an example, and those skilled in the art can set appropriate thresholds according to actual conditions.
[0077] In operation S650 , a target policy is generated according to the target display state and the predicted running time corresponding to each task.
[0078] Figure 7 The flowchart for determining the predicted operating time in the control method according to the embodiment of the present disclosure is schematically shown.
[0079] like Figure 7 As shown, in Figure 6 Based on the illustrated embodiment, operation S630 may include operations S710 to S720.
[0080] In operation S710, the power consumption per unit time of at least one second task and / or fourth task is calculated, wherein, when at least one second task and / or fourth task needs to be displayed on the display interface, the power consumption per unit time is calculated when the display interface is in a target display state.
[0081] Specifically, the power consumption per unit time of at least one second task and / or fourth task can be calculated by a power consumption detection tool pre-configured in the electronic device, based on the historical operation data of the second task and / or fourth task in the electronic device, wherein when at least one second task and / or fourth task needs to be displayed on the display interface, the power consumption per unit time is calculated when the display interface is in the target display state. For example, Task 1 needs to be displayed on the display interface, and the target display state is that the brightness of the display interface is 50, then the power consumption per unit time of Task 1 is calculated when the brightness of the display interface is 50.
[0082] In operation S720, the predicted running time corresponding to each task is predicted based on the power consumption per unit time corresponding to each task and the first constraint condition. The first constraint condition includes: when at least one second task and / or fourth task is run in the electronic device for a corresponding predicted running time, the remaining power of the electronic device at the first running moment can meet the target power required to run the first task.
[0083] Before operation S720, it may also include predicting the power consumption of the first task, and determining the target power required by the electronic device at the first operating moment according to the power consumption of the first task and the current power of the electronic device. The specific method of predicting the power consumption of the first task can be predicted according to a preset power consumption model. Those skilled in the art can select appropriate historical data as samples and select an appropriate model for training to obtain a prediction model. The specific training process is not described in detail here. It should be noted that the power consumption of the first task at this time is the power consumption under the target display state.
[0084] For example, the second task and / or the fourth task determined in operation S620 includes i tasks, which are respectively denoted as F1 to F i , F1~F i The corresponding power consumption per unit time is P1~P i , assuming that the predicted running time to be predicted is X1~X i , then we can establish the objective function by solving the linear programming problem, establish the inequality condition of the linear programming problem according to the first constraint condition, and calculate X1~X i The value of .
[0085] Specifically, the formula for the power consumption E generated by the electronic device during the total time T from the start of executing the strategy to the first running moment is:.
[0086]
[0087] Inequality condition 1 of the linear programming problem is:
[0088]
[0089] Inequality condition 2 of the linear programming problem is:
[0090]
[0091] Among them, E current is the current power of the electronic device, E goal A target power level is set to enable the electronic device to run the first task at the first moment.
[0092] Then according to inequality conditions 1 and inequality conditions 2, taking formula (1) as the objective function, we can solve the linear programming problem to obtain X1~X i The value of .
[0093] Then we can solve X1~X i When the value of is , its optimal solution can be used as a set of solutions to obtain the predicted running time corresponding to each task, and then generate the target strategy.
[0094] In some other embodiments, the above linear programming problem may be further supplemented with inequality conditions. For example, when the running time of the second task or the fourth task must be greater than a certain value, the following inequality conditions may be further supplemented: n ≥T n , where n is the subscript of the task whose running time must be greater than a certain value in 1~i, X n is the estimated running time of the task, T n The task running time must be greater than a specific value. Correspondingly, at least one set of X1~X i The solution is used as the predicted runtime corresponding to each task.
[0095] When there are multiple solutions to the above linear programming problem, the optimal solution and at least one group of suboptimal solutions can be selected as the predicted running time corresponding to each task. The suboptimal solution can be obtained by adding constraints to the linear programming problem, for example, adding constraints: in each group of solutions obtained, the difference between each Xi corresponding to the same task Fi needs to be greater than a preset threshold.
[0096] Figure 8 The flowchart of updating the power consumption per unit time in the control method according to the embodiment of the present disclosure is schematically shown.
[0097] like Figure 8 As shown, in Figure 7 Based on the illustrated embodiment, operations S810 to S840 may be further included before operation S710.
[0098] In operation S810, it is determined whether the predicted running time of each task can be calculated. Figure 7 In the illustrated embodiment, the objective function (1) may be unable to be solved under the inequality conditions of the specified linear programming problem. That is, at this time, no matter how the running time of the task in the electronic device is adjusted, the electronic device cannot meet the power required to run the first task at the first running time.
[0099] When the predicted running time of each task cannot be calculated, operations S820 to S830 are executed in a loop until the predicted running time of each task can be calculated.
[0100] In operation S820, the target display state is updated, wherein the power consumption per unit time of the task that needs to be displayed on the display interface is less than the power consumption per unit time before the update in the updated target display state. For example, if the brightness of the display interface is adjusted from 80 to 50, then at this time, the power consumption per unit time of the task that needs to be displayed on the display interface at a brightness of 50 is less than the power consumption of the display interface at a brightness of 80. The updated target display state can be updated, for example, by a preset update gradient, for example, setting the screen brightness to decrease by 10 each time it is updated.
[0101] In operation S830, the power consumption per unit time of each task is recalculated according to the updated target display state.
[0102] It can be understood that after an update, the power consumption per unit time of the tasks that need to be displayed on the display interface is lower than before. Therefore, it is equivalent to changing the constraint range of the objective function (1) in disguise. At this time, the power consumption per unit time of each task is recalculated, and the power consumption per unit time of each task is calculated based on the recalculated power consumption per unit time, and Figure 7 The calculation method in the illustrated embodiment determines whether the predicted running time of each task can be calculated. If so, the calculation is performed. If not, operations S820 to S830 are repeated to further reduce the power consumption per unit time of the tasks that need to be displayed on the display interface.
[0103] Fig. 9 A flowchart for generating a target strategy in a control method according to an embodiment of the present disclosure is schematically shown.
[0104] like Fig. 9 As shown, in Figure 6 Based on the embodiment, operation S650 may include operations S910 to S930.
[0105] The target strategy may include at least one of the first strategy, the second strategy and the third strategy. Among them, the first strategy represents the strategy for controlling the stopping of the second task. The first strategy may record at least one second task and the second running time corresponding to the second task. The second running time indicates the time when the second task needs to stop running. The second strategy represents the strategy for controlling the starting and stopping of the third task. The second strategy may record at least one third task and the third running time and / or fourth running time corresponding to the third task. The third running time indicates the time when the third task needs to start running, and the fourth running time indicates the time when the third task needs to stop running. The third strategy represents the parameters of the display interface of the electronic device when the second task and / or the third task are running.
[0106] In operation S910, the first strategy is determined according to the predicted running time corresponding to the second task. Specifically, the second running time of the second task is determined according to the predicted running time corresponding to the second task and the current time, and the first strategy is determined according to the second running time. For example, the execution time of the target strategy is 12:00 am, and the predicted running time of Task 1 is 1 hour. Since Task 1 belongs to the second task, Task 1 should stop running after 1 hour from the current time. Then, the first strategy will record "Stop running Task 1 at 13:00 pm".
[0107] In operation S920, a second strategy is determined according to the predicted running time corresponding to the third task. Specifically, the third running time and / or the fourth running time of the third task are determined according to the predicted running time of the third task, and the second strategy is determined according to the third running time and / or the fourth running time of the third task. It should be noted that the fourth running time is after the third running time and not after the first running time, or the fourth running time may be the same as the third running time and not after the first running time. In the case where only the third running time of the third task is determined by the predicted running time of the third task, the time obtained by adding the third running time to the predicted running time is the first running time or after the first running time. In the case where only the fourth running time of the third task is determined by the predicted running time of the third task, the time obtained by subtracting the start time of the third task from the fourth running time of the third task is less than or equal to the predicted running time of the third task.
[0108] For example, the execution time of the target policy is 12:00 am, and the electronic device needs to run a meeting task (first task) at 5:00 pm (first running time). Task 2 is the fourth task, and the predicted running time is 2 hours. Then, three second strategies can be determined. The first is that the third running time and the fourth running time of Task 2 are both determined, for example, "start Task 2 at 2:00 pm and stop Task 2 at 4:00 pm"; the second is that the third time of Task 2 is determined, for example, "start Task 2 at 4:00 pm"; the third is that the fourth time of Task 2 is determined, for example, "start Task 2 at any time between 2:00 pm and 3:00 pm, and stop Task 2 at 4:00 pm".
[0109] According to an embodiment of the present disclosure, the target policy also includes a third policy. In operation S830, the target value of the display parameter of the display interface is determined according to the target display state, and the third policy is generated according to the target value of the display parameter. For example, the third policy may be "set the screen brightness of the display to 50".
[0110] Fig.10 Another flow chart of a control method according to an embodiment of the present disclosure is schematically shown.
[0111] like Fig.10 As shown, based on the foregoing embodiment, the process of controlling the power consumption of the electronic device based on the target strategy may further include operations S1010 to S1040.
[0112] The target policy has been executed, but before the first running time, the target object, such as the user, has an emergency and needs to execute an unpredicted new task, that is, the fifth task. At this time, if the power consumption of the electronic device is still controlled according to the determined target policy, since the fifth task increases the power consumption, the electronic device may not have enough power to meet the power demand of running the first task at the first running time. In view of this, the process of controlling the power consumption of the electronic device based on the target policy may also include the following operations.
[0113] In operation S1010, in response to the start of the fifth task, the power consumption of the fifth task is predicted. The fifth task is a task that the electronic device is about to run during the period from the current time to the first running time, but is not predicted based on historical tasks that have been run in the electronic device. The specific method of predicting the power consumption of the fifth task can be predicted based on a preset power consumption model. Those skilled in the art can select appropriate historical data as samples and select an appropriate model for training to obtain a prediction model. The specific training process is not described in detail here. Through the prediction model, the power consumption generated by the electronic device running the fifth task from the start of the fifth task to the end of the task can be predicted.
[0114] In operation S1020, a second constraint condition is determined according to the power consumption of the fifth task, where the second constraint condition includes: before the first running time, the electronic device can run the fifth task.
[0115] In operation S1030, the target strategy is re-determined according to the second constraint condition. Figure 7 On the basis of the embodiment shown, an inequality condition of the objective function is added. Or, the power consumption of the electronic device before the first running time is re-determined according to the power consumption of the fifth task, that is, the inequality condition 2 of the objective function is modified and added. For example:
[0116] Modify the inequality condition 2 of the linear programming problem to:
[0117]
[0118] Among them, E unexpected is the power consumption of the fifth task. Figure 7 Each step of the illustrated embodiment determines a target strategy.
[0119] In operation S1040, the power consumption of the electronic device is controlled according to the re-determined target policy, so that the electronic device can run the first task at the first running time. That is, according to the re-determined target policy, not only the electronic device can run the first task at the first running time, but also the electronic device needs to run the fifth task before the first running time.
[0120] Fig.11 A block diagram of a control device according to an embodiment of the present disclosure is schematically shown.
[0121] like Fig.11 As shown, the control device 1100 includes a determination module 1110 and a control module 1120 .
[0122] The determination module 1110 may perform, for example, operation S210 for determining a target strategy in response to the existence of a target task in the electronic device; the target running time of the target task satisfies the first task condition.
[0123] The control module 1120 may perform, for example, operation S220 for controlling the power consumption of the electronic device based on the target policy so that the electronic device can run the target task at the target running time.
[0124] For example, any multiple of the acquisition module 1110 and the power supply module 1120 can be combined in one module for implementation, or any one of the modules can be split into multiple modules. Alternatively, at least part of the functions of one or more of these modules can be combined with at least part of the functions of other modules and implemented in one module. According to an embodiment of the present disclosure, at least one of the acquisition module 1110 and the power supply module 1120 can be at least partially implemented as a hardware circuit, such as a field programmable gate array (FPGA), a programmable logic array (PLA), a system on a chip, a system on a substrate, a system on a package, an application-specific integrated circuit (ASIC), or can be implemented by hardware or firmware such as any other reasonable way of integrating or packaging the circuit, or implemented in any one of the three implementation methods of software, hardware and firmware or in any appropriate combination of any of them. Alternatively, at least one of the acquisition module 1110 and the power supply module 1120 can be at least partially implemented as a computer program module, and when the computer program module is run, the corresponding function can be executed.
[0125] Fig.12 A block diagram of an example electronic device that can be used to implement the method of an embodiment of the present disclosure is schematically shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workbenches, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.
[0126] like Fig.12 As shown, the device 1200 includes a computing unit 1201, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 1202 or a computer program loaded from a storage unit 1208 into a random access memory (RAM) 1203. In the RAM 1203, various programs and data required for the operation of the device 1200 can also be stored. The computing unit 1201, the ROM 1202, and the RAM 1203 are connected to each other via a bus 1204. An input / output (I / O) interface 1205 is also connected to the bus 1204.
[0127] Multiple components in the electronic device 1200 are connected to the I / O interface 1205, including: an input unit 1206, such as a keyboard, a mouse, etc.; an output unit 1207, such as various types of displays, speakers, etc.; a storage unit 1208, such as a disk, an optical disk, etc.; and a communication unit 1209, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 1209 allows the device 1200 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0128] The computing unit 1201 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 1201 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 1201 performs the various methods and processes described above, such as the application running method. For example, in some embodiments, the application running method may be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as a storage unit 1208. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 1200 via the ROM 1202 and / or the communication unit 1209. When the computer program is loaded into the RAM 1203 and executed by the computing unit 1201, one or more steps of the application running method described above may be performed. Alternatively, in other embodiments, the computing unit 1201 may be configured to execute the application running method in any other appropriate manner (e.g., by means of firmware).
[0129] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0130] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0131] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or device, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0132] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0133] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.
[0134] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship between the client and the server is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. Among them, the server may be a cloud server, also known as a cloud computing server or a cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services ("Virtual Private Server", or "VPS" for short). The server may also be a server of a distributed system, or a server combined with a blockchain.
[0135] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.
[0136] The above specific implementations do not constitute a limitation on the protection scope of the present disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present disclosure shall be included in the protection scope of the present disclosure.
Claims
1. A control method, comprising: In response to a first task existing in the electronic device, determining a target policy, a first running time of the first task satisfying a first task condition; The power consumption of the electronic device is controlled based on the target policy so that the electronic device can run the first task at the first running time.
2. The method according to claim 1, wherein in response to the first task existing in the electronic device, before determining the target strategy, the method further comprises: In the case where the first parameter satisfies the first condition, if the second parameter satisfies the second condition, determining that the electronic device is in a target mode, in response to the presence of a first task in the electronic device in the target mode; The first parameter represents the efficacy selection data input by the target object, and the second parameter represents the power supply mode of the power supply component of the electronic device.
3. The method according to claim 1, wherein controlling the power consumption of the electronic device based on the target policy comprises: controlling the execution of at least the second task and / or the third task based on the target strategy; The second task is a task currently being executed by the electronic device, and the third task is a task that will be executed by the electronic device during the period from now to the first execution time.
4. The method according to claim 3, wherein the step of controlling at least the operation of the second task and / or the third task based on the target strategy comprises: If the target policy includes a first policy, controlling the second task to stop running at a second running time based on the first policy; If the target policy includes a second policy, controlling the third task to start running at a third running time and / or stop running at a fourth running time based on the second policy; If the target policy includes a third policy, parameters of the display interface of the electronic device when the second task and / or the third task are executed are adjusted based on the third policy so that the display interface of the electronic device is in a target display state.
5. The method according to claim 4, wherein determining the target strategy comprises: Determining a target display state of a display interface of the electronic device; determining at least one of the second task and / or the fourth task; The fourth task is a task that is predicted to be executed by the electronic device at or after the current moment based on historical tasks that have been executed in the electronic device; Determine a predicted running time corresponding to at least one of the second task and / or the fourth task; If the fourth task exists, determining the third task satisfying the second condition from the fourth tasks; The second condition is that the third running time of the fourth task is before the first running time; The target strategy is generated according to the target display state and the predicted running time corresponding to each task.
6. The method according to claim 5, wherein determining the predicted running time corresponding to at least one of the second task and / or the fourth task comprises: Calculating the power consumption per unit time of at least one of the second tasks and / or the fourth tasks, wherein when at least one of the second tasks and / or the fourth tasks needs to be displayed on the display interface, the power consumption per unit time is calculated when the display interface is in the target display state; Predicting the predicted running time corresponding to each task according to the power consumption per unit time corresponding to each task and the first constraint condition; Among them, the first constraint condition includes: when at least one of the second task and / or the fourth task is run in the electronic device for a corresponding predicted running time, the remaining power of the electronic device at the first running time can meet the target power required to run the first task.
7. The method according to claim 6, before calculating the power consumption per unit time of at least one of the second task and / or the fourth task, further comprising: Determine whether the predicted runtime of each task can be calculated; If the predicted running time of each task cannot be calculated, the following operations are performed repeatedly until the predicted running time of each task can be calculated: Updating the target display state, wherein the power consumption per unit time of the task that needs to be displayed on the display interface in the updated target display state is less than the power consumption per unit time before the update; According to the updated target display status, the power consumption per unit time of each task is recalculated.
8. The method according to claim 5, wherein generating the target strategy according to the target display state and the predicted running time corresponding to each task comprises: The target strategy includes the first strategy, and the first strategy is determined according to the predicted running time corresponding to the second task; The target strategy includes the second strategy, and the second strategy is determined according to the predicted running time corresponding to the third task; The target strategy includes a third strategy, and a target value of a display parameter of the display interface is determined according to the target display state, and the third strategy is generated according to the target value of the display parameter.
9. The method according to any one of claims 5 to 8, wherein the process of controlling the power consumption of the electronic device based on the target policy further comprises: In response to starting a fifth task, predicting the power consumption of the fifth task, wherein the fifth task is a task that is to be run by the electronic device during the period from now to the first running time and is not predicted based on historical tasks that have been run in the electronic device; Determining a second constraint condition according to the power consumption of the fifth task, wherein the second constraint condition includes: before the first running time, the electronic device can run the fifth task; re-determining the target strategy according to the second constraint; The power consumption of the electronic device is controlled according to the re-determined target policy, so that the electronic device can run the first task at the first running time.
10. A control device comprising: A determination module, configured to determine a target strategy in response to the existence of a target task in the electronic device; The target running time of the target task satisfies a first condition; as well as The control module is used to control the power consumption of the electronic device based on the target strategy so that the electronic device can run the target task at the target running time.
Citation Information
Cited By
Notebook computer endurance optimization method combined with AI technology
CN119472964A
Laptop Battery Life Optimization Method Integrated with AI Technology
CN119472964B
