Financial card number automatic recognition method and system based on digital image processing

Through the financial card number automatic identification system based on digital image processing, the existing bank card number identification system has solved the problem of high time-consuming and difficult to deal with pictures with large rotation angles, and efficient and accurate identification of bank card number is achieved, reducing economic losses and manual entry costs.

CN119007211BActive Publication Date: 2025-03-21QINGDAO OTC CLEARING CENT CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411463158.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-21
Publication Date
2025-03-21
Estimated Expiration
2044-10-21

AI Technical Summary

Technical Problem

The existing bank card number identification system is time-consuming and difficult to process pictures with large rotation angles. Due to the limitations of the magnetic stripes, there is a problem of forgetting to pick up the card and wear of the magnetic stripes, which increases economic losses and manual entry costs.

Method used

The automatic identification system of financial card number based on digital image processing is adopted, including the financial card image acquisition module, the image correction module, the digital identification module and the verification module. Through the steps of preliminary image judgment, correction, identification and verification, automatic identification of bank card number is realized.

Benefits of technology

It improves the accuracy and efficiency of bank card number identification, reduces manual entry costs, and avoids economic losses caused by wear of magnetic stripes and forgetting to take the card.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119007211B_ABST
    Figure CN119007211B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of automatic identification of financial card numbers, and discloses an automatic identification method and system for financial card numbers based on digital image processing, comprising a financial card image acquisition module, a financial card image correction module, a financial card number image recognition module and a financial card number verification module, wherein the financial card image acquisition module comprises an image input unit and an image preliminary judgment unit, the financial card image correction module makes a judgment based on the image data of the complete financial card judged by the image preliminary judgment unit, and the financial card number image recognition module comprises a digital recognition unit and a stain judgment unit. The system first judges whether the financial card is complete, and if it is judged that the financial card is complete, the correction is directly performed, and if it is judged that the financial card is incomplete, the user is prompted to re-shoot, until it is judged to be complete, the image data is sent to the financial card image correction module for correction, and the deflection angle of the image is adjusted to ensure the accuracy of identification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of automatic identification of financial card numbers, and in particular to a method and system for automatic identification of financial card numbers based on digital image processing. Background Art

[0002] Character recognition technology based on digital image processing is based on optical imaging and uses the powerful processing capabilities of digital image processing software to achieve its recognition function. Arabic numerals, as universal numerals, play an important role in various fields such as economy and life. Therefore, automatic digital recognition technology has high practicality. Nowadays, the theoretical methods of handwritten and printed digital recognition are constantly updated and mainly used in daily life such as bill face value recognition, traffic management car license plate recognition system, apartment management house number recognition, etc. Bank cards are closely related to social life. Applying digital recognition technology to bank card number recognition has high practicality. However, due to our There are many types of bank cards in China, and the background of the card surface is quite complicated. Bank card number recognition is much more difficult than simple digital recognition. At present, there is no automatic bank card number recognition system based on digital image processing. The existing more mature bank card number recognition systems are generally based on magnetic stripe reading, which requires the insertion of a bank card. When withdrawing money at an ATM, it is easy to forget to take the card due to negligence, resulting in economic losses. In addition, the life of the magnetic stripe is limited. After a certain number of swipes, the magnetic stripe will be worn to varying degrees, causing the bank card to become invalid. In addition, as the number of people using bank cards becomes wider and wider, the cost of manual entry of a large number of bank card number images of users by merchants is gradually increasing.

[0003] At present, most bank card number images are processed through bank card text recognition systems. However, most traditional bank card text recognition systems are based on template matching algorithms, that is, searching for image areas that match their template images in the image. The recognition algorithm of this recognition system is time-consuming and cannot provide good recognition results for images with large rotation angles. Summary of the invention

[0004] 1. Technical issues to be resolved

[0005] In view of the deficiencies in the prior art, the present invention provides a method and system for automatic recognition of financial card numbers based on digital image processing, which has the advantages of unifying the angle of the card number image and ensuring recognition accuracy, thereby solving the above technical problems.

[0006] (II) Technical solution

[0007] To achieve the above-mentioned object, the present invention provides the following technical solutions: a financial card number automatic recognition system based on digital image processing, comprising a financial card image acquisition module, a financial card image correction module, a financial card number image recognition module and a financial card number verification module;

[0008] The financial card image acquisition module includes an image input unit and an image preliminary judgment unit. The image input unit is used to receive the image data of the financial card uploaded by the user's mobile phone, and send the received image data of the financial card to the image preliminary judgment unit, and judge whether the financial card is complete. If it is judged that the financial card is incomplete, the user is prompted to re-take the photo. If it is judged that the financial card is complete, the photographed image data of the financial card is sent to the financial card image correction module. The image input unit also reads the user's mobile phone data, and at the same time collects the number and total number of first shots that pass the complete judgment with the same model of mobile phone used by the current user for shooting and collection, and calculates the weight ratio of the mobile phone model;

[0009] The financial card image correction module makes a judgment based on the image data of the complete financial card judged by the image preliminary judgment unit. If it is judged that the image data of the financial card needs to be corrected, the image data of the financial card is corrected and the corrected image data is output to the financial card number recognition module for recognition. If it is judged that the image data of the financial card does not need to be corrected, the image data of the financial card is directly sent to the financial card number image recognition module.

[0010] The financial card number image recognition module includes a digit recognition unit and a stain judgment unit. The digit recognition unit is used to recognize the digits in the image data of the financial card, and send the recognized financial card number to the stain judgment unit for stain judgment, and send the financial card number judged by the stain judgment unit to the financial card number verification module for verification;

[0011] The financial card number verification module includes a user information collection unit and a user financial card number verification unit. The user information collection unit is used to collect all financial card numbers of the user on the currently uploaded financial platform. The user financial card number verification unit is used to verify the card number identified by the financial card number image recognition module.

[0012] As a preferred technical solution of the present invention, the specific steps of the image preliminary judgment unit judging whether the image data of the financial card uploaded by the user is complete are as follows:

[0013] Step A1: select the uploaded image data with a minimum rectangle and crop it;

[0014] Step A2: after the cropping is completed, the ratio of the area of ​​the currently selected image data to the area of ​​the original image data is calculated;

[0015] Step A3: When the ratio calculated in step A2 is lower than the set threshold, the financial card is judged to be incomplete.

[0016] As a preferred technical solution of the present invention, the calculation expression in step A2 is as follows:

[0017] ;

[0018] in, Indicates the ratio of the area of ​​the current frame-selected image data to the area of ​​the original image data. Indicates the area of ​​the current selected image data. Represents the area of ​​the original image data, Indicates the weight ratio of mobile phone models.

[0019] As a preferred technical solution of the present invention, the expression of the weight ratio of the mobile phone models is as follows:

[0020] ;

[0021] in, Indicates The weight ratio of the mobile phone models, Indicates The number of times the first shot of the mobile phone passed the complete judgment, Indicates The total number of times the mobile phone has taken photos and uploaded them.

[0022] As a preferred technical solution of the present invention, the steps of correcting the image data of the financial card by the financial card image correction module are as follows:

[0023] Step B1: Establish an XOY coordinate system with the center point of the image data selected in the image preliminary judgment unit as the origin, and determine the coordinates of the four boundary points of the image data selected in the image preliminary judgment unit. , , , ;

[0024] Step B2: calculating the deflection degree corresponding to the image data of the financial card based on the boundary point coordinates to obtain a lateral deflection value and a longitudinal deflection value;

[0025] Step B3: Obtain a torsion angle according to the lateral deflection value and the longitudinal deflection value, and twist the image according to the torsion angle.

[0026] As a preferred technical solution of the present invention, the calculation expression of step B2 is as follows:

[0027] Lateral torsion value:

[0028] ;

[0029] Longitudinal torsion value:

[0030] ;

[0031] in, represents the lateral torsion value, represents the longitudinal torsion value, represents the inverse tangent trigonometric function, represents the absolute value, , , , They respectively represent the coordinates of the four boundary points of the image data selected in the image data preliminary judgment unit.

[0032] As a preferred technical solution of the present invention, the expression calculated in step B3 is as follows:

[0033] ;

[0034] in, represents the torsion angle, represents the lateral torsion value, Indicates the longitudinal torsion value.

[0035] As a preferred technical solution of the present invention, the expression for stain judgment performed by the stain judgment unit is as follows:

[0036] ;

[0037] in, Indicates the area of ​​the stain, Indicates the stain judgment ratio, Indicates the area of ​​the current selected image data.

[0038] As a preferred technical solution of the present invention, the specific steps of the verification by the user financial card number verification unit are as follows:

[0039] Step C1: Difference the identified card number with all the financial card numbers uploaded by the user on the financial platform, bit by bit;

[0040] Step C2: determine whether the difference result in step C1 is 0. If it is 0, the recognition is correct, and the recognized card number is displayed to the user.

[0041] The present invention also provides a method for automatic identification of financial card numbers based on digital image processing, which uses the above-mentioned automatic identification system for financial card numbers based on digital image processing, and comprises the following steps:

[0042] Step 1: The user takes a photo of the current bank card and uploads the image data of the bank card to the image recording unit, which then sends the photo to the image preliminary judgment unit to judge whether the bank card is complete. If the card is incomplete, the user is prompted to take a photo again. If the card is complete, step 2 is executed.

[0043] Step 2: determine whether the image data of the financial card needs to be corrected. If so, correct the image data of the financial card and execute step 3. If not, directly execute step 3.

[0044] Step 3: Identify the bank card number, perform stain determination, output the bank card number, and verify the card number.

[0045] Compared with the prior art, the present invention provides a method and system for automatically identifying financial card numbers based on digital image processing, which has the following beneficial effects:

[0046] The present invention first determines whether the financial card is complete. If it is determined that the financial card is complete, the user is not prompted to retake the photo. If it is determined that the financial card is incomplete, the user is prompted to retake the photo. After the financial card is determined to be complete, the image data is sent to the financial card image correction module for correction, thereby adjusting the deflection angle of the image so that the image direction is roughly consistent, thereby ensuring the accuracy of recognition. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] Figure 1 It is a schematic diagram of the system framework of the present invention;

[0048] Figure 2 It is a schematic diagram of the process of the present invention. DETAILED DESCRIPTION

[0049] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0050] See also Figure 1-Figure 2 , a financial card number automatic recognition system based on digital image processing, including a financial card image acquisition module, a financial card image correction module, a financial card number image recognition module and a financial card number verification module;

[0051] The financial card image acquisition module includes an image entry unit and an image preliminary judgment unit. The image entry unit is used to receive the image data of the financial card uploaded by the user's mobile phone, and send the received image data of the financial card to the image preliminary judgment unit, and judge whether the financial card is complete. If it is judged that the financial card is incomplete, the user is prompted to re-shoot. If it is judged that the financial card is complete, the image data of the photographed financial card is sent to the financial card image correction module. The image entry unit also includes reading the user's mobile phone data, and at the same time collecting the number of times and the total number of times that the first shooting passes the complete judgment with the same model of mobile phone used by the current user for shooting and collection, and calculating the weight ratio of the mobile phone model. The specific steps of the image preliminary judgment unit judging whether the financial card in the image data of the financial card uploaded by the user is complete are as follows:

[0052] Step A1: select the uploaded image data with a minimum rectangle and crop it;

[0053] Step A2: After the cropping is completed, the ratio of the area of ​​the current framed image data to the area of ​​the original image data is calculated. The calculation expression in step A2 is as follows:

[0054] ;

[0055] in, Indicates the ratio of the area of ​​the current frame-selected image data to the area of ​​the original image data. Indicates the area of ​​the current selected image data. Represents the area of ​​the original image data, Indicates the weight ratio of the mobile phone model. By introducing the data of the user's corresponding mobile phone model, the user's mobile phone status at the time can be obtained to consider the objective factors that occur during the mobile phone shooting process;

[0056] Step A3: When the ratio calculated in step A2 is lower than the set threshold, the financial card is judged to be incomplete. The weight ratio of the mobile phone model is expressed as follows:

[0057] ;

[0058] in, Indicates The weight ratio of the mobile phone models, Indicates The number of times the first shot of the mobile phone passed the complete judgment, Indicates The total number of times the mobile phone has uploaded photos and videos;

[0059] The financial card image correction module makes a judgment based on the image data of the complete financial card judged by the image preliminary judgment unit. If it is judged that the image data of the financial card needs to be corrected, the image data of the financial card is corrected and the corrected image data is output to the financial card number recognition module for recognition. If it is judged that the image data of the financial card does not need to be corrected, the image data of the financial card is directly sent to the financial card number image recognition module.

[0060] The steps for image correction in the financial card image correction module are as follows:

[0061] Step B1: Establish an XOY coordinate system with the center point of the image data selected in the image preliminary judgment unit as the origin, and determine the coordinates of the four boundary points of the image data selected in the image preliminary judgment unit. , , , ;

[0062] Step B2: Calculate the deflection degree corresponding to the image data of the financial card based on the boundary point coordinates to obtain a lateral deflection value and a longitudinal deflection value. The calculation expression of step B2 is as follows:

[0063] Lateral torsion value:

[0064] ;

[0065] Longitudinal torsion value:

[0066] ;

[0067] in, represents the lateral torsion value, represents the longitudinal torsion value, represents the inverse tangent trigonometric function, represents the absolute value, , , , They respectively represent the coordinates of the four boundary points of the image data selected in the image data preliminary judgment unit. By analyzing the horizontal and vertical torsion values, the torsion of the image can be well obtained.

[0068] Step B3: Obtain a torsion angle according to the lateral deflection value and the longitudinal deflection value, and twist the image according to the torsion angle. The expression calculated in step B3 is as follows:

[0069] ;

[0070] in, represents the torsion angle, represents the lateral torsion value, Indicates the longitudinal torsion value.

[0071] The financial card number image recognition module includes a digital recognition unit and a stain judgment unit. The digital recognition unit is used to recognize the digital in the image data of the financial card, and send the recognized financial card number to the stain judgment unit for stain judgment. The financial card number judged by the stain judgment unit is sent to the financial card number verification module for verification. The expression of stain judgment by the stain judgment unit is as follows:

[0072] ;

[0073] in, Indicates the area of ​​the stain, Indicates the stain judgment ratio, Indicates the area of ​​the currently selected image data, the identification of the stains there, and reminds the user to clean the card when the degree of stains on the card surface is high.

[0074] The financial card number verification module includes a user information collection unit and a user financial card number verification unit. The user information collection unit is used to collect all financial card numbers of the user on the currently uploaded financial platform. The user financial card number verification unit is used to verify the card number identified by the financial card number image recognition module. The specific steps of the user financial card number verification unit are as follows:

[0075] Step C1: Difference the identified card number with all the financial card numbers uploaded by the user on the financial platform, bit by bit;

[0076] Step C2: determine whether the difference result in step C1 is 0. If it is 0, the recognition is correct, and the recognized card number is displayed to the user.

[0077] Embodiment 1:

[0078] For user A, the area of ​​the current framed image captured by him is , the area of ​​the original image data , No. Weight ratio of mobile phone models ,at this time At this time, the image is judged to be complete and the image data is sent to the financial card image correction module for correction. At this time, the coordinates of the four points are , , , ;

[0079] At this time, calculate the lateral torsion value:

[0080] ;

[0081] ;

[0082] at this time , at this time the deflection Get the existing image;

[0083] Embodiment 2:

[0084] For user B, the area of ​​the current framed image captured by him is , the area of ​​the original image data , No. Weight ratio of mobile phone models ,at this time At this time, the image is judged to be incomplete. After it is judged to be complete, the image data is sent to the financial card image correction module for correction. At this time, the coordinates of the four points are , , , ;

[0085] At this time, the lateral torsion value and the longitudinal torsion value are calculated:

[0086] ;

[0087] ;

[0088] at this time , at this time the deflection An existing image is obtained. For a small angle adjustment in the first embodiment, no deflection is required. However, for a large twist in the second embodiment, the corresponding angle of the image needs to be adjusted first, so as to ensure the centering of the image. First, it is determined whether the financial card is complete. If it is determined that the financial card is complete, the user is not prompted to retake the photo. If it is determined that the financial card is incomplete, the user is prompted to retake the photo. After it is determined to be complete, the image data is sent to the financial card image correction module for correction, so as to adjust the deflection angle of the image so that the image direction is roughly consistent, thereby ensuring the recognition accuracy.

[0089] The present invention also provides a method for automatic identification of financial card numbers based on digital image processing, which uses the above-mentioned automatic identification system for financial card numbers based on digital image processing, and comprises the following steps:

[0090] Step 1: The user takes a photo of the current bank card and uploads the image data of the bank card to the image recording unit, which then sends the photo to the image preliminary judgment unit to judge whether the bank card is complete. If the card is incomplete, the user is prompted to take a photo again. If the card is complete, step 2 is executed.

[0091] Step 2: determine whether the image data of the financial card needs to be corrected. If so, correct the image data of the financial card and execute step 3. If not, directly execute step 3.

[0092] Step 3: Identify the bank card number, perform stain determination, output the bank card number, and verify the card number.

[0093] While the embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that many changes, modifications, substitutions and variations can be made to the embodiments without departing from the principles and spirit of the invention.

Claims

1. A financial card number automatic recognition system based on digital image processing, characterized in that: It includes a financial card image acquisition module, a financial card image correction module, a financial card number image recognition module and a financial card number verification module; The financial card image acquisition module includes an image input unit and an image preliminary judgment unit. The image input unit is used to receive the image data of the financial card uploaded by the user's mobile phone, and send the received image data of the financial card to the image preliminary judgment unit, and judge whether the financial card is complete. If it is judged that the financial card is incomplete, the user is prompted to re-take the photo. If it is judged that the financial card is complete, the photographed image data of the financial card is sent to the financial card image correction module. The image input unit also reads the user's mobile phone data, and at the same time collects the number and total number of first shots that pass the complete judgment with the same model of mobile phone used by the current user for shooting and collection, and calculates the weight ratio of the mobile phone model; The financial card image correction module makes a judgment based on the image data of the complete financial card judged by the image preliminary judgment unit. If it is judged that the image data of the financial card needs to be corrected, the image data of the financial card is corrected and the corrected image data is output to the financial card number recognition module for recognition. If it is judged that the image data of the financial card does not need to be corrected, the image data of the financial card is directly sent to the financial card number image recognition module. The financial card number image recognition module includes a digit recognition unit and a stain judgment unit. The digit recognition unit is used to recognize the digits in the image data of the financial card, and send the recognized financial card number to the stain judgment unit for stain judgment, and send the financial card number judged by the stain judgment unit to the financial card number verification module for verification; The financial card number verification module includes a user information collection unit and a user financial card number verification unit. The user information collection unit is used to collect all financial card numbers of the user on the currently uploaded financial platform. The user financial card number verification unit is used to verify the card number identified by the financial card number image recognition module.

2. The financial card number automatic recognition system based on digital image processing according to claim 1, characterized in that: The specific steps of the image preliminary judgment unit judging whether the image data of the financial card uploaded by the user is complete are as follows: Step A1: select the uploaded image data with a minimum rectangle and crop it; Step A2: after the cropping is completed, the ratio of the area of ​​the currently selected image data to the area of ​​the original image data is calculated; Step A3: When the ratio calculated in step A2 is lower than the set threshold, the financial card is judged to be incomplete.

3. The financial card number automatic recognition system based on digital image processing according to claim 2, characterized in that: The calculation expression in step A2 is as follows: ; in, Indicates the ratio of the area of ​​the current frame-selected image data to the area of ​​the original image data. Indicates the area of ​​the current selected image data. Represents the area of ​​the original image data, Indicates the weight ratio of mobile phone models.

4. The financial card number automatic recognition system based on digital image processing according to claim 3, characterized in that: The expression of the weight ratio of the mobile phone model is as follows: ; in, Indicates The weight ratio of the mobile phone models, Indicates The number of times the first shot of the mobile phone passed the complete judgment, Indicates The total number of times the mobile phone has taken photos and uploaded them.

5. The financial card number automatic recognition system based on digital image processing according to claim 2, characterized in that: The steps of the financial card image correction module correcting the image data of the financial card are as follows: Step B1: Establish an XOY coordinate system with the center point of the image data selected in the image preliminary judgment unit as the origin, and determine the coordinates of the four boundary points of the image data selected in the image preliminary judgment unit. , , , ; Step B2: calculating the deflection degree corresponding to the image data of the financial card based on the boundary point coordinates to obtain a lateral deflection value and a longitudinal deflection value; Step B3: Obtain a torsion angle according to the lateral deflection value and the longitudinal deflection value, and twist the image data according to the torsion angle.

6. The financial card number automatic recognition system based on digital image processing according to claim 5, characterized in that: The calculation expression of step B2 is as follows: Lateral torsion value: ; Longitudinal torsion value: ; in, represents the lateral torsion value, represents the longitudinal torsion value, represents the inverse tangent trigonometric function, represents the absolute value, , , , They respectively represent the coordinates of the four boundary points of the image data selected in the image data preliminary judgment unit.

7. The financial card number automatic recognition system based on digital image processing according to claim 6, characterized in that: The expression calculated in step B3 is as follows: ; in, represents the torsion angle, represents the lateral torsion value, Indicates the longitudinal torsion value.

8. The financial card number automatic recognition system based on digital image processing according to claim 1, characterized in that: The stain judgment unit performs stain judgment using the following expression: ; in, Indicates the stain judgment ratio, Indicates the area of ​​the stain, Indicates the area of ​​the current selected image data.

9. The financial card number automatic recognition system based on digital image processing according to claim 1, characterized in that: The specific steps of the user financial card number verification unit for verification are as follows: Step C1: Difference the identified card number with all the financial card numbers uploaded by the user on the financial platform, bit by bit; Step C2: determine whether the difference result in step C1 is 0. If it is 0, the recognition is correct, and the recognized card number is displayed to the user.

10. A method for automatic identification of financial card numbers based on digital image processing, applied to a system for automatic identification of financial card numbers based on digital image processing as claimed in any one of claims 1 to 9, characterized in that: The following steps are involved: Step 1: The user takes a photo of the current bank card and uploads the image data of the bank card to the image recording unit, which then sends the photo to the image preliminary judgment unit to judge whether the bank card is complete. If the card is incomplete, the user is prompted to take a photo again. If the card is complete, step 2 is executed. Step 2: determine whether the image data of the financial card needs to be corrected. If so, correct the image data of the financial card and execute step 3. If not, directly execute step 3. Step 3: Identify the bank card number, perform stain determination, output the bank card number, and verify the card number.

Citation Information

Patent Citations

  • Financial self-service device and anti-peeping system and anti-peeping method thereof

    CN102610035A

  • Automatic bank card number recognition device based on digital image processing

    CN106203415A