CN111432136A - Current value adjusting method and device for lens lamp panel - Google Patents

Current value adjusting method and device for lens lamp panel Download PDF

Info

Publication number
CN111432136A
CN111432136A CN202010260762.0A CN202010260762A CN111432136A CN 111432136 A CN111432136 A CN 111432136A CN 202010260762 A CN202010260762 A CN 202010260762A CN 111432136 A CN111432136 A CN 111432136A
Authority
CN
China
Prior art keywords
target image
preset
white balance
determining
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010260762.0A
Other languages
Chinese (zh)
Other versions
CN111432136B (en
Inventor
陈果
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN202010260762.0A priority Critical patent/CN111432136B/en
Publication of CN111432136A publication Critical patent/CN111432136A/en
Application granted granted Critical
Publication of CN111432136B publication Critical patent/CN111432136B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/70Circuitry for compensating brightness variation in the scene
    • H04N23/71Circuitry for evaluating the brightness variation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/70Circuitry for compensating brightness variation in the scene
    • H04N23/75Circuitry for compensating brightness variation in the scene by influencing optical camera components
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/70Circuitry for compensating brightness variation in the scene
    • H04N23/76Circuitry for compensating brightness variation in the scene by influencing the image signals

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Color Television Image Signal Generators (AREA)
  • Studio Devices (AREA)

Abstract

The invention provides a method and a device for adjusting the current value of a lens lamp panel, which comprise the following steps: determining an environment brightness value of a target image shot by a target monitoring device and a white balance parameter of each statistical block in the target image, wherein the target image comprises N statistical blocks, and N is greater than or equal to 1; determining the infrared component ratio of the target image according to the distance between the white balance parameter of each statistical block and a preset white balance parameter, wherein the preset white balance parameter is the average white balance parameter of a first preset image shot by the target monitoring equipment in a closed environment; determining an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio; and adjusting the current value of a lens lamp panel on the target monitoring equipment according to the infrared light brightness value. According to the invention, the problem of overexposure of the object shot by the monitoring equipment due to the fact that the object is close to the lamp panel is solved.

Description

Current value adjusting method and device for lens lamp panel
Technical Field
The invention relates to the field of communication, in particular to a method and a device for adjusting a current value of a lens lamp panel.
Background
With the improvement of safety consciousness of people, monitoring equipment is common in daily life. Such as factories, homes, elevators and monitoring equipment on traffic roads. Under the darker condition of environment, the infrared lamp light filling on self lamp plate can be opened to the surveillance camera machine, promotes the monitoring effect under the darker environment. But if have the object to be nearer apart from the lamp plate in the control environment, because the reason of infrared reflection of light, the phenomenon of object overexposure can appear, and object background dark space luminance all around can become dark moreover, all can't satisfy the control demand like this, in case the criminal incident that appears illegal, can lead to the important details of control to lose.
To among the correlation technique, because the object is nearer apart from the lamp plate, the problem of overexposure appears in the object that the supervisory equipment that leads to shot, does not have effectual solution at present yet.
Disclosure of Invention
The embodiment of the invention provides a method and a device for adjusting a current value of a lens lamp panel, which are used for at least solving the problem that an object shot by monitoring equipment is overexposed due to the fact that the object is close to the lamp panel in the related art.
According to an embodiment of the present invention, there is provided a method for adjusting a current value of a lens lamp panel, including: determining an environment brightness value of a target image shot by a target monitoring device and a white balance parameter of each statistical block in the target image, wherein the target image comprises N statistical blocks, and N is greater than or equal to 1; determining the infrared component ratio of the target image according to the distance between the white balance parameter of each statistical block and a preset white balance parameter, wherein the preset white balance parameter is an average white balance parameter of a first preset image shot by the target monitoring device in a closed environment; determining an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio; and adjusting the current value of a lens lamp panel on the target monitoring equipment according to the infrared light brightness value.
Optionally, the determining an infrared component ratio of the target image according to a distance between the white balance parameter of each statistical partition and a preset white balance parameter includes: determining a statistical block corresponding to the white balance parameter with the distance to the preset white balance parameter smaller than or equal to a first preset threshold value as a target statistical block; and determining the ratio of the number M of the target statistical blocks to the number N of all statistical blocks in the target image as the infrared component ratio of the target image.
Optionally, the determining the infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio includes: determining the product of the environment brightness value and the infrared component ratio as an infrared light brightness value of the target image, wherein the larger the infrared light brightness value is, the closer the object in the target image is to the target monitoring device when the target image is shot, and the smaller the infrared light brightness value is, the farther the object in the target image is from the target monitoring device when the target image is shot.
Optionally, the adjusting, according to the infrared brightness value, a current value of a lens lamp panel on the target monitoring device includes: determining that the ratio of the infrared light brightness value of the target image to a preset infrared light brightness value of a second preset image is a light reflection ratio, wherein the second preset image is an image obtained by shooting a preset object with a distance less than or equal to a preset distance by the target monitoring equipment; determining a small-angle lens current value on the lens lamp panel as PWM (1-rate), and determining a large-angle lens current value on the lens lamp panel as PWM rate, wherein the PWM is a maximum current value of the lens lamp panel, and the rate is the reflection ratio.
Optionally, the method further comprises one of: under the condition that the PWM (1-rate) is determined to be smaller than a second preset threshold value and the PWM rate is greater than a third preset threshold value, adjusting a small-angle lens current value on the lens lamp plate to be the second preset threshold value and adjusting a large-angle lens current value on the lens lamp plate to be the third preset threshold value; and under the condition that the PWM (1-rate) is determined to be greater than a fourth preset threshold value and the PWM rate is determined to be less than a fifth preset threshold value, adjusting the small-angle lens current value on the lens lamp plate to be the fourth preset threshold value, and adjusting the large-angle lens current value on the lens lamp plate to be the fifth preset threshold value.
Optionally, determining an ambient brightness value of the target image captured by the target monitoring device includes: acquiring a shutter value when the target monitoring equipment shoots the target image and an exposure gain value of the target image; determining the ambient brightness value Env according to the following formula:
Figure BDA0002439203360000031
wherein, cur _ shut is the shutter value, cur _ gain is the exposure gain value, and K1 and K2 are preset parameters.
According to another embodiment of the present invention, there is provided a current value adjusting apparatus of a lens lamp panel, including: the device comprises a first determining module, a second determining module and a processing module, wherein the first determining module is used for determining an environment brightness value of a target image shot by a target monitoring device and a white balance parameter of each statistical block in the target image, the target image comprises N statistical blocks, and N is greater than or equal to 1; a second determining module, configured to determine an infrared component ratio of the target image according to a distance between a white balance parameter of each statistical block and a preset white balance parameter, where the preset white balance parameter is an average white balance parameter of a first preset image captured by the target monitoring device in a closed environment; a third determining module, configured to determine an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio; and the adjusting module is used for adjusting the current value of a lens lamp panel on the target monitoring equipment according to the infrared light brightness value.
Optionally, the second determining module further includes: a first determining unit, configured to determine, as a target statistical block, a statistical block corresponding to a white balance parameter whose distance from the preset white balance parameter is smaller than or equal to a first preset threshold; a second determining unit, configured to determine that a ratio of the number M of the target statistical blocks to the number N of all statistical blocks in the target image is an infrared component ratio of the target image.
According to a further embodiment of the present invention, there is also provided a storage medium having a computer program stored therein, wherein the computer program is arranged to perform the steps of any of the above method embodiments when executed.
According to yet another embodiment of the present invention, there is also provided an electronic device, including a memory in which a computer program is stored and a processor configured to execute the computer program to perform the steps in any of the above method embodiments.
By the invention, N is more than or equal to 1 by determining the environmental brightness value of the target image shot by the target monitoring equipment and the white balance parameter of each statistical block in N statistical blocks included in the target image; determining the infrared component ratio of the target image according to the distance between the white balance parameter of each statistical block and a preset white balance parameter, wherein the preset white balance parameter is the average white balance parameter of a first preset image shot by the target monitoring equipment in a closed environment; determining an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio; and adjusting the current value of a lens lamp panel on the target monitoring equipment according to the infrared light brightness value. Therefore, the purpose of adjusting the current of the lens lamp plate according to the distance between the object and the monitoring equipment in the image is achieved, the problem that the object shot by the monitoring equipment is overexposed due to the fact that the object is close to the lamp plate can be solved, the size of the current value of the lens lamp plate can be automatically adjusted, and the effect of improving the quality of the image shot by the monitoring equipment is improved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the invention without limiting the invention. In the drawings:
fig. 1 is a block diagram of a hardware structure of a mobile terminal of a method for adjusting a current value of a lens lamp panel according to an embodiment of the present invention;
fig. 2 is a flowchart of a current value adjusting method of a lens lamp panel according to an embodiment of the present invention;
fig. 3 is a first schematic diagram illustrating a current value adjusting method for a lens lamp panel according to an alternative embodiment of the present invention;
fig. 4 is a schematic diagram of a current value adjusting method for a lens lamp panel according to an alternative embodiment of the invention;
fig. 5 is a block diagram of a current value adjusting apparatus of a lens lamp panel according to an embodiment of the present invention.
Detailed Description
The invention will be described in detail hereinafter with reference to the accompanying drawings in conjunction with embodiments. It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order.
The method provided by the first embodiment of the present application may be executed in a mobile terminal, a computer terminal, or a similar computing device. Taking the operation on a mobile terminal as an example, fig. 1 is a block diagram of a hardware structure of the mobile terminal of a method for adjusting a current value of a lens lamp panel according to an embodiment of the present invention. As shown in fig. 1, the mobile terminal 10 may include one or more (only one shown in fig. 1) processors 102 (the processor 102 may include, but is not limited to, a processing device such as a microprocessor MCU or a programmable logic device FPGA) and a memory 104 for storing data, and optionally may also include a transmission device 106 for communication functions and an input-output device 108. It will be understood by those skilled in the art that the structure shown in fig. 1 is only an illustration, and does not limit the structure of the mobile terminal. For example, the mobile terminal 10 may also include more or fewer components than shown in FIG. 1, or have a different configuration than shown in FIG. 1.
The memory 104 may be used to store a computer program, for example, a software program and a module of application software, such as a computer program corresponding to the current value adjusting method of the lens lamp panel in the embodiment of the present invention, and the processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, so as to implement the above method. The memory 104 may include high speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory located remotely from the processor 102, which may be connected to the mobile terminal 10 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.
The transmission device 106 is used for receiving or transmitting data via a network. Specific examples of the network described above may include a wireless network provided by a communication provider of the mobile terminal 10. In one example, the transmission device 106 includes a Network adapter (NIC), which can be connected to other Network devices through a base station so as to communicate with the internet. In one example, the transmission device 106 may be a Radio Frequency (RF) module, which is used for communicating with the internet in a wireless manner.
In this embodiment, a method for adjusting a current value of a lens lamp panel operating in the mobile terminal is provided, and fig. 2 is a flowchart of a method for adjusting a current value of a lens lamp panel according to an embodiment of the present invention, as shown in fig. 2, the flowchart includes the following steps:
step S202, determining an environment brightness value of a target image shot by target monitoring equipment and a white balance parameter of each statistical block in the target image, wherein the target image comprises N statistical blocks, and N is greater than or equal to 1;
step S204, determining the infrared component ratio of the target image according to the distance between the white balance parameter of each statistical block and a preset white balance parameter, wherein the preset white balance parameter is an average white balance parameter of a first preset image shot by the target monitoring equipment in a closed environment;
step S206, determining an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio;
and S208, adjusting the current value of a lens lamp panel on the target monitoring equipment according to the infrared light brightness value.
Fig. 3 is a schematic diagram of a lens lamp panel on the target monitoring device according to an alternative embodiment of the present invention, where the lens lamp panel includes small-angle and large-angle lens lamps, and the small-angle and large-angle lens lamps are staggered and symmetrically distributed to ensure uniformity of supplementary lighting. The object that closely is the main part target of control, need see closely the object clearly, but the object detail all around also need pay attention to simultaneously, need reduce the current strength of the last small-angle lens of camera lamp plate (reduce central light filling intensity) this moment, guaranteed that the control object center can not lead to overexposure seriously because of closely infrared light is too strong. In addition, due to the fact that objects exist in a short distance, the overall exposure intensity can be reduced through the automatic exposure module of the camera, the light supplement intensity around can be improved through increasing the current intensity of the large-angle lens on the lamp panel of the camera (the light supplement intensity of the surrounding background is improved), and the uniformity of the overall brightness of the monitored image is guaranteed. On the contrary, when judging that there is not closely object reflection of light, when the control scene is spacious, the more far away that needs to see this moment is better, remote messenger our control main part, the current intensity of small-angle lens (improvement center light filling intensity) on the camera lamp plate need increase this moment, the current intensity of large-angle lens (reduce background light filling intensity all around) on the reduction camera lamp plate, has guaranteed the maximum distance of control.
As an alternative embodiment, the object monitoring device includes a camera and a lens light panel. Dividing a target image shot by a target monitoring device into N statistical blocks, counting white balance data (rGain1, bGain1), (rGain2, bGain2), (rGain3, bGain3) … (rGainn, bGainn) of each statistical block in the image, and counting the ambient brightness value of the current target image:
Figure BDA0002439203360000071
where K1 and K2 are preset constant coefficients, and cur _ gain and cur _ shut are the exposure gain value and shutter value of the current target image, respectively.
As an alternative embodiment, the far and near states of the infrared lamp are determined by judging the infrared reflection intensity of the object currently monitored. The distance of the object is different, the light information reflected back to the sensor in the camera is also different, and the far and near states of the object are determined through the component information of the reflected back light. In this embodiment, the monitoring device is placed in a narrow space such as a closed small carton, light of the fill-in light is ensured to be completely reflected into the camera sensor, a first preset image is obtained in the closed space through shooting by the camera, the average value of white balance parameters (irRGain, irBGain) of the first preset image in a pure infrared environment is counted, and the infrared component ratio of the target image is determined according to the distance between the white balance parameters (rGain1, bGain1), (rGain2, bGain2), (rGain3, bGain3) … (rGain, bGain) of each statistical block in the target image and the average value of white balance parameters (rGain, irBGain) in the pure infrared environment.
As an alternative embodiment, the luminance contributed by the infrared light in the environment luminance value, that is, the infrared light luminance value EnvIr ═ ir _ rate, may be obtained by calculating the obtained environment luminance value Env and the infrared component ratio ir _ rate to which the target pushes. In the supervisory environment, when shooing the target image, object distance light filling lamp in the target image is more close, and the EnvIr that makes statistics out is bigger, if on the contrary the object is more far away from the light filling lamp, and the light filling reflection of light is weaker, and the EnvIr that makes statistics out is smaller. Therefore, the distance between an object and the monitoring equipment when the target image is shot can be reflected according to the infrared light brightness value of the target image, and the current value of the lens lamp panel on the target monitoring equipment is adjusted according to the reflected distance. Thereby, the exposure problem caused by the object being too close to the monitoring equipment can be placed.
Through the above steps, since N is greater than or equal to 1 by determining the ambient brightness value of the target image captured by the target monitoring device and the white balance parameter of each of N statistical blocks included in the target image; determining the infrared component ratio of the target image according to the distance between the white balance parameter of each statistical block and a preset white balance parameter, wherein the preset white balance parameter is the average white balance parameter of a first preset image shot by the target monitoring equipment in a closed environment; determining an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio; and adjusting the current value of a lens lamp panel on the target monitoring equipment according to the infrared light brightness value. Therefore, the purpose of adjusting the current of the lens lamp plate according to the distance between the object and the monitoring equipment in the image is achieved, the problem that the object shot by the monitoring equipment is overexposed due to the fact that the object is close to the lamp plate can be solved, the size of the current value of the lens lamp plate can be automatically adjusted, and the effect of improving the quality of the image shot by the monitoring equipment is improved.
Alternatively, the execution subject of the above steps may be a terminal or the like, but is not limited thereto.
Optionally, the determining an infrared component ratio of the target image according to a distance between the white balance parameter of each statistical partition and a preset white balance parameter includes: determining a statistical block corresponding to the white balance parameter with the distance to the preset white balance parameter smaller than or equal to a first preset threshold value as a target statistical block; and determining the ratio of the number M of the target statistical blocks to the number N of all statistical blocks in the target image as the infrared component ratio of the target image.
As an alternative embodiment, the white balance parameters (rGain1, bGain1), (rGain2, bGain2), (rGain3, bGain3) … (rGain, bGain) of each statistical block of the target image are compared with the average white balance parameter (irRGain, irBGain) in the pure infrared environment on two-dimensional coordinates, as shown in fig. 4, a two-dimensional coordinate diagram is shown, and the statistical block corresponding to the white balance parameter (irRGain, irBGain) whose distance from (irRGain, irBGain) is smaller than a first preset threshold L is determined as the target statistical block with (irRGain, irBGain) as the center, the distance between the white balance parameters (rGain2, bGain) and the pure (rGain, bGain) is smaller than a first preset threshold L as shown in fig. 4, the threshold 2 is determined as the pure white balance parameter (rGain2, bGain) and the pure (rGain, bGain) is equal to the pure infrared block P638, the infrared block is determined as the target statistical block with the infrared ray radius equal to be larger than the infrared ray radius of the target image, and the infrared ray radius of the target block is equal to 100.
Optionally, the determining the infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio includes: determining the product of the environment brightness value and the infrared component ratio as an infrared light brightness value of the target image, wherein the larger the infrared light brightness value is, the closer the object in the target image is to the target monitoring device when the target image is shot, and the smaller the infrared light brightness value is, the farther the object in the target image is from the target monitoring device when the target image is shot.
As an optional implementation, according to the calculated environment luminance value Env, the infrared component ratio ir _ ratio in the environment is monitored, and the luminance contributed by the infrared light in the environment luminance value of the target image, that is, the infrared luminance value EnvIr ═ Env ir _ ratio, can be obtained, in the monitored environment, the more the object is close to the fill light, the larger the counted EnvIr is, and conversely, if the object is farther from the fill light, the weaker the fill light reflection is, the smaller the counted EnvIr is.
Optionally, the adjusting, according to the infrared brightness value, a current value of a lens lamp panel on the target monitoring device includes: determining that the ratio of the infrared light brightness value of the target image to a preset infrared light brightness value of a second preset image is a light reflection ratio, wherein the second preset image is an image obtained by shooting a preset object with a distance less than or equal to a preset distance by the target monitoring equipment; determining a small-angle lens current value on the lens lamp panel as PWM (1-rate), and determining a large-angle lens current value on the lens lamp panel as PWM rate, wherein the PWM is a maximum current value of the lens lamp panel, and the rate is the reflection ratio.
As an alternative embodiment, a maximum ir luminance value may be calibrated, which may be calibrated as follows: when the object is nearer at the red lens lamp plate, for example 1 meter or be less than 1 meter or other numerical values, specific distance value can be markd according to actual conditions by oneself. Taking the calibration distance of 1 meter as an example, the reflection of light is strongest at the moment, the center of a second preset image obtained by shooting through monitoring equipment can be overexposed, the periphery can be darker, the current of a small-angle lens needs to be adjusted to be minimum, the current of a large-angle lens needs to be adjusted to be maximum, and the calculated infrared light brightness value is taken as EnvIrMax. When the monitoring equipment is used for shooting an image, the correlation coefficient of an object in the image and a lens lamp panel fill light can be expressed by a formula of (EnvIr/Env _ max)% 100, Env _ Ir is an infrared brightness value counted by the current position of the object, and when the object is closer than a calibration distance, the ratio value is always 100%, and at the moment, the current object is already close; when the object is farther than the calibrated distance, the statistic EnvIr is smaller than the Env _ max, the ratio changes from 0% to 100%, and the closer the object is to the fill light, the larger the ratio is, and the smaller the ratio is. This rate value may reflect the near-far state of the object. Therefore, the distance of an object in front of the infrared lamp can be known through the infrared reflection intensity.
As an alternative embodiment, the small angle and large angle lens currents are adjusted by the calculated ratio, the small angle lens current value on the lens panel is set to PWM (1-ratio), the large angle lens current value on the lens panel is set to PWM ratio, PWM is the maximum current value of the lens panel, and ratio is the reflection ratio. Taking the example of the PWM as 800mA, most of the current designs of the conventional infrared lamps do not control the magnitude of the current, for example, the current on the lamp panel is fixed to be adjusted to be 800mA at maximum, and half of the current of 400mA is contributed by each of the large-angle lens group and the small-angle lens group. Because the current of the traditional large-angle lens group and the current of the traditional small-angle lens group can not change according to the distance of the shot object, the exposure phenomenon can be generated under the condition that the shot object is too close to the monitoring equipment.
According to the method, the distance between the object and the infrared lamp is estimated according to the light emitting intensity of the object in the infrared lamp environment. For example, when the object is 15 meters away from the infrared lamp, the reflection ratio is calculated to be 10%, and then the small angle lens current is 800 × 720mA (1-10%); the large-angle lens current is 800 × 10% to 80mA, so that the total lamp panel current is kept unchanged, namely 800mA (the total lamp panel power is unchanged); when the object is 10 meters away from the infrared lamp, the calculated light reflection rate is 50%, then the current of the small-angle lens is 800 x (1-50%), 400mA, and the current of the large-angle lens is 400mA, and the state is consistent with the current of the large-angle and small-angle lens in the traditional scheme; when the object is 5 meters away from the infrared lamp, the calculated light reflection ratio is 90%, and then the small-angle lens current is 800 × 1-90% — 80mA, and the large-angle lens current is 800 × 90% — 720 mA; this application is according to big angle and the small-angle lens current on the distance dynamic adjustment lamp plate of shooting object and supervisory equipment, and the phenomenon of exposure appears in the image that can effectually prevent to shoot, reaches the effect that improves the monitoring degree of accuracy.
Optionally, the method further comprises one of: under the condition that the PWM (1-rate) is determined to be smaller than a second preset threshold value and the PWM rate is greater than a third preset threshold value, adjusting a small-angle lens current value on the lens lamp plate to be the second preset threshold value and adjusting a large-angle lens current value on the lens lamp plate to be the third preset threshold value; and under the condition that the PWM (1-rate) is determined to be greater than a fourth preset threshold value and the PWM rate is determined to be less than a fifth preset threshold value, adjusting the small-angle lens current value on the lens lamp plate to be the fourth preset threshold value, and adjusting the large-angle lens current value on the lens lamp plate to be the fifth preset threshold value.
As an alternative embodiment, if the current of the large-angle or small-angle lens on the lamp panel is too small, the lamp will be off, and thus the lamp panel will be mistaken for a fault. In this embodiment, to prevent the lamp-out condition caused by too small of a current, a minimum threshold is set during both the large angle and small angle lens adjustments. E.g. 10mA (only remain on, the contribution to brightness is already small). When an object is 0.5 m away from the infrared lamp, the calculated reflection rate is 99%, the calculated current of the small-angle lens is 8mA, the calculated current of the large-angle lens is 792mA, and due to the fact that a threshold value is preset, when the current is smaller than the minimum value or larger than the maximum value, the threshold value is kept unchanged, the current of the small-angle lens is 10mA, and the current of the large-angle lens is 790 mA. Or for example, when the object is 1.5 meters away from the infrared lamp, the calculated reflection ratio is 1%, the calculated current of the small-angle lens is 792mA, and the calculated current of the large-angle lens is 8mA, and since the threshold value is preset, the threshold value is kept unchanged when the current is smaller than the minimum value or larger than the maximum value, the current of the small-angle lens is 790mA, and the current of the large-angle lens is 10 mA.
As an optional implementation scheme, the distance between the object and the infrared lamp is estimated according to the infrared luminous intensity of the object, the currents of the small-angle lens and the large-angle lens are adjusted in a self-adaptive mode, when the object is closer and closer, the current of the small-angle lens is gradually reduced, the current of the large-angle lens is increased, and when the object is farther and farther, the current of the small-angle lens is gradually increased, and the current of the small-angle lens is reduced. The whole system can dynamically adjust the current intensity of the small-angle lens and the large-angle lens on the lamp panel in a self-adaptive mode according to algorithm parameters. When an object is in a close range, the phenomenon that the periphery of the center is excessively exposed is avoided; when no object is reflected, the light supplement distance is increased as much as possible.
Optionally, determining an ambient brightness value of the target image captured by the target monitoring device includes: acquiring a shutter value when the target monitoring equipment shoots the target image and an exposure gain value of the target image; determining the ambient brightness value Env according to the following formula:
Figure BDA0002439203360000111
wherein, cur _ shut is the shutter value, cur _ gain is the exposure gain value, and K1 and K2 are preset parameters.
Through the above description of the embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
In this embodiment, a current value adjusting device for a lens lamp panel is further provided, where the current value adjusting device is used to implement the foregoing embodiments and preferred embodiments, and the description of the current value adjusting device is omitted. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware, or a combination of software and hardware is also possible and contemplated.
Fig. 5 is a block diagram of a current value adjusting apparatus of a lens lamp panel according to an embodiment of the present invention, and as shown in fig. 5, the apparatus includes: a first determining module 52, configured to determine an ambient brightness value of a target image captured by a target monitoring device, and a white balance parameter of each statistical block in the target image, where the target image includes N statistical blocks, and N is greater than or equal to 1; a second determining module 54, configured to determine an infrared component ratio of the target image according to a distance between the white balance parameter of each statistical block and a preset white balance parameter, where the preset white balance parameter is an average white balance parameter of a first preset image captured by the target monitoring device in a closed environment; a third determining module 56, configured to determine an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio; and the adjusting module 58 is used for adjusting the current value of the lens lamp panel on the target monitoring equipment according to the infrared light brightness value.
Optionally, the second determining module further includes: a first determining unit, configured to determine, as a target statistical block, a statistical block corresponding to a white balance parameter whose distance from the preset white balance parameter is smaller than or equal to a first preset threshold; a second determining unit, configured to determine that a ratio of the number M of the target statistical blocks to the number N of all statistical blocks in the target image is an infrared component ratio of the target image.
Optionally, the third determining module further includes: a third determination unit configured to determine that a product of the environment brightness value and the infrared component ratio is an infrared light brightness value of the target image, wherein a larger infrared light brightness value indicates a closer distance of an object in the target image to the target monitoring device when the target image is captured, and a smaller infrared light brightness value indicates a farther distance of the object in the target image to the target monitoring device when the target image is captured.
Optionally, the adjusting module is further configured to adjust a current value of a lens lamp panel on the target monitoring device according to the infrared light brightness value in the following manner, and determine that a ratio of the infrared light brightness value of the target image to a preset infrared light brightness value of a second preset image is a light reflection ratio, where the second preset image is an image obtained by shooting a preset object whose distance is less than or equal to a preset distance by the target monitoring device; determining a small-angle lens current value on the lens lamp panel as PWM (1-rate), and determining a large-angle lens current value on the lens lamp panel as PWM rate, wherein the PWM is a maximum current value of the lens lamp panel, and the rate is the reflection ratio.
Optionally, the above apparatus is further configured to, when it is determined that the PWM (1-ratio) is smaller than a second preset threshold and the PWM ratio is greater than a third preset threshold, adjust the small-angle lens current value on the lens lamp panel to the second preset threshold, and adjust the large-angle lens current value on the lens lamp panel to the third preset threshold; and under the condition that the PWM (1-rate) is determined to be greater than a fourth preset threshold value and the PWM rate is determined to be less than a fifth preset threshold value, adjusting the small-angle lens current value on the lens lamp plate to be the fourth preset threshold value, and adjusting the large-angle lens current value on the lens lamp plate to be the fifth preset threshold value.
Optionally, the first determining module is further configured to determine an environment brightness value of the target image captured by the target monitoring device by: acquiring a shutter value when the target monitoring equipment shoots the target image and an exposure gain value of the target image; determining the ambient brightness value Env according to the following formula:
Figure BDA0002439203360000141
wherein, cur _ shut is the shutter value, cur _ gain is the exposure gain value, and K1 and K2 are preset parameters.
It should be noted that, the above modules may be implemented by software or hardware, and for the latter, the following may be implemented, but not limited to: the modules are all positioned in the same processor; alternatively, the modules are respectively located in different processors in any combination.
Embodiments of the present invention also provide a storage medium having a computer program stored therein, wherein the computer program is arranged to perform the steps of any of the above method embodiments when executed.
Alternatively, in the present embodiment, the storage medium may be configured to store a computer program for executing the steps of:
s1, determining an environment brightness value of a target image shot by a target monitoring device and a white balance parameter of each statistical block in the target image, wherein the target image comprises N statistical blocks, and N is greater than or equal to 1;
s2, determining the infrared component ratio of the target image according to the distance between the white balance parameter of each statistical block and a preset white balance parameter, wherein the preset white balance parameter is an average white balance parameter of a first preset image shot by the target monitoring equipment in a closed environment;
s3, determining the infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio;
and S4, adjusting the current value of the lens lamp panel on the target monitoring equipment according to the infrared light brightness value.
Optionally, in this embodiment, the storage medium may include, but is not limited to: various media capable of storing computer programs, such as a usb disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk.
Embodiments of the present invention also provide an electronic device comprising a memory having a computer program stored therein and a processor arranged to run the computer program to perform the steps of any of the above method embodiments.
Optionally, the electronic apparatus may further include a transmission device and an input/output device, wherein the transmission device is connected to the processor, and the input/output device is connected to the processor.
Optionally, in this embodiment, the processor may be configured to execute the following steps by a computer program:
s1, determining an environment brightness value of a target image shot by a target monitoring device and a white balance parameter of each statistical block in the target image, wherein the target image comprises N statistical blocks, and N is greater than or equal to 1;
s2, determining the infrared component ratio of the target image according to the distance between the white balance parameter of each statistical block and a preset white balance parameter, wherein the preset white balance parameter is an average white balance parameter of a first preset image shot by the target monitoring equipment in a closed environment;
s3, determining the infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio;
and S4, adjusting the current value of the lens lamp panel on the target monitoring equipment according to the infrared light brightness value.
Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments and optional implementation manners, and this embodiment is not described herein again.
It will be apparent to those skilled in the art that the modules or steps of the present invention described above may be implemented by a general purpose computing device, they may be centralized on a single computing device or distributed across a network of multiple computing devices, and alternatively, they may be implemented by program code executable by a computing device, such that they may be stored in a storage device and executed by a computing device, and in some cases, the steps shown or described may be performed in an order different than that described herein, or they may be separately fabricated into individual integrated circuit modules, or multiple ones of them may be fabricated into a single integrated circuit module. Thus, the present invention is not limited to any specific combination of hardware and software.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. A current value adjusting method of a lens lamp panel is characterized by comprising the following steps:
determining an environment brightness value of a target image shot by a target monitoring device and a white balance parameter of each statistical block in the target image, wherein the target image comprises N statistical blocks, and N is greater than or equal to 1;
determining the infrared component ratio of the target image according to the distance between the white balance parameter of each statistical block and a preset white balance parameter, wherein the preset white balance parameter is an average white balance parameter of a first preset image shot by the target monitoring device in a closed environment;
determining an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio;
and adjusting the current value of a lens lamp panel on the target monitoring equipment according to the infrared light brightness value.
2. The method according to claim 1, wherein the determining the infrared component ratio of the target image according to the distance between the white balance parameter of each statistical block and a preset white balance parameter comprises:
determining a statistical block corresponding to the white balance parameter with the distance to the preset white balance parameter smaller than or equal to a first preset threshold value as a target statistical block;
and determining the ratio of the number M of the target statistical blocks to the number N of all statistical blocks in the target image as the infrared component ratio of the target image.
3. The method according to claim 1 or 2, wherein said determining an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio comprises:
determining the product of the environment brightness value and the infrared component ratio as an infrared light brightness value of the target image, wherein the larger the infrared light brightness value is, the closer the object in the target image is to the target monitoring device when the target image is shot, and the smaller the infrared light brightness value is, the farther the object in the target image is from the target monitoring device when the target image is shot.
4. The method of claim 1, wherein the adjusting the current value of a lens lamp panel on the target monitoring device according to the infrared light brightness value comprises:
determining that the ratio of the infrared light brightness value of the target image to a preset infrared light brightness value of a second preset image is a light reflection ratio, wherein the second preset image is an image obtained by shooting a preset object with a distance less than or equal to a preset distance by the target monitoring equipment;
determining a small-angle lens current value on the lens lamp panel as PWM (1-rate), and determining a large-angle lens current value on the lens lamp panel as PWM rate, wherein the PWM is a maximum current value of the lens lamp panel, and the rate is the reflection ratio.
5. The method of claim 4, further comprising one of:
under the condition that the PWM (1-rate) is determined to be smaller than a second preset threshold value and the PWM rate is greater than a third preset threshold value, adjusting a small-angle lens current value on the lens lamp plate to be the second preset threshold value and adjusting a large-angle lens current value on the lens lamp plate to be the third preset threshold value;
and under the condition that the PWM (1-rate) is determined to be greater than a fourth preset threshold value and the PWM rate is determined to be less than a fifth preset threshold value, adjusting the small-angle lens current value on the lens lamp plate to be the fourth preset threshold value, and adjusting the large-angle lens current value on the lens lamp plate to be the fifth preset threshold value.
6. The method of claim 1, wherein determining an ambient brightness value of the target image captured by the target monitoring device comprises:
acquiring a shutter value when the target monitoring equipment shoots the target image and an exposure gain value of the target image;
determining the ambient brightness value Env according to the following formula:
Figure FDA0002439203350000031
wherein cur _ shut is the shutter value, cur _ gain is the exposure gain value, and K1 and K2 are preset parameters.
7. The utility model provides a current value adjusting device of lens lamp plate which characterized in that includes:
the device comprises a first determining module, a second determining module and a processing module, wherein the first determining module is used for determining an environment brightness value of a target image shot by a target monitoring device and a white balance parameter of each statistical block in the target image, the target image comprises N statistical blocks, and N is greater than or equal to 1;
a second determining module, configured to determine an infrared component ratio of the target image according to a distance between a white balance parameter of each statistical block and a preset white balance parameter, where the preset white balance parameter is an average white balance parameter of a first preset image captured by the target monitoring device in a closed environment;
a third determining module, configured to determine an infrared light brightness value of the target image according to the environment brightness value and the infrared component ratio;
and the adjusting module is used for adjusting the current value of a lens lamp panel on the target monitoring equipment according to the infrared light brightness value.
8. The apparatus of claim 7, wherein the second determining module further comprises:
a first determining unit, configured to determine, as a target statistical block, a statistical block corresponding to a white balance parameter whose distance from the preset white balance parameter is smaller than or equal to a first preset threshold;
a second determining unit, configured to determine that a ratio of the number M of the target statistical blocks to the number N of all statistical blocks in the target image is an infrared component ratio of the target image.
9. A storage medium, in which a computer program is stored, wherein the computer program is arranged to perform the method of any of claims 1 to 6 when executed.
10. An electronic device comprising a memory and a processor, wherein the memory has stored therein a computer program, and wherein the processor is arranged to execute the computer program to perform the method of any of claims 1 to 6.
CN202010260762.0A 2020-04-03 2020-04-03 Current value adjusting method and device for lens lamp panel Active CN111432136B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010260762.0A CN111432136B (en) 2020-04-03 2020-04-03 Current value adjusting method and device for lens lamp panel

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010260762.0A CN111432136B (en) 2020-04-03 2020-04-03 Current value adjusting method and device for lens lamp panel

Publications (2)

Publication Number Publication Date
CN111432136A true CN111432136A (en) 2020-07-17
CN111432136B CN111432136B (en) 2021-06-18

Family

ID=71557830

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010260762.0A Active CN111432136B (en) 2020-04-03 2020-04-03 Current value adjusting method and device for lens lamp panel

Country Status (1)

Country Link
CN (1) CN111432136B (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102256066A (en) * 2011-01-17 2011-11-23 深圳市保千里电子有限公司 Infrared high speed ball and method for intelligently adjusting brightness of infrared lamp by infrared high speed ball
CN105487321A (en) * 2015-12-28 2016-04-13 生迪智慧科技有限公司 Control method for infrared light-compensating lamp and shooting apparatus
CN106101549A (en) * 2016-07-07 2016-11-09 浙江宇视科技有限公司 Automatic switching method, Apparatus and system round the clock
CN107451561A (en) * 2017-07-31 2017-12-08 广东欧珀移动通信有限公司 Iris recognition light compensation method and device
CN108184076A (en) * 2018-02-01 2018-06-19 天津天地伟业信息系统集成有限公司 A kind of brightness calculation algorithm based on Color Statistical
CN108243311A (en) * 2016-12-27 2018-07-03 杭州萤石网络有限公司 The method of adjustment and picture pick-up device of infrared lamp power
WO2019227912A1 (en) * 2018-05-31 2019-12-05 杭州海康威视数字技术股份有限公司 Image capture device, control method, and machine readable storage medium
CN110876042A (en) * 2018-08-31 2020-03-10 厦门星宸科技有限公司 Circuit for controlling image capture device and related control method

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102256066A (en) * 2011-01-17 2011-11-23 深圳市保千里电子有限公司 Infrared high speed ball and method for intelligently adjusting brightness of infrared lamp by infrared high speed ball
CN105487321A (en) * 2015-12-28 2016-04-13 生迪智慧科技有限公司 Control method for infrared light-compensating lamp and shooting apparatus
CN106101549A (en) * 2016-07-07 2016-11-09 浙江宇视科技有限公司 Automatic switching method, Apparatus and system round the clock
CN108243311A (en) * 2016-12-27 2018-07-03 杭州萤石网络有限公司 The method of adjustment and picture pick-up device of infrared lamp power
CN107451561A (en) * 2017-07-31 2017-12-08 广东欧珀移动通信有限公司 Iris recognition light compensation method and device
CN108184076A (en) * 2018-02-01 2018-06-19 天津天地伟业信息系统集成有限公司 A kind of brightness calculation algorithm based on Color Statistical
WO2019227912A1 (en) * 2018-05-31 2019-12-05 杭州海康威视数字技术股份有限公司 Image capture device, control method, and machine readable storage medium
CN110876042A (en) * 2018-08-31 2020-03-10 厦门星宸科技有限公司 Circuit for controlling image capture device and related control method

Also Published As

Publication number Publication date
CN111432136B (en) 2021-06-18

Similar Documents

Publication Publication Date Title
CN103826066B (en) Automatic exposure adjusting method and system
US10880493B2 (en) Imaging device, method and system of providing fill light, and movable object
CN103190144B (en) Region of interest extracts
WO2021109620A1 (en) Exposure parameter adjustment method and apparatus
CN110225257B (en) Day and night mode switching method and device, camera device and storage medium
US9179062B1 (en) Systems and methods for performing operations on pixel data
EP3657785B1 (en) Image white balance processing method and apparatus, and terminal device
EP3852350B1 (en) Automatic exposure method and apparatus for dual-light image, and dual-light image camera and machine storage medium
CN106664363B (en) Glisten collision detection and compensation system, method, equipment and computer-readable media
US10313601B2 (en) Image capturing device and brightness adjusting method
CN111770285B (en) Exposure brightness control method and device, electronic equipment and storage medium
WO2021007690A1 (en) Exposure control method, apparatus and movable platform
CN109842763A (en) A kind of automatic light-supplementing method, system and video camera
CN111064902A (en) Aperture control method and device and exposure control method
CN112188175A (en) Photographing apparatus and image processing method
CN111432136B (en) Current value adjusting method and device for lens lamp panel
CN111935415B (en) Brightness adjusting method and device, storage medium and electronic device
CN111263078B (en) Method and device for determining image pickup mode, storage medium and electronic device
CN110264402B (en) Image fusion method, image fusion device, storage medium and electronic device
CN111970501A (en) Pure color scene AE color processing method and device, electronic equipment and storage medium
CN111273504A (en) Focusing processing method and device
CN115767260A (en) Anti-overexposure processing method and device, image acquisition equipment and storage medium
CN113905194B (en) Exposure ratio processing method, terminal equipment and computer storage medium
CN106464814B (en) Flash of light collision detection, compensation and prevention
CN109167932A (en) A kind of photography light control system

Legal Events

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