WO2021218183A1 - Certificate edge detection method and apparatus, and device and medium - Google Patents

Certificate edge detection method and apparatus, and device and medium Download PDF

Info

Publication number
WO2021218183A1
WO2021218183A1 PCT/CN2020/136317 CN2020136317W WO2021218183A1 WO 2021218183 A1 WO2021218183 A1 WO 2021218183A1 CN 2020136317 W CN2020136317 W CN 2020136317W WO 2021218183 A1 WO2021218183 A1 WO 2021218183A1
Authority
WO
WIPO (PCT)
Prior art keywords
target image
edge detection
face
document
image
Prior art date
Application number
PCT/CN2020/136317
Other languages
French (fr)
Chinese (zh)
Inventor
黄泽浩
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2021218183A1 publication Critical patent/WO2021218183A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/16Human faces, e.g. facial parts, sketches or expressions
    • G06V40/168Feature extraction; Face representation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • G06F18/2411Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches based on the proximity to a decision surface, e.g. support vector machines
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • G06V10/44Local feature extraction by analysis of parts of the pattern, e.g. by detecting edges, contours, loops, corners, strokes or intersections; Connectivity analysis, e.g. of connected components
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/16Human faces, e.g. facial parts, sketches or expressions
    • G06V40/161Detection; Localisation; Normalisation

Definitions

  • This application relates to the technical field of financial technology (Fintech), in particular to the edge detection method, device, equipment and medium of the document.
  • the inventor realizes that when the edge of the document is damaged, it will cause a large recognition error.
  • This application provides a document edge detection method, which includes the following steps:
  • the present application also provides a document edge detection device, which includes:
  • the request receiving module is configured to obtain the target image associated with the edge detection request of the image credential when the edge detection request of the image credential is received;
  • the face recognition module is used to input the target image into a preset face recognition model, extract the face feature points in the target image, and according to the face feature points and the feature coordinates of the face feature points , Determine the face photo in the target image;
  • a credential image extraction module for extracting a credential body image containing a face photo from the target image according to the photo information of the face photo;
  • the result output module is used to input the document body image to the preset edge detection model to obtain the card edge line segment, analyze the card edge line segment, and output the certificate edge detection result.
  • the present application also provides a document edge detection device.
  • the document edge detection device includes a memory, a processor, and a computer program corresponding to the document edge detection that is stored in the memory and can run on the processor.
  • the computer program corresponding to the document edge detection is executed by the processor, the following steps are implemented:
  • the present application also provides a computer-readable storage medium on which a computer program corresponding to the edge detection of a document is stored, and when the computer program corresponding to the edge detection of the document is executed by a processor, the following steps are implemented:
  • FIG. 1 is a schematic diagram of the device structure of the hardware operating environment involved in the solution of the embodiment of the present application;
  • FIG. 2 is a schematic flowchart of a first embodiment of a method for detecting the edge of an application document
  • FIG. 3 is a schematic diagram of functional modules of an embodiment of the document edge detection device of this application.
  • FIG. 1 is a schematic diagram of the device structure of the hardware operating environment involved in the solution of the embodiment of the present application.
  • the edge detection device of the example embodiment of this application may be a server device, as shown in FIG. Among them, the communication bus 1002 is used to implement connection and communication between these components.
  • the user interface 1003 may include a display screen (Display) and an input unit such as a keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface and a wireless interface.
  • the network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface).
  • the memory 1005 may be a high-speed RAM memory, or a stable memory (non-volatile memory), such as a magnetic disk memory.
  • the memory 1005 may also be a storage device independent of the aforementioned processor 1001.
  • FIG. 1 does not constitute a limitation on the device, and may include more or fewer components than those shown in the figure, or a combination of certain components, or different component arrangements.
  • the memory 1005 which is a computer storage medium, may include an operating network communication module, a user interface module, and a computer program corresponding to the edge detection of the document.
  • the network interface 1004 is mainly used to connect to the back-end server and communicate with the back-end server; the user interface 1003 is mainly used to connect to the client (user side) to communicate with the client; and the processor 1001 can be used to call a computer program corresponding to the edge detection of a document stored in the memory 1005, and perform operations in the following method for detecting edge of a document.
  • Fig. 2 is a schematic flowchart of the first embodiment of the document edge detection method of this application.
  • the document edge detection method includes:
  • step S10 when a request for edge detection of an image certificate is received, a target image associated with the request for edge detection of an image certificate is acquired.
  • the document edge detection method in this embodiment is applied to document edge detection equipment in financial institutions (banking institutions, insurance institutions, securities institutions, etc.) in the financial industry.
  • the credential edge detection device receives the image credential edge detection request.
  • the triggering method of the image credential edge detection request is not specifically limited, that is, the image credential edge detection request can be actively triggered by the user, for example, the user clicks "on the display page of the credential edge detection device "Edge detection” button to actively trigger the image ID edge detection request; in addition, the image ID edge detection request can also be automatically triggered, for example, the ID edge detection device is preset: when a new ID scan image is received, the image ID is automatically triggered Edge detection request.
  • the credential edge detection device receives the image credential edge detection request, and the credential edge detection device obtains the target image associated with the image credential edge detection request.
  • the target image in this embodiment contains card information, and may also include other than the card.
  • Other information, in addition, the color and size of the target image are not specifically limited, for example, the target image may be color or black and white.
  • Step S20 Input the target image into a preset face recognition model, extract the face feature points in the target image, and determine the face feature point according to the face feature point and the feature coordinates of the face feature point The face photo in the target image.
  • the face recognition model is preset in the document edge detection device, that is, the document edge detection device uses the face image as sample data, and pre-trains according to the face image to obtain the preset face recognition model, and the document edge detection device inputs the target image
  • the target image is processed through the preset face recognition model
  • the document edge detection device extracts the facial feature points in the target image
  • the document edge detection device obtains the feature coordinates of the face feature points
  • the document edge detection device According to the facial feature points and the feature coordinates of the face feature points, the face photo in the target image is determined, that is, the document edge detection device analyzes the feature point coordinates of the face feature points according to the clustering algorithm, and obtains a cluster center ( x0, y0), then, the document edge detection device obtains a minimum bounding rectangle according to the feature coordinates of each facial feature point, and the document edge detecting device uses this bounding rectangle as the face photo in the target image.
  • Step S30 according to the photo information of the face photo, extract a document body image containing the face photo from the target image.
  • the document edge detection device extracts the document body image containing the face photo from the target image according to the photo information of the face photo, and the implementation method is not specifically limited:
  • Implementation method 1 The document edge detection equipment first reduces and enlarges the standard documents (standard documents can be ID cards, library cards, student cards or passports, etc.) to obtain the smallest number of document area, document length, width, and facial feature points
  • standard documents can be ID cards, library cards, student cards or passports, etc.
  • the circumscribed rectangle and the coordinates of the cluster center the document edge detection device saves the document edge detection device to save the document length, width and the corresponding aspect ratio of the circumscribed rectangle, the proportional relationship between the cluster center coordinates, and the proportional relationship between the cluster center and the distance of the document, the document edge
  • the detection device records the proportional relationship to generate a preset ID face ratio mapping table.
  • the ID edge detection device obtains the ID subject containing the face photo in the target image according to the face photo and the preset ID face ratio mapping table, for example, ,
  • the document edge detection equipment presets the document face ratio mapping table to record that the ratio of the face image of the library witness to the document body is 1:6, and the document edge detection equipment determines that the size of the face photo is 2cm*3cm, the document edge detection The device acquires an area of 4cm*9cm as the main body image of the document according to the ratio mapping relationship of the face of the document.
  • the document edge detection device determines the document body image according to the coordinates of the face image in the target image and the coordinate relationship between the document body, that is, the document edge detection device acquires the coordinates x1, y1, and the document edge detection
  • the equipment obtains the coordinates of the document body x2 and y2; the document edge detection equipment is based on x1 ⁇ x2, y1 ⁇ y2, and x1-(x2-x1)/a, x2+(x2-x1)/a, y1-(y2-y1)/a, y2+(y2-y1)/a, the document edge detection device obtains the document body image containing the face photo in the target image, where the value of a can be around 30 (it can also be changed in different situations .)
  • step S20 includes:
  • Step a1 obtaining photo information of the face photo, where the photo information includes location information and size information of the face photo;
  • Step a2 query a preset person ID mapping table, obtain the ID type corresponding to the location information, and determine ID size information according to the ID type and the size information of the face photo;
  • Step a3 Extract a document body image containing the face photo from the target image according to the document size information and the photo information of the face photo.
  • the document edge detection device obtains the photo information of the face photo, where the photo information includes the position information and size information of the face photo; Set the mapping table of photo location information and certificate type) to obtain the document type corresponding to the location information.
  • the document edge detection device determines the document size information according to the document type and the size information of the face photo; the document edge detection device determines the document size information according to the document size information and the face
  • the photo information of the photo is to extract the document body image containing the face photo from the target image.
  • the document body image containing the face photo is extracted from the target image, so as to input the document body image into the preset edge detection model to perform the document edge detection.
  • This embodiment Only the main body image of the document is processed in, which reduces the amount of data processing and further improves the efficiency and accuracy of edge detection.
  • Step S40 Input the main body image of the document into a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the document.
  • the document edge detection equipment presets the edge detection model.
  • the preset edge detection model refers to the pre-set line segment monitoring algorithm.
  • the document edge detection device inputs the main body image of the document to the preset edge detection model to obtain the card edge line segment.
  • the document edge detection equipment analyzes Card edge line segment, to determine whether the card edge line segment encloses a matrix, if the card edge line segment encloses a matrix, the document edge detection device outputs a complete document edge, if the card edge line segment does not enclose a matrix, the document edge detection device outputs a document edge incomplete .
  • the face photo in the target image is recognized, and the document body image is extracted in the reverse direction based on the face photo, so that the document body image is input to the preset edge detection model to obtain the card edge line segment, and the card edge line segment is analyzed , Output the detection result of the document edge, improve the accuracy of the document edge detection in the target image, and further improve the accuracy of the identification of the document information.
  • This embodiment is a step after step S10 in the first embodiment.
  • the difference between this embodiment and the foregoing embodiment lies in:
  • the target image does not contain a human face image, input the target image to a preset edge detection model to obtain a card edge line segment, analyze the card edge line segment, and output a document edge detection result;
  • the target image contains a face image
  • extract the face feature points in the target image and determine the face in the target image according to the face feature points and the feature coordinates of the face feature points Photo.
  • the document edge detection device inputs the target image to the preset.
  • the preset face recognition model is the same as in the first embodiment, and this embodiment will not go into details
  • the recognition result is obtained (the recognition result refers to the result of whether facial feature information is extracted), and the document edge detection device is based on
  • the recognition result determines whether the target image contains a face image; if the target image does not contain a face image, the document edge detection device inputs the target image to the preset edge detection model to obtain the card edge line segment, and the document edge detection device analyzes the card edge Line segment, output the detection result of the document edge; if the target image contains a face image, the document edge detection device extracts the facial feature points in the target image, and the document edge detection device uses the face feature points and the feature coordinates of the face feature points To determine the face photo in the target image.
  • the preset face recognition model is the same as in the first embodiment, and this embodiment will not go into details
  • the recognition result refers to the result of whether facial feature information is extracted
  • This embodiment is a step after step S10 in the first embodiment.
  • the difference between this embodiment and the foregoing embodiment lies in:
  • the inclination angle of the target image is determined according to the straight line and the direct projection, and the target image is moved backward according to the inclination angle.
  • the document edge detection device inputs the target image into the preset edge detection model.
  • the document edge detection device first detects the target image in a straight line, and the document edge detection device transforms each pixel coordinate point into a unified metric that contributes to the characteristics of the straight line.
  • a straight line is a collection of a series of discrete points in the target image.
  • the pixel coordinates P(x, y) of the image are known, and r, theta is the variable to be looked for.
  • the edge detection device of the document draws each pixel (r, theta) value
  • the document edge detection device converts the image Cartesian coordinates to the polar coordinate Hough space.
  • This transformation from point to curve is called the Hough transform of a straight line.
  • the transformation is performed by quantizing the Hough parameter space into a finite interval of values. Divide or accumulate the grid.
  • the Hough transform algorithm starts, the coordinate point P(x, y) of each pixel is converted to (r, Theta) curve points are added to the corresponding grid data points.
  • a wave crest appears it means that there is a straight line.
  • the document edge detection device determines that there is a straight line, the document edge detection device projects the straight line to obtain the projection line corresponding to the straight line.
  • the document edge detection device obtains the inclination angle of the line according to the law of cosine, and the document edge detection device rotates the target according to the inclination angle. Image to complete the angle correction of the target image.
  • the document edge detection device recognizes and rotates the target image, which improves the accuracy of recognition.
  • This embodiment is a detailed step of step S40 in the first embodiment.
  • the difference between this embodiment and the foregoing embodiment lies in:
  • the detection result of the missing corner of the card edge is output.
  • the document edge detection device inputs the main body image of the document into the preset edge detection model to obtain the edge line segment of the card.
  • the document edge detection device takes the midpoint of all the edge line segments of the card according to the discrete point classification and statistical algorithm, and performs k-nearest neighbors on all midpoints Four categories. At the same time, all points of the line segment corresponding to this midpoint belong to this cluster. Then, after the document edge detection equipment classifies each cluster, the abnormal points are removed first, and then the support vector machine is used for the second classification.
  • the document edge detection equipment counts the distance from all points of each cluster to the support vector, and the document edge detection equipment takes the cube and then divides it. Take the number of all points in this cluster.
  • the document edge detection device determines the missing corner of the card edge line segment and outputs a prompt message, and vice versa.
  • the document edge detection device inputs the main body image of the document into the preset edge detection model to obtain the edge line segment of the card.
  • the document edge detection device obtains the number of pixels contained in each edge line segment of the card, and compares the number of pixels with the preset number of points, The document edge detection device determines whether the length of the edge line segment of the card is greater than the preset number of points, where the preset number of points can be a length of 10 pixels, and if the length of the card edge line segment is less than the preset number of points, delete it.
  • the document edge detection device obtains the vertex coordinates of the remaining pixels, and then uses the k-nearest neighbor algorithm to cluster them into 4 categories to obtain the number of line segments that determine the edge line segment of the card.
  • the document edge detection device determines whether the number of line segments of the card edge line segment is greater than 4. If the number of line segments is greater than 4, the edge is considered to be incomplete, and vice versa.
  • This embodiment is a step after step S40 in the first embodiment.
  • the difference between this embodiment and the foregoing embodiment lies in:
  • the target image is classified and saved to a corresponding certificate image database.
  • the document edge detection device performs text recognition on the rectangular area enclosed by the edge line of the card to obtain the text information contained in the main image of the document.
  • the text recognition method in this embodiment is not limited.
  • the text recognition method can be OCR (Optical Character Recognition (optical character recognition)
  • the document edge detection device determines the type of the document in the target image based on the text information, and then the document edge detection device saves the target image to the corresponding document image database according to the type of the document.
  • the document edge detection device classifies and saves the target image, which can facilitate the user to find it.
  • the present application also provides a document edge detection device, the document edge detection device includes:
  • the request receiving module 10 is configured to obtain the target image associated with the edge detection request of the image credential when the edge detection request of the image credential is received;
  • the face recognition module 20 is configured to input the target image into a preset face recognition model, extract facial feature points in the target image, and based on the facial feature points and the features of the face feature points Coordinates, determine the face photo in the target image;
  • the credential image extraction module 30 is configured to extract the credential body image containing the face photo from the target image according to the photo information of the face photo;
  • the result output module 40 is used to input the document body image to a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the document.
  • the document edge detection device includes:
  • the line segment recognition module is configured to input the target image into a preset edge detection model, output a line segment recognition result, and determine whether there is a straight line in the target image according to the line segment recognition result;
  • the image movement module is configured to determine the inclination angle of the target image according to the straight line and the direct projection if there is a straight line in the target image, and move the target image in reverse according to the inclination angle.
  • the face recognition module 20 includes:
  • a recognition judgment unit configured to input the target image into a preset face recognition model, obtain a recognition result, and determine whether the target image contains a face image according to the recognition result;
  • the input detection unit is configured to, if the target image does not contain a face image, input the target image to a preset edge detection model to obtain a card edge line segment, analyze the card edge line segment, and output a document edge detection result;
  • the extraction and determination unit is configured to, if the target image contains a face image, extract the face feature points in the target image, and determine the face feature point according to the face feature point and the feature coordinates of the face feature point The face photo in the target image.
  • the credential image extraction module 30 includes:
  • An information acquisition unit for acquiring photo information of the face photo by an application, where the photo information includes location information and size information of the face photo;
  • the query determining unit is configured to query a preset person ID mapping table, obtain the ID type corresponding to the location information, and determine the ID size information according to the ID type and the size information of the face photo;
  • the image extracting unit is configured to extract the document body image containing the face photo from the target image according to the document size information and the photo information of the face photo.
  • the result output module 40 includes:
  • the image input unit is used to input the image of the main body of the certificate to the preset edge detection model to obtain the edge line segment of the card;
  • the classification processing unit is configured to process each of the edge line segments of the card according to a preset discrete point classification statistical algorithm to obtain the midpoint of the edge line segment of the card;
  • the delete classification unit is used to classify the midpoint into four nearest neighbors, regard the points on the edge line segment of the card corresponding to the same midpoint as a cluster, delete the abnormal points in each cluster, and perform the calculation on the remaining points in each cluster.
  • Support vector machine two classification
  • a statistical comparison unit configured to count the distances from all points in each cluster to the support vector, take the cube of the distance and divide by the number of all points in the cluster to obtain a calculation result, and compare the calculation result with a preset threshold;
  • the result output unit is configured to output the detection result of the missing corner of the card edge if the calculation result is greater than the preset threshold.
  • the result output module 40 includes:
  • the image input unit is used to input the image of the main body of the certificate to the preset edge detection model to obtain the edge line segment of the card;
  • the quantity comparison unit is used to obtain the number of pixels contained in each edge line segment of the card, and compare the number of pixels with a preset number of points;
  • the information quantity unit is used to delete noise card edge line segments whose number of pixels is less than the preset number of points, and process the remaining card edge line segments according to the preset clustering algorithm to obtain the number of line segments of the card edge line segment;
  • the result output unit is configured to output the detection result of the missing corner of the card edge if the number of line segments is greater than 4.
  • the document edge detection device further includes:
  • the text recognition module is used to perform text recognition on the rectangular area enclosed by the edge line segment of the card to obtain the text information contained in the main body image of the certificate;
  • the classification saving module is used to classify and save the target image to the corresponding credential image database according to the text information.
  • the method implemented when the document edge detection device is executed can refer to the various embodiments of the document edge detection method of this application, which will not be repeated here.
  • the document edge detection device recognizes the face photo in the target image and extracts the document body image in the reverse direction according to the face photo, thereby inputting the document body image to the preset edge detection model to obtain the edge line segment of the card.
  • the edge line segment of the card is analyzed, and the detection result of the edge of the document is output, which improves the accuracy of detecting the edge of the document in the target image, and further improves the accuracy of identification of the document information.
  • the present application also provides a computer-readable storage medium.
  • the computer-readable storage medium may be volatile or non-volatile.
  • the computer readable storage medium of the present application stores a computer program corresponding to the document edge detection, and when the computer program corresponding to the document edge detection is executed by a processor, the steps of the document edge detection method described above are implemented.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Oral & Maxillofacial Surgery (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Health & Medical Sciences (AREA)
  • Data Mining & Analysis (AREA)
  • Human Computer Interaction (AREA)
  • General Health & Medical Sciences (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • General Engineering & Computer Science (AREA)
  • Evolutionary Computation (AREA)
  • Evolutionary Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Artificial Intelligence (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Image Analysis (AREA)
  • Image Processing (AREA)

Abstract

A certificate edge detection method and apparatus, and a device and a medium. The method comprises: when an image certificate edge detection request is received, acquiring a target image associated with the image certificate edge detection request (S10); inputting the target image into a preset facial recognition model, extracting a facial feature point from the target image, and determining a facial photograph in the target image according to the facial feature point and a feature coordinate of the facial feature point (S20); according to photograph information of the facial photograph and from the target image, extracting a certificate main body image that includes the facial photograph (S30); and inputting the certificate main body image into a preset edge detection model, obtaining a card edge line segment, analyzing the card edge line segment, and outputting a certificate edge detection result (S40). By means of the method, the accuracy of certificate edge detection is improved.

Description

证件边沿检测方法、装置、设备及介质Certificate edge detection method, device, equipment and medium
本申请要求于2020年4月30日提交中国专利局、申请号为CN202010362784.8、名称为“证件边沿检测方法、装置、设备及介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application filed with the Chinese Patent Office on April 30, 2020, with the application number CN202010362784.8, and the title "Document Edge Detection Method, Device, Equipment and Medium", the entire content of which is incorporated by reference In this application.
技术领域Technical field
本申请涉及金融科技(Fintech)技术领域,尤其涉及证件边沿检测方法、装置、设备和介质。This application relates to the technical field of financial technology (Fintech), in particular to the edge detection method, device, equipment and medium of the document.
背景技术Background technique
随着人工智能的发展,人工智能对证件的分析的场景越来越多。With the development of artificial intelligence, there are more and more scenarios for the analysis of documents by artificial intelligence.
在图像处理与分析、模式识别和计算机视觉等研究领域中通常需要提取目标区域的完整轮廓以获得关于目标的诸多有价值的信息,例如,当前利用图像处理算法识别身份证扫描图像,通过识别身份证扫描图像中的身份证边沿线,然后识别身份证中信息,有效的识别证件的边沿,可以提高后期对后面的卡片分析的准确度,现有的图像中边沿线的识别,主要是根据图像的形状。In the research fields of image processing and analysis, pattern recognition and computer vision, it is usually necessary to extract the complete outline of the target area to obtain a lot of valuable information about the target. Scan the edge of the ID card in the image, and then identify the information in the ID, effectively identifying the edge of the ID, which can improve the accuracy of subsequent card analysis. The identification of the edge in the existing image is mainly based on the image shape.
技术问题technical problem
发明人意识到针对证件边沿残缺有破损的时候,会导致识别误差较大。The inventor realizes that when the edge of the document is damaged, it will cause a large recognition error.
技术解决方案Technical solutions
本申请提供一种证件边沿检测方法,所述证件边沿检测方法包括如下步骤:This application provides a document edge detection method, which includes the following steps:
在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像;When receiving the edge detection request of the image credential, acquiring the target image associated with the edge detection request of the image credential;
将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片;Input the target image to a preset face recognition model, extract facial feature points in the target image, and determine the target image according to the facial feature points and the feature coordinates of the face feature points 'S face photo;
根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像;According to the photo information of the face photo, extracting a document body image containing the face photo from the target image;
将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。Input the main body image of the certificate to a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the certificate.
本申请还提供一种证件边沿检测装置,所述证件边沿检测装置包括:The present application also provides a document edge detection device, which includes:
请求接收模块,用于在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像;The request receiving module is configured to obtain the target image associated with the edge detection request of the image credential when the edge detection request of the image credential is received;
人脸识别模块,用于将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片;The face recognition module is used to input the target image into a preset face recognition model, extract the face feature points in the target image, and according to the face feature points and the feature coordinates of the face feature points , Determine the face photo in the target image;
证件图像提取模块,用于根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像;A credential image extraction module for extracting a credential body image containing a face photo from the target image according to the photo information of the face photo;
结果输出模块,用于将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。The result output module is used to input the document body image to the preset edge detection model to obtain the card edge line segment, analyze the card edge line segment, and output the certificate edge detection result.
本申请还提供一种证件边沿检测设备,所述证件边沿检测设备包括:存储器、处理器及存储在所述存储器上并可在所述处理器上运行的证件边沿检测对应的计算机程序,所述证件边沿检测对应的计算机程序被所述处理器执行时实现如下步骤:The present application also provides a document edge detection device. The document edge detection device includes a memory, a processor, and a computer program corresponding to the document edge detection that is stored in the memory and can run on the processor. When the computer program corresponding to the document edge detection is executed by the processor, the following steps are implemented:
在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像;When receiving the edge detection request of the image credential, acquiring the target image associated with the edge detection request of the image credential;
将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片;Input the target image to a preset face recognition model, extract facial feature points in the target image, and determine the target image according to the facial feature points and the feature coordinates of the face feature points 'S face photo;
根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像;According to the photo information of the face photo, extracting a document body image containing the face photo from the target image;
将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。Input the main body image of the certificate to a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the certificate.
本申请还提供一种计算机可读存储介质,所述计算机可读存储介质上存储有证件边沿检测对应的计算机程序,所述证件边沿检测对应的计算机程序被处理器执行时实现如下步骤:The present application also provides a computer-readable storage medium on which a computer program corresponding to the edge detection of a document is stored, and when the computer program corresponding to the edge detection of the document is executed by a processor, the following steps are implemented:
在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像;When receiving the edge detection request of the image credential, acquiring the target image associated with the edge detection request of the image credential;
将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片;Input the target image to a preset face recognition model, extract facial feature points in the target image, and determine the target image according to the facial feature points and the feature coordinates of the face feature points 'S face photo;
根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像;According to the photo information of the face photo, extracting a document body image containing the face photo from the target image;
将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。Input the main body image of the certificate to a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the certificate.
附图说明Description of the drawings
图1是本申请实施例方案涉及的硬件运行环境的设备结构示意图;FIG. 1 is a schematic diagram of the device structure of the hardware operating environment involved in the solution of the embodiment of the present application;
图2为本申请证件边沿检测方法第一实施例的流程示意图;FIG. 2 is a schematic flowchart of a first embodiment of a method for detecting the edge of an application document;
图3为本申请证件边沿检测装置一实施例的功能模块示意图。FIG. 3 is a schematic diagram of functional modules of an embodiment of the document edge detection device of this application.
本申请目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。The realization, functional characteristics, and advantages of the purpose of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings.
本发明的实施方式Embodiments of the present invention
应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。It should be understood that the specific embodiments described here are only used to explain the present application, and are not used to limit the present application.
如图1所示,图1是本申请实施例方案涉及的硬件运行环境的设备结构示意图。As shown in FIG. 1, FIG. 1 is a schematic diagram of the device structure of the hardware operating environment involved in the solution of the embodiment of the present application.
本申请实施例证件边沿检测设备可以是服务器设备,如图1所示,该证件边沿检测设备可以包括:处理器1001,例如CPU,网络接口1004,用户接口1003,存储器1005,通信总线1002。其中,通信总线1002用于实现这些组件之间的连接通信。用户接口1003可以包括显示屏(Display)、输入单元比如键盘(Keyboard),可选用户接口1003还可以包括标准的有线接口、无线接口。网络接口1004可选的可以包括标准的有线接口、无线接口(如WI-FI接口)。存储器1005可以是高速RAM存储器,也可以是稳定的存储器(non-volatile memory),例如磁盘存储器。存储器1005可选的还可以是独立于前述处理器1001的存储装置。The edge detection device of the example embodiment of this application may be a server device, as shown in FIG. Among them, the communication bus 1002 is used to implement connection and communication between these components. The user interface 1003 may include a display screen (Display) and an input unit such as a keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface). The memory 1005 may be a high-speed RAM memory, or a stable memory (non-volatile memory), such as a magnetic disk memory. Optionally, the memory 1005 may also be a storage device independent of the aforementioned processor 1001.
本领域技术人员可以理解,图1中示出的设备结构并不构成对设备的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。Those skilled in the art can understand that the structure of the device shown in FIG. 1 does not constitute a limitation on the device, and may include more or fewer components than those shown in the figure, or a combination of certain components, or different component arrangements.
如图1所示,作为一种计算机存储介质的存储器1005中可以包括操作网络通信模块、用户接口模块以及证件边沿检测对应的计算机程序。As shown in FIG. 1, the memory 1005, which is a computer storage medium, may include an operating network communication module, a user interface module, and a computer program corresponding to the edge detection of the document.
在图1所示的设备中,网络接口1004主要用于连接后台服务器,与后台服务器进行数据通信;用户接口1003主要用于连接客户端(用户端),与客户端进行数据通信;而处理器1001可以用于调用存储器1005中存储的证件边沿检测对应的计算机程序,并执行下述证件边沿检测方法中的操作。In the device shown in Figure 1, the network interface 1004 is mainly used to connect to the back-end server and communicate with the back-end server; the user interface 1003 is mainly used to connect to the client (user side) to communicate with the client; and the processor 1001 can be used to call a computer program corresponding to the edge detection of a document stored in the memory 1005, and perform operations in the following method for detecting edge of a document.
基于上述硬件结构,提出本申请证件边沿检测方法实施例。Based on the above hardware structure, an embodiment of the method for detecting the edge of the document in this application is proposed.
参照图2,图2为本申请证件边沿检测方法第一实施例的流程示意图,在本实施例中所述证件边沿检测方法包括:Referring to Fig. 2, Fig. 2 is a schematic flowchart of the first embodiment of the document edge detection method of this application. In this embodiment, the document edge detection method includes:
步骤S10,在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像。In step S10, when a request for edge detection of an image certificate is received, a target image associated with the request for edge detection of an image certificate is acquired.
本实施例中证件边沿检测方法应用于金融行业的金融机构(银行机构、保险机构、证券机构等)中的证件边沿检测设备。The document edge detection method in this embodiment is applied to document edge detection equipment in financial institutions (banking institutions, insurance institutions, securities institutions, etc.) in the financial industry.
证件边沿检测设备接收图像证件边沿检测请求,图像证件边沿检测请求的触发方式不作具体限定,即,图像证件边沿检测请求可以是用户主动触发的,例如,用户点击证件边沿检测设备显示页面上的“边沿检测”按键,主动触发图像证件边沿检测请求;此外,图像证件边沿检测请求还可以是自动触发的,例如,证件边沿检测设备预先设置:在接收到新的证件扫描图像时,自动触发图像证件边沿检测请求。The credential edge detection device receives the image credential edge detection request. The triggering method of the image credential edge detection request is not specifically limited, that is, the image credential edge detection request can be actively triggered by the user, for example, the user clicks "on the display page of the credential edge detection device "Edge detection" button to actively trigger the image ID edge detection request; in addition, the image ID edge detection request can also be automatically triggered, for example, the ID edge detection device is preset: when a new ID scan image is received, the image ID is automatically triggered Edge detection request.
证件边沿检测设备接收图像证件边沿检测请求,证件边沿检测设备获取图像证件边沿检测请求关联的目标图像,可以理解的是,本实施例中目标图像中包含卡片信息,还可以包含除卡片之外的其他信息,此外,目标图像的颜色和尺寸不作具体限定,例如,目标图像可以是彩色或者黑白。The credential edge detection device receives the image credential edge detection request, and the credential edge detection device obtains the target image associated with the image credential edge detection request. It can be understood that the target image in this embodiment contains card information, and may also include other than the card. Other information, in addition, the color and size of the target image are not specifically limited, for example, the target image may be color or black and white.
步骤S20,将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片。Step S20: Input the target image into a preset face recognition model, extract the face feature points in the target image, and determine the face feature point according to the face feature point and the feature coordinates of the face feature point The face photo in the target image.
证件边沿检测设备中预设人脸识别模型,即,证件边沿检测设备将人脸图像作为样本数据,预先根据人脸图像进行训练,得到预设人脸识别模型,证件边沿检测设备将目标图像输入至预设人脸识别模型,通过预设人脸识别模型处理目标图像,证件边沿检测设备提取目标图像中的人脸特征点,证件边沿检测设备获取人脸特征点的特征坐标,证件边沿检测设备按照人脸特征点和人脸特征点的特征坐标,确定目标图像中的人脸照片,即,证件边沿检测设备按照聚类算法分析人脸特征点的特征点坐标,获取到一个聚类中心(x0,y0),然后,证件边沿检测设备根据各个人脸特征点的特征坐标,获取一个最小外接矩形,证件边沿检测设备将这个外接矩形作为目标图像中的人脸照片。The face recognition model is preset in the document edge detection device, that is, the document edge detection device uses the face image as sample data, and pre-trains according to the face image to obtain the preset face recognition model, and the document edge detection device inputs the target image To the preset face recognition model, the target image is processed through the preset face recognition model, the document edge detection device extracts the facial feature points in the target image, the document edge detection device obtains the feature coordinates of the face feature points, and the document edge detection device According to the facial feature points and the feature coordinates of the face feature points, the face photo in the target image is determined, that is, the document edge detection device analyzes the feature point coordinates of the face feature points according to the clustering algorithm, and obtains a cluster center ( x0, y0), then, the document edge detection device obtains a minimum bounding rectangle according to the feature coordinates of each facial feature point, and the document edge detecting device uses this bounding rectangle as the face photo in the target image.
步骤S30,根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像。Step S30, according to the photo information of the face photo, extract a document body image containing the face photo from the target image.
证件边沿检测设备根据人脸照片的照片信息,从目标图像中提取包含人脸照片的证件主体图像,实现方式不作具体限定:The document edge detection device extracts the document body image containing the face photo from the target image according to the photo information of the face photo, and the implementation method is not specifically limited:
实现方式一:证件边沿检测设备先对标准证件(标准证件可以是身份证、借书证、学生证或护照等等)缩小放大获得多个证件面积、证件长、宽和人脸特征点的最小外接矩形以及聚类中心坐标,证件边沿检测设备保存证件长、宽与这个外接矩形的对应长宽比以及聚类中心坐标之间的比例关系,以及聚类中心到证件距离的比例关系,证件边沿检测设备将比例关系进行记录生成预设证件人脸比例映射表,然后,证件边沿检测设备根据人脸照片和预设证件人脸比例映射表,获得目标图像中包含人脸照片的证件主体,例如,证件边沿检测设备中预设证件人脸比例映射表中记录借书证人脸图像与证件本体的比例为1:6,证件边沿检测设备确定人脸照片的尺寸为2cm*3cm时,证件边沿检测设备根据证件人脸比例映射关系,获取4cm*9cm寸的区域作为证件主体图像。Implementation method 1: The document edge detection equipment first reduces and enlarges the standard documents (standard documents can be ID cards, library cards, student cards or passports, etc.) to obtain the smallest number of document area, document length, width, and facial feature points The circumscribed rectangle and the coordinates of the cluster center, the document edge detection device saves the document edge detection device to save the document length, width and the corresponding aspect ratio of the circumscribed rectangle, the proportional relationship between the cluster center coordinates, and the proportional relationship between the cluster center and the distance of the document, the document edge The detection device records the proportional relationship to generate a preset ID face ratio mapping table. Then, the ID edge detection device obtains the ID subject containing the face photo in the target image according to the face photo and the preset ID face ratio mapping table, for example, , The document edge detection equipment presets the document face ratio mapping table to record that the ratio of the face image of the library witness to the document body is 1:6, and the document edge detection equipment determines that the size of the face photo is 2cm*3cm, the document edge detection The device acquires an area of 4cm*9cm as the main body image of the document according to the ratio mapping relationship of the face of the document.
实现方式二:证件边沿检测设备根据目标图像中人脸图像的坐标和证件主体之间的坐标关系,确定证件主体图像,即,证件边沿检测设备获取人脸图像的坐标x1、y1、证件边沿检测设备获取证件主体坐标x2、y2;证件边沿检测设备根据x1<x2,y1<y2,和x1-(x2-x1)/a,x2+(x2-x1)/a, y1-(y2-y1)/a, y2+(y2-y1)/a,证件边沿检测设备获得目标图像中包含人脸照片的证件主体图像,其中a的值可以取30附近(不同情况也可以改变。)Implementation method 2: The document edge detection device determines the document body image according to the coordinates of the face image in the target image and the coordinate relationship between the document body, that is, the document edge detection device acquires the coordinates x1, y1, and the document edge detection The equipment obtains the coordinates of the document body x2 and y2; the document edge detection equipment is based on x1<x2, y1<y2, and x1-(x2-x1)/a, x2+(x2-x1)/a, y1-(y2-y1)/a, y2+(y2-y1)/a, the document edge detection device obtains the document body image containing the face photo in the target image, where the value of a can be around 30 (it can also be changed in different situations .)
此外,本实施例中还给出了实现方式三,在本实施例中步骤S20包括:In addition, the third implementation manner is also given in this embodiment. In this embodiment, step S20 includes:
步骤a1,获取所述人脸照片的照片信息,其中,所述照片信息包括人脸照片的位置信息和尺寸信息;Step a1, obtaining photo information of the face photo, where the photo information includes location information and size information of the face photo;
步骤a2,查询预设人证映射表,获取所述位置信息对应的证件类型,根据所述证件类型和所述人脸照片的尺寸信息确定证件尺寸信息;Step a2, query a preset person ID mapping table, obtain the ID type corresponding to the location information, and determine ID size information according to the ID type and the size information of the face photo;
步骤a3,根据所述证件尺寸信息和所述人脸照片的照片信息,从所述目标图像中提取包含所述人脸照片的证件主体图像。Step a3: Extract a document body image containing the face photo from the target image according to the document size information and the photo information of the face photo.
即,证件边沿检测设备获取人脸照片的照片信息,其中,照片信息包括人脸照片的位置信息和尺寸信息;证件边沿检测设备查询预设人证映射表(预设人证映射表是指预先设置的照片位置信息与证件种类映射表),获取位置信息对应的证件类型,证件边沿检测设备根据证件类型和人脸照片的尺寸信息确定证件尺寸信息;证件边沿检测设备根据证件尺寸信息和人脸照片的照片信息,从目标图像中提取包含所述人脸照片的证件主体图像。That is, the document edge detection device obtains the photo information of the face photo, where the photo information includes the position information and size information of the face photo; Set the mapping table of photo location information and certificate type) to obtain the document type corresponding to the location information. The document edge detection device determines the document size information according to the document type and the size information of the face photo; the document edge detection device determines the document size information according to the document size information and the face The photo information of the photo is to extract the document body image containing the face photo from the target image.
本实施例中给出了根据人脸照片的照片信息,从目标图像中提取包含人脸照片的证件主体图像,以将证件主体图像输入至预设边沿检测模型,进行证件边沿检测,本实施例中只处理证件主体图像,减少了数据处理量,进一步地提高了边沿检测的效率和准确性。In this embodiment, according to the photo information of the face photo, the document body image containing the face photo is extracted from the target image, so as to input the document body image into the preset edge detection model to perform the document edge detection. This embodiment Only the main body image of the document is processed in, which reduces the amount of data processing and further improves the efficiency and accuracy of edge detection.
步骤S40,将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。Step S40: Input the main body image of the document into a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the document.
证件边沿检测设备预设边沿检测模型,预设边沿检测模型是指预先设置的线段监测算法,证件边沿检测设备将证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,证件边沿检测设备分析卡片边沿线段,确定卡片边沿线段是否围成矩阵,若卡片边沿线段围成矩阵,证件边沿检测设备则输出证件边沿完整,若卡片边沿线段没有围成矩阵,证件边沿检测设备则输出证件边沿不完整。The document edge detection equipment presets the edge detection model. The preset edge detection model refers to the pre-set line segment monitoring algorithm. The document edge detection device inputs the main body image of the document to the preset edge detection model to obtain the card edge line segment. The document edge detection equipment analyzes Card edge line segment, to determine whether the card edge line segment encloses a matrix, if the card edge line segment encloses a matrix, the document edge detection device outputs a complete document edge, if the card edge line segment does not enclose a matrix, the document edge detection device outputs a document edge incomplete .
本实施例中通过识别目标图像中的人脸照片,根据人脸照片反向地抽取证件主体图像,从而将证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果,提高了目标图像中的证件边沿检测的准确性,进一步地提高证件信息识别的准确性。In this embodiment, the face photo in the target image is recognized, and the document body image is extracted in the reverse direction based on the face photo, so that the document body image is input to the preset edge detection model to obtain the card edge line segment, and the card edge line segment is analyzed , Output the detection result of the document edge, improve the accuracy of the document edge detection in the target image, and further improve the accuracy of the identification of the document information.
进一步地,基于本申请证件边沿检测方法第一实施例,提出本申请证件边沿检测方法第二实施例。Further, based on the first embodiment of the document edge detection method of the present application, a second embodiment of the document edge detection method of the present application is proposed.
本实施例是第一实施例中步骤S10之后的步骤,本实施例与上述实施例的区别在于:This embodiment is a step after step S10 in the first embodiment. The difference between this embodiment and the foregoing embodiment lies in:
将所述目标图像输入至预设人脸识别模型,获得识别结果并根据所述识别结果判断所述目标图像中是否包含人脸图像;Inputting the target image into a preset face recognition model, obtaining a recognition result, and judging whether the target image contains a face image according to the recognition result;
若所述目标图像中不包含人脸图像,则将所述目标图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果;If the target image does not contain a human face image, input the target image to a preset edge detection model to obtain a card edge line segment, analyze the card edge line segment, and output a document edge detection result;
若所述目标图像中包含人脸图像,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片。If the target image contains a face image, extract the face feature points in the target image, and determine the face in the target image according to the face feature points and the feature coordinates of the face feature points Photo.
可以理解的是,部分证件中不包含人脸图像,若直接按照第一实施例中方案执行,可能会出现识别误差,为了提高证件边沿检测的准确率,证件边沿检测设备将目标图像输入至预设人脸识别模型(预设人脸识别模型与第一实施例相同,本实施例不作赘述),获得识别结果(识别结果是指是否提取到人脸特征信息的结果),证件边沿检测设备根据识别结果判断目标图像中是否包含人脸图像;若目标图像中不包含人脸图像,证件边沿检测设备则将目标图像输入至预设边沿检测模型,获得卡片边沿线段,证件边沿检测设备分析卡片边沿线段,输出证件边沿检测结果;若目标图像中包含人脸图像,证件边沿检测设备提取目标图像中的人脸特征点,证件边沿检测设备根据人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片。本实施例中在证件中不包含人脸图像时,也可以进行预设人脸识别模型准确识别,使得证件边沿检测的适用范围更加广泛。It is understandable that some documents do not contain face images. If the scheme in the first embodiment is directly implemented, recognition errors may occur. In order to improve the accuracy of document edge detection, the document edge detection device inputs the target image to the preset. Set up a face recognition model (the preset face recognition model is the same as in the first embodiment, and this embodiment will not go into details), and the recognition result is obtained (the recognition result refers to the result of whether facial feature information is extracted), and the document edge detection device is based on The recognition result determines whether the target image contains a face image; if the target image does not contain a face image, the document edge detection device inputs the target image to the preset edge detection model to obtain the card edge line segment, and the document edge detection device analyzes the card edge Line segment, output the detection result of the document edge; if the target image contains a face image, the document edge detection device extracts the facial feature points in the target image, and the document edge detection device uses the face feature points and the feature coordinates of the face feature points To determine the face photo in the target image. In this embodiment, when the document does not contain a face image, the preset face recognition model can also be accurately recognized, so that the application range of the document edge detection is wider.
进一步地,基于本申请证件边沿检测方法上述实施例,提出本申请证件边沿检测方法第三实施例。Further, based on the foregoing embodiments of the document edge detection method of the present application, a third embodiment of the document edge detection method of the present application is proposed.
本实施例是第一实施例中步骤S10之后的步骤,本实施例与上述实施例的区别在于:This embodiment is a step after step S10 in the first embodiment. The difference between this embodiment and the foregoing embodiment lies in:
将所述目标图像输入至预设边沿检测模型,输出线段识别结果,根据所述线段识别结果判断所述目标图像中是否存在直线;Inputting the target image into a preset edge detection model, outputting a line segment recognition result, and judging whether there is a straight line in the target image according to the line segment recognition result;
若所述目标图像中存在直线,则根据所述直线和所述直接的投影,确定所述目标图像的倾斜角度,按照所述倾斜角度反向移动目标图像。If there is a straight line in the target image, the inclination angle of the target image is determined according to the straight line and the direct projection, and the target image is moved backward according to the inclination angle.
具体地,证件边沿检测设备将目标图像输入至预设边沿检测模型,证件边沿检测设备先对目标图像进行直线检测,证件边沿检测设备将每个像素坐标点变换为对直线特质有贡献的统一度量,例如:一条直线在目标图像中是一系列离散点的集合,证件边沿检测设备通过直线离散极坐标公式,表达出直线的离散点几何等式如下:X *cos(theta) + y * sin(theta) = r ,其中角度theta指r与X轴之间的夹角,r为到直线几何垂直距离,任何在直线上点,x, y都可以表达,其中 r, theta是常量,在实现的图像处理领域,图像的像素坐标P(x, y)是已知的,而r, theta则是要寻找的变量,如果证件边沿检测设备根据像素点坐标P(x, y)值,绘制每个像素点(r, theta)值,然后证件边沿检测设备从图像笛卡尔坐标转换到极坐标霍夫空间,这种从点到曲线的变换称为直线的霍夫变换,变换通过量化霍夫参数空间为有限个值间隔等分或者累加格子,当霍夫变换算法开始,每个像素坐标点P(x, y)被转换到(r, theta)的曲线点上面,累加到对应的格子数据点,当一个波峰出现时候,说明有直线存在。证件边沿检测设备在判定有直线存在时,证件边沿检测设备将直线进行投影,获取直线对应的投影直线,证件边沿检测设备根据余弦定理,得到直线的倾斜角度,证件边沿检测设备根据倾斜角度旋转目标图像,以完成目标图像的角度矫正。本实施例中证件边沿检测设备识别将目标图像进行旋转,提高了识别的准确率。Specifically, the document edge detection device inputs the target image into the preset edge detection model. The document edge detection device first detects the target image in a straight line, and the document edge detection device transforms each pixel coordinate point into a unified metric that contributes to the characteristics of the straight line. For example, a straight line is a collection of a series of discrete points in the target image. The document edge detection device uses the linear discrete polar coordinate formula to express the linear discrete point geometric equation as follows: X *cos(theta) + y * sin( theta) = r, where the angle theta refers to the angle between r and the X axis, r is the geometric vertical distance to the straight line, any point on the straight line, x, y can be expressed, where r, theta are constants. In the realm of image processing, the pixel coordinates P(x, y) of the image are known, and r, theta is the variable to be looked for. If the edge detection device of the document draws each pixel (r, theta) value, and then the document edge detection device converts the image Cartesian coordinates to the polar coordinate Hough space. This transformation from point to curve is called the Hough transform of a straight line. The transformation is performed by quantizing the Hough parameter space into a finite interval of values. Divide or accumulate the grid. When the Hough transform algorithm starts, the coordinate point P(x, y) of each pixel is converted to (r, Theta) curve points are added to the corresponding grid data points. When a wave crest appears, it means that there is a straight line. When the document edge detection device determines that there is a straight line, the document edge detection device projects the straight line to obtain the projection line corresponding to the straight line. The document edge detection device obtains the inclination angle of the line according to the law of cosine, and the document edge detection device rotates the target according to the inclination angle. Image to complete the angle correction of the target image. In this embodiment, the document edge detection device recognizes and rotates the target image, which improves the accuracy of recognition.
进一步地,基于本申请证件边沿检测方法上述实施例,提出本申请证件边沿检测方法第四实施例。Further, based on the foregoing embodiments of the document edge detection method of the present application, a fourth embodiment of the document edge detection method of the present application is proposed.
本实施例是第一实施例中步骤S40的细化步骤,本实施例与上述实施例的区别在于:This embodiment is a detailed step of step S40 in the first embodiment. The difference between this embodiment and the foregoing embodiment lies in:
实现方式一:Realization method one:
将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段;Input the main body image of the certificate to the preset edge detection model to obtain the edge line segment of the card;
根据预设离散点分类统计算法处理各所述卡片边沿线段,获得所述卡片边沿线段的中点;Processing each of the edge line segments of the card according to a preset discrete point classification statistical algorithm to obtain the midpoint of the edge line segment of the card;
对所述中点进行近邻四分类,将同一中点对应的卡片边沿线段上的点作为一簇,删除每一簇中的异常点,对每一簇中剩余的点进行支持向量机二分类;Performing four nearest neighbor classifications on the midpoint, taking the points on the edge line segment of the card corresponding to the same midpoint as a cluster, deleting the abnormal points in each cluster, and performing the support vector machine two classification on the remaining points in each cluster;
统计每一簇所有点到支持向量的距离,将所述距离取立方后除以这一簇所有点数量,获得计算结果,将所述计算结果与预设阈值进行比较;Count the distances from all points of each cluster to the support vector, take the cube of the distance and divide by the number of all points in this cluster to obtain a calculation result, and compare the calculation result with a preset threshold;
若所述计算结果大于预设阈值,则输出卡片边沿缺角的检测结果。If the calculation result is greater than the preset threshold, the detection result of the missing corner of the card edge is output.
证件边沿检测设备将证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,证件边沿检测设备根据离散点分类统计算法,对所有的卡片边沿线段取中点,对所有的中点进行k近邻四分类。同时这个中点对应的线段所有点属于这一簇。然后,证件边沿检测设备分类后的每一簇先去掉异常的点,再进行支持向量机二分类,件边沿检测设备统计每一簇所有点到支持向量的距离,证件边沿检测设备取立方再除以这一簇所有点数量。如果最后立方和大于阈值p0(P0是基于非缺角正常图片统计的一个临界值(阈值p0可以取100)),证件边沿检测设备判定卡片边沿线段缺角,输出提示信息,反之。The document edge detection device inputs the main body image of the document into the preset edge detection model to obtain the edge line segment of the card. The document edge detection device takes the midpoint of all the edge line segments of the card according to the discrete point classification and statistical algorithm, and performs k-nearest neighbors on all midpoints Four categories. At the same time, all points of the line segment corresponding to this midpoint belong to this cluster. Then, after the document edge detection equipment classifies each cluster, the abnormal points are removed first, and then the support vector machine is used for the second classification. The document edge detection equipment counts the distance from all points of each cluster to the support vector, and the document edge detection equipment takes the cube and then divides it. Take the number of all points in this cluster. If the final cube sum is greater than the threshold value p0 (P0 is a critical value based on the statistics of normal images without missing corners (threshold p0 can be 100)), the document edge detection device determines the missing corner of the card edge line segment and outputs a prompt message, and vice versa.
实现方式二:Implementation method two:
将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段;Input the main body image of the certificate to the preset edge detection model to obtain the edge line segment of the card;
获取各所述卡片边沿线段中包含的像素点数量,将所述像素点数量与预设点数进行比较;Acquiring the number of pixels included in each edge line segment of the card, and comparing the number of pixels with a preset number of points;
删除像素点数量小于预设点数的噪声卡片边沿线段,按预设聚类算法处理剩余的卡片边沿线段,获得卡片边沿线段的线段数量;Delete noise card edge line segments whose number of pixels is less than the preset number of points, and process the remaining card edge line segments according to the preset clustering algorithm to obtain the number of line segments of the card edge line segment;
若所述线段数量大于4,则输出卡片边沿缺角的检测结果。If the number of line segments is greater than 4, the detection result of the missing corner of the card edge is output.
证件边沿检测设备将证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,证件边沿检测设备获取各卡片边沿线段中包含的像素点数量,将所述像素点数量与预设点数进行比较,证件边沿检测设备判断卡片边沿线段的长度是否大于预设点数,其中,预设点数可以是10个像素点的长度,若卡片边沿线段的长度小于预设点数删去。证件边沿检测设备获取剩余像素点的顶点坐标,然后用k近邻算法按4类聚分,得到确定卡片边沿线段的线段数量,证件边沿检测设备判断卡片边沿线段的线段数量是否大于4,若卡片边沿线段数目大于4即可认为边沿残缺,反之。The document edge detection device inputs the main body image of the document into the preset edge detection model to obtain the edge line segment of the card. The document edge detection device obtains the number of pixels contained in each edge line segment of the card, and compares the number of pixels with the preset number of points, The document edge detection device determines whether the length of the edge line segment of the card is greater than the preset number of points, where the preset number of points can be a length of 10 pixels, and if the length of the card edge line segment is less than the preset number of points, delete it. The document edge detection device obtains the vertex coordinates of the remaining pixels, and then uses the k-nearest neighbor algorithm to cluster them into 4 categories to obtain the number of line segments that determine the edge line segment of the card. The document edge detection device determines whether the number of line segments of the card edge line segment is greater than 4. If the number of line segments is greater than 4, the edge is considered to be incomplete, and vice versa.
进一步地,基于本申请证件边沿检测方法上述实施例,提出本申请证件边沿检测方法第五实施例。Further, based on the foregoing embodiments of the document edge detection method of the present application, a fifth embodiment of the document edge detection method of the present application is proposed.
本实施例是第一实施例中步骤S40之后的步骤,本实施例与上述实施例的区别在于:This embodiment is a step after step S40 in the first embodiment. The difference between this embodiment and the foregoing embodiment lies in:
对所述卡片边沿线段围成的矩形区域进行文字识别,获得所述证件主体图像中包含的文字信息;Perform text recognition on the rectangular area enclosed by the edge of the card to obtain the text information contained in the main body image of the certificate;
根据所述文字信息将所述目标图像分类保存至对应的证件图像数据库。According to the text information, the target image is classified and saved to a corresponding certificate image database.
证件边沿检测设备对卡片边沿线段围成的矩形区域进行文字识别,获得证件主体图像中包含的文字信息,本实施例中文字识别方式不作限定,例如,文字识别方式可以是OCR (Optical Character Recognition,光学字符识别),证件边沿检测设备根据文字信息,确定目标图像中证件的种类,然后,证件边沿检测设备根据证件的种类将目标图像保存至对应的证件图像数据库。本实施例中,证件边沿检测设备将目标图像进行分类保存,可以方便用户查找。The document edge detection device performs text recognition on the rectangular area enclosed by the edge line of the card to obtain the text information contained in the main image of the document. The text recognition method in this embodiment is not limited. For example, the text recognition method can be OCR (Optical Character Recognition (optical character recognition), the document edge detection device determines the type of the document in the target image based on the text information, and then the document edge detection device saves the target image to the corresponding document image database according to the type of the document. In this embodiment, the document edge detection device classifies and saves the target image, which can facilitate the user to find it.
参照图3,本申请还提供一种证件边沿检测装置,所述证件边沿检测装置包括:3, the present application also provides a document edge detection device, the document edge detection device includes:
请求接收模块10,用于在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像;The request receiving module 10 is configured to obtain the target image associated with the edge detection request of the image credential when the edge detection request of the image credential is received;
人脸识别模块20,用于将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片;The face recognition module 20 is configured to input the target image into a preset face recognition model, extract facial feature points in the target image, and based on the facial feature points and the features of the face feature points Coordinates, determine the face photo in the target image;
证件图像提取模块30,用于根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像;The credential image extraction module 30 is configured to extract the credential body image containing the face photo from the target image according to the photo information of the face photo;
结果输出模块40,用于将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。The result output module 40 is used to input the document body image to a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the document.
在一实施例中,所述的证件边沿检测装置,包括:In an embodiment, the document edge detection device includes:
线段识别模块,用于将所述目标图像输入至预设边沿检测模型,输出线段识别结果,根据所述线段识别结果判断所述目标图像中是否存在直线;The line segment recognition module is configured to input the target image into a preset edge detection model, output a line segment recognition result, and determine whether there is a straight line in the target image according to the line segment recognition result;
图像移动模块,用于若所述目标图像中存在直线,则根据所述直线和所述直接的投影,确定所述目标图像的倾斜角度,按照所述倾斜角度反向移动目标图像。The image movement module is configured to determine the inclination angle of the target image according to the straight line and the direct projection if there is a straight line in the target image, and move the target image in reverse according to the inclination angle.
在一实施例中,所述人脸识别模块20,包括:In an embodiment, the face recognition module 20 includes:
识别判断单元,用于将所述目标图像输入至预设人脸识别模型,获得识别结果并根据所述识别结果判断所述目标图像中是否包含人脸图像;A recognition judgment unit, configured to input the target image into a preset face recognition model, obtain a recognition result, and determine whether the target image contains a face image according to the recognition result;
输入检测单元,用于若所述目标图像中不包含人脸图像,则将所述目标图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果;The input detection unit is configured to, if the target image does not contain a face image, input the target image to a preset edge detection model to obtain a card edge line segment, analyze the card edge line segment, and output a document edge detection result;
提取确定单元,用于若所述目标图像中包含人脸图像,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片。The extraction and determination unit is configured to, if the target image contains a face image, extract the face feature points in the target image, and determine the face feature point according to the face feature point and the feature coordinates of the face feature point The face photo in the target image.
在一实施例中,所述证件图像提取模块30,包括:In an embodiment, the credential image extraction module 30 includes:
信息获取单元,应用获取所述人脸照片的照片信息,其中,所述照片信息包括人脸照片的位置信息和尺寸信息;An information acquisition unit for acquiring photo information of the face photo by an application, where the photo information includes location information and size information of the face photo;
查询确定单元,用于查询预设人证映射表,获取所述位置信息对应的证件类型,根据所述证件类型和所述人脸照片的尺寸信息确定证件尺寸信息;The query determining unit is configured to query a preset person ID mapping table, obtain the ID type corresponding to the location information, and determine the ID size information according to the ID type and the size information of the face photo;
图像提取单元,用于根据所述证件尺寸信息和所述人脸照片的照片信息,从所述目标图像中提取包含所述人脸照片的证件主体图像。The image extracting unit is configured to extract the document body image containing the face photo from the target image according to the document size information and the photo information of the face photo.
在一实施例中,所述结果输出模块40,包括:In an embodiment, the result output module 40 includes:
图像输入单元,用于将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段;The image input unit is used to input the image of the main body of the certificate to the preset edge detection model to obtain the edge line segment of the card;
分类处理单元,用于根据预设离散点分类统计算法处理各所述卡片边沿线段,获得所述卡片边沿线段的中点;The classification processing unit is configured to process each of the edge line segments of the card according to a preset discrete point classification statistical algorithm to obtain the midpoint of the edge line segment of the card;
删除分类单元,用于对所述中点进行近邻四分类,将同一中点对应的卡片边沿线段上的点作为一簇,删除每一簇中的异常点,对每一簇中剩余的点进行支持向量机二分类;The delete classification unit is used to classify the midpoint into four nearest neighbors, regard the points on the edge line segment of the card corresponding to the same midpoint as a cluster, delete the abnormal points in each cluster, and perform the calculation on the remaining points in each cluster. Support vector machine two classification;
统计比较单元,用于统计每一簇所有点到支持向量的距离,将所述距离取立方后除以这一簇所有点数量,获得计算结果,将所述计算结果与预设阈值进行比较;A statistical comparison unit, configured to count the distances from all points in each cluster to the support vector, take the cube of the distance and divide by the number of all points in the cluster to obtain a calculation result, and compare the calculation result with a preset threshold;
结果输出单元,用于若所述计算结果大于预设阈值,则输出卡片边沿缺角的检测结果。The result output unit is configured to output the detection result of the missing corner of the card edge if the calculation result is greater than the preset threshold.
在一实施例中,所述结果输出模块40,包括:In an embodiment, the result output module 40 includes:
图像输入单元,用于将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段;The image input unit is used to input the image of the main body of the certificate to the preset edge detection model to obtain the edge line segment of the card;
数量比对单元,用于获取各所述卡片边沿线段中包含的像素点数量,将所述像素点数量与预设点数进行比较;The quantity comparison unit is used to obtain the number of pixels contained in each edge line segment of the card, and compare the number of pixels with a preset number of points;
信息数量单元,用于删除像素点数量小于预设点数的噪声卡片边沿线段,按预设聚类算法处理剩余的卡片边沿线段,获得卡片边沿线段的线段数量;The information quantity unit is used to delete noise card edge line segments whose number of pixels is less than the preset number of points, and process the remaining card edge line segments according to the preset clustering algorithm to obtain the number of line segments of the card edge line segment;
结果输出单元,用于若所述线段数量大于4,则输出卡片边沿缺角的检测结果。The result output unit is configured to output the detection result of the missing corner of the card edge if the number of line segments is greater than 4.
在一实施例中,所述的证件边沿检测装置,还包括:In an embodiment, the document edge detection device further includes:
文字识别模块,用于对所述卡片边沿线段围成的矩形区域进行文字识别,获得所述证件主体图像中包含的文字信息;The text recognition module is used to perform text recognition on the rectangular area enclosed by the edge line segment of the card to obtain the text information contained in the main body image of the certificate;
分类保存模块,用于根据所述文字信息将所述目标图像分类保存至对应的证件图像数据库。The classification saving module is used to classify and save the target image to the corresponding credential image database according to the text information.
其中,在所述处证件边沿检测装置被执行时所实现的方法可参照本申请证件边沿检测方法各个实施例,此处不再赘述。Among them, the method implemented when the document edge detection device is executed can refer to the various embodiments of the document edge detection method of this application, which will not be repeated here.
本申请实施例中,证件边沿检测装置通过识别目标图像中的人脸照片,根据人脸照片反向地抽取证件主体图像,从而将证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果,提高了目标图像中的证件边沿检测的准确性,进一步地提高证件信息识别的准确性。In the embodiment of the present application, the document edge detection device recognizes the face photo in the target image and extracts the document body image in the reverse direction according to the face photo, thereby inputting the document body image to the preset edge detection model to obtain the edge line segment of the card. The edge line segment of the card is analyzed, and the detection result of the edge of the document is output, which improves the accuracy of detecting the edge of the document in the target image, and further improves the accuracy of identification of the document information.
本申请还提供一种计算机可读存储介质,所述计算机可读存储介质可以是易失性,也可以是非易失性。The present application also provides a computer-readable storage medium. The computer-readable storage medium may be volatile or non-volatile.
本申请计算机可读存储介质上存储有证件边沿检测对应的计算机程序,所述证件边沿检测对应的计算机程序被处理器执行时实现如上所述的证件边沿检测方法的步骤。The computer readable storage medium of the present application stores a computer program corresponding to the document edge detection, and when the computer program corresponding to the document edge detection is executed by a processor, the steps of the document edge detection method described above are implemented.
其中,在所述处理器上运行的证件边沿检测对应的计算机程序被执行时所实现的方法可参照本申请证件边沿检测方法各个实施例,此处不再赘述。For the method implemented when the computer program corresponding to the document edge detection running on the processor is executed, please refer to the various embodiments of the document edge detection method of this application, which will not be repeated here.
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者系统不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者系统所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者系统中还存在另外的相同要素。It should be noted that in this article, the terms "include", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements not only includes those elements, It also includes other elements not explicitly listed, or elements inherent to the process, method, article, or system. If there are no more restrictions, the element defined by the sentence "including a..." does not exclude the existence of other identical elements in the process, method, article, or system that includes the element.
上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。The serial numbers of the foregoing embodiments of the present application are for description only, and do not represent the superiority or inferiority of the embodiments.
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在如上所述的一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台证件边沿检测设备设备(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本申请各个实施例所述的方法。Through the description of the above implementation manners, those skilled in the art can clearly understand that the above-mentioned embodiment method can be implemented by means of software plus the necessary general hardware platform, of course, it can also be implemented by hardware, but in many cases the former is better.的实施方式。 Based on this understanding, the technical solution of this application essentially or the part that contributes to the existing technology can be embodied in the form of a software product, and the computer software product is stored in a storage medium (such as ROM/RAM) as described above. , Magnetic disk, optical disk), including several instructions to make a document edge detection equipment (can be a mobile phone, computer, server, air conditioner, or network equipment, etc.) execute the method described in each embodiment of this application.
以上仅为本申请的优选实施例,并非因此限制本申请的专利范围,凡是利用本申请说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本申请的专利保护范围内。The above are only the preferred embodiments of the application, and do not limit the scope of the patent for this application. Any equivalent structure or equivalent process transformation made using the content of the description and drawings of the application, or directly or indirectly applied to other related technical fields , The same reason is included in the scope of patent protection of this application.

Claims (20)

  1. 一种证件边沿检测方法,其中,所述证件边沿检测方法包括如下步骤:A document edge detection method, wherein the document edge detection method includes the following steps:
    在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像;When receiving the edge detection request of the image credential, acquiring the target image associated with the edge detection request of the image credential;
    将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片;Input the target image to a preset face recognition model, extract facial feature points in the target image, and determine the target image according to the facial feature points and the feature coordinates of the face feature points 'S face photo;
    根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像;According to the photo information of the face photo, extracting a document body image containing the face photo from the target image;
    将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。Input the main body image of the certificate to a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the certificate.
  2. 如权利要求1所述的证件边沿检测方法,其中,所述在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像的步骤之后,所述方法包括:The document edge detection method according to claim 1, wherein, after the step of obtaining the target image associated with the image document edge detection request when the image document edge detection request is received, the method comprises:
    将所述目标图像输入至预设边沿检测模型,输出线段识别结果,根据所述线段识别结果判断所述目标图像中是否存在直线;Inputting the target image into a preset edge detection model, outputting a line segment recognition result, and judging whether there is a straight line in the target image according to the line segment recognition result;
    若所述目标图像中存在直线,则根据所述直线和所述直接的投影,确定所述目标图像的倾斜角度,按照所述倾斜角度反向移动目标图像。If there is a straight line in the target image, the inclination angle of the target image is determined according to the straight line and the direct projection, and the target image is moved backward according to the inclination angle.
  3. 如权利要求1所述的证件边沿检测方法,其中,所述将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片的步骤,包括:The method for detecting the edge of a document according to claim 1, wherein said inputting said target image into a preset face recognition model, extracting face feature points in said target image, and according to said face feature points and The step of determining the feature coordinates of the feature points of the face and the face photo in the target image includes:
    将所述目标图像输入至预设人脸识别模型,获得识别结果并根据所述识别结果判断所述目标图像中是否包含人脸图像;Inputting the target image into a preset face recognition model, obtaining a recognition result, and judging whether the target image contains a face image according to the recognition result;
    若所述目标图像中不包含人脸图像,则将所述目标图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果;If the target image does not contain a human face image, input the target image to a preset edge detection model to obtain a card edge line segment, analyze the card edge line segment, and output a document edge detection result;
    若所述目标图像中包含人脸图像,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片。If the target image contains a face image, extract the face feature points in the target image, and determine the face in the target image according to the face feature points and the feature coordinates of the face feature points Photo.
  4. 如权利要求1所述的证件边沿检测方法,其中,所述根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像的步骤,包括:The method for detecting the edge of a document according to claim 1, wherein the step of extracting the document body image containing the face photo from the target image according to the photo information of the face photo comprises:
    获取所述人脸照片的照片信息,其中,所述照片信息包括人脸照片的位置信息和尺寸信息;Acquiring photo information of the face photo, where the photo information includes location information and size information of the face photo;
    查询预设人证映射表,获取所述位置信息对应的证件类型,根据所述证件类型和所述人脸照片的尺寸信息确定证件尺寸信息;Query a preset person ID mapping table, obtain the ID type corresponding to the location information, and determine ID size information according to the ID type and the size information of the face photo;
    根据所述证件尺寸信息和所述人脸照片的照片信息,从所述目标图像中提取包含所述人脸照片的证件主体图像。According to the credential size information and the photo information of the face photo, a credential body image containing the face photo is extracted from the target image.
  5. 如权利要求1所述的证件边沿检测方法,其中,所述将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果的步骤,包括:The method for detecting the edge of a document according to claim 1, wherein the step of inputting the main body image of the document into a preset edge detection model to obtain a line segment of the card edge, analyzing the line segment of the card edge, and outputting the detection result of the edge of the document, include:
    将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段;Input the main body image of the certificate to the preset edge detection model to obtain the edge line segment of the card;
    根据预设离散点分类统计算法处理各所述卡片边沿线段,获得所述卡片边沿线段的中点;Processing each of the edge line segments of the card according to a preset discrete point classification statistical algorithm to obtain the midpoint of the edge line segment of the card;
    对所述中点进行近邻四分类,将同一中点对应的卡片边沿线段上的点作为一簇,删除每一簇中的异常点,对每一簇中剩余的点进行支持向量机二分类;Performing four nearest neighbor classifications on the midpoint, taking the points on the edge line segment of the card corresponding to the same midpoint as a cluster, deleting the abnormal points in each cluster, and performing the support vector machine two classification on the remaining points in each cluster;
    统计每一簇所有点到支持向量的距离,将所述距离取立方后除以这一簇所有点数量,获得计算结果,将所述计算结果与预设阈值进行比较;Count the distances from all points of each cluster to the support vector, take the cube of the distance and divide by the number of all points in this cluster to obtain a calculation result, and compare the calculation result with a preset threshold;
    若所述计算结果大于预设阈值,则输出卡片边沿缺角的检测结果。If the calculation result is greater than the preset threshold, the detection result of the missing corner of the card edge is output.
  6. 如权利要求1所述的证件边沿检测方法,其中,所述将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果的步骤,包括:The method for detecting the edge of a document according to claim 1, wherein the step of inputting the image of the main body of the document into a preset edge detection model to obtain the edge line segment of the card, analyzing the edge line segment of the card, and outputting the edge detection result of the document, include:
    将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段;Input the main body image of the certificate to the preset edge detection model to obtain the edge line segment of the card;
    获取各所述卡片边沿线段中包含的像素点数量,将所述像素点数量与预设点数进行比较;Acquiring the number of pixels included in each edge line segment of the card, and comparing the number of pixels with a preset number of points;
    删除像素点数量小于预设点数的噪声卡片边沿线段,按预设聚类算法处理剩余的卡片边沿线段,获得卡片边沿线段的线段数量;Delete noise card edge line segments whose number of pixels is less than the preset number of points, and process the remaining card edge line segments according to the preset clustering algorithm to obtain the number of line segments of the card edge line segment;
    若所述线段数量大于4,则输出卡片边沿缺角的检测结果。If the number of line segments is greater than 4, the detection result of the missing corner of the card edge is output.
  7. 如权利要求1至6任意一项所述的证件边沿检测方法,其中,所述将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果的步骤之后,所述方法还包括:The document edge detection method according to any one of claims 1 to 6, wherein said inputting said document body image to a preset edge detection model to obtain card edge line segments, analyzing said card edge line segments, and outputting the document edge After the step of detecting the result, the method further includes:
    对所述卡片边沿线段围成的矩形区域进行文字识别,获得所述证件主体图像中包含的文字信息;Perform text recognition on the rectangular area enclosed by the edge of the card to obtain the text information contained in the main body image of the certificate;
    根据所述文字信息将所述目标图像分类保存至对应的证件图像数据库。According to the text information, the target image is classified and saved to a corresponding certificate image database.
  8. 一种证件边沿检测装置,其中,所述证件边沿检测装置包括:A document edge detection device, wherein the document edge detection device includes:
    请求接收模块,用于在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像;The request receiving module is configured to obtain the target image associated with the edge detection request of the image credential when the edge detection request of the image credential is received;
    人脸识别模块,用于将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片;The face recognition module is used to input the target image into a preset face recognition model, extract the face feature points in the target image, and according to the face feature points and the feature coordinates of the face feature points , Determine the face photo in the target image;
    证件图像提取模块,用于根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像;A credential image extraction module for extracting a credential body image containing a face photo from the target image according to the photo information of the face photo;
    结果输出模块,用于将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。The result output module is used to input the document body image to the preset edge detection model to obtain the card edge line segment, analyze the card edge line segment, and output the certificate edge detection result.
  9. 一种证件边沿检测设备,其中,所述证件边沿检测设备包括:存储器、处理器及存储在所述存储器上并可在所述处理器上运行的证件边沿检测对应的计算机程序,所述证件边沿检测对应的计算机程序被所述处理器执行时实现如下步骤:A document edge detection device, wherein the document edge detection device includes a memory, a processor, and a computer program corresponding to the document edge detection stored in the memory and running on the processor. The document edge When detecting that the corresponding computer program is executed by the processor, the following steps are implemented:
    在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像;When receiving the edge detection request of the image credential, acquiring the target image associated with the edge detection request of the image credential;
    将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片;Input the target image to a preset face recognition model, extract facial feature points in the target image, and determine the target image according to the facial feature points and the feature coordinates of the face feature points 'S face photo;
    根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像;According to the photo information of the face photo, extracting a document body image containing the face photo from the target image;
    将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。Input the main body image of the certificate to a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the certificate.
  10. 如权利要求9所述的证件边沿检测设备,其中,所述在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像的步骤之后,所述证件边沿检测对应的计算机程序被所述处理器执行时还实现如下步骤:The document edge detection device according to claim 9, wherein after the step of acquiring the target image associated with the image document edge detection request when the image document edge detection request is received, the computer corresponding to the document edge detection When the program is executed by the processor, the following steps are also implemented:
    将所述目标图像输入至预设边沿检测模型,输出线段识别结果,根据所述线段识别结果判断所述目标图像中是否存在直线;Inputting the target image into a preset edge detection model, outputting a line segment recognition result, and judging whether there is a straight line in the target image according to the line segment recognition result;
    若所述目标图像中存在直线,则根据所述直线和所述直接的投影,确定所述目标图像的倾斜角度,按照所述倾斜角度反向移动目标图像。If there is a straight line in the target image, the inclination angle of the target image is determined according to the straight line and the direct projection, and the target image is moved backward according to the inclination angle.
  11. 如权利要求9所述的证件边沿检测设备,其中,所述将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片的步骤,包括:The document edge detection device according to claim 9, wherein said inputting said target image into a preset face recognition model, extracting face feature points in said target image, and according to said face feature points and The step of determining the feature coordinates of the feature points of the face and the face photo in the target image includes:
    将所述目标图像输入至预设人脸识别模型,获得识别结果并根据所述识别结果判断所述目标图像中是否包含人脸图像;Inputting the target image into a preset face recognition model, obtaining a recognition result, and judging whether the target image contains a face image according to the recognition result;
    若所述目标图像中不包含人脸图像,则将所述目标图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果;If the target image does not contain a human face image, input the target image to a preset edge detection model to obtain a card edge line segment, analyze the card edge line segment, and output a document edge detection result;
    若所述目标图像中包含人脸图像,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片。If the target image contains a face image, extract the face feature points in the target image, and determine the face in the target image according to the face feature points and the feature coordinates of the face feature points Photo.
  12. 如权利要求9所述的证件边沿检测设备,其中,所述根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像的步骤,包括:9. The document edge detection device according to claim 9, wherein the step of extracting the document body image containing the face photo from the target image according to the photo information of the face photo comprises:
    获取所述人脸照片的照片信息,其中,所述照片信息包括人脸照片的位置信息和尺寸信息;Acquiring photo information of the face photo, where the photo information includes location information and size information of the face photo;
    查询预设人证映射表,获取所述位置信息对应的证件类型,根据所述证件类型和所述人脸照片的尺寸信息确定证件尺寸信息;Query a preset person ID mapping table, obtain the ID type corresponding to the location information, and determine ID size information according to the ID type and the size information of the face photo;
    根据所述证件尺寸信息和所述人脸照片的照片信息,从所述目标图像中提取包含所述人脸照片的证件主体图像。According to the credential size information and the photo information of the face photo, a credential body image containing the face photo is extracted from the target image.
  13. 如权利要求9所述的证件边沿检测设备,其中,所述将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果的步骤,包括:9. The document edge detection device according to claim 9, wherein the step of inputting the document body image to a preset edge detection model to obtain a card edge line segment, analyzing the card edge line segment, and outputting a document edge detection result, include:
    将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段;Input the main body image of the certificate to the preset edge detection model to obtain the edge line segment of the card;
    根据预设离散点分类统计算法处理各所述卡片边沿线段,获得所述卡片边沿线段的中点;Processing each of the edge line segments of the card according to a preset discrete point classification statistical algorithm to obtain the midpoint of the edge line segment of the card;
    对所述中点进行近邻四分类,将同一中点对应的卡片边沿线段上的点作为一簇,删除每一簇中的异常点,对每一簇中剩余的点进行支持向量机二分类;Performing four nearest neighbor classifications on the midpoint, taking the points on the edge line segment of the card corresponding to the same midpoint as a cluster, deleting the abnormal points in each cluster, and performing the support vector machine two classification on the remaining points in each cluster;
    统计每一簇所有点到支持向量的距离,将所述距离取立方后除以这一簇所有点数量,获得计算结果,将所述计算结果与预设阈值进行比较;Count the distances from all points of each cluster to the support vector, take the cube of the distance and divide by the number of all points in this cluster to obtain a calculation result, and compare the calculation result with a preset threshold;
    若所述计算结果大于预设阈值,则输出卡片边沿缺角的检测结果。If the calculation result is greater than the preset threshold, the detection result of the missing corner of the card edge is output.
  14. 如权利要求9所述的证件边沿检测设备,其中,所述将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果的步骤,包括:9. The document edge detection device according to claim 9, wherein the step of inputting the document body image to a preset edge detection model to obtain a card edge line segment, analyzing the card edge line segment, and outputting a document edge detection result, include:
    将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段;Input the main body image of the certificate to the preset edge detection model to obtain the edge line segment of the card;
    获取各所述卡片边沿线段中包含的像素点数量,将所述像素点数量与预设点数进行比较;Acquiring the number of pixels included in each edge line segment of the card, and comparing the number of pixels with a preset number of points;
    删除像素点数量小于预设点数的噪声卡片边沿线段,按预设聚类算法处理剩余的卡片边沿线段,获得卡片边沿线段的线段数量;Delete noise card edge line segments whose number of pixels is less than the preset number of points, and process the remaining card edge line segments according to the preset clustering algorithm to obtain the number of line segments of the card edge line segment;
    若所述线段数量大于4,则输出卡片边沿缺角的检测结果。If the number of line segments is greater than 4, the detection result of the missing corner of the card edge is output.
  15. 如权利要求9至14任意一项所述的证件边沿检测设备,其中,所述将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果的步骤之后,所述证件边沿检测对应的计算机程序被所述处理器执行时还实现如下步骤:The document edge detection device according to any one of claims 9 to 14, wherein said inputting said document body image to a preset edge detection model to obtain card edge line segments, analyzing said card edge line segments, and outputting the document edge After the step of detecting the result, when the computer program corresponding to the edge detection of the document is executed by the processor, the following steps are further implemented:
    对所述卡片边沿线段围成的矩形区域进行文字识别,获得所述证件主体图像中包含的文字信息;Perform text recognition on the rectangular area enclosed by the edge of the card to obtain the text information contained in the main body image of the certificate;
    根据所述文字信息将所述目标图像分类保存至对应的证件图像数据库。According to the text information, the target image is classified and saved to a corresponding certificate image database.
  16. 一种计算机可读存储介质,其中,所述计算机可读存储介质上存储有证件边沿检测对应的计算机程序,所述证件边沿检测对应的计算机程序被处理器执行时实现如下步骤:A computer-readable storage medium, wherein a computer program corresponding to document edge detection is stored on the computer-readable storage medium, and the following steps are implemented when the computer program corresponding to document edge detection is executed by a processor:
    在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像;When receiving the edge detection request of the image credential, acquiring the target image associated with the edge detection request of the image credential;
    将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片;Input the target image to a preset face recognition model, extract facial feature points in the target image, and determine the target image according to the facial feature points and the feature coordinates of the face feature points 'S face photo;
    根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像;According to the photo information of the face photo, extracting a document body image containing the face photo from the target image;
    将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果。Input the main body image of the certificate to a preset edge detection model to obtain the edge line segment of the card, analyze the edge line segment of the card, and output the edge detection result of the certificate.
  17. 如权利要求16所述的计算机可读存储介质,其中,所述在接收到图像证件边沿检测请求时,获取所述图像证件边沿检测请求关联的目标图像的步骤之后,所述证件边沿检测对应的计算机程序被处理器执行时还实现如下步骤:The computer-readable storage medium according to claim 16, wherein, after the step of obtaining the target image associated with the image certificate edge detection request when the image certificate edge detection request is received, the certificate edge detection corresponds to When the computer program is executed by the processor, the following steps are also implemented:
    将所述目标图像输入至预设边沿检测模型,输出线段识别结果,根据所述线段识别结果判断所述目标图像中是否存在直线;Inputting the target image into a preset edge detection model, outputting a line segment recognition result, and judging whether there is a straight line in the target image according to the line segment recognition result;
    若所述目标图像中存在直线,则根据所述直线和所述直接的投影,确定所述目标图像的倾斜角度,按照所述倾斜角度反向移动目标图像。If there is a straight line in the target image, the inclination angle of the target image is determined according to the straight line and the direct projection, and the target image is moved backward according to the inclination angle.
  18. 如权利要求16所述的计算机可读存储介质,其中,所述将所述目标图像输入至预设人脸识别模型,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片的步骤,包括:The computer-readable storage medium according to claim 16, wherein said inputting said target image to a preset face recognition model, extracting face feature points in said target image, and according to said face feature points And the feature coordinates of the feature points of the face, the step of determining the face photo in the target image includes:
    将所述目标图像输入至预设人脸识别模型,获得识别结果并根据所述识别结果判断所述目标图像中是否包含人脸图像;Inputting the target image into a preset face recognition model, obtaining a recognition result, and judging whether the target image contains a face image according to the recognition result;
    若所述目标图像中不包含人脸图像,则将所述目标图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果;If the target image does not contain a human face image, input the target image to a preset edge detection model to obtain a card edge line segment, analyze the card edge line segment, and output a document edge detection result;
    若所述目标图像中包含人脸图像,提取所述目标图像中的人脸特征点,根据所述人脸特征点和所述人脸特征点的特征坐标,确定所述目标图像中的人脸照片。If the target image contains a face image, extract the face feature points in the target image, and determine the face in the target image according to the face feature points and the feature coordinates of the face feature points Photo.
  19. 如权利要求16所述的计算机可读存储介质,其中,所述根据所述人脸照片的照片信息,从所述目标图像中提取包含人脸照片的证件主体图像的步骤,包括:15. The computer-readable storage medium according to claim 16, wherein the step of extracting a document body image containing the face photo from the target image according to the photo information of the face photo comprises:
    获取所述人脸照片的照片信息,其中,所述照片信息包括人脸照片的位置信息和尺寸信息;Acquiring photo information of the face photo, where the photo information includes location information and size information of the face photo;
    查询预设人证映射表,获取所述位置信息对应的证件类型,根据所述证件类型和所述人脸照片的尺寸信息确定证件尺寸信息;Query a preset person ID mapping table, obtain the ID type corresponding to the location information, and determine ID size information according to the ID type and the size information of the face photo;
    根据所述证件尺寸信息和所述人脸照片的照片信息,从所述目标图像中提取包含所述人脸照片的证件主体图像。According to the credential size information and the photo information of the face photo, a credential body image containing the face photo is extracted from the target image.
  20. 如权利要求16所述的计算机可读存储介质,其中,所述将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段,分析所述卡片边沿线段,输出证件边沿检测结果的步骤,包括:The computer-readable storage medium according to claim 16, wherein the step of inputting the main body image of the document into a preset edge detection model to obtain the edge line segment of the card, analyzing the edge line segment of the card, and outputting the edge detection result of the document ,include:
    将所述证件主体图像输入至预设边沿检测模型,获得卡片边沿线段;Input the main body image of the certificate to the preset edge detection model to obtain the edge line segment of the card;
    根据预设离散点分类统计算法处理各所述卡片边沿线段,获得所述卡片边沿线段的中点;Processing each of the edge line segments of the card according to a preset discrete point classification statistical algorithm to obtain the midpoint of the edge line segment of the card;
    对所述中点进行近邻四分类,将同一中点对应的卡片边沿线段上的点作为一簇,删除每一簇中的异常点,对每一簇中剩余的点进行支持向量机二分类;Performing four nearest neighbor classifications on the midpoint, taking the points on the edge line segment of the card corresponding to the same midpoint as a cluster, deleting the abnormal points in each cluster, and performing the support vector machine two classification on the remaining points in each cluster;
    统计每一簇所有点到支持向量的距离,将所述距离取立方后除以这一簇所有点数量,获得计算结果,将所述计算结果与预设阈值进行比较;Count the distances from all points of each cluster to the support vector, take the cube of the distance and divide by the number of all points in this cluster to obtain a calculation result, and compare the calculation result with a preset threshold;
    若所述计算结果大于预设阈值,则输出卡片边沿缺角的检测结果。If the calculation result is greater than the preset threshold, the detection result of the missing corner of the card edge is output.
PCT/CN2020/136317 2020-04-30 2020-12-15 Certificate edge detection method and apparatus, and device and medium WO2021218183A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010362784.8 2020-04-30
CN202010362784.8A CN111582134A (en) 2020-04-30 2020-04-30 Certificate edge detection method, device, equipment and medium

Publications (1)

Publication Number Publication Date
WO2021218183A1 true WO2021218183A1 (en) 2021-11-04

Family

ID=72114248

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/136317 WO2021218183A1 (en) 2020-04-30 2020-12-15 Certificate edge detection method and apparatus, and device and medium

Country Status (2)

Country Link
CN (1) CN111582134A (en)
WO (1) WO2021218183A1 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111582134A (en) * 2020-04-30 2020-08-25 平安科技(深圳)有限公司 Certificate edge detection method, device, equipment and medium
CN112883959B (en) * 2021-01-21 2023-07-25 平安银行股份有限公司 Identity card integrity detection method, device, equipment and storage medium
CN113221926B (en) * 2021-06-23 2022-08-02 华南师范大学 Line segment extraction method based on angular point optimization

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107742094A (en) * 2017-09-22 2018-02-27 江苏航天大为科技股份有限公司 Improve the image processing method of testimony of a witness comparison result
CN109376735A (en) * 2018-08-31 2019-02-22 百度在线网络技术(北京)有限公司 Identity information extracting method, device, electronic equipment and storage medium
CN110248037A (en) * 2019-05-30 2019-09-17 苏宁金融服务(上海)有限公司 A kind of identity document scan method and device
US20190355122A1 (en) * 2016-12-30 2019-11-21 Huawei Technologies Co., Ltd. Device, Method, and Graphical User Interface for Processing Document
CN110781890A (en) * 2019-10-25 2020-02-11 上海德启信息科技有限公司 Identification card identification method and device, electronic equipment and readable storage medium
CN111079571A (en) * 2019-11-29 2020-04-28 杭州数梦工场科技有限公司 Identification card information identification and edge detection model training method and device
CN111582134A (en) * 2020-04-30 2020-08-25 平安科技(深圳)有限公司 Certificate edge detection method, device, equipment and medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190355122A1 (en) * 2016-12-30 2019-11-21 Huawei Technologies Co., Ltd. Device, Method, and Graphical User Interface for Processing Document
CN107742094A (en) * 2017-09-22 2018-02-27 江苏航天大为科技股份有限公司 Improve the image processing method of testimony of a witness comparison result
CN109376735A (en) * 2018-08-31 2019-02-22 百度在线网络技术(北京)有限公司 Identity information extracting method, device, electronic equipment and storage medium
CN110248037A (en) * 2019-05-30 2019-09-17 苏宁金融服务(上海)有限公司 A kind of identity document scan method and device
CN110781890A (en) * 2019-10-25 2020-02-11 上海德启信息科技有限公司 Identification card identification method and device, electronic equipment and readable storage medium
CN111079571A (en) * 2019-11-29 2020-04-28 杭州数梦工场科技有限公司 Identification card information identification and edge detection model training method and device
CN111582134A (en) * 2020-04-30 2020-08-25 平安科技(深圳)有限公司 Certificate edge detection method, device, equipment and medium

Also Published As

Publication number Publication date
CN111582134A (en) 2020-08-25

Similar Documents

Publication Publication Date Title
WO2021218183A1 (en) Certificate edge detection method and apparatus, and device and medium
US9754164B2 (en) Systems and methods for classifying objects in digital images captured using mobile devices
WO2019169772A1 (en) Picture processing method, electronic apparatus, and storage medium
US11610084B1 (en) Apparatuses, methods, and systems for 3-channel dynamic contextual script recognition using neural network image analytics and 4-tuple machine learning with enhanced templates and context data
CN111209827B (en) Method and system for OCR (optical character recognition) bill problem based on feature detection
WO2021212873A1 (en) Defect detection method and apparatus for four corners of certificate, and device and storage medium
WO2022156178A1 (en) Image target comparison method and apparatus, computer device and readable storage medium
CN112381775A (en) Image tampering detection method, terminal device and storage medium
CN111353491B (en) Text direction determining method, device, equipment and storage medium
WO2021151319A1 (en) Card edge detection method, apparatus, and device, and readable storage medium
CN110795714A (en) Identity authentication method and device, computer equipment and storage medium
JP2019102061A (en) Text line segmentation method
CN110866457A (en) Electronic insurance policy obtaining method and device, computer equipment and storage medium
CN111368632A (en) Signature identification method and device
CN111222585A (en) Data processing method, device, equipment and medium
CN110443184A (en) ID card information extracting method, device and computer storage medium
CN110222660B (en) Signature authentication method and system based on dynamic and static feature fusion
CN113627423A (en) Circular seal character recognition method and device, computer equipment and storage medium
WO2019071663A1 (en) Electronic apparatus, virtual sample generation method and storage medium
Fan et al. A robust proposal generation method for text lines in natural scene images
WO2021184718A1 (en) Card border recognition method, apparatus and device, and computer storage medium
CN113610090B (en) Seal image identification and classification method, device, computer equipment and storage medium
US11900705B2 (en) Intelligent engineering data digitization
CN115205881A (en) Form identification method, equipment and medium
WO2019071476A1 (en) Express information input method and system based on intelligent terminal

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20933379

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20933379

Country of ref document: EP

Kind code of ref document: A1