Multi-algorithm identification control type payment method and system based on single camera
By capturing facial and palm print features with a single camera, and combining image preprocessing and dynamic decision-making, the hardware cost and recognition effect issues of biometric payment in complex environments have been solved, enabling an efficient and secure payment process.
Patent Information
- Application Number
- CN202511553852.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-29
- Publication Date
- 2025-12-12
AI Technical Summary
Existing biometric payment technologies have poor recognition performance in complex environments, single-modality is easily interfered with, multi-module solutions have high hardware costs and poor operational consistency, and multi-algorithm scheduling under a single camera is difficult to achieve efficiently.
A single camera is used to capture facial and palm print features. The image preprocessing unit performs multi-step optimization, and combined with a preset algorithm module and scene parameter library, dynamic decision-making is carried out to output recognition results in a unified format and complete the transaction on the payment platform.
Reduce hardware costs, improve recognition success rate, adapt to complex environments, ensure the continuity and security of the payment process, and support offline credit payments.
Smart Images

Figure CN121120073A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of multi-modal feature processing of images, in particular to a multi-algorithm recognition control type payment method and system based on a single camera, which is suitable for offline consumption scenarios such as canteens, convenience stores, etc. with complex lighting, diverse user groups, and high concurrency. BACKGROUND
[0002] Existing biometric payment technologies mainly fall into two categories: single modal recognition and multi-modal hybrid recognition. In single modal recognition, face recognition is susceptible to environmental light interference, face occlusion (such as masks), and other factors, while palm print recognition faces the problem of palm state fluctuations. When used alone, both have limited scene adaptability. Traditional multi-modal solutions (such as dual-camera capture) require the deployment of multiple specialized devices, increasing hardware costs by more than 30%, and users need to complete recognition in different areas, with poor operational continuity.
[0003] In existing technologies, biometric recognition focuses on optimizing the algorithm itself, while ignoring the difficulty of single algorithms to adapt to complex scenarios. At the same time, how to achieve efficient scheduling and dynamic decision-making of multi-algorithm results under a single camera hardware has become a key pain point that balances cost and adaptability. SUMMARY
[0004] To overcome the above problems in the prior art, the present application provides a multi-algorithm recognition control type payment method and system based on a single camera, which adopts the following technical solutions:
[0005] In a first aspect, the present application provides a multi-algorithm recognition control type payment method based on a single camera, comprising:
[0006] Based on a preset distance, an image data frame containing face and palm print features is captured by a deployed single camera;
[0007] A multi-step optimization is performed on the image data frame by an image preprocessing unit, and a standardized image data is output to a corresponding algorithm module;
[0008] Based on a preset algorithm module, the recognition result is obtained, and a unified format of the recognition result is output;
[0009] A preset scene parameter library is based on the recognition result, and a dynamic decision logic is executed to obtain a decision result;
[0010] Based on the decision result, user information and transaction data are encrypted and transmitted to a payment platform. After the payment platform completes the fee deduction or offline transaction accounting successfully, the transaction result is returned.
[0011] Further, the deployed single camera can simultaneously frame the face and palm print regions.
[0012] Further, the image data frame is subjected to multi-step optimization by the image preprocessing unit, including wide dynamic range optimization, grayscale processing and size standardization.
[0013] Further, the wide dynamic range optimization of the image data frame includes:
[0014] Based on the pixel coordinates of the face frame region or the palm print frame region obtained by the preset detector, the face local image and the palm local image are extracted from the image data frame based on the pixel coordinate information.
[0015] The face local image and the palm local image are divided into different regions, and the average brightness of each region is calculated. When the adjacent region brightness contrast exceeds the preset threshold, the image data frame has overexposure or underexposure.
[0016] The first image data is obtained by wide dynamic range optimization for the image frame region with overexposure or underexposure.
[0017] Further, the first image data is obtained by wide dynamic range optimization for the image frame region with overexposure or underexposure, including:
[0018] The face local image and the palm local image are converted into a luminance-chrominance separation color space, and the luminance component and the reserved chrominance component are output.
[0019] The luminance component is subjected to bilateral filtering to obtain a smooth local illumination map.
[0020] Based on the luminance component and the local illumination map, an initial correction coefficient is obtained by a nonlinear tone mapping function.
[0021] The initial correction coefficient is multiplied by the weight map pixel by pixel to obtain a final correction coefficient.
[0022] The luminance component is adjusted by the final correction coefficient to obtain an optimized luminance component.
[0023] The optimized luminance component and the reserved chrominance component are combined, and a reverse color space conversion is performed to obtain the first image data optimized by wide dynamic range.
[0024] Further, the recognition result is obtained, including: when the single algorithm score in the preset algorithm module meets the scene corresponding threshold, directly outputting the recognition success result; when the single algorithm score does not meet the scene corresponding threshold, analyzing the error code and generating a scene guide.
[0025] Further, the preset scene parameter library includes platform preset scene parameters and actual use environment preset parameters.
[0026] In a second aspect, the application further provides a single-camera-based multi-algorithm identification control type payment system, comprising:
[0027] A data acquisition module is configured to capture image data frames containing face and palmprint features based on a preset distance through a deployed single camera.
[0028] A standardized data acquisition module is configured to perform multi-step optimization on the image data frames through an image preprocessing unit, and output standardized image data to corresponding algorithm modules.
[0029] An identification result acquisition module is configured to obtain identification results based on preset algorithm modules, and output identification results in a unified format.
[0030] A decision result acquisition module is configured to execute dynamic decision logic based on identification results and a preset scene parameter library to obtain decision results.
[0031] A transaction result return module is configured to encrypt and transmit user information and transaction data to a payment platform based on decision results, and return transaction results after the payment platform completes fee deduction or offline transaction accounting.
[0032] In a third aspect, the application provides an electronic device, comprising:
[0033] One or more processors, a memory, and one or more computer programs, wherein the one or more computer programs are stored in the memory, and the one or more computer programs include instructions that, when executed by the device, cause the device to perform the single-camera-based multi-algorithm identification control type payment method of the first aspect.
[0034] In a fourth aspect, the application provides a computer-readable storage medium having a computer program stored therein, which, when executed on a computer, causes the computer to perform the single-camera-based multi-algorithm identification control type payment method of the first aspect.
[0035] In a fifth aspect, the application provides a computer program, which, when executed by a computer, is configured to perform the single-camera-based multi-algorithm identification control type payment method of the first aspect.
[0036] In a possible design, the program in the fifth aspect can be stored in whole or in part on a storage medium packaged with the processor, or in part or in whole on a storage medium not packaged with the processor.
[0037] The application has the following beneficial effects:
[0038] 1. This application uses a single camera to capture facial and palm print images, which can achieve image capture without deploying dedicated hardware equipment, reducing hardware costs and improving the continuity of image capture operations during the payment process.
[0039] 2. The dynamic decision-making mechanism of this application makes dynamic decisions on the recognition threshold and other parameters. By dynamically modifying the recognition threshold and other parameters, the recognition success rate in complex environments is greatly improved, and the applicability to the elderly is more friendly than the traditional method.
[0040] 3. This application can initiate a payment request through encrypted data after receiving payment information. In special circumstances such as network outages, offline credit payment can be realized, and a deduction record can be formed while ensuring payment security. Attached Figure Description
[0041] Figure 1 This is a flowchart of a multi-algorithm recognition and control payment method based on a single camera, according to an embodiment of this application.
[0042] Figure 2 This is a flowchart illustrating the multi-algorithm recognition result control payment process in an embodiment of this application.
[0043] Figure 3 This is a flowchart of a multi-algorithm recognition and control payment system based on a single camera, according to an embodiment of this application. Detailed Implementation
[0044] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein in the specification of the application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application; the terms "comprising" and "having," and any variations thereof, in the specification, claims, and foregoing drawings of this application, are intended to cover non-exclusive inclusion. The terms "first," "second," etc., in the specification, claims, or foregoing drawings of this application are used to distinguish different objects, not to describe a particular order.
[0045] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0046] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.
[0047] Please refer to Figure 1 The following is a flowchart of a multi-algorithm recognition and control payment method based on a single camera, provided as an embodiment of this application. The specific implementation steps are as follows:
[0048] Step S1: Based on a preset distance, capture image data frames containing facial and palm print features using a single deployed camera.
[0049] It should be noted that the preset distance in this embodiment is the area 20-80cm away from a single camera.
[0050] It should be noted that the single camera used in this embodiment is a single camera equipped with an advanced image signal processor, with a resolution of 2 megapixels and a frame rate of 30fps. During the deployment of a single camera, the deployment can be based on the actual situation; the use of a single camera in this embodiment is merely an example.
[0051] It should be noted that the deployed single camera can simultaneously select both the face and palm print area.
[0052] Step S2: The image data frame is optimized through multiple steps by the image preprocessing unit, and the output standardized image data is distributed to the corresponding algorithm module.
[0053] In this embodiment of the application, when the acquired image data frame is blurry or occluded, the frame is discarded and reacquired.
[0054] In the embodiments of this application, the multi-step optimization performed by the image preprocessing unit includes wide dynamic range optimization, grayscale processing, and size standardization of the image data frame.
[0055] In this embodiment of the application, wide dynamic range optimization of image data frames includes:
[0056] The pixel coordinates of the face bounding box or palm print bounding box are obtained based on the preset detector. Based on the pixel coordinate information, the local face image and the local palm image are extracted from the image data frame.
[0057] The face and hand images are segmented into different regions, and the average brightness of each region is calculated. When the brightness contrast of adjacent regions exceeds a preset threshold, the image data frame is considered to be overexposed or underexposed.
[0058] For image frame regions that are overexposed or underexposed, wide dynamic range optimization is used to obtain the first image data.
[0059] In this embodiment of the application, for image frame regions that are overexposed or underexposed, wide dynamic range optimization is used to obtain first image data, including:
[0060] The image of a face and a hand is converted into a color space with luminance-chrominance separation, and the luminance component and the retained chrominance component are output.
[0061] Bilateral filtering is applied to the luminance component to obtain a smooth local illumination map.
[0062] Based on the luminance component and local illumination map, the initial correction coefficients are obtained through a nonlinear tone mapping function.
[0063] The initial correction coefficients are multiplied pixel by pixel by the weight map to obtain the final correction coefficients.
[0064] The luminance component is adjusted by a final correction factor to obtain the optimized luminance component.
[0065] The optimized luminance component is combined with the retained chrominance component, and an inverse color space conversion is performed to obtain the first image data optimized for wide dynamic range.
[0066] In this embodiment, the process of obtaining the weight map is as follows: initialize a weight matrix with the same size as the original image data frame, initialize all pixel values in the weight matrix as a background base weight, obtain the pixel coordinates of the face bounding box region or palm print bounding box region by a preset detector, determine the key region that needs to be optimized, traverse all pixels in the key region that needs to be optimized, set the value of the weight matrix of the key region to the highest weight, and generate a weight map with the same size as the original image based on the highest weight and the background base weight.
[0067] In this embodiment, the highest weight is set to 1, and a background base weight is set for the background area outside the critical area, with the value of the background base weight being less than 1. This application uses a weight map to perform wide dynamic range optimization on image data frames, distinguishing between parts that need optimization and those that do not.
[0068] In this embodiment of the application, the YOLO algorithm is used as a detector to detect the face region or the palm region and obtain the pixel coordinates of the face region or the palm region.
[0069] It should be noted that this application reduces color interference by performing grayscale processing on image data frames optimized for wide dynamic range.
[0070] It should be noted that the embodiments of this application standardize the image size, uniformly outputting a 640×480 pixel image. The specific image size standardization depends on the specific settings, and the image size standardization in the embodiments of this application is merely an example.
[0071] In the embodiments of this application, overexposure / underexposure problems caused by backlight / strong light can be eliminated by optimizing image data frames with wide dynamic range.
[0072] Step S3: Based on the preset algorithm module, obtain the recognition results and output the recognition results in a unified format.
[0073] In this embodiment of the application, obtaining the recognition result includes: when the score of a single algorithm in the preset algorithm module meets the threshold corresponding to the scene, the recognition success result is directly output; when the score of a single algorithm does not meet the threshold corresponding to the scene, the error code is parsed and scene-based guidance is generated.
[0074] In this embodiment, the preset algorithm module includes a palmprint recognition module and a face recognition algorithm module. This application can use existing third-party palmprint recognition modules and third-party face recognition algorithm modules to realize the recognition of faces and palmprints.
[0075] It should be noted that when the score of a single algorithm in the preset algorithm module meets the threshold corresponding to the scene, that is, the score of a single algorithm is greater than or equal to the threshold corresponding to the scene, such as a palm print threshold of 75 points and a face threshold of 80 points.
[0076] It should be noted that contextualized guidance is generated, such as prompts like "Please place your palm close to the camera" and "Do not cover your face."
[0077] It should be noted that the output recognition results should be in a uniform format, which may include recognition scores, confidence levels, and error codes.
[0078] Step S4: Preset scene parameter library, execute dynamic decision logic based on recognition results, and obtain decision results.
[0079] In this embodiment of the application, the preset scenario parameter library includes platform preset scenario parameters and actual usage environment preset parameters.
[0080] It should be noted that the platform's preset scene parameters include palmprint + face hybrid recognition, face only, and palmprint only modes.
[0081] It should be noted that the platform's preset scene parameters support backend configuration, and each mode can preset algorithm priorities and decision thresholds. The palmprint + face hybrid recognition is an adaptive mode, which processes the preview data frames and distributes them to various algorithm recognition modules, uniformly processing the recognition results returned by each algorithm. The palmprint-only mode is suitable for scenarios where the customer does not collect facial data, or during peak periods such as epidemics or flu seasons (when users generally wear masks), or when facial features are impaired (e.g., facial injuries). It only uses the palmprint algorithm, with a fixed recognition threshold of 75 points (which can be modified in the backend). The face-only mode is suitable for scenarios where the customer does not collect palmprint data, or when the user's hand is injured, disabled, or has unclear palm features (e.g., palmprint wear from long-term heavy physical labor). It only uses the face algorithm, with a fixed recognition threshold of 80 points.
[0082] It should be noted that the preset parameters for actual use include preset recognition thresholds and whether recognition with a mask is supported.
[0083] It should be noted that the dynamic decision-making logic includes: when a recognition failure occurs within a preset time period, the application dynamically modifies preset scene parameters, such as the recognition threshold, to improve recognition efficiency while ensuring recognition accuracy. After the preset scene parameters are dynamically modified, steps S1-S4 continue to be executed until the score of a single algorithm meets the threshold corresponding to the scene, at which point a successful recognition result is output.
[0084] Step S5: Based on the decision result, encrypt and transmit user information and transaction data to the payment platform. After the payment platform completes the deduction or successfully records the offline transaction, it returns the transaction result.
[0085] It should be noted that, after receiving the decision result, the payment integration module in this application embodiment encrypts and transmits user information and transaction data to the payment platform (transmission time ≤ 200ms); after the payment platform completes the deduction or offline transaction accounting, it returns the transaction success / failure result; the integration module transmits the result to the display screen, showing "Payment successful, amount XX yuan" or "Payment failed, please try again", and at the same time plays auxiliary prompt voice through the device speaker.
[0086] It should be noted that in the embodiments of this application, when recognition fails multiple times in a row, the algorithm priority is automatically switched. While ensuring recognition accuracy, the threshold is dynamically adjusted appropriately, for example, by reducing it by 2-3 points.
[0087] It should be noted that this application establishes multiple payment strategies to ensure the reliability and success rate of payments. When a payment channel experiences network anomalies or other failures, it automatically retryes. The retry interval and the maximum number of retries can be configured by backend parameters. If the payment still fails after reaching the maximum number of retries, an offline payment strategy is adopted, recording information such as personnel information, payment amount, and timestamp, which is then asynchronously uploaded to the payment platform by the backend for supplementary deduction.
[0088] During peak payment periods, if N consecutive online payment attempts fail (the number can be controlled by platform parameters), an offline payment strategy will be automatically activated, and online payment attempts will no longer be attempted to avoid waiting for each transaction due to network issues. This ensures a convenient experience for most regular customers while guaranteeing that payment tasks are not lost. After the peak period, normal transaction mode will resume.
[0089] By controlling payment strategies, efficient settlement is achieved in scenarios with multiple customers making concurrent payments. While ensuring payment security, the convenience of contactless payment is maintained to the greatest extent, which can significantly improve operational efficiency and customer satisfaction in restaurants and other scenarios.
[0090] Please refer to Figure 2The following is a flowchart of the multi-algorithm recognition result control payment process according to an embodiment of this application. The specific implementation process is as follows:
[0091] The image acquisition module 101 acquires face image data frames and / or palmprint image data frames. The image preprocessing unit 102 performs wide dynamic range optimization, grayscale processing, and size standardization on the face image data frames and / or palmprint image data frames to obtain standardized image data frames. These standardized data frames are then input into the multi-algorithm access module 103. The multi-algorithm access module calls a third-party face algorithm 104 or a third-party palmprint algorithm 105. Based on the unified format recognition results acquired by the multi-algorithm access module 107, dynamic decision-making is performed. If the decision result is successful, the system proceeds to the payment integration module 110, where the transaction result is output through the backend payment platform 111. If the decision result is unsuccessful, the system proceeds to the exception handling unit 112, where a message is sent to the user through the user prompt unit 109. Simultaneously, the mode configuration module 108 dynamically adjusts the parameters of the algorithm decision-making module.
[0092] Please refer to Figure 3 The following is a schematic diagram of a multi-algorithm recognition and control payment system based on a single camera, provided in an embodiment of this application.
[0093] The data acquisition module 301 is used to capture image data frames containing facial and palm print features using a deployed single camera based on a preset distance.
[0094] The standardized data acquisition module 302 is used to perform multi-step optimization on the image data frame through the image preprocessing unit and output standardized image data to the corresponding algorithm module.
[0095] The recognition result acquisition module 303 is used to acquire recognition results based on a preset algorithm module and output recognition results in a unified format.
[0096] The decision result acquisition module 304 is used to preset the scene parameter library, execute dynamic decision logic based on the recognition results, and acquire decision results.
[0097] The transaction result return module 305 is used to encrypt and transmit user information and transaction data to the payment platform based on the decision result. After the payment platform completes the deduction or successfully records the offline transaction, it returns the transaction result.
[0098] Obviously, the embodiments described above are only some embodiments of this application, not all embodiments. The accompanying drawings show preferred embodiments of this application, but do not limit the patent scope of this application. This application can be implemented in many different forms; rather, the purpose of providing these embodiments is to provide a more thorough and comprehensive understanding of the disclosure of this application. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing specific embodiments, or make equivalent substitutions for some of the technical features. Any equivalent structures made using the content of this application's specification and drawings, directly or indirectly applied to other related technical fields, are similarly within the scope of patent protection of this application.
Claims
1. A multi-algorithm recognition and control payment method based on a single camera, characterized in that, include: Based on a preset distance, image data frames containing facial and palm print features are captured by a single deployed camera; The image preprocessing unit performs multi-step optimization on the image data frame and outputs standardized image data which is then distributed to the corresponding algorithm module. Based on the preset algorithm module, the recognition results are obtained and output in a unified format; A pre-defined scene parameter library is used to execute dynamic decision-making logic based on the recognition results and obtain the decision results. Based on the decision, user information and transaction data are encrypted and transmitted to the payment platform. After the payment platform completes the deduction or successfully records the offline transaction, it returns the transaction result.
2. The multi-algorithm recognition and control payment method based on a single camera according to claim 1, characterized in that, The deployed single camera can simultaneously select the face and palm print area.
3. The multi-algorithm recognition and control payment method based on a single camera according to claim 1, characterized in that, The image preprocessing unit performs multi-step optimization on the image data frame, including wide dynamic range optimization, grayscale processing, and size standardization.
4. The multi-algorithm recognition and control payment method based on a single camera according to claim 1, characterized in that, Wide dynamic range optimization of image data frames includes: The pixel coordinates of the face bounding box region or palm print bounding box region are obtained based on the preset detector, and the local face image and palm image are extracted from the image data frame based on the pixel coordinate information. The face and hand images are segmented into different regions, and the average brightness of each region is calculated. When the brightness contrast of adjacent regions exceeds a preset threshold, the image data frame is overexposed or underexposed. For image frame regions that are overexposed or underexposed, wide dynamic range optimization is used to obtain the first image data.
5. The multi-algorithm recognition and control payment method based on a single camera according to claim 4, characterized in that, For image frame regions that are overexposed or underexposed, wide dynamic range optimization is used to obtain the first image data, including: Convert partial images of a face and a hand into a color space with luminance-chrominance separation, and output the luminance component and the retained chrominance component; Bilateral filtering is applied to the luminance component to obtain a smooth local illumination map; Based on the luminance component and local illumination map, the initial correction coefficients are obtained through a nonlinear tone mapping function; The initial correction coefficients are multiplied pixel by pixel by the weight map to obtain the final correction coefficients; The luminance component is adjusted by a final correction factor to obtain the optimized luminance component; The optimized luminance component is combined with the retained chrominance component, and an inverse color space conversion is performed to obtain the first image data optimized for wide dynamic range.
6. The multi-algorithm recognition and control payment method based on a single camera according to claim 1, characterized in that, Obtaining recognition results includes: when the score of a single algorithm in the preset algorithm module meets the threshold corresponding to the scene, directly outputting a successful recognition result; when the score of a single algorithm does not meet the threshold corresponding to the scene, parsing the error code and generating scene-specific guidance.
7. The multi-algorithm recognition and control payment method based on a single camera according to claim 1, characterized in that, The preset scene parameter library includes platform preset scene parameters and actual usage environment preset parameters.
8. A multi-algorithm recognition and control payment system based on a single camera, used to implement the multi-algorithm recognition and control payment method based on a single camera as described in claims 1-7, characterized in that, include: The data acquisition module is used to capture image data frames containing facial and palm print features using a single deployed camera based on a preset distance. The standardized data acquisition module is used to perform multi-step optimization on the image data frame through the image preprocessing unit, and output standardized image data to be distributed to the corresponding algorithm module. The recognition result acquisition module is used to acquire recognition results based on the preset algorithm module and output the recognition results in a unified format. The decision result acquisition module is used to preset a scenario parameter library, execute dynamic decision logic based on the recognition results, and obtain decision results; The transaction result return module is used to encrypt and transmit user information and transaction data to the payment platform based on the decision result. After the payment platform completes the deduction or successfully records the offline transaction, it returns the transaction result.
9. An electronic device, characterized in that, include: One or more processors; Memory, used to store one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the multi-algorithm recognition and control payment method based on a single camera as described in any one of claims 1-7.
10. A computer-readable storage medium storing computer instructions thereon, characterized in that, When executed by the processor, this instruction implements the steps of the single-camera-based multi-algorithm recognition and control payment method as described in any one of claims 1-7.