CN117336609A - Power consumption control method and device, electronic equipment and storage medium - Google Patents

Power consumption control method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN117336609A
CN117336609A CN202210712572.7A CN202210712572A CN117336609A CN 117336609 A CN117336609 A CN 117336609A CN 202210712572 A CN202210712572 A CN 202210712572A CN 117336609 A CN117336609 A CN 117336609A
Authority
CN
China
Prior art keywords
power consumption
consumption level
image acquisition
acquisition module
image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210712572.7A
Other languages
Chinese (zh)
Inventor
廖宽龙
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Xiaomi Mobile Software Co Ltd
Original Assignee
Beijing Xiaomi Mobile Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Xiaomi Mobile Software Co Ltd filed Critical Beijing Xiaomi Mobile Software Co Ltd
Priority to CN202210712572.7A priority Critical patent/CN117336609A/en
Publication of CN117336609A publication Critical patent/CN117336609A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N17/00Diagnosis, testing or measuring for television systems or their details
    • H04N17/002Diagnosis, testing or measuring for television systems or their details for television cameras

Landscapes

  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • General Health & Medical Sciences (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Studio Devices (AREA)

Abstract

An embodiment of the present disclosure is a power consumption control method, including: determining the current jitter amplitude of an image acquisition module; determining a target power consumption level required by image acquisition of the image acquisition module according to the current jitter amplitude; when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, reducing the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in unit time; in this way, power consumption can be reduced appropriately according to the jitter amplitude.

Description

Power consumption control method and device, electronic equipment and storage medium
Technical Field
The disclosure relates to the field of electronic technology, and in particular, to a power consumption control method and device, an electronic device and a storage medium.
Background
With the wide use of image acquisition modules, more algorithms are loaded on the image acquisition modules due to the addition of more functions, so that more power consumption is easy to consume. This also reduces the user experience, making the power consumption problem more and more pronounced. The power consumption problem is also a reference for users to select related products of the image acquisition module, but other functions such as anti-shake function are also required to be combined.
The image acquisition module has an anti-shake function, and the introduction of the anti-shake function can ensure the definition of the image acquired by the image acquisition module, but the execution of the anti-shake function can generate power consumption.
Therefore, the need to balance the image quality output by the image acquisition module with the power consumption of the image acquisition module is a problem that requires further investigation.
Disclosure of Invention
The embodiment of the disclosure discloses a power consumption control method and device, a test system, equipment and a storage medium.
A first aspect of an embodiment of the present disclosure provides a power consumption control method, the method including: determining the current jitter amplitude of an image acquisition module; determining a target power consumption level required by image acquisition of the image acquisition module according to the current jitter amplitude; when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, reducing the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in unit time.
Optionally, when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, reducing the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in unit time, including: when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, respectively determining the image frame number difference corresponding to the current power consumption level and the target power consumption level; and reducing the number of frames of the cached image in the unit time according to the image frame number difference, so that the current power consumption level of the image acquisition module is reduced to the target power consumption level.
Optionally, the method further comprises: and carrying out anti-shake processing on the image currently acquired by the image acquisition module according to the number of buffered image frames in unit time corresponding to the current power consumption level and an anti-shake algorithm.
Optionally, the determining the target power consumption level required by the image acquisition of the image acquisition module according to the current jitter amplitude includes one of the following: if the current jitter amplitude is in the first jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a first power consumption level; if the current jitter amplitude is in the second jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a second power consumption level; wherein the average jitter amplitude of the second jitter amplitude range is higher than the average jitter amplitude of the first jitter amplitude range; the power consumption corresponding to the first power consumption level is lower than the power consumption corresponding to the second power consumption level; if the current jitter amplitude is in a third jitter amplitude range, determining that a target power consumption level required by image acquisition of the image acquisition module is a third power consumption level; wherein the average jitter amplitude of the third jitter amplitude range is higher than the average jitter amplitude of the second jitter amplitude range; the second power consumption level is lower than the third power consumption level.
Optionally, if the current power consumption level decreases from a first level to the second power consumption level; the image acquisition module reduces the number of buffered image frames by a first frame number in unit time; if the current power consumption level is reduced from a second level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a second frame in unit time; if the current power consumption level is reduced from a first level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a third frame in unit time; the first frame number is greater than the third frame number; the first frame number is greater than or equal to the second frame number; the second frame number is greater than or equal to the third frame number.
Optionally, the first frame number is an integer multiple of the second frame number; the first frame number is an integer multiple of the third frame number.
A second aspect of the present disclosure provides a power consumption control apparatus, the apparatus comprising: the first determining module is used for determining the current jitter amplitude of the image acquisition module; the second determining module is used for determining a target power consumption level required by image acquisition of the image acquisition module according to the current jitter amplitude; and the power consumption reduction module is used for reducing the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in unit time when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module.
Optionally, the power consumption reduction module is further configured to: when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, respectively determining the image frame number difference corresponding to the current power consumption level and the target power consumption level; and reducing the number of frames of the cached image in the unit time according to the image frame number difference, so that the current power consumption level of the image acquisition module is reduced to the target power consumption level.
Optionally, the apparatus further comprises: and the anti-shake processing module is used for carrying out anti-shake processing on the image currently acquired by the image acquisition module according to the number of buffered image frames in unit time corresponding to the current power consumption level and an anti-shake algorithm.
Optionally, the power consumption reduction module is configured to be one of: if the current jitter amplitude is in the first jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a first power consumption level; if the current jitter amplitude is in the second jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a second power consumption level; wherein the average jitter amplitude of the second jitter amplitude range is higher than the average jitter amplitude of the first jitter amplitude range; the power consumption corresponding to the first power consumption level is lower than the power consumption corresponding to the second power consumption level; if the current jitter amplitude is in a third jitter amplitude range, determining that a target power consumption level required by image acquisition of the image acquisition module is a third power consumption level; wherein the average jitter amplitude of the third jitter amplitude range is higher than the average jitter amplitude of the second jitter amplitude range; the second power consumption level is lower than the third power consumption level.
Optionally, if the current power consumption level decreases from a first level to the second power consumption level; the image acquisition module reduces the number of buffered image frames by a first frame number in unit time; if the current power consumption level is reduced from a second level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a second frame in unit time; if the current power consumption level is reduced from a first level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a third frame in unit time; the first frame number is greater than the third frame number; the first frame number is greater than or equal to the second frame number; the second frame number is greater than or equal to the third frame number.
Optionally, the first frame number is an integer multiple of the second frame number; the first frame number is an integer multiple of the third frame number.
A third aspect of the disclosed embodiments provides an apparatus comprising: a memory for storing processor-executable instructions; a processor connected to the memory; wherein the processor is configured to perform the power consumption control method as provided in the first aspect of the above embodiment.
A fourth aspect of the disclosed embodiments provides a non-transitory computer-readable storage medium having stored therein computer-executable instructions that, when executed by a processor, implement the power consumption control method as provided in the second aspect of the embodiments described above.
The embodiment of the disclosure provides a power consumption control method, which comprises the following steps: determining a target power consumption level required by image acquisition of the image acquisition module according to the current jitter amplitude; when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, reducing the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in unit time; thus, the embodiment of the disclosure can realize the anti-shake function to ensure the image quality and simultaneously reduce the power consumption.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
FIG. 1 is a flow chart diagram of a power consumption control method shown in an exemplary embodiment of the present disclosure;
FIG. 2 is a flow chart diagram of a power consumption control method shown in an exemplary embodiment of the present disclosure;
FIG. 3 is a flow chart diagram of a power consumption control method shown in an exemplary embodiment of the present disclosure;
FIG. 4 is a flow chart diagram of a power consumption control method shown in an exemplary embodiment of the present disclosure;
FIG. 5 is a flow chart diagram of a power consumption control method shown in an exemplary embodiment of the present disclosure;
FIG. 6 is a flow chart diagram of a power consumption control method shown in an exemplary embodiment of the present disclosure;
fig. 7 is a schematic structural view of a power consumption control apparatus shown in an exemplary embodiment of the present disclosure;
fig. 8 is a schematic structural view of a power consumption control apparatus shown in an exemplary embodiment of the present disclosure;
fig. 9 is a schematic structural view of an electronic device shown in an exemplary embodiment of the present disclosure.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples do not represent all implementations consistent with the invention. Rather, they are merely examples of apparatus and methods consistent with aspects of the invention as detailed in the accompanying application.
In an embodiment of the present disclosure, as shown in fig. 1, there is provided a power consumption control method, including:
step S101, determining the current jitter amplitude of an image acquisition module;
step S102, determining a target power consumption level required by image acquisition of the image acquisition module according to the current jitter amplitude;
step S103, when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, reducing the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in unit time.
In some embodiments, the image capturing module may be in an independent device form, or may be an image capturing module in a fixed terminal or a mobile terminal, for example, an image capturing module in a mobile phone, a tablet computer, a notebook computer, or other devices, for example, an image capturing module in a robot, an unmanned aerial vehicle, or other devices.
Here, the image acquisition module at least comprises an image sensor and a gyroscope. The image sensor user acquires the image, and the gyroscope is used for detecting the current jitter amplitude of the image acquisition module.
Regarding the step S101, the current jitter amplitude of the image acquisition module may be determined by the jitter-related data acquired by the gyroscope. For example, the current jitter amplitude of the image acquisition module can be determined by the movement related data and the angle deflection related data acquired by the gyroscope.
In some embodiments, the dither amplitude may be divided into different dither amplitude ranges, the different dither amplitude ranges corresponding to different ones of the target power consumption levels. Then, with respect to the step S102, a target power consumption level required for image acquisition of the image acquisition module may be determined according to a jitter amplitude range to which the current jitter amplitude belongs.
Here, determining, according to the jitter amplitude range to which the current jitter amplitude belongs, the target power consumption level required for image acquisition of the image acquisition module may include:
and determining a target power consumption level required by the image acquisition module to execute anti-shake operation under the current shake amplitude according to the shake amplitude range to which the current shake amplitude belongs.
The anti-shake operation herein may include: and (3) converting pixel values of unclear images acquired by the image acquisition module according to an anti-shake algorithm to obtain image processing operation of clear images.
For example, the size of the dither amplitude range to which the dither amplitude belongs is proportional to the corresponding required target power consumption level. The smaller the jitter amplitude range, the smaller the target power consumption level required.
Therefore, the target power consumption level corresponds to the power consumption required to be consumed by the image acquisition module, and when the power consumption of the image acquisition module is within the target power consumption level, the requirements of anti-shake and proper power consumption reduction can be met when the image acquisition requirement of the image acquisition module is met.
In some embodiments, the current power consumption of the image acquisition module may be determined by obtaining data of a power supply module that supplies power to the image acquisition module.
For example, for an image acquisition module of a terminal, data of a terminal battery node may be acquired. For example, when the electronic device performs image acquisition, the power consumption data of the image acquisition module is recorded under a predetermined directory. When the electronic equipment executes the operation, the power consumption data can be read from a preset catalogue, so that the current power consumption of the image acquisition module is known.
For example, when the image acquisition module is just started, image acquisition is performed according to a default power consumption level or a power consumption level with the highest use frequency based on historical acquisition operation. At this time, the actual power consumption level of the image acquisition module can be corrected by reading the power consumption data.
For example, the image acquisition module reads the power consumption generated at the current moment by image acquisition according to the current acquisition frequency from the catalog "/sys/class/power_supply/battery/current_now" of the electronic device.
Here, regarding the current power consumption level range, the current power consumption level interval may be divided according to a power consumption average value within a history period and a scene type. And determining the current power consumption level according to the current power consumption level interval in which the current power consumption falls.
In some embodiments, the scene type includes:
a first class of scenes;
and the second type of scenes, wherein the expected duration corresponding to the second type of scenes is smaller than the expected duration corresponding to the first type of scenes.
The number of power consumption level intervals may be positively correlated with the expected duration of the corresponding scene.
For example, in the first scenario where long duration is required for long-term outgoing, the number of power consumption level intervals is larger, so that the reduction of power consumption can be controlled more accurately, for example, the duration of one day, two days, or three days can be used.
For another example, in the second type of scenario requiring a short duration for short-term outages, the number of power consumption level intervals may be smaller, so that the reduction of power consumption can be easily controlled. For example, the use of a duration of 1 hour, 2 hours, or the like may be used
In some embodiments, with respect to the step S103, when the current power consumption level is higher than the target power consumption level required by the image acquisition module, it is indicated that the image acquisition module has a margin that can reduce power consumption. Accordingly, when an anti-shake operation is performed, an anti-shake operation based on an anti-shake algorithm can be performed on the number of image frames acquired in the current unit time. If the number of the image frames acquired in unit time is smaller, the number of the image frames aimed by the anti-shake operation is reduced, so that the power consumption consumed by the anti-shake operation is reduced, and the current power consumption level of the image acquisition module is reduced to the target power consumption level.
Here, the reducing the number of frames of the image buffered by the image acquisition module in a unit time may reduce part of power consumption from the time of buffering the image. And since the number of image frames for performing the anti-shake operation is reduced, power consumption consumed by the anti-shake operation is reduced.
Therefore, the power consumption of the image acquisition module can be reduced while a clear image is obtained.
As shown in fig. 2, in an embodiment of the disclosure, the step S103 includes:
step S1031, when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, respectively determining the image frame number difference corresponding to the current power consumption level and the target power consumption level;
Step S1032, reducing the number of frames of the buffered images of the image acquisition module in unit time according to the image frame number difference, so that the current power consumption level of the image acquisition module is reduced to the target power consumption level.
In the embodiment of the disclosure, the image frame number difference is used for reducing the number of buffered image frames of the image acquisition module in unit time.
Here, there is a corresponding number of image frames with respect to the current power consumption level, and there is a corresponding number of image frames with respect to the target power consumption level. When the current power consumption level needs to be reduced to the target power consumption level, the image frame number difference is corresponding.
For example, the image acquisition module includes: the control chip or the electronic equipment comprising the image acquisition module is provided with a Central Processing Unit (CPU), and the corresponding image frame number difference between any two power consumption levels can be determined according to the corresponding relation between each power consumption level and the image frame number in unit time.
For example, when the current power consumption level is higher than the target power consumption level, the CPU of the image acquisition module may acquire, through the stored information of the image, an image frame number difference between the frame number corresponding to the current power consumption level and the frame number corresponding to the target power consumption level, so as to determine which image frame number difference may enable the current target power consumption level to be reduced to the target power consumption level.
In this way, in the subsequent application, the number of frames of the buffered image of the image acquisition module in the unit time can be reduced according to the difference of the number of frames of the image, and the image with the reduced number of frames in the unit time is subjected to the anti-shake operation, so that the power consumption consumed by the anti-shake operation can be reduced to the target power consumption level.
In the embodiment of the disclosure, the power consumption of the image acquisition module can be reduced more conveniently and rapidly through the image frame number difference.
As shown in connection with fig. 3, in an embodiment of the disclosure, the method further includes:
step S104, performing anti-shake processing on the image currently acquired by the image acquisition module according to the number of buffered image frames in unit time corresponding to the current power consumption level and an anti-shake algorithm.
In the embodiment of the present disclosure, the current power consumption level refers to a power consumption level currently consumed by the image acquisition module, and may be the current power consumption level subjected to the reduction processing in step S103.
Here, the anti-shake operation is performed on the image corresponding to the number of buffered frames in the unit time according to the number of buffered frames in the unit time corresponding to the current power consumption level, thereby improving the definition of the image.
For example, if the number of buffered image frames in a unit time corresponding to the current power consumption level is a, anti-shake processing is performed on the image frames of a Zhang Huancun in each unit time according to the image of a Zhang Huancun and the anti-shake algorithm.
Here, a is a positive integer. a can take the following values: 10. 12, 14, etc. go through appropriate values corresponding to the current power consumption level determination.
After the anti-shake processing is carried out on the multi-frame buffer image in unit time, at least one fused image with improved definition can be obtained. When the number of frames of the buffered image is larger, the more clear partial images can be obtained, and the more probability of obtaining a high-definition image is.
Therefore, it is necessary to determine the number of buffered images per unit time for the anti-shake operation according to the current power consumption level, and perform the anti-shake operation on the buffered images per unit time having a certain number of frames, thereby obtaining a clearer image.
As shown in connection with fig. 4, in the embodiment of the disclosure, the step S102 includes one of the following:
step S1021, if the current jitter amplitude is in a first jitter amplitude range, determining that a target power consumption level required by image acquisition of the image acquisition module is a first power consumption level;
step S1022, if the current jitter amplitude is in the second jitter amplitude range, determining that the target power consumption level required by the image acquisition of the image acquisition module is the second power consumption level; wherein the average jitter amplitude of the second jitter amplitude range is higher than the average jitter amplitude of the first jitter amplitude range; the power consumption corresponding to the first power consumption level is lower than the power consumption corresponding to the second power consumption level;
Step S1023, if the current jitter amplitude is in a third jitter amplitude range, determining that a target power consumption level required by image acquisition of the image acquisition module is a third power consumption level; wherein the average jitter amplitude of the third jitter amplitude range is higher than the average jitter amplitude of the second jitter amplitude range; the second power consumption level is lower than the third power consumption level.
In the embodiment of the disclosure, the smaller the jitter amplitude, the more the margin for adjusting the power consumption level when the anti-jitter processing is needed, the lower the target power consumption level can be. The larger the jitter amplitude is, the smaller the margin for adjusting the power consumption level is, and the smaller or the same amount of reduction of the target power consumption level is.
For example, with respect to the step S1021, if the adjustment margin of the current power consumption level corresponding to the first jitter amplitude range is greater and the required power consumption is smaller, the first power consumption level may be one or two steps lower than the current power consumption level.
For another example, with respect to the step S1022, if the adjustment margin of the current power consumption level corresponding to the second jitter amplitude range is smaller than the adjustment margin of the first jitter amplitude range, the required power consumption is greater than the first jitter amplitude range, and the first power consumption level may be one step lower than the current power consumption level.
Here, since the current power consumption corresponding to the second jitter amplitude range is higher than the current power consumption of the first jitter amplitude range, and the power consumption level to be adjusted by the second jitter amplitude range is smaller than the power consumption level to be adjusted by the second jitter amplitude range, it is indicated that the first power consumption level is lower than the second power consumption level.
In one embodiment, regarding the step S1023, since the third jitter amplitude range is larger, the more the current power consumption of the image acquisition module is, the less the power consumption margin is left for the system, and the target power consumption level should be kept to be the third power consumption level consistent with the current power consumption level. Thus, the third power consumption level is higher than the second power consumption level.
Here, the current power consumption is different for each jitter amplitude range, and the larger the jitter amplitude average value of the jitter range in which the jitter amplitude is located, the more power consumption is required for the anti-jitter processing, and the less target power consumption level can be reduced.
Thus, when the current jitter amplitude is in a lower jitter amplitude range, the more the target power consumption level difference can be reduced, the lower the corresponding target power consumption level.
Therefore, the power consumption level capable of being reduced and the target power consumption level can be determined according to the current jitter amplitude, so that the power consumption is reduced and the anti-jitter effect is achieved.
In the embodiment of the disclosure, if the current power consumption level is reduced from the first level to the second power consumption level; the image acquisition module reduces the number of buffered image frames by a first frame number in unit time;
if the current power consumption level is reduced from a second level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a second frame in unit time;
if the current power consumption level is reduced from a first level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a third frame in unit time;
the first frame number is greater than the third frame number;
the first frame number is greater than or equal to the second frame number;
the second frame number is greater than or equal to the third frame number.
In the embodiment of the disclosure, the current power consumption level may be divided into a first level and a second level; wherein the first level is higher than the second level. The second level is higher than the second power consumption level, and the first level is higher than the first power consumption level and the second power consumption level.
In some embodiments, when the dither amplitude of the image acquisition module is in the first amplitude range, one or two steps may be reduced from the current power consumption level to the target power consumption level.
For example, if the current power consumption level is the first level, the target power consumption level may be reduced from the first level power consumption to the target power consumption level of the second power consumption level.
For another example, if the current power consumption level is the first level, the target power consumption level may reduce the two-level power consumption to the target power consumption level of the first power consumption level.
In other embodiments, the current power consumption level may be reduced one level to the target power consumption level when the dither amplitude of the image acquisition module is in the second amplitude range.
For example, if the current power consumption level is the second level, the target power consumption level may be reduced by one level to the target power consumption level of the first power consumption level.
For another example, if the current power consumption level is the first level, the target power consumption level may be reduced by a target power consumption level from the first level to the second level.
In some embodiments, the number of frames that need to be reduced from the first level to the second level of power consumption is the first number of frames; the number of frames to be reduced from the second level to the first power consumption level is the second number of frames; the number of frames to be reduced from the first level to the first power consumption level is the third number of frames.
Here, the larger the difference between the power consumption corresponding to the current power consumption level and the target power consumption level that needs to be reduced, the more the number of image frames that it needs to reduce. There may be a case where the first frame number is greater than the second frame number and the second frame number is greater than the third frame number.
In other embodiments, when the difference between the power consumption corresponding to the current power consumption level and the target power consumption level to be reduced in the first jitter amplitude range is the same as the difference between the power consumption corresponding to the current power consumption level and the target power consumption level to be reduced in the second jitter amplitude range, the number of image frames to be reduced is equal. There may be a case where the first frame number may be equal to the second frame number, and the second frame number is equal to the third frame number.
In this way, the number of frames to be reduced can be dynamically determined according to the target power consumption level to be reduced.
In an embodiment of the disclosure, the first frame number is an integer multiple of the second frame number;
the first frame number is an integer multiple of the third frame number.
In some embodiments, the third frame number may be n, the second frame number may be mxn and the first frame number may be kχm×n. Here, k, m, and n are positive integers.
For example, the third frame number may be 2, the second frame number may be 4, and the first frame number may be 8.
In other embodiments, the third frame number may be n, the second frame number may be n, and the first frame number may be m×n or k×n.
Here, k may take a value of 2 or m may take a value of 2, and n may take appropriate values of 2, 3, 4, etc.
When the camera is started, monitoring the power consumption of the camera, comparing with a preset power consumption level interval, obtaining the current anti-shake amplitude of the camera, knowing the shake amplitude of the shake amplitude according to the shake amplitude, adjusting the power consumption level result according to the shake amplitude evaluation unit, knowing how strong a buffer frame scheme needs to be adopted at the moment according to the final power consumption level result, knowing the buffer frame adjustment strength according to the buffer frame adjustment strength, subtracting the buffer frame adjustment frame number on the basis of the current obtained buffer frame number, finally transmitting the obtained buffer frame data into an anti-shake algorithm, and performing anti-shake processing, thereby finally achieving the purpose of anti-shake. Thus, the anti-shake purpose can be achieved, and the purpose of reducing power consumption is also achieved.
In the embodiment of the disclosure, referring to fig. 5, the image acquisition module includes a monitoring power consumption unit, a preset dividing unit, a determining unit, and an adjusting unit.
In the embodiment of the disclosure, the power consumption unit is monitored to continuously acquire the data of the battery node, then the data is compared with the preset power consumption threshold gear, and then a corresponding strategy is made. The embodiments of the present disclosure are not limited to the above-described scheme of acquiring power consumption data. From the battery end node: power consumption data is obtained by/sys/class/power_supply/battery/current_now. The average power consumption value of a period of time can be counted, power consumption fluctuation intervals in different scenes can be set through previous project experience, and the like.
In the embodiment of the disclosure, the preset dividing unit divides the power consumption threshold into low, medium, high and above; and the anti-shake amplitude range is divided into small, medium and large. The buffer frame adjustment is divided into: weak, medium and strong.
As shown in connection with fig. 6, power consumption evaluation, jitter amplitude evaluation, and buffered frame evaluation may be performed in embodiments of the present disclosure.
Power consumption evaluation: comparing the power consumption value of the power consumption monitoring with three preset interval values of low, medium and high, and judging which interval the value falls in to evaluate the power consumption level; the average power consumption value of a period of time can be counted, power consumption fluctuation intervals in different scenes can be set through previous project experience, and the like.
Jitter amplitude assessment: the jitter amplitude of the current camera is obtained, and then the jitter amplitude is compared with a preset jitter amplitude range to see which jitter amplitude level range belongs to. The jitter amplitude range may be divided into 3 levels of small, medium, large, etc. As shown in table 1 below.
TABLE 1
Buffer frame assessment: before anti-shake processing is performed based on an anti-shake algorithm, in order to improve the anti-shake effect, the anti-shake effect is improved by adding a frame buffer mode. The anti-shake function is completed based on the data of the sensor in the buffered frame by the preset number of buffered frames and then by combining an anti-shake algorithm (for example, the anti-shake algorithm includes a lens anti-shake algorithm, a body anti-shake algorithm, etc.).
According to the number of the buffer frames, the anti-shake effect is improved.
In order to reduce the power consumption of the anti-shake algorithm, according to the obtained power consumption data, evaluating the power consumption level of what range the current power consumption value belongs to, then obtaining the anti-shake amplitude at the moment under the current camera, knowing the shake amplitude of the shake amplitude at the moment according to the shake amplitude, then adjusting the power consumption level result according to the shake amplitude evaluation unit, knowing how strong a buffer frame scheme needs to be adopted at the moment according to the final power consumption level result, knowing the buffer frame adjustment frame number needs to be subtracted on the basis of the current obtained buffer frame number according to the buffer frame adjustment strength,
and finally, transmitting the obtained buffer frame data into an anti-shake algorithm to perform anti-shake processing, and finally, achieving the purpose of anti-shake. Thus, the purposes of anti-shake and power consumption reduction are achieved, as shown in the following table.
TABLE 2
An adjusting unit: the buffer frame adjusting frame number is known according to the result obtained by the buffer frame evaluating unit in the determining unit, then the buffer frame adjusting frame number is subtracted on the basis of the obtained buffer frame number, and finally the obtained buffer frame data is transmitted into an anti-shake algorithm for anti-shake processing, and finally the purpose of realizing anti-shake is achieved. Thus, the anti-shake purpose can be achieved, and the purpose of reducing power consumption is also achieved.
Therefore, the power consumption increase caused by the anti-shake algorithm is reduced, the running load of the camera is reduced from the source, the computing capacity of the CPU is reduced, and the system load is indirectly reduced, so that the purpose of reducing the power consumption is achieved.
The embodiment of the disclosure not only can monitor the power consumption condition of the system, but also can predict the pre-designed power consumption range by combining the current power consumption, then accurately control the algorithm, and from a better service system, fundamentally eliminate the problems of excessive power consumption, temperature exceeding and the like caused by excessive load of the algorithm and more CPU computing power consumption, thereby solving the problems of excessive power consumption, temperature exceeding and the like
As shown in conjunction with fig. 7, an embodiment of the present disclosure provides a power consumption control apparatus 300, the apparatus 300 including:
a first determining module 301, configured to determine a current jitter amplitude of the image acquisition module;
a second determining module 302, configured to determine a target power consumption level required for image acquisition of the image acquisition module according to the current jitter amplitude;
and the power consumption reduction module 303 is configured to reduce, when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in a unit time.
The power consumption reduction module 303 is further configured to:
when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, respectively determining the image frame number difference corresponding to the current power consumption level and the target power consumption level;
and reducing the number of frames of the cached image in the unit time according to the image frame number difference, so that the current power consumption level of the image acquisition module is reduced to the target power consumption level.
As shown in connection with fig. 8, in an embodiment of the disclosure, the apparatus 300 further includes:
the anti-shake processing module 304 is configured to perform anti-shake processing on an image currently acquired by the image acquisition module according to the number of buffered image frames in a unit time corresponding to the current power consumption level and an anti-shake algorithm.
In the embodiment of the present disclosure, the power consumption reduction module 303 is configured to be one of the following:
if the current jitter amplitude is in the first jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a first power consumption level;
if the current jitter amplitude is in the second jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a second power consumption level; wherein the average jitter amplitude of the second jitter amplitude range is higher than the average jitter amplitude of the first jitter amplitude range; the power consumption corresponding to the first power consumption level is lower than the power consumption corresponding to the second power consumption level;
If the current jitter amplitude is in a third jitter amplitude range, determining that a target power consumption level required by image acquisition of the image acquisition module is a third power consumption level; wherein the average jitter amplitude of the third jitter amplitude range is higher than the average jitter amplitude of the second jitter amplitude range; the second power consumption level is lower than the third power consumption level.
In the embodiment of the disclosure, if the current power consumption level is reduced from the first level to the second power consumption level; the image acquisition module reduces the number of buffered image frames by a first frame number in unit time;
if the current power consumption level is reduced from a second level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a second frame in unit time;
if the current power consumption level is reduced from a first level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a third frame in unit time;
the first frame number is greater than the third frame number;
the first frame number is greater than or equal to the second frame number;
the second frame number is greater than or equal to the third frame number.
In an embodiment of the disclosure, the first frame number is an integer multiple of the second frame number;
The first frame number is an integer multiple of the third frame number.
In an embodiment of the present disclosure, as shown in connection with fig. 9, there is provided an electronic device 500 including:
a memory 504 for storing processor-executable instructions;
a processor 520 coupled to the memory 504;
wherein the processor 520 is configured to perform the power consumption control method provided by any of the foregoing technical solutions.
Is a block diagram of an apparatus 500, according to an exemplary embodiment. For example, the apparatus 500 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, or the like.
Referring to fig. 9, an apparatus 500 may include one or more of the following components: a processing component 502, a memory 504, a power component 506, a multimedia component 508, an audio component 510, an input/output (I/O) interface 512, a sensor component 514, and a communication component 516.
The processing component 502 generally controls overall operation of the apparatus 500, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing component 502 may include one or more processors 520 to execute instructions to perform all or part of the steps of the methods described above. Further, the processing component 502 can include one or more modules that facilitate interactions between the processing component 502 and other components. For example, the processing component 502 can include a multimedia module to facilitate interaction between the multimedia component 508 and the processing component 502.
Memory 504 is configured to store various types of data to support operations at device 500. Examples of such data include instructions for any application or method operating on the apparatus 500, contact data, phonebook data, messages, pictures, videos, and the like. The memory 504 may be implemented by any type or combination of volatile or nonvolatile memory devices 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 memory, flash memory, magnetic or optical disk.
The power component 506 provides power to the various components of the device 500. The power components 506 may include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power for the device 500.
The multimedia component 508 includes a screen between the device 500 and the user that provides an output interface. 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 touch screen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may sense not only the boundary of a touch or slide action, but also the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 508 includes a front-facing camera and/or a rear-facing camera. The front-facing camera and/or the rear-facing camera may receive external multimedia data when the device 500 is in an operational mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have focal length and optical zoom capabilities.
The audio component 510 is configured to output and/or input audio signals. For example, the audio component 510 includes a Microphone (MIC) configured to receive external audio signals when the device 500 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may be further stored in the memory 504 or transmitted via the communication component 516. In some embodiments, the audio component 510 further comprises a speaker for outputting audio signals.
The I/O interface 512 provides an interface between the processing component 502 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: homepage button, volume button, start button, and lock button.
The sensor assembly 514 includes one or more sensors for providing status assessment of various aspects of the apparatus 500. For example, the sensor assembly 514 may detect the on/off state of the device 500, the relative positioning of the components, such as the display and keypad of the apparatus 500, the sensor assembly 514 may also detect a change in position of the apparatus 500 or one component of the apparatus 500, the presence or absence of user contact with the apparatus 500, the orientation or acceleration/deceleration of the apparatus 500, and a change in temperature of the apparatus 500. The sensor assembly 514 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 514 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 514 may also include an acceleration sensor, a gyroscopic sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 516 is configured to facilitate communication between the apparatus 500 and other devices in a wired or wireless manner. The apparatus 500 may access a wireless network based on a communication standard, such as WiFi,2G or 3G, or a combination thereof. In one exemplary embodiment, the communication component 516 receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 516 further includes a Near Field Communication (NFC) module to facilitate short range communications. 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.
In an exemplary embodiment, the apparatus 500 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 elements for executing the methods described above.
In an exemplary embodiment, a non-transitory computer readable storage medium is also provided, such as memory 504, including instructions executable by processor 520 of apparatus 500 to perform the above-described method. For example, the non-transitory computer readable storage medium may be ROM, random Access Memory (RAM), CD-ROM, magnetic tape, floppy disk, optical data storage device, etc.
Embodiments of the present disclosure provide a non-transitory computer-readable storage medium, which when executed by a processor of a computer, enables the computer to perform the power consumption control method of one or more of the foregoing technical solutions.
The processor, when executing the instructions, is capable of performing at least the steps of:
determining the current jitter amplitude of an image acquisition module;
determining a target power consumption level required by image acquisition of the image acquisition module according to the current jitter amplitude;
when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, reducing the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in unit time.
It may be appreciated that, when the current power consumption level of the image capturing module is higher than the target power consumption level required by the image capturing module, reducing the current power consumption level of the image capturing module to the target power consumption level by reducing the number of frames of the image captured by the image capturing module in unit time includes:
When the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, respectively determining the image frame number difference corresponding to the current power consumption level and the target power consumption level;
and reducing the number of frames of the cached image in the unit time according to the image frame number difference, so that the current power consumption level of the image acquisition module is reduced to the target power consumption level.
It will be appreciated that the method further comprises:
and carrying out anti-shake processing on the image currently acquired by the image acquisition module according to the number of buffered image frames in unit time corresponding to the current power consumption level and an anti-shake algorithm.
It can be appreciated that the determining, according to the current jitter amplitude, a target power consumption level required for image acquisition of the image acquisition module includes one of the following:
if the current jitter amplitude is in the first jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a first power consumption level;
if the current jitter amplitude is in the second jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a second power consumption level; wherein the average jitter amplitude of the second jitter amplitude range is higher than the average jitter amplitude of the first jitter amplitude range; the power consumption corresponding to the first power consumption level is lower than the power consumption corresponding to the second power consumption level;
If the current jitter amplitude is in a third jitter amplitude range, determining that a target power consumption level required by image acquisition of the image acquisition module is a third power consumption level; wherein the average jitter amplitude of the third jitter amplitude range is higher than the average jitter amplitude of the second jitter amplitude range; the second power consumption level is lower than the third power consumption level.
It will be appreciated that if the current power consumption level decreases from a first level to the second power consumption level; the image acquisition module reduces the number of buffered image frames by a first frame number in unit time;
if the current power consumption level is reduced from a second level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a second frame in unit time;
if the current power consumption level is reduced from a first level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a third frame in unit time;
the first frame number is greater than the third frame number;
the first frame number is greater than or equal to the second frame number;
the second frame number is greater than or equal to the third frame number.
It is understood that the first frame number is an integer multiple of the second frame number;
The first frame number is an integer multiple of the third frame number.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This disclosure is intended to cover any adaptations, uses, or adaptations of the disclosure following the general principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following application.
It is to be understood that the present disclosure is not limited to the precise arrangements and instrumentalities shown in the drawings, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the present disclosure is limited only by the accompanying application documents.

Claims (10)

1. A power consumption control method, the method comprising:
determining the current jitter amplitude of an image acquisition module;
determining a target power consumption level required by image acquisition of the image acquisition module according to the current jitter amplitude;
when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, reducing the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in unit time.
2. The power consumption control method according to claim 1, wherein when the current power consumption level of the image capturing module is higher than the target power consumption level required by the image capturing module, reducing the current power consumption level of the image capturing module to the target power consumption level by reducing the number of frames of the image cached by the image capturing module in a unit time, comprises:
when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, respectively determining the image frame number difference corresponding to the current power consumption level and the target power consumption level;
and reducing the number of frames of the cached image in the unit time according to the image frame number difference, so that the current power consumption level of the image acquisition module is reduced to the target power consumption level.
3. The power consumption control method according to claim 1 or 2, characterized in that the method further comprises:
and carrying out anti-shake processing on the image currently acquired by the image acquisition module according to the number of buffered image frames in unit time corresponding to the current power consumption level and an anti-shake algorithm.
4. The method according to claim 1 or 2, wherein determining a target power consumption level required for image acquisition of the image acquisition module according to the current jitter amplitude comprises one of:
If the current jitter amplitude is in the first jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a first power consumption level;
if the current jitter amplitude is in the second jitter amplitude range, determining that the target power consumption level required by image acquisition of the image acquisition module is a second power consumption level; wherein the average jitter amplitude of the second jitter amplitude range is higher than the average jitter amplitude of the first jitter amplitude range; the power consumption corresponding to the first power consumption level is lower than the power consumption corresponding to the second power consumption level;
if the current jitter amplitude is in a third jitter amplitude range, determining that a target power consumption level required by image acquisition of the image acquisition module is a third power consumption level; wherein the average jitter amplitude of the third jitter amplitude range is higher than the average jitter amplitude of the second jitter amplitude range; the second power consumption level is lower than the third power consumption level.
5. The method for controlling power consumption according to claim 4, wherein,
if the current power consumption level is reduced from a first level to the second power consumption level; the image acquisition module reduces the number of buffered image frames by a first frame number in unit time;
If the current power consumption level is reduced from a second level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a second frame in unit time;
if the current power consumption level is reduced from a first level to the first power consumption level; the image acquisition module reduces the number of frames of the cached images by a third frame in unit time;
the first frame number is greater than the third frame number;
the first frame number is greater than or equal to the second frame number;
the second frame number is greater than or equal to the third frame number.
6. The method for controlling power consumption according to claim 5, wherein,
the first frame number is an integer multiple of the second frame number;
the first frame number is an integer multiple of the third frame number.
7. A power consumption control apparatus, characterized in that the apparatus comprises:
the first determining module is used for determining the current jitter amplitude of the image acquisition module;
the second determining module is used for determining a target power consumption level required by image acquisition of the image acquisition module according to the current jitter amplitude;
and the power consumption reduction module is used for reducing the current power consumption level of the image acquisition module to the target power consumption level by reducing the number of frames of the image cached by the image acquisition module in unit time when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module.
8. The power consumption control apparatus of claim 7, wherein the power consumption reduction module is further configured to:
when the current power consumption level of the image acquisition module is higher than the target power consumption level required by the image acquisition module, respectively determining the image frame number difference corresponding to the current power consumption level and the target power consumption level;
and reducing the number of frames of the cached image in the unit time according to the image frame number difference, so that the current power consumption level of the image acquisition module is reduced to the target power consumption level.
9. An apparatus, the apparatus comprising:
a memory for storing processor-executable instructions;
a processor connected to the memory;
wherein the processor is configured to perform the power consumption control method as provided in any one of claims 1 to 6.
10. A non-transitory computer-readable storage medium having stored therein computer-executable instructions that, when executed by a processor, implement the power consumption control method as provided in any one of claims 1 to 6.
CN202210712572.7A 2022-06-22 2022-06-22 Power consumption control method and device, electronic equipment and storage medium Pending CN117336609A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210712572.7A CN117336609A (en) 2022-06-22 2022-06-22 Power consumption control method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210712572.7A CN117336609A (en) 2022-06-22 2022-06-22 Power consumption control method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN117336609A true CN117336609A (en) 2024-01-02

Family

ID=89290694

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210712572.7A Pending CN117336609A (en) 2022-06-22 2022-06-22 Power consumption control method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN117336609A (en)

Similar Documents

Publication Publication Date Title
CN110796988B (en) Backlight adjusting method and device
CN107040591B (en) Method and device for controlling client
CN107480785B (en) Convolutional neural network training method and device
CN108200279B (en) Backlight adjusting method, device and equipment
US11062640B2 (en) Screen display method and screen display device
CN108922479B (en) Method and device for managing liquid crystal display module
CN111724803A (en) Audio processing method and device, electronic equipment and storage medium
CN108629814B (en) Camera adjusting method and device
CN112821508B (en) Charging method, device and storage medium
CN105472228B (en) Image processing method and device and terminal
CN111601377B (en) Temperature control method, device and storage medium
CN111953980A (en) Video processing method and device
CN109922203B (en) Terminal, screen off method and device
CN107026941B (en) Method and device for processing reply of unread message
CN106775541B (en) Electronic device and screen display method
CN117336609A (en) Power consumption control method and device, electronic equipment and storage medium
CN114442792A (en) Method and device for adjusting operating frequency of processor and storage medium
CN110704197B (en) Method, apparatus and medium for processing memory access overhead
CN111698414B (en) Image signal processing method and device, electronic device and readable storage medium
CN108108668B (en) Age prediction method and device based on image
CN112019680A (en) Screen brightness adjusting method and device
CN113138036B (en) Temperature detection method and device and electronic equipment
CN110876015B (en) Method and device for determining image resolution, electronic equipment and storage medium
CN116627239A (en) Power consumption control method, power consumption control device, terminal and storage medium
CN116567411A (en) Power consumption control method, device, equipment and medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination