Image acquisition system and method, electronic device and computer readable storage medium
By adjusting the positional relationship between the light source and the calibration reference, a calibrated image is generated, which solves the vignetting problem of wide-angle cameras, reduces the cost of using integrating sphere equipment, and achieves uniform image brightness.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BLACK SESAME TECH (SHENZHEN) CO LTD
- Filing Date
- 2022-08-24
- Publication Date
- 2026-06-16
AI Technical Summary
In existing technologies, wide-angle cameras suffer from vignetting during imaging, and traditional lens shading correction techniques require expensive integrating sphere equipment with high maintenance costs.
By configuring the positional relationship between the light source and the calibration reference, and adjusting the illumination direction of the light source, the illuminance of the light source in different areas of the calibration reference meets the preset uniformity conditions. The image of the calibration reference is then acquired using an image acquisition device, and a calibration image is generated for lens shadow correction of the image acquisition device.
It reduces the purchase and maintenance costs of testing equipment for acquiring corrected images, achieves lens shading correction, and improves image brightness uniformity.
Smart Images

Figure CN115561952B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of image acquisition, specifically to an image acquisition system and method, electronic device, and computer-readable storage medium. Background Technology
[0002] With the rapid development of digital camera technology, wide-angle cameras are being used more and more widely in our daily lives and work. Wide-angle camera lenses, due to their short focal length, wide angle of view, and long depth of field, are well-suited for capturing large scenes, such as architecture and landscapes.
[0003] However, with wide-angle cameras, as the field of view increases at greater distances, the amount of oblique light passing through the camera lens gradually decreases. This results in an image where the center area is brighter and the edges are darker, a phenomenon known as vignetting. To address this vignetting issue, lens shading correction technology can be used. This technique compensates for the brightness of shadows at the image edges, ensuring good brightness uniformity in the image presented to the user.
[0004] Traditional lens shading correction techniques typically use an integrating sphere to acquire a correction image, which is then used to calculate the camera's correction parameters for calibration. However, integrating spheres are expensive to purchase and require regular maintenance. Summary of the Invention
[0005] In view of this, in order to solve the problems existing in the prior art, the embodiments of this application provide an image acquisition system and method, an electronic device and a computer-readable storage medium, which can reduce the purchase and maintenance costs of test equipment used to acquire calibrated images.
[0006] In a first aspect, embodiments of this application provide an image acquisition system, including: a light source, a calibration reference, and an image acquisition device to be calibrated. The light source is configured to adjust the positional relationship between itself and the calibration reference and the direction in which the light source illuminates the calibration reference, such that the illuminance of the light emitted by the light source in different areas of the calibration reference meets a preset uniformity condition. The image acquisition device is configured to acquire at least one image of the calibration reference when the uniformity condition is met. The at least one image is used to obtain a calibration image, and the calibration image is used to perform lens shading correction on the image acquisition device.
[0007] In some embodiments of this application, the image acquisition device is positioned on the normal line passing through the center point of the calibration reference, and the light source includes multiple sub-light sources, which are symmetrically arranged about the normal line as an axis.
[0008] In some embodiments of this application, the image acquisition device is disposed between at least one light source and a calibration reference.
[0009] In some embodiments of this application, the uniformity condition is that the ratio of the difference between the maximum illuminance and the minimum illuminance to the minimum illuminance is less than or equal to 20%.
[0010] In some embodiments of this application, the acquisition system further includes at least one diffuser layer disposed in front of the lens of the image acquisition device.
[0011] In some embodiments of this application, at least one diffuser layer comprises multiple flexible diffusers configured to be arranged symmetrically in an arc shape in front of the lens of the image acquisition device.
[0012] In some embodiments of this application, at least one diffuser layer is a frosted sheet.
[0013] In some embodiments of this application, the distance D between the surface of at least one diffuser layer near the lens of the image acquisition device and the lens of the image acquisition device satisfies: 0mm < D ≤ 2mm.
[0014] In some embodiments of this application, the acquisition system further includes a controller configured to adjust the positional relationship between the light source and the calibration reference object and the direction of the light source illuminating the calibration reference object through a driving device, so that the illuminance of the light emitted by the light source in different areas of the calibration reference object meets the uniformity condition.
[0015] In some embodiments of this application, the acquisition system further includes multiple illuminance detection devices distributed in different areas for detecting the illuminance in different areas.
[0016] Secondly, embodiments of this application provide an image acquisition method, comprising: adjusting the positional relationship between a light source and a correction reference, and adjusting the direction of the light source illuminating the correction reference so that the illuminance of different areas on the correction reference meets a preset uniformity condition; acquiring at least one image of the correction reference using an image acquisition device to be corrected when the uniformity condition is met; generating a correction image based on the at least one image, the correction image being used to perform lens shading correction on the image acquisition device.
[0017] In some embodiments of this application, the image acquisition device is positioned on the normal line passing through the center point of the calibration reference, the light source includes multiple sub-light sources, and adjusting the positional relationship between the light source and the calibration reference includes: adjusting the positional relationship between the light source and the calibration reference while satisfying the condition that the multiple sub-light sources are symmetrically arranged with the normal line as the axis.
[0018] In some embodiments of this application, at least one diffuser is provided in front of the lens of the image acquisition device.
[0019] In some embodiments of this application, acquiring at least one image of a calibration reference using an image acquisition device to be calibrated includes: acquiring at least one image from multiple different angles using the image acquisition device to obtain multiple images; generating a calibration image based on at least one image includes: averaging the multiple images to generate the calibration image.
[0020] In some embodiments of this application, different angles include the forward direction of the lens of the image acquisition device facing the calibration reference object, and the four directions of up, down, left, and right that form a preset angle with the forward direction, with the preset angle not exceeding 45 degrees.
[0021] Thirdly, embodiments of this application provide an electronic device, including: a processor; and a memory for storing processor-executable instructions, wherein the processor is used to execute the image acquisition method described in the second aspect above.
[0022] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program for executing the image acquisition method described in the second aspect above.
[0023] Fifthly, embodiments of this application provide an image acquisition device, comprising: an adjustment module for adjusting the positional relationship between a light source and a correction reference, and adjusting the direction of the light source illuminating the correction reference so that the illuminance of different areas on the correction reference meets a preset uniformity condition; an acquisition module for acquiring at least one image of the correction reference using the image acquisition device to be corrected when the uniformity condition is met; and a generation module for generating a correction image based on the at least one image, the correction image being used to perform lens shading correction on the image acquisition device.
[0024] According to embodiments of this application, by setting the positional relationship between the light source and the calibration reference, uniform illumination conditions are provided on the calibration reference. An image of the calibration reference is acquired using an image acquisition device to be calibrated, and a calibration image is obtained based on the image of the calibration reference for lens shading correction of the image acquisition device. This image acquisition system eliminates the need for an expensive integrating sphere, reducing the purchase and maintenance costs of the testing equipment for acquiring calibration images. Attached Figure Description
[0025] Figure 1 The diagram shown is a schematic representation of the structure of an image acquisition system provided in an exemplary embodiment of this application.
[0026] Figure 2 The diagram shown is a schematic diagram of the structure of an image acquisition system provided in another exemplary embodiment of this application.
[0027] Figure 3The diagram shown is a flowchart illustrating an image acquisition method provided in an exemplary embodiment of this application.
[0028] Figure 4 The diagram shown is a schematic diagram of the image acquisition device provided in an exemplary embodiment of this application at different shooting angles.
[0029] Figure 5 The diagram shown is a flowchart illustrating an image acquisition method provided in another exemplary embodiment of this application.
[0030] Figure 6 The diagram shown is a schematic of a corrected image obtained using the image acquisition system and method provided in the embodiments of this application.
[0031] Figure 7 The image shown is a schematic diagram of a calibrated image obtained using an integrating sphere device.
[0032] Figure 8a The image shown is a schematic diagram of an image without lens shading correction.
[0033] Figure 8b The image shown is a schematic diagram of the image after lens shading correction using an integrating sphere device.
[0034] Figure 8c The image shown is a schematic diagram of an image after lens shading correction using the image acquisition system and method provided in the embodiments of this application.
[0035] Figure 9 The diagram shown is a block diagram of an electronic device for performing an image acquisition method according to an exemplary embodiment of this application.
[0036] Figure 10 The diagram shown is a schematic representation of the structure of an image acquisition device provided in an exemplary embodiment of this application. Detailed Implementation
[0037] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0038] Related technologies
[0039] An integrating sphere, also called a light sphere, is a hollow, complete spherical shell with a smooth inner wall coated with a diffuse reflective material. Its typical function is to collect light, which is then used as a diffuse light source. An integrating sphere can achieve a uniform Lambertian diffuse light output with very uniform brightness. Because the integrating sphere can provide a uniform brightness environment, traditional lens shading correction uses integrating sphere equipment to acquire correction images, which are then processed by algorithms to correct uneven brightness in images captured by the camera.
[0040] However, integrating sphere equipment is expensive to purchase and requires frequent maintenance. Therefore, there is an urgent need for a simple and practical image acquisition method and system that can acquire calibrated images without the need for integrating sphere equipment.
[0041] Exemplary System
[0042] Figure 1 The diagram shown is a schematic representation of the structure of an image acquisition system provided in an exemplary embodiment of this application.
[0043] like Figure 1 As shown, the image acquisition system includes a light source 10, a calibration reference 11, and an image acquisition device 12. The image acquisition device 12 can be disposed between the light source 10 and the calibration reference 11.
[0044] The calibration reference 11 can be a flat object such as a wall or a flat panel. Specifically, the calibration reference 11 can include a gray wall, gray cardboard, or gray curtain. For example, the calibration reference 11 can include an 18% gray flat wall, an 18% gray flat cardboard, or an 18% gray flat curtain.
[0045] The image acquisition device 12 may include a standard lens camera, a wide-angle lens camera, an ultra-wide-angle lens camera, a telephoto lens camera, etc.
[0046] The light source 10 can be a pair of light sources or a combination of multiple light sources. Specifically, the light source 10 can include incandescent lamps, energy-saving lamps, metal halide lamps, and LED lamps (light-emitting diodes). For example, the light source 10 can be a flexible LED lamp.
[0047] The light source 10 is configured to adjust the positional relationship between itself and the calibration reference object and the direction in which the light source illuminates the calibration reference object so that the illuminance of the light emitted by the light source in different areas of the calibration reference object 11 meets a preset uniformity condition. The image acquisition device 12 is configured to acquire at least one image of the calibration reference object 11 when the uniformity condition is met. The at least one image is used to obtain a calibration image, wherein the calibration image is used to perform lens shadow correction on the image acquisition device.
[0048] Specifically, the light emitted by the light source 10 illuminates the calibration reference 11. By adjusting the positional relationship between the light source 10 and the calibration reference 11, as well as the direction of the light source illuminating the calibration reference, the illuminance of different areas on the calibration reference 11 can meet the preset uniformity conditions. Subsequently, the image acquisition device 12 is used to acquire an image of the calibration reference 11 to obtain a calibration image.
[0049] The corrected image is used to perform lens shading correction on the image acquisition device. Lens shading correction is used to address the issue of shadows appearing around the lens due to uneven optical refraction. For example, based on the corrected image, a shading correction algorithm can calculate the brightness compensation coefficient of pixels in the shadow area. Images acquired by the image acquisition device after shading correction exhibit good brightness uniformity, improving the dark edges of the image. Furthermore, the corrected image is used to calculate correction parameters for the image acquisition device 12. These parameters can be stored in the image acquisition device 12 and can be retrieved when shading correction is needed for images captured by the image acquisition device 12, resulting in an image with eliminated vignetting and uniform brightness. The correction parameters can include brightness parameters and chromaticity parameters. The brightness parameter can be the ratio of the average brightness of the central area to the average brightness of each area; the chromaticity parameter can be the ratio of the average chromaticity of the central area to the average chromaticity of each area.
[0050] It should be noted that the higher the illuminance uniformity of the calibration reference 11, the better, so as to provide a uniform light source environment for the acquisition of the calibration image, thereby improving the accuracy of the calibration parameters and the correction effect of lens shadows. Illuminance, also known as light intensity, refers to the luminous flux received per unit area, that is, a physical quantity used to express the brightness of the illuminated surface.
[0051] In one embodiment, illuminance uniformity can be used to represent the preset uniformity condition. Illuminance uniformity refers to the ratio of the minimum illuminance in different areas to the average illuminance of the entire calibration reference, i.e., illuminance uniformity = minimum illuminance value / average illuminance value. Alternatively, as another embodiment, illuminance uniformity can also refer to the ratio of the minimum illuminance in different areas to the maximum illuminance of the entire calibration reference. The closer the illuminance uniformity is to 1, the better. The minimum and maximum illuminance values can be calculated using a pixel-by-pixel calculation method. When the difference between the illuminance uniformity in different areas of the calibration reference and 1 is less than a preset threshold, the preset uniformity condition is determined to be met. For example, the preset uniformity condition can be an illuminance uniformity greater than or equal to 90%. It should be understood that the illuminance uniformity is not specifically limited in this application, and those skilled in the art can set it according to specific circumstances.
[0052] In another embodiment, the preset uniformity condition can be that the ratio of the difference between the maximum and minimum illuminance to the minimum illuminance is less than or equal to 20%. Alternatively, the preset uniformity condition can be that different areas simultaneously satisfy the condition that the ratio of the difference between the maximum and minimum illuminance to the minimum illuminance is less than or equal to 20% and the illuminance uniformity is greater than or equal to 90%.
[0053] In one embodiment, when capturing an image using the image acquisition device 12, the light source 10 can first be adjusted to a suitable position and its illumination direction adjusted to ensure uniform illuminance on different areas of the calibration reference 11 and between different areas. Then, the image acquisition device 12 is used to capture an image of the calibration reference 11 to obtain at least one image. The different areas on the calibration reference can be divided into regions based on their area. It should be noted that the size of the region can be set according to the dimensions of the calibration reference, and this embodiment does not limit this.
[0054] Optionally, the above-described acquisition system may further include an illuminance measuring device 14 and a controller (or computing device) 15. The illuminance measuring device 14 is used to detect the illuminance of light in different areas of the calibration reference 11. The computing device 15 is used to adjust the light source 10 to a suitable position by controlling a driving device based on the illuminance of different areas of the calibration reference 11 detected by the illuminance measuring device 14, and to adjust the illumination direction of the light source 10 by another driving device, so that the illuminance of light in different areas of the calibration reference 11 is uniform.
[0055] Optionally, the computing device 15 is used to adjust the image acquisition device 12 to a suitable position by controlling the drive device so that the image acquisition device 12 is displayed on the calibration reference object 11 with as few shadows as possible, and to ensure that the brightness of the acquired image is not affected by factors other than uniform illumination.
[0056] It should be understood that the image acquisition system can be set up in a normal image quality laboratory environment. Specifically, the width and height of the laboratory meet the requirements of wide-angle shooting by the camera, provide sufficient space to set up a calibration reference, and the calibration reference has good flatness. For example, the width of the calibration reference is greater than or equal to 4m, and the height is greater than or equal to 2.5m. It should be understood that those skilled in the art can set the size of the calibration reference according to the wide-angle FOV of the image acquisition device, and this application embodiment does not impose any limitations on this.
[0057] This application provides an image acquisition system that adjusts the positional relationship between the light source and a calibration reference object, as well as the direction of the light source illuminating the calibration reference object, to ensure that the illuminance of the light emitted by the light source in different areas of the calibration reference object meets a preset uniformity condition. Then, with the illuminance uniformity condition met, an image acquisition device acquires at least one image of the calibration reference object, and a calibrated image is obtained based on this image for lens shading correction of the image acquisition device. The image acquisition system provided in this application does not require the use of an expensive integrating sphere, thus reducing the purchase and maintenance costs of the testing equipment for acquiring calibrated images.
[0058] Figure 2 The diagram shown is a schematic diagram of the structure of an image acquisition system provided in another exemplary embodiment of this application.
[0059] It should be noted that the image acquisition system provided in this embodiment is Figure 1 Another embodiment of the image acquisition system provided in the embodiments, the functions of the light source, the calibration reference and the image acquisition device to be calibrated in the system are described above. To avoid repetition, the similarities will not be repeated.
[0060] like Figure 2 As shown, the light source of the image acquisition system includes a first sub-light source 101 and a second sub-light source 102. The image acquisition device 12 is located on the normal 103 (hereinafter referred to as normal 103) passing through the center point of the calibration reference 11, and its lens faces and is perpendicular to the calibration reference 11. The first sub-light source 101 and the second sub-light source 102 are symmetrically arranged about the normal 103. By adjusting the vertical distance D1 between the first sub-light source 101 and the second sub-light source 102 and the calibration reference 11, the vertical distance D2 between the first sub-light source 101 and the second sub-light source 102 and the normal, and the illumination angle α of the first sub-light source 101 and the second sub-light source 102, the illuminance of different areas on the calibration reference 11 can meet the preset uniformity conditions. The acquisition system according to this embodiment is beneficial for providing a calibration reference with uniform brightness, providing a uniform light source environment for the acquisition of the calibration image, thereby improving the accuracy of the calibration parameters and improving the correction effect of lens shadows.
[0061] In one embodiment, the calibration reference 11 can be divided into different regions, such as regions B to F. In some embodiments, adjacent regions of the calibration reference 11 also meet the uniformity requirement of illumination; for example, region A on the first calibration reference 111 and region G on the second calibration reference 112 also meet the uniformity requirement of illumination. It should be noted that the division of regions can be set differently according to the size of the calibration reference 11 and the field of view of the image acquisition device 12 to be calibrated, and this embodiment does not limit this.
[0062] In one embodiment, the calibration reference 11 is connected to the first calibration reference 111 and the second calibration reference 112 with the same curvature to form a calibration reference with curvature. This provides a calibration reference that meets the uniformity condition, which is closer to the testing environment of the integrating sphere. This provides a uniform light source environment for the acquisition of the calibration image, thereby improving the accuracy of the calibration parameters and improving the correction effect of lens shadows.
[0063] In one embodiment, the preset uniformity condition of the above-mentioned acquisition system is that the ratio of the difference between the maximum illuminance and the minimum illuminance to the minimum illuminance is less than or equal to 20%.
[0064] Alternatively, the preset uniformity condition can also be illuminance uniformity, expressed as the ratio of minimum illuminance to average illuminance. For example, illuminance uniformity is greater than or equal to 90%. Higher illuminance uniformity is better, as a uniformly illuminated calibration reference can provide a uniform light source environment for acquiring the calibration image, thereby improving the accuracy of the calibration parameters.
[0065] In one embodiment, the acquisition system further includes at least one diffuser layer disposed in front of the lens of the image acquisition device. The diffuser layer can further provide uniform incident light to the image acquisition device, compensate for the illuminance uniformity of the calibration reference, and provide a uniform light source environment for acquiring the calibration image, thereby improving the accuracy of the calibration parameters and thus enhancing the correction effect of lens shading.
[0066] In one embodiment, at least one diffuser layer comprises multiple flexible diffusers and is arranged symmetrically in an arc shape in front of the lens of the image acquisition device. The arrangement of multiple flexible diffusers provides more uniform incident light compared to a single diffuser layer. For example, at least one diffuser layer comprises multiple flexible diffusers configured to be symmetrically arranged in an arc shape in front of the lens of the image acquisition device.
[0067] The flexible diffuser can be shaped with a certain curvature and can be symmetrically placed in front of the lens in an arc shape. This allows the flexible diffuser to completely envelop the lens, preventing light leakage and ensuring that as much or all of the light passes through the diffuser before entering the lens. Optionally, the flexible diffuser can be shaped like a hemispherical surface in front of the lens. Alternatively, multiple flexible diffusers can be placed in the wide-angle and non-wide-angle viewing directions of the lens. For example, the flexible diffuser can be shaped like a hemispherical arc in the wide-angle viewing direction and a flat surface in the non-wide-angle viewing direction, so that the arc-shaped diffuser in the wide-angle direction and the flat diffuser in the non-wide-angle direction form a semi-cylindrical shape, thus completely enveloping the lens. The placement of the flexible diffuser can compensate for the uniformity of illumination of the correction reference object, providing a uniform light source environment for obtaining the correction image, thereby improving the accuracy of the correction parameters and the correction effect of lens shading.
[0068] In one embodiment, at least one diffuser layer is a frosted sheet. Specifically, a fine-grained frosted sheet can provide better uniform incident light than a coarse-grained frosted sheet.
[0069] In one embodiment, the distance D between the surface of at least one diffuser layer near the lens of the image acquisition device and the lens of the image acquisition device satisfies: 0mm < D ≤ 2mm.
[0070] For example, if the distance between the diffuser and the lens of the image acquisition device is set to 1mm, experiments have shown that the corrected image obtained by this setting has better brightness uniformity and can obtain more accurate correction parameters, thus resulting in better uniformity of the image after lens shadow correction.
[0071] In one embodiment, the acquisition system further includes a controller configured to adjust the positions of the light source and the image acquisition device, as well as the direction in which the light source illuminates the calibration reference object, via a driving device, so that the illuminance of the light emitted by the light source in different areas of the calibration reference object meets a preset uniformity condition.
[0072] Specifically, when using a pair of light sources, the controller can use a preset strategy to control the drive mechanism (e.g., a motor) to drive the two light sources to translate or rotate, thereby adjusting the positional relationship between the light sources and the calibration reference, and adjusting the direction of the light sources illuminating the calibration reference until a uniform illumination condition that meets the requirements is formed on the calibration reference.
[0073] In one embodiment, the acquisition system may further include multiple illuminance detection devices distributed in the different areas for detecting the illuminance in the different areas.
[0074] For example, an illuminance meter can be used to detect the illuminance in different areas of a calibration reference object, and the controller can receive the measurement results from the illuminance meter and calculate whether the illuminance in different areas is uniform.
[0075] Exemplary methods
[0076] Figure 3 The diagram shown is a flowchart illustrating an image acquisition method provided in an exemplary embodiment of this application. Figure 3 The collection method can be determined by Figure 1 The controller or computing device executes this. For ease of understanding, in conjunction with... Figure 1 right Figure 2 The image acquisition system shown provides a detailed description of the image acquisition method. For example... Figure 3 As shown, the image acquisition method includes the following. It should be noted that the image acquisition method provided in this embodiment and... Figure 2 The image acquisition system provided in the embodiment is corresponding, and to avoid repetition, the similarities will not be repeated.
[0077] 310: Adjust the positional relationship between the light source and the calibration reference, and adjust the direction in which the light source illuminates the calibration reference, so that the illuminance of different areas on the calibration reference meets the preset uniformity condition.
[0078] Specifically, the positional relationship between the light source and the calibration reference includes the horizontal distance and the vertical distance between them. When the light source comprises multiple sub-light sources, the positional relationship between the light source and the calibration reference can include the distance between each sub-light source and the calibration reference, as well as the distance between the multiple sub-light sources.
[0079] The direction in which the light source illuminates the calibration reference can be represented by the angle formed by the light emission direction from the center point of the light source and the normal direction of the surface of the calibration reference, or by the angle formed by the light emission direction from the center point of the light source and the surface of the calibration reference. In some embodiments, at least the illuminance of different areas on the calibration reference corresponding to the wide-angle range of the lens of the image acquisition device to be calibrated must meet a preset uniformity condition.
[0080] By adjusting the positional relationship between the light source and the calibration reference, the illuminance of different areas on the calibration reference meets the preset uniformity conditions, thereby providing a uniformly illuminated image acquisition environment for the image acquisition device to be calibrated.
[0081] It should be noted that for detailed instructions on ensuring the illuminance in different areas of the calibration reference meets the preset uniformity conditions, please refer to [link to relevant documentation]. Figure 1 The embodiments shown are not described again here to avoid repetition.
[0082] 320: Under the condition that the uniformity condition is met, acquire at least one image of the calibration reference using the image acquisition device to be calibrated.
[0083] Specifically, after the illumination in different areas of the calibration reference meets the preset uniformity condition, one or more images of the calibration reference can be acquired using an image acquisition device with a wide-angle lens. For example, the image acquisition device can be used to acquire multiple images of the calibration reference along the same or different directions.
[0084] 330: Generate a correction image based on at least one image, the correction image being used to correct lens shading on the image acquisition device.
[0085] Specifically, if only one image is captured, it can be directly used as the correction image. If multiple images are captured, they can be fused together to generate the correction image.
[0086] In some embodiments, when the illuminance uniformity of the calibration reference is high, an image acquired by the image acquisition device can be used as the calibration image.
[0087] This application provides an image acquisition method. By adjusting the positional relationship between a light source and a calibration reference object, and adjusting the direction of the light source illuminating the calibration reference object, a calibration reference object with uniform illumination is provided. Then, at least one image of the calibration reference object is acquired using an image acquisition device to be calibrated. The calibrated image obtained based on at least one image can be used to correct lens shading on the image acquisition device. This image acquisition method does not require an integrating sphere, eliminating the need for an expensive integrating sphere, and can be performed in a normal image quality laboratory environment, reducing the purchase and maintenance costs of testing equipment for acquiring calibration images.
[0088] It should be understood that Figure 3 The method can also be implemented manually by the operator. For example, the operator can move the position and orientation of the light source and determine whether the illuminance is uniform in different areas based on the values displayed by the illuminance measuring instruments set on different areas of the calibration reference.
[0089] In one embodiment, the image acquisition device is positioned on the normal line passing through the center point of the calibration reference. The light source includes multiple sub-light sources. Adjusting the positional relationship between the light source and the calibration reference includes: adjusting the positional relationship between the light source and the calibration reference while ensuring that the multiple sub-light sources are symmetrically arranged with the normal line as the axis.
[0090] Specifically, the image acquisition device is positioned on the normal line passing through the center point of the calibration reference object facing forward. Furthermore, the positions of multiple sub-light sources are adjusted so that they are symmetrically distributed about the normal line as an axis, thereby improving the uniformity of illumination in different areas of the calibration reference object and shortening the adjustment time. The method according to this embodiment facilitates the provision of a calibration reference object with uniform brightness, providing a uniform light source environment for acquiring the calibration image, thereby improving the accuracy of calibration parameters and enhancing the correction effect of lens shading.
[0091] For example, a baseline can be established that passes through the normal and is parallel to the surface of the calibration reference. Multiple sub-light sources can be uniformly arranged on this baseline. For instance, the baseline can be a straight line, a circle centered on the normal, or a polygon. If the baseline is a straight line, multiple sub-light sources can be uniformly arranged on both sides of the normal along the baseline. If the baseline is a circle, multiple sub-light sources can be uniformly arranged around the normal along the circumference of the circle. If the baseline is a polygon, multiple sub-light sources can be placed at the vertices of the polygon.
[0092] In one embodiment, the image acquisition device is disposed between at least one light source and a calibration reference.
[0093] Positioning the image acquisition device between the light source and the calibration reference object avoids the light source appearing within the field of view of the image acquisition device, thus providing more favorable positional conditions for image acquisition. In this case, when performing step 310, the distance between the image acquisition device to be calibrated and the calibration reference object can also be adjusted simultaneously to minimize the shadow of the image acquisition device on the calibration reference object, or to prevent multiple overlapping shadows of the image acquisition device from appearing on the calibration reference object, thereby ensuring that the calibration reference object meets the condition of uniform illumination.
[0094] In one embodiment, at least one diffuser is provided in front of the lens of the image acquisition device.
[0095] The setting of a diffuser can further provide uniform incident light for the image acquisition device, compensate for the uniformity of illumination of the calibration reference, and provide a uniform light source environment for the acquisition of the calibration image, so as to improve the accuracy of the calibration parameters and improve the correction effect of lens shadows.
[0096] Alternatively, a multi-layer diffuser can provide more uniform incident light compared to a single-layer diffuser.
[0097] The flexible diffuser can further compensate for the uniformity of illumination of the calibration reference, providing a uniform light source environment for the acquisition of the calibration image, thereby improving the accuracy of the calibration parameters and the correction effect of lens shadows.
[0098] In one embodiment, at least one diffuser layer is a frosted sheet.
[0099] The frosted sheet can be a frosted film with a frosted effect or a transparent adhesive tape with a frosted effect.
[0100] Optionally, choosing a fine-grained frosted glass can further improve the uniformity of incident light from the lens.
[0101] In one embodiment, the distance D between the surface of at least one diffuser layer near the lens of the image acquisition device and the lens of the image acquisition device satisfies: 0mm < D ≤ 2mm.
[0102] For example, when the distance between the diffuser and the lens of the image acquisition device is set to 1mm, experiments have shown that the uniformity of the image generated after lens shading correction is better when the corrected image acquired with this setting is obtained.
[0103] Optionally, when setting a diffuser in front of the lens, wrinkles in the diffuser should be avoided to improve the uniformity of incident light into the lens.
[0104] Optionally, when setting multiple diffusers in front of the lens, air bubbles should be avoided between the multiple diffusers to improve the uniformity of incident light into the lens.
[0105] Optionally, the light source can be a flexible LED light source.
[0106] Optionally, a softbox can be placed at the light source to improve the uniformity of illumination on the calibration reference.
[0107] In one embodiment, acquiring at least one image of a calibration reference using an image acquisition device to be calibrated includes: acquiring at least one image from multiple different angles using the image acquisition device to obtain multiple images; generating a calibration image based on at least one image includes: averaging the multiple images to generate the calibration image.
[0108] The angle between the lens of the image acquisition device and the calibration reference object is adjusted, and at least one image is acquired from multiple different shooting angles. These multiple images are then averaged, and the averaged image is used as the calibration image. On one hand, acquiring multiple images in the same direction can reduce noise in the acquired images; on the other hand, acquiring images from multiple different angles can compensate for the uniformity of illumination on the calibration reference object, providing a uniform light source environment for acquiring the calibration image, thereby improving the accuracy of the calibration parameters and enhancing the correction effect of lens shading.
[0109] Figure 4 The diagram shown is a schematic diagram of the image acquisition device provided in an exemplary embodiment of this application at different shooting angles.
[0110] like Figure 4As shown, multiple different shooting angles include the forward direction of the lens of the image acquisition device facing the calibration reference (the normal direction of the calibration reference surface) and the four directions of up, down, left, and right at a preset angle θ with respect to the forward direction. The preset angle θ is no greater than 45 degrees.
[0111] Furthermore, keeping the exposure time, gain, and aperture of the image acquisition device constant, at least one image is acquired from each of the five different directions mentioned above. By averaging these multiple images, the averaged image is used as the correction image. This method can compensate for areas with poor illumination uniformity on the correction reference, making the generated correction image more compliant with uniform illumination requirements, improving the accuracy of the correction parameters, and thus enhancing the precision of lens shading correction. For example, by acquiring images from multiple symmetrical shooting directions using the image acquisition device, a correction image with uniform brightness can be further obtained.
[0112] For example, the image acquisition device acquires 16 images in each of the five different directions, for a total of 80 images. The data matrices of the 80 images are then accumulated pixel by pixel and averaged to finally generate a corrected image.
[0113] Figure 5 The diagram shown is a flowchart illustrating an image acquisition method provided in another exemplary embodiment of this application. Figure 5 As shown, this data acquisition method includes the following. It should be noted that... Figure 5 The example is Figure 3 The similarities in the examples will not be repeated here; the focus here is on describing the differences.
[0114] 510: Adjust the positional relationship between the light source and the calibration reference, and adjust the direction of the light source illuminating the calibration reference so that the illuminance of different areas on the calibration reference meets the preset uniformity conditions.
[0115] Specifically, at least within the field of view of the image acquisition device, the illuminance distribution on the calibration reference must meet the uniformity condition.
[0116] 520: Adjust the distance between the image acquisition device and the calibration reference object so that the shadow of the image acquisition device is not projected onto the calibration reference object.
[0117] 530: At least one layer of frosted film is placed in front of the lens of the image acquisition device.
[0118] Specifically, the frosted film is set symmetrically in a hemispherical shape at a distance of 1mm from the lens.
[0119] 540: Acquire at least one image in a direction perpendicular to the calibration reference using an image acquisition device.
[0120] 550: Keeping the exposure time, gain, and aperture of the image acquisition device constant, rotate the lens of the image acquisition device up, down, left, and right by preset angles respectively, and acquire at least one image.
[0121] 560: Average the obtained images to generate a corrected image.
[0122] Exemplary Experimental Test
[0123] Figure 6 The diagram shown is a schematic of a corrected image obtained using the image acquisition system and method provided in the embodiments of this application. Figure 7 The image shown is a schematic diagram of a calibrated image obtained using an integrating sphere device.
[0124] like Figure 6 and Figure 7 As shown, the corrected image obtained using the image acquisition system and method provided in this application embodiment is very close to the corrected image obtained using an integrating sphere device, verifying that the image acquisition system and method provided in this application embodiment have high reliability and accuracy. Furthermore, it saves on the cost of purchasing an integrating sphere device and the maintenance costs during subsequent use.
[0125] Figure 8a The image shown is a schematic diagram of an image without lens shading correction. Figure 8b The image shown is a schematic diagram of the image after lens shading correction using an integrating sphere device. Figure 8c The image shown is a schematic diagram of an image after lens shading correction using the image acquisition system and method provided in the embodiments of this application.
[0126] like Figure 8a , 8b As shown in Figure 8c, a comparison reveals that the image quality obtained after correction using the image acquisition system and method provided in this application is very close to the image quality obtained after correction using an integrating sphere device. This verifies that the image acquisition system and method of this application have high reliability and accuracy. Furthermore, it saves on the cost of purchasing an integrating sphere device and the maintenance costs during subsequent use.
[0127] Figure 9 The diagram shown is a block diagram of an electronic device 900 for performing an image acquisition method according to an exemplary embodiment of this application.
[0128] like Figure 9As shown, the electronic device 900 includes a processing component 910, which further includes one or more processors, and memory resources represented by a memory 920 for storing instructions executable by the processing component 910, such as application programs. The application programs stored in the memory 920 may include one or more modules, each corresponding to a set of instructions. Furthermore, the processing component 910 is configured to execute instructions to perform the aforementioned image acquisition method.
[0129] Electronic device 900 may also include a power supply component configured to perform power management of electronic device 900, a wired or wireless network interface configured to connect electronic device 900 to a network, and an input / output (I / O) interface. Electronic device 900 can be operated based on an operating system stored in memory 920, such as Windows Server. TM Mac OSX TM Unix TM Linux TM FreeBSD TM Or similar.
[0130] Figure 10 The diagram shown is a schematic representation of the structure of an image acquisition device 1000 provided in an exemplary embodiment of this application.
[0131] like Figure 10 As shown, the image acquisition device 1000 includes: an adjustment module 1010, an acquisition module 1020, and a generation module 1030.
[0132] The adjustment module 1010 is used to adjust the positional relationship between the light source and the calibration reference, and to adjust the direction of the light source illuminating the calibration reference, so that the illuminance of different areas on the calibration reference meets the preset uniformity conditions.
[0133] The acquisition module 1020 is used to acquire at least one image of the calibration reference object using the image acquisition device to be calibrated, provided that the uniformity condition is met.
[0134] The generation module 1030 is used to generate a correction image based on at least one image, and the correction image is used to perform lens shading correction on the image acquisition device.
[0135] This application provides an image acquisition device. By adjusting the positional relationship between a light source and a calibration reference object, and adjusting the direction of the light source illuminating the calibration reference object, a calibration reference object with uniform illumination is provided. Subsequently, at least one image of the calibration reference object is acquired using the image acquisition device to be calibrated. The calibrated image obtained based on at least one image can be used to perform lens shading correction on the image acquisition device. This image acquisition device does not require an integrating sphere, eliminating the need for an expensive integrating sphere, and can be used in a normal image quality laboratory environment, thereby reducing the purchase and maintenance costs of testing equipment for acquiring calibration images.
[0136] In one embodiment, the image acquisition device is positioned on the normal line passing through the center point of the calibration reference, the light source includes multiple sub-light sources, and the adjustment module 1010 is further used to adjust the positional relationship between the light source and the calibration reference under the condition that the multiple sub-light sources are symmetrically arranged with the normal line as the axis.
[0137] In one embodiment, at least one diffuser is provided in front of the lens of the image acquisition device.
[0138] Optionally, at least one diffuser layer includes multiple flexible diffusers configured to be arranged symmetrically in an arc shape in front of the lens of the image acquisition device.
[0139] Optionally, at least one diffuser layer may be a frosted sheet.
[0140] Optionally, the distance D between the surface of at least one diffuser layer near the lens of the image acquisition device and the lens of the image acquisition device satisfies: 0mm < D ≤ 2mm.
[0141] In one embodiment, the acquisition module 1020 is further configured to acquire at least one image from each of multiple different angles using an image acquisition device, thereby obtaining multiple images. Optionally, the exposure time, gain, and aperture of the image acquisition device are kept constant, and at least one image is acquired from each of the aforementioned five different directions, thereby obtaining multiple images.
[0142] In one embodiment, the generation module 1030 is further configured to perform averaging on multiple images to generate a corrected image.
[0143] In one embodiment, the different angles include the forward direction of the lens of the image acquisition device facing the calibration reference, and four directions at a preset angle to the forward direction: up, down, left, and right. The preset angle θ is no greater than 45 degrees. A non-transitory computer-readable storage medium, when the instructions in the storage medium are executed by the processor of the aforementioned electronic device 900, enables the electronic device 900 to execute an image acquisition method. The image acquisition method includes: adjusting the positional relationship between the light source and the calibration reference, and adjusting the direction of the light source illuminating the calibration reference so that the illuminance of different areas on the calibration reference meets a preset uniformity condition; acquiring at least one image of the calibration reference using the image acquisition device to be calibrated when the uniformity condition is met; obtaining a calibration image based on the at least one image, the calibration image being used to perform lens shading correction on the image acquisition device.
[0144] All of the above-mentioned optional technical solutions can be combined in any way to form optional embodiments of this application, and will not be described in detail here.
[0145] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0146] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0147] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.
[0148] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0149] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0150] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program verification codes, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0151] It should be noted that in the description of this application, the terms "first," "second," "third," etc., are used for descriptive purposes only and should not be construed as indicating or implying relative importance. Furthermore, in the description of this application, unless otherwise stated, "a plurality of" means two or more.
[0152] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Any modifications or equivalent substitutions made within the spirit and principles of this application should be included within the protection scope of this application.
Claims
1. An image acquisition system, characterized in that, include: Light source, calibration reference, illuminance measuring device, and image acquisition device to be calibrated. The illuminance measuring device is used to detect the illuminance in different areas of the calibration reference. The light source is configured to adjust its positional relationship with the calibration reference and the direction in which it illuminates the calibration reference, so that the illuminance of the light emitted by the light source in different areas of the calibration reference meets a preset uniformity condition. The image acquisition device is configured to acquire at least one image of the calibration reference after determining that the illuminance of the light emitted by the light source in different areas of the calibration reference meets the uniformity condition. The at least one image is used to obtain a calibration image, which is used to calculate calibration parameters for the image acquisition device. The calibration parameters are stored in the image acquisition device and are called when the image acquisition device subsequently captures images to perform lens shading correction on the image acquisition device.
2. The image acquisition system according to claim 1, characterized in that, The image acquisition device is positioned on the normal line passing through the center point of the calibration reference object, and the light source includes multiple sub-light sources, which are symmetrically arranged about the normal line as an axis.
3. The image acquisition system according to claim 1, characterized in that, The image acquisition device is positioned between the at least one light source and the calibration reference.
4. The data acquisition system according to claim 1, characterized in that, The acquisition system also includes at least one diffuser layer, which is disposed in front of the lens of the image acquisition device.
5. The image acquisition system according to claim 4, characterized in that, The at least one diffuser layer comprises multiple flexible diffusers configured to be arranged symmetrically in an arc shape in front of the lens of the image acquisition device.
6. The data acquisition system according to claim 4, characterized in that, The at least one diffuser layer is a frosted sheet.
7. The image acquisition system according to claim 4, characterized in that, The distance D between the surface of the at least one diffuser layer near the lens of the image acquisition device and the lens of the image acquisition device satisfies: 0mm < D ≤ 2mm.
8. The image acquisition system according to any one of claims 1-7, characterized in that, The acquisition system also includes a controller, which is configured to adjust the positional relationship between the light source and the calibration reference object and the direction in which the light source illuminates the calibration reference object via a driving device, so that the illuminance of the light emitted by the light source in different areas of the calibration reference object meets the uniformity condition.
9. An image acquisition method, characterized in that, The acquisition method is performed by the image acquisition system according to any one of claims 1-8, and the acquisition method includes: Detect and calibrate the illuminance in different areas of a reference object; Adjust the positional relationship between the light source and the calibration reference, and adjust the direction of the light source illuminating the calibration reference so that the illuminance of different areas on the calibration reference meets the preset uniformity condition; After determining that the illuminance of the light emitted by the light source in different areas of the calibration reference meets the uniformity condition, at least one image of the calibration reference is acquired using the image acquisition device to be calibrated. The corrected image is generated based on the at least one image. The corrected image is used to calculate correction parameters for the image acquisition device. The correction parameters are stored in the image acquisition device and are called when the image acquisition device subsequently captures images to perform lens shading correction on the image acquisition device.
10. An electronic device, characterized in that, include: processor; Memory used to store the processor's executable instructions. The processor is used to execute the acquisition method described in claim 9.