Reflection area auxiliary correction method and device based on visual risk control camera
By detecting and adjusting the reflective area in real time in the visual risk control camera, the problem of reflective occlusion of key information in the ID photo is solved, the success rate of ID photo shooting and image quality are improved, and the workload of the auditor is reduced.
Patent Information
- Application Number
- CN202510399859.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-01
- Publication Date
- 2025-06-10
AI Technical Summary
In remote risk control scenarios, the reflection of the ID photo often blocks the key information of the ID, resulting in failure of verification and increasing the workload of the auditor. The existing automated image processing technology cannot effectively solve the problem of the reflective area.
The reflective area assisted correction method based on the visual risk control camera is adopted, and the reflective area in the image to be detected in real time through the preset detection model, the light intensity distribution characteristics are extracted in combination with the multi-scale analysis method, and the light source equipment of the camera is adjusted to reduce reflection until there is no reflective area.
Effectively reduce the obstruction of key information of the document by reflection, significantly improve the success rate of document shooting, optimized document images more accurately reflect document information, reduce verification failure caused by reflection, and reduce the workload of the auditor.
Smart Images

Figure CN120128804A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of image processing technology, and particularly to a method and device for auxiliary correction of reflective areas based on a vision risk control camera. Background Art
[0002] In remote risk control scenarios, users often need to use their mobile phones to take photos of ID cards to complete identity verification or information entry. However, the reflection on the ID card photos often obscures the key information of the ID card, resulting in failed verification and increasing the workload of auditors.
[0003] Related automated image processing technologies, such as automatic exposure, white balance, and image enhancement, can adjust the overall image brightness and contrast, but lack targeted solutions for specific reflective areas. This not only affects the user experience but also reduces the efficiency and accuracy of the risk control process. Summary of the Invention
[0004] To solve or partially solve the problems existing in the related technologies, this application provides a method and device for auxiliary correction of reflective areas based on a vision risk control camera, which can effectively reduce the occlusion of key information on the ID card by reflection, significantly improve the success rate of ID card shooting, and the optimized ID card image can more accurately reflect the ID card information, reduce verification failures caused by reflection, and reduce the workload of auditors.
[0005] In the first aspect of this application, a method for auxiliary correction of reflective areas based on a vision risk control camera is provided, including: Collecting a to-be-detected image through a vision risk control camera; Performing real-time reflection detection on the to-be-detected image based on a preset detection model to determine whether there is a reflective area in the to-be-detected image; including: the preset detection model combines a multi-scale analysis method to extract the light intensity distribution characteristics of the to-be-detected image; evaluating the to-be-detected image according to the light intensity distribution characteristics, and determining whether there is a reflective area in the to-be-detected image based on the evaluation result; If there is a reflective area in the to-be-detected image, adjusting the light source device of the vision risk control camera, and returning to the step of collecting the to-be-detected image through the vision risk control camera until there is no reflective area in the to-be-detected image.
[0006] Preferably, the preset detection model combines a multi-scale analysis method to extract the light intensity distribution characteristics of the to-be-detected image, including: Establishing a coordinate system corresponding to the to-be-detected image and assigning coordinates to each pixel in the to-be-detected image; Extracting the brightness of each pixel through the preset detection model and calculating the local brightness change rate; Analyze the brightness and local brightness change rate of each pixel through multi-scale analysis to obtain the light intensity distribution characteristics of the image to be detected.
[0007] Preferably, evaluating the detection image according to the light intensity distribution characteristics and determining whether there is a reflective area in the image to be detected based on the evaluation result includes: The preset visual conversion model performs light intensity distribution modeling on the image to be detected based on the light intensity distribution characteristics to obtain a light intensity distribution model corresponding to the image to be detected; wherein, the preset visual conversion model is optimized by contrastive learning. Determine whether there is a reflective area in the image to be detected based on the light intensity distribution model using the self-attention mechanism.
[0008] Preferably, the visual risk control camera is embedded with a parameter adjustment strategy model. If there is a reflective area in the image to be detected, adjusting the light source device of the visual risk control camera includes: Generate corresponding adjustment parameters based on the reflective area through the parameter adjustment strategy model. Adjust the light source device according to the adjustment parameters.
[0009] Preferably, the adjustment parameters at least include a target light intensity and a target angle. Generating corresponding adjustment parameters based on the reflective area through the parameter adjustment strategy model includes: Generate a target light intensity based on the range of the reflective area. Generate a target angle based on the position of the reflective area.
[0010] Preferably, after the step of adjusting the light source device of the visual risk control camera, it further includes: When there is a reflective area in the image to be detected, generate an adjustment instruction and send it to the user interface; the adjustment instruction is used to prompt the user to adjust the shooting object of the visual risk control camera and / or the terminal device including the visual risk control camera.
[0011] The second aspect of this application provides a visual risk control camera, including: An acquisition module for acquiring an image to be detected. A detection module for performing real-time reflective detection on the image to be detected based on a preset detection model to determine whether there is a reflective area in the image to be detected; the detection module includes: an extraction sub-module for extracting the light intensity distribution characteristics of the image to be detected through the preset detection model combined with multi-scale analysis; a determination sub-module for evaluating the detection image according to the light intensity distribution characteristics and determining whether there is a reflective area in the image to be detected based on the evaluation result. An adjustment module, configured to adjust the light source device of the vision risk control camera if there is a reflective area in the image to be detected, and return to the step of collecting the image to be detected by the vision risk control camera until there is no reflective area in the image to be detected.
[0012] Preferably, the detection module includes: An assignment sub-module, configured to establish a coordinate system corresponding to the image to be detected and assign coordinates to each pixel in the image to be detected; An extraction sub-module, configured to extract the brightness of each pixel through the preset detection model and calculate the local brightness change rate; An analysis sub-module, configured to analyze the brightness of each pixel and the local brightness change rate through multi-scale analysis to obtain the light intensity distribution characteristics of the image to be detected.
[0013] Preferably, the detection module further includes: A modeling sub-module, configured to perform light intensity distribution modeling on the image to be detected based on the light intensity distribution characteristics by using a preset vision conversion model to obtain a light intensity distribution model corresponding to the image to be detected; wherein, the preset vision conversion model is optimized by contrastive learning; A determination sub-module, configured to determine whether there is a reflective area in the image to be detected based on the light intensity distribution model by using a self-attention mechanism.
[0014] A third aspect of the present application provides an electronic device, including: A processor; and A memory, storing executable code thereon, which when executed by the processor causes the processor to execute the method as described above.
[0015] The technical solution provided by the present application may include the following beneficial effects: The embodiments of the present application disclose a method for auxiliary correction of reflective areas based on a vision risk control camera, including collecting an image to be detected by the vision risk control camera; performing real-time reflective detection on the image to be detected based on a preset detection model to determine whether there is a reflective area in the image to be detected; if there is a reflective area in the image to be detected, adjusting the light source device of the vision risk control camera, and returning to the step of collecting the image to be detected by the vision risk control camera until there is no reflective area in the image to be detected. Through the above method, it is possible to effectively reduce the occlusion of key document information by reflection, significantly improve the success rate of document shooting, the optimized document image can more accurately reflect the document information, reduce verification failures caused by reflection, and reduce the workload of reviewers.
[0016] The technical solution of this application can also: by adjusting the instruction in real-time and feeding it back to the user, it can provide the user with real-time operation guidance to optimize the shooting effect and achieve non-reflective shooting.
[0017] It should be understood that the above general description and the following detailed description are only exemplary and explanatory, and cannot limit this application. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] By describing the exemplary embodiments of this application in more detail in conjunction with the drawings, the above and other objects, features, and advantages of this application will become more apparent. Among them, in the exemplary embodiments of this application, the same reference numerals generally represent the same components.
[0019] Figure 1 is a schematic flowchart of the method for assisting in correcting the reflective area based on a vision risk control camera shown in an embodiment of this application; Figure 2 is another schematic flowchart of the method for assisting in correcting the reflective area based on a vision risk control camera shown in an embodiment of this application; Figure 3 is a flowchart of the method for assisting in correcting the reflective area based on a vision risk control camera shown in an embodiment of this application; Figure 4 is a schematic structural diagram of a vision risk control camera shown in an embodiment of this application; Figure 5 is another schematic structural diagram of a vision risk control camera shown in an embodiment of this application; Figure 6 is a schematic structural diagram of an electronic device shown in an embodiment of this application. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0020] The embodiments of this application will be described in more detail below with reference to the drawings. Although the embodiments of this application are shown in the drawings, it should be understood that this application can be implemented in various forms and should not be limited by the embodiments described herein. On the contrary, these embodiments are provided to make this application more thorough and complete, and to convey the scope of this application fully to those skilled in the art.
[0021] The terms used in this application are only for the purpose of describing specific embodiments and are not intended to limit this application. The singular forms "a", "the", and "said" used in this application and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more of the associated listed items.
[0022] It should be understood that although the terms "first", "second", "third", etc. may be used in this application to describe various information, such information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of this application, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Thus, the features defined with "first" and "second" may explicitly or implicitly include one or more of such features. In the description of this application, the meaning of "a plurality" is two or more, unless otherwise specifically defined.
[0023] Related automated image processing technologies, such as automatic exposure, white balance, and image enhancement, can adjust the overall image brightness and contrast, but lack targeted solutions for specific reflective areas. This not only affects the user experience but also reduces the efficiency and accuracy of the risk control process.
[0024] To address the above problems, the embodiments of this application provide a method for auxiliary correction of reflective areas based on a vision risk control camera, which can effectively reduce the occlusion of key document information by reflections, significantly improve the success rate of document shooting, and the optimized document image can more accurately reflect the document information, reduce verification failures caused by reflections, and reduce the workload of reviewers.
[0025] The technical solutions of the embodiments of this application are described in detail below with reference to the accompanying drawings.
[0026] Figure 1 is a schematic flowchart of the method for auxiliary correction of reflective areas based on a vision risk control camera shown in the embodiments of this application.
[0027] See Figure 1 and the method includes: Step 110, collect the image to be detected through the vision risk control camera.
[0028] The embodiments of this application can be applied in a remote risk control scenario. Remote Risk Control refers to the process of monitoring, analyzing, and controlling risks through remote technical means, which is widely used in fields such as finance, industry, and security. By combining means such as image sensors, AI (Artificial Intelligence), the Internet of Things, and big data, real-time monitoring and intelligent early warning of risks can be achieved.
[0029] An image sensor is integrated in the vision risk control camera of the embodiments of this application. An image sensor is a device that converts optical signals into electrical signals and is widely used in fields such as digital cameras, camcorders, smartphones, autonomous driving vehicles, security monitoring, and medical imaging. The vision risk control camera can be installed in a terminal device, and the terminal device can be a smartphone, a smart tablet, etc.
[0030] In the process of remote risk control, users may need to take pictures of personal documents for verification. The image sensor in the visual risk control camera can collect the image to be detected, which can be an image of the personal document that the user needs to use for verification. However, in a complex light environment, there may be a reflective area in the image to be detected, blocking the important information in the document and resulting in verification failure. In addition, the image to be detected can also be obtained by the user uploading a photo by themselves.
[0031] Step 120, perform real-time reflective detection on the image to be detected based on a preset detection model to determine whether there is a reflective area in the image to be detected; it includes: the preset detection model combines the multi-scale analysis method to extract the light intensity distribution characteristics of the image to be detected; evaluate the image to be detected according to the light intensity distribution characteristics, and determine whether there is a reflective area in the image to be detected based on the evaluation result.
[0032] The preset detection model can be a pre-trained model. A reflective tracking algorithm is embedded in the preset detection model. Through the reflective tracking algorithm in the preset detection model, real-time reflective detection can be performed on the image to be detected in real time to determine whether there is a reflective area in the image to be detected. Generally, the reflective area has the following characteristics: high brightness, the reflective area is brighter than the surrounding environment; highlight, the light in the local reflective area is very concentrated, forming a relatively strong brightness; irregular shape, the shape of the reflective area often depends on the nature of the reflection surface, and generally the reflective area is relatively blurred and irregular; the color change is related to the surface material, and the color of the reflective area may be related to the spectral characteristics of the surface material. For example, the metal surface may reflect a relatively cold color tone, while the water surface or glass may present a relatively warm color tone reflection.
[0033] The preset detection model can be obtained through the following methods: 1. Data preparation: Collect a large number of images with reflective color patches and mark the reflective parts to form a training data set.
[0034] 2. Model selection: Select a suitable deep learning model (such as ResNet (Residual Network), VIT (vision transformer), etc.) for training.
[0035] 3. Model training: Use the training data set containing reflective marks to train the model, adjust the model parameters, and improve the recognition accuracy.
[0036] 4. Model testing: Use the test set to test the model and evaluate indicators such as the accuracy rate and recall rate of the model.
[0037] 5. Model Deployment: Deploy the trained model to the actual system for online evaluation.
[0038] The light intensity distribution feature of the image to be detected refers to the spatial distribution of pixel brightness (light intensity) in the image to be detected, reflecting the brightness change law and characteristics of the image. The preset detection model includes a feature extraction model and an evaluation model. Before extracting the light intensity distribution feature, preprocessing operations such as denoising and enhancement can be performed on the image to improve the recognition accuracy. The feature extraction model can be used to extract the light intensity distribution feature of the image to be detected by combining the multi-scale analysis method. The core of the multi-scale analysis method is to capture the features of the image at different scales (or resolutions) and fuse these features into the image analysis process. When analyzing the image to be detected, the image to be detected can be converted into multiple images of different scales, and the features related to light intensity are independently extracted on each sized image, and then the features related to light intensity extracted at each scale are integrated together to obtain the light intensity distribution feature of the image to be detected. By using the multi-scale analysis method, the accuracy and robustness of the detection of the image to be detected can be improved.
[0039] Input the light intensity distribution feature into the evaluation model, and output the possibility and impact degree score of the presence of specular reflection interference in the picture. Based on the evaluation result, determine whether there is a specular reflection area and the type of the specular reflection area in the image to be detected. Among them, both the feature extraction model and the evaluation model are pre-trained models.
[0040] Step 130, if there is a specular reflection area in the image to be detected, adjust the light source device of the visual risk control camera, and return to Step 110 until there is no specular reflection area in the image to be detected.
[0041] The visual risk control camera also includes a light source device, where the light source device can be an LED (light-emitting diode) light source or a device screen. If there is a specular reflection area in the image to be detected, the light source parameters of the light source device of the visual risk control camera can be adjusted in real time, such as the light source brightness and angle, the light source color temperature, the light source spectrum, the dynamic range of the light source, etc., to dynamically reduce the brightness of the specular reflection area and enhance the details of the non-specular reflection area. After adjusting the light source device, return to Step 110 again, re-collect the image to be detected, and re-detect the specular reflection of the image to be detected until there is no specular reflection area in the image to be detected, and the process of image acquisition and optimization ends, and the optimized image is saved in the remote risk control system.
[0042] An embodiment of the present application discloses a method for auxiliary correction of a reflective area based on a visual risk control camera, including collecting an image to be detected through the visual risk control camera; performing real-time reflective detection on the image to be detected based on a preset detection model to determine whether there is a reflective area in the image to be detected; including: the preset detection model combines a multi-scale analysis method to extract the light intensity distribution characteristics of the image to be detected; evaluating the image to be detected according to the light intensity distribution characteristics, and determining whether there is a reflective area in the image to be detected based on the evaluation result; if there is a reflective area in the image to be detected, adjusting the light source device of the visual risk control camera, and returning to the step of collecting the image to be detected through the visual risk control camera until there is no reflective area in the image to be detected. Through the above method, it is possible to effectively reduce the occlusion of key information on the certificate by reflection, significantly improve the success rate of certificate shooting, the optimized certificate image can more accurately reflect the certificate information, reduce the verification failure caused by reflection, and reduce the workload of the reviewer.
[0043] Figure 2 FIG. is another schematic flowchart of the method for auxiliary correction of the reflective area based on the visual risk control camera shown in the embodiment of the present application.
[0044] See Figure 2 , the method includes: Step 210, collecting an image to be detected through the visual risk control camera.
[0045] During the process of remote risk control, the user may need to take a personal certificate for verification. The image sensor in the visual risk control camera can collect the image to be detected. The image to be detected can be an image of the personal certificate that the user needs to use for verification. However, in a complex light environment, there may be a reflective area in the image to be detected, blocking the important information in the certificate and resulting in verification failure. In addition, the image to be detected can also be obtained by the user's self-upload method.
[0046] Step 220, establishing a coordinate system corresponding to the image to be detected and assigning coordinates to each pixel in the image to be detected.
[0047] A coordinate system corresponding to the image to be detected can be established, and coordinates can be assigned to each pixel in the image to be detected.
[0048] Step 230, extracting the brightness of each pixel through a preset detection model and calculating the local brightness change rate.
[0049] Extract the brightness of each pixel through a preset detection model. For the brightness of each pixel, within the local area of the image to be detected, compare the brightness of the current pixel with the brightness of its surrounding pixels to obtain the local brightness change rate in the image to be detected. By calculating the local brightness change rate, the distinguishability of pixel brightness in different areas of the image to be detected can be enhanced.
[0050] Step 240: Analyze the brightness of each pixel and the local brightness change rate through multi-scale analysis to obtain the light intensity distribution characteristics of the image to be detected.
[0051] In the embodiment of the present application, the multi-scale analysis method can select the multi-scale Retinex (MSR) algorithm. The multi-scale Retinex algorithm is an image enhancement method based on the Retinex theory, which decomposes the image into an illumination component and a reflection component. The illumination component represents the lighting information, while the reflection component represents the inherent properties of the object. By removing the influence of the illumination component, the details and colors of the image can be enhanced. By performing Gaussian filtering on the image at multiple scales, a more stable illumination estimate can be obtained. By analyzing the brightness of each pixel and the local brightness change rate through multi-scale analysis, the light intensity distribution characteristics of the image to be detected can be obtained.
[0052] Step 250: The preset visual transformation model performs light intensity distribution modeling on the image to be detected based on the light intensity distribution characteristics to obtain a light intensity distribution model corresponding to the image to be detected; wherein, the preset visual transformation model is optimized by the contrastive learning method.
[0053] In the embodiment of the present application, the preset visual transformation model can select the Vision Transformer (VIT) model. The preset visual transformation model performs light intensity distribution modeling on the image to be detected according to the light intensity distribution characteristics, so as to establish a light intensity distribution model corresponding to the image to be detected.
[0054] In one example, the preset visual transformation model is optimized by the contrastive learning method. By comparing positive samples (similar samples) and negative samples (dissimilar samples), the embedded representation of the data is learned, so that similar samples are closer in the embedding space and dissimilar samples are farther away, enabling it to better learn the difference characteristics between the reflective area and the normal area, so as to improve the robustness and generalization ability of the detection.
[0055] Step 260: Based on the light intensity distribution model, use the self-attention mechanism to determine whether there is a reflective area in the image to be detected.
[0056] The self-attention mechanism is a special attention mechanism that allows the model to consider the relationship between each element in the sequence and all other elements when processing a sequence. Different from the traditional attention mechanism, the self-attention mechanism does not rely on external "queries" and "keys", but uses the sequence itself as the source of queries, keys, and values (Values).
[0057] Based on the light intensity distribution model, a self-attention mechanism is adopted to determine whether there is a reflective area in the image to be detected. In the image to be detected, if the area composed of reflective pixels exceeds a preset range, it can be determined that there is a reflective area in the image to be detected. In one example, the preset range can be 4×4 pixels. When the area composed of reflective pixels is detected to exceed 4×4, it is determined that there is a reflective area, and the image to be detected needs to be adjusted. The reflective area is defaultly located in the center of the image to be detected.
[0058] Step 270, if there is a reflective area in the image to be detected, adjust the light source device of the visual risk control camera, and return to step 210 until there is no reflective area in the image to be detected.
[0059] The visual risk control camera also includes a light source device, where the light source device can be an LED (light-emitting diode) light source or a device screen. If there is a reflective area in the image to be detected, the light source brightness and angle of the light source device of the visual risk control camera can be adjusted in real time to dynamically reduce the brightness of the reflective area and enhance the details of the non-reflective area. After adjusting the light source device, return to step 210 again, re-collect the image to be detected, and re-detect the reflection of the image to be detected until there is no reflective area in the image to be detected, and the process of image acquisition and optimization ends. The optimized image is stored in the downstream remote risk control system.
[0060] In an optional embodiment of the present application, the visual risk control camera is embedded with a parameter adjustment strategy model, and step 270 includes: Generate corresponding adjustment parameters based on the reflective area through the parameter adjustment strategy model; Adjust the light source device according to the adjustment parameters.
[0061] The visual risk control camera is embedded with a parameter adjustment strategy model. The parameter adjustment strategy model can generate adjustment parameters adapted to the detected reflective area, and the light source device can be adjusted according to the adjustment parameters.
[0062] In an optional embodiment of the present application, the parameter adjustment strategy model is trained by the reinforcement learning method.
[0063] The core of the reinforcement learning method is the value function, which estimates the expected cumulative reward that can be obtained by starting from a given state and following a specific strategy. By continuously updating the value function, the model learns to distinguish which states are more likely to lead to high rewards, so as to make better decisions. In the embodiment of the present application, the reflection area detection error is used as the reward signal to train the model, and the parameters in the value function are updated to obtain the parameter adjustment strategy model with the best effect.
[0064] In an alternative embodiment of the present application, the adjustment parameters at least include a target illumination intensity and a target angle. Generating corresponding adjustment parameters based on the specular region by the parameter adjustment strategy model includes: Generating a target illumination intensity based on the range of the specular region; Generating a target angle based on the position of the specular region.
[0065] The adjustment parameters at least include a target illumination intensity and a target angle. When it is determined that there is a specular region, according to the coordinates of the specular pixels in the specular region, the range and position of the specular region can be calculated. According to the range of the specular region, the target illumination intensity that the light source device needs to adjust can be generated. According to the target illumination intensity, the light source device can be adjusted. If the range of the specular region is large, the illumination intensity of the light source device can be appropriately reduced; according to the position of the specular region, the target angle that the light source device needs to adjust can be generated. According to the target angle, the light source device can be adjusted. For example, if the specular region is on the left side of the image to be detected, the light source device is adjusted to the right, and each time it can be adjusted by 3°, and multiple adjustments are made for detection. In addition, parameters such as the exposure, color temperature, spectrum, and dynamic range of the light source device can also be adjusted. Those skilled in the art can understand that the angle adjusted each time above is only an example, and the present application does not limit this.
[0066] In an alternative embodiment of the present application, after step 270, it further includes: When there is a specular region in the image to be detected, generating an adjustment instruction and sending it to the user interface; the adjustment instruction is used to prompt the user to adjust the shooting object of the visual risk control camera and / or the terminal device including the visual risk control camera.
[0067] After detecting the specular region, an adjustment instruction can also be generated and sent to the user interface. The adjustment instruction prompts the user to adjust the position and angle of the shooting object of the visual risk control camera, and can also prompt the user to adjust the position and angle of the terminal device including the visual risk control camera. By providing the adjustment instruction to the user in real time, operation guidance can be provided to the user in real time to optimize the shooting effect and achieve specular-free shooting.
[0068] In an alternative embodiment of the present application, AR (Augmented Reality) technology can also be used to embed specular detection and real-time feedback into the terminal device. Through sensors such as depth sensors, accelerometers, and gyroscopes equipped with the AR device, environmental information is captured, and 3D environmental modeling is performed in combination with the image data collected by the camera to display the relationship between the user and the light source, guide and promote the user to improve the posture, and display the real-time effect of the user adjusting the posture of the camera or device in real time.
[0069] See Figure 3, which is a flowchart of a method for assisting in correcting the reflective area of a vision risk control camera. The method includes: Step 310: Start the vision risk control camera and collect the image to be detected.
[0070] Step 320: Continuously perform image analysis and reflection detection on the image to be detected in real time.
[0071] Step 330: Determine whether there is a reflective area in the image to be detected according to the detection result; if so, execute Step 340, if not, execute Step 360.
[0072] Step 340: Adjust the light source device of the vision risk control camera.
[0073] Step 350: Generate an adjustment instruction and send it to the user interface to prompt the user to adjust the shooting object of the vision risk control camera and / or the terminal device including the vision risk control camera, and return to Step 310.
[0074] Step 360: Complete image acquisition and save the image.
[0075] The embodiment of the present application discloses a method for assisting in correcting the reflective area based on a vision risk control camera, including collecting an image to be detected through the vision risk control camera; establishing a coordinate system corresponding to the image to be detected, assigning coordinates to each pixel in the image to be detected, extracting the brightness of each pixel through a preset detection model, and calculating the local brightness change rate, analyzing the brightness of each pixel and the local brightness change rate through a multi-scale analysis method to obtain the light intensity distribution characteristics of the image to be detected, and the preset vision conversion model performs light intensity distribution modeling on the image to be detected based on the light intensity distribution characteristics to obtain a light intensity distribution model corresponding to the image to be detected; wherein, the preset vision conversion model is optimized by a contrastive learning method, and the self-attention mechanism is used based on the light intensity distribution model to determine whether there is a reflective area in the image to be detected. If there is a reflective area in the image to be detected, adjust the light source device of the vision risk control camera, and return to the step of collecting the image to be detected through the vision risk control camera until there is no reflective area in the image to be detected. Through the above method, the shooting failure rate can be reduced, especially in a complex light environment, the quality and details of the captured image are significantly improved, making the document information clearer; the workload of review is greatly reduced, the shooting time of the user is shortened, the user experience is improved, the operation repetition caused by shooting failure is reduced, and a more convenient operation experience is provided; the security and reliability of the data are improved, and the accuracy and anti-counterfeiting ability of the remote risk control system are enhanced.
[0076] Corresponding to the foregoing embodiment of the application function implementation method, the present application also provides a vision risk control camera, an electronic device and corresponding embodiments.
[0077] Figure 4 It is a schematic structural diagram of the visual risk control camera shown in the embodiments of the present application.
[0078] See Figure 4 , the visual risk control camera 400 includes: An acquisition module 410, configured to acquire an image to be detected; During the process of remote risk control, users may need to take pictures of personal documents for verification. The image sensor in the visual risk control camera can acquire the image to be detected. The image to be detected can be an image of a personal document that the user needs to use for verification. However, in a complex light environment, there may be a reflective area in the image to be detected, blocking important information in the document and resulting in verification failure. In addition, the image to be detected can also be obtained by the user's self-upload method.
[0079] A detection module 420, configured to perform real-time reflection detection on the image to be detected based on a preset detection model to determine whether there is a reflective area in the image to be detected; including: the preset detection model combines a multi-scale analysis method to extract the light intensity distribution characteristics of the image to be detected; evaluate the image to be detected according to the light intensity distribution characteristics, and determine whether there is a reflective area in the image to be detected based on the evaluation result.
[0080] The preset detection model can be a pre-trained model. Through the reflection tracking algorithm in the preset detection model, real-time reflection detection can be performed on the image to be detected in real time to determine whether there is a reflective area in the image to be detected. Usually, the reflective area has the following characteristics: high brightness: the reflective area is brighter than the surrounding environment; highlight: the light in the local reflective area is very concentrated, forming a relatively strong brightness; irregular shape: the shape of the reflective area often depends on the nature of the reflection surface, and generally the reflective area is relatively blurred and irregular; color change is related to the surface material: the color of the reflective area may be related to the spectral characteristics of the surface material. For example, a metal surface may reflect a relatively cold color tone, while a water surface or glass may present a relatively warm color tone reflection.
[0081] The light intensity distribution feature of the image to be detected refers to the spatial distribution of pixel brightness (light intensity) in the image to be detected, reflecting the brightness change law and characteristics of the image. The preset detection model includes a feature extraction model and an evaluation model. Before extracting the light intensity distribution feature, preprocessing operations such as denoising and enhancement can be performed on the image to improve the recognition accuracy. The feature extraction model can be used to extract the light intensity distribution feature of the image to be detected by combining the multi-scale analysis method. The core of the multi-scale analysis method is to capture the features of the image from different scales (or resolutions) and integrate these features into the image analysis process. When analyzing the image to be detected, the image to be detected can be converted into multiple images of different scales, and features related to light intensity can be independently extracted on each sized image, and then the features related to light intensity extracted from each scale are integrated together to obtain the light intensity distribution feature of the image to be detected. By using the multi-scale analysis method, the accuracy and robustness of the detection of the image to be detected can be improved.
[0082] Input the light intensity distribution feature into the evaluation model, and output the possibility and impact degree score of the presence of specular reflection interference in the picture. Based on the evaluation result, determine whether there is a specular reflection area and the type of the specular reflection area in the image to be detected. Among them, both the feature extraction model and the evaluation model are pre-trained models.
[0083] The adjustment module 430 is used to adjust the light source device of the visual risk control camera if there is a specular reflection area in the image to be detected, and call the acquisition module 410 until there is no specular reflection area in the image to be detected.
[0084] The visual risk control camera also includes a light source device, where the light source device can be an LED light source or a device screen. If there is a specular reflection area in the image to be detected, the light source brightness and angle of the light source device of the visual risk control camera can be adjusted in real time to dynamically reduce the brightness of the specular reflection area and enhance the details of the non-specular reflection area. After adjusting the light source device, the image to be detected is re-acquired, and the specular reflection detection of the image to be detected is re-performed until there is no specular reflection area in the image to be detected, and the process of image acquisition and optimization ends, and the optimized image is saved in the remote risk control system.
[0085] The embodiment of the present application discloses a visual risk control camera, which can effectively reduce the occlusion of key document information by specular reflection, significantly improve the success rate of document shooting, the optimized document image can more accurately reflect the document information, reduce the verification failure caused by specular reflection, and reduce the workload of the reviewer.
[0086] Figure 5 It is another structural schematic diagram of the visual risk control camera shown in the embodiment of the present application.
[0087] See Figure 5, the visual risk control camera 400 is communicatively connected to the remote risk control system 500, where the visual risk control camera 400 includes: An acquisition module 410 for acquiring an image to be detected; A detection module 420 for performing a specular reflection detection on the image to be detected in real time based on a preset detection model to determine whether there is a specular reflection area in the image to be detected; including: the preset detection model combines a multi-scale analysis method to extract the light intensity distribution features of the image to be detected; evaluates the image to be detected according to the light intensity distribution features, and determines whether there is a specular reflection area in the image to be detected based on the evaluation result.
[0088] Among them, the detection module 420 includes: An allocation sub-module 421 for establishing a coordinate system corresponding to the image to be detected and allocating coordinates to each pixel in the image to be detected; An extraction sub-module 422 for extracting the brightness of each pixel through the preset detection model and calculating the local brightness change rate; An analysis sub-module 423 for analyzing the brightness of each pixel and the local brightness change rate through a multi-scale analysis method to obtain the light intensity distribution features of the image to be detected.
[0089] The detection module 420 further includes: A modeling sub-module 424 for performing a light intensity distribution modeling on the image to be detected based on the light intensity distribution features by a preset visual conversion model to obtain a light intensity distribution model corresponding to the image to be detected; among them, the preset visual conversion model is optimized by a contrastive learning method; A determination sub-module 425 for determining whether there is the specular reflection area in the image to be detected based on the light intensity distribution model by using a self-attention mechanism.
[0090] An adjustment module 430 for, if there is a specular reflection area in the image to be detected, adjusting the light source device of the visual risk control camera, and returning to the step of acquiring the image to be detected by the visual risk control camera until there is no specular reflection area in the image to be detected.
[0091] Among them, the visual risk control camera is embedded with a parameter adjustment strategy model, and the adjustment module 430 includes: A parameter generation sub-module 431 for generating corresponding adjustment parameters based on the specular reflection area through the parameter adjustment strategy model; An adjustment sub-module 432 for adjusting the light source device according to the adjustment parameters.
[0092] In an alternative embodiment of the present application, the adjustment parameters at least include a target illumination intensity and a target angle. The parameter generation sub-module 431 is further configured to generate the target illumination intensity based on the range of the specular region; and generate the target angle based on the position of the specular region.
[0093] The visual risk control camera 400 further includes: A user interface module 440, configured to generate an adjustment instruction and send it to the user interface when there is a specular region in the image to be detected. The adjustment instruction is used to prompt the user to adjust the shooting object of the visual risk control camera and / or the terminal device including the visual risk control camera.
[0094] A remote risk control system 500, configured to store the image to be detected after adjustment and optimization.
[0095] The embodiment of the present application discloses a visual risk control camera, which can reduce the shooting failure rate, especially in a complex light environment, significantly improve the quality and details of the captured image, make the document information clearer; greatly reduce the workload of review, shorten the shooting time of the user, improve the user experience, reduce the operation repetition caused by shooting failure, and provide a more convenient operation experience; improve the security and reliability of data, and enhance the accuracy and anti-counterfeiting ability of the remote risk control system.
[0096] Regarding the device in the above embodiments, the specific manner in which each module performs operations has been described in detail in the embodiments related to the method, and will not be elaborated here.
[0097] Figure 6 is a schematic structural diagram of an electronic device shown in the embodiment of the present application.
[0098] See Figure 6 , the electronic device 600 includes a memory 610 and a processor 620.
[0099] The processor 620 may be a central processing unit (CPU), or may also be other general-purpose processors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0100] The memory 610 may include various types of storage units, such as system memory, read-only memory (ROM), and permanent storage devices. Among them, the ROM may store static data or instructions required by the processor 620 or other modules of the computer. The permanent storage device may be a readable and writable storage device. The permanent storage device may be a non-volatile storage device that does not lose the stored instructions and data even when the computer is powered off. In some embodiments, the permanent storage device uses a mass storage device (such as a magnetic or optical disk, flash memory) as the permanent storage device. In some other embodiments, the permanent storage device may be a removable storage device (such as a floppy disk, optical drive). The system memory may be a readable and writable storage device or a volatile readable and writable storage device, such as dynamic random access memory. The system memory may store some or all of the instructions and data required by the processor during operation. In addition, the memory 610 may include any combination of computer-readable storage media, including various types of semiconductor storage chips (such as DRAM, SRAM, SDRAM, flash memory, programmable read-only memory), and magnetic disks and / or optical disks may also be used. In some embodiments, the memory 610 may include a removable storage device that is readable and / or writable, such as a compact disc (CD), read-only digital versatile disc (such as DVD-ROM, dual-layer DVD-ROM), read-only Blu-ray disc, super density disc, flash memory card (such as SD card, min SD card, Micro-SD card, etc.), magnetic floppy disk, etc. Computer-readable storage media do not include carrier waves and instantaneous electronic signals transmitted wirelessly or by wire.
[0101] Executable code is stored on the memory 610, and when the executable code is processed by the processor 620, it can cause the processor 620 to execute some or all of the methods described above.
[0102] In addition, the method according to the present application can also be implemented as a computer program or a computer program product, which includes computer program code instructions for executing some or all of the steps in the above method of the present application.
[0103] Alternatively, the present application can also be implemented as a computer-readable storage medium (or non-transitory machine-readable storage medium or machine-readable storage medium), on which executable code (or computer program or computer instruction code) is stored. When the executable code (or computer program or computer instruction code) is executed by a processor of an electronic device (or a server, etc.), it causes the processor to execute some or all of the steps of the above method according to the present application.
[0104] The embodiments of the present application have been described above. The above description is exemplary and not exhaustive, and is also not limited to the disclosed embodiments. Many modifications and variations are obvious to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of the terms used herein is intended to best explain the principles of the embodiments, practical applications, or improvements to the technology in the market, or to enable other ordinary skill in the art to understand the embodiments disclosed herein.
Claims
1. A reflective area auxiliary correction method based on a visual wind control camera, characterized in that: Collect the images to be detected through the visual wind control camera; Performing a reflection detection on the image to be detected in real time based on a preset detection model to determine whether there is a reflection area in the image to be detected; The method includes: extracting the light intensity distribution characteristics of the image to be detected by combining the preset detection model with a multi-scale analysis method; The multi-scale analysis method evaluates the image to be detected according to the light intensity distribution characteristics, and determines whether there is a reflective area in the image to be detected based on the evaluation result; If there is a reflective area in the image to be detected, the light source device of the visual wind control camera is adjusted, and the process returns to the step of collecting the image to be detected through the visual wind control camera until there is no reflective area in the image to be detected.
2. The method according to claim 1, characterized in that: The preset detection model combined with the multi-scale analysis method to extract the light intensity distribution characteristics of the image to be detected includes: Establishing a coordinate system corresponding to the image to be detected, and assigning coordinates to each pixel in the image to be detected; Extracting the brightness of each pixel through the preset detection model, and calculating the local brightness change rate; The brightness of each pixel and the local brightness change rate are analyzed by a multi-scale analysis method to obtain the light intensity distribution characteristics of the image to be detected.
3. The method according to claim 1, characterized in that The step of evaluating the detection image according to the light intensity distribution feature and determining whether there is a reflective area in the image to be detected based on the evaluation result comprises: The preset visual conversion model performs light intensity distribution modeling on the image to be detected based on the light intensity distribution feature to obtain a light intensity distribution model corresponding to the image to be detected; wherein the preset visual conversion model is optimized by a contrast learning method; Based on the light intensity distribution model, a self-attention mechanism is adopted to determine whether the reflective area exists in the image to be detected.
4. The method according to claim 1, characterized in that: The visual wind control camera is embedded with a parameter adjustment strategy model, and if the reflective area exists in the image to be detected, adjusting the light source device of the visual wind control camera includes: Generate corresponding adjustment parameters based on the reflective area through the parameter adjustment strategy model; The light source device is adjusted according to the adjustment parameter.
5. The method according to claim 4, characterized in that The adjustment parameters include at least target light intensity and target angle, and the generating corresponding adjustment parameters based on the reflective area by the parameter adjustment strategy model includes: generating a target light intensity based on the range of the reflective area; A target angle is generated based on the position of the reflective area.
6. The method according to claim 1, characterized in that After the step of adjusting the light source device of the visual wind control camera, the step further includes: When there is a reflective area in the image to be detected, an adjustment instruction is generated and sent to the user interface; the adjustment instruction is used to prompt the user to adjust the shooting object of the visual wind control camera and / or the terminal device including the visual wind control camera.
7. A visual wind control camera, characterized in that: The visual wind control camera includes: An acquisition module, used for acquiring images to be detected; A detection module, used to perform reflection detection on the image to be detected in real time based on a preset detection model, and determine whether there is a reflective area in the image to be detected; the detection module includes: an extraction submodule, used to extract the light intensity distribution characteristics of the image to be detected by combining the preset detection model with a multi-scale analysis method; a determination submodule, used to evaluate the detection image according to the light intensity distribution characteristics, and determine whether there is a reflective area in the image to be detected based on the evaluation result; The adjustment module is used to adjust the light source device of the visual wind control camera if there is a reflective area in the image to be detected, and return to the step of collecting the image to be detected through the visual wind control camera until there is no reflective area in the image to be detected.
8. The visual wind control camera according to claim 7, characterized in that: The detection module comprises: An allocation submodule, used for establishing a coordinate system corresponding to the image to be detected, and allocating coordinates to each pixel in the image to be detected; An extraction submodule, used to extract the brightness of each pixel through the preset detection model and calculate the local brightness change rate; The analysis submodule is used to analyze the brightness of each pixel and the local brightness change rate through a multi-scale analysis method to obtain the light intensity distribution characteristics of the image to be detected.
9. The visual wind control camera according to claim 7, characterized in that: The detection module also includes: A modeling submodule, for performing light intensity distribution modeling on the image to be detected based on the light intensity distribution characteristics by using a preset visual conversion model, so as to obtain a light intensity distribution model corresponding to the image to be detected; wherein the preset visual conversion model is optimized by a contrast learning method; A determination submodule is used to determine whether the reflective area exists in the image to be detected by adopting a self-attention mechanism based on the light intensity distribution model.
10. An electronic device, characterized in that: include: processor; as well as A memory having executable codes stored thereon, which, when executed by the processor, causes the processor to execute the method according to any one of claims 1 to 6.