Purple fringing measurement and analysis system and method, storage medium, and electronic device
Through the purple edge measurement and analysis system, the angle and position of the light source and camera are adjusted, the purple edge image is obtained and the purple edge information is calculated, which solves the problem of the lack of quantitative research solutions in the existing technology and realizes the improvement of the shooting function and cost of electronic equipment. reduce.
Patent Information
- Application Number
- CN202310687179.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-09
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2043-06-09
AI Technical Summary
The existing technology lacks a solution to quantitatively study the purple fringing phenomenon in images, and cannot effectively evaluate and improve the shooting function of electronic equipment.
A purple edge measurement and analysis system is provided, including a light source part, a measurement control part and a control system. By adjusting the angle and position of the light source and camera, the purple edge image is obtained and the purple edge information is calculated, thereby achieving quantitative research on the shooting function of electronic equipment.
Provide a stable purple-fringed shooting environment for different electronic devices, improve the digital imaging function of the camera through quantitative research results, reduce labor costs and simulate the actual scene spectrum, and comprehensively evaluate the purple-fringing phenomenon.
Smart Images

Figure CN117714663B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of image processing, and in particular to a purple fringing measurement and analysis system and method, a storage medium, and an electronic device. Background Art
[0002] Image purple fringing exists in digital imaging electronic devices such as digital cameras and surveillance cameras. It usually appears at the junction of high light and low light when the contrast of the subject in the image is large. The object appears in a color that does not belong to the object, usually purple. The larger the field of view of the camera, the higher the probability of purple fringing, and the more obvious the purple fringing phenomenon will be. There are two reasons for the formation of purple fringing. On the one hand, due to the different optical path differences of light of different wavelengths passing through the lens, the degree of light deflection is different, and it converges to different points on the optical axis or focuses on different positions on the plane; on the other hand, when there are distinct bright and dark areas in the shooting scene, the exposure measurement of the scene is mainly based on the average brightness of the area, which causes the bright area to accumulate too many photons and leak to the surrounding pixels, which is the halo effect.
[0003] Existing technologies all detect and eliminate purple fringing in images from the perspective of image algorithms, or reduce or eliminate the purple fringing phenomenon in images from the perspective of the optical design of the camera of the electronic device. It is understandable that if the purple fringing phenomenon of each electronic device can be quantitatively studied, the shooting function of the electronic device can be judged based on the quantitative research results or the shooting function of the electronic device can be further improved through software and hardware design, etc. However, the existing technology currently lacks a solution for quantitative research on the purple fringing phenomenon. Summary of the invention
[0004] In order to solve the problem of lack of a solution for quantitative research on the purple fringing phenomenon in the above-mentioned purple fringing images, the present application provides a purple fringing measurement and analysis system and method, a storage medium, and an electronic device.
[0005] In a first aspect, the present application provides a purple fringing measurement and analysis system, including a light source unit, a measurement control unit and a control system; the light source unit is used to provide the spectrum required for the tested device to capture a purple fringing image; the measurement control unit is used to adjust the tested device to a first angle and a first position; the control system is used to obtain a purple fringing image captured by the tested device at the first angle and the first position, and obtain corresponding purple fringing information based on the purple fringing image.
[0006] Based on the above scheme, a relatively stable purple-fringing shooting environment can be provided for different electronic devices with shooting functions, so as to conduct a quantitative study on images with purple-fringing phenomenon captured by different electronic devices, and then improve the digital imaging function of cameras of different electronic devices based on the quantitative research results.
[0007] In a possible implementation of the first aspect above, the first angle is that a shooting plane of the camera of the device under test is relatively parallel to the light source panel of the light source part; the first position is a position where the device under test maintains a preset distance from the light source part, and the preset distance is a preset multiple of the 35mm equivalent focal length of the camera of the device under test.
[0008] In the present application, the first position may be a position where the device under test and the light source unit maintain a focal length that is 40 times the equivalent focal length of the camera of 35 mm.
[0009] In a possible implementation of the first aspect above, the light source unit includes at least one sub-light source and a light source adjustment system; the light source adjustment system is used to provide a spectrum required for the tested device to capture a purple-fringed image by adjusting illumination parameters of the multiple sub-light sources, and the illumination parameters include color temperature and / or brightness.
[0010] In the present application, the sub-light source may be an LED lamp, and the color temperature, brightness and other parameters of these LED lamps may be adjusted by the light source adjustment system to simulate the spectrum of a scene where the purple fringing phenomenon is prone to occur. Alternatively, the cold light and warm light color temperature LED lamps may be mixed by pulse width modulation (PWM) dimming technology, and the brightness of the cold light LED lamp and the warm light LED lamp may be adjusted respectively to achieve the adjustment of the color temperature of the light source.
[0011] In a possible implementation of the first aspect above, the measurement control unit includes a clamping device and a motion track; the clamping device is used to clamp the device under test; the motion track is used to provide a moving path for the device under test to adjust the device under test to a first angle and a first position.
[0012] In the present application, the motion track includes X, Y, and Z axis motion tracks. The measurement control unit also includes a control unit for controlling the switch of the clamping device and for controlling the clamping device to clamp the device under test to a preset position on the motion track to achieve automated measurement and reduce labor costs.
[0013] In a possible implementation of the first aspect above, the control system is used to obtain a purple-fringed image of the device under test captured at a first angle and a first position in a preset capture mode.
[0014] In a possible implementation of the first aspect above, the preset shooting mode includes a combination of any one or more modes of a main camera lens, a wide-angle camera lens, a telephoto camera lens, various preset exposure times, and various preset fields of view.
[0015] In this application, the preset shooting modes are: switching different cameras, for example, you can switch between main camera, wide angle, telephoto and multiple lenses, set different exposure times, for example, you can set the exposure time to 1 / 60 second, 1 / 125 second, 1 / 250 second, etc.; set different fields of view, for example, you can set the field of view to 30 degrees, 60 degrees, 90 degrees, etc. You can obtain a purple-fringed image according to any combination of one or more preset modes.
[0016] In a possible implementation of the first aspect above, the control system is used to: obtain a first color offset, a second color offset, and a purple fringing threshold based on a color gamut of the purple-fringed image; obtain a purple-fringing area based on a difference between an intersection of the first color offset and the second color offset and the purple-fringing threshold; and integrate the purple-fringing area to obtain quantitative information of the purple fringing.
[0017] In this application, the purple fringing threshold is an empirical value that can be obtained by visual judgment.
[0018] In a possible implementation of the first aspect, the first color offset is an offset of a red channel with respect to a green channel with respect to a pixel; and the second color offset is an offset of a blue channel with respect to a green channel with respect to a pixel.
[0019] In a possible implementation of the first aspect above, the first color offset is determined based on the difference between the grayscale value of the red channel and the grayscale value of the green channel at a specific pixel position, and the number of bits of the color gamut of the camera of the device under test; the second color offset is determined based on the difference between the grayscale value of the blue channel and the grayscale value of the green channel at the specific pixel position, and the number of bits of the color gamut of the camera of the device under test.
[0020] In the present application, the first color offset is determined based on the difference between the grayscale value of the red channel and the grayscale value of the green channel at a specific pixel position, divided by the number of bits of the color gamut of the camera of the tested device; the second color offset is determined based on the difference between the grayscale value of the blue channel and the grayscale value of the green channel at a specific pixel position, divided by the number of bits of the color gamut of the camera of the tested device.
[0021] In a possible implementation of the first aspect, the purple fringing measurement and analysis system further includes a marker card, which is used to verify whether a shooting surface of a camera of the device under test remains relatively parallel to a panel of the light source unit.
[0022] In the present application, the style of the mark card can be set to be a rectangle of the same size as the target, and a cross mark is set in the middle of the mark card.
[0023] In a possible implementation of the first aspect above, a method for verifying whether the shooting surface of the camera of the device under test and the panel of the light source part remain relatively parallel based on a mark card includes: when it is determined that the mark of the mark card in the camera picture of the device under test coincides with the default mark in the camera picture of the device under test, it is determined that the shooting surface of the camera of the device under test and the panel of the light source part remain relatively parallel.
[0024] In the present application, when it is determined that the crosshairs in the camera image of the device under test coincide with the crosshairs in the default camera of the device under test, it can be determined that the shooting surface of the camera of the device under test remains relatively parallel to the panel of the light source part.
[0025] In a possible implementation of the first aspect above, the method of adjusting the device under test to the first angle includes: moving the device under test on a motion track; when the device under test and the light source part are set to multiple preset distances, the angle at which the mark of the label card in the camera picture of the device under test and the mark of the default camera of the device under test both coincide with each other is taken as the first angle.
[0026] In the present application, the plurality of preset distances may be a preset long distance and a preset short distance. For example, the preset long distance may be 50 cm, and the preset short distance may be 20 cm.
[0027] In a second aspect, the present application provides a purple fringing measurement and analysis method, which is applied to the first aspect and any possible implementation of the purple fringing measurement and analysis system of the first aspect, the method comprising: adjusting the device under test to a first angle and a first position based on a measurement control unit; providing a spectrum required for the device under test to capture a purple fringing image based on a light source unit; acquiring a purple fringing image captured by the device under test at the first angle and the first position based on a control system, and acquiring corresponding purple fringing information based on the purple fringing image.
[0028] In a third aspect, the present application provides a computer-readable storage medium, on which instructions are stored. When the instructions are executed on an electronic device, the electronic device implements the purple fringing measurement and analysis method in the second aspect.
[0029] In a fourth aspect, the present application provides an electronic device, comprising: a memory for storing instructions executed by one or more processors of the electronic device; and a processor, which is one of the processors of the electronic device, for executing the instructions stored in the memory to implement the purple fringing measurement and analysis method in the second aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] Figure 1 is a schematic diagram showing a scenario of a purple fringing measurement and analysis system according to some embodiments of the present application;
[0031] Figure 2is a schematic diagram showing comparison of spectra of four light sources that are prone to purple fringing according to some embodiments of the present application;
[0032] Figure 3 is a schematic diagram showing a cross mark card according to some embodiments of the present application;
[0033] Figure 4 is a schematic flow chart showing a method for ensuring that a shooting surface of a mobile phone camera and a light source panel are relatively parallel according to some embodiments of the present application;
[0034] Figure 5 is a schematic diagram showing a process of measuring and analyzing purple fringing data according to some embodiments of the present application;
[0035] Figure 6 A schematic diagram of a purple-fringed image is shown according to some embodiments of the present application. DETAILED DESCRIPTION
[0036] The illustrative embodiments of the present application include, but are not limited to, a purple fringing measurement and analysis system and method, a storage medium, and an electronic device.
[0037] The technical solution of the present application is introduced below in conjunction with the accompanying drawings.
[0038] As mentioned above, existing technologies all detect and eliminate the purple fringing phenomenon in images from the perspective of image algorithms or camera optical design, but there is no technical means to establish a criterion for judging the purple fringing phenomenon of images captured by cameras of electronic devices and to conduct a quantitative study on the purple fringing phenomenon. To this end, the present application provides a purple fringing measurement and analysis system, which can provide a relatively stable purple fringing shooting environment for different electronic devices with shooting functions, thereby conducting a quantitative study on images with purple fringing captured by different electronic devices, and then improving the digital imaging function of cameras of different electronic devices based on the quantitative research results.
[0039] It can be understood that the electronic device for performing purple fringing measurement and analysis involved in the embodiments of the present application can be an electronic device with a camera function, including but not limited to mobile phones, tablets, PCs, large screens, wearable devices, car computers, etc. For the sake of ease of description, the technical solution of the present application is introduced below using the electronic device as a mobile phone as an example.
[0040] Specifically, for example, in some embodiments, the purple fringing measurement and analysis system may include a light source unit and a measurement control unit, wherein the light source unit is used to provide a plurality of spectra that are prone to purple fringing phenomenon for the measurement environment; the measurement control unit is used to adjust the angle and position between the mobile phone camera and the light source, and is used to capture purple fringing images.
[0041] For example, Figure 1A schematic diagram of a scenario of a purple fringing measurement and analysis system is shown. In this scenario, the light source unit includes a light source and a target. The target can be attached to the light source and is used to calibrate the position of the camera of the device under test during the measurement process so that the camera of the device under test is parallel to the light source. The light source is used to provide a spectrum in which the purple fringing phenomenon is prone to occur in different scenarios. In actual measurement, by changing parameters such as the color temperature and brightness of the light source, a variety of spectra in which the purple fringing phenomenon is prone to occur during shooting can be provided for the device under test. The measurement control unit includes a clamping device and a motion track of the device under test. Before controlling the device under test to shoot a purple fringed image, the distance and angle between the camera of the device under test and the light source can be adjusted by controlling the clamping device to move on the motion track, so as to calibrate the size and angle of the purple fringed image shot by the device under test.
[0042] It is understood that in some embodiments of the present application, in order to eliminate the interference of other light sources other than the light source when the tested device captures the purple-fringed image, the entire measurement process needs to be performed in a dark room. The dark room environment mentioned in the embodiments of the present application includes a lightless environment and any environment without other interfering light sources other than the light source.
[0043] It can be understood that in some embodiments of the present application, the measurement control unit may also include a control unit for controlling the switch of the clamping device, and for controlling the clamping device to clamp the tested device and move it to a preset position on the motion track, thereby realizing automated measurement and reducing labor costs.
[0044] It can be understood that in some embodiments of the present application, a plurality of LED lamps (sub-light sources) may be provided in the light source, and the number of LED lamps may be set according to actual needs. The light source unit may also include a light source adjustment system, and the color temperature, brightness and other parameters of these LED lamps may be adjusted by the light source adjustment system, so as to simulate the spectrum of scenes prone to purple fringing. For example, the spectrum of scenes prone to purple fringing includes indoor signboard spectrum, indoor lighting spectrum, window spectrum and outdoor sunlight spectrum.
[0045] Specifically, Figure 2 The following are comparisons of various spectra showing the purple fringing phenomenon that is likely to occur when the tested device is actually shooting. Figure 2 As shown, the ordinate represents the absorbance (Absorbance Unit, au) of the four light source spectra, and the abscissa represents the wavelength of the four light source spectra. Figure 2The absorbance of the window spectrum and the indoor lighting spectrum increases with the increase of wavelength. When the wavelength is 450nm, the absorbance reaches a peak of 1.0au, and then the absorbance decreases with the increase of wavelength; when the wavelength is 480nm, the absorbance reaches a valley of 0.25au, and then the absorbance increases with the increase of wavelength; when the wavelength is 590nm, the absorbance reaches another peak of 1.0au, and then the absorbance decreases with the increase of wavelength. The absorbance of the outdoor solar spectrum increases with the increase of wavelength. When the wavelength is 460nm, the absorbance reaches a peak of 0.82au, and then the absorbance fluctuates and decreases with the increase of wavelength. The absorbance of the indoor light sign spectrum increases with the increase of wavelength. When the wavelength is 450nm, the absorbance reaches a peak of 0.9au, and then the absorbance decreases with the increase of wavelength; when the wavelength is 480nm, the absorbance reaches a valley of 0.25au, and then the absorbance increases with the increase of wavelength; when the wavelength is 530nm, the absorbance reaches another peak of 0.6au, and then the absorbance fluctuates and decreases with the increase of wavelength.
[0046] For example, in some embodiments, the spectrum of scenes prone to purple fringing can be simulated through PWM dimming, thyristor dimming and other technologies. Taking PWM dimming as an example, the duty cycle of the PWM signal in the light source can be adjusted to change the average current of the LED lamp in the light source to adjust the brightness of the light source. Alternatively, PWM dimming technology adjusts the brightness of the cold light LED lamp and the warm light LED lamp by mixing two color temperatures of cold light and warm light, respectively, to adjust the color temperature of the light source. By adjusting the color temperature, brightness and other parameters of the LED lamp in the light source, multiple spectrums of scenes prone to purple fringing can be simulated.
[0047] In addition, it can be understood that the clamping device of the measurement and control part can adopt an air suction end clamping structure, and use the suction force formed by the negative pressure in the suction cup to clamp the device under test. It is mainly used to clamp the device under test with a large shape and moderate thickness. The clamping device of the measurement and control part can also adopt a magnetic suction end clamping structure, which can attract the ferromagnetic device under test by connecting the current in the coil of the electromagnetic suction cup to generate magnetic force. The specific structure of the clamping device of the measurement and control part in this application can be set as needed and is not limited here.
[0048] In addition, it can be understood that the motion track of the measurement control unit can include X, Y, and Z axis motion tracks, and the couplings of each axis can be connected to a servo motor, and the data of the servo motor can be adjusted to realize the automatic movement of the clamping device of the tested device on the motion track; or, the couplings of each axis in the X, Y, and Z axis motion tracks can also be connected to a rotating disk, and the rotating disk can be manually adjusted to realize the manual movement of the clamping device of the tested device on the motion track. The specific structure and motion mode of the motion track of the measurement control unit in this application can be set as needed, and are not limited here.
[0049] In addition, it can be understood that after the tested device captures a purple-fringed image, the purple-fringed image can be quantitatively analyzed. For example, the purple-fringed area can be calculated and obtained by quantifying the degree of pixel offset of the red channel and the blue channel compared to the green channel in the color domain, so as to study the shooting functions of different tested devices.
[0050] In addition, in order to eliminate the influence of the angle difference between the camera and the light source on the captured purple-fringed image when different electronic devices or the same electronic device are photographed at different times, and to maintain the uniformity of the shooting environment, in some embodiments, when the device under test is used to shoot the purple light image, it is necessary to adjust the relative parallelism between the shooting surface of the camera of the device under test and the light source panel. For example, still taking the mobile phone as an example, a cross mark card of the same size as the target can be placed on the card slot in front of the light source, such as Figure 3 As shown, there is a cross mark in the middle of the mark card, and the cross mark in the mobile phone camera image can be ensured to coincide with the cross mark of the mobile phone camera by adjusting the mobile phone and the device clamping device, so as to achieve relative parallelism between the shooting surface of the camera of the tested device and the light source panel.
[0051] For example, Figure 4 The figure shows a flow chart of adjusting the shooting surface of the camera of the device under test to be relatively parallel to the light source panel, taking a mobile phone as an example. Figure 4 As shown, the method includes:
[0052] S101: The clamping device clamps the mobile phone and roughly adjusts the camera of the mobile phone to be parallel to the light source.
[0053] In some embodiments, the clamping device can hold the mobile phone and move it on the X, Y, and Z axis motion tracks, and based on the results of human eye observation, the mobile phone camera can be roughly adjusted to be parallel to the light source.
[0054] S102: Place a cross mark card in front of the card slot of the light source.
[0055] In some embodiments, the size of the cross mark placed in front of the card slot of the light source can be consistent with the size of the target, such as Figure 3 As shown, a cross mark can be set in the center of the cross mark card.
[0056] The embodiments of the present application do not limit the style of the label card. For example, a label card as large as the target can be divided into 9 areas of equal size to form a nine-square grid label card; or a circular label card can be set in the center of the target, and a center point can be set at the center of the circle, etc.
[0057] S103: Move the clamping device so that the mobile phone is at a first preset distance from the light source.
[0058] In some embodiments, the position of the mobile phone and the clamping device is moved on the X, Y, and Z axis motion tracks so that the mobile phone and the clamping device are at a first preset distance from the light source, such as a preset long distance. The preset long distance can be 50 cm, or it can be set to other values according to actual needs.
[0059] S104: Adjust the position of the mobile phone up, down, left, and right to ensure that the crosshairs in the camera image coincide with the default crosshairs of the camera.
[0060] In some embodiments, the clamping device and the mobile phone are moved on the X, Y, and Z axis motion tracks, and the default crosshairs in the mobile phone camera are turned on, so that the crosshairs in the mobile phone camera screen (the cross in the crosshairs card) coincide with the default cross in the mobile phone camera.
[0061] In some embodiments, when the label card is set to a nine-square grid style, the nine-square grid composition of the mobile phone camera can be turned on so that the nine-square grid lines in the camera image coincide with the default nine-square grid composition in the mobile phone camera.
[0062] In some embodiments, when the label card is set to a circle, the default crosshairs in the mobile phone camera can be turned on so that the center point of the circle in the camera image coincides with the default cross intersection point in the mobile phone camera.
[0063] S105: Move the mobile phone forward to a position at a second preset distance from the light source, and determine whether the crosshairs in the camera image coincide with the default crosshairs of the camera.
[0064] In some embodiments, the clamping device and the mobile phone are moved on the X-axis motion track to reduce the distance between the clamping device and the mobile phone and the light source, so that the clamping device and the mobile phone and the light source are at a second preset distance, for example, a preset close distance, which can be 20 cm, or can be set to other values according to actual needs. It is determined whether the cross in the mobile phone camera image (the cross in the cross mark card) coincides with the default cross in the mobile phone camera. If they coincide, it indicates that the shooting surface of the mobile phone camera is relatively parallel to the light source panel, and the process ends; if they do not coincide, it indicates that the shooting surface of the mobile phone camera is not relatively parallel to the light source panel, and go to step S106.
[0065] S106: Adjust the tilt and rotation angle of the mobile phone to ensure that the crosshairs in the camera image coincide with the default crosshairs of the camera.
[0066] Adjust the tilt and rotation angle of the phone, for example, you can adjust the elevation and depression angles of the phone, or adjust the phone clockwise so that the crosshairs in the phone camera screen coincide with the default crosshairs of the phone camera.
[0067] In some embodiments, in order to reduce measurement errors, it is necessary to ensure that when the mobile phone is at a first preset distance and a second preset distance from the light source, the crosshairs in the mobile phone camera image coincide with the cross of the default camera. Only then can the calibration be considered complete and the shooting surface of the mobile phone camera remain relatively parallel to the light source panel.
[0068] In some embodiments, after determining that the crosshairs in the camera image coincide with the default crosshairs of the camera, the process may proceed to step S103, that is, the position of the mobile phone at a first preset distance from the light source, and the shooting surface of the mobile phone camera and the light source panel may be adjusted to be relatively parallel.
[0069] Through the above adjustment method, the relative parallelism between the shooting surface of the mobile phone camera and the light source panel can be ensured, thereby avoiding the influence of the angle difference between the shooting surface of the mobile phone camera and the light source panel on the captured purple-edge image.
[0070] Combine the following Figure 5 , analyze the purple fringing data captured by different cameras, and thus analyze the shooting functions of different electronic devices. Figure 5 A schematic diagram of a purple fringing measurement and analysis process is shown, including:
[0071] S201: Calibrate the camera position.
[0072] Calibrate the shooting surface of the mobile phone camera to keep it relatively parallel to the light source panel, which can be referred to step S101 to step S106, and will not be repeated here. After the calibration is completed, replace the cross mark card placed on the card slot in front of the light source with a fully transparent test chart.
[0073] S202: Setting light source parameters (spectrum, color temperature, brightness).
[0074] In an environment where the influence of interfering light sources is eliminated, such as in a dark room, the spectrum, color temperature, brightness and other parameters of the LED lamp in the light source can be set by the control system as described above, and the following can be obtained: Figure 2 The light source spectrum shown is prone to purple fringing when shooting with a mobile phone.
[0075] In some embodiments, the spectrum of scenes prone to purple fringing can also be simulated through PWM dimming, thyristor dimming and other technologies. For example, the brightness of the light source can be adjusted by adjusting the duty cycle of the PWM signal in the light source; or the brightness of the cold light LED lamp and the warm light LED lamp can be adjusted separately to achieve the adjustment of the color temperature of the light source.
[0076] S203: Setting the mobile phone to be clamped on the X, Y, and Z axis automated motion tracks, at a preset multiple equivalent focal length from the target.
[0077] In some embodiments, in order to avoid the influence of the size of the test chart in the shooting pictures of different cameras on the analysis of purple fringing data, the mobile phone and its clamping device are moved on the X, Y, and Z axis motion tracks so that the distance between the mobile phone and the target is a preset multiple of the 35mm equivalent focal length of the mobile phone's camera. In some embodiments, the distance between the mobile phone and the target can be set to 40 times the 35mm equivalent focal length of the mobile phone's camera. In this way, it can be ensured that the imaging sizes of the test charts taken by different cameras are equal, and the subsequent purple fringing data analysis is based on the purple fringing that appears in the imaging of the same size.
[0078] S204: Test the purple fringing of the main camera, wide-angle camera, and telephoto camera in professional mode with different exposure times and fields of view.
[0079] In some embodiments, a purple-fringed image can be captured in a preset shooting mode, for example, the preset mode is: switching different cameras, the main camera, wide-angle, telephoto lens can be switched, different exposure times can be set, for example, the exposure time can be set to 1 / 60 second, 1 / 125 second, 1 / 250 second, etc.; different fields of view can be set, for example, the field of view can be set to 30 degrees, 60 degrees, 90 degrees, etc. According to any combination of one or more preset modes, a purple-fringed image can be obtained by a fully automatic shooting method.
[0080] The purple-fringing conditions obtained from different angles mentioned in the embodiments of the present application are merely exemplary. In some embodiments, other performances of different cameras may also be tested, such as selecting different aperture, resolution, frame rate and other parameters of the camera to obtain different purple-fringed images.
[0081] Since the test chart placed on the card slot in front of the light source is fully transparent, the light source can be emitted through the inner frame of the target. In the images taken by different cameras, the inner frame of the target will have different degrees of purple fringing in the horizontal and vertical directions (the four oblique edges of the test chart), and the purple fringing images of the four oblique edges in the horizontal and vertical directions are obtained respectively. For example, refer to Figure 6 As shown in (a), 6(c), 6(e), and 6(g).
[0082] Figure 6(a) is the grayscale value of the color channel of the test card at the horizontal bevel 1 (purple-edge image), the horizontal axis represents the pixel position, and the vertical axis represents the grayscale value. Figure 6 As shown in (a), when the pixel position is 0 to 120, the grayscale value of the red channel rises in a fluctuating manner, and the grayscale value of the red channel is greater than the grayscale values of the green channel and the blue channel. The grayscale values of the green channel and the blue channel are comparable in size and show a fluctuating upward trend. Starting from the pixel position of 120, the grayscale values of the red channel, the blue channel, and the green channel are the same, with a size of 55%. When the pixel position is 120 to 125, the grayscale values of the red channel, the blue channel, and the green channel rise in a straight line, and when the pixel position is 125, the grayscale values of the red channel, the blue channel, and the green channel reach 100%.
[0083] Figure 6 (c) is the grayscale value of the color channel of the test card at the horizontal oblique edge 2 (purple-edge image), the horizontal axis represents the pixel position, and the vertical axis represents the grayscale value. Figure 6 As shown in (c), when the pixel position is 0 to 65, the grayscale values of the red channel, the blue channel, and the green channel are the same, and when the pixel position is 0 to 60, the grayscale values of the red channel, the blue channel, and the green channel are 100%. When the pixel position is 60 to 65, the grayscale values of the red channel, the blue channel, and the green channel decrease linearly, and when the pixel position is 65, the grayscale values of the red channel, the blue channel, and the green channel are 55%. When the pixel position is 65 to 190, the grayscale values of the red channel, the blue channel, and the green channel show a fluctuating downward trend.
[0084] Figure 6 (e) is the grayscale value of the color channel of the test image card at the vertical oblique edge 3 (purple-edge image), the horizontal axis represents the pixel position, and the vertical axis represents the grayscale value. Figure 6 As shown in (e), when the pixel position is 0 to 90, the grayscale value of the red channel shows a fluctuating upward trend. When the pixel position starts from 90, the grayscale value of the red channel rises linearly, and when the pixel position is 95 to 190, the grayscale value of the red channel reaches 100%. When the pixel position is 25 to 85, the grayscale values of the green channel and the blue channel are comparable and show a fluctuating upward trend.
[0085] Figure 6 (g) is the grayscale value of the color channel of the test image card at the vertical diagonal edge 4 (purple-edge image), the horizontal axis represents the pixel position, and the vertical axis represents the grayscale value. Figure 6As shown in (g), when the pixel position is 0 to 70, the grayscale values of the red channel and the green channel are the same, which is 100%. When the pixel position is 70 to 75, the grayscale value of the red channel decreases linearly, and when the pixel position is 75, the grayscale value of the red channel reaches 50%. When the pixel position is 75 to 190, the grayscale values of the red channel, green channel, and blue channel show a fluctuating downward trend.
[0086] S205: Calculate and analyze purple fringing data of lenses with different exposure times and different fields of view.
[0087] In the embodiment of the present application, based on the purple fringing conditions of different exposure times and different fields of view, for example, the acquired purple fringing image can be used to calculate and analyze the purple fringing data of lenses with different exposure times and different fields of view.
[0088] In some embodiments, based on the purple-fringed images of four oblique edges in the horizontal and vertical directions captured by different cameras and combined with formula (1), the color shift degree of the red channel and the blue channel in the color gamut relative to the green channel with the pixel is calculated.
[0089] It can be understood that the degree of color shift can be used to reflect the severity of color fringing.
[0090]
[0091] Wherein, F(x) represents the grayscale value of a certain pixel position of the red channel R(x) and the blue channel B(x) in the color domain, G(x) represents the grayscale value of a certain position of the green channel in the color domain, and f(x) represents the color shift degree of the red channel and the blue channel with the pixel compared with the green channel in the color domain, wherein the shift amount of the red channel with the pixel compared with the green channel is the first color shift amount, and the shift amount of the blue channel with the pixel compared with the green channel is the second color shift amount. bit The bit indicates the number of bits in the color gamut of the camera being tested.
[0092] In some embodiments, a purple fringing threshold α that can be perceived by the naked eye can be set. The purple fringing threshold α can also be set based on experience. The difference between the intersection of the offset of the red channel and the blue channel with the pixel in the color gamut and α is the purple fringing area. Refer to formula (2), and then integrate the purple fringing area to obtain the quantization result of the purple fringing.
[0093]
[0094] In formula (2), f blue (x) represents the offset of the blue channel relative to the green channel in the color gamut; f red (x) represents the offset of the red channel relative to the green channel in the color gamut; min(fblue (x),f red (x)) represents the intersection of the red channel and the blue channel in the color gamut compared to the green channel with the offset of the pixel; α is the purple fringing threshold; (min(f blue (x),f red (x))-α) represents the purple fringing area, and A represents the quantization result of the purple fringing.
[0095] For example, Table 1 shows the color edge conditions of four oblique edges, which will be analyzed below in conjunction with the accompanying drawings and will not be described in detail here.
[0096]
[0097] Table 1
[0098] For example, you can refer to Figure 6 (b), 6(d), 6(f), 6(h), calculate and analyze the purple fringing data.
[0099] Figure 6 (b) is the color shift degree of the red channel and the blue channel compared with the green channel in the color gamut of the test card at the horizontal bevel 1. The horizontal axis represents the pixel position and the vertical axis represents the gray value. Figure 6 As shown in (b), when the pixel position is 0 to 100, the grayscale value of the red channel fluctuates and rises, and when the pixel position is 100, the grayscale value of the red channel reaches 7%. When the pixel position is 100 to 110, the grayscale value of the red channel rises linearly, and when the pixel position is 110, the grayscale value of the red channel reaches a peak value of 38%. When the pixel position is 110 to 120, the grayscale value of the red channel drops linearly, and when the pixel position is 120, the grayscale value of the red channel reaches the lowest value of 0%. When the pixel position is 120 to 190, the grayscale value of the red channel tends to 0%. Among them, the degree of color shift of the pixel also indicates the severity of the color edge. For example, according to formula (1) and referring to Table 1, the test image is stuck in the horizontal oblique edge 1, the blue color edge is 4.42 (0.34), and the red color edge is 13.25 (1.03).
[0100] like Figure 6 As shown in (b), when the pixel position is 0 to 100, the grayscale value of the blue channel fluctuates and decreases, and when the pixel position is 100, the grayscale value of the blue channel reaches a minimum value of -5%. When the pixel position is 100 to 120, the grayscale value of the blue channel rises linearly, and when the pixel position is 120, the grayscale value of the blue channel reaches a maximum value of 28%.
[0101] like Figure 6As shown in (b), the purple fringing threshold α is set to the shadow part (part A and part B), and part A is the intersection of the offset of the red channel and the blue channel with the pixel compared to the green channel in the color gamut. The difference between the purple fringing threshold α and part A is the purple fringing area (part B). According to formula (2), the quantization result of the purple fringing can be obtained by integrating the purple fringing area (part B). For example, referring to Table 1, the test image is stuck in the horizontal oblique edge 1, and the purple color fringing is 4.42 (0.34).
[0102] Figure 6 (d) is the color shift degree of the red channel and the blue channel compared with the green channel in the color gamut of the test card at the horizontal bevel 2. The horizontal axis represents the pixel position and the vertical axis represents the gray value. Figure 6 As shown in (d), when the pixel position is 0 to 50, the gray value of the red channel tends to 1%, when the pixel position is 50 to 70, the gray value of the red channel drops linearly, and when the pixel position is 70, the gray value of the red channel reaches a minimum value of -20%. When the pixel position is 70 to 100, the gray value of the red channel gradually increases, and when the pixel position is 100, the gray value of the red channel reaches a maximum value of 4%. When the pixel position is 100 to 120, the gray value of the red channel gradually decreases, when the pixel position is 120 to 135, the gray value of the red channel gradually increases, and when the pixel position is 135 to 190, the gray value of the red channel gradually decreases to 0%. The severity of the color edge is also indicated by the degree of color shift of the pixel. For example, according to formula (1) and referring to Table 1, when the test image is stuck in the horizontal oblique edge 2, the blue color edge is 9.82 (0.76) and the red color edge is 8.64 (0.67).
[0103] like Figure 6 As shown in (d), when the pixel position is 50 to 70, the grayscale value of the blue channel gradually increases; when the pixel position is 70, the grayscale value of the blue channel reaches a maximum value of 5%; when the pixel position is 70 to 85, the grayscale value of the blue channel gradually decreases; when the pixel position is 85 to 100, the grayscale value of the blue channel gradually increases; when the pixel position is 100 to 150, the grayscale value of the blue channel fluctuates between 2% and -2%.
[0104] like Figure 6 As shown in (d), the purple fringing threshold α is set, and the difference between the purple fringing threshold α and the intersection of the offset of the red channel and the blue channel with the green channel in the color domain is the purple fringing area. The quantization result of the purple fringing can be obtained by integrating the purple fringing area. For example, according to formula (2) and referring to Table 1, the test image is stuck in the horizontal oblique edge 2, and the purple color fringing is 4.59 (0.36).
[0105] Figure 6(f) is the color shift degree of the red channel and the blue channel compared with the green channel in the color gamut of the test card at the vertical hypotenuse 3. The horizontal axis represents the pixel position and the vertical axis represents the gray value. Figure 6 As shown in (f), when the pixel position is 0 to 70, the grayscale value of the red channel rises in a fluctuating manner, and when the pixel position is 70, the grayscale value of the red channel is 4.5%. When the pixel position is 70 to 75, the grayscale value of the red channel decreases, and when the pixel position is 75, the grayscale value of the red channel is 2%. When the pixel position is 75 to 80, the grayscale value of the red channel rises linearly, and when the pixel position is 80, the grayscale value of the red channel reaches a maximum value of 5.5%. When the pixel position is 80 to 90, the grayscale value of the red channel drops linearly, and when the pixel position is 90, the grayscale value of the red channel is 0.5%, and when the pixel position is 90 to 190, the grayscale value of the red channel tends to 0.5%. The severity of the color edge is also indicated by the degree of color shift of the pixel. For example, according to formula (1) and referring to Table 1, the test image is stuck in the vertical oblique edge 3, the blue color edge is 8.08 (0.63), and the red color edge is 0.00 (0.00).
[0106] like Figure 6 As shown in (f), when the pixel position is 30 to 70, the grayscale value of the blue channel rises in a fluctuating manner, and when the pixel position is 70, the grayscale value of the blue channel is 1.5%. When the pixel position is 70 to 80, the grayscale value of the blue channel drops linearly, and when the pixel position is 80, the grayscale value of the blue channel is -2.5%. When the pixel position is 80 to 85, the grayscale value of the blue channel rises linearly, and when the pixel position is 85, the grayscale value of the blue channel reaches a maximum value of 5%.
[0107] like Figure 6 As shown in (f), part C is the purple edge area, and the quantization result of the purple edge can be obtained by integrating the purple edge area. For example, according to formula (2) and referring to Table 1, the test image is stuck in the vertical oblique edge 3, and the purple color edge is 0.00 (0.00).
[0108] Figure 6 (h) is the color shift degree of the red channel and the blue channel compared with the green channel in the color gamut of the test card at the vertical hypotenuse 4. The horizontal axis represents the pixel position and the vertical axis represents the gray value. Figure 6As shown in (h), when the pixel position is 0 to 65, the grayscale value of the red channel is 0.5%. When the pixel position is 65 to 75, the grayscale value of the red channel rises linearly. When the pixel position is 75, the grayscale value of the red channel reaches a maximum value of 12.5%. When the pixel position is 75 to 190, the grayscale value of the red channel decreases in a fluctuating manner and eventually tends to 1%. The severity of the color edge is also indicated by the degree of color shift of the pixel. For example, according to formula (1) and referring to Table 1, the test image is stuck in the vertical oblique edge 4, the blue color edge is 6.00 (0.47), and the red color edge is 9.98 (0.77).
[0109] like Figure 6 As shown in (h), when the pixel position is 75 to 100, the grayscale value of the blue channel decreases from 8% to -1%, and when the pixel position is 100 to 190, the grayscale value of the blue channel gradually increases to approach 0.5%.
[0110] like Figure 6 As shown in (h), the purple fringing threshold α is set to the shadow part (part D and part E), and part E is the intersection of the offset of the red channel and the blue channel with the pixel compared to the green channel in the color gamut. The difference between the purple fringing threshold α and part E is the purple fringing area (part D). The quantization result of the purple fringing can be obtained by integrating the purple fringing area (part D). For example, according to formula (2) and referring to Table 1, the test image is stuck in the vertical oblique edge 4, and the purple color edge is 6.00 (0.47).
[0111] For example, Table 2 shows the average color edge conditions of the four oblique edges of the test chart.
[0112]
[0113] Table 2
[0114] As shown in Table 2, in the acquired purple-fringed image, the average color fringing value of the blue color among the four oblique edges of the test chart is 7.1 (0.55), the average color fringing value of the red color is 8.0 (0.62), and the average color fringing value of the purple color is 3.8 (0.29).
[0115]
[0116] Table 3
[0117] For example, Table 3 shows the maximum color edge conditions of the four oblique edges of the test chart. As shown in Table 3, in the acquired purple-edge image, the maximum color edge value of the blue color among the four oblique edges of the test chart is 9.28 (0.76), the maximum color edge value of the red color is 13.25 (1.03), and the maximum color edge value of the purple color is 6.00 (0.47).
[0118] The above-mentioned purple fringing measurement and analysis system provides a relatively stable purple fringing shooting environment for different electronic devices with shooting functions, so as to quantitatively study the shooting functions of different electronic devices in capturing images with purple fringing. The purple fringing measurement and analysis system adopts a method in which the light source and target are fixed, and the mobile phone and the clamping device are moved. When the purple fringing is measured at a large angle between the mobile phone camera and the light source, the size requirements for the light source panel and the target can be reduced. At the same time, the system adopts a fully automatic shooting method, which can reduce labor costs to the greatest extent. In addition, the light source spectrum is adjustable, which can realize the laboratory realization of the light source spectrum of life scenes, and fully restore the scenes that may actually produce purple fringing.
[0119] In the accompanying drawings, some structural or method features may be shown in a specific arrangement and / or order. However, it should be understood that such a specific arrangement and / or order may not be required. Instead, in some embodiments, these features may be arranged in a manner and / or order different from that shown in the illustrative drawings. In addition, the inclusion of structural or method features in a particular figure does not mean that such features are required in all embodiments, and in some embodiments, these features may not be included or may be combined with other features.
[0120] It should be noted that the units / modules mentioned in the various device embodiments of the present invention are all logical units / modules. Physically, a logical unit / module can be a physical unit / module, or a part of a physical unit / module, or can be implemented as a combination of multiple physical units / modules. The physical implementation of these logical units / modules themselves is not the most important. The combination of functions implemented by these logical units / modules is the key to solving the technical problems proposed by the present invention. In addition, in order to highlight the innovative part of the present invention, the above-mentioned device embodiments of the present invention do not introduce units / modules that are not closely related to solving the technical problems proposed by the present invention, which does not mean that there are no other units / modules in the above-mentioned device embodiments.
[0121] It should be noted that in the examples and description of this patent, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "including one" do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0122] While the present invention has been shown and described with reference to certain preferred embodiments thereof, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the scope of the invention.
Claims
1. A purple fringing measurement and analysis system, characterized in that: It includes a light source part, a measurement control part and a control system; The light source unit is used to provide the spectrum required by the device under test to capture a purple-fringed image; The measurement control unit is used to adjust the device under test to a first angle and a first position; The control system is used to obtain a purple-fringed image of the device under test taken at the first angle and the first position, and obtain corresponding purple-fringed information based on the purple-fringed image; The control system is used for: Based on the color gamut of the purple-fringed image, a first color offset, a second color offset and a purple-fringed threshold are obtained, wherein the first color offset is an offset of a red channel with respect to a green channel with respect to a pixel, and the second color offset is an offset of a blue channel with respect to a green channel with respect to a pixel; Obtaining a purple-fringed area based on a difference between an intersection of the first color offset and the second color offset and the purple-fringed threshold, wherein the intersection is a minimum value between the first color offset and the second color offset; The purple-fringe region is integrated to obtain quantified information of the purple-fringe.
2. The system according to claim 1, characterized in that The first angle is such that a shooting plane of the camera of the device under test and a light source panel of the light source unit remain relatively parallel; The first position is a position where the device under test maintains a preset distance from the light source portion, and the preset distance is a preset multiple of the 35 mm equivalent focal length of the camera of the device under test.
3. The system according to claim 1 or 2, characterized in that: The light source unit includes at least one sub-light source and a light source adjustment system; The light source adjustment system is used to provide the spectrum required by the tested device to capture the purple-fringed image by adjusting the illumination parameters of the plurality of sub-light sources, wherein the illumination parameters include color temperature and / or brightness.
4. The system according to claim 1 or 2, characterized in that: The measurement control unit includes a clamping device and a motion track; The clamping device is used to clamp the device under test; The motion track is used to provide a moving path for the device under test, so as to adjust the device under test to the first angle and the first position.
5. The system according to claim 1 or 2, characterized in that: The control system is used to obtain the purple-fringed image captured by the device under test at the first angle and the first position in a preset shooting mode.
6. The system according to claim 5, characterized in that The preset shooting modes include a combination of any one or more modes under a main camera lens, a wide-angle camera lens, a telephoto camera lens, various preset exposure times, and various preset fields of view.
7. The system according to claim 1, characterized in that The first color offset is determined based on a difference between a grayscale value of the red channel and a grayscale value of the green channel at a specific pixel position, and a number of bits of the color gamut of the camera of the device under test; The second color offset is determined based on a difference between a grayscale value of the blue channel and a grayscale value of the green channel at the specific pixel position, and a number of bits of the color gamut of the camera of the device under test.
8. The system according to claim 1, characterized in that The purple fringing measurement and analysis system further includes a standard card, The mark card is used to verify whether the shooting surface of the camera of the tested device and the panel of the light source unit remain relatively parallel.
9. The system according to claim 8, characterized in that The method of verifying whether the shooting surface of the camera of the device under test and the panel of the light source unit remain relatively parallel based on the standard card includes: When it is determined that the mark of the label card in the camera image of the device under test coincides with the default mark in the camera image of the device under test, it is determined that the shooting surface of the camera of the device under test remains relatively parallel to the panel of the light source unit.
10. The system according to claim 1 or 2, characterized in that: The method of adjusting the device under test to a first angle includes: Moving the device under test on a motion track; When the device under test and the light source unit are set to a plurality of preset distances, an angle at which the mark of the label card in the camera image of the device under test and the mark of the default camera of the device under test both overlap is used as the first angle.
11. A purple fringing measurement and analysis method, characterized in that: Applied to the purple fringing measurement and analysis system according to any one of claims 1 to 10, the method comprising: adjusting the device under test to the first angle and the first position based on a measurement control unit; Providing a spectrum required by the device under test to capture the purple-fringed image based on the light source unit; Acquire the purple-fringed image taken by the device under test at the first angle and the first position based on the control system, and acquire corresponding purple-fringed information based on the purple-fringed image; Wherein, the obtaining corresponding purple fringing information based on the purple fringing image includes: Based on the color gamut of the purple-fringed image, a first color offset, a second color offset and a purple-fringed threshold are obtained, wherein the first color offset is an offset of a red channel with respect to a green channel with respect to a pixel, and the second color offset is an offset of a blue channel with respect to a green channel with respect to a pixel; Obtaining a purple-fringed area based on a difference between an intersection of the first color offset and the second color offset and the purple-fringed threshold, wherein the intersection is a minimum value between the first color offset and the second color offset; The purple-fringe region is integrated to obtain quantified information of the purple-fringe.
12. A computer-readable storage medium, characterized in that: The readable storage medium stores instructions, and when the instructions are executed on an electronic device, the electronic device implements the purple fringing measurement and analysis method described in claim 11.
13. An electronic device, characterized in that: include: a memory for storing instructions to be executed by one or more processors of the electronic device; and a processor, which is one of the processors of the electronic device, configured to execute instructions stored in the memory to implement the purple fringing measurement and analysis method described in claim 11.
Citation Information
Patent Citations
Taste bud gum
AU2007100872A4
Color illumination system for spatial light modulators using multiple double telecentric relays
CA2435858A1
Salient region layered extracting method based on HLS color space
CN103679716A
Method and device for calibrating imaging difference
CN107563987A
Image purple edge correction method for adjustable aperture optical system
CN111199524A
