Method, device, lamp, electronic device and medium for adjusting lamp brightness
By obtaining the exposure index and data format conversion of the environmental image, combined with automatic exposure control, the accurate brightness adjustment of the lamp is achieved, solving the problem of inaccurate brightness adjustment in the existing technology, and improving user experience and energy-saving effects.
Patent Information
- Application Number
- CN202210488825.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-06
- Publication Date
- 2024-12-13
- Estimated Expiration
- 2042-05-06
AI Technical Summary
In the prior art, the brightness adjustment of lamps is not accurate enough, resulting in waste of electricity and discomfort.
By obtaining the exposure index of the environment image, determining the brightness parameters based on the preset mapping relationship, adjusting the brightness of the lamp, and using data format conversion (such as BR to YUV format) and automatic exposure control, accurate brightness adjustment and current adjustment are achieved.
Improves the accuracy and speed of brightness adjustment, reduces flicker discomfort, improves user experience, and reduces power loss.
Smart Images

Figure CN114786295B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of lamp brightness control, and in particular to a method, device, lamp, electronic equipment and medium for adjusting lamp brightness. Background Art
[0002] With the continuous development of social economy and the increasingly prominent problem of global energy shortage, people are paying more and more attention to environmental protection and energy saving. In the field of lighting, light emitting diode (LED) lamps are attracting more and more users with their advantages of energy saving, environmental protection, good color rendering and response speed. As a new type of green light source product, LED lamps are widely used in the lighting fields of roads, homes, enterprises, etc.
[0003] In the related art, lamps can be roughly divided into two categories according to whether the brightness can be adjusted: brightness adjustable LED lamps and brightness non-adjustable LED lamps. Among them, non-adjustable brightness lamps often cause power waste because the brightness cannot be adjusted; while the adjustable brightness lamps in the related art need to be dimmed by a power switch or other external devices, and the adjustment accuracy is poor, which still causes power waste to a certain extent.
[0004] It can be seen that the existing technology has the problem of insufficient precision in adjusting the brightness of the lamp. Summary of the invention
[0005] Therefore, the technical problem to be solved by the present invention is to overcome the defect of the prior art that the brightness adjustment of the lamp is not accurate enough, thereby providing a method, device, lamp, electronic device and medium for adjusting the brightness of the lamp.
[0006] A first aspect of the present invention provides a method for adjusting the brightness of a lamp, which may include but is not limited to at least one of the following steps:
[0007] Acquire an environmental image of a target area, the environmental image having a first data format, and at least one lamp is arranged in the target area;
[0008] Performing data format conversion processing on the environment image, and obtaining the current exposure index during the data format conversion processing;
[0009] Determine a current brightness parameter corresponding to the current exposure index according to a preset mapping relationship, where the preset mapping relationship is a mapping relationship between the exposure index and the brightness parameter;
[0010] The brightness of at least one lamp is adjusted based on the current brightness parameter.
[0011] In the above technical solution, the current exposure index is obtained during the process of converting the ambient image data format, and the brightness parameter is determined based on the current exposure index to adjust the brightness of the lamp, so that the time used for adjusting the brightness is greatly reduced, and the brightness adjustment is more linear, thereby achieving precise brightness adjustment, reducing or even avoiding the discomfort caused by flickering caused by low-precision brightness adjustment solutions in traditional technologies, and improving the user experience.
[0012] In combination with the first aspect of the present invention, a first implementation of the first aspect of the present invention provides a method for adjusting lamp brightness, wherein performing data format conversion processing on an environment image includes:
[0013] The environment image is converted from a first data format to a second data format.
[0014] In the above embodiment, by converting a first data format that is easy for a computer to read, for example, an image in a Bayer array (BayerRaw, BR) or red green blue (Red Green Blue, RGB) format, into a second data format that is easy for the human eye to recognize, for example, a YUV data format ("Y" represents brightness (Luminance or Luma), that is, a grayscale value, and "U" and "V" represent chrominance (Chrominance or Chroma), which is used to describe the color and saturation of the image and is used to specify the color of a pixel), based on converting the data format of the environment image from the first data format to the second data format, for example, converting the data format of the environment image from the BR data format to the YUV data format, the present invention can make image browsing more convenient.
[0015] In combination with the first implementation of the first aspect of the present invention, the second implementation of the first aspect of the present invention provides a method for adjusting the brightness of a lamp, wherein obtaining a current exposure index during data format conversion processing includes:
[0016] Before the environment image is updated from the first data format to the second data format, a current exposure index is obtained.
[0017] In the above-mentioned embodiment, the present invention can obtain the current exposure index before the ambient image data format is updated to the second data format, for example, before the ambient image data format becomes the YUV data format, so as to determine the current exposure index and its corresponding brightness parameter as early as possible, thereby achieving the purpose of adjusting the lamp brightness more quickly based on the determined brightness parameter, so as to effectively improve the accuracy of lamp brightness adjustment by speeding up the speed of lamp brightness adjustment.
[0018] In combination with any one of the first aspect, the first implementation of the first aspect, and the second implementation of the first aspect of the present invention, a third implementation of the first aspect of the present invention provides a method for adjusting lamp brightness, wherein obtaining a current exposure index during data format conversion processing includes:
[0019] After the automatic exposure control process is completed, the current exposure index is obtained;
[0020] The data format conversion process includes the automatic exposure control (Automatic Exposure Control, AEC) process.
[0021] In the above technical solution, the AEC process can be used to adjust the image to an image with appropriate brightness to meet the human eye's ability to distinguish picture details and identify targets, and to make the image's color expression meet visual psychological needs and actual engineering indicators.
[0022] In combination with any one of the first aspect, the first implementation of the first aspect, and the second implementation of the first aspect of the present invention, a fourth implementation of the first aspect of the present invention provides a method for adjusting the brightness of a lamp, wherein the brightness of at least one lamp is adjusted based on a current brightness parameter, including:
[0023] Compare the current brightness parameter with the standard brightness parameter to obtain a comparison result;
[0024] adjusting the supply current of the lamp based on the comparison result to adjust the brightness of at least one lamp;
[0025] The standard brightness parameter is a brightness parameter corresponding to the required ambient brightness.
[0026] In the above implementation, the appropriate required ambient brightness can be set according to the specific application scenario or personal preference requirements to make the entire lighting environment more comfortable.
[0027] In combination with the fourth embodiment of the first aspect of the present invention, the fifth embodiment of the first aspect of the present invention provides a method for adjusting the brightness of a lamp, wherein adjusting the power supply current of the lamp based on the comparison result includes:
[0028] If the current brightness parameter is greater than the standard brightness parameter, reducing the power supply current of the lamp by a first percentage;
[0029] If the current brightness parameter is less than the standard brightness parameter, increasing the power supply current of the lamp by a second percentage;
[0030] If the current brightness parameter is equal to the standard brightness parameter, the power supply current of the lamp is kept unchanged.
[0031] In the above-mentioned implementation, the current is adjusted according to the numerical relationship between the brightness parameters corresponding to the actual ambient brightness and the required ambient brightness, thereby adjusting the brightness of the lamp more accurately.
[0032] In combination with the fifth embodiment of the first aspect of the present invention, the sixth embodiment of the first aspect of the present invention provides a method for adjusting lamp brightness, wherein the first percentage and the second percentage are determined by the difference between a current brightness parameter and a standard brightness parameter.
[0033] In the above implementation, the brightness of the lamp is adjusted through a precise calculation process, so that it is more suitable for people's daily life and work needs, the brightness adjustment is more precise, and the power loss can be reduced.
[0034] In combination with any one of the first aspect of the present invention, the first implementation of the first aspect of the present invention, and the second implementation of the first aspect of the present invention, a seventh implementation of the first aspect of the present invention provides a method for adjusting lamp brightness, wherein after adjusting the brightness of at least one lamp based on the current brightness parameter, the method further includes:
[0035] Return to the step of obtaining the environment image of the target area.
[0036] In the above embodiment, multiple steps may be used to adjust the brightness of the lamp. The brightness adjustment process is more linear, which reduces the loss of the lamp and does not cause discomfort to people due to sudden brightness changes.
[0037] In combination with the first aspect of the present invention, the first embodiment of the first aspect of the present invention and any one of the second embodiment of the first aspect of the present invention, the eighth embodiment of the first aspect of the present invention provides a method for adjusting the brightness of a lamp, wherein the lamp includes an LED.
[0038] In the above implementation, the LED lamp is more energy-saving and environmentally friendly. At the same time, the LED lamp also has the advantages of good color rendering and response speed and can be widely used in the lighting fields of roads, homes, enterprises, etc.
[0039] In combination with any one of the first aspect of the present invention, the first implementation of the first aspect of the present invention, and the second implementation of the first aspect of the present invention, a ninth implementation of the first aspect of the present invention provides a method for adjusting lamp brightness, wherein acquiring an environmental image of a target area includes:
[0040] The environment image is acquired when the camera is in a preview state, and the camera is used to collect the environment image.
[0041] In the above implementation, the camera can be turned on timed or periodically, and the camera log information (Logfile, LOG) can be read when the camera is in preview mode to obtain the exposure index from the log information, thereby reducing the use time of the camera and being more energy-efficient.
[0042] A second aspect of the present invention provides a device for adjusting lamp brightness, which may include but is not limited to an image acquisition module, a first data determination module, a second data determination module, and a brightness adjustment module.
[0043] An image acquisition module, used to acquire an environmental image of a target area, the environmental image having a first data format, and at least one lamp is arranged in the target area;
[0044] A first data determination module is used to perform data format conversion processing on the environment image, and obtain a current exposure index during the data format conversion processing;
[0045] A second data determination module, used to determine a current brightness parameter corresponding to a current exposure index according to a preset mapping relationship, where the preset mapping relationship is a mapping relationship between the exposure index and the brightness parameter;
[0046] The brightness adjustment module is used to adjust the brightness of at least one lamp based on the current brightness parameter.
[0047] A third aspect of the present invention provides a lamp, which includes but is not limited to at least one lamp and a control unit, wherein the at least one lamp and the control unit are electrically connected, and the control unit is used to execute the aforementioned lamp brightness adjustment method.
[0048] A fourth aspect of the present invention provides an electronic device, which includes but is not limited to a memory and a processor, wherein the memory stores computer-readable instructions, and when the computer-readable instructions are executed by the processor, the processor executes the aforementioned method for adjusting the brightness of a lamp.
[0049] A fifth aspect of the present invention provides a storage medium storing computer-readable instructions, wherein when the computer-readable instructions are executed by one or more processors, the one or more processors execute the aforementioned method for adjusting the brightness of a lamp.
[0050] It can be understood that the above-mentioned devices, lamps, electronic devices or computer storage media are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods and will not be repeated here.
[0051] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0053] Figure 1 An exemplary flow chart of a method for adjusting lamp brightness according to an embodiment of the present invention;
[0054] Figure 2 An exemplary hardware schematic diagram of a method for implementing lamp brightness adjustment according to an embodiment of the present invention;
[0055] Figure 3 An exemplary software flow chart of a method for implementing lamp brightness adjustment according to an embodiment of the present invention;
[0056] Figure 4 is an exemplary flow chart of the environment image format conversion process according to an embodiment of the present invention;
[0057] Figure 5 This is a schematic diagram of an exemplary structure of a device for adjusting lamp brightness according to an embodiment of the present invention;
[0058] Figure 6 The figure is a schematic diagram of an exemplary structure of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0059] The technical solution of the present invention will be described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0060] In the description of the present invention, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, it can also be the internal connection of two components, it can be a wireless connection, or it can be a wired connection. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0061] In addition, the technical features involved in the different embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other.
[0062] like Figure 1 As shown in , one or more embodiments of the present invention provide a method for adjusting lamp brightness, which includes but is not limited to the following steps.
[0063] Step S110: Acquire an environment image of a target area, wherein the environment image has a first data format, and at least one lamp is arranged in the target area.
[0064] Specifically, combined Figure 2 As shown in , the power supply provides power to a digital signal processor (DSP), the DSP is electrically connected to the camera, and can obtain an environmental image of a target area from the camera, wherein the target area has at least one lamp (eg, an LED lamp).
[0065] In one or more embodiments of the present invention, acquiring the environment image of the target area may include, but is not limited to, acquiring the environment image when the camera is in a preview state, and the camera is used to collect the environment image.
[0066] Specifically, combined Figure 3 The camera can be opened regularly or periodically, and the camera log information (Logfile, LOG) can be read when the camera is in the preview state to obtain the environment image from the log information, which reduces the use time of the camera and is more energy-efficient.
[0067] In a specific example of the present invention, the camera sends the captured image to the DSP, and the image at this time has a first data format, and the first data format can be a BR data format or an RGB data format. The BR data format refers to a common method used to capture digital images when a charge coupled device (CCD) or a complementary metal oxide semiconductor (CMOS) device is used as a light sensor. The RGB data format is a color standard in the industry. Various colors are obtained by changing the three color channels of red (R), green (G), and blue (B) and superimposing them on each other. RGB represents the colors of the three channels of red, green, and blue. This standard covers almost all colors that can be perceived by human vision and is one of the most widely used color systems.
[0068] Step S120: performing data format conversion processing on the environment image, and obtaining the current exposure index during the data format conversion processing.
[0069] Specifically, combined Figure 2 and Figure 3 , the DSP can be used to convert the data format of the environmental image and obtain the current exposure index of the image through the specified application (Application, APP).
[0070] In one or more embodiments of the present invention, performing data format conversion processing on the environment image may include: converting the environment image from a first data format to a second data format.
[0071] For example, combined with Figure 4 , DSP can perform image signal processing (Image Signal Processor, ISP) on the received image in the first data format (BR data format). The process of ISP processing the image may include converting the image in the BR data format into the image in the RGB data format through AEC, black level correction, bad pixel removal, Bayer noise removal, lens screening, bilinear interpolation algorithm and other processing processes, and then obtaining the image in the second data format (for example, YUV data format) through automatic white balance, color correction, tone mapping, chroma enhancement, skin color enhancement, hardware wavelet noise elimination, adaptive spatial filter and other processing processes.
[0072] In the above embodiment, by converting the image in the BR data format which is easy for the computer to read into the YUV data format which is easy for the human eye to recognize, the image browsing can be made more convenient.
[0073] In one or more embodiments of the present invention, obtaining the current exposure index during the data format conversion process may include: obtaining the current exposure index before the environment image is updated from the first data format to the second data format.
[0074] In one or more embodiments of the present invention, obtaining the current exposure index during the data format conversion process includes:
[0075] After the automatic exposure control process is completed, the current exposure index is obtained;
[0076] The data format conversion process includes an automatic exposure control process.
[0077] Specifically, combined Figure 4 , the current exposure index can be obtained by using the DSP during the ISP processing, before the image in BR data format is converted into the image in YUV data format, through the AEC processing process. Among them, the APP reads the LOG information of the AEC through the DSP set in the central processing unit (CPU) to read the current exposure index from the LOG information.
[0078] At least one embodiment of the present invention can obtain the current exposure index before the environment image data format is updated to the second data format, for example, before the environment image data format becomes the YUV data format, so as to determine the current exposure index and its corresponding brightness parameter as early as possible, thereby achieving the purpose of adjusting the light brightness faster based on the determined brightness parameter, so as to effectively improve the accuracy of light brightness adjustment by speeding up the speed of light brightness adjustment. In addition, the AEC process can be used to adjust the image to an image with appropriate brightness, so as to meet the human eye's ability to distinguish picture details and identify targets, and to enable the color performance of the image to meet the visual psychological needs and actual engineering indicators.
[0079] Step S130: determining a current brightness parameter corresponding to the current exposure index according to a preset mapping relationship, where the preset mapping relationship is a mapping relationship between the exposure index and the brightness parameter.
[0080] Specifically, combined Figure 3 , the current brightness parameter (e.g., actual brightness value) corresponding to the current exposure index can be determined by querying a mapping table that records the mapping relationship between the exposure index and the brightness parameter (i.e., the preset mapping relationship), wherein the preset mapping relationship is obtained by the light box brightness test. By adjusting the light box brightness level, the exposure index also changes accordingly. For example, the brightness parameter 1500 corresponds to the exposure index a, the brightness parameter 780 corresponds to the exposure index b, and so on; by using a brightness meter, the brightness parameter is read, and the exposure index and the corresponding brightness parameter are recorded to obtain the following:
[0081] The mapping table is shown in Table 1.
[0082]
[0083]
[0084] Table 1
[0085] Step S140: adjusting the brightness of at least one lamp based on the current brightness parameter.
[0086] Specifically, in one or more embodiments of the present invention, adjusting the brightness of at least one lamp based on the current brightness parameter may include:
[0087] Compare the current brightness parameter with the standard brightness parameter to obtain a comparison result;
[0088] adjusting the supply current of the lamp based on the comparison result to adjust the brightness of at least one lamp;
[0089] The standard brightness parameter is a brightness parameter corresponding to the required ambient brightness.
[0090] In the above implementation, the appropriate required ambient brightness can be set according to the specific application scenario or personal preference requirements to make the entire lighting environment more comfortable.
[0091] Specifically, in one or more embodiments of the present invention, adjusting the power supply current of the lamp based on the comparison result may include:
[0092] If the current brightness parameter is greater than the standard brightness parameter, reducing the power supply current of the lamp by a first percentage;
[0093] If the current brightness parameter is less than the standard brightness parameter, increasing the power supply current of the lamp by a second percentage;
[0094] If the current brightness parameter is equal to the standard brightness parameter, the power supply current of the lamp is kept unchanged.
[0095] In the above embodiment, the current is adjusted according to the numerical relationship between the brightness parameters corresponding to the actual ambient brightness and the required ambient brightness, thereby adjusting the brightness of the lamp more accurately.
[0096] In one or more embodiments of the present invention, after adjusting the brightness of at least one lamp based on the current brightness parameter, the method further includes:
[0097] Return to the step of obtaining the environment image of the target area.
[0098] In the above embodiment, multiple steps may be used to adjust the lamp brightness. The brightness adjustment process is more linear, which reduces the loss of the lamp and does not cause discomfort to people due to sudden brightness changes.
[0099] Specifically, combined Figure 3 The actual brightness value can be compared with the preset standard brightness value (ie, standard brightness parameter). If the actual brightness value is less than the preset standard brightness value, the power supply current of the lamp is increased; if the actual brightness value is greater than the preset standard brightness value, the power supply current of the lamp is reduced.
[0100] In a specific example of the present invention, Figure 2 , the power supply current of the lamp can be adjusted based on the comparison between the actual brightness value X and the preset standard brightness value Y:
[0101] If X is greater than Y, the DSP reduces the current to the lamp by 10% through the pulse width modulation (PWM). After the brightness of the lamp stabilizes, the exposure index continues to feedback the current brightness value X until X=Y.
[0102] If X is less than Y, DSP increases the current to the lamp by 10% through PWM. After the lamp brightness stabilizes, the exposure index continues to feedback the current brightness value X until X=Y.
[0103] In one or more embodiments of the present invention, the first percentage and the second percentage may be determined by a difference between a current brightness parameter and a standard brightness parameter.
[0104] In the above implementation, the brightness of the lamp is adjusted through a precise calculation process, so that it is more suitable for people's daily life and work needs, the brightness adjustment is more precise, and the power loss can be reduced.
[0105] In the above embodiments, the DSP, PWM and camera can be connected via a two-wire serial bus (Inter-Integrated Circuit, I2C), which is a simple, bidirectional, two-wire synchronous serial bus that only needs two wires to transmit information between devices connected to the bus.
[0106] In the aforementioned embodiment, the universal AEC algorithm of the camera is used to make a brightness mapping relationship, so that the DSP adds the function of reading the current brightness, which can accurately and dynamically adjust the brightness of the light, and technology helps to save energy and reduce emissions.
[0107] Compared with the related art of reading the digital camera's photosensitivity quantification regulations (International Standards Organization, ISO) information from the captured YUV picture and then inferring the brightness mapping relationship, the present invention can read the exposure index in real time in the first module AEC in the ISP processing flow. Compared with other patents, the brightness information is fed back faster, so the brightness can be adjusted faster and more linearly, reducing the discomfort caused by flicker.
[0108] like Figure 5 As shown in , one or more embodiments of the present invention further provide a device for adjusting lamp brightness. The device provided by the embodiment of the present invention includes but is not limited to an image acquisition module, a first data determination module, a second data determination module and a brightness adjustment module, which are described in detail as follows.
[0109] The image acquisition module 110 is used to acquire an environmental image of a target area, where the environmental image has a first data format, and at least one lamp is arranged in the target area.
[0110] In one or more embodiments of the present invention, the light may include an LED.
[0111] In one or more embodiments of the present invention, the image acquisition module 110 can acquire the environment image when the camera is in a preview state, and the camera is used to collect the environment image.
[0112] The first data determination module 120 is used to perform data format conversion processing on the environment image and obtain the current exposure index during the data format conversion processing.
[0113] In one or more embodiments of the present invention, the first data determination module 120 may include:
[0114] A format conversion submodule, used to convert the environment image from a first data format to a second data format;
[0115] The data acquisition submodule is used to acquire the current exposure index before the environment image is updated from the first data format to the second data format.
[0116] In one or more embodiments of the present invention, the data acquisition submodule may acquire the current exposure index after the automatic exposure control process is completed; wherein the data format conversion process includes the automatic exposure control process.
[0117] The second data determination module 130 is used to determine a current brightness parameter corresponding to a current exposure index according to a preset mapping relationship, where the preset mapping relationship is a mapping relationship between the exposure index and the brightness parameter.
[0118] The brightness adjustment module 140 is used to adjust the brightness of at least one lamp based on the current brightness parameter.
[0119] In one or more embodiments of the present invention, the brightness adjustment module 140 may include:
[0120] A comparison submodule, used for comparing the current brightness parameter with the standard brightness parameter to obtain a comparison result;
[0121] a current regulating submodule, configured to regulate the power supply current of the lamp based on the comparison result, so as to regulate the brightness of at least one lamp;
[0122] The standard brightness parameter is a brightness parameter corresponding to the required ambient brightness.
[0123] In one or more embodiments of the present invention, the current regulation submodule can reduce the power supply current of the lamp by a first percentage when the current brightness parameter is greater than the standard brightness parameter; increase the power supply current of the lamp by a second percentage when the current brightness parameter is less than the standard brightness parameter; and keep the power supply current of the lamp unchanged when the current brightness parameter is equal to the standard brightness parameter.
[0124] In one or more embodiments of the present invention, the current regulation submodule may determine the first percentage and the second percentage according to a difference between a current brightness parameter and a standard brightness parameter.
[0125] In one or more embodiments of the present invention, the current regulating submodule may feed back the result to the image acquisition module after adjusting the brightness of at least one lamp based on the current brightness parameter.
[0126] One or more embodiments of the present invention further provide a lamp, comprising at least one lamp and a control unit, wherein the at least one lamp is electrically connected to the control unit, and the control unit is used to execute the lamp brightness adjustment method in the aforementioned embodiments.
[0127] In addition, if Figure 6 As shown in , one or more embodiments of the present invention further provide an electronic device 300, including a processor 301 and a memory 302, the processor 301 and the memory 302 are communicatively connected to each other via a communication bus 303, the memory 302 stores computer instructions, and the processor 301 executes the aforementioned obstacle information determination method or the aforementioned vehicle obstacle avoidance method by executing the computer instructions.
[0128] Finally, one or more embodiments of the present invention further provide a computer-readable storage medium. The computer-readable storage medium stores computer instructions, which are used to cause the computer to execute the aforementioned obstacle information determination method or the aforementioned vehicle obstacle avoidance method. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk. The detailed implementation process of the video processing method has been described in detail in this specification and will not be repeated here.
[0129] The logic and / or steps represented in the flowchart or otherwise described herein, for example, may be considered as an ordered list of executable instructions for implementing logical functions, and may be embodied in any computer-readable storage medium for use by an instruction execution system, apparatus, or device (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, apparatus, or device and execute instructions), or in conjunction with such instruction execution system, apparatus, or device. For purposes of this specification, a "computer-readable storage medium" may be any device that can contain, store, communicate, propagate, or transmit a program for use by an instruction execution system, apparatus, or device, or in conjunction with such instruction execution system, apparatus, or device. More specific examples of computer-readable storage media (a non-exhaustive list) include the following: an electrical connection with one or more wirings (electronic devices), a portable computer disk case (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM, or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). In addition, the computer-readable storage medium may even be a paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, deciphering, or processing in another suitable manner as necessary, and then stored in a computer memory.
[0130] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0131] It can be understood that the above-mentioned devices, computer equipment or computer storage media are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods and will not be repeated here.
[0132] In the description of this specification, the description with reference to the terms "this embodiment", "one embodiment", "some embodiments", "example", "specific example", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.
[0133] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of the present invention, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0134] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and simple improvements made to the essential contents of the present invention should be included in the protection scope of the present invention.
[0135] Obviously, the above embodiments are merely examples for the purpose of clear explanation, and are not intended to limit the implementation methods. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the implementation methods here. The obvious changes or modifications derived therefrom are still within the scope of protection of the invention.
Claims
1. A method for adjusting lamp brightness, characterized in that: include: When the camera is in a preview state, an environmental image of a target area is acquired, the environmental image has a first data format, at least one light is arranged in the target area, the camera turned on periodically or periodically is used to collect the environmental image, and the first data format is a BR data format; Performing data format conversion processing on the environment image to convert the image in BR data format into an image in YUV data format, converting the image in BR data format into an image in RGB data format through the processing of automatic exposure control, black level correction, bad pixel removal, Bayer noise removal, lens screening, and bilinear interpolation algorithm, obtaining the image in YUV data format through the processing of automatic white balance, color correction, tone mapping, chroma enhancement, hardware wavelet noise elimination, and adaptive spatial filter, and reading camera log information during the process of automatic exposure control in the process of data format conversion processing to obtain a current exposure index from the camera log information; Determine a current brightness parameter corresponding to the current exposure index according to a preset mapping relationship, wherein the preset mapping relationship is a mapping relationship between the exposure index and the brightness parameter; The brightness of the at least one lamp is adjusted based on the current brightness parameter.
2. The method for adjusting lamp brightness according to claim 1, characterized in that: The adjusting the brightness of the at least one lamp based on the current brightness parameter comprises: Comparing the current brightness parameter with a standard brightness parameter to obtain a comparison result; adjusting the power supply current of the lamp based on the comparison result to adjust the brightness of the at least one lamp; The standard brightness parameter is a brightness parameter corresponding to the required ambient brightness.
3. The method for adjusting lamp brightness according to claim 2, characterized in that: The step of adjusting the power supply current of the lamp based on the comparison result comprises: If the current brightness parameter is greater than the standard brightness parameter, reducing the power supply current of the lamp by a first percentage; If the current brightness parameter is less than the standard brightness parameter, increasing the power supply current of the lamp by a second percentage; If the current brightness parameter is equal to the standard brightness parameter, the power supply current of the lamp is kept unchanged.
4. The method for adjusting lamp brightness according to claim 3, characterized in that: The first percentage and the second percentage are determined by a difference between the current brightness parameter and the standard brightness parameter.
5. The method for adjusting lamp brightness according to claim 1, characterized in that: After adjusting the brightness of the at least one lamp based on the current brightness parameter, the method further includes: Return to the step of acquiring the environment image of the target area.
6. The method for adjusting lamp brightness according to claim 1, characterized in that: The lamp comprises a light emitting diode lamp.
7. A device for adjusting lamp brightness, characterized in that: include: An image acquisition module, used for acquiring an environmental image of a target area when the camera is in a preview state, the environmental image having a first data format, at least one lamp being arranged in the target area, the camera being turned on periodically or periodically being used for acquiring the environmental image, the first data format being a BR data format; a first data determination module, used for performing data format conversion processing on the environment image to convert the image in BR data format into an image in YUV data format; the first data determination module is used for converting the image in BR data format into an image in RGB data format through the processing of automatic exposure control, black level correction, bad pixel removal, Bayer noise removal, lens screening, and bilinear interpolation algorithm; the first data determination module is used for obtaining the image in YUV data format through the processing of automatic white balance, color correction, tone mapping, chroma enhancement, hardware wavelet noise elimination, and adaptive spatial filter; the first data determination module is used for reading camera log information during the process of automatic exposure control in the process of data format conversion processing to obtain a current exposure index from the camera log information; A second data determination module, configured to determine a current brightness parameter corresponding to the current exposure index according to a preset mapping relationship, wherein the preset mapping relationship is a mapping relationship between the exposure index and the brightness parameter; A brightness adjustment module is used to adjust the brightness of the at least one lamp based on the current brightness parameter.
8. A lamp, characterized in that: The method comprises at least one lamp and a control unit, wherein the at least one lamp and the control unit are electrically connected, and the control unit is used to execute the method for adjusting the brightness of a lamp according to any one of claims 1 to 6.
9. An electronic device, characterized in that: The method comprises a memory and a processor, wherein the memory stores computer-readable instructions, and when the computer-readable instructions are executed by the processor, the processor executes the method for adjusting the brightness of a lamp as claimed in any one of claims 1 to 6.
10. A storage medium storing computer-readable instructions, characterized in that: When the computer-readable instructions are executed by one or more processors, the one or more processors are caused to perform the method for adjusting the brightness of a lamp according to any one of claims 1 to 6.
