Power consumption control method, device, terminal and storage medium
By designing multi-level temperature control levels and power consumption control strategies in terminal devices, the problem of excessive temperature caused by high power consumption of coprocessors is solved, and the balance between image processing quality and power consumption is achieved to ensure stable operation of the equipment.
Patent Information
- Application Number
- CN202110931467.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-08-13
- Publication Date
- 2025-08-15
- Estimated Expiration
- 2041-08-13
AI Technical Summary
The high power consumption of the coprocessor in the terminal device causes the overall temperature to be too high, which affects the continuous use of the shooting process and makes it difficult to take into account both image processing quality and operational power consumption.
By designing multi-level temperature control levels and setting corresponding power consumption control strategies for each temperature control level, determining the current temperature control level based on hardware temperature and implementing power consumption control, ensuring image preprocessing quality while avoiding excessive temperature.
On the premise of ensuring image processing quality, the power consumption of the coprocessor is effectively reduced, and the temperature is avoided, thus achieving long-term stable use of terminal equipment.
Smart Images

Figure CN115706851B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of image processing, and in particular to a power consumption control method, device, terminal, and storage medium. Background Art
[0002] As one of the most frequently used functions in terminals, the shooting function allows users to record events through photos or videos anytime and anywhere.
[0003] During the shooting process, the image sensor transmits the collected raw image data to the application processor (AP), which performs noise reduction, white balance, exposure and other processing on the raw image data, and then displays the processed image. In order to further improve the shooting quality, in the related technology, a coprocessor (Coprocessor Chip, CC) is set between the image sensor and the AP, so that the coprocessor is used to perform image preprocessing on the raw image data. However, since the coprocessor includes components such as Double Data Rate SDRAM (DDRSDRAM), Mobile Industry Processor Interface (MIPI) and Neural-network Processing Unit (NPU), the overall power consumption of the terminal is too high. Summary of the Invention
[0004] The present invention provides a method, device, terminal, and storage medium for controlling power consumption. The technical solution is as follows:
[0005] In one aspect, an embodiment of the present application provides a power consumption control method, the method comprising:
[0006] When the shooting function is turned on, determining a target temperature control level from at least two temperature control levels based on the hardware temperature;
[0007] Obtaining a target power consumption control strategy corresponding to the target temperature control level, wherein different temperature control levels correspond to different power consumption control strategies, and different power consumption control strategies have different degrees of impact on power consumption;
[0008] Based on the target power consumption control strategy, power consumption of a coprocessor is controlled. The coprocessor is used to preprocess the raw image data output by the image sensor and transmit the preprocessed image data to the application processor AP.
[0009] On the other hand, an embodiment of the present application provides a power consumption control device, the device comprising:
[0010] a level determination module, configured to determine a target temperature control level from at least two temperature control levels based on the hardware temperature when the shooting function is enabled;
[0011] a strategy determination module, configured to obtain a target power consumption control strategy corresponding to the target temperature control level, wherein different temperature control levels correspond to different power consumption control strategies, and different power consumption control strategies have different degrees of influence on power consumption;
[0012] The first power consumption control module is configured to control the power consumption of the coprocessor based on the target power consumption control strategy. The coprocessor is configured to preprocess the raw image data output by the image sensor and transmit the preprocessed image data to the application processor AP.
[0013] On the other hand, an embodiment of the present application provides a terminal, which includes: an image sensor, a coprocessor, a processor and a memory; the memory stores at least one instruction, and the at least one instruction is used to be executed by the processor to implement the power consumption control method described in the above aspect.
[0014] On the other hand, an embodiment of the present application provides a computer-readable storage medium, in which at least one program code is stored. The program code is loaded and executed by a processor to implement the power consumption control method described in the above aspect.
[0015] In another aspect, embodiments of the present application provide a computer program product or computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform the power consumption control method provided in various optional implementations of the above aspects.
[0016] The technical solutions provided in the embodiments of the present application can bring the following beneficial effects:
[0017] In an embodiment of the present application, when the terminal is provided with a coprocessor for preprocessing the raw image data output by the image sensor, by designing multiple temperature control levels and setting corresponding power consumption control strategies for different temperature control levels, the current temperature control level is determined based on the hardware temperature during the shooting process, and then the power consumption of the coprocessor is controlled based on the power consumption control strategy corresponding to the current temperature control level. While ensuring the quality of image preprocessing, the problem of excessive temperature due to excessive power consumption is avoided, thereby achieving the effect of taking into account both image processing quality and operating power consumption. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0019] Figure 1 shows a structural block diagram of a terminal provided by an exemplary embodiment of the present application;
[0020] Figure 2 It is a schematic diagram of the data transmission process between the image sensor, coprocessor and processor;
[0021] Figure 3 A flowchart of a power consumption control method provided by an exemplary embodiment of the present application is shown;
[0022] Figure 4 is a schematic diagram illustrating an implementation of a power consumption control process according to an exemplary embodiment of the present application;
[0023] Figure 5 A flowchart of a power consumption control method provided by another exemplary embodiment of the present application is shown;
[0024] Figure 6 is a software architecture diagram of the coprocessor and the software on the application processor shown in an exemplary embodiment of the present application;
[0025] Figure 7 is a flow chart of a coprocessor initialization parameter setting process shown in an exemplary embodiment of the present application;
[0026] Figure 8 A flowchart of a power consumption control method provided by another exemplary embodiment of the present application is shown;
[0027] Figure 9 is a flow chart of a dynamic switching process shown in an exemplary embodiment of the present application;
[0028] Figure 10 is a flowchart of a static switching process shown in an exemplary embodiment of the present application;
[0029] Figure 11 A structural block diagram of a power consumption control device provided by an embodiment of the present application is shown. DETAILED DESCRIPTION
[0030] In order to make the objectives, technical solutions and advantages of this application clearer, the implementation methods of this application will be further described in detail below with reference to the accompanying drawings.
[0031] Please refer to Figure 1, which shows a block diagram of a terminal structure provided by an exemplary embodiment of the present application. The terminal in the present application may include one or more of the following components: a processor 110 , a memory 120 , an image sensor 130 , and a coprocessor 140 .
[0032] The processor 110 may include one or more processing cores (also known as APs). The processor 110 utilizes various interfaces and circuits to connect various components within the terminal. It executes instructions, programs, code sets, or instruction sets stored in the memory 120, as well as accesses data stored in the memory 120, to perform various terminal functions and process data. Optionally, the processor 110 may be implemented in at least one hardware form: a digital signal processing (DSP), a field-programmable gate array (FPGA), or a programmable logic array (PLA). The processor 110 may integrate one or a combination of a CPU, a graphics processing unit (GPU), a modem, and an image signal processor (ISP). The CPU primarily processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing the content displayed on the touchscreen display; the modem handles wireless communications; and the ISP performs image processing (such as pixel correction, temporal noise reduction, 3D noise reduction, white balance, automatic exposure, etc.). It is understandable that the above-mentioned modem may not be integrated into the processor 110, but may be implemented separately through a communication chip.
[0033] The memory 120 may include a random access memory (RAM) or a read-only memory (ROM). Optionally, the memory 120 includes a non-transitory computer-readable storage medium. The memory 120 may be used to store instructions, programs, codes, code sets, or instruction sets. The memory 120 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc. The operating system may be an Android system (including a system deeply developed based on the Android system), an iOS system developed by Apple (including a system deeply developed based on the iOS system), or other systems. The data storage area may also store data created by the terminal during use (such as a phone book, audio and video data, chat record data), etc. In an embodiment of the present application, at least one instruction is stored in the memory 120, and the at least one instruction is used to be executed by the processor 110 to execute the power consumption control method in the following embodiment.
[0034] Image sensor 130 (camera sensor) is a sensor composed of photosensitive elements and is used to output raw (RAW) image data. Typically, image sensor 130 is integrated with the camera. When the camera is turned on, image sensor 130 outputs the raw image data of the image captured by the camera, which is then processed by subsequent processing components.
[0035] Coprocessor Chip (CC) 140 is a processor independent of processor 110 and is used to assist processor 110 in data processing. In the embodiment of the present application, coprocessor 140 is connected to processor 110 and image sensor 130 respectively, and is used to preprocess the raw image data output by image sensor 130 and transmit the preprocessed image data to processor 110 for further processing by processor 110.
[0036] Indicative, such as Figure 2As shown, the coprocessor 140 is provided with an ISP 141, an NPU 142, a DDR cache 143, and an IDI 144 (Image Data Interface). After the coprocessor 140 receives raw image data from the image sensor 130 via the MIPI RX (MIPI receiver), the ISP 141 calls the IDI 144 to obtain the raw image data, processes the raw image data, and writes it to the DDR cache 143. After reading the image data from the DDR cache 143, the NPU 142 performs AI processing on the image data, and then calls the IDI 144 to transmit the processed image data to the processor 110 via the MIPI TX (MIPI transmitter).
[0037] Optionally, the terminal may further include a display screen for displaying images. This may be a touch screen display screen that is used to receive touch operations on or near the touch screen screen using any suitable object such as a finger or a stylus, and to display the user interface of each application. The touch screen display screen is usually provided on the front panel of the terminal. The touch screen display screen can be designed as a full screen, a curved screen, or a special-shaped screen. The touch screen display screen can also be designed as a combination of a full screen and a curved screen, or a combination of a special-shaped screen and a curved screen, which is not limited in the embodiments of the present application.
[0038] In addition, those skilled in the art will understand that the terminal structures shown in the above figures do not constitute limitations on the terminal. The terminal may include more or fewer components than shown, or may combine certain components or arrange the components differently. For example, the terminal also includes RF circuits, camera components, sensors, audio circuits, power supplies, and other components, which will not be described in detail here.
[0039] Setting up a coprocessor independent of the AP and using it to pre-process the raw images output by the image sensor can help improve image quality. However, since the coprocessor includes components such as the DSP, DDR cache, MIPI, and NPU, and some components (such as the NPU) consume high power during operation, this will increase the overall operating power consumption of the device. At the same time, increased operating power consumption may cause the terminal to overheat, making it impossible to use the coprocessor for long periods of time during shooting.
[0040] To balance image processing quality and operating power consumption, in the embodiments of the present application, the terminal is configured with multiple temperature control levels, and different power consumption control strategies are configured for each temperature control level. During the shooting process, the terminal determines the current temperature control level based on the hardware temperature and controls the power consumption of the coprocessor based on the power consumption control strategy corresponding to the current temperature control level. This ensures the quality of image preprocessing while avoiding the problem of excessive temperature caused by excessive power consumption. The power consumption control process is described below using an exemplary embodiment.
[0041] Please refer to Figure 3 , which shows a flow chart of a power consumption control method provided by an exemplary embodiment of the present application, the method comprising:
[0042] Step 301 : When the shooting function is turned on, a target temperature control level is determined from at least two temperature control levels based on the hardware temperature.
[0043] Because the coprocessor is used to pre-process the raw image data during the capture process, in this embodiment, the terminal performs power consumption control when the capture function is enabled; if the capture function is disabled, no power consumption control is required. Optionally, the terminal performs power consumption control when the capture function is enabled, or the terminal performs power consumption control while the capture function is running.
[0044] Since the hardware temperature of the terminal can reflect the power consumption, and measuring temperature is less difficult than measuring power consumption, in this embodiment, the terminal determines the target temperature control level based on the hardware temperature, and then determines how to control power consumption based on the target temperature control level, rather than directly controlling power consumption based on the terminal power consumption.
[0045] Optionally, the hardware temperature is an average temperature of the hardware in a working state.
[0046] In some embodiments, the terminal is pre-configured with at least two temperature control levels, where different temperature control levels correspond to different hardware temperature ranges. During the capture process, the terminal determines a target temperature control level from the at least two temperature control levels based on the hardware temperature range to which the hardware temperature belongs. Optionally, the temperature control level is positively correlated with the hardware temperature, i.e., the higher the hardware temperature, the higher the corresponding temperature control level.
[0047] In an exemplary embodiment, the terminal determines the second temperature control level among the four temperature control levels as the target temperature control level. The embodiment of the present application does not limit the number of temperature control levels.
[0048] Step 302 : Obtain a target power consumption control strategy corresponding to a target temperature control level, wherein different temperature control levels correspond to different power consumption control strategies, and different power consumption control strategies have different impacts on power consumption.
[0049] In one possible implementation, corresponding power consumption control strategies are pre-set for different temperature control levels, wherein different power consumption control strategies have different degrees of impact on power consumption, and the higher the temperature control level, the greater the degree of reduction in terminal power consumption after adopting the power consumption control strategy corresponding to the temperature control level.
[0050] Optionally, the power consumption control policy is used to instruct power consumption control of shooting-related hardware, where the shooting-related hardware includes at least one of an image sensor, a coprocessor, and an AP. For example, the power consumption control policy is used to instruct power consumption control only for the coprocessor, or the power consumption control policy is used to instruct power consumption control for both the coprocessor and the AP.
[0051] In one possible implementation, the target power consumption control strategy includes power consumption control parameters, which may include hardware switch indication parameters (indicating whether the hardware in the coprocessor is enabled), algorithm switch indication parameters (indicating whether to run the corresponding algorithm), resolution parameters, frame rate parameters, model parameters (the model used in the image processing process), CPU / GPU computing resource parameters, etc., which are not limited to the embodiments of the present application.
[0052] In an illustrative example, the terminal is set with four temperature control levels, and the corresponding relationship between different temperature control levels and power consumption control strategies is shown in Table 1.
[0053] Table 1
[0054]
[0055] Step 303 : Based on the target power consumption control strategy, the power consumption of the coprocessor is controlled. The coprocessor is used to pre-process the raw image data output by the image sensor and transmit the pre-processed image data to the AP.
[0056] In one possible implementation, the terminal controls the power consumption of the coprocessor based on the power consumption control parameters related to the coprocessor in the target power consumption control strategy to reduce the power consumption of the coprocessor (reduce preprocessing quality) or improve the power consumption of the coprocessor (improve preprocessing quality).
[0057] In one possible scenario, during the shooting process, when the hardware temperature is high, based on the determined target power consumption control strategy, the coprocessor only runs part of the algorithm when preprocessing the image, thereby reducing the power consumption of the coprocessor and thus reducing the hardware temperature; when the hardware temperature is low, based on the determined target power consumption control strategy, the coprocessor uses a neural network model with more model parameters when preprocessing the image, which helps to improve the quality of image preprocessing.
[0058] Optionally, in addition to controlling the coprocessor's power consumption, the terminal can also control the AP's ISP chip's power consumption based on the target power consumption control policy. In some embodiments, the power consumption control policy can include control of AP-side ISP function switches and image post-processing. These controls can cover the entire camera process, improving image processing quality and power consumption control.
[0059] To sum up, in an embodiment of the present application, when the terminal is provided with a coprocessor for preprocessing the raw image data output by the image sensor, by designing multiple temperature control levels and setting corresponding power consumption control strategies for different temperature control levels, the current temperature control level is determined based on the hardware temperature during the shooting process, and then the power consumption of the coprocessor is controlled based on the power consumption control strategy corresponding to the current temperature control level. While ensuring the quality of image preprocessing, the problem of excessive temperature due to excessive power consumption is avoided, thereby achieving the effect of taking into account both image processing quality and operating power consumption.
[0060] Regarding the method for determining the correspondence between temperature control levels and power consumption control strategies, in one possible implementation, developers use a k-means clustering algorithm to cluster image processing power consumption and image processing quality under different power consumption control strategies, and then generate a correspondence between temperature control levels and power consumption control strategies based on the clustering results. Optionally, this process may include the following steps:
[0061] 1. Determine the power consumption control sub-strategy as the input set D = {x1, x2, ..., xm} of the k-means. For example, turn off the NPU, turn off the ISP, select an image processing algorithm, reduce the resolution, reduce the frame rate, select a neural network model, reduce CPU / GPU computing resources, etc.
[0062] 2. Determine the quantitative evaluation indicators of various power consumption control strategies in the two dimensions of image processing power consumption and image processing quality.
[0063] 3. Using image processing power consumption and image processing quality as the horizontal and vertical axes of the plane coordinate system, the k-means clustering algorithm is used to cluster the power consumption control strategies until convergence, and several clusters are obtained.
[0064] 4. Based on the power consumption control strategy in the cluster, generate the corresponding relationship between the temperature control level and the power consumption control strategy.
[0065] Of course, in other possible implementations, the terminal can analyze user usage characteristics to generate a power consumption control strategy that conforms to the user usage characteristics (for example, it can be generated through AI) to meet the user's personalized needs. In particular, when the collected user usage characteristics are relatively few, the k-means clustering method can be used. When the collected user usage characteristics meet the needs, the AI method can be switched.
[0066] In one possible implementation, when a terminal is equipped with a unified temperature control mechanism (for making unified temperature control decisions based on the terminal temperature), after adding a coprocessor, it is necessary to add a negative temperature coefficient (NTC) thermocouple to the coprocessor. The NTC thermocouple is then used to measure the coprocessor's processor temperature. The terminal temperature (case temperature) is then simulated based on the processor temperature and the temperatures of other hardware, allowing unified temperature control decisions to be made based on the terminal temperature. Accordingly, after obtaining the unified temperature control decision result, the terminal uses the coprocessor as one of the control items for the unified temperature control and controls its power consumption.
[0067] In addition, in addition to controlling power consumption based on the unified temperature control decision result, the terminal also needs to determine whether the coprocessor has abnormal junction temperature based on the coprocessor's own processor temperature, and then control power consumption based on the coprocessor junction temperature decision result.
[0068] Indicative, such as Figure 4 As shown, during the power consumption control process, the terminal takes the unified temperature control and / or coprocessor junction temperature as input, obtains the temperature control level through level mapping, and then determines the power consumption control strategy from the power consumption control strategy library based on the temperature control level. The power consumption control strategy is processed for special cases based on the current shooting scene (the power consumption control strategy may conflict with the current shooting scene, and some unexecutable operations in the power consumption control strategy need to be excluded). Finally, the coprocessor is controlled based on the processed power consumption control strategy to perform power consumption control (such as frame rate control, scene selection, coprocessor parameter setting, etc.).
[0069] In some embodiments, because the coprocessor does not perform image preprocessing before the capture function is enabled (i.e., it is in an inactive state), when the capture function is enabled, the terminal only needs to make a unified temperature control decision based on the terminal temperature, and does not need to control power consumption based on the coprocessor's junction temperature decision. However, during the capture function, because the coprocessor is in an active state, the terminal needs to control power consumption based on both unified temperature control and the coprocessor's junction temperature decision. The following uses exemplary embodiments to illustrate the above two scenarios.
[0070] Please refer to Figure 5 , which shows a flow chart of a power consumption control method provided by another exemplary embodiment of the present application, the method comprising:
[0071] Step 501: In response to a shooting function start instruction, determine the terminal temperature based on the hardware temperature.
[0072] In one possible implementation, upon receiving a command to enable the camera function, the terminal simulates the terminal temperature (case temperature) based on the hardware temperature of each hardware component, so that a unified temperature control decision can be subsequently made based on the terminal temperature. This embodiment of the present application does not limit the specific algorithm for simulating the terminal temperature based on the hardware temperature.
[0073] Optionally, since the coprocessor is in a non-working state when the shooting function is not enabled, when determining the terminal temperature, the terminal may determine the terminal temperature based on the hardware temperature of hardware other than the coprocessor.
[0074] Step 502: Determine a target temperature control level from at least two temperature control levels based on the terminal temperature.
[0075] In one possible implementation, a unified temperature control decision is used to determine the power consumption level of the terminal based on the terminal temperature. However, the power consumption level does not correspond one-to-one to the temperature control level (thermal policy level) in the embodiment of the present application. Therefore, a mechanism is required to map the power consumption level of the terminal to the temperature control level.
[0076] Optionally, this step may include the following steps:
[0077] 1. Determine the current power consumption level based on the terminal temperature.
[0078] Optionally, the terminal is provided with a unified temperature control decision module, which is used to determine the power consumption level based on the terminal temperature. In some embodiments, the unified temperature control decision module is provided with a correspondence between the power consumption level and the terminal temperature range. After obtaining the terminal temperature, the terminal determines the current power consumption level based on the terminal temperature range to which the terminal temperature belongs. The embodiments of the present application do not limit the specific method for determining the power consumption level based on the terminal temperature.
[0079] 2. Based on the mapping relationship between power consumption level and temperature control level, determine the target temperature control level corresponding to the current power consumption level.
[0080] In one possible implementation, the terminal is configured with a mapping relationship between power consumption levels and temperature control levels. After determining the current power consumption level, the terminal determines the target temperature control level corresponding to the current power consumption level from the mapping relationship. This mapping relationship can be pre-configured in the terminal by the developer and can be updated.
[0081] In an illustrative example, the mapping relationship between power consumption levels and temperature control levels is shown in Table 2.
[0082] Table 2
[0083] Power consumption level Temperature control level Level 1, level 2 Level 1 Level 2, Level 4, Level 5 Level 2 Level 6 Level 3
[0084] For example, when the unified temperature control decision module determines that the current power consumption level is level 2, the terminal determines that the target temperature control level is level 1 based on the mapping relationship shown in Table 2.
[0085] In addition to determining the terminal temperature in real time when the shooting function is turned on, and then determining the target temperature control level based on the terminal temperature, in other possible implementations, when the shooting function is not turned on, the unified temperature control decision module periodically determines the power consumption level. When the shooting function is turned on instruction is received, the terminal determines the temperature control level based on the most recently determined power consumption level. This embodiment does not limit this.
[0086] Step 503: Obtain a target power consumption control strategy corresponding to the target temperature control level.
[0087] The implementation of this step can refer to the above step 302, and this implementation will not be repeated here.
[0088] Step 504 : setting initial operating parameters of the coprocessor based on the target power consumption control strategy, wherein the power consumption of the coprocessor is different under different operating parameters.
[0089] After the capture function is activated, the coprocessor needs to begin image preprocessing. Therefore, the terminal sets the initial operating parameters for the coprocessor based on the target power consumption control strategy. Different operating parameters result in different coprocessor power consumption and, accordingly, different coprocessor image preprocessing effects.
[0090] Of course, in addition to initializing the coprocessor, the terminal may also initialize the image sensor and other shooting-related hardware, which is not limited in this embodiment.
[0091] Combined with the data shown in Table 1, when the target temperature control level is Level 0, the terminal sets the coprocessor to enable the AINR (AI noise reduction) function of the NPU and the 3DNR (3D noise reduction) function of the ISP; when the target temperature control level is Level 3, the terminal sets the coprocessor to disable the AINR (AI noise reduction) function of the NPU and the 3DNR (3D noise reduction) function of the ISP.
[0092] like Figure 6 , which shows the software architecture diagram of the coprocessor and the application processor (AP). The Explorer on the left is the software running on the coprocessor, while the software on the right is the software running on the application processor.
[0093] Explorer can be divided into the Services layer, the Kernel layer, and the HAL (Hardware Abstraction Layer) layer. The Services layer includes the ISP Service, Thermal Manager service, and PowerManager service; the Kernel layer includes the RT Thread, Component, and Driver, which includes the T-sensor driver and the ISP driver; the HAL layer is used to abstract the T-sensor and ISP.
[0094] On the application processor side, from top to bottom, there are AP&FWK (application layer and framework layer), PowerManager (power management), Camera2 (camera), ThermalManagerService (thermal management service), CameraService (camera service), Thermal HAL, Camera HAL, Thermal Sensor, and Camera Driver. The unified temperature control module includes Events Receiver and Strategy&Action.
[0095] In MMS, the MMS (JAVA) SDK is equipped with an MMS (JAVA) Manager that interacts with Strategy & Action. MMS (JAVA) is equipped with an MMS (JAVA) Core that interacts with the MMS (JAVA) Manager, as well as ClientManager (client management), Power Controller (power consumption control), and Wakeup Controller (wakeup control). The MMS (C++) SDK is equipped with an MMS (C++) Manager that interacts with the MMS (JAVA) Core. MMS (C++) is equipped with an MMS (C++) Core that interacts with the MMS (C++) Manager, as well as Explorer HAL. Explorer HAL is equipped with PowerManager / Thermal Policy (power consumption management / temperature control policy) and Scene Manager (scene management), and interacts with Explorer through Explorer Driver.
[0096] exist Figure 6 In the software architecture shown in FIG. 1 , in an exemplary embodiment, as shown in FIG. 1 , Figure 7 As shown, the process of initializing the coprocessor operating parameters may include the following steps.
[0097] Step 701: The unified temperature control sends the power level to the Explorer HAL.
[0098] Accordingly, the Explorer HAL stores the received power consumption level.
[0099] In step 702 , the Camera HAL performs a configuration stream (configStreams) operation.
[0100] When receiving the shooting function start command, the Camera HAL performs the configuration flow operation.
[0101] Step 703: MMS passes the configuration flow operation to Explorer HAL.
[0102] In step 704 , the Explorer HAL obtains the most recently stored power consumption level (get last power levelstored).
[0103] In step 705 , the Explorer HAL performs status collection.
[0104] In step 706 , the Explorer HAL determines the temperature control level corresponding to the power consumption level in the strategy stage.
[0105] In step 707 , the Explorer HAL makes a decision to enter temperature control level 1 .
[0106] In step 708 , the Explorer HAL starts the coprocessor based on the operating parameters corresponding to the temperature control level 1 (start explore with level 1 config).
[0107] Please refer to Figure 8 , which shows a flow chart of a power consumption control method provided by another exemplary embodiment of the present application, the method comprising:
[0108] Step 801: During the operation of the shooting function, the terminal temperature is determined based on the hardware temperature.
[0109] Since the coprocessor performs image preprocessing during the shooting function, the terminal needs to obtain the hardware temperature of the coprocessor and other hardware to simulate the terminal temperature.
[0110] Step 802 : Determine a target temperature control level from at least two temperature control levels based on the terminal temperature and the processor temperature of the coprocessor.
[0111] In one possible implementation, temperature control level adjustment can be triggered in two situations: 1. A change in the power consumption level issued by the unified temperature control; 2. An abnormal junction temperature of the coprocessor. Therefore, when determining the target temperature control level, the terminal needs to determine the corresponding temperature control level based on the terminal temperature and the coprocessor temperature, and then determine the target temperature control level from these two factors. Optionally, this step may include the following sub-steps.
[0112] Step 802A: Determine the current power consumption level based on the terminal temperature.
[0113] Step 802B: Determine a first temperature control level corresponding to the current power consumption level based on a mapping relationship between power consumption levels and temperature control levels.
[0114] The implementation of steps 802A to 802B may refer to step 502 , and will not be described in detail in this embodiment.
[0115] Step 802C: determining a second temperature control level from at least two temperature control levels based on the processor temperature.
[0116] In addition to determining a first temperature control level for the terminal as a whole, the terminal also needs to determine a second temperature control level for the coprocessor based on the processor temperature. In one possible implementation, the terminal is configured with a correspondence between processor temperature ranges and temperature control levels, and the terminal determines the temperature control level corresponding to the processor temperature range to which the processor temperature belongs as the second temperature control level.
[0117] In some embodiments, to prevent the processor from overheating, when determining the second temperature control level based on the processor temperature, the terminal first detects whether the processor temperature is below a temperature threshold, which serves as the hardware protection threshold for the coprocessor. If the processor temperature is below the temperature threshold, the processor temperature is determined to be normal, and the second temperature control level is determined based on the processor temperature. If the processor temperature is above the temperature threshold, continued operation may damage the coprocessor, so the terminal shuts down the coprocessor.
[0118] Step 802D: Determine a target temperature control level from the first temperature control level and the second temperature control level.
[0119] Optionally, when the first temperature control level is inconsistent with the second temperature control level, the terminal determines the higher temperature control level of the two as the target temperature control level, where the temperature control level is positively correlated with the degree of impact on power consumption, that is, the higher the temperature control level, the more obvious the power consumption decreases after adopting the power consumption control strategy corresponding to the temperature control level, and accordingly, the more obvious the temperature drop of the terminal.
[0120] In a possible implementation, in response to the first temperature control level being higher than the second temperature control level, the first temperature control level is determined as the target temperature control level; in response to the first temperature control level being lower than the second temperature control level, the second temperature control level is determined as the target temperature control level.
[0121] Schematically, when the first temperature control level determined based on the terminal temperature is level 1, and the second temperature control level determined based on the processor temperature is level 2 (the power consumption of the coprocessor is too high, while the power consumption of other hardware is normal), the terminal determines the target temperature control level as level 2, that is, the power consumption of the coprocessor needs to be controlled through the power consumption control strategy corresponding to level 2.
[0122] Step 803: Obtain a target power consumption control strategy corresponding to the target temperature control level.
[0123] The implementation of this step can refer to the above step 302, and this implementation will not be repeated here.
[0124] Step 804: Determine the current power consumption control strategy.
[0125] During the operation of the shooting function, when the current power consumption control strategy is adjusted to the target function control strategy, since not all control items support dynamic adjustment, for example, when the resolution of the image sensor needs to be adjusted, the stream needs to be reconfigured. Therefore, in a possible implementation method, the terminal needs to detect whether dynamic switching is supported between the current power consumption control strategy and the target power consumption control strategy. If supported, execute step 805; if not, execute step 806.
[0126] Step 805 : In response to the current power consumption control strategy and the target power consumption control strategy supporting dynamic switching, adjusting the operating parameters of the coprocessor.
[0127] In some embodiments, in order to avoid reconfiguring the flow, when some control items that require flow configuration need to be adjusted based on the target power consumption control strategy, the coprocessor can adjust the process or parameters through its own unique capabilities to achieve a similar adjustment effect.
[0128] In one possible implementation, when the target power consumption control strategy indicates that the output parameters of the image sensor need to be adjusted (such as reducing the resolution and frame rate), if the image sensor is adjusted directly, the image sensor stream must be reconfigured. To avoid reconfiguring the stream, the coprocessor can process the raw image data output by the image sensor through its own resize and buffer control functions to achieve the effect of reducing the image resolution and frame rate. Optionally, this step can include the following sub-steps.
[0129] Step 805A: In response to the image resolution indicated by the current power control policy being a first resolution and the image resolution indicated by the target power control policy being a second resolution, the coprocessor is controlled to enable a resolution adjustment mode, wherein the first resolution is higher than the second resolution. In the resolution adjustment mode, the coprocessor is configured to reduce the resolution of the raw image data output by the image sensor.
[0130] When it is determined based on the current power control strategy and the target power control strategy that the image resolution needs to be lowered (perhaps because the current resolution is too high, resulting in too much processing required of the coprocessor, so the resolution needs to be lowered to reduce the processing capacity of the coprocessor), in order to avoid directly configuring the flow of the image processor, the coprocessor in the embodiment of the present application supports a resolution adjustment mode.
[0131] In resolution adjustment mode, the coprocessor resizes the raw image data output by the image sensor, thereby reducing the resolution without adjusting the resolution of the image sensor, thereby reducing the amount of data processed in the subsequent preprocessing process and achieving the effect of reducing the power consumption of the coprocessor.
[0132] In one possible implementation, when the image resolution needs to be lowered, the terminal controls the coprocessor to turn on the resolution adjustment mode; when the image resolution needs to be restored subsequently, the terminal only needs to control the coprocessor to turn off the resolution adjustment mode, which will not affect the user's normal use.
[0133] Step 805B, in response to the frame rate indicated by the current power control strategy being a first frame rate and the frame rate indicated by the target power control strategy being a second frame rate, the coprocessor is controlled to turn on a frame rate adjustment mode, and the first frame rate is higher than the second frame rate; wherein, in the frame rate adjustment mode, the coprocessor is used to preprocess part of the original image data output by the image sensor.
[0134] When it is determined based on the current power control strategy and the target power control strategy that the frame rate needs to be lowered (perhaps because the frame rate is too high, resulting in too much processing required of the coprocessor, so the frame rate needs to be lowered to reduce the processing capacity of the coprocessor), in order to avoid directly configuring the flow of the image processor, the coprocessor in the embodiment of the present application supports a frame rate adjustment mode.
[0135] In the frame rate adjustment mode, the coprocessor bypasses the raw image data (frames) output by the image sensor. For example, only the odd-numbered raw image data (frames) are forwarded, and the even-numbered raw image data (frames) are transmitted back to the image sensor for continued use. That is, the frame rate is reduced to half of the original value, thereby achieving the effect of lowering the frame rate without adjusting the frame rate of the image sensor, thereby reducing the data processing volume in the subsequent preprocessing process, and achieving the effect of reducing the power consumption of the coprocessor.
[0136] Of course, the coprocessor may also achieve effects such as 1 / 3 frame rate reduction or 2 / 3 frame rate reduction by controlling the frame number of the subsequently transmitted original image data (frame), which is not limited in this embodiment.
[0137] In one possible implementation, when the frame rate needs to be lowered, the terminal controls the coprocessor to turn on the frame rate adjustment mode; when the frame rate needs to be restored subsequently, the terminal only needs to control the coprocessor to turn off the frame rate adjustment mode, which will not affect the user's normal use.
[0138] In other possible implementations, when the frame rate and resolution need to be adjusted simultaneously, the terminal may control the coprocessor to enable the frame rate adjustment mode and the resolution adjustment mode simultaneously, which is not limited in this embodiment.
[0139] It should be noted that the above embodiment is only a schematic illustration of the coprocessor adjusting parameters to achieve resolution and frame rate adjustment. In other possible embodiments, the coprocessor can also achieve other functions by adjusting other parameters, and this embodiment does not constitute a limitation to this.
[0140] Step 806 : In response to the current power consumption control policy and the target power consumption control policy not supporting dynamic switching, reconfigure the flow.
[0141] When some control items in the target power consumption control strategy do not support dynamic adjustment (and the coprocessor cannot achieve similar effects by adjusting parameters), when the terminal adjusts the control item, it needs to reconfigure the flow, that is, perform static switching.
[0142] In an illustrative example, when the resolution of the image processor needs to be reduced, the terminal needs to reconfigure the stream when controlling the image processor to switch the resolution.
[0143] In this embodiment, the coprocessor sets the frame rate adjustment mode and the resolution adjustment mode. Without switching the frame rate and resolution of the image sensor, the coprocessor enables the frame rate adjustment mode and the resolution adjustment mode to achieve the effect of reducing the frame rate and resolution. There is no need to reconfigure the stream, thereby reducing the impact of power consumption control strategy switching on user use.
[0144] exist Figure 6 In the software architecture shown in FIG. 1 , in an exemplary embodiment, as shown in FIG. 1 , Figure 9 As shown, the above dynamic switching process may include the following steps.
[0145] Step 901: During the operation of the Camera App, the current temperature control level is level 1.
[0146] Step 902: Centralized temperature control monitors the terminal temperature (monitoring).
[0147] In step 903, the unified temperature control makes a decision and takes action based on the terminal temperature.
[0148] Step 904: The unified temperature control sends the power consumption level of ExplorerController to MMS (set power level of ExplorerController).
[0149] MMS passes the power consumption level to Explorer HAL.
[0150] In step 905 , the Explorer HAL performs status collection.
[0151] In step 906 , the Explorer HAL determines the temperature control level corresponding to the power consumption level in the strategy stage.
[0152] In step 907 , the Explorer HAL makes a decision to close the AINR function of the coprocessor.
[0153] In step 908 , the Explorer HAL controls the coprocessor to close the AINR function (close explorer AINR).
[0154] In step 909 , the Explorer HAL notifies the Camera HAL coprocessor that the AINR function has been completed (notifyexplorer AINR closed).
[0155] In step 910 , the Camera HAL sets metadata for the next capture result.
[0156] This operation is to notify the Camera HAL and pass the corresponding adjustment information to the App as metadata. The metadata will be written to the metadata area of the next frame image (a frame image will be generated after the process capture request).
[0157] In step 911 , the Camera App sends a setRepeatingRequest to the Camera HAL.
[0158] In step 912 , the Camera HAL responds to the request (Process_capture_request).
[0159] In step 913 , the image sensor generates a new frame and notifies the Camera HAL.
[0160] Step 914 , the Camera HAL writes metadata into the capture result (ie, the newly generated image) (Process_capture_result.Write metadata into result).
[0161] In step 915 , the Camera HAL notifies the Camera App to save two split videos.
[0162] exist Figure 6 In the software architecture shown in FIG. 1 , in an exemplary embodiment, as shown in FIG. 1 , Figure 10 As shown, the above static switching process may include the following steps.
[0163] Step 1001: During the operation of the Camera App, the current temperature control level is level 1.
[0164] Step 1002: Centralized temperature control monitors the terminal temperature (monitoring).
[0165] In step 1003, the unified temperature control makes a decision and takes action based on the terminal temperature.
[0166] Step 1004 : The unified temperature control sends the power consumption level of ExplorerController to MMS (set powerlevel of ExplorerController).
[0167] MMS passes the power consumption level to Explorer HAL.
[0168] Step 1005 : Explorer HAL performs status collection.
[0169] In step 1006 , the Explorer HAL determines the temperature control level corresponding to the power consumption level in the strategy stage.
[0170] In step 1007 , the Explorer HAL determines that the temperature control level needs to be adjusted to level 2 (make decision to enter level 2).
[0171] In step 1008 , the Explorer HAL notifies the Camera HAL that streams need to be reconfigured (notify need re-configure Streams).
[0172] Since dynamic switching between level 1 and level 2 is not supported (for example, if the resolution of the image sensor needs to be adjusted), the Camera HAL needs to be notified to reconfigure the stream.
[0173] Step 1009 , the Camera HAL sets custom metadata for the next capture result (set custommetadata to next capture result).
[0174] Step 1010: The Camera App sends a setRepeatingRequest to the Camera HAL.
[0175] Step 1011 , the Camera HAL responds to the request (Process_capture_request).
[0176] In step 1012 , the image sensor generates a new frame and notifies the Camera HAL.
[0177] Step 1013 , the Camera HAL writes metadata into the capture result (ie, the newly generated image) (Process_capture_result.Write metadata into result).
[0178] In step 1014 , the Camera App notifies the user to choose to re-configure Streams.
[0179] The app prompts the user to switch the resolution / frame rate due to temperature control and restarts the device. The stream configuration is performed when the device is restarted.
[0180] The following are device embodiments of the present application, which can be used to implement the method embodiments of the present application. For details not disclosed in the device embodiments of the present application, please refer to the method embodiments of the present application.
[0181] Please refer to Figure 11, which shows a structural block diagram of a power consumption control device provided by an embodiment of the present application. The device may include:
[0182] The level determination module 1101 is configured to determine a target temperature control level from at least two temperature control levels based on the hardware temperature when the shooting function is enabled;
[0183] A strategy determination module 1102 is configured to obtain a target power consumption control strategy corresponding to the target temperature control level, wherein different temperature control levels correspond to different power consumption control strategies, and different power consumption control strategies have different degrees of impact on power consumption;
[0184] The first power consumption control module 1103 is configured to control the power consumption of the coprocessor based on the target power consumption control strategy. The coprocessor is configured to preprocess the raw image data output by the image sensor and transmit the preprocessed image data to the application processor AP.
[0185] Optionally, the level determination module 1101 includes:
[0186] a first level determining unit, configured to determine the terminal temperature based on the hardware temperature in response to a shooting function activation instruction; and determine the target temperature control level from at least two temperature control levels based on the terminal temperature;
[0187] or,
[0188] The second level determination unit is used to determine the terminal temperature based on the hardware temperature during the operation of the shooting function; and determine the target temperature control level from at least two levels of temperature control levels based on the terminal temperature and the processor temperature of the coprocessor.
[0189] Optionally, the first level determining unit is configured to:
[0190] determining a current power consumption level based on the terminal temperature;
[0191] Based on the mapping relationship between the power consumption level and the temperature control level, the target temperature control level corresponding to the current power consumption level is determined.
[0192] Optionally, the first power consumption control module 1103 includes:
[0193] The first power consumption control unit is configured to set initial operating parameters of the coprocessor based on the target power consumption control strategy, wherein the power consumption of the coprocessor is different under different operating parameters.
[0194] Optionally, the second level determining unit is configured to:
[0195] determining a current power consumption level based on the terminal temperature;
[0196] Determining a first temperature control level corresponding to the current power consumption level based on a mapping relationship between the power consumption level and the temperature control level;
[0197] determining a second temperature control level from at least two temperature control levels based on the processor temperature;
[0198] The target temperature control level is determined from the first temperature control level and the second temperature control level.
[0199] Optionally, when determining the target temperature control level from the first temperature control level and the second temperature control level, the second level determining unit is configured to:
[0200] In response to the first temperature control level being higher than the second temperature control level, determining the first temperature control level as the target temperature control level;
[0201] In response to the first temperature control level being lower than the second temperature control level, the second temperature control level is determined as the target temperature control level, wherein the temperature control level is positively correlated with the degree of influence on power consumption.
[0202] Optionally, the first power consumption control module 1103 includes:
[0203] The second power consumption control unit is configured to determine a current power consumption control strategy; and in response to supporting dynamic switching between the current power consumption control strategy and the target power consumption control strategy, adjust the operating parameters of the coprocessor.
[0204] Optionally, the second power consumption control unit is specifically configured to:
[0205] In response to the image resolution indicated by the current power control policy being a first resolution and the image resolution indicated by the target power control policy being a second resolution, controlling the coprocessor to enable a resolution adjustment mode, the first resolution being higher than the second resolution;
[0206] Wherein, in the resolution adjustment mode, the coprocessor is used to perform resolution reduction processing on the original image data output by the image sensor.
[0207] Optionally, the second power consumption control unit is specifically configured to:
[0208] In response to the frame rate indicated by the current power control policy being a first frame rate and the frame rate indicated by the target power control policy being a second frame rate, controlling the coprocessor to enable a frame rate adjustment mode, the first frame rate being higher than the second frame rate;
[0209] Wherein, in the frame rate adjustment mode, the coprocessor is used to preprocess part of the original image data output by the image sensor.
[0210] Optionally, the first power consumption control module 1103 further includes:
[0211] The third power consumption control unit is configured to reconfigure the flow in response to the current power consumption control policy and the target power consumption control policy not supporting dynamic switching.
[0212] Optionally, the second level determining unit is configured to:
[0213] In response to the processor temperature being lower than a temperature threshold, determining a second temperature control level from at least two temperature control levels based on the processor temperature;
[0214] The device further comprises:
[0215] The shut-down module is configured to shut down the coprocessor in response to the processor temperature being higher than the temperature threshold.
[0216] Optionally, the correspondence between the temperature control level and the power consumption control strategy is determined by a k-means clustering algorithm, wherein the clustering basis of the k-means clustering algorithm is the image processing power consumption and image processing quality under the power consumption control strategy.
[0217] Optionally, the device further includes:
[0218] The second power consumption control module is used to control the power consumption of the image signal processing ISP chip of the AP based on the target power consumption control strategy.
[0219] To sum up, in an embodiment of the present application, when the terminal is provided with a coprocessor for preprocessing the raw image data output by the image sensor, by designing multiple temperature control levels and setting corresponding power consumption control strategies for different temperature control levels, the current temperature control level is determined based on the hardware temperature during the shooting process, and then the power consumption of the coprocessor is controlled based on the power consumption control strategy corresponding to the current temperature control level. While ensuring the quality of image preprocessing, the problem of excessive temperature due to excessive power consumption is avoided, thereby achieving the effect of taking into account both image processing quality and operating power consumption.
[0220] It should be noted that the above embodiments provide devices that implement their functions using only the division of the above functional modules as examples. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the device and method embodiments provided in the above embodiments are based on the same concept. The specific implementation process is detailed in the method embodiment and will not be repeated here.
[0221] An embodiment of the present application further provides a computer-readable storage medium, which stores at least one program code, and the program code is loaded and executed by a processor to implement the power consumption control method described in the above embodiments.
[0222] According to one aspect of the present application, a computer program product or computer program is provided, the computer program product or computer program including computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform the power consumption control method provided in various optional implementations of the above aspects.
[0223] It should be understood that the "multiple" mentioned in this article refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent three situations: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the previous and subsequent associated objects are in an "or" relationship. In addition, the step numbers described in this article only illustrate a possible execution sequence between the steps. In some other embodiments, the above steps may not be executed in the order of the numbers, such as two steps with different numbers are executed at the same time, or two steps with different numbers are executed in the opposite order to the diagram. The embodiments of the present application do not limit this.
[0224] The above description is merely an optional embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present application shall be included in the scope of protection of the present application.
Claims
1. A power consumption control method, characterized in that: The method comprises: When the shooting function is turned on, determining a target temperature control level from at least two temperature control levels based on the hardware temperature; Obtaining a target power consumption control strategy corresponding to the target temperature control level, wherein different temperature control levels correspond to different power consumption control strategies, and different power consumption control strategies have different degrees of impact on power consumption; Determine the current power consumption control strategy; In response to supporting dynamic switching between the current power consumption control strategy and the target power consumption control strategy, adjusting operating parameters of a coprocessor, the coprocessor being configured to preprocess raw image data output by an image sensor and transmit the preprocessed image data to an application processor AP; In response to the fact that dynamic switching is not supported between the current power consumption control policy and the target power consumption control policy, the image sensor is reconfigured for flow. When some control items in the target power consumption control policy do not support dynamic adjustment and the terminal adjusts the some control items, the image sensor needs to be reconfigured for flow.
2. The method according to claim 1, characterized in that The step of determining a target temperature control level from at least two temperature control levels based on the hardware temperature when the shooting function is enabled includes: In response to a shooting function start instruction, determining a terminal temperature based on the hardware temperature; and determining the target temperature control level from at least two temperature control levels based on the terminal temperature; or, During the operation of the shooting function, the terminal temperature is determined based on the hardware temperature; and the target temperature control level is determined from at least two temperature control levels based on the terminal temperature and the processor temperature of the coprocessor.
3. The method according to claim 2, characterized in that The determining the target temperature control level from at least two temperature control levels based on the terminal temperature includes: determining a current power consumption level based on the terminal temperature; Based on the mapping relationship between the power consumption level and the temperature control level, the target temperature control level corresponding to the current power consumption level is determined.
4. The method according to claim 3, characterized in that The controlling the power consumption of the coprocessor based on the target power consumption control strategy includes: Initial operating parameters of the coprocessor are set based on the target power consumption control strategy, wherein the power consumption of the coprocessor is different under different operating parameters.
5. The method according to claim 2, characterized in that The determining the target temperature control level from at least two temperature control levels based on the terminal temperature and the processor temperature of the coprocessor includes: determining a current power consumption level based on the terminal temperature; Determining a first temperature control level corresponding to the current power consumption level based on a mapping relationship between the power consumption level and the temperature control level; determining a second temperature control level from at least two temperature control levels based on the processor temperature; The target temperature control level is determined from the first temperature control level and the second temperature control level.
6. The method according to claim 5, characterized in that The determining the target temperature control level from the first temperature control level and the second temperature control level includes: In response to the first temperature control level being higher than the second temperature control level, determining the first temperature control level as the target temperature control level; In response to the first temperature control level being lower than the second temperature control level, the second temperature control level is determined as the target temperature control level, wherein the temperature control level is positively correlated with the degree of influence on power consumption.
7. The method according to claim 1, characterized in that The adjusting the operating parameters of the coprocessor includes: In response to the image resolution indicated by the current power consumption control policy being a first resolution and the image resolution indicated by the target power consumption control policy being a second resolution, controlling the coprocessor to enable a resolution adjustment mode, the first resolution being higher than the second resolution; Wherein, in the resolution adjustment mode, the coprocessor is used to perform resolution reduction processing on the original image data output by the image sensor.
8. The method according to claim 1, characterized in that The adjusting the operating parameters of the coprocessor includes: In response to the frame rate indicated by the current power consumption control policy being a first frame rate and the frame rate indicated by the target power consumption control policy being a second frame rate, controlling the coprocessor to enable a frame rate adjustment mode, the first frame rate being higher than the second frame rate; Wherein, in the frame rate adjustment mode, the coprocessor is used to preprocess part of the original image data output by the image sensor.
9. The method according to claim 5, characterized in that The determining a second temperature control level from at least two temperature control levels based on the processor temperature includes: In response to the processor temperature being lower than a temperature threshold, determining a second temperature control level from at least two temperature control levels based on the processor temperature; The method further comprises: In response to the processor temperature being greater than the temperature threshold, the coprocessor is shut down.
10. The method according to any one of claims 1 to 9, characterized in that: The correspondence between the temperature control level and the power consumption control strategy is determined by a k-means clustering algorithm, wherein the clustering basis of the k-means clustering algorithm is the image processing power consumption and image processing quality under the power consumption control strategy.
11. The method according to any one of claims 1 to 9, characterized in that: The method further comprises: Based on the target power consumption control strategy, the power consumption of the image signal processing (ISP) chip of the AP is controlled.
12. A power consumption control device, characterized in that: The device comprises: a level determination module, configured to determine a target temperature control level from at least two temperature control levels based on the hardware temperature when the shooting function is enabled; a strategy determination module, configured to obtain a target power consumption control strategy corresponding to the target temperature control level, wherein different temperature control levels correspond to different power consumption control strategies, and different power consumption control strategies have different degrees of influence on power consumption; A first power consumption control module, configured to determine a current power consumption control strategy; In response to supporting dynamic switching between the current power consumption control strategy and the target power consumption control strategy, adjusting operating parameters of a coprocessor, the coprocessor being configured to preprocess raw image data output by an image sensor and transmit the preprocessed image data to an application processor AP; In response to the fact that dynamic switching is not supported between the current power consumption control policy and the target power consumption control policy, the image sensor is reconfigured for flow. When some control items in the target power consumption control policy do not support dynamic adjustment and the terminal adjusts the some control items, the image sensor needs to be reconfigured for flow.
13. A terminal, characterized in that: The terminal includes: an image sensor, a coprocessor, a processor, and a memory; the memory stores at least one instruction, and the at least one instruction is used to be executed by the processor to implement the power consumption control method according to any one of claims 1 to 11.
14. A computer-readable storage medium, characterized in that At least one program code is stored in the computer-readable storage medium, and the program code is loaded and executed by the processor to implement the power consumption control method according to any one of claims 1 to 11.
Citation Information
Patent Citations
Method and device for controlling power consumption of terminal, and terminal
CN105786148A
Image processing method, terminal and computer storage medium
CN110933294A