Method and device for testing signal-to-noise ratio of face recognition camera
Through automated reception and calculation of the signal-to-noise ratio test method of face recognition camera, the high cost and inefficiency problems caused by traditional manual measurement and calculation are solved, and high-quality and efficient signal-to-noise ratio testing is achieved.
Patent Information
- Application Number
- CN202411703979.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-26
- Publication Date
- 2025-02-25
AI Technical Summary
Traditional face recognition signal-to-noise ratio (SNR) testing relies on manual measurement and calculation, resulting in high production costs, low testing efficiency, and the problem of unstandard verification results.
提供一种人脸识别摄像头信噪比测试方法,通过自动接收目标像素和调节因子,获取目标数据,并根据这些数据自动计算信噪比,确定产品是否合格。
It realizes automated signal-to-noise ratio testing, reduces labor costs and time costs, improves testing efficiency, ensures the standardization and accuracy of test results, and meets the demand for efficient and high-quality products in modern manufacturing.
Smart Images

Figure CN119520769A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of computer vision image processing, and in particular to a method and device for testing the signal-to-noise ratio of a face recognition camera. Background Art
[0002] In the fields of high-end photography, scientific research, industrial inspection, etc., customers have extremely high requirements for the imaging quality of face recognition cameras. Signal-to-noise ratio (SNR) testing is one of the important links in quality control. A high signal-to-noise ratio helps reduce image misjudgments and missed detections caused by noise interference. Therefore, in the product production process, in order to improve the accuracy and reliability of face recognition, signal-to-noise ratio (SNR) testing is one of the key elements to ensure that face recognition camera products meet the requirements.
[0003] The traditional face recognition signal-to-noise ratio (SNR) test manually inputs the gain signal and noise signal, and then manually measures the signal brightness values of the 19th and 24th grayscale blocks and the noise signal of the 22nd grayscale block of the 11-level grayscale card to calculate the signal-to-noise ratio (SNR), and then compares it with the standard signal-to-noise ratio (SNR) to screen out unqualified face recognition camera products.
[0004] However, the disadvantages of manual measurement and calculation are high production costs, measurement and calculation vary from person to person, and there may be non-standard verification results, which affects the overall production quality and reduces customer satisfaction with the product. At the same time, when facing a large order volume, a large amount of labor and time costs are required, the efficiency is very low, and the test accuracy is not high, which does not meet the needs of modern manufacturing for efficient and high-quality products. Summary of the invention
[0005] In order to overcome the shortcomings of the prior art, the purpose of the present invention is to provide a face recognition camera signal-to-noise ratio test method and device, which can automatically perform signal-to-noise ratio test on the face recognition camera, and solve the problems of high cost and low test efficiency caused by manual measurement and manual calculation.
[0006] In order to solve the above problems, the present invention is implemented according to the following scheme:
[0007] A method for testing the signal-to-noise ratio of a face recognition camera is provided, including:
[0008] Receive target pixels and target adjustment factors of the camera to be tested;
[0009] Get the target data of the camera to be tested;
[0010] Determining a target signal-to-noise ratio according to the target adjustment factor and the target data;
[0011] A test result of the camera to be tested is determined according to the target pixel and the target signal-to-noise ratio, and the test result is used to determine whether the camera to be tested is a qualified product.
[0012] Compared with the prior art, the beneficial effects of the face recognition camera signal-to-noise ratio testing method of the present invention are as follows: by automatically acquiring target data and then automatically calculating the target signal-to-noise ratio, the signal-to-noise ratio quality of the face recognition camera product is verified to automatically determine whether the face recognition camera product is qualified, thereby ensuring that the face recognition camera products leaving the factory have high-quality production control, thereby improving customer satisfaction with the product, and reducing testing costs and improving testing efficiency.
[0013] Optionally, the camera to be tested includes a sensor;
[0014] The receiving of the target pixel and the target adjustment factor of the camera to be tested includes:
[0015] determining the received sensor pixel as the target pixel;
[0016] When the received adjustment factor is less than or equal to a preset threshold, determining the received adjustment factor as the target adjustment factor;
[0017] When the received adjustment factor is greater than the preset threshold, the adjustment factor is received again until the received adjustment factor is less than or equal to the preset threshold, and the received adjustment factor is determined as the target adjustment factor.
[0018] Optionally, the test requirement is used to indicate the strictness of the test on the camera to be tested; the preset threshold is set according to the test requirement, including:
[0019] Determining a minimum threshold value for indicating a minimum test requirement, wherein the minimum test requirement is used to indicate a minimum stringency of a test on a camera to be tested;
[0020] The preset threshold is determined according to the test requirement and the minimum test requirement.
[0021] Optionally, obtaining target data of the camera to be tested includes:
[0022] Setting the parameters of the camera to be tested to optimal parameters;
[0023] The camera to be tested shoots with the optimal parameters to obtain the target data.
[0024] Optionally, the target data includes sensor data;
[0025] The sensor data includes a gain signal, a first noise signal, a second noise signal, a first signal brightness value, and a second signal brightness value.
[0026] Optionally, the gain signal includes an output signal of the sensor input signal after being amplified;
[0027] The first noise signal includes a random signal output by the sensor when there is no input signal;
[0028] The second noise signal comprises a noise signal of the sensor at a target signal brightness value;
[0029] The first signal brightness value includes a signal brightness value of a first grayscale block, which is used to represent the output signal intensity of the sensor on the first grayscale block;
[0030] The second signal brightness value includes a signal brightness value of a second grayscale block, and is used to represent the output signal intensity of the sensor on the second grayscale block.
[0031] Optionally, determining a test result of the camera to be tested according to the target pixel and the target signal-to-noise ratio includes:
[0032] Determining a signal-to-noise ratio threshold according to the target pixel;
[0033] A test result is determined according to the signal-to-noise ratio threshold and the target signal-to-noise ratio.
[0034] Optionally, determining a test result according to the signal-to-noise ratio threshold and the target signal-to-noise ratio includes:
[0035] When the target signal-to-noise ratio is greater than the signal-to-noise ratio threshold, the test result is a qualified product;
[0036] When the target signal-to-noise ratio is less than or equal to the signal-to-noise ratio threshold, the test result is an unqualified product.
[0037] Optionally, the number of qualified products and the number of unqualified products are determined according to the test results of the camera to be tested;
[0038] The sum of the number of qualified products and the number of unqualified products is determined as the number of test cameras;
[0039] A test report is generated based on the number of qualified products and the number of test cameras, and the test report is the product qualification rate.
[0040] A computer device is also provided, comprising a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, at least one program, a code set or an instruction set is loaded and executed by the processor to implement the signal-to-noise ratio testing method. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 The figure is a flow chart of the signal-to-noise ratio testing method of the present invention. DETAILED DESCRIPTION
[0042] The preferred embodiments of the present invention are described below in conjunction with the accompanying drawings. It should be understood that the preferred embodiments described herein are only used to illustrate and explain the present invention, and are not used to limit the present invention.
[0043] When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. On the contrary, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the attached claims. In the description of the present application, it should be understood that the terms "first", "second", "third", etc. are only used to distinguish similar objects, and do not have to be used to describe a specific order or sequence, nor can they be understood as indicating or implying relative importance. For those of ordinary skill in the art, the specific meanings of the above terms in the present application can be understood according to the specific circumstances.
[0044] See also Figure 1 As shown, the present invention provides a method for testing the signal-to-noise ratio of a face recognition camera, comprising:
[0045] S1: Receive the target pixel and target adjustment factor of the camera to be tested, including:
[0046] Receive the sensor pixels and adjustment factors sent by the tester, determine the received sensor pixels as target pixels, and automatically check whether the received adjustment factors meet the preset threshold. When the received adjustment factors are less than or equal to the preset threshold, determine the received adjustment factors as the target adjustment factors. When the received adjustment factors are greater than the preset threshold, an error is reported, notifying the tester to resend the adjustment factors, and receiving the adjustment factors resent by the tester until the received adjustment factors are less than or equal to the preset threshold. Then determine the received adjustment factors as the target adjustment factors.
[0047] The camera to be tested includes a sensor. The sensor pixels are determined by the type of sensor used by the camera to be tested. The number of sensor pixels directly affects the image resolution and image quality of the camera, that is, the number of sensor pixels determines the image details and clarity that the camera to be tested can capture during the test process.
[0048] The purpose of determining the target adjustment factor is to decouple the entire project. The adjustment factor is used to adjust the strictness of the signal-to-noise ratio test to better meet the product needs of different customers. The smaller the adjustment factor, the stricter the camera signal-to-noise ratio test. The camera needs to achieve a higher signal-to-noise ratio to be considered a qualified product. The test requirements are used to indicate the strictness of the test on the camera to be tested. The preset threshold is set according to the test requirements, including:
[0049] First, a minimum threshold value for indicating a minimum test requirement is determined, where the minimum test requirement is used to indicate a minimum strictness of the test on the camera to be tested; then, a preset threshold value is determined based on the test requirement and the minimum test requirement.
[0050] In order to meet the basic requirements of customers for products, the preset threshold of the present invention is 100; in the present invention, the smaller the value of the target adjustment factor is, the higher the customer's requirements for the product are; in the actual testing process, the size of the target adjustment factor can be adjusted according to the customer's requirements for the product. For example, if the customer's requirements for the product result are twice as stringent, the tester only needs to set the target adjustment factor within the preset threshold of 100÷2=50; if the customer's requirements for the product result are 10 times more stringent, the tester only needs to set the target adjustment factor within the preset threshold of 100÷10=10.
[0051] S2: Obtaining target data of the camera to be tested, including: setting parameters of the camera to be tested to optimal parameters; shooting with the camera to be tested using the optimal parameters to obtain target data.
[0052] The parameters of the camera to be tested are set to the optimal parameters in order to ensure the accuracy and reliability of the target data, and thus ensure the accuracy and reliability of the signal-to-noise ratio test results. Specifically, the ISP parameters of the camera to be tested are debugged to the optimal level, and the relevant parameters of the camera to be tested are set to normal mode.
[0053] Camera ISP (Image Signal Processor) refers to a chip or module that specializes in processing digital images. It is mainly used to convert analog signals output by digital camera image sensors into digital signals, and perform various enhancements and processing on them to improve image quality and enhance image clarity, color reproduction, dynamic range and depth perception. By debugging the ISP parameters of the camera to be tested to the optimal state, it can be ensured that the camera to be tested outputs high-quality distortion correction images during the test process, reducing distortion errors caused by image quality problems, thereby ensuring the accuracy and reliability of the test.
[0054] Set the relevant parameters of the camera to be tested to normal mode, that is, do not turn on special functions such as night mode, HDR, face enhancement, etc. when shooting. These special functions may affect the acquired target data, and then affect the calculation results of the signal-to-noise ratio, and the accuracy and reliability of the test results cannot be guaranteed. By setting the relevant parameters of the camera to be tested to normal mode, it can be ensured that the signal-to-noise ratio test results of the camera to be tested are not affected by these special functions, thereby ensuring the accuracy and reliability of the signal-to-noise ratio test.
[0055] The target data includes sensor data, that is, data of the sensor used by the camera to be tested; wherein the sensor data includes a gain signal, a first noise signal, a second noise signal, a first signal brightness value, and a second signal brightness value; the gain signal includes an output signal after the sensor input signal is amplified; the first noise signal includes a random signal output by the sensor when there is no input signal; the second noise signal includes the noise signal of the sensor at the target signal brightness value, and the target signal brightness value is the signal brightness value of the 22nd grayscale block of the 11-level grayscale card; the first signal brightness value includes the signal brightness value of the first grayscale block, which is used to indicate the output signal strength of the sensor on the first grayscale block, and the first grayscale block is the 19th grayscale block of the 11-level grayscale card; the second signal brightness value includes the signal brightness value of the second grayscale block, which is used to indicate the output signal strength of the sensor on the second grayscale block, and the second grayscale block is the 24th grayscale block of the 11-level grayscale card.
[0056] A grayscale card is a tool used to test image quality. It contains a series of grayscale combinations with different brightness levels, which are used to evaluate the camera's ability to distinguish grayscale changes under different lighting environments. Grayscale cards are usually divided into two types: transmission and reflection. They can test parameters such as white balance, gray balance, signal-to-noise ratio, dynamic range, and grayscale response. Grayscale blocks are the basic units of grayscale cards, and each grayscale block represents a specific brightness level. Grayscale blocks have different densities and brightness levels, and are used to test the camera's grayscale response capabilities.
[0057] S3: Determine the target signal-to-noise ratio according to the target adjustment factor and the target data. After obtaining the target adjustment factor and the target data, the target signal-to-noise ratio can be automatically calculated by the following formula:
[0058] SNR = F*lg{|S 19 -S 24 |÷[(N1+N2)÷2]}÷V
[0059] Among them, SNR is the target signal-to-noise ratio, F is the target adjustment factor, V is the gain signal, N1 is the first noise signal, N2 is the second noise signal, S 19 is the brightness value of the first signal, S 24 is the brightness value of the second signal.
[0060] S4: Determine the test result of the camera to be tested according to the target pixel and the target signal-to-noise ratio. The test result is used to determine whether the camera to be tested is a qualified product, including:
[0061] First, determine the pixel type corresponding to the target pixel, then determine the signal-to-noise ratio threshold based on the pixel type, and finally determine the test result based on the target signal-to-noise ratio and the signal-to-noise ratio threshold. The specific process is as follows:
[0062] When the pixel type is CIF, the signal-to-noise ratio threshold is 138.6. If the target signal-to-noise ratio is greater than 138.6, the test result of the camera to be tested is a qualified product. If the target signal-to-noise ratio is less than or equal to 138.6, the test result of the camera to be tested is an unqualified product.
[0063] When the pixel type is D1 or 720P, the signal-to-noise ratio threshold is 126.5. If the target signal-to-noise ratio is greater than 126.5, the test result of the camera to be tested is a qualified product. If the target signal-to-noise ratio is less than or equal to 126.5, the test result of the camera to be tested is an unqualified product.
[0064] When the pixel type is 1080P, the signal-to-noise ratio threshold is 110.7. If the target signal-to-noise ratio is greater than 110.7, the test result of the camera to be tested is a qualified product. If the target signal-to-noise ratio is less than or equal to 110.7, the test result of the camera to be tested is an unqualified product.
[0065] When the pixel type is above 3 million, the signal-to-noise ratio threshold is 96.3. If the target signal-to-noise ratio is greater than 96.3, the test result of the camera to be tested is a qualified product. If the target signal-to-noise ratio is less than or equal to 96.3, the test result of the camera to be tested is an unqualified product.
[0066] When the pixel type is CIF, the corresponding resolution is 352*288 pixels; when the pixel type is D1, the corresponding resolution is 720*480 pixels; when the pixel type is 720P, the corresponding resolution is 1280*720 pixels; when the pixel type is 1080P, the corresponding resolution is 1920*1080 pixels; when the pixel type is more than 3 million, the corresponding resolution is 2048*1536 pixels or higher; it can be seen that different pixel types correspond to different resolutions.
[0067] The signal-to-noise ratio is the ratio of signal strength to noise strength, and is used to measure the clarity and detail of an image. Therefore, high-resolution images usually have a higher signal-to-noise ratio and can capture more details, thereby increasing signal strength. However, in practical applications, an increase in resolution does not always mean an increase in the signal-to-noise ratio, because high-resolution images may introduce more noise. Therefore, when performing a signal-to-noise ratio test on a camera to be tested with a high resolution corresponding to the pixel type, the test will be more stringent, that is, the higher the resolution corresponding to the pixel type, the smaller the signal-to-noise ratio threshold, in order to ensure the accuracy of the test results.
[0068] After determining the test results of each camera to be tested in this test, the number of qualified products and the number of unqualified products are determined according to the test results of each camera to be tested. The number of qualified products and the number of unqualified products are added together to obtain the number of test cameras for this test, so as to automatically calculate the product qualification rate of this test, and the product qualification rate is used as a test report and fed back to the tester and the customer. The calculation formula of the product qualification rate is as follows:
[0069] R=(p÷s)×100%.
[0070] Among them, R is the product qualification rate, p is the number of qualified products, and s is the number of test cameras.
[0071] The present invention automatically calculates the target signal-to-noise ratio according to the target adjustment factor, and compares and verifies it with the signal-to-noise ratio threshold to determine whether each camera to be tested is a qualified product. Finally, a test report is automatically generated and fed back to the tester and the customer, ensuring that the face recognition camera products shipped have high-quality production control, thereby improving customer satisfaction with the products. In addition, by automatically acquiring target data, that is, automatically calculating the target signal-to-noise ratio, compared with manual calculation and manual measurement methods, the present invention effectively reduces time and labor costs, improves test efficiency, and does not require manual participation in the calculation process, thereby avoiding inaccurate test results caused by manual labor.
[0072] The present invention also provides a computer device, comprising a processor and a memory, wherein the memory stores at least one instruction, at least one program, code set or instruction set, and the at least one instruction, at least one program, code set or instruction set is loaded and executed by the processor to implement the above-mentioned signal-to-noise ratio testing method.
[0073] The processor can be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
[0074] The memory can be used to store the computer program or module, and the processor realizes various functions of the signal-to-noise ratio test method by running or executing the computer program or module stored in the memory, and calling the data stored in the memory. The memory can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, an application required for at least one function, etc.; the data storage area can store data created according to the use of the mobile phone, etc. In addition, the memory can include a high-speed random access memory, and can also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0075] The above are only preferred embodiments of the present application and are not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application should be included in the protection scope of the present application.
Claims
1. A method for testing the signal-to-noise ratio of a face recognition camera, characterized in that: include: Receive target pixels and target adjustment factors of the camera to be tested; Get the target data of the camera to be tested; Determining a target signal-to-noise ratio according to the target adjustment factor and the target data; A test result of the camera to be tested is determined according to the target pixel and the target signal-to-noise ratio, and the test result is used to determine whether the camera to be tested is a qualified product.
2. A face recognition camera signal-to-noise ratio testing method according to claim 1, characterized in that: The camera to be tested includes a sensor; The receiving of the target pixel and the target adjustment factor of the camera to be tested includes: determining the received sensor pixel as the target pixel; When the received adjustment factor is less than or equal to a preset threshold, determining the received adjustment factor as the target adjustment factor; When the received adjustment factor is greater than the preset threshold, the adjustment factor is received again until the received adjustment factor is less than or equal to the preset threshold, and the received adjustment factor is determined as the target adjustment factor.
3. A face recognition camera signal-to-noise ratio testing method according to claim 2, characterized in that: Test requirements are used to indicate the strictness of the test for the camera to be tested; The preset threshold is set according to the test requirements, including: Determining a minimum threshold value for indicating a minimum test requirement, wherein the minimum test requirement is used to indicate a minimum stringency of a test on a camera to be tested; The preset threshold is determined according to the test requirement and the minimum test requirement.
4. A face recognition camera signal-to-noise ratio testing method according to claim 1, characterized in that: The step of obtaining target data of the camera to be tested includes: Setting the parameters of the camera to be tested to optimal parameters; The camera to be tested shoots with the optimal parameters to obtain the target data.
5. A face recognition camera signal-to-noise ratio testing method according to claim 4, characterized in that: The target data includes sensor data; The sensor data includes a gain signal, a first noise signal, a second noise signal, a first signal brightness value, and a second signal brightness value.
6. A face recognition camera signal-to-noise ratio test method according to claim 4, characterized in that: The gain signal includes an output signal after the sensor input signal is amplified; The first noise signal includes a random signal output by the sensor when there is no input signal; The second noise signal comprises a noise signal of the sensor at a target signal brightness value; The first signal brightness value includes a signal brightness value of a first grayscale block, which is used to represent the output signal intensity of the sensor on the first grayscale block; The second signal brightness value includes a signal brightness value of a second grayscale block, and is used to represent the output signal intensity of the sensor on the second grayscale block.
7. A face recognition camera signal-to-noise ratio testing method according to claim 1, characterized in that: Determining the test result of the camera to be tested according to the target pixel and the target signal-to-noise ratio includes: Determining a signal-to-noise ratio threshold according to the target pixel; A test result is determined according to the signal-to-noise ratio threshold and the target signal-to-noise ratio.
8. A method for testing the signal-to-noise ratio of a face recognition camera according to claim 7, characterized in that: The step of determining a test result according to the signal-to-noise ratio threshold and the target signal-to-noise ratio includes: When the target signal-to-noise ratio is greater than the signal-to-noise ratio threshold, the test result is a qualified product; When the target signal-to-noise ratio is less than or equal to the signal-to-noise ratio threshold, the test result is an unqualified product.
9. A face recognition camera signal-to-noise ratio testing method according to claim 8, characterized in that: Determine the number of qualified products and the number of unqualified products according to the test results of the camera to be tested; The sum of the number of qualified products and the number of unqualified products is determined as the number of test cameras; A test report is generated based on the number of qualified products and the number of test cameras, and the test report is the product qualification rate.
10. A computer device, characterized in that: The computer device includes a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, at least one program, a code set or an instruction set is loaded and executed by the processor to implement the signal-to-noise ratio testing method as described in any one of claims 1 to 9.