Power consumption anomaly detection method and device, electronic equipment and storage medium

By recording the application's runtime and power consumption changes, calculating the current value, and combining historical current data with confidence intervals, the problem of inaccurate power consumption anomaly judgment in existing technologies is solved, enabling precise location and automated detection of power consumption anomalies.

CN121658306APending Publication Date: 2026-03-13BEIJING XIAOMI MOBILE SOFTWARE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-11
Publication Date
2026-03-13

AI Technical Summary

Technical Problem

Existing power consumption log analysis solutions struggle to quickly pinpoint concentrated problem areas and lack quantitative indicators, resulting in an inconspicuous and inaccurate assessment of power consumption anomalies.

Method used

By recording the application's runtime and power consumption changes, the current value is calculated. Using average current and single current values, combined with historical current data and confidence intervals, it is determined whether the application has abnormal power consumption. Furthermore, based on the scenario category and detection parameters, the abnormal point can be located more precisely.

Benefits of technology

It improves the accuracy and efficiency of power consumption anomaly detection, can quickly locate specific problem points, reduce manual intervention, and improve the accuracy and automation of power consumption anomaly detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121658306A_ABST
    Figure CN121658306A_ABST
Patent Text Reader

Abstract

The invention relates to a power consumption anomaly detection method and device, electronic equipment and a storage medium. The power consumption anomaly detection method comprises the following steps: recording the running duration of each running of at least one application program in a first time period, and recording the corresponding electric quantity change value of the at least one application program in each running duration; and for each application program in the at least one application program, obtaining a current value based on the running duration and the electric quantity change value, and determining whether the power consumption of the application program is abnormal or not based on the current value. According to the invention, based on the current value corresponding to the application program, whether the power consumption of the application program is abnormal can be determined.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of computer technology, and in particular to methods, apparatus, electronic devices and storage media for detecting abnormal power consumption. Background Technology

[0002] In the field of electronic devices, relying on log analysis to monitor user power consumption, performance, and thermal issues is a common practice. Unlike functional modules, it is difficult to pinpoint anomalies in user experience modules such as power consumption from a specific log segment. Therefore, existing power consumption log analysis solutions typically utilize overall resource analysis, defining thresholds for each resource segment. Once a threshold is exceeded, a resource anomaly is identified, thereby confirming an anomaly in power consumption.

[0003] In related technologies, the experience module often collects a large number of user logs in a short period of time. Since most logs do not have problems and it is difficult to find concentrated problem points in abnormal logs manually, R&D engineers need to solve the problem of quickly processing logs in batches, quickly filtering out abnormal logs, and completing the clustering of abnormal scenarios.

[0004] In related technologies, log processing for similar user experience modules involves automatic batch processing to filter and analyze overall resources, locate abnormal resource items, and store the data, thus identifying potential anomalies. However, this anomaly analysis lacks quantifiable metrics and cannot quickly pinpoint concentrated problem outbreaks from batch logs. Summary of the Invention

[0005] To overcome the problems existing in related technologies, this disclosure provides a power consumption anomaly detection method, apparatus, electronic device, and storage medium.

[0006] According to a first aspect of the present disclosure, a power consumption anomaly detection method is provided, comprising recording the runtime of at least one application during each run within a first time period, and recording the power consumption change value corresponding to the at least one application during each run; for each application in the at least one application, obtaining a current value based on the runtime and the power consumption change value, and determining whether the application has a power consumption anomaly based on the current value.

[0007] In one embodiment, obtaining a current value based on the runtime and the power change value, and determining whether the application has power consumption anomalies based on the current value, includes: determining a single current value and an average current, wherein the single current value is the ratio of the power change value within a single runtime to the corresponding single runtime, and the average current is the ratio of the sum of power changes for each runtime to the sum of all runtime values; and determining whether the application has power consumption anomalies based on the single current value and / or the average current.

[0008] In one embodiment, determining whether the application has power consumption anomalies based on the single current value and / or the average current includes: determining a current value threshold based on the current values ​​corresponding to the application running within a recorded historical time period, wherein the current value threshold is greater than the current values ​​corresponding to the application running within the historical time period; determining that the application has power consumption anomalies in response to the average current being greater than or equal to the current value threshold; and determining that the application has power consumption anomalies in response to the single current value being greater than or equal to the current value threshold and the single current value being within a confidence interval, wherein the confidence interval is determined based on the average current.

[0009] In one embodiment, the method further includes: in response to determining that the application has an abnormal power consumption, determining a target scene category corresponding to the application based on pre-stored scene categories, wherein the target scene category belongs to the pre-stored scene categories; determining target detection parameters corresponding to the target scene category according to the correspondence between scene categories and detection parameters; determining the current detection value and parameter threshold corresponding to each of the target detection parameters; if there is a detection parameter whose current detection value is greater than the parameter threshold, determining the detection parameter in the application whose current detection value is greater than the parameter threshold as an abnormal detection parameter.

[0010] In one implementation, the target scenario category includes at least one of the following: standby scenario, gaming scenario, video scenario, and daily usage scenario.

[0011] In one embodiment, before determining whether the application has power consumption abnormalities based on the current value, the method further includes: determining the battery state; wherein, in response to the battery state being normal or showing signs of aging, the method continues to determine whether the application has power consumption abnormalities based on the current value; and in response to the battery state being abnormal, the method stops determining whether the application has power consumption abnormalities based on the current value.

[0012] According to a second aspect of the present disclosure, a power consumption anomaly detection device is provided, comprising a recording unit for recording the runtime of at least one application during each run within a first time period, and recording the power consumption change value corresponding to the at least one application during each run; and a determining unit for obtaining a current value for each application based on the runtime and the power consumption change value, and determining whether the application has a power consumption anomaly based on the current value.

[0013] In one implementation, the current value is obtained based on the runtime and the power change value. Based on the current value, the determining unit determines whether the application has power consumption anomalies in the following manner: determining a single current value and an average current, wherein the single current value is the ratio between the power change value within a single runtime and the corresponding single runtime, and the average current is the ratio between the sum of power changes for each runtime and the sum of all runtimes; and determining whether the application has power consumption anomalies based on the single current value and / or the average current.

[0014] In one implementation, based on the single current value and / or the average current, the determining unit determines whether the application has power consumption anomalies in the following manner: a current value threshold is determined based on the current values ​​corresponding to the application running within a recorded historical time period, wherein the current value threshold is greater than the current values ​​corresponding to the application running within the historical time period; in response to the average current being greater than or equal to the current value threshold, the application is determined to have power consumption anomalies; in response to the single current value being greater than or equal to the current value threshold and the single current value being within a confidence interval, the application is determined to have power consumption anomalies, wherein the confidence interval is determined based on the average current.

[0015] In one embodiment, the determining unit is further configured to: in response to determining that the application has an abnormal power consumption, determine a target scene category corresponding to the application based on pre-stored scene categories, wherein the target scene category belongs to the pre-stored scene categories; determine target detection parameters corresponding to the target scene category according to the correspondence between scene categories and detection parameters; determine the current detection value and parameter threshold corresponding to each of the target detection parameters; if there is a detection parameter whose current detection value is greater than the parameter threshold, determine the detection parameter in the application whose current detection value is greater than the parameter threshold as an abnormal detection parameter.

[0016] In one implementation, the target scenario category includes at least one of the following: standby scenario, gaming scenario, video scenario, and daily usage scenario.

[0017] In one embodiment, before determining whether the application has power consumption abnormalities based on the current value, the determining unit is further configured to: determine the battery state; wherein, in response to the battery state being normal or showing signs of aging, the determination of whether the application has power consumption abnormalities based on the current value continues; and in response to the battery state being abnormal, the determination of whether the application has power consumption abnormalities based on the current value is stopped.

[0018] According to a third aspect of the present disclosure, an electronic device is provided, comprising: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to: execute the power consumption anomaly detection method described in the first aspect or any embodiment of the first aspect.

[0019] According to a fourth aspect of the present disclosure, a storage medium is provided, the storage medium storing instructions that, when executed by a processor, enable the processor to perform the power consumption anomaly detection method described in the first aspect or any embodiment of the first aspect.

[0020] The technical solutions provided by the embodiments of this disclosure may include the following beneficial effects: recording the runtime of at least one application within a first time period, and recording the power consumption change value of at least one application within each runtime period. Based on the power consumption change value and the runtime, a current value is obtained, which facilitates accurate assessment of the application's energy consumption. Based on the current value, it is possible to determine whether the application has abnormal power consumption.

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

[0022] The accompanying drawings, which are incorporated in and form a part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure.

[0023] Figure 1 This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment.

[0024] Figure 2 This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment.

[0025] Figure 3 This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment.

[0026] Figure 4 This is a flowchart illustrating a method for updating a database according to an exemplary embodiment.

[0027] Figure 5 This is a flowchart illustrating a method for determining anomaly detection parameters according to an exemplary embodiment.

[0028] Figure 6 This is a flowchart illustrating a method for determining battery state according to an exemplary embodiment.

[0029] Figure 7This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment.

[0030] Figure 8 This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment.

[0031] Figure 9 This is a block diagram illustrating a power consumption anomaly detection device according to an exemplary embodiment.

[0032] Figure 10 This is a block diagram illustrating a power consumption anomaly detection device according to an exemplary embodiment.

[0033] Figure 11 This is a block diagram illustrating a power consumption anomaly detection device according to an exemplary embodiment. Detailed Implementation

[0034] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this disclosure.

[0035] In the field of log analysis for electronic devices, the criteria for judging anomalies in logs from the experience module are heavily influenced by subjective factors in batch analysis, lacking a clear standard definition for the validity of feedback logs. When processing large volumes of logs, the analysis logic for resource anomaly localization is often still followed across multiple sub-scenarios involved in the experience module, failing to achieve detailed breakdown and hindering the localization of specific problems. Furthermore, log analysis typically only outputs resource analysis conclusions for each log entry, without breaking down and clustering problem scenarios, thus failing to pinpoint concentrated problem outbreak points.

[0036] In related technologies, when the user experience module detects abnormal power consumption, it typically captures logs from the first time interval. If no abnormality is found, logs from the second time interval are captured, and the logs are uploaded to a server for comparison and analysis. Alternatively, it uses overall resources as a benchmark, with the standard for judging power consumption anomalies being consistent across all scenarios, making it difficult to confirm the accuracy of the judgment. These technologies result in a lack of intuitive judgment criteria. If problems arise during initial use, it will be impossible to determine power consumption anomalies, the problem scenario will be unclear, and further manual confirmation is required, increasing manpower. Furthermore, the automation level is low, and the judgment criteria are not intuitive enough.

[0037] In view of this, this disclosure proposes a power consumption anomaly detection method, which uses current as the standard judgment criterion and compares it with historical current data to determine whether the application has power consumption anomalies.

[0038] Figure 1 This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment. Figure 1 As shown, the method includes steps S11 to S12.

[0039] In step S11, the runtime of at least one application during each run within the first time period is recorded, and the power consumption change value corresponding to each run of at least one application is also recorded.

[0040] In this embodiment of the disclosure, the runtime of at least one application within a first time period is recorded. It is understood that multiple applications can run within the first time period, and each application can correspond to multiple runtimes of varying lengths. The power consumption change value for each runtime of the application within the first time period is also recorded.

[0041] In step S12, for each application in at least one application, a current value is obtained based on the runtime and power change value, and based on the current value, it is determined whether the application has power consumption anomalies.

[0042] In this embodiment, the current value can be calculated using the following formula: (starting power consumption - ending power consumption) / (ending time - starting time). The current value for each running application may differ across its runtime. If an application is used multiple times within a first time period, that first time period includes multiple runtimes. Based on each runtime and the current value within each runtime, applications with abnormal power consumption can be identified.

[0043] In this embodiment of the disclosure, the power consumption of an application is determined based on the current value, improving the accuracy of power consumption anomaly detection. It can also pinpoint the running application corresponding to the current value and analyze what kind of power consumption anomaly the application is exhibiting.

[0044] In this embodiment of the disclosure, based on the current value, the following method can be used to determine whether the application has abnormal power consumption.

[0045] In this embodiment of the disclosure, applications with abnormal power consumption are identified within the running applications based on the average current and / or single current value over the runtime.

[0046] In this embodiment of the disclosure, the single current value and the average current are determined. Since the first time period includes at least one running duration, the single current value is obtained based on the ratio between the power change value of a single running duration and the corresponding single running duration, which facilitates obtaining the current value for each running duration within the first time period.

[0047] For example, the exported battery data (dump of service battery) in the log file can be parsed to obtain the applications or a preset number of applications with high power consumption within a first time period. Based on the usage duration of the obtained applications and the corresponding power change values, the current value can be obtained.

[0048] In this embodiment of the disclosure, the average current is obtained based on the ratio between the sum of the power change values ​​corresponding to each runtime and the sum of the power change values ​​corresponding to each runtime. The sum of the power change values ​​corresponding to each runtime can be understood as the product of the runtime of a single run of at least one application within a first time period and the current value corresponding to that single runtime, plus the sum of the current values ​​corresponding to each runtime.

[0049] In this embodiment of the disclosure, the average current of the application within the first time period is determined based on the current value corresponding to each runtime within the first time period, and the runtime values ​​within the first time period. For example, this can be understood as calculating the average current of the application within the first time period based on the current value of each application and iterating through each application. For instance, if a user uses application A for the first runtime, uses application B for the second runtime, and continues to use application A for the third runtime, then the average current of application A within the first time period is determined based on the two current values ​​and the two runtime values ​​of application A.

[0050] For example, the average current of the application during the first time period can be calculated using the following formula:

[0051] ∑(current*time) / ∑time=app_average_current. Where current is the current value, current*time is the change in power consumption over the runtime, and the average current (app_average_current) is obtained by comparing the sum of the power consumption changes for each runtime with the sum of all runtimes.

[0052] In this embodiment of the disclosure, since the first time period includes multiple runtimes, and the user can use multiple applications within the first time period, the current value of each application within each runtime is statistically analyzed to obtain the runtime of each application and the current value within that runtime within the first time period.

[0053] In this embodiment of the disclosure, for the scenario of electronic device standby, if it is determined that the screen has been off for four hours or other values, then the standby data is valid and the data will be recorded.

[0054] In this embodiment of the disclosure, the average current is a current value determined based on a current value and multiple runtimes within a first time period. Based on the average current and / or single current value, applications with abnormal power consumption are identified within the running applications.

[0055] In this embodiment of the disclosure, based on the average current and / or current value of the application within a first time period in the log file, it is easy to identify applications with abnormal power consumption and to accurately locate applications with abnormal power consumption.

[0056] In this embodiment of the disclosure, based on average current and / or single current values, applications with abnormal power consumption can be identified within the running application. Figure 2 This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment. Figure 2 As shown, the method includes steps S21 to S22b.

[0057] In step S21, a current value threshold is determined based on the current values ​​corresponding to the applications running within the recorded historical time period.

[0058] In this embodiment, the database stores multiple data points, including the current corresponding to historical applications, electronic device platform information, standard battery capacity of electronic devices, current database based on application usage time, and application classification. The electronic device platform information can be understood as different models of electronic devices. The application classification can be understood as categorizing applications according to their type, such as games, videos, daily use, and standby applications. It is understood that the data in the database needs to be continuously updated iteratively.

[0059] In this embodiment of the disclosure, using an application as an identifier, the current value corresponding to the application running within a historical time period is determined in the database, and a current value threshold is determined. The current value threshold is greater than the current value corresponding to the application running within the historical time period. For example, the current value threshold can be obtained by multiplying the current value corresponding to the application running within the historical time period by a coefficient greater than 1. For instance, the current value threshold can be the current value corresponding to the historically running application * 1.1.

[0060] In step S22a, in response to the average current being greater than or equal to a current value threshold, it is determined that the application has an abnormal power consumption.

[0061] In this embodiment of the disclosure, in response to the average current being greater than or equal to a current threshold, it is determined that the application has an abnormal power consumption. For applications with abnormal power consumption, the abnormal data of the application with abnormal power consumption is returned to the upper-layer data in the form of (application name, average current).

[0062] In step S22b, in response to a single current value being greater than or equal to a current value threshold and the single current value being within a confidence interval, it is determined that the application has an abnormal power consumption.

[0063] In this embodiment of the disclosure, in response to a single current value being greater than or equal to a current value threshold and the single current value being within a confidence interval, the application is determined to be an application with abnormal power consumption.

[0064] In this embodiment of the disclosure, the confidence interval is used to determine whether the current value threshold is valid. The current value threshold involves two values: the average current and the standard deviation. The average current is determined based on the current value and the runtime of each operation within the first time period, thus representing the average current of the application within that first time period. The standard deviation can be calculated based on the average current, for example, using the following formula: Where current represents the current value of the current application. The standard deviation is obtained by squared the difference between the current value and the average current for each runtime of the current application, and then dividing the squared difference by the total number of runtimes (n). Therefore, the confidence interval is the interval composed of this data.

[0065] In this embodiment, if a single current value is greater than a current threshold, and this current value falls within the confidence interval consisting of (average current - standard deviation) and (average current + standard deviation), then the current value greater than the current threshold is determined to be a valid value. Furthermore, the application is identified as having abnormal power consumption, and this value is returned to the upper layer in the form of (application name, abnormal current value, abnormal duration), where the abnormal current value is the current value corresponding to the application whose power consumption is determined to exist.

[0066] For example, in combination Figure 3 The method for detecting abnormal power consumption is explained. Figure 3 This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment. Figure 3 As shown, the input current value is used to calculate the average current and standard deviation for each application. If the current value is the average current and is greater than or equal to a current threshold, then (application name, average current) is returned. If the current value is the current value of the application over each runtime, is greater than or equal to the current threshold, and is within the confidence interval (considered valid data), then (application name, abnormal current value, abnormal duration) is returned.

[0067] This disclosure includes embodiments, such as Figure 4 As shown, Figure 4This is a flowchart illustrating a database update method according to an exemplary embodiment. If the average current and / or current value is less than a current value threshold, the application is determined to be an application without power consumption anomalies, and abnormal current data is determined to be absent. The current value and usage duration when no power consumption anomalies are found are imported into the database, updating the database with the current values ​​corresponding to historically running applications. For example, the usage duration in the database can be updated using the following formula: new time = old time + time, where new time is the updated duration data, old time is the duration data before the update, and time is the duration corresponding to the application without power consumption anomalies. The current data in the database is updated as follows: new current = (old current * old time + new current * time) / new time. Where new current is the updated current data, old current is the current data before the update, and new current * time is the current value corresponding to the application without power consumption anomalies. It is understood that if abnormal data is determined to exist, (application name, abnormal current value, abnormal duration) is returned.

[0068] In this embodiment, the application that determines power consumption anomalies based on average current accurately locates the source of data anomalies. By identifying power consumption anomalies based on the application's current values ​​over various runtime periods, the system can eliminate the possibility of overall power consumption anomalies due to a single anomaly in the calculation of data, thus ensuring the accuracy and validity of the input current values. This improves the accuracy of log analysis in the power consumption domain.

[0069] In this embodiment of the disclosure, after identifying an application with abnormal power consumption, the usage scenario of the application is further determined. For example, based on the type of the application, the parameters that need to be detected under this type are determined, thereby accurately locating the specific power consumption anomaly point of the application in a certain usage scenario.

[0070] Figure 5 This is a flowchart illustrating a method for determining anomaly detection parameters according to an exemplary embodiment. Figure 5 As shown, the method includes steps S31 to S34.

[0071] In step S31, in response to determining that the application has an abnormal power consumption, the target scenario category corresponding to the application is determined based on the pre-stored scenario categories.

[0072] In this embodiment of the disclosure, the application classification stored in the database can be understood as a pre-stored scenario category. After identifying the application with abnormal power consumption, the applications running within a first time period are clustered to determine the target scenario category corresponding to the application within the first time period. The scenario category can correspond to the application classification and may include different scenario categories such as game scenarios, video scenarios, daily use scenarios, and standby scenarios. The target scenario category can be one of the following: game scenarios, video scenarios, daily use scenarios, and standby scenarios. Based on the pre-stored scenario categories, the target scenario category of the application with abnormal power consumption is determined.

[0073] In step S32, the target detection parameters corresponding to the target scene category are determined according to the correspondence between scene category and detection parameters.

[0074] In this embodiment of the disclosure, different scene categories correspond to different detection parameters. Based on the correspondence between scene categories and detection parameters, once the target scene category is determined, the corresponding detection parameters are the target detection parameters.

[0075] In step S33, the current detection value and parameter threshold corresponding to each of the target detection parameters are determined.

[0076] In this embodiment of the disclosure, the detection parameters include multiple detection values, and the detection values ​​in each detection parameter are different, and each detection value corresponds to a parameter threshold.

[0077] In step S34, if there is a detection parameter whose current detection value is greater than the parameter threshold, the detection parameter in the application whose current detection value is greater than the parameter threshold is determined to be an abnormal detection parameter.

[0078] In this embodiment of the disclosure, the current detection value corresponding to each target detection parameter is determined. If there is a detection parameter whose current detection value is greater than a parameter threshold, the target scene category is determined based on the detection parameter. Based on the target scene category, the corresponding application is determined to be a power consumption abnormal application, and the detection parameter whose current detection value is greater than the parameter threshold is determined to be an abnormal detection parameter.

[0079] In this embodiment of the disclosure, based on the detection parameters in the target detection parameters that are greater than the parameter threshold, the abnormal detection parameters of the application with abnormal power consumption are determined. This not only identifies the application with abnormal power consumption, but also specifically identifies one of the detection parameters of the application with abnormal power consumption, thereby enabling rapid and automated location of the problem point of abnormal power consumption from batch logs.

[0080] In this embodiment of the disclosure, different scene categories correspond to different detection parameters. Based on the correspondence between scene categories and detection parameters, the target scene category can be determined to include at least one of the following target detection parameters. The target scene category includes at least one of the following: standby scene, game scene, video scene, and daily use scene.

[0081] In this embodiment of the disclosure, when the target scenario category is a standby scenario, the target parameters include at least one of the following: modem usage during the abnormal power consumption period, network status, Wi-Fi usage, signal status, lock status, wake-up status, wake-up application name, Bluetooth and / or GPS status information, and subsystem sleep status. Taking the modem as an example, it is necessary to obtain signal strength information and network status information for the first time period. If the detection value corresponding to the modem usage during the abnormal power consumption period is greater than the parameter threshold, then the modem usage during the abnormal power consumption period is determined to be an abnormal detection parameter, and the abnormal detection parameter exceeding the parameter threshold is output.

[0082] In this embodiment of the disclosure, when the target scene category is a game scene, the target detection parameters include at least one of the following: game mode during the abnormal power consumption period, target refresh rate, screen brightness, resolution, wireless communication data, performance mode, balanced mode, and background processor status. Specifically, for game-specific scenes, the focus can be primarily on whether the game mode is in performance mode or balanced mode, and the target refresh rate value. For example, if the detected value is determined to be the target refresh rate value, and the current detected value is greater than the parameter threshold, then the target refresh rate is an abnormal detection parameter, thus it can be determined that the target refresh rate is abnormal in the application within the game scene.

[0083] In this embodiment of the disclosure, when the target scene category is a video scene, the target detection parameters include at least one of the following: abnormal time period video toolbox, refresh rate, screen brightness, volume, wireless, communication data, background processor status, resolution, frequency boosting behavior, whether screen compensation is enabled, and frame interpolation. For certain specific scenarios within a video scene, the usage of the video toolbox within the video scene can be the primary focus. For example, if the detection value is determined to be an abnormal time period video toolbox, and the current detection value is greater than the parameter threshold, then the abnormal time period video toolbox is an abnormal detection parameter, and it can be determined that the abnormal time period video toolbox is abnormal in an application within a video scene.

[0084] In this embodiment of the disclosure, when the target scenario category is a daily use scenario, the target detection parameters include at least one of the following: audio / video application, camera application, refresh rate, wireless communication technology, processor information, resolution, and whether the audio / video application and camera application are abnormally locked. Among these, the focus can be primarily on whether the audio / video application and camera application are abnormally locked. For example, if the detection value is determined to be resolution, and the current detection value is greater than a parameter threshold, then resolution is an abnormal detection parameter, and therefore it can be determined that the resolution is abnormal in applications within a daily use scenario.

[0085] In this embodiment of the disclosure, each log is parsed in a loop, and the results are output to determine whether the application in each log is abnormal and the corresponding resource analysis conclusion. This enables the differentiation and clustering of problem scenarios, and can locate the concentrated problem outbreak points.

[0086] In this embodiment of the disclosure, before determining the application with abnormal power consumption based on the current value, it is also necessary to determine the battery capacity of the electronic device, and determine whether it is necessary to further determine the application with abnormal power consumption based on the current value based on the battery capacity.

[0087] In this embodiment of the disclosure, Figure 6 This is a flowchart illustrating a method for determining battery state according to an exemplary embodiment. Figure 6 As shown, the method includes steps S41 to S42b.

[0088] In step S41, the battery state is determined.

[0089] In this embodiment of the disclosure, before determining whether the application has power consumption abnormalities based on the current value, it is also necessary to determine the battery status. Based on the battery status, it is determined whether to continue based on whether the application has power consumption abnormalities or not.

[0090] In step S42a, in response to whether the battery status is normal or aging occurs, the application continues to determine whether there is an abnormal power consumption based on the current value.

[0091] In this embodiment, the current battery capacity is determined to be within a first capacity range, and a first prompt message is output. This first prompt message indicates that the battery is aging and prompts the user to continue identifying applications with abnormal power consumption. Alternatively, the current battery capacity is determined to be within a second capacity range, and a second prompt message is output. This second prompt message indicates that the battery is functioning normally and prompts the user to continue identifying applications with abnormal power consumption. The current battery capacity can be determined from records in a database. Battery aging can be understood as the battery performance beginning to decline, but not yet to the point of severely affecting usability; therefore, the user is prompted that the battery is aging, and the user continues to identify applications with abnormal power consumption. If the current battery capacity is within the second capacity range, the battery condition can be considered normal, and the user continues to identify applications with abnormal power consumption.

[0092] In this embodiment of the disclosure, the maximum battery capacity within the first capacity range is less than or equal to the minimum battery capacity within the second capacity range, the minimum battery capacity within the first capacity range is greater than a capacity threshold, the capacity threshold is less than the nominal capacity of the battery, and the maximum battery capacity within the second capacity range is the nominal capacity of the battery. The nominal capacity can be the capacity value specified on the product label or in the product specifications of the electronic device.

[0093] For example, the first capacity range can be [0.7 * nominal capacity, 0.8 * nominal capacity], the second capacity range can be [0.8 * nominal capacity, 1 * nominal capacity], and the capacity threshold can be * nominal capacity. The capacity range can also be other values, which are not specifically limited in this disclosure.

[0094] In step S42b, in response to an abnormal battery state, the determination of whether there is an abnormal power consumption in the application is stopped based on the current value.

[0095] In this embodiment of the disclosure, battery anomalies can include at least one of the following: the current battery capacity is less than a capacity threshold, the battery power consumption changes continuously and the duration of the change is less than a duration threshold, or the battery power consumption changes discontinuously. Where the current battery capacity is less than the capacity threshold, there may be a situation where the battery is severely aged, thus it can be determined that the power consumption anomaly is caused by severe battery aging. A continuous change in battery power consumption with a duration less than a duration threshold can be understood as a sudden drop in battery power. A sudden drop in battery power can be understood as the battery level changing continuously, but at an abnormal rate. For example, losing one bar of battery power in a short period of time. The criterion for judging a sudden drop in battery power can be that the average current of two consecutive battery power intervals is greater than 3A or other preset values, then it is considered a sudden drop in battery power, and all time periods of the drop and the average power loss time are output. Discontinuous changes in battery power consumption can be understood as a power outage phenomenon in the electronic device. A power outage can be understood as the battery level changing discontinuously. For example, the battery level is 50% one moment and 1% the next. The criterion for judging a power outage is that discontinuous changes in battery power constitute a power outage. It is understood that power outages usually occur when the battery is low or when the user restarts the electronic device. If a battery malfunction is detected, a third message is output. This third message indicates a battery malfunction and stops the application that is detecting power consumption issues.

[0096] In this embodiment of the disclosure, battery aging and battery malfunctions are excluded, thus avoiding the influence of battery status on power consumption anomaly detection and improving the accuracy of power consumption anomaly detection.

[0097] In this embodiment of the disclosure, based on the combination Figure 7 The method for detecting abnormal power consumption is explained. Figure 7 This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment. Figure 7 As shown, import the log file and calculate the current value of the application within the first time period. The log file records the current value of the application running within the first time period for each of the multiple durations. Based on (starting battery level - ending battery level) / (end time - start time), calculate the current value of the application for each duration within the first time period. Based on the current values, identify the applications with abnormal power consumption.

[0098] In this embodiment, current values ​​under different scenarios are clustered. Based on the current values, the application, time period, and log file exceeding the current value threshold are split for each scenario to obtain the average current. Based on the average current and / or current value, applications with abnormal power consumption are identified among the running applications. For example, if the average current is greater than or equal to the current value threshold, an application with abnormal power consumption is identified, and (application name, average current) is returned. The average current (app_average_current) is calculated based on ∑(current*time) / ∑time. If the current value is greater than or equal to the current value threshold, and the current value greater than or equal to the current value threshold is within a confidence interval, an application with abnormal power consumption is identified, and (application name, abnormal current value, abnormal duration) is returned. The confidence interval is [average current - standard deviation, average current + standard deviation], and the standard deviation is based on... get.

[0099] In this embodiment of the disclosure, after identifying an application with abnormal power consumption, the scenario is segmented, and based on the correspondence between scenario categories and detection parameters, the target detection parameters corresponding to the target scenario category are determined. The current detection value corresponding to each target detection parameter is determined. If there is a detection parameter whose current detection value is greater than a parameter threshold, it is determined as an abnormal detection parameter. Abnormal scenarios are clustered, and a conclusion is output.

[0100] In this embodiment of the disclosure, combined with Figure 8 The method for identifying power consumption anomalies based on scene categories is explained. Figure 8 This is a flowchart illustrating a power consumption anomaly detection method according to an exemplary embodiment. Figure 8 As shown, the abnormal application, scenario category, and abnormal current time period are input. The system retrieves the nominal capacity of the current electronic device's hardware battery from the database and obtains the current battery capacity. If the current battery capacity is less than 0.7 * nominal capacity, the battery is considered aged, an abnormal battery warning is issued, and the detection of applications with abnormal power consumption is stopped. If the current battery capacity is within the nominal capacity range of [0.7, 0.8], an abnormal battery condition is indicated, and the detection of applications with abnormal power consumption continues. If the current battery capacity is within the nominal capacity range of [0.8, 1], the battery is considered normal, and the detection of applications with abnormal power consumption continues. If the current battery capacity is within the nominal capacity range of [0.7, 1], and there is no sudden drop in battery power or / or power outage, the detection of applications with abnormal power consumption continues.

[0101] In this embodiment of the disclosure, if it is determined that the battery is not abnormal, the application scenario category is determined, where the scenario category includes standby, daily use, video, and game scenarios. In response to detecting that the target scenario category is a standby scenario, the target detection parameters include at least one of the following: modem usage, network status, Wi-Fi usage, signal status, lock status, wake-up status, wake-up application name, Bluetooth and / or GPS status information, and subsystem sleep status during the abnormal power consumption period. In response to detecting that the target scenario category is a game scenario, the target detection parameters include at least one of the following: game mode, target refresh rate, screen brightness, resolution, wireless communication data, performance mode, balanced mode, and background processor status during the abnormal power consumption period. In response to detecting that the target scenario category is a video scenario, the target detection parameters include at least one of the following: video toolbox, refresh rate, screen brightness, volume, wireless communication data, background processor status, resolution, frequency boosting behavior, whether screen compensation is enabled, and frame interpolation during the abnormal power consumption period. In response to the detection that the target scene category is a daily use scenario, the target detection parameters include at least one of the following: audio / video application, camera application, refresh rate, wireless communication technology, processor information, resolution, and whether the audio / video application and camera application are abnormally locked. Based on the determined anomaly detection parameters, abnormal resource information is recorded, abnormal scenes are clustered, analysis conclusions are output, and the outbreak points of abnormal scenes are summarized.

[0102] In this embodiment, current is used as the standard for judgment, and the comparison data is a historical current data database. Usage scenarios are divided into major categories such as hardware battery, standby, daily use, video, and gaming. Different scenarios focus on different aspects of the analytical resources, and the threshold judgment is more consistent with the specific circumstances of each scenario. This improves the accuracy of power consumption anomaly judgment, effectively helps to locate the concentrated feedback points of problems, and effectively reduces manpower pressure, allowing R&D engineers to pinpoint anomalies based on the conclusions.

[0103] Based on the same concept, this disclosure also provides a power consumption anomaly detection device 100.

[0104] It is understood that the power consumption anomaly detection device 100 provided in this disclosure includes hardware structures and / or software modules corresponding to each function in order to achieve the above-mentioned functions. In conjunction with the units and algorithm steps of the various examples disclosed in this disclosure, this disclosure can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed by hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the technical solutions of this disclosure.

[0105] Figure 9 This is a block diagram illustrating a power consumption anomaly detection device 100 according to an exemplary embodiment. (Refer to...) Figure 9 The device includes a recording unit 101 and a determination unit 102.

[0106] The recording unit 101 is used to record the runtime of at least one application during each run within a first time period, and to record the power consumption change value corresponding to at least one application during each runtime.

[0107] The determining unit 102 is used to obtain a current value for each application in at least one application based on the runtime and the power change value, and to determine whether the application has power consumption abnormalities based on the current value.

[0108] In one implementation, a current value is obtained based on the runtime and the power change value. Based on the current value, the determining unit 102 determines whether the application has power consumption anomalies in the following manner: determining the single current value and the average current, wherein the single current value is the ratio between the power change value within a single runtime and the corresponding single runtime, and the average current is the ratio between the sum of the power change values ​​for each runtime and the sum of the runtime values; and determining whether the application has power consumption anomalies based on the single current value and / or the average current.

[0109] In one implementation, based on a single current value and / or average current, the determining unit 102 determines whether the application has power consumption anomalies in the following manner: based on the current values ​​corresponding to the application running within a recorded historical time period, a current value threshold is determined, wherein the current value threshold is greater than the current values ​​corresponding to the application running within the historical time period; in response to the average current being greater than or equal to the current value threshold, the application is determined to have power consumption anomalies; in response to a single current value being greater than or equal to the current value threshold and the single current value being within a confidence interval, the application is determined to have power consumption anomalies, wherein the confidence interval is determined based on the average current.

[0110] In one embodiment, the determining unit 102 is further configured to: in response to determining that the application has an abnormal power consumption, determine the target scene category corresponding to the application based on pre-stored scene categories, wherein the target scene category belongs to the pre-stored scene categories; determine the target detection parameters corresponding to the target scene category according to the correspondence between scene categories and detection parameters; determine the current detection value and parameter threshold corresponding to each of the target detection parameters; if there is a detection parameter whose current detection value is greater than the parameter threshold, determine the detection parameter in the application whose current detection value is greater than the parameter threshold as an abnormal detection parameter.

[0111] In one implementation, the target scenario category includes at least one of the following: standby scenario, gaming scenario, video scenario, and daily use scenario.

[0112] In one embodiment, before determining whether the application has power consumption abnormalities based on the current value, the determining unit 102 is further configured to: determine the battery state; wherein, in response to the battery state being normal or showing signs of aging, the determination of whether the application has power consumption abnormalities based on the current value continues; and in response to the battery state being abnormal, the determination of whether the application has power consumption abnormalities based on the current value is stopped.

[0113] Regarding the apparatus in the above embodiments, the specific manner in which each module performs its operation has been described in detail in the embodiments related to the method, and will not be elaborated upon here.

[0114] Figure 10 This is a block diagram illustrating a power consumption anomaly detection device 200 according to an exemplary embodiment. Device 200 can be provided as a terminal. For example, device 200 can be a mobile phone, computer, digital broadcasting terminal, messaging device, game console, tablet device, medical device, fitness equipment, personal digital assistant, etc.

[0115] Reference Figure 10 The device 200 may include one or more of the following components: processing component 202, memory 204, power component 206, multimedia component 208, audio component 210, input / output (I / O) interface 212, sensor component 214, and communication component 216.

[0116] Processing component 202 typically controls the overall operation of device 200, such as operations associated with display, telephone calls, data communication, camera operation, and recording. Processing component 202 may include one or more processors 220 to execute instructions to perform all or part of the steps of the methods described above. Furthermore, processing component 202 may include one or more modules to facilitate interaction between processing component 202 and other components. For example, processing component 202 may include a multimedia module to facilitate interaction between multimedia component 208 and processing component 202.

[0117] Memory 204 is configured to store various types of data to support the operation of device 200. Examples of such data include instructions for any application or method operating on device 200, contact data, phonebook data, messages, pictures, videos, etc. Memory 204 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.

[0118] The power supply component 206 provides power to the various components of the device 200. The power supply component 206 may include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power to the device 200.

[0119] Multimedia component 208 includes a screen that provides an output interface between the device 200 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touchscreen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors may sense not only the boundaries of the touch or swipe action but also the duration and pressure associated with the touch or swipe operation. In some embodiments, multimedia component 208 includes a front-facing camera and / or a rear-facing camera. When the device 200 is in an operating mode, such as a shooting mode or a video mode, the front-facing camera and / or the rear-facing camera may receive external multimedia data. Each front-facing camera and rear-facing camera may be a fixed optical lens system or have focal length and optical zoom capabilities.

[0120] Audio component 210 is configured to output and / or input audio signals. For example, audio component 210 includes a microphone (MIC) configured to receive external audio signals when device 200 is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals may be further stored in memory 204 or transmitted via communication component 216. In some embodiments, audio component 210 also includes a speaker for outputting audio signals.

[0121] I / O interface 212 provides an interface between processing component 202 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to, home buttons, volume buttons, power buttons, and lock buttons.

[0122] Sensor assembly 214 includes one or more sensors for providing status assessments of various aspects of device 200. For example, sensor assembly 214 may detect the on / off state of device 200, the relative positioning of components such as the display and keypad of device 200, changes in the position of device 200 or a component of device 200, the presence or absence of user contact with device 200, the orientation or acceleration / deceleration of device 200, and temperature changes of device 200. Sensor assembly 214 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. Sensor assembly 214 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, sensor assembly 214 may also include an accelerometer, a gyroscope, a magnetometer, a pressure sensor, or a temperature sensor.

[0123] Communication component 216 is configured to facilitate wired or wireless communication between device 200 and other devices. Device 200 can access wireless networks based on communication standards, such as WiFi, 2G, or 3G, or combinations thereof. In one exemplary embodiment, communication component 216 receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, communication component 216 also includes a near-field communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on radio frequency identification (RFID) technology, Infrared Data Association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.

[0124] In an exemplary embodiment, the apparatus 200 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the methods described above.

[0125] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 204 including instructions, which can be executed by a processor 220 of the device 200 to perform the above-described method. For example, the non-transitory computer-readable storage medium may be a ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.

[0126] Figure 11 This is a block diagram illustrating a power consumption anomaly detection device 300 according to an exemplary embodiment. For example, device 300 may be provided as a server. (Refer to...) Figure 11The device 300 includes a processing component 322, which further includes one or more processors, and memory resources represented by memory 332 for storing instructions, such as application programs, that can be executed by the processing component 322. The application programs stored in memory 332 may include one or more modules, each corresponding to a set of instructions. Furthermore, the processing component 322 is configured to execute instructions to perform the methods described above.

[0127] Device 300 may also include a power supply component 326 configured to perform power management of device 300, a wired or wireless network interface 350 configured to connect device 300 to a network, and an input / output (I / O) interface 358. Device 300 may operate on an operating system stored in memory 332, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, or similar.

[0128] It is understood that in this disclosure, "multiple" refers to two or more, and other quantifiers are similar. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, and B alone. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. The singular forms "a," "the," and "the" are also intended to include the plural forms unless the context clearly indicates otherwise.

[0129] It is further understood that the terms "first," "second," etc., are used to describe various types of information, but this information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another, and do not indicate a specific order or degree of importance. In fact, the expressions "first," "second," etc., are completely interchangeable. For example, without departing from the scope of this disclosure, first information can also be referred to as second information, and similarly, second information can also be referred to as first information.

[0130] It is further understood that the terms “center,” “longitudinal,” “lateral,” “front,” “rear,” “up,” “down,” “left,” “right,” “vertical,” “horizontal,” “top,” “bottom,” “inner,” and “outer,” etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are only for the convenience of describing this embodiment and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation.

[0131] It can be further understood that, unless otherwise specified, "connection" includes both direct connections where no other components exist between the two parties and indirect connections where other components exist between them.

[0132] It is further understood that although operations are described in a specific order in the accompanying drawings in the embodiments of this disclosure, this should not be construed as requiring these operations to be performed in the specific order or serial order shown, or requiring all of the shown operations to be performed to obtain the desired result. In certain environments, multitasking and parallel processing may be advantageous.

[0133] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This disclosure is intended to cover any variations, uses, or adaptations of the invention that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein.

[0134] It should be understood that this disclosure is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this disclosure is limited only by the appended claims.

Claims

1. A method for detecting abnormal power consumption, characterized in that, include: Record the runtime of at least one application during each run within a first time period, and record the battery level change value corresponding to the at least one application during each run. For each of the at least one application, a current value is obtained based on the runtime and the power change value, and based on the current value, it is determined whether the application has abnormal power consumption.

2. The method according to claim 1, characterized in that, The process of obtaining a current value based on the runtime and the power consumption change, and determining whether the application has abnormal power consumption based on the current value, includes: Determine the single current value and the average current. The single current value is the ratio between the change in power within a single running time and the corresponding single running time. The average current is the ratio between the sum of the power changes for each running time and the sum of the values ​​for each running time. Based on the single current value and / or the average current, determine whether the application has power consumption anomalies.

3. The method according to claim 2, characterized in that, The step of determining whether the application has power consumption anomalies based on the single current value and / or the average current includes: Based on the current values ​​corresponding to the application running within the recorded historical time period, a current value threshold is determined, wherein the current value threshold is greater than the current values ​​corresponding to the application running within the historical time period. In response to the average current being greater than or equal to the current value threshold, it is determined that the application has an abnormal power consumption. In response to the single current value being greater than or equal to the current value threshold and the single current value being within a confidence interval, it is determined that the application has an abnormal power consumption, wherein the confidence interval is determined based on the average current.

4. The method according to any one of claims 1 to 3, characterized in that, The method further includes: In response to determining that the application has an abnormal power consumption, a target scene category corresponding to the application is determined based on pre-stored scene categories, wherein the target scene category belongs to the pre-stored scene categories; Based on the correspondence between scene categories and detection parameters, determine the target detection parameters corresponding to the target scene category; Determine the current detection value and parameter threshold corresponding to each of the target detection parameters; If there is a detection parameter whose current detection value is greater than the parameter threshold, the detection parameter in the application whose current detection value is greater than the parameter threshold is determined to be an abnormal detection parameter.

5. The method according to claim 4, characterized in that, The target scenario category includes at least one of the following: standby scenario, gaming scenario, video scenario, and daily use scenario.

6. The method according to claim 1, characterized in that, Before determining whether the application has power consumption anomalies based on the current value, the method further includes: Determine the battery status; In response to whether the battery status is normal or shows signs of aging, the system continues to determine whether the application has abnormal power consumption based on the current value. In response to the abnormal battery status, the determination of whether the application has abnormal power consumption based on the current value is stopped.

7. A power consumption anomaly detection device, characterized in that, include: A recording unit is used to record the runtime of at least one application during each run within a first time period, and to record the power consumption change value corresponding to the at least one application during each run. The determining unit is configured to, for each of the at least one application, obtain a current value based on the runtime and the power change value, and determine whether the application has power consumption anomalies based on the current value.

8. The apparatus according to claim 7, characterized in that, The current value is obtained based on the runtime and the power change value. Based on the current value, the determining unit determines whether the application has power consumption anomalies in the following manner: Determine the single current value and the average current. The single current value is the ratio between the change in power within a single running time and the corresponding single running time. The average current is the ratio between the sum of the power changes for each running time and the sum of the values ​​for each running time. Based on the single current value and / or the average current, determine whether the application has power consumption anomalies.

9. The apparatus according to claim 8, characterized in that, Based on the single current value and / or the average current, the determining unit determines whether the application has power consumption anomalies in the following manner: Based on the current values ​​corresponding to the application running within the recorded historical time period, a current value threshold is determined, wherein the current value threshold is greater than the current values ​​corresponding to the application running within the historical time period. In response to the average current being greater than or equal to the current value threshold, it is determined that the application has an abnormal power consumption. In response to the single current value being greater than or equal to the current value threshold and the single current value being within a confidence interval, it is determined that the application has an abnormal power consumption, wherein the confidence interval is determined based on the average current.

10. The apparatus according to any one of claims 7 to 9, characterized in that, The determining unit is further configured to: In response to determining that the application has an abnormal power consumption, a target scene category corresponding to the application is determined based on pre-stored scene categories, wherein the target scene category belongs to the pre-stored scene categories; Based on the correspondence between scene categories and detection parameters, determine the target detection parameters corresponding to the target scene category; Determine the current detection value and parameter threshold corresponding to each of the target detection parameters; If there is a detection parameter whose current detection value is greater than the parameter threshold, the detection parameter in the application whose current detection value is greater than the parameter threshold is determined to be an abnormal detection parameter.

11. The apparatus according to claim 10, characterized in that, The target scenario category includes at least one of the following: standby scenario, gaming scenario, video scenario, and daily use scenario.

12. The apparatus according to claim 7, characterized in that, Before determining whether the application has power consumption anomalies based on the current value, the determining unit is further configured to: Determine the battery status; In response to whether the battery status is normal or shows signs of aging, the system continues to determine whether the application has abnormal power consumption based on the current value. In response to the abnormal battery status, the determination of whether the application has abnormal power consumption based on the current value is stopped.

13. An electronic device, characterized in that, include: processor: Memory used to store processor-executable instructions; The processor is configured to execute the power consumption anomaly detection method according to any one of claims 1 to 6.

14. A storage medium, characterized in that, The storage medium stores instructions that, when executed by a processor, enable the processor to perform the power consumption anomaly detection method according to any one of claims 1 to 6.