Methods, devices, computer-readable media and electronic equipment for verifying the authenticity of documents
By performing anti-counterfeiting recognition and feature mining on document images and using multiple verification models to verify feature combinations, the problem of low accuracy in document authenticity recognition has been solved, achieving higher recognition accuracy and generalization ability.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- TENCENT TECHNOLOGY (SHENZHEN) CO LTD
- Filing Date
- 2021-05-21
- Publication Date
- 2026-05-26
AI Technical Summary
Existing methods for verifying the authenticity of documents have low accuracy and are difficult to effectively distinguish between genuine and counterfeit documents.
By acquiring an anti-counterfeiting recognition model, the document image is processed for anti-counterfeiting recognition, feature mining is performed to generate extended features, and multiple verification models are used to verify the feature combination, ultimately determining the authenticity of the document.
It improves the accuracy and generalization ability of document authenticity recognition, and reduces the problem of low recognition accuracy caused by model overfitting or underfitting.
Smart Images

Figure CN115375893B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of computer and communication technology, and specifically relates to a method, device, computer-readable medium and electronic device for identifying the authenticity of documents. Background Technology
[0002] Identification documents (such as ID cards, passports, and driver's licenses) are important credentials recording basic personal information and are widely used in many areas of social activity. In daily life, people often need to upload images of their identification documents online for identity verification. However, users may upload images of counterfeit documents to impersonate others, thus necessitating the verification of document authenticity. However, existing document authenticity verification methods suffer from problems such as low accuracy.
[0003] It should be noted that the information disclosed in the background section above is only used to enhance the understanding of the background of this application, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention
[0004] The purpose of this application is to provide a method, device, computer-readable medium, and electronic device for identifying the authenticity of documents, so as to solve the problem of low accuracy in the current identification of the authenticity of documents.
[0005] Other features and advantages of this application will become apparent from the following detailed description, or may be learned in part from practice of this application.
[0006] According to one aspect of the embodiments of this application, a method for identifying the authenticity of identification documents is provided, characterized in that it includes:
[0007] Obtain the anti-counterfeiting recognition results obtained by performing anti-counterfeiting recognition processing on multiple images of the target document using the anti-counterfeiting recognition model;
[0008] Feature mining is performed on the anti-counterfeiting recognition results of the multiple document images to obtain extended features;
[0009] At least one feature combination is generated based on the anti-counterfeiting recognition result and the extended features, and the feature combination is verified by the verification model corresponding to each feature combination to obtain the verification result corresponding to each feature combination.
[0010] The authenticity of the target document is determined based on the verification results corresponding to each combination of features.
[0011] According to one aspect of the embodiments of this application, a document authenticity verification device is provided, comprising:
[0012] The anti-counterfeiting recognition result acquisition module is used to acquire the anti-counterfeiting recognition results obtained by the anti-counterfeiting recognition model through anti-counterfeiting recognition processing on multiple document images of the target document;
[0013] The feature mining module is used to perform feature mining on the anti-counterfeiting recognition results of the multiple document images to obtain extended features;
[0014] The verification module is used to generate at least one feature combination based on the anti-counterfeiting recognition result and the extended features, and to perform verification processing on each feature combination through the verification model corresponding to each feature combination to obtain the verification result corresponding to each feature combination.
[0015] The document authenticity determination module is used to determine the authenticity of the target document based on the verification results corresponding to the various feature combinations.
[0016] In one embodiment of this application, the anti-counterfeiting identification result acquisition module includes:
[0017] The anti-counterfeiting point detection unit is used to detect anti-counterfeiting points contained in multiple document images of the target document, including static anti-counterfeiting points and dynamic anti-counterfeiting points;
[0018] A static anti-counterfeiting point identification unit is used to perform anti-counterfeiting identification on each of the static anti-counterfeiting points through the anti-counterfeiting identification model, and obtain the static anti-counterfeiting identification result of each of the static anti-counterfeiting points, wherein the static anti-counterfeiting identification result includes the authenticity probability of the static anti-counterfeiting point;
[0019] The dynamic anti-counterfeiting point identification unit is used to perform anti-counterfeiting identification on each of the dynamic anti-counterfeiting points through the anti-counterfeiting identification model to obtain dynamic anti-counterfeiting identification results. The dynamic anti-counterfeiting identification results include the authenticity probability of the dynamic anti-counterfeiting point and the feature change sequence of the dynamic anti-counterfeiting point.
[0020] In one embodiment of this application, the feature mining module includes:
[0021] The static feature mining unit is used to calculate the statistical value of the authenticity probability of each static anti-counterfeiting point based on the static anti-counterfeiting identification result of each static anti-counterfeiting point, and use the statistical value of the authenticity probability of each static anti-counterfeiting point as the extended feature. The statistical value includes at least one of mean, variance, median and gradient.
[0022] In one embodiment of this application, the feature mining module includes:
[0023] The dynamic feature mining unit is used to calculate the statistical value of the authenticity probability of each dynamic anti-counterfeiting point based on the dynamic anti-counterfeiting identification result of each dynamic anti-counterfeiting point. The statistical value includes at least one of mean, variance, median and gradient. The unit samples the feature change sequence of the dynamic anti-counterfeiting point according to multiple sampling rules to obtain the feature change sub-sequence. The statistical value of the authenticity probability of the dynamic anti-counterfeiting point and the feature change sub-sequence are used as the extended features.
[0024] In one embodiment of this application, the at least one feature combination includes a fused feature obtained by fusing the anti-counterfeiting recognition result and the extended feature, and the verification module is specifically used for:
[0025] The fusion feature is verified by a first verification model to obtain a first verification result corresponding to the fusion feature. The first verification model is trained based on the fusion feature of the training samples.
[0026] In one embodiment of this application, the document authenticity determination module is specifically used for:
[0027] If the probability value contained in the first verification result is greater than or equal to a preset threshold, the target document is determined to be genuine; if the probability value contained in the first verification result is less than the preset threshold, the target document is determined to be fake.
[0028] In one embodiment of this application, the at least one feature combination includes the anti-counterfeiting identification result and the extended feature, and the verification module is specifically used for:
[0029] The extended features are verified using a second verification model to obtain a second verification result corresponding to the extended features. The second verification model is trained based on the extended features of the training samples. The anti-counterfeiting recognition result is verified using a third verification model to obtain a third verification result corresponding to the anti-counterfeiting recognition result. The third verification model is trained based on the anti-counterfeiting recognition results of the training samples.
[0030] In one embodiment of this application, the document authenticity determination module is specifically used for:
[0031] Obtain the first accuracy of the first verification model and the second accuracy of the second verification model;
[0032] The weighted average of the probability values contained in the first verification result and the probability values contained in the second verification result is determined based on the first accuracy rate and the second accuracy rate.
[0033] The authenticity of the target document is determined based on the weighted average value.
[0034] In one embodiment of this application, the at least one feature combination includes the anti-counterfeiting identification result, the extended feature, and a fused feature obtained by fusing the anti-counterfeiting identification result and the extended feature. The verification module is specifically used for:
[0035] The fused features are verified using a first verification model to obtain a first verification result corresponding to the fused features. The first verification model is trained based on the fused features of the training samples. The extended features are verified using a second verification model to obtain a second verification result corresponding to the extended features. The second verification model is trained based on the extended features of the training samples. The anti-counterfeiting recognition result is verified using a third verification model to obtain a third verification result corresponding to the anti-counterfeiting recognition result. The third verification model is trained based on the anti-counterfeiting recognition result of the training samples.
[0036] In one embodiment of this application, the document authenticity determination module is specifically used for:
[0037] Obtain the first accuracy of the first verification model, the second accuracy of the second verification model, and the third accuracy of the third verification model;
[0038] The probability values contained in the first verification result, the probability values contained in the second verification result, and the weighted average of the probability values contained in the third verification result are determined based on the first accuracy rate, the second accuracy rate, and the third accuracy rate.
[0039] The authenticity of the target document is determined based on the weighted average value.
[0040] In one embodiment of this application, the apparatus further includes:
[0041] The training sample acquisition module is used to acquire the anti-counterfeiting recognition results of the anti-counterfeiting recognition model for multiple training sample document images respectively.
[0042] The training sample feature mining module is used to perform feature mining on the anti-counterfeiting recognition results of the training samples to obtain extended features of the training samples.
[0043] The training sample feature fusion module is used to fuse the anti-counterfeiting recognition result of the training sample with the extended features of the training sample to obtain the training sample fused features;
[0044] The first verification model training module is used to construct a first machine learning model and train the first machine learning model by fusing features from the training samples to obtain the first verification model.
[0045] The second verification model training module is used to construct a second machine learning model and train the second machine learning model by expanding features through the training samples to obtain the second verification model.
[0046] The third verification model training module is used to construct a third machine learning model and train the third machine learning model using the anti-counterfeiting recognition results of the training samples to obtain the third verification model.
[0047] In one embodiment of this application, the apparatus further includes:
[0048] The first accuracy determination module is used to test the first verification model by fusing features of test samples, and determine the first accuracy of the first verification model based on the test results.
[0049] The second accuracy determination module is used to test the second verification model by expanding features through test samples, and to determine the second accuracy of the second verification model based on the test results.
[0050] The third accuracy determination module is used to test the third verification model through the anti-counterfeiting recognition results of the test samples, and determine the third accuracy of the third verification model based on the test results.
[0051] According to one aspect of the embodiments of this application, a computer-readable medium is provided, on which a computer program is stored, which, when executed by a processor, implements the document authenticity recognition method as described in the above technical solutions.
[0052] According to one aspect of the embodiments of this application, an electronic device is provided, the electronic device comprising: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to perform a document authenticity identification method as described above by executing the executable instructions.
[0053] According to one aspect of the embodiments of this application, a computer program product or computer program is provided, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform the document authenticity verification method as described above.
[0054] In the technical solution provided in this application embodiment, after obtaining the anti-counterfeiting recognition result of the anti-counterfeiting recognition model, the authenticity of the target document is not directly determined based on the anti-counterfeiting recognition result. Instead, feature mining is performed on the anti-counterfeiting recognition result to obtain extended features, adding features in multiple dimensions that can be used for anti-counterfeiting recognition. This allows for multi-dimensional identification of the target document's authenticity, improving the accuracy of document authenticity recognition. Furthermore, different feature combinations are verified by different verification models, and finally, the authenticity of the target document is determined by the verification results of each feature combination. This enhances the generalization ability of document authenticity recognition and effectively solves the problem of low recognition accuracy caused by model overfitting or underfitting.
[0055] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and do not limit this application. Attached Figure Description
[0056] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application. It is obvious that the drawings described below are merely some embodiments of this application, and those skilled in the art can obtain other drawings based on these drawings without any inventive effort.
[0057] Figure 1 An exemplary system architecture block diagram illustrating the application of the technical solution of this application is shown schematically.
[0058] Figure 2 A flowchart illustrating a document authenticity verification method provided in one embodiment of this application is shown.
[0059] Figure 3 The flowchart illustrating the anti-counterfeiting recognition process of an ID card image by an anti-counterfeiting recognition model provided in one embodiment of this application is shown in the illustration.
[0060] Figure 4 A schematic diagram illustrating a document authenticity verification method provided in another embodiment of this application is shown.
[0061] Figure 5 A schematic diagram of the structure of the document authenticity recognition device provided in the embodiments of this application is shown.
[0062] Figure 6 The diagram illustrates the structure of the multi-anti-counterfeiting point result integration system provided in the embodiments of this application.
[0063] Figure 7 A schematic diagram of a computer system architecture suitable for implementing the embodiments of this application is shown. Detailed Implementation
[0064] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, these exemplary embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided to make this application more comprehensive and complete, and to fully convey the concept of the exemplary embodiments to those skilled in the art.
[0065] Furthermore, the described features, structures, or characteristics can be combined in any suitable manner in one or more embodiments. Numerous specific details are provided in the following description to give a thorough understanding of embodiments of this application. However, those skilled in the art will recognize that the technical solutions of this application can be practiced without one or more of the specific details, or other methods, components, apparatuses, steps, etc., can be employed. In other instances, well-known methods, apparatuses, implementations, or operations are not shown or described in detail to avoid obscuring various aspects of this application.
[0066] The block diagrams shown in the accompanying drawings are merely functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities can be implemented in software, in one or more hardware modules or integrated circuits, or in different network and / or processor devices and / or microcontroller devices.
[0067] The flowcharts shown in the accompanying drawings are merely illustrative and do not necessarily include all content and operations / steps, nor do they necessarily have to be performed in the described order. For example, some operations / steps can be broken down, while others can be combined or partially combined; therefore, the actual execution order may change depending on the specific circumstances.
[0068] It should be noted that "multiple" in this article refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone. The character " / " generally indicates that the preceding and following related objects have an "or" relationship.
[0069] The technical solution of this application embodiment uses a machine learning model to identify the authenticity of documents. Machine learning (ML) is a multidisciplinary field involving probability theory, statistics, approximation theory, convex analysis, algorithm complexity theory, and many other disciplines. It specifically studies how computers can simulate or implement human learning behavior to acquire new knowledge or skills and reorganize existing knowledge structures to continuously improve their performance. Machine learning is the core of artificial intelligence and the fundamental way to give computers intelligence; its applications span all areas of artificial intelligence. Machine learning and deep learning typically include techniques such as artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and instructional learning. The machine learning model used in the technical solution of this application embodiment can be deployed on... Figure 1 In the system architecture shown.
[0070] Figure 1 An exemplary system architecture block diagram illustrating the application of the technical solution of this application is shown schematically.
[0071] like Figure 1 As shown, the system architecture 100 may include a terminal device 101, a network 102, and a server 103. The terminal device 101 may include various electronic devices such as smartphones, tablets, laptops, and desktop computers. The server 103 may be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services. The network 102 may be a communication medium of various connection types capable of providing a communication link between the terminal device 101 and the server 103, such as a wired communication link or a wireless communication link. Wireless communication links include, but are not limited to, Bluetooth, Wi-Fi, Near Field Communication (NFC), and cellular mobile communication networks. Users can use the terminal device 101 to interact with the server 103 through the network 102 to receive or send messages, etc.
[0072] Depending on the implementation requirements, the system architecture in this application embodiment can have any number of terminal devices 101, network 102, and server 103. For example, server 103 can be a server group composed of multiple server devices. In addition, the technical solutions provided in this application embodiment can be applied to terminal device 101, or to server 103, or can be implemented jointly by terminal device 101 and server 103. This application does not impose any special limitations on this.
[0073] For example, terminal device 101 can acquire multiple images of the target document 104 that needs to be verified for authenticity, and then send the multiple document images to server 103 via network 102. After receiving these multiple document images, server 103 first performs anti-counterfeiting recognition processing on each of the multiple document images using an anti-counterfeiting recognition model to obtain the corresponding anti-counterfeiting recognition results; then it performs feature mining on the anti-counterfeiting recognition results of the multiple document images to obtain extended features; finally, it generates at least one feature combination based on the anti-counterfeiting recognition results and extended features, and verifies each feature combination using the verification model corresponding to each feature combination to obtain the verification results corresponding to each feature combination, and then determines the authenticity of the target document based on the verification results corresponding to each feature combination.
[0074] In one embodiment of this application, after determining the authenticity of the target document 104, the server 103 can return the authenticity result of the target document 104 to the terminal device 101 through the network 102, and then the terminal device 101 can display the authenticity result of the target document 104 to the user.
[0075] In one embodiment of this application, the document authenticity verification method provided in this embodiment is executed by server 103. Server 103 is used to receive multiple document images of the target document 104 uploaded by terminal device 101, and to identify the authenticity of the target document 104 based on the multiple document images. Accordingly, the document authenticity verification device is generally set in server 103. However, it is readily understood by those skilled in the art that the document authenticity verification method provided in this embodiment can also be executed by terminal device 101, and accordingly, the document authenticity verification device can also be set in terminal device 101. This exemplary embodiment does not impose any special limitations on this. For example, in one exemplary embodiment, terminal device 101 is used to collect and acquire multiple document images of the target document 104, and to identify the authenticity of the target document 104 based on the multiple document images.
[0076] The implementation details of the technical solutions in the embodiments of this application are described in detail below:
[0077] Figure 2 The flowchart of a document authenticity verification method according to an embodiment of this application is illustrated schematically. This document authenticity verification method can be executed by a server, which can be... Figure 1 The server 103 shown; this document authenticity verification method can also be executed by a terminal device, which can be... Figure 1 The terminal device 101 shown is as follows. Figure 2 As shown, one embodiment of this application provides a document authenticity verification method that includes at least steps 210 to 240, specifically:
[0078] Step 210: Obtain the anti-counterfeiting recognition results obtained by performing anti-counterfeiting recognition processing on multiple document images of the target document by the anti-counterfeiting recognition model.
[0079] Specifically, the target document can be a physical document such as an ID card, passport, social security card, or medical insurance card. Multiple images of the target document can be obtained by an image acquisition device capturing images of the target document from different angles, or by an image acquisition device capturing a video stream containing the target document from different angles and then extracting multiple document images from that video stream. The anti-counterfeiting recognition model is a conventional model used to identify the authenticity of document images. When processing the document images, the anti-counterfeiting recognition model performs anti-counterfeiting recognition on each image separately and outputs the corresponding recognition result. Thus, after multiple document images undergo anti-counterfeiting recognition processing by the anti-counterfeiting recognition model, multiple anti-counterfeiting recognition results can be obtained.
[0080] In one embodiment of this application, the target document typically has markings with anti-counterfeiting identification and detection functions, referred to as anti-counterfeiting dots. When performing anti-counterfeiting identification on the document image, the anti-counterfeiting identification model usually identifies the anti-counterfeiting dots on the document image, such as... Figure 3 As shown, the anti-counterfeiting recognition model for document images includes at least steps 310 to 330, specifically:
[0081] Step 310: Detect the anti-counterfeiting points contained in multiple document images of the target document. The anti-counterfeiting points include static anti-counterfeiting points and dynamic anti-counterfeiting points.
[0082] Specifically, anti-counterfeiting features include static and dynamic anti-counterfeiting features. Static anti-counterfeiting features are those on the document that do not change visually (e.g., color, shape, outline, contrast, saturation, etc.) due to environmental changes (e.g., changes in document angle or lighting). Examples include textured text printed on the document using microprinting technology. Dynamic anti-counterfeiting features are those on the document that change visually (e.g., color, shape, outline, contrast, clarity, saturation, etc.) according to environmental changes (e.g., changes in document angle or lighting). Examples include color-changing inks, motion printing, holograms, laser imaging, and 3D embossing.
[0083] Step 320: Perform anti-counterfeiting identification on each static anti-counterfeiting point using the anti-counterfeiting identification model to obtain the static anti-counterfeiting identification results for each static anti-counterfeiting point. The static anti-counterfeiting identification results include the authenticity probability of the static anti-counterfeiting point.
[0084] Step 330: Perform anti-counterfeiting identification on each dynamic anti-counterfeiting point through the anti-counterfeiting identification model to obtain the dynamic anti-counterfeiting identification result. The dynamic anti-counterfeiting identification result includes the authenticity probability of the dynamic anti-counterfeiting point and the feature change sequence of the dynamic anti-counterfeiting point.
[0085] Specifically, after detecting static and dynamic anti-counterfeiting points in the document image, the anti-counterfeiting recognition model performs anti-counterfeiting recognition processing on the static and dynamic points respectively, obtaining the corresponding static and dynamic anti-counterfeiting recognition results. For the static anti-counterfeiting recognition result, it includes the authenticity probability of the static anti-counterfeiting point, which represents the probability value that the static anti-counterfeiting point is genuine. For the dynamic anti-counterfeiting recognition result, it includes the authenticity probability of the dynamic anti-counterfeiting point and the feature change sequence of the dynamic anti-counterfeiting point. The authenticity probability represents the probability value that the dynamic anti-counterfeiting point is genuine, and the feature change sequence represents the feature sequence formed by the changes in attribute information (such as color, clarity, texture, shape, etc.) of the dynamic anti-counterfeiting points in multiple document images.
[0086] In one embodiment of this application, the authenticity probability of static anti-counterfeiting points included in the static anti-counterfeiting identification result and the authenticity probability of dynamic anti-counterfeiting points included in the dynamic anti-counterfeiting identification result are both values between 0 and 1. The closer the value is to 1, the more authentic the corresponding static or dynamic anti-counterfeiting point is. The feature change sequence of dynamic anti-counterfeiting points is generally sorted according to the time sequence of multiple document images. For example, if there are 10 document images, the 10 document images are numbered from 1 to 10 according to the time sequence. The attribute information A of the dynamic anti-counterfeiting point of the i-th document image is... i Then the characteristic change sequence of the dynamic anti-counterfeiting points can be represented as (A1, A2, A3, A4, A5, A6, A7, A8, A9, A... 10 ).
[0087] Generally speaking, document recognition usually uses the voting results of static anti-counterfeiting recognition results of each static anti-counterfeiting point and dynamic anti-counterfeiting recognition results of each dynamic anti-counterfeiting point as the final authenticity recognition result of the document image. The authenticity result obtained in this way is difficult to distinguish the quality and importance of each anti-counterfeiting point, has poor expression ability of anti-counterfeiting points, and the accuracy and generalization of anti-counterfeiting results still need to be improved.
[0088] Continue to refer to Figure 2 As shown, in step 220, feature mining is performed on the anti-counterfeiting recognition results of multiple document images to obtain extended features.
[0089] Specifically, feature mining involves further analyzing and processing the anti-counterfeiting recognition results of multiple document images to obtain extended features. Feature mining can be performed by calculating relevant statistical values based on the anti-counterfeiting recognition results of multiple document images, or by analyzing the differences or similarities in the anti-counterfeiting recognition results of multiple document images. Alternatively, it can pre-set standards for anti-counterfeiting recognition results (such as setting the range of authenticity probabilities for anti-counterfeiting points in the anti-counterfeiting recognition results), and then analyze the differences or similarities between the anti-counterfeiting recognition results of multiple document images and the pre-set standards.
[0090] In one embodiment of this application, since the anti-counterfeiting recognition result of the document image includes static anti-counterfeiting recognition result and dynamic anti-counterfeiting recognition result, feature mining also includes feature mining of static anti-counterfeiting recognition result and feature mining of dynamic anti-counterfeiting recognition result.
[0091] In one embodiment of this application, feature mining of static anti-counterfeiting identification results includes: calculating the statistical value of the authenticity probability of each static anti-counterfeiting point based on the static anti-counterfeiting identification results of each static anti-counterfeiting point, and using the statistical value of the authenticity probability of the static anti-counterfeiting points as an extended feature. The statistical value includes at least one of the following: mean, variance, median, and gradient. Specifically, feature mining of static anti-counterfeiting identification results involves calculating the statistical value of the authenticity probability of each static anti-counterfeiting point, using this statistical value as an extended feature, and the statistical value includes at least one of the following: mean, variance, median, and gradient. The statistical value may also include statistical parameters such as standard deviation, mode, mean deviation, and range. The mean may be one or more of the following: arithmetic mean, geometric mean, harmonic mean, or weighted mean.
[0092] In one embodiment of this application, when calculating the statistical value of the authenticity probability of static anti-counterfeiting points, the authenticity probabilities of all static anti-counterfeiting points can be treated as a group of data for statistical value calculation. Alternatively, the authenticity probabilities of static anti-counterfeiting points can be grouped, and then the statistical value of each group of data can be calculated separately. For example, if there are 10 static anti-counterfeiting identification results, that is, there are 10 data points of authenticity probability of static anti-counterfeiting points, the mean, variance, and median of these 10 data points can be calculated as extended features. Optionally, the authenticity probabilities of the 10 static anti-counterfeiting points can be divided into 2 groups, with 5 data points in each group, and then the mean, variance, and median of the 5 data points in each group can be calculated as extended features. When grouping, the authenticity probabilities of the 10 static anti-counterfeiting points can be sorted according to the time series of the corresponding document images, and then the first 5 data points can be divided into one group, and the last 5 data points can be divided into another group; alternatively, the authenticity probabilities of the 10 static anti-counterfeiting points can be randomly divided into 2 groups.
[0093] In one embodiment of this application, feature mining of dynamic anti-counterfeiting identification results includes: calculating the statistical value of the authenticity probability of dynamic anti-counterfeiting points based on the dynamic anti-counterfeiting identification results of each dynamic anti-counterfeiting point, wherein the statistical value includes at least one of mean, variance, median, and gradient; sampling the feature change sequence of dynamic anti-counterfeiting points according to multiple sampling rules to obtain a feature change subsequence; and using the statistical value of the authenticity probability of dynamic anti-counterfeiting points and the feature change subsequence as extended features. Specifically, the extended features obtained from feature mining of dynamic anti-counterfeiting identification results include two parts: the statistical value of the authenticity probability of dynamic anti-counterfeiting points and the feature change subsequence of dynamic anti-counterfeiting points. The calculation method of the statistical value of the authenticity probability of dynamic anti-counterfeiting points can refer to the aforementioned description of the statistical value of the authenticity probability of static anti-counterfeiting points, and will not be repeated here. The sampling rule for the feature change sequence of dynamic anti-counterfeiting points can be a pre-set sampling rule or random sampling. For example, for the feature change sequence of dynamic anti-counterfeiting points (A1, A2, A3, A4, A5, A6, A7, A8, A9, A... 10 Following the rule of sampling once every other point, we can obtain the feature change subsequences (A1, A3, A5, A7, A9) and (A2, A4, A6, A8, A9). 10 ).
[0094] Continue to refer to Figure 2 As shown, in step 230, at least one feature combination is generated based on the anti-counterfeiting recognition result and extended features, and each feature combination is verified by the verification model corresponding to each feature combination to obtain the verification result corresponding to each feature combination.
[0095] Specifically, the feature combination is generated by combining the anti-counterfeiting identification result and the extended feature. Different combinations of the anti-counterfeiting identification result and the extended feature will result in different feature combinations. The generated feature combination can be the anti-counterfeiting identification result or the extended feature itself, or it can be a fusion feature formed by fusing the anti-counterfeiting identification result and the extended feature. For example, if the anti-counterfeiting identification result is P and the extended feature is X, the two can be fused to obtain the fusion feature (P, X).
[0096] In one embodiment of this application, at least one feature combination can be generated based on the anti-counterfeiting identification result and the extended features. For example, a feature combination can be generated based on the anti-counterfeiting identification result and the extended features, where the feature combination is the anti-counterfeiting identification result, the extended features, or a fused feature. As another example, two feature combinations can be generated based on the anti-counterfeiting identification result and the extended features, where one feature combination is the anti-counterfeiting identification result and the other is the extended features. Yet another example is that three feature combinations can be generated based on the anti-counterfeiting identification result and the extended features, where the three feature combinations are the anti-counterfeiting identification result, the extended features, and the fused features, respectively.
[0097] In one embodiment of this application, each feature combination corresponds to a verification model. This verification model is used to further analyze the data within the feature combination to output a corresponding verification result, which is also a probability value representing the authenticity of the target document. For example, when a feature combination is generated as an extended feature, the feature combination is verified using the verification model corresponding to the extended feature to obtain a verification result.
[0098] In one embodiment of this application, assuming a feature combination is generated, which is a fused feature obtained by fusing the anti-counterfeiting recognition result and the extended features, the verification process through the verification model includes: verifying the fused feature through a first verification model to obtain a first verification result corresponding to the fused feature. The first verification model is trained based on the fused features of the training samples. Specifically, the first verification model is a machine learning model (such as SVM (Support Vector Machine), GBDT (Gradient Boosting Decision Tree), Random Forest, XGBoost, etc.), which is trained through the fused features of the training samples. The fused features of the training samples are obtained by fusing the anti-counterfeiting recognition result and the extended features of the training samples of the training sample document image. The first verification result is obtained by verifying the fused feature through the first verification model. The first verification result includes a probability value M1 representing the probability that the target document is genuine based on the fused features.
[0099] In one embodiment of this application, assuming a feature combination is generated, which is combined into an extended feature, the verification process using a verification model includes: verifying the extended feature using a second verification model to obtain a second verification result corresponding to the extended feature. The second verification model is trained based on the extended features of the training samples. Specifically, the second verification model is a machine learning model (such as SVM, GBDT, Random Forest, XGBoost, etc.), which is trained using the extended features of the training samples, which are based on the training sample document images. The fused feature is then verified using the second verification model to obtain the second verification result. The second verification result includes a probability value M2 representing the probability that the target document is genuine based on the extended features.
[0100] In one embodiment of this application, assuming a feature combination is generated, which forms an anti-counterfeiting recognition result, the verification process using a verification model includes: verifying the anti-counterfeiting recognition result using a third verification model to obtain a third verification result corresponding to the anti-counterfeiting recognition result. The third verification model is trained based on the anti-counterfeiting recognition results of training samples. Specifically, the third verification model is a machine learning model (such as SVM, GBDT, Random Forest, XGBoost, etc.), trained using the anti-counterfeiting recognition results of training samples. The anti-counterfeiting recognition results of training samples are obtained through feature mining based on the anti-counterfeiting recognition results of training sample document images. The fused features are verified using the third verification model to obtain the third verification result. The third verification result includes a probability value M3 representing the probability that the target document is genuine based on the anti-counterfeiting recognition result.
[0101] In one embodiment of this application, assuming two feature combinations are generated, namely a fused feature and an extended feature, the verification process using a verification model includes: verifying the fused feature using a first verification model to obtain a first verification result corresponding to the fused feature; and verifying the extended feature using a second verification model to obtain a second verification result corresponding to the extended feature. The verification of the fused feature and the extended feature can be referred to the preceding description and will not be repeated here.
[0102] In one embodiment of this application, assuming two feature combinations are generated, namely a fused feature and an anti-counterfeiting recognition result, the verification process using a verification model includes: verifying the fused feature using a first verification model to obtain a first verification result corresponding to the fused feature; and verifying the anti-counterfeiting recognition result using a third verification model to obtain a third verification result corresponding to the anti-counterfeiting recognition result. The verification of the fused feature and the anti-counterfeiting recognition result can be referred to the preceding description and will not be repeated here.
[0103] In one embodiment of this application, assuming two feature combinations are generated, namely an extended feature and an anti-counterfeiting recognition result, the verification process using the verification model includes: verifying the extended feature using a second verification model to obtain a second verification result corresponding to the extended feature; and verifying the anti-counterfeiting recognition result using a third verification model to obtain a third verification result corresponding to the anti-counterfeiting recognition result. The verification of the anti-counterfeiting recognition result and the extended feature can be referred to the preceding description and will not be repeated here.
[0104] In one embodiment of this application, assuming three feature combinations are generated—a fused feature, an extended feature, and an anti-counterfeiting recognition result—the verification process using a verification model includes: verifying the fused feature using a first verification model to obtain a first verification result corresponding to the fused feature; verifying the extended feature using a second verification model to obtain a second verification result corresponding to the extended feature; and verifying the anti-counterfeiting recognition result using a third verification model to obtain a third verification result corresponding to the anti-counterfeiting recognition result. The verification of the fused feature, extended feature, and anti-counterfeiting recognition result can be referred to the preceding description and will not be repeated here.
[0105] In one embodiment of this application, before the verification process is performed using the verification model, the training of the verification model is further included. Specifically, this includes: obtaining the anti-counterfeiting recognition results of the anti-counterfeiting recognition model for multiple training sample document images; performing feature mining on the anti-counterfeiting recognition results of the training samples to obtain extended features of the training samples; fusing the anti-counterfeiting recognition results of the training samples with the extended features of the training samples to obtain fused features of the training samples; constructing a first machine learning model and training the first machine learning model using the fused features of the training samples to obtain a first verification model; constructing a second machine learning model and training the second machine learning model using the extended features of the training samples to obtain a second verification model; and constructing a third machine learning model and training the third machine learning model using the anti-counterfeiting recognition results of the training samples to obtain a third verification model.
[0106] Specifically, multiple training sample document images are acquired. Based on these images, an anti-counterfeiting recognition model is used to perform anti-counterfeiting recognition processing, feature mining, and feature fusion to obtain training sample anti-counterfeiting recognition results, extended features, and fused features. Then, machine learning models are constructed and trained for each of these three features, resulting in a first, second, and third validation model. The specific formation process of the training sample anti-counterfeiting recognition results, extended features, and fused features can be found in the previous description of their formation process, and will not be repeated here. By obtaining multiple types of features through feature mining and feature fusion, and training validation models for each type of feature, the expressive power and complexity of the models can be improved, thereby increasing model accuracy and reducing the risk of underfitting.
[0107] In one embodiment of this application, the first machine learning model, the second machine learning model, and the third machine learning model are preferably of the same type, such as all being SVM models. Optionally, depending on actual needs, the first machine learning model, the second machine learning model, and the third machine learning model can also be of different types, such as the first and second machine learning models being SVM models, and the third machine learning model being a GBDT model.
[0108] Continue to refer to Figure 2 Step 240: Determine the authenticity of the target document based on the verification results corresponding to each feature combination.
[0109] Specifically, when there is only one feature combination, the authenticity of the target document is determined directly by the verification result of that feature combination; when there are multiple feature combinations, the authenticity of the target document is determined jointly by the verification results corresponding to each feature combination.
[0110] In one embodiment of this application, when a feature combination is a fused feature, an extended feature, or an anti-counterfeiting identification result, the authenticity of the target document is determined by the relationship between the probability value contained in the corresponding verification result and a preset threshold. For example, if the feature combination is a fused feature, then if the probability value M1 contained in the first verification result is greater than or equal to the preset threshold, the target document is determined to be genuine; if the probability value M1 contained in the first verification result is less than the preset threshold, the target document is determined to be counterfeit. When the feature combination is an extended feature or an anti-counterfeiting identification result, the authenticity of the target document is determined by the relationship between the probability value M2 contained in the second verification result or the probability value M3 contained in the third verification result and the preset threshold.
[0111] In one embodiment of this application, the probability values M1, M2, and M3 of the first verification result are all values between 0 and 1. For example, if the probability value M1 of the first verification result is 0.6, and the preset threshold is set to 0.5, then the target document is determined to be genuine.
[0112] In one embodiment of this application, the first verification model has a first accuracy P1, the second verification model has a second accuracy P2, and the third verification model has a second accuracy P3. Before determining the authenticity of the target document based on the verification results corresponding to each feature combination, it is necessary to test the first verification model, the second verification model, and the third verification model using test sample fusion features, test sample extended features, and test sample anti-counterfeiting recognition results, respectively, and determine the first accuracy P1 of the first verification model, the second accuracy P2 of the second verification model, and the third accuracy P3 of the third verification model based on the test results.
[0113] In one embodiment of this application, when there are multiple feature combinations, the weighted average of the verification results of each feature combination can be calculated based on the accuracy of the verification model corresponding to each feature combination. The authenticity of the target document is then determined by the relationship between this weighted average and a preset threshold. For example, if there are two feature combinations, namely an extended feature and an anti-counterfeiting recognition result, the corresponding verification results are the probability value M2 contained in the second verification result and the probability value M3 contained in the third verification result. Then, the weighted average of the verification results S = M2 × P2 + M3 × P3 is calculated. If the weighted average S is greater than or equal to the preset threshold, the target document is determined to be genuine; if the weighted average S is less than the preset threshold, the target document is determined to be counterfeit.
[0114] In one embodiment of this application, when calculating the weighted average of the verification results of each feature combination based on the accuracy of the verification model corresponding to each feature combination, softmax processing can also be applied to the accuracy of the verification model corresponding to each feature combination, so that the accuracy of the verification model corresponding to each feature combination is between 0 and 1. For example, if there are three feature combinations: fused feature, extended feature, and anti-counterfeiting recognition result, and the corresponding verification results are: probability value M1 contained in the first verification result, probability value M2 contained in the second verification result, and probability value M3 contained in the third verification result, then the weighted average S of the verification results is calculated as follows:
[0115] S=softmax(P1)×M1+softmax(P2)×M2+softmax(P3)×M3
[0116] in,
[0117] In the technical solution provided in this application embodiment, after obtaining the anti-counterfeiting recognition result of the anti-counterfeiting recognition model, the authenticity of the target document is not directly determined based on the anti-counterfeiting recognition result. Instead, feature mining is performed on the anti-counterfeiting recognition result to obtain extended features, adding features in multiple dimensions that can be used for anti-counterfeiting recognition. This allows for multi-dimensional identification of the target document's authenticity, improving the accuracy of document authenticity recognition. Furthermore, different feature combinations are verified by different verification models, and finally, the authenticity of the target document is determined by the verification results of each feature combination. This enhances the generalization ability of document authenticity recognition and effectively solves the problem of low recognition accuracy caused by model overfitting or underfitting.
[0118] refer to Figure 4 . Figure 4 A schematic flowchart illustrating a document authenticity verification method provided in one embodiment of this application is shown. Figure 4 As shown, an embodiment of this application provides a document authenticity verification method including steps 1 to 6, specifically as follows:
[0119] Step 1: Collect anti-counterfeiting points.
[0120] Specifically, anti-counterfeiting point collection refers to acquiring multiple training sample ID card images and detecting the anti-counterfeiting points contained in these images. The anti-counterfeiting points in the training sample ID card images include static and dynamic anti-counterfeiting points. A description of static and dynamic anti-counterfeiting points can be found in step 210 above, and will not be repeated here.
[0121] Step 2: Feature extraction.
[0122] Specifically, feature extraction refers to obtaining the anti-counterfeiting recognition results of training samples obtained from the anti-counterfeiting recognition model for each anti-counterfeiting point. Based on the classification of anti-counterfeiting points, the training sample anti-counterfeiting recognition results include static anti-counterfeiting recognition results and dynamic anti-counterfeiting recognition results. Static anti-counterfeiting recognition results include the authenticity probability of static anti-counterfeiting points, while dynamic anti-counterfeiting recognition results include the authenticity probability of dynamic anti-counterfeiting points and the feature change sequence of dynamic anti-counterfeiting points. Related descriptions can be found in step 210 above and will not be repeated here.
[0123] 3. Feature mining.
[0124] Specifically, feature mining refers to further analysis and processing of the anti-counterfeiting recognition results of the training samples to obtain extended features of the training samples. It should be noted that... Figure 4 In the flowchart shown, step 2 feature extraction and step 3 feature mining are parallel steps following step 1 anti-counterfeiting point collection. This is used to indicate that step 2 feature extraction and step 3 feature mining are two different feature acquisition methods, and is not used to limit the specific execution order of step 2 feature extraction and step 3 feature mining. Furthermore, the data used in step 3 feature mining is the data obtained from step 2 feature extraction (i.e., the anti-counterfeiting recognition results of the training samples).
[0125] Based on the classification of anti-counterfeiting points, feature mining includes steps 3.1 and 3.2, specifically:
[0126] Step 3.1: Static feature mining.
[0127] Specifically, static feature mining refers to performing feature mining on the static anti-counterfeiting recognition results of training samples to obtain extended features of the training samples. Static feature mining mainly calculates the statistical values of the authenticity probability of each static anti-counterfeiting point, including but not limited to one or more of the mean, variance, median, gradient, standard deviation, mode, mean difference, and range of the authenticity probability of each static anti-counterfeiting point. Related descriptions can be found in step 220 above and will not be repeated here.
[0128] Step 3.2, Dynamic Feature Mining.
[0129] Specifically, dynamic feature mining refers to performing feature mining on the dynamic anti-counterfeiting recognition results of training samples to obtain extended features of the training samples. Dynamic feature mining includes two parts: calculating the statistical value of the authenticity probability of each dynamic anti-counterfeiting point and sampling the feature change sequence of the dynamic anti-counterfeiting points to form a feature change subsequence. The statistical value of the authenticity probability of each dynamic anti-counterfeiting point includes, but is not limited to, one or more of the following: mean, variance, median, gradient, standard deviation, mode, mean deviation, and range. The feature change subsequence formed by sampling the feature change sequence of the dynamic anti-counterfeiting points can be obtained according to a preset sampling rule or by random sampling. For a related description, please refer to the description in step 220 above, which will not be repeated here.
[0130] Step 4: Feature combination.
[0131] Specifically, feature combination refers to generating at least one training sample feature combination based on the anti-counterfeiting recognition result of the training sample and the extended features of the training sample. In this embodiment, the training sample feature combination includes the anti-counterfeiting recognition result of the training sample, the extended features of the training sample, and the fused features of the training sample obtained by fusing the anti-counterfeiting recognition result of the training sample and the extended features of the training sample. Related descriptions can be found in step 230 above, and will not be repeated here.
[0132] Step 5: Feature modeling.
[0133] Specifically, feature modeling refers to constructing a machine learning model for each training sample feature combination and training it to obtain a trained validation model. Specifically, it involves: constructing a first machine learning model and training it by fusing features with training samples to obtain a first validation model; constructing a second machine learning model and training it by expanding features with training samples to obtain a second validation model; and constructing a third machine learning model and training it by using anti-counterfeiting recognition results of training samples to obtain a third validation model.
[0134] Furthermore, after training and obtaining the validation models, each validation model is tested using test data to determine its accuracy. Specifically, the first validation model is tested using fused features from test samples, and its first accuracy is determined based on the test results; the second validation model is tested using expanded features from test samples, and its second accuracy is determined based on the test results; and the third validation model is tested using anti-counterfeiting recognition results from test samples, and its third accuracy is determined based on the test results.
[0135] Step 6: Model fusion.
[0136] Specifically, model fusion refers to the process of obtaining verification results from the three verification models mentioned above when verifying the authenticity of a target document. Then, a weighted average of the verification results from the three models is calculated based on their accuracy. Finally, the authenticity of the target document is determined based on this weighted average. A related description can be found in step 240 above, and will not be repeated here.
[0137] In the technical solution provided in this application embodiment, feature mining enriches the features of the anti-counterfeiting recognition results of each anti-counterfeiting point, and feature combination is used to group the features. Models are trained separately for different feature groups, and finally, model fusion is used to improve the final accuracy, generalization, and robustness of the anti-counterfeiting results. Using feature mining can better improve the model's expressive power and complexity, increase model accuracy, and reduce the risk of underfitting; using feature grouping and model fusion can improve the model's generalization ability and reduce the risk of overfitting.
[0138] It should be noted that although the steps of the method in this application are described in a specific order in the accompanying drawings, this does not require or imply that the steps must be performed in that specific order, or that all the steps shown must be performed to achieve the desired result. Additional or alternative steps may be omitted, multiple steps may be combined into one step, and / or one step may be broken down into multiple steps.
[0139] The following describes an embodiment of the apparatus of this application, which can be used to execute the document authenticity identification method in the above embodiments of this application. Figure 5 A schematic block diagram of the document authenticity verification device provided in an embodiment of this application is shown. Figure 5 As shown, the document authenticity verification device provided in this application embodiment includes:
[0140] The anti-counterfeiting recognition result acquisition module 510 is used to acquire the anti-counterfeiting recognition results obtained by the anti-counterfeiting recognition model through anti-counterfeiting recognition processing of multiple document images of the target document;
[0141] The feature mining module 520 is used to perform feature mining on the anti-counterfeiting recognition results of the multiple document images to obtain extended features;
[0142] The verification module 530 is used to generate at least one feature combination based on the anti-counterfeiting recognition result and the extended feature, and to perform verification processing on each feature combination through the verification model corresponding to each feature combination to obtain the verification result corresponding to each feature combination.
[0143] The document authenticity determination module 540 is used to determine the authenticity of the target document based on the verification results corresponding to the various feature combinations.
[0144] In one embodiment of this application, the anti-counterfeiting identification result acquisition module 510 includes:
[0145] The anti-counterfeiting point detection unit is used to detect anti-counterfeiting points contained in multiple document images of the target document, including static anti-counterfeiting points and dynamic anti-counterfeiting points;
[0146] A static anti-counterfeiting point identification unit is used to perform anti-counterfeiting identification on each of the static anti-counterfeiting points through the anti-counterfeiting identification model, and obtain the static anti-counterfeiting identification result of each of the static anti-counterfeiting points, wherein the static anti-counterfeiting identification result includes the authenticity probability of the static anti-counterfeiting point;
[0147] The dynamic anti-counterfeiting point identification unit is used to perform anti-counterfeiting identification on each of the dynamic anti-counterfeiting points through the anti-counterfeiting identification model to obtain dynamic anti-counterfeiting identification results. The dynamic anti-counterfeiting identification results include the authenticity probability of the dynamic anti-counterfeiting point and the feature change sequence of the dynamic anti-counterfeiting point.
[0148] In one embodiment of this application, the feature mining module 520 includes:
[0149] The static feature mining unit is used to calculate the statistical value of the authenticity probability of each static anti-counterfeiting point based on the static anti-counterfeiting identification result of each static anti-counterfeiting point, and use the statistical value of the authenticity probability of each static anti-counterfeiting point as the extended feature. The statistical value includes at least one of mean, variance, median and gradient.
[0150] In one embodiment of this application, the feature mining module 520 includes:
[0151] The dynamic feature mining unit is used to calculate the statistical value of the authenticity probability of each dynamic anti-counterfeiting point based on the dynamic anti-counterfeiting identification result of each dynamic anti-counterfeiting point. The statistical value includes at least one of mean, variance, median and gradient. The unit samples the feature change sequence of the dynamic anti-counterfeiting point according to multiple sampling rules to obtain the feature change sub-sequence. The statistical value of the authenticity probability of the dynamic anti-counterfeiting point and the feature change sub-sequence are used as the extended features.
[0152] In one embodiment of this application, the at least one feature combination includes a fused feature obtained by fusing the anti-counterfeiting recognition result and the extended feature, and the verification module 530 is specifically used for:
[0153] The fusion feature is verified by a first verification model to obtain a first verification result corresponding to the fusion feature. The first verification model is trained based on the fusion feature of the training samples.
[0154] In one embodiment of this application, the document authenticity determination module 540 is specifically used for:
[0155] If the probability value contained in the first verification result is greater than or equal to a preset threshold, the target document is determined to be genuine; if the probability value contained in the first verification result is less than the preset threshold, the target document is determined to be fake.
[0156] In one embodiment of this application, the at least one feature combination includes the anti-counterfeiting identification result and the extended feature, and the verification module 530 is specifically used for:
[0157] The extended features are verified using a second verification model to obtain a second verification result corresponding to the extended features. The second verification model is trained based on the extended features of the training samples. The anti-counterfeiting recognition result is verified using a third verification model to obtain a third verification result corresponding to the anti-counterfeiting recognition result. The third verification model is trained based on the anti-counterfeiting recognition results of the training samples.
[0158] In one embodiment of this application, the document authenticity determination module 540 is specifically used for:
[0159] Obtain the first accuracy of the first verification model and the second accuracy of the second verification model;
[0160] The weighted average of the probability values contained in the first verification result and the probability values contained in the second verification result is determined based on the first accuracy rate and the second accuracy rate.
[0161] The authenticity of the target document is determined based on the weighted average value.
[0162] In one embodiment of this application, the at least one feature combination includes the anti-counterfeiting identification result, the extended feature, and a fused feature obtained by fusing the anti-counterfeiting identification result and the extended feature. The verification module 530 is specifically used for:
[0163] The fused features are verified using a first verification model to obtain a first verification result corresponding to the fused features. The first verification model is trained based on the fused features of the training samples. The extended features are verified using a second verification model to obtain a second verification result corresponding to the extended features. The second verification model is trained based on the extended features of the training samples. The anti-counterfeiting recognition result is verified using a third verification model to obtain a third verification result corresponding to the anti-counterfeiting recognition result. The third verification model is trained based on the anti-counterfeiting recognition result of the training samples.
[0164] In one embodiment of this application, the document authenticity determination module 540 is specifically used for:
[0165] Obtain the first accuracy of the first verification model, the second accuracy of the second verification model, and the third accuracy of the third verification model;
[0166] The probability values contained in the first verification result, the probability values contained in the second verification result, and the weighted average of the probability values contained in the third verification result are determined based on the first accuracy rate, the second accuracy rate, and the third accuracy rate.
[0167] The authenticity of the target document is determined based on the weighted average value.
[0168] In one embodiment of this application, the apparatus further includes:
[0169] The training sample acquisition module is used to acquire the anti-counterfeiting recognition results of the anti-counterfeiting recognition model for multiple training sample document images respectively.
[0170] The training sample feature mining module is used to perform feature mining on the anti-counterfeiting recognition results of the training samples to obtain extended features of the training samples.
[0171] The training sample feature fusion module is used to fuse the anti-counterfeiting recognition result of the training sample with the extended features of the training sample to obtain the training sample fused features;
[0172] The first verification model training module is used to construct a first machine learning model and train the first machine learning model by fusing features from the training samples to obtain the first verification model.
[0173] The second verification model training module is used to construct a second machine learning model and train the second machine learning model by expanding features through the training samples to obtain the second verification model.
[0174] The third verification model training module is used to construct a third machine learning model and train the third machine learning model using the anti-counterfeiting recognition results of the training samples to obtain the third verification model.
[0175] In one embodiment of this application, the apparatus further includes:
[0176] The first accuracy determination module is used to test the first verification model by fusing features of test samples, and determine the first accuracy of the first verification model based on the test results.
[0177] The second accuracy determination module is used to test the second verification model by expanding features through test samples, and to determine the second accuracy of the second verification model based on the test results.
[0178] The third accuracy determination module is used to test the third verification model through the anti-counterfeiting recognition results of the test samples, and determine the third accuracy of the third verification model based on the test results.
[0179] The specific details of the document authenticity verification device provided in the various embodiments of this application have been described in detail in the corresponding method embodiments, and will not be repeated here.
[0180] refer to Figure 6 , Figure 6 A schematic diagram illustrating the structure of the multi-anti-counterfeiting point result integration system provided in this application embodiment is shown. The multi-anti-counterfeiting point result integration system provided in this embodiment can run on a terminal device, such as a computer, and can be used to implement the document authenticity verification method provided in this application embodiment. The multi-anti-counterfeiting point result integration system provided in this embodiment can also integrate the document authenticity verification device provided in this application embodiment.
[0181] like Figure 6 As shown, the multi-anti-counterfeiting point result integration system 600 provided in this application embodiment includes a feature extraction module 610, a feature mining module 620, a feature combination modeling module 630, and an anti-counterfeiting result fusion module 640. The feature mining module 620 includes a static feature mining module 621 and a dynamic feature mining module 622.
[0182] The feature extraction module 610 is used to obtain the anti-counterfeiting recognition results of the training samples obtained by the anti-counterfeiting recognition model through anti-counterfeiting recognition processing of multiple training sample document images. Each document image contains static anti-counterfeiting points and dynamic anti-counterfeiting points. Correspondingly, the training sample anti-counterfeiting recognition results include the static anti-counterfeiting recognition results and the dynamic anti-counterfeiting recognition results. The static anti-counterfeiting recognition results include the authenticity probability of the static anti-counterfeiting points, and the dynamic anti-counterfeiting recognition results include the authenticity probability of the dynamic anti-counterfeiting points and the feature change sequence of the dynamic anti-counterfeiting points.
[0183] The feature mining module 620 is used to perform feature mining on the anti-counterfeiting recognition results of the training samples for each anti-counterfeiting point, obtaining extended features of the training samples. The static feature mining module 621 of the feature mining module 620 is used to perform feature mining on the static anti-counterfeiting recognition results of the training samples, mainly calculating the statistical values of the authenticity probability of static anti-counterfeiting points in the static anti-counterfeiting recognition results of each training sample, including but not limited to calculating one or more of the mean, variance, median, gradient, standard deviation, mode, mean deviation, and range of the authenticity probability of each static anti-counterfeiting point. The dynamic feature mining module 622 of the feature mining module 620 is used to perform feature mining on the dynamic anti-counterfeiting recognition results of the training samples, mainly including calculating the statistical values of the authenticity probability of dynamic anti-counterfeiting points in the dynamic anti-counterfeiting recognition results of each training sample, and sampling the feature change sequences of the dynamic anti-counterfeiting points to form feature change subsequences. The statistical values of the authenticity probability of dynamic anti-counterfeiting points in the dynamic anti-counterfeiting recognition results of each training sample include but are not limited to calculating one or more of the mean, variance, median, gradient, standard deviation, mode, mean deviation, and range of the authenticity probability of each dynamic anti-counterfeiting point. The sampling of the feature change sequence of dynamic anti-counterfeiting points to form feature change subsequences includes random sampling and sampling according to preset rules.
[0184] The feature combination modeling module 630 is used to generate at least one feature combination based on the anti-counterfeiting recognition results and extended features of the training samples, and to construct and train machine learning models based on each feature combination to obtain trained validation models. For example, the anti-counterfeiting recognition results and extended features of the training samples are fused to obtain fused features of the training samples, a first validation model is obtained based on the fused features of the training samples, a second validation model is obtained based on the extended features of the training samples, and a third validation model is obtained based on the anti-counterfeiting recognition results of the training samples.
[0185] The anti-counterfeiting result fusion module 640 is used to obtain the corresponding verification results through the aforementioned three verification models when identifying the authenticity of the target document. Then, it calculates the weighted average of the verification results of the three verification models based on their accuracy and finally determines the authenticity of the target document based on the weighted average.
[0186] Figure 7 A schematic block diagram of a computer system architecture for implementing an electronic device according to embodiments of the present application is shown.
[0187] It should be noted that, Figure 7 The computer system 700 of the electronic device shown is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments of this application.
[0188] like Figure 7As shown, the computer system 700 includes a central processing unit (CPU) 701, which can perform various appropriate actions and processes based on programs stored in read-only memory (ROM) 702 or programs loaded from storage section 708 into random access memory (RAM) 703. The RAM 703 also stores various programs and data required for system operation. The CPU 701, ROM 702, and RAM 703 are interconnected via a bus 704. An input / output interface 705 (I / O interface) is also connected to the bus 704.
[0189] The following components are connected to the input / output interface 705: an input section 706 including a keyboard, mouse, etc.; an output section 707 including a cathode ray tube (CRT), liquid crystal display (LCD), etc., and speakers, etc.; a storage section 708 including a hard disk, etc.; and a communication section 709 including a network interface card such as a local area network card, modem, etc. The communication section 709 performs communication processing via a network such as the Internet. A drive 710 is also connected to the input / output interface 705 as needed. A removable medium 711, such as a disk, optical disk, magneto-optical disk, semiconductor memory, etc., is installed on the drive 710 as needed so that computer programs read from it can be installed into the storage section 708 as needed.
[0190] Specifically, according to embodiments of this application, the processes described in the various method flowcharts can be implemented as computer software programs. For example, embodiments of this application include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via communication section 709, and / or installed from removable medium 711. When the computer program is executed by central processing unit 701, it performs various functions defined in the system of this application.
[0191] It should be noted that the computer-readable medium shown in the embodiments of this application can be a computer-readable signal medium, a computer-readable storage medium, or any combination of the two. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), flash memory, optical fiber, portable compact disc read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this application, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In this application, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such transmitted data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. The computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to wireless, wired, etc., or any suitable combination thereof.
[0192] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram or flowchart, and combinations of blocks in a block diagram or flowchart, may be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0193] It should be noted that although several modules or units for the device used to perform actions have been mentioned in the detailed description above, this division is not mandatory. In fact, according to the embodiments of this application, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.
[0194] Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware. Therefore, the technical solutions according to the embodiments of this application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, external hard drive, etc.) or on a network, including several instructions to cause a computing device (such as a personal computer, server, touch terminal, or network device, etc.) to execute the method according to the embodiments of this application.
[0195] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein.
[0196] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.
Claims
1. A method for identifying the authenticity of a certificate, characterized in that, Including: Obtaining anti-counterfeiting recognition results obtained by performing anti-counterfeiting recognition processing on multiple document images of a target document by an anti-counterfeiting recognition model; Performing feature mining on the anti-counterfeiting recognition results of the multiple document images to obtain extended features; Fusing the anti-counterfeiting recognition results with the extended features to obtain fused features, and generating multiple feature combinations based on the anti-counterfeiting recognition results, the extended features, and the fused features; Performing verification processing on each of the feature combinations through a verification model corresponding to each feature combination to obtain a verification result corresponding to each feature combination; the verification result is a probability value that the target document is genuine; Calculating a weighted average of the verification results corresponding to each feature combination according to the accuracy rate corresponding to each verification model, and determining the authenticity of the target document based on the relationship between the weighted average and a preset threshold.
2. The method for identifying the authenticity of a certificate according to claim 1, wherein The obtaining anti-counterfeiting recognition results obtained by performing anti-counterfeiting recognition processing on multiple document images of a target document by an anti-counterfeiting recognition model includes: Detecting anti-counterfeiting points included in the multiple document images of the target document, where the anti-counterfeiting points include static anti-counterfeiting points and dynamic anti-counterfeiting points; Performing anti-counterfeiting recognition on each of the static anti-counterfeiting points through the anti-counterfeiting recognition model to obtain a static anti-counterfeiting recognition result for each of the static anti-counterfeiting points, and the static anti-counterfeiting recognition result includes the authenticity probability of the static anti-counterfeiting point; Performing anti-counterfeiting recognition on each of the dynamic anti-counterfeiting points through the anti-counterfeiting recognition model to obtain a dynamic anti-counterfeiting recognition result, and the dynamic anti-counterfeiting recognition result includes the authenticity probability of the dynamic anti-counterfeiting point and the characteristic change sequence of the dynamic anti-counterfeiting point.
3. The method for identifying the authenticity of a certificate according to claim 2, wherein The performing feature mining on the anti-counterfeiting recognition results of the multiple document images to obtain extended features includes: Calculating a statistical value of the authenticity probability of the static anti-counterfeiting points according to the static anti-counterfeiting recognition results of each of the static anti-counterfeiting points, and using the statistical value of the authenticity probability of the static anti-counterfeiting points as the extended feature, and the statistical value includes at least one of mean, variance, median, and gradient.
4. The method for identifying the authenticity of a certificate according to claim 2, wherein The performing feature mining on the anti-counterfeiting recognition results of the multiple document images to obtain extended features further includes: Calculating a statistical value of the authenticity probability of the dynamic anti-counterfeiting points according to the dynamic anti-counterfeiting recognition results of each of the dynamic anti-counterfeiting points, and the statistical value includes at least one of mean, variance, median, and gradient; Sampling the characteristic change sequence of the dynamic anti-counterfeiting points according to multiple sampling rules to obtain characteristic change subsequences; Using the statistical value of the authenticity probability of the dynamic anti-counterfeiting points and the characteristic change subsequences as the extended features.
5. The method for identifying the authenticity of a certificate according to claim 1, wherein After fusing the anti-counterfeiting recognition results with the extended features to obtain fused features, the method further includes: Performing verification processing on the fused features through a first verification model to obtain a first verification result corresponding to the fused features, and the first verification model is trained according to training sample fused features.
6. The method for identifying the authenticity of a certificate according to claim 5, wherein The method further includes: If the probability value included in the first verification result is greater than or equal to the preset threshold, determining that the target document is a genuine document; If the probability value included in the first verification result is less than the preset threshold, determining that the target document is a fake document.
7. The method for identifying the authenticity of a certificate according to claim 1, wherein The multiple feature combinations include the anti-counterfeiting recognition result and the extended features; the verification processing of each feature combination through the verification model corresponding to each feature combination to obtain the verification result corresponding to each feature combination includes: The extended features are verified using a second verification model to obtain a second verification result corresponding to the extended features. The second verification model is trained based on the extended features of the training samples. The anti-counterfeiting identification result is verified by a third verification model to obtain the third verification result corresponding to the anti-counterfeiting identification result. The third verification model is trained based on the anti-counterfeiting identification results of the training samples.
8. The method for identifying the authenticity of a certificate according to claim 7, wherein, The step of calculating the weighted average of the verification results corresponding to each feature combination based on the accuracy of each verification model, and determining the authenticity of the target document through the relationship between the weighted average and a preset threshold, includes: Obtain the second accuracy of the second verification model and the third accuracy of the third verification model; Based on the second accuracy rate and the third accuracy rate, determine the weighted average of the probability values contained in the second verification result and the probability values contained in the third verification result; The authenticity of the target document is determined based on the relationship between the weighted average value and a preset threshold.
9. The method for identifying the authenticity of a certificate according to claim 1, wherein The combination of multiple features includes the anti-counterfeiting recognition result, the extended features, and the fused features; The process of verifying each feature combination using a verification model corresponding to each feature combination to obtain the verification result corresponding to each feature combination includes: The fusion feature is verified by a first verification model to obtain a first verification result corresponding to the fusion feature. The first verification model is trained based on the fusion feature of the training samples. The extended features are verified using a second verification model to obtain a second verification result corresponding to the extended features. The second verification model is trained based on the extended features of the training samples. The anti-counterfeiting identification result is verified by a third verification model to obtain the third verification result corresponding to the anti-counterfeiting identification result. The third verification model is trained based on the anti-counterfeiting identification results of the training samples.
10. The method for identifying the authenticity of a certificate according to claim 9, wherein The step of calculating the weighted average of the verification results corresponding to each feature combination based on the accuracy of each verification model, and determining the authenticity of the target document through the relationship between the weighted average and a preset threshold, includes: Obtain the first accuracy of the first verification model, the second accuracy of the second verification model, and the third accuracy of the third verification model; Based on the first accuracy rate, the second accuracy rate, and the third accuracy rate, determine the weighted average of the probability values contained in the first verification result, the probability values contained in the second verification result, and the probability values contained in the third verification result. The authenticity of the target document is determined based on the relationship between the weighted average value and a preset threshold.
11. The method for identifying the authenticity of a certificate according to claim 10, wherein Before verifying the fused feature using the first verification model to obtain the first verification result corresponding to the fused feature, the method further includes: Obtain the anti-counterfeiting recognition results of the training sample documents output by the anti-counterfeiting recognition model for multiple training sample document images; Feature mining is performed on the anti-counterfeiting recognition results of the training samples to obtain extended features of the training samples; The anti-counterfeiting recognition results of the training samples are fused with the extended features of the training samples to obtain the fused features of the training samples; A first machine learning model is constructed and trained using the fused features from the training samples to obtain the first verification model; A second machine learning model is constructed and trained by expanding features using the training samples to obtain the second validation model; A third machine learning model is constructed and trained using the anti-counterfeiting recognition results of the training samples to obtain a third verification model.
12. The method for identifying the authenticity of a certificate according to claim 11, wherein Before obtaining the first accuracy of the first validation model, the second accuracy of the second validation model, and the third accuracy of the third validation model, the method further includes: The first verification model is tested by using test sample fusion features, and the first accuracy of the first verification model is determined based on the test results. The second verification model is tested by expanding the features of the test samples, and the second accuracy of the second verification model is determined based on the test results. The third verification model is tested using the anti-counterfeiting recognition results of the test samples, and the third accuracy of the third verification model is determined based on the test results.
13. An apparatus for identifying the authenticity of a certificate, characterized in that, include: The anti-counterfeiting recognition result acquisition module is used to acquire the anti-counterfeiting recognition results obtained by the anti-counterfeiting recognition model through anti-counterfeiting recognition processing on multiple document images of the target document; The feature mining module is used to perform feature mining on the anti-counterfeiting recognition results of the multiple document images to obtain extended features; The verification module is used to fuse the anti-counterfeiting recognition result with the extended features to obtain fused features, and to generate multiple feature combinations based on the anti-counterfeiting recognition result, the extended features, and the fused features. Each feature combination is then verified using a verification model corresponding to that feature combination to obtain a verification result for each feature combination. The verification result is the probability value that the target document is genuine. The document authenticity determination module is used to calculate the weighted average of the verification results corresponding to each feature combination based on the accuracy of each verification model, and determine the authenticity of the target document by the relationship between the weighted average and a preset threshold.
14. A computer-readable medium having a computer program stored thereon, which, when executed by a processor, implements the document authenticity identification method according to any one of claims 1 to 12.
15. An electronic device, characterized in that, include: processor; as well as Memory for storing the executable instructions of the processor; The processor is configured to execute the document authenticity verification method according to any one of claims 1 to 12 by executing the executable instructions.
16. A computer program product, characterized in that, The computer program product includes computer instructions, which are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and executes the computer instructions to cause the computer device to perform the document authenticity verification method as described in any one of claims 1 to 12.