A method, system, device and storage medium for improving the consistency of the brightness of a structured light module image
By using gray card testing and iterative current adjustment, the problem of inconsistent image brightness in structured light modules was solved, achieving brightness and performance consistency among modules.
Patent Information
- Application Number
- CN202411964364.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-30
- Publication Date
- 2025-11-04
- Estimated Expiration
- 2044-12-30
AI Technical Summary
Inconsistent image brightness is caused by the specification errors of various components in the structured light module, affecting product consistency.
The brightness of the image center point is tested using a gray card, and the current is adjusted iteratively to ensure consistent image brightness across different modules.
Quickly adjust the current parameters of the structured light module to ensure consistent image brightness across different modules, thereby improving product performance consistency.
Smart Images

Figure CN120047365B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of structured light camera calibration, in particular to a method, system and device for improving the consistency of structured light module image brightness and a storage medium. BACKGROUND
[0002] During the production of infrared camera modules with self-complementary light, due to the specification internal error of various devices, the image brightness will be inconsistent even if the same parameters are used between modules.
[0003] When producing infrared camera modules with self-complementary light, each component, including image sensors, infrared lamp LEDs, drive ICs, etc., will have certain specification internal error. These errors may be caused by production process, material selection, measurement accuracy, etc.
[0004] Firstly, as the core component of the module, the performance parameters of the image sensor such as sensitivity, dark current, noise, etc. will have a certain fluctuation range. These fluctuations may cause the sensor to respond differently to light under different lighting conditions, thereby affecting the overall brightness of the image.
[0005] Secondly, the luminous intensity and spectral characteristics of the infrared lamp LED will also have certain errors. Although LEDs are strictly selected and tested before leaving the factory, in actual application, due to factors such as working environment, temperature, aging, etc., the light-emitting performance of the LED may change. This change will directly affect the intensity and effect of the module's complementary light, and further affect the brightness of the image.
[0006] In addition, the fluctuation of the performance parameters of the drive IC as an important component to control the work of the module may also affect the image brightness. For example, the current control ability and output voltage stability of the drive IC will affect the light-emitting state of the LED, thereby affecting the brightness of the image.
[0007] When the errors of these devices are superimposed in the module, it will cause a large difference in image brightness between modules even if the same parameters are used. This difference may manifest as the overall image being too dark or too bright, or there may be obvious brightness unevenness in certain areas.
[0008] The disclosure of the above background art content is only used to assist in understanding the inventive concept and technical solutions of the present application, and it does not necessarily belong to the prior art of the present patent application. In the absence of explicit evidence that the above content has been disclosed before the filing date of the present patent application, the above background art should not be used to evaluate the novelty and inventiveness of the present application. SUMMARY
[0009] Therefore, the application quickly makes the image brightness of different structured light modules consistent by testing the brightness of the center point of the gray card image and iteratively adjusting the current according to the differences of different structured light modules, which is beneficial to the consistency of the performance of the same model product.
[0010] In a first aspect, the application provides a method for improving the consistency of structured light module image brightness, characterized in that it comprises:
[0011] Step S1: setting a gray card at a first distance in front of a structured light module, and making the structured light module capture a first image of the gray card at a current X;
[0012] Step S2: calculating the brightness Y1 of a first center frame on the first image to obtain a brightness coefficient β=Y1 / Y and a current amplification coefficient α=1 / β; wherein Y is the brightness of a first center frame on an image captured by a standard module at a first distance;
[0013] Step S3: loading the current amplification coefficient into the structured light module, setting the gray card at a second distance in front of the structured light module, and making the structured light module capture a second image of the gray card at a current X*α;
[0014] Step S4: calculating the brightness Y2 of a second center frame on the second image to obtain a brightness coefficient β'=Y2 / Y'; wherein Y' is the brightness of a second center frame on an image captured by a standard module at a second distance; the first center frame and the second center frame have the same number of light spots;
[0015] Step S5: if β' is within a preset range, saving the current amplification coefficient α'=1 / β' to the structured light module; otherwise, executing step S3.
[0016] Optionally, the method for improving the consistency of structured light module image brightness, characterized in that the first center frame is a rectangular frame with the center of the first image as the center; and the second center frame is a rectangular frame with the center of the second image as the center.
[0017] Optionally, the method for improving the consistency of structured light module image brightness, characterized in that the size of the rectangular frame is not less than 1 / 10 of the length of the shortest side of the image.
[0018] Optionally, the method for improving the consistency of structured light module image brightness, characterized in that the structured light module comprises a structured light projector and a receiver.
[0019] The structured light projector is configured to project infrared structured light.
[0020] The receiver is configured to receive the reflection signal of the infrared structured light and expose.
[0021] Optionally, the method for improving the consistency of image brightness of a structured light module, characterized in that further comprising: a floodlight for supplementing light for the structured light projector.
[0022] Optionally, the method for improving the consistency of image brightness of a structured light module, characterized in that when the structured light module can project both structured light and floodlight, the gray card is first set at the first distance to project structured light and floodlight respectively, then the gray card is set at the second distance to project structured light and floodlight respectively, and the current amplification coefficient of structured light and the current amplification coefficient of floodlight are designed respectively to make the structured light and the floodlight obtain consistent image brightness.
[0023] Optionally, the method for improving the consistency of image brightness of a structured light module, characterized in that when calculating the first center frame brightness Y1, comprising:
[0024] Step S21: extracting the pixels of the first center frame on the first image and performing binarization;
[0025] Step S22: obtaining the light spot area through threshold comparison;
[0026] Step S23: calculating the brightness mean value of the light spot area on the first image as the first center frame brightness Y1.
[0027] In a second aspect, the present application provides a system for improving the consistency of image brightness of a structured light module, which is used to implement the method for improving the consistency of image brightness of a structured light module as described in any of the above aspects, and characterized in that comprising:
[0028] A first setting module is used to set a gray card at a first distance in front of a structured light module, and make the structured light module collect a first image of the gray card with a current X;
[0029] A first calculating module is used to calculate the first center frame brightness Y1 on the first image, obtain the brightness coefficient β=Y1 / Y, and the current amplification coefficient α=1 / β; wherein Y is the first center frame brightness of the image taken at the first distance by a standard module;
[0030] A second setting module is used to load the current amplification coefficient into the structured light module, set the gray card at a second distance in front of the structured light module, and make the structured light module collect a second image of the gray card with a current X*α;
[0031] A second calculation module is configured to calculate a second center frame luminance Y2 on the second image to obtain a luminance coefficient β' = Y2 / Y', wherein Y' is a second center frame luminance on an image captured at a second distance by a standard module; and the first center frame and the second center frame have the same number of light spots.
[0032] A judging module is configured to save a current amplification coefficient α' = 1 / β' to the structured light module if β' is within a preset range; otherwise, the second setting module is executed.
[0033] In a third aspect, the present application provides a device for improving the image luminance consistency of a structured light module, which comprises:
[0034] A processor;
[0035] A memory having executable instructions of the processor stored therein;
[0036] The processor is configured to execute the steps of the method for improving the image luminance consistency of the structured light module according to any one of the above aspects by executing the executable instructions.
[0037] In a fourth aspect, the present application provides a computer readable storage medium for storing a program, which is configured to implement the steps of the method for improving the image luminance consistency of the structured light module according to any one of the above aspects.
[0038] Compared with the prior art, the present application has the following advantages:
[0039] The present application calibrates the structured light module by using a gray card at different positions and adjusts the luminance of the structured light module according to the luminance of the center point, changes the distance of the gray card, and iteratively updates the current amplification coefficient, so that different modules can converge to the same image luminance level, and the product consistency of the same type of structured light module is ensured. BRIEF DESCRIPTION OF DRAWINGS
[0040] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, the drawings in the following description are only embodiments of the present application, and for those skilled in the art, other drawings can be obtained without creative labor based on the provided drawings. Other features, objects and advantages of the present application will become more apparent through reading the following detailed description of the non-limiting embodiments with reference to the following drawings:
[0041] Figure 1 A step flow chart of a method for improving the image luminance consistency of a structured light module in an embodiment of the present application;
[0042] Figure 2 FIG. 1 is a structural schematic diagram of a structured light module according to an embodiment of the present application;
[0043] Figure 3 FIG. 2 is a flowchart of a step of calculating the first center frame brightness Y1 according to an embodiment of the present application;
[0044] Figure 4 FIG. 3 is a structural schematic diagram of a system for improving the image brightness consistency of a structured light module according to an embodiment of the present application;
[0045] Figure 5 FIG. 4 is a structural schematic diagram of an apparatus for improving the image brightness consistency of a structured light module according to an embodiment of the present application; and
[0046] Figure 6 FIG. 5 is a structural schematic diagram of a computer readable storage medium according to an embodiment of the present application. DETAILED DESCRIPTION
[0047] The present application will be described in detail below with specific embodiments. The following embodiments will help those skilled in the art to further understand the present application, but do not limit the present application in any form. It should be noted that for those skilled in the art, without departing from the concept of the present application, a number of modifications and improvements can be made. These are within the scope of the present application.
[0048] The terms "first", "second", "third", "fourth" and the like in the description, claims, and drawings of the present application, and the above-mentioned drawings, if any, are used to distinguish similar objects, and do not necessarily have to describe a particular order or sequence. It should be understood that the data thus used can be interchanged under appropriate circumstances, so that the embodiments of the present application described herein, for example, can be implemented in an order other than those illustrated or described herein. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device including a series of steps or units does not have to be limited to those steps or units clearly listed, but can include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0049] The method for improving the image brightness consistency of a structured light module according to an embodiment of the present application is intended to solve the problems in the prior art.
[0050] The technical solutions of the present application and how the technical solutions of the present application solve the above technical problems will be described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of the present application will be described below with reference to the drawings.
[0051] The present application can keep the image brightness of different structured light modules consistent by testing the brightness of the center point of the image of the gray card and iteratively adjusting the current, which is beneficial to the consistency of the performance of the same type of product.
[0052] Since the image brightness and the infrared current value are in a linear relationship under the same exposure gain of each structured light module, the present application can quickly and accurately adjust the current while keeping the parameters of the receiving end unchanged.
[0053] Figure 1 The present application is a flow chart of the steps of a method for improving the consistency of the image brightness of a structured light module. Figure 1 As shown in the figure, the method for improving the consistency of the image brightness of a structured light module includes:
[0054] Step S1: Place a gray card at a first distance in front of the structured light module, and make the structured light module collect a first image of the gray card at a current X.
[0055] In this step, the gray card is a card with a specific reflectivity, which is used to calibrate and measure the brightness of the image. In this step, the gray card is used as a standard brightness reference. The structured light module is a device that generates a depth map by projecting a specific pattern and capturing the reflected light. The current X is the current value that drives the structured light module to work, which will affect the intensity and brightness of the light emitted by the module. Place the gray card at a first distance in front of the structured light module (the distance is pre-set to ensure the accuracy of the measurement), then adjust the current of the structured light module to X value, and collect the first image of the gray card.
[0056] Step S2: Calculate the brightness Y1 of the first center frame on the first image, get the brightness coefficient β = Y1 / Y, and the current amplification coefficient α = 1 / β.
[0057] In this step, Y is the first center box brightness on the image taken by the standard module at the first distance. On the first image, a center region is selected as the first center box, which should contain the gray card center region for accurate brightness measurement. The average brightness value Y1 within the first center box is measured and compared with the brightness value Y of the first center box on the image taken by the standard module at the first distance, and the brightness coefficient β = Y1 / Y is calculated. This coefficient reflects the brightness difference between the current structured light module and the standard module under the same conditions. According to the brightness coefficient β, the current amplification coefficient α = 1 / β is calculated. This coefficient will be used to adjust the current of the structured light module to make the brightness of the light emitted closer to the standard module. Due to the angle problem, the reflectivity of the center region of the image is the most accurate, and the reflectivity of other points is not as high. Therefore, using the center region of the image as a standard has better accuracy than using the entire image for adjustment.
[0058] Step S3: Load the current amplification coefficient into the structured light module, set the gray card at a second distance in front of the structured light module, and make the structured light module collect a second image of the gray card at the current X*α.
[0059] In this step, the calculated current amplification coefficient α is loaded into the structured light module to adjust its working current. The gray card is moved to a second distance in front of the structured light module (the distance is different from the first distance to test the brightness consistency of the module at different distances). The structured light module is driven at the adjusted current X*α, and a second image of the gray card is collected.
[0060] Step S4: Calculate the brightness Y2 of the second center box on the second image to obtain the brightness coefficient β' = Y2 / Y'.
[0061] In this step, Y' is the brightness of the second center box on the image taken by the standard module at the second distance; the first center box and the second center box have the same number of light spots. On the second image, a center region with the same number of light spots as the first center box is selected as the second center box. The average brightness value Y2 within the second center box is measured and compared with the brightness value Y' of the second center box on the image taken by the standard module at the second distance, and the brightness coefficient β' = Y2 / Y' is calculated. This coefficient reflects the brightness difference between the structured light module and the standard module at the current distance.
[0062] Step S5: If β' is within a preset range, save the current amplification coefficient α' = 1 / β' to the structured light module; otherwise, perform step S3.
[0063] In this step, the preset range is the acceptable range of the luminance coefficient β' set according to the actual application requirements. If β' is within the preset range, it means that the luminance of the adjusted structured light module at the second distance is similar to that of the standard module. At this time, the new current amplification coefficient α' = 1 / β' is saved to the structured light module for subsequent use. If β' is not within the preset range, it means that the adjusted luminance still does not meet the requirements. At this time, it needs to return to step S3 to adjust the current amplification coefficient again and test again until β' meets the requirements.
[0064] In some embodiments, the first center frame is a rectangular frame centered on the center of the first image; the second center frame is a rectangular frame centered on the center of the second image. The first center frame is a rectangular frame centered on the center of the first image, which is used to select a specific area from the first image for measuring the average brightness value in that area. The size of the rectangular frame can be adjusted as needed, but it should be large enough to include enough pixels for accurate brightness measurement, and small enough to avoid including too much edge or background area, which can introduce unnecessary brightness variations. Similar to the first center frame, the second center frame is also a rectangular frame centered on the center of the second image. The second center frame is set the same as the first center frame, and is also used to select a specific area from the second image for brightness measurement. Since it is the center area of the image taken at a different distance, it can be used to compare the brightness consistency of the structured light module at different distances. Since the structured light beam is laser, its emission has high consistency and small divergence angle, so the size of the first center frame and the second center frame is basically the same, but due to the different spot sizes in the first image and the second image, there is a certain difference between the size of the first center frame and the second center frame. The difference between the size of the first center frame and the second center frame is related to the ratio of the first distance to the second distance. This embodiment can more accurately measure and compare the brightness of images taken by the structured light module under different conditions, so as to adjust its working parameters to improve the brightness consistency. This method is particularly suitable for application scenarios that require high precision and high brightness consistency, such as 3D scanning, object recognition, etc.
[0065] In some embodiments, the shortest side of the rectangular frame is not less than 1 / 10 of the image side length. The shortest side of the rectangular frame, whether it is the width or the height, should not be less than 1 / 10 of the corresponding side length of the entire image. The size requirement of this embodiment is to avoid the rectangular frame being too small, resulting in insufficient number of pixels contained, so that the brightness of the image cannot be accurately reflected. Smaller areas may be more susceptible to factors such as noise, image distortion, or uneven lighting, leading to inaccurate brightness measurement. In practical applications, this size requirement can be adjusted according to specific circumstances. For example, if the resolution of the image is very high, even if the size of the rectangular frame is relatively small, it may contain enough pixels for accurate brightness measurement. However, in most cases, following this size requirement can help us choose a center area that is neither too large nor too small, thereby ensuring the accuracy and reliability of the brightness measurement.
[0066] Figure 2 A structural diagram of a structured light module in an embodiment of the present application is shown. As shown in the figure, a structured light module in an embodiment of the present application includes a structured light projector and a receiver. Figure 2
[0067] The structured light projector is configured to project infrared structured light.
[0068] Specifically, the structured light projector is a key component in the structured light module, which is responsible for projecting infrared structured light to the measured object. Infrared structured light is usually a light with a specific pattern or pattern, such as grating stripes, dot matrix, etc. These light rays, after being reflected by the surface of the object, will form a specific deformation or displacement, thereby carrying the three-dimensional shape information of the object.
[0069] The receiver is configured to receive the reflection signal of the infrared structured light and expose.
[0070] Specifically, the receiver is another important part of the structured light module, which is responsible for receiving the infrared structured light signal projected by the structured light projector and reflected by the surface of the object. The receiver usually uses high-sensitivity photoelectric sensors or cameras, which can capture the intensity and distribution information of the reflected light. When the receiver receives the reflection signal, it will perform exposure operation, i.e. using photoelectric effect to convert the light signal into electrical signal. These electrical signals are then processed and analyzed to extract the three-dimensional shape information of the object.
[0071] The working principle of the structured light module can be summarized as follows:
[0072] The structured light projector projects infrared structured light to the measured object.
[0073] After the infrared structured light is reflected by the surface of the object, it forms a specific deformation or displacement.
[0074] The receiver captures the reflected infrared structured light signal and performs an exposure operation.
[0075] The receiver converts the captured light signal into an electrical signal and performs processing and analysis.
[0076] According to the processing result, the three-dimensional shape information of the object is extracted.
[0077] In some embodiments, the structured light module further comprises a floodlight for supplementing light for the structured light projector. Adding a floodlight to the structured light module is a design to enhance its functionality and applicability. The main role of the floodlight is to provide supplementary lighting for the structured light projector to ensure that the structured light module can still work normally and obtain accurate three-dimensional information in the case of insufficient light or complex environmental lighting conditions. The spectrum of the floodlight should match the infrared light of the structured light projector to ensure that they can work together and produce the best measurement effect.
[0078] In some embodiments, when the structured light module can both project structured light and floodlight, first set the gray card at the first distance to project structured light and floodlight respectively, then set the gray card at the second distance to project structured light and floodlight respectively, and design the current amplification coefficient of structured light and the current amplification coefficient of floodlight respectively to make the image brightness of structured light and floodlight consistent. In the context of the structured light module being able to project both structured light and floodlight, in order to ensure that structured light and floodlight can obtain consistent image brightness at different distances, the current amplification coefficients of them need to be accurately designed. The gray card is set at the first distance and the second distance respectively. The gray card is a card with uniform reflectivity, used for calibrating and measuring the brightness of the image. At each distance, structured light and floodlight are projected respectively. In the structured light module, the current amplification coefficient is used to affect the brightness of the light source. The specific steps include:
[0079] Test at the first distance:
[0080] Place the gray card at the first distance.
[0081] Project structured light and record the image brightness.
[0082] Adjust the current amplification coefficient of structured light to make the image brightness reach the preset value.
[0083] Project floodlight and record the image brightness.
[0084] Adjust the current amplification coefficient of floodlight to make the image brightness consistent with that of structured light.
[0085] Test at the second distance:
[0086] Move the gray card to the second distance.
[0087] Repeat the above steps to adjust the current amplification coefficients of structured light and flood light respectively, so that the image brightness of the two is consistent.
[0088] Determination of current amplification coefficient:
[0089] Structured light current amplification coefficient: At the first distance and the second distance, respectively record the current amplification coefficient required to make the structured light image brightness reach the preset value.
[0090] Flood light current amplification coefficient: At the first distance and the second distance, respectively record the current amplification coefficient required to make the flood light image brightness consistent with the structured light image brightness.
[0091] Through the above experimental steps, the current amplification coefficients required for structured light and flood light to obtain consistent image brightness at different distances can be determined. These coefficients can be applied in the production and debugging process of structured light module to ensure that the module can provide high-quality image output under different lighting conditions.
[0092] Figure 3 A flowchart of a step in the embodiment of the present application for calculating the first center frame brightness Y1. As shown in Figure 3 the embodiment of the present application, the step of calculating the first center frame brightness Y1 includes:
[0093] Step S21: Extract the pixels of the first center frame on the first image and perform binarization.
[0094] In this step, first determine the position of the center frame on the first image. This is usually obtained by pre-set coordinates or dynamic calculation based on image size. Then, extract all the pixels covered by the center frame from the image. And then binarization. Binarization is the process of converting an image to contain only two pixel values (usually 0 and 255). This helps to simplify the image, making it more suitable for subsequent processing.
[0095] In this step, we choose an appropriate threshold value to compare the pixel values within the center frame with this threshold value. Pixels above the threshold value are set to 255 (white), while pixels below the threshold value are set to 0 (black).
[0096] Step S22: Get the light spot area by threshold comparison.
[0097] In this step, a threshold is applied again in the binary image (the same threshold as used in binarization). This threshold is used to distinguish between the light spot area (usually the brighter area) and the background area. Pixels above this threshold are considered part of the light spot area. Through threshold comparison, it can be determined which pixels belong to the light spot area. These pixels will be used for subsequent calculation of the brightness mean. The light spot area obtained in this step is a mask, which can be mapped to the first image to obtain the corresponding area.
[0098] Step S23: Calculate the brightness mean of the light spot area on the first image as the first center frame brightness Y1.
[0099] In this step, since the light spot area has been determined, the brightness mean of these pixels on the first image needs to be calculated. The brightness mean will be the arithmetic mean of these pixel values, and the calculated brightness mean will be the first center frame brightness Y1. This value can be used for subsequent comparison, analysis or calibration process.
[0100] By following these steps, we can accurately calculate the center frame brightness of the first image captured by the structured light module. These steps not only ensure the accuracy of the calculation, but also improve the processing efficiency and reliability.
[0101] Figure 4 The structural diagram of a system for improving the consistency of image brightness of a structured light module in an embodiment of the present application. As shown in the figure, the system for improving the consistency of image brightness of a structured light module in an embodiment of the present application comprises: Figure 4 As shown in the figure, the system for improving the consistency of image brightness of a structured light module in an embodiment of the present application comprises:
[0102] A first setting module is configured to set a gray card at a first distance in front of the structured light module, and make the structured light module capture a first image of the gray card at a current X;
[0103] A first calculation module is configured to calculate the first center frame brightness Y1 on the first image, obtain the brightness coefficient β = Y1 / Y, and the current amplification coefficient α = 1 / β; wherein Y is the first center frame brightness of the image captured by the standard module at the first distance;
[0104] A second setting module is configured to load the current amplification coefficient into the structured light module, set the gray card at a second distance in front of the structured light module, and make the structured light module capture a second image of the gray card at a current X*α;
[0105] A second calculation module is configured to calculate the second center frame brightness Y2 on the second image, and obtain the brightness coefficient β' = Y2 / Y'; wherein Y' is the second center frame brightness of the image captured by the standard module at the second distance; the first center frame and the second center frame have the same number of light spots;
[0106] The judging module is configured to save the current amplification coefficient a' = 1 / β' to the structured light module if β' is within a preset range, or execute the second setting module.
[0107] The embodiment can test the brightness of the center point of the gray card test image and iteratively adjust the current according to the difference between different structured light modules, so as to quickly keep the image brightness of different structured light modules consistent, and facilitate the consistency of the performance of the same model product.
[0108] Figure 5 is a structural schematic diagram of an equipment for improving the consistency of structured light module image brightness in the embodiment of the application. The electronic device 600 according to this embodiment of the application will be described below with reference to Figure 5 Figure 5 The displayed electronic device 600 is only an example, and should not bring any limitation to the function and use range of the embodiment of the application.
[0109] As shown in Figure 5 , the electronic device 600 is in the form of a general computing device. The components of the electronic device 600 can include but are not limited to: at least one processing unit 610, at least one storage unit 620, a bus 630 connecting different platform components (including the storage unit 620 and the processing unit 610), a display unit 640, etc.
[0110] The storage unit stores program codes, which can be executed by the processing unit 610, so that the processing unit 610 executes the steps according to various exemplary embodiments of the application described in the above method part of the specification for improving the consistency of structured light module image brightness. For example, the processing unit 610 can execute the steps as shown in Figure 1
[0111] The storage unit 620 can include a readable medium in the form of a volatile storage unit, such as a random access memory (RAM) 6201 and / or a cache memory unit 6202, and can further include a read-only memory (ROM) 6203.
[0112] The storage unit 620 can further include a program / utility 6204 having a set of (at least one) program modules 6205, such as an operating system, one or more application programs, other program modules, and program data, and each of these examples or some combination thereof, can include the implementation of a grid environment.
[0113] Bus 630 can be one of several types of bus structures including a storage bus or a memory bus, a peripheral bus, a graphics bus, a processor bus, or a local bus using any of a variety of bus architectures.
[0114] Electronic device 600 can also communicate with one or more external devices 700 such as a keyboard or a pointing device, a Bluetooth device, etc.; other devices associated with electronic device 600; and / or one or more devices that enable user interaction with electronic device 600 (e.g., a display, speakers, etc.); and / or one or more devices that enable communication of electronic device 600 with other computing devices. Such communication can occur via input / output (I / O) interface 650. Still yet, electronic device 600 can communicate with one or more networks such as a local area network (LAN), a general wide area network (WAN), and / or a public network (e.g., the Internet) via a network adapter 660. As depicted, network adapter 660 can communicate with the other components of electronic device 600 via bus 630 although it is understood that other buses, and / or communication methods, can be used to enable communication between electronic device 600 and network adapter 660. Figure 5 It should be appreciated that the software components described herein may, when loaded into the electronic device 600 and executed, transform the electronic device 600 in terms of what it can do, i.e., from a general-purpose computing device capable of implementing the present application to a special-purpose computing device that can implement the steps described herein. A machine so transformed is considered to be "special purpose computing device" in that it has
[0115] The embodiment of the present application also provides a computer readable storage medium for storing a program, the program being executed to implement the steps of a method for improving the consistency of image brightness of a structured light module. In some possible implementation manners, various aspects of the present application can also be implemented in the form of a program product, which includes program codes for causing terminal equipment to perform the steps described in the above method part of the present application with respect to improving the consistency of image brightness of a structured light module when the program product is run on the terminal equipment.
[0116] As shown above, the embodiment of the present application can quickly make the image brightness of different structured light modules consistent by testing the brightness of the center point of the gray card test image and iteratively adjusting the current according to the differences between different structured light modules, which is beneficial to the consistency of the performance of the same product model.
[0117] Figure 6 is a structural diagram of the computer readable storage medium in the embodiment of the present application. Referring to Figure 6As shown, a program product 800 for implementing the above-described method according to an embodiment of the present application is described, which can take the form of a portable compact disc read-only memory (CD-ROM) and includes a program code, and can be run on a terminal device, such as a personal computer. However, the program product of the present application is not limited thereto, and in the present document, the readable storage medium can be any tangible medium that contains or stores a program that can be used by or in connection with an instruction execution system, apparatus, or device.
[0118] The program product can take any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium, for example, can be, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination thereof. More specific examples (a non-exhaustive list) of the readable storage medium include an electrical connection having one or more wires, a portable disc, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof.
[0119] The computer readable storage medium can include a data signal carried by a carrier wave or a propagated signal, where the readable program code is carried by the data signal. Such a propagated signal can take any of a variety of forms, including but not limited to electro-magnetic, optical, or any suitable combination thereof. The readable storage medium can also be any readable medium that is not a storage medium and that can be used to carry or store program code in any form, which can be used by or in connection with an instruction execution system, apparatus, or device. The program code carried or provided by the readable storage medium can be transmitted using any suitable medium, including but not limited to wireless, wired, optical, RF, or any suitable combination thereof.
[0120] The program code for carrying out operations of the present application can be written in any combination of one or more programming languages, including an object-oriented programming language such as Java, C++, or the like, and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code can execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device or entirely on the remote computing device or server. In the latter scenario, the remote computing device can be connected to the user's computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or the connection can be made to an external computing device, such as through the Internet using an Internet service provider.
[0121] According to the difference of different structured light modules, the brightness of the center point of the gray card test image is tested, and the current is iteratively adjusted, so that the image brightness of different structured light modules is kept consistent, which is beneficial to the consistency of the performance of the same type of product.
[0122] The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the difference from other embodiments. The same or similar parts between the various embodiments can be referred to each other. The above description of the disclosed embodiments enables a person skilled in the art to implement or use the present application. Various modifications to the embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
[0123] The specific embodiments of the present application are described above. It should be understood that the present application is not limited to the specific embodiments described above, and various modifications or changes can be made by those skilled in the art within the scope of the claims, which does not affect the essential content of the present application.
Claims
1. A method for improving the consistency of the brightness of a structured light module image, characterized in that, The method comprises: Step S1: setting a gray card at a first distance in front of a structured light module, and making the structured light module capture a first image of the gray card at a current X; Step S2: calculating a first center frame brightness Y1 on the first image to obtain a brightness coefficient β=Y1 / Y and a current amplification coefficient α=1 / β; wherein Y is a first center frame brightness of an image captured at the first distance by a standard module; Step S3: loading the current amplification coefficient into the structured light module, setting the gray card at a second distance in front of the structured light module, and making the structured light module capture a second image of the gray card at a current X*α; Step S4: calculating a second center frame brightness Y2 on the second image to obtain a brightness coefficient β'=Y2 / Y'; wherein Y' is a second center frame brightness of an image captured at the second distance by the standard module; the first center frame and the second center frame have the same number of light spots; Step S5: if β' is within a preset range, saving the current amplification coefficient α'=1 / β' to the structured light module; otherwise, performing step S3.
2. The method for improving the consistency of the image brightness of a structured light module according to claim 1, characterized in that, The first center frame is a rectangular frame with the center of the first image as the center; and the second center frame is a rectangular frame with the center of the second image as the center.
3. The method for improving the consistency of the image brightness of a structured light module according to claim 2, characterized in that, The size of the rectangular frame is not less than 1 / 10 of the length of the side of the image.
4. The method for improving the consistency of the image brightness of a structured light module according to claim 1, characterized in that, The structured light module comprises a structured light projector and a receiver; The structured light projector is configured to project infrared structured light; The receiver is configured to receive a reflection signal of the infrared structured light and expose.
5. The method for improving the consistency of the image brightness of a structured light module according to claim 4, characterized in that, Further comprising: A floodlight configured to provide light for the structured light projector.
6. The method for improving the consistency of the image brightness of a structured light module according to claim 1, wherein, When the structured light module can project structured light and floodlight, the gray card is first set at the first distance to project structured light and floodlight respectively, and then the gray card is set at the second distance to project structured light and floodlight respectively, and the current amplification coefficient of the structured light and the current amplification coefficient of the floodlight are designed respectively to make the structured light and the floodlight obtain consistent image brightness.
7. The method of claim 1, wherein, In the calculation of the first center frame brightness Y1, the method comprises: Step S21: extracting pixels of the first center frame on the first image and performing binaryzation; Step S22: obtaining a light spot area through threshold comparison; Step S23: calculating a brightness mean value of the light spot area on the first image as the first center frame brightness Y1.
8. A system for improving the brightness consistency of a structured light module image, configured to implement the method for improving the brightness consistency of a structured light module image according to any one of claims 1 to 7, characterized in that, The method comprises: A first setting module configured to set a gray card at a first distance in front of a structured light module, and make the structured light module capture a first image of the gray card at a current X; A first calculating module configured to calculate a first center frame brightness Y1 on the first image to obtain a brightness coefficient β=Y1 / Y and a current amplification coefficient α=1 / β; wherein Y is a first center frame brightness of an image captured at the first distance by a standard module; A second setting module configured to load the current amplification coefficient into the structured light module, set the gray card at a second distance in front of the structured light module, and make the structured light module capture a second image of the gray card at a current X*α; A second calculation module is configured to calculate a second center frame luminance Y2 on the second image to obtain a luminance coefficient β'=Y2 / Y', wherein Y' is a second center frame luminance on an image captured at a second distance by a standard module; the first center frame and the second center frame have the same number of light spots; A judgment module is configured to save a current amplification coefficient α'=1 / β' to the structured light module if β' is within a preset range; otherwise, execute the second setting module.
9. A device for improving the brightness uniformity of structured light module images, characterized in that, The method comprises the following steps: A processor; A memory, wherein executable instructions of the processor are stored; The processor is configured to execute the executable instructions to perform the steps of the method for improving the image luminance consistency of the structured light module according to any one of claims 1 to 7.
10. A computer readable storage medium for storing a program, characterized in that, The program is executed to perform the steps of the method for improving the image luminance consistency of the structured light module according to any one of claims 1 to 7.
Citation Information
Patent Citations
Structured light module image brightness calibration device
CN119958463A
Method, system and device for improving image brightness consistency of infrared camera module and storage medium
CN120031979A