Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention more apparent, embodiments of the present invention will be described in detail below with reference to the accompanying drawings. However, it will be appreciated by those of ordinary skill in the art that numerous technical details are set forth in order to provide a better understanding of the present application in various embodiments of the present invention. However, the technical solution claimed in the present application can be implemented without these technical details and various changes and modifications based on the following embodiments.
Unless the context clearly requires otherwise, throughout the description and the claims, the words "comprise", "comprising", and the like are to be construed in an inclusive sense as opposed to an exclusive or exhaustive sense; that is, what is meant is "including, but not limited to".
In the description of the present disclosure, it is to be understood that the terms "first," "second," and the like are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. In addition, in the description of the present disclosure, "a plurality" means two or more unless otherwise specified.
The first embodiment of the present invention relates to a power control method, which is applied to an electronic device, where the electronic device may be a depth camera itself, a device with a depth camera installed therein, or another device, such as a server or a terminal, communicatively connected to the depth camera or the device with a depth camera installed therein. The depth camera may be a binocular camera or the like. As shown in fig. 1, the power control method includes:
step 101: and determining the hole filling rate of the first image according to the first image shot by the depth camera.
Specifically, the hole filling rate of the first image is determined based on the depth information of the first image. The electronic device analyzes the first image to determine depth information in each pixel in the first image. For some pixel points in the first image, because the binoculars are not matched, the pixel points have no depth (or parallax) information, or the depth (or parallax) information is smaller than a preset value, the depth information of the pixel points is considered to be invalid, and the pixel points are the holes. And the electronic equipment divides the number of the pixel points with the effective depth information by the total number of the pixel points of the first image to obtain the hole filling rate of the first image. The preset value can be set as required, for example, set to 0, or other values.
Step 102: and judging whether the hole filling rate of the first image meets the preset hole filling requirement or not.
Specifically, the hole filling requirement may be determined according to the usage scenario of the first image, and the hole filling requirement is exemplified below.
In a first example, the preset hole filling requirement is: the difference value between the hole filling rate of the first image and the target value of the preset hole filling rate is smaller than a preset first threshold value.
In a second example, the preset hole filling requirements are: the difference value between the hole filling rate of the first image and the hole filling rate of the second image is smaller than a preset second threshold value; the second image is a frame image before the first image.
In a third example, the preset hole filling requirement is: the difference value between the hole filling rate of the first image and the target value of the preset hole filling rate is smaller than a preset first threshold value, or the difference value between the hole filling rate of the first image and the hole filling rate of the second image is smaller than a preset second threshold value.
It should be noted that, as can be understood by those skilled in the art, in practical applications, the cavity filling requirement may also be other requirements, and this embodiment is merely an example, and does not limit the specific content of the cavity filling requirement.
It should be noted that, as will be understood by those skilled in the art, in practical applications, the target value of the void filling rate may be set as needed, for example, to any value in the range from 50% to 100%, the first threshold may be set as needed, for example, to any value in the range from 0% to 3%, and the second threshold may also be set as needed, for example, to any value in the range from 0% to 2%, which is not limited in the present embodiment.
It is worth mentioning that the emission power of the infrared emitter is automatically adjusted based on the hole filling rate, and the intelligence of the electronic equipment is improved.
Step 103: and determining whether to adjust the transmitting power of the infrared transmitter of the depth camera according to the judgment result.
Specifically, from the principle of binocular stereo vision, the more detailed the subject in the scene is, the higher the accuracy of stereo matching, and the more accurate the depth map (or disparity map) generated, the fewer holes. Therefore, the electronic device can determine whether to adjust the transmitting power of the infrared emitter according to whether the hole filling rate of the first image currently shot by the depth camera meets the hole filling requirement.
In one embodiment, the electronic device adjusts the transmission power if the determination result indicates that the hole filling rate of the first image does not meet the hole filling requirement. And if the filling requirement of the cavity is determined to be met, the transmitting power of the infrared transmitter is not adjusted.
It should be noted that, as can be understood by those skilled in the art, if the hole filling rate of the first image meets the hole filling requirement, the electronic device may not adjust the transmission power of the infrared emitter, or may determine whether the transmission power of the infrared emitter needs to be adjusted by combining with other parameters of the first image.
The manner in which the electronic device adjusts the transmit power is illustrated below.
In a first example, if it is determined that the hole filling rate does not meet the hole filling requirement, the process of adjusting the transmission power is as follows: determining the adjustment direction of the transmitting power of the infrared transmitter according to the hole filling rate of the first image, the hole filling rate of the second image and the size relationship between the transmitting power corresponding to the first image and the transmitting power corresponding to the second image; adjusting the transmitting power according to the adjusting direction; the second image is a frame image before the first image.
Optionally, before determining the adjustment direction of the emission power of the infrared emitter, the electronic device determines that the hole filling rate of the first image and the hole filling rate of the second image satisfy a constraint relationship, where the constraint relationship is that a difference between the hole filling rate of the first image and the hole filling rate of the second image is less than or equal to a fourth threshold.
In a second example, the electronic device determines whether the first image is a first frame image shot after the infrared transmitter is turned on according to the transmitting power corresponding to the first image and the transmitting power corresponding to the second image; if yes, adjusting the transmitting power of the infrared transmitter according to a preset adjusting direction; if not, determining the adjustment direction of the emission power of the infrared emitter according to the cavity filling rate of the first image, the cavity filling rate of the second image and the size relationship between the emission power corresponding to the first image and the emission power corresponding to the second image; adjusting the transmitting power according to the adjusting direction; the second image is a frame image before the first image. In this case, the preset adjusting direction may be turned up or turned down. When the adjustment is performed according to a certain adjustment direction, a certain preset value may be adjusted, for example, if the adjustment direction is increased, the transmission power is increased by 10 mw.
It should be noted that, as can be understood by those skilled in the art, in practical application, the preset value may be set according to the granularity supported by the hardware of the depth camera, for example, if the minimum adjustment amount supported by the depth camera is 5 milliwatts, the preset value may be set to 5 milliwatts, and the embodiment does not limit the specific value of the preset value.
In a third example, it is determined whether the infrared emitter is on; if the infrared emitter is not started, adjusting the emission power of the infrared detector to a preset third default power; if the infrared emitter is determined to be started, determining the adjustment direction of the emission power of the infrared emitter according to the void filling rate of the first image, the void filling rate of the second image and the size relationship between the emission power corresponding to the first image and the emission power corresponding to the second image; adjusting the transmitting power according to the adjusting direction; the second image is a frame image before the first image. The value of the third default power may be set according to experience or experimental results, and may be the same as or different from the first default power.
In one embodiment, the electronic device may combine the adjustment modes of the second example and the third example. For example, when adjusting the transmission power based on a certain image, it is assumed that pre _ TX represents the transmission power of a previous frame, cur _ TX represents the transmission power of a current frame, pre _ hole _ filing represents the hole filling rate of the previous frame, cur _ hole _ filling represents the hole filling rate of the current frame, and the preset adjustment direction is increasing. When triggering an adjustment of the transmit power, assumptions and heuristics are made first, since the algorithm does not know at this point whether to adjust the power up or down. Namely: if the hole filling rate is increased, the transmitting power is increased firstly; if the hole filling rate is reduced, the transmit power is reduced. And judging whether the current scene is the hole filling rate which is increased along with the increase of the power or the current scene which is reduced along with the increase of the power according to the result of the first test. Specifically, the process of adjusting power as shown in fig. 2 includes the following steps:
step 201: it is determined whether pre _ TX is 0 and cur _ TX is the first default power. If yes, go to step 202, otherwise, go to step 204.
Step 202: pre _ hold _ filing is cur _ hold _ filing, and pre _ TX is cur _ TX.
Step 203: the transmit power is increased. And then ending the adjusting process.
Step 204: it is determined whether pre _ TX equals 0 and cur _ TX equals 0. If yes, go to step 205, otherwise, go to step 206.
Step 205: turning on an infrared transmitter, and adjusting the transmitting power of the infrared transmitter to a first default power; pre _ TX equals 0. And then ending the adjusting process.
Step 206: it is determined whether pre _ hold _ filtering > cur _ hold _ filtering holds. If yes, go to step 207, and if not, go to step 208.
Step 207: the transmit power is adjusted in a first manner. The flow is then ended.
Specifically, as shown in fig. 3, step 207 includes the following sub-steps:
step 2071: whether cur _ TX is larger than or equal to pre _ TX is judged. If not, go to step 2072, otherwise go to step 2073.
Step 2072: let pre _ TX be cur _ TX, the transmit power is reduced. Wherein the reduced value can be set as desired. The flow is then ended.
Step 2073: let pre _ TX be cur _ TX.
Step 2074: it is determined whether cur TX is greater than or equal to the maximum transmit power. If yes, go to step 2075, otherwise go to step 2076.
Step 2075: the transmit power is adjusted to a maximum transmit power. The flow is then ended.
Step 2076: the transmit power is increased. Wherein the increased value can be set as desired.
Step 208: it is determined whether pre _ hold _ filing ═ cur _ hold _ filing holds. If yes, the adjustment process is ended, otherwise, step 209 is executed.
Step 209: the transmit power is adjusted in a second manner.
Specifically, as shown in fig. 4, step 209 comprises the following sub-steps:
step 2091: whether cur _ TX is larger than or equal to pre _ TX is judged. If yes, go to step 2092, otherwise go to step 2093.
Step 2092: let pre _ TX be cur _ TX, the transmit power is reduced. Wherein the reduced value can be set as desired. The flow is then ended.
Step 2093: let pre _ TX be cur _ TX.
Step 2094: it is determined whether cur TX is greater than or equal to the maximum transmit power. If yes, go to step 2095, otherwise, go to step 2096.
Step 2095: the transmit power is adjusted to a maximum transmit power. The flow is then ended.
Step 2096: the transmit power is increased. Wherein the increased value can be set as desired.
It should be noted that, those skilled in the art can understand that, in practical application, other adjustment manners may also be adopted, which are not listed here.
In one embodiment, the electronic device adjusts the transmission power if the determination result indicates that the hole filling rate of the first image does not meet the hole filling requirement. If the situation that the cavity filling requirement is met is determined, judging whether the shooting scene of the first image is a preset special scene or not according to the judgment parameters of the first image and a preset judgment standard; the evaluation parameter comprises depth information of the first image and/or a brightness index of the first image; if yes, adjusting the transmitting power; if not, the transmit power is not adjusted.
It should be noted that, those skilled in the art can understand that, in practical applications, the judgment parameter may also be other image parameters, and this embodiment is merely an example, and does not limit the type of the parameter used in practical applications.
It is worth mentioning that the emission power of the electronic equipment under a special scene is adjusted, so that the applicable scene of the power control method is improved, and a better adjusting effect can be obtained.
The evaluation parameters and the corresponding evaluation criteria are exemplified below.
In one embodiment, the evaluation parameters are depth information of the first image and a hole filling rate of the first image, and the preset judgment criteria are as follows: and if the depth information of the first image indicates that effective depth information exists in the first image, and the difference value between the hole filling rate of the first image and the hole filling rate of the second image is smaller than a preset third threshold value, determining that the shooting scene of the first image is a preset special scene. Specifically, if the object is far from the depth camera, the infrared emitter is turned on or off, and the emitting power is adjusted in a small amplitude based on the current emitting power, the change of the cavity filling rate is small. If the transmitting power is increased to the infrared effective transmitting power value under the long distance obtained based on experiments or experiences, the adjustment of the transmitting power can increase the hole filling rate, and therefore, the situation can be treated as a special scene.
It should be noted that the third threshold may be set as needed, and this embodiment is not limited, and the third threshold may be equal to or different from the first threshold.
In one embodiment, the evaluation parameter is a brightness index of the first image, and the preset evaluation criterion is: and if the brightness index of the first image indicates that the current scene is very bright, determining that the shooting scene of the first image is a preset special scene. Specifically, if the ambient brightness is too high, the emission power is adjusted under the condition of low emission power, and the void filling rate does not change greatly before and after the adjustment. If the transmitting power is adjusted to be higher, the adjustment of the transmitting power can effectively improve the hole filling rate. Therefore, this case can be treated as a special scene. If the brightness index is increased along with the increase of the brightness, the current scene is considered to be very bright when the brightness index is larger than the brightness index threshold, and if the brightness index is increased along with the increase of the brightness, the brightness index is smaller than the brightness index threshold, the current brightness is considered to be very bright. The brightness index threshold may be set according to the selected brightness index and the project requirement, and the embodiment is not limited.
In one embodiment, the auto-exposure control algorithm defines a corresponding relationship between the actual brightness and a value of the brightness parameter (lux _ index), and can convert the actual brightness into the lux _ index. If the brightness index is the brightness parameter (lux _ index) in the automatic exposure control algorithm, the brightness index threshold may be defined according to the implementation of the automatic exposure control algorithm and the light sensitivity of the light sensor in the depth camera. For example, if the luminance parameter (lux _ index) ranges from 0 to 400, i.e. the luminance parameter is 0 when the actual luminance is the brightest, and the luminance index decreases as the luminance increases, the luminance index threshold may be any value in 180-.
In one embodiment, the evaluation parameter is depth information of the first image, and the preset judgment criteria are: and if the depth information of the first image indicates that no effective depth information exists in the region of interest of the first image, determining that the shooting scene of the first image is a preset special scene. Specifically, the region of interest is centered in a Field of View (FOV) of the first image, the size of the region being defined as a percentage of the FOV, e.g., 40% of the FOV, and the size of the ROI region being adjustable. Since the ROI region has no valid depth information, it may be far from the object or the object is in a blind area, which may adjust the transmit power to a maximum for further determination.
In one embodiment, the evaluation parameter is a hole filling rate of the first image, depth information of the first image, and a brightness index of the first image, and the preset evaluation criterion is: if the depth information of the first image indicates that effective depth information exists in the first image, and the difference value between the hole filling rate of the first image and the hole filling rate of the second image is smaller than a preset third threshold value, or if the brightness index of the first image indicates that the current scene is very bright, or the depth information of the first image indicates that effective depth information does not exist in the region of interest of the first image, it is determined that the shooting scene of the first image is a preset special scene.
It should be noted that, those skilled in the art may understand that the evaluation parameter may also be other parameters, and in practical applications, those skilled in the art may increase the evaluation parameter of the response, the judgment standard of the special scenario, and the processing manner of the special scenario according to other special scenarios found in the use or experiment process of the electronic device, which are only exemplified herein.
In one embodiment, if the shooting scene of the first image is a preset special scene, the adjusting the transmission power specifically includes: and adjusting the transmitting power to a second default power corresponding to the special scene.
For example, as shown in fig. 5, taking a third example of the hole filling requirement as an example, the electronic device determining whether to adjust the transmission power based on the hole filling rate includes the following steps:
step 501: and judging whether the difference value between the hole filling rate of the first image and the target value of the preset hole filling rate is smaller than a preset first threshold value.
Specifically, if the difference between the hole filling rate of the first image and the target value of the hole filling rate is small, step 503 is executed, and if the difference between the hole filling rate of the first image and the target value of the hole filling rate is large, it indicates that the image captured under the current emission power of the infrared emitter cannot meet the use requirement of the first image, and step 502 is executed.
Step 502: and judging whether the difference value between the hole filling rate of the first image and the hole filling rate of the second image is smaller than a preset second threshold value. If yes, step 503 is executed, and if the difference between the hole filling rate of the first image and the hole filling rate of the second image is large, it is indicated that, in the present situation, the quality of the image shot by the depth camera can be effectively improved by adjusting the transmission power of the infrared transmitter, and the transmission power can be further adjusted, and step 504 is executed.
Step 503: and judging whether the shooting scene of the first image is a preset special scene. Specifically, in some special scenes, the reason why the hole filling rate of the first image reaches the target value or the change value before and after the hole filling rate is not large after the transmission power is adjusted is that the current ambient brightness is very bright and other special factors. Therefore, in the present embodiment, a special scene determination step is added to screen some known special scenes. When the shooting scene is a special scene, even if the hole filling rate of the first image meets the hole filling requirement, step 504 is executed to further improve the shooting quality, otherwise, step 505 is executed.
Step 504: the transmit power is adjusted.
Step 505: the transmit power is not adjusted.
It should be noted that, in the example shown in fig. 5, the manner of adjusting the transmission power when the first image does not meet the cavity filling requirement is the same as the manner of adjusting the transmission power when the shooting scene of the first image is a special scene, and those skilled in the art can understand that in practical application, different adjustment manners may also be adopted. For example, when the first image does not meet the hole filling requirement, the manner of adjusting the transmission power is as follows: determining the adjustment direction of the transmitting power of the infrared transmitter according to the hole filling rate of the first image, the hole filling rate of the second image and the size relationship between the transmitting power corresponding to the first image and the transmitting power corresponding to the second image; adjusting the transmitting power according to the adjusting direction; the second image is a frame image before the first image. When the shooting scene of the first image is a special scene, the mode of adjusting the transmitting power is as follows: adjusting the transmitting power to a second default power corresponding to the special scene; or adjusting the transmitting power to a second default power corresponding to the special scene; determining the adjustment direction of the transmitting power of the infrared transmitter according to the hole filling rate of the first image, the hole filling rate of the second image and the size relationship between the transmitting power corresponding to the first image and the transmitting power corresponding to the second image; adjusting the transmitting power according to the adjusting direction; the second image is a frame image before the first image. Fig. 5 is an example only, and is not intended to be limiting.
In one example, the electronic device determines whether the shooting scene of the first image is a special scene and a power adjustment process in each special scene is shown in fig. 6, and includes the following steps:
step 601: and judging whether the first image meets the first requirement. The first requirement is that the depth information of the first image indicates that effective depth information exists in the first image, and the difference value between the hole filling rate of the first image and the hole filling rate of the second image is smaller than a preset third threshold value.
Specifically, if the depth camera is far from the measured object, after the infrared transmitter is turned on with the first default power, the value of the effective distance exists in the region of interest, and the cavity filling rate does not change much after the infrared transmitter is turned off/on, which indicates that the current first default power is not helpful to increase the cavity filling rate due to the distance. Therefore, if the depth information of the first image indicates that there is valid depth information in the first image, and the difference between the hole filling rate of the first image and the hole filling rate of the second image is smaller than the preset third threshold, step 602 is executed to change the transmission power to the second default power in the special scene, that is, the remote default power (tx _ far _ default) with a larger value, otherwise, step 603 is executed.
Step 602: the transmit power is adjusted to the remote default power. The flow is then ended.
Step 603: and judging whether the first image meets the second requirement. The second requirement is that the luminance index is greater than a preset luminance index threshold.
Specifically, in some scenarios, the ambient brightness is very bright, resulting in a less effective increase in transmit power based on the current transmit power. The ambient brightness is determined based on the brightness index (lux _ index), and the brighter the ambient, the smaller the lux _ index. If the brightness index of the first image is greater than the preset brightness index threshold, step 604 is executed to modify the transmission power to a second default power in the special scene, that is, a higher-brightness default power with a larger value, otherwise, step 605 is executed.
Step 604: the transmit power is adjusted to a high brightness default power. The flow is then ended.
It should be noted that, in practical applications, if it is determined that lux _ index is smaller than the brightness index threshold, it is determined that the current environment is too bright, and in a case that the current scene does not belong to other special scenes, turning on or turning off the infrared emitter has little influence on the hole filling rate, in which case, the infrared detector may be turned off, so that the transmission power of the infrared detector is 0.
Step 605: and judging whether the first image meets the third requirement. A third requirement is that no valid depth information is present in the region of interest of the first image.
Specifically, there is no valid depth information (distance value) in the region of interest, and it may be that the object is far from the depth camera or that the object is in a dead zone. Therefore, if there is no effective depth information in the region of interest of the first image, step 606 may be executed to adjust the transmission power to a second default power, i.e. a maximum power, in the special scene, so as to further determine the specific situation.
Step 606: the transmission power is adjusted to the maximum power, and then the process ends.
It should be noted that fig. 6 is only an example, and in practical applications, after step 602, step 604 and step 606, other judgments may be performed to further adjust the transmission power, for example, after step 602, step 604 and step 606 are executed, the adjustment direction of the transmission power of the infrared emitter is determined according to the hole filling rate of the first image and the hole filling rate of the second image, and the magnitude relationship between the transmission power corresponding to the first image and the transmission power corresponding to the second image; adjusting the transmitting power according to the adjusting direction; the second image is a frame image before the first image. The present embodiment is illustrative only and not limiting.
The above description is only for illustrative purposes and does not limit the technical aspects of the present invention.
Compared with the prior art, the power control method provided in the embodiment judges whether the transmitting power of the infrared transmitter of the depth camera needs to be adjusted in the current scene based on the hole filling rate, which is an index indicating the quality of the depth image, so that the transmitting power of the infrared transmitter is more suitable for the current scene, the situation of power consumption caused by continuously increasing the transmitting power for improving the hole filling rate is avoided, and the situation of insufficient depth detection precision caused by too low transmitting power is also avoided.
The second embodiment of the present invention relates to a power control method, and is further improved on the basis of the first embodiment, and the specific improvements are as follows: before step 101, it is determined whether to turn on the infrared emitter based on the texture value of the first image.
Specifically, as shown in fig. 7, the present embodiment includes steps 701 to 707, wherein steps 705 to 707 are substantially the same as steps 101 to 103 in the first embodiment, and are not repeated here. The following mainly introduces the differences:
step 701: a texture value of the first image is obtained.
Specifically, the texture value is determined based on the gradient in the X-axis direction and the gradient in the Y-axis direction of the region of interest of the first image. For example, the texture value may be an average gradient in the X-axis direction and the Y-axis direction of the region of interest of the first image.
It should be noted that, as will be understood by those skilled in the art, in practical applications, other parameters may be used for the texture value, and this embodiment is merely an example.
In one embodiment, the region of interest of the first image is determined to be normally exposed prior to acquiring the texture values of the first image. Specifically, when the electronic device starts to operate, automatic exposure adjustment is performed first. The electronics count the gray scale values (Y) of the pixels in the region of interest and make exposure adjustments based on the gray scale value of each pixel. For example, the region of interest is divided into m x n sub-regions, such as 3 x 3, where m and n may be any positive integer. For each sub-region of m x n, a weighting coefficient is set, which is adjustable. And calculating the gray average value of the sub-regions for the pixels in each sub-region. And multiplying the gray average value of each sub-area by the weighting coefficient of the corresponding sub-area to obtain a weighted gray value. And adding the weighted gray values of all the sub-areas in the region of interest to obtain the gray value of the region of interest. If the gray value of the region of interest indicates that the region of interest is overexposed, the electronic device may adjust the Exposure by an Automatic Exposure Control (AEC) algorithm until the region of interest is not overexposed. Alternatively, if the exposure time is adjusted to be the shortest under high light conditions, such as an outdoor glare environment, and the exposure is still overexposed after the minimum sensor gain and the processor gain, the subsequent steps are not executed and the infrared emitter is determined not to be turned on directly.
It is worth mentioning that, because the infrared emitter is turned on or off in a high-brightness environment, the influence on the image quality is small, and when the environment is determined to be too bright, the power adjustment of the infrared emitter is not performed, so that unnecessary resource waste is avoided.
Step 702: and judging whether the first image has texture or not according to the texture value of the first image and a preset texture threshold.
Specifically, if it is determined that the first image has no texture, step 703 is performed, otherwise, step 705 is performed.
Step 703: and judging whether the infrared emitter is started or not.
Specifically, step 705 is performed if the ir emitter is turned on, and step 704 is performed if the ir emitter is not turned on.
Step 704: and adjusting the sending power of the infrared transmitter to a preset first default power, and shooting the first image again. Step 705 is then performed.
It is worth mentioning that when the first image has no texture, the pattern required to be projected by the infrared emitter is illustrated, and the details of the texture of the object to be shot are increased. Therefore, whether the infrared emitter is started or not is judged firstly when the first image has no texture, and the infrared emitter is started firstly under the condition that the infrared emitter is not started, so that the electronic equipment can automatically start the infrared emitter under the condition that the infrared emitter needs to be started. Subsequent adjustment operation is carried out on the basis of the image shot after the infrared transmitter is started, so that a judgment cycle can be reduced, and unnecessary resource waste is reduced.
Step 705: and determining the hole filling rate of the first image according to the first image shot by the depth camera.
Step 706: and judging whether the hole filling rate of the first image meets the preset hole filling requirement or not.
Step 707: and determining whether to adjust the transmitting power of the infrared transmitter of the depth camera according to the judgment result.
The above description is only for illustrative purposes and does not limit the technical aspects of the present invention.
Compared with the prior art, the power control method provided in the embodiment judges whether to start the infrared transmitter based on the texture value when performing infrared adjustment based on the hole filling rate, so that the electronic device can automatically start the infrared transmitter, and performs subsequent adjustment operation based on an image shot after the infrared transmitter is started, thereby reducing one judgment cycle and reducing unnecessary resource waste.
The steps of the above methods are divided for clarity, and the implementation may be combined into one step or split some steps, and the steps are divided into multiple steps, so long as the same logical relationship is included, which are all within the protection scope of the present patent; it is within the scope of the patent to add insignificant modifications to the algorithms or processes or to introduce insignificant design changes to the core design without changing the algorithms or processes.
A third embodiment of the present invention relates to a power control device, as shown in fig. 8, including: a determination module 801, a judgment module 802, and an adjustment module 803. The determining module 801 is configured to determine a hole filling rate of a first image according to the first image captured by the depth camera, where the hole filling rate of the first image is determined according to the depth information of the first image. The determining module 802 is configured to determine whether a hole filling rate of the first image meets a preset hole filling requirement. The adjusting module 803 is configured to determine whether to adjust the transmitting power of the infrared emitter of the depth camera according to the determination result.
It should be understood that this embodiment is a system example corresponding to the first embodiment, and may be implemented in cooperation with the first embodiment. The related technical details mentioned in the first embodiment are still valid in this embodiment, and are not described herein again in order to reduce repetition. Accordingly, the related-art details mentioned in the present embodiment can also be applied to the first embodiment.
It should be noted that each module referred to in this embodiment is a logical module, and in practical applications, one logical unit may be one physical unit, may be a part of one physical unit, and may be implemented by a combination of multiple physical units. In addition, in order to highlight the innovative part of the present invention, elements that are not so closely related to solving the technical problems proposed by the present invention are not introduced in the present embodiment, but this does not indicate that other elements are not present in the present embodiment.
A fourth embodiment of the present invention relates to an electronic apparatus, as shown in fig. 9, including: at least one processor 901; and, memory 902 communicatively connected to at least one processor 901; the memory 902 stores instructions executable by the at least one processor 901, and the instructions are executed by the at least one processor 901, so that the at least one processor 901 can execute the power control method mentioned in the above embodiments.
The electronic device includes: one or more processors 901 and a memory 902, where one processor 901 is taken as an example in fig. 9. The processor 901 and the memory 902 may be connected by a bus or by other means, and fig. 9 illustrates the connection by the bus as an example. Memory 902, which is a non-volatile computer-readable storage medium, may be used to store non-volatile software programs, non-volatile computer-executable programs, and modules 9. The processor 901 executes various functional applications of the device and data processing by executing nonvolatile software programs, instructions, and modules stored in the memory 902, that is, implements the above-described power control method.
The memory 902 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required for at least one function; the storage data area may store a list of options, etc. Further, the memory 902 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some embodiments, the memory 902 may optionally include memory located remotely from the processor 901, which may be connected to an external device via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
One or more modules are stored in the memory 902 and when executed by the one or more processors 901 perform the power control method of any of the method embodiments described above.
The product can execute the method provided by the embodiment of the application, has corresponding functional modules and beneficial effects of the execution method, and can refer to the method provided by the embodiment of the application without detailed technical details in the embodiment.
A fifth embodiment of the present invention relates to a computer-readable storage medium storing a computer program. The computer program realizes the above-described method embodiments when executed by a processor.
That is, as can be understood by those skilled in the art, all or part of the steps in the method for implementing the embodiments described above may be implemented by a program instructing related hardware, where the program is stored in a storage medium and includes several instructions to enable a device (which may be a single chip, a chip, or the like) or a processor (processor) to execute all or part of the steps of the method described in the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
It will be understood by those of ordinary skill in the art that the foregoing embodiments are specific examples for carrying out the invention, and that various changes in form and details may be made therein without departing from the spirit and scope of the invention in practice.