Defect detection method and system for banknote printing plate, electronic device and storage medium
Patent Information
- Application Number
- CN202611139791.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-29
- Publication Date
- 2026-10-09
AI Technical Summary
[0002]相关技术中,印版质量检测算法主要通过模板对比的方式进行缺陷检测,底层逻辑主要是将模板灰度图与扫描图像灰度图进行对比,然后根据预设阈值确定缺陷,但是在相关技术中,容易出现大量的缺陷漏报、误报的情况
[0029]在得到第三缺陷数据及类别后,第四确定模块还将第三缺陷数据及类别输入至分级模型中,得到钞券印版的缺陷等级,其中,分级模型能够根据第三缺陷数据及类别确定出钞券印版的缺陷等级,示例性地,缺陷等级可以分为需要进行处理和不需要进行处理两个等级。其中,第一缺陷数据及类别和第二缺陷数据及类别中所包含的缺陷数量可以为一个,也可以为多个。在得到钞券印版的缺陷等级和第三缺陷数据及类别之后,第一匹配模块将钞券印版的缺陷等级和第三缺陷数据及类别进行交叉验证,从而得到验证结果,也就是确定第三缺陷数据及类别所属的缺陷等级是否与钞券印版的缺陷等级相同。若第三缺陷数据及类别所属的缺陷等级与钞券印版的缺陷等级相同,则说明分级模型没有问题,不存在误报信息,因此直接将钞券印版的缺陷等级作为目标缺陷的缺陷等级,其中,目标缺陷的数量可以为一个或多个。若第三缺陷数据及类别所属的缺陷等级与钞券印版的缺陷等级不相同,则说明分级模型存在错误,因此第二处理模块需要将第三缺陷数据及类别所属的缺陷等级作为目标缺陷的缺陷等级。本发明首先将钞券印版的图像信息分别采用不同的方法确定钞券印版的缺陷,然后对两种方法得到的缺陷之间的并集进行处理,从而保证了识别出的缺陷的全面性,避免了漏报问题的出现。利用分类模型确定钞券印版中存在的缺陷等级,然后将之前得到缺陷与缺陷等级进行交叉验证,得到目标缺陷,从而避免了出现误报信息的情况。
Smart Images

Figure CN122887872A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of printing plate quality inspection technology, and more specifically, to a method and system for detecting defects in banknote printing plates, an electronic device, and a storage medium. Background Technology
[0002] In related technologies, printing plate quality inspection algorithms mainly detect defects by comparing templates. The underlying logic is to compare the grayscale image of the template with the grayscale image of the scanned image, and then determine the defects based on a preset threshold. However, in related technologies, a large number of defects are easily missed or falsely reported. Summary of the Invention
[0003] The present invention aims to solve at least one of the technical problems existing in the prior art or related art.
[0004] Therefore, the first aspect of the present invention proposes a method for detecting defects in banknote printing plates.
[0005] A second aspect of the present invention provides a defect detection system for banknote printing plates.
[0006] A third aspect of the present invention provides an electronic device.
[0007] A fourth aspect of the present invention provides a storage medium.
[0008] In view of this, according to a first aspect of the present invention, a defect detection method for banknote printing plates is proposed, comprising: acquiring original image information of the banknote printing plate; determining template image information based on the banknote printing plate; determining first defect data and category based on the original image information and the template image information; determining second defect data and category based on the original image information and a classification model; combining the first defect data and category and the second defect data and category to obtain third defect data and category; determining the defect level of the banknote printing plate based on the third defect data and category and a classification model; cross-validating the defect level of the banknote printing plate and the third defect data and category to obtain a verification result; and determining the category and defect level of the target defect based on the defect level of the third defect data and category when the verification result indicates that the defect level of the third defect data and category is different from the defect level of the banknote printing plate.
[0009] The defect detection method for banknote printing plates provided by this invention mainly includes: firstly, acquiring the original image information of the banknote printing plate; exemplarily, a two-dimensional camera can be used to acquire the original image information of the banknote printing plate. Then, determining template image information based on the banknote printing plate, wherein the template image information refers to the image information of a banknote printing plate without any defects. Next, comparing the original image information and the template image information to obtain first defect data and categories. Simultaneously, inputting the original image information into a classification model to obtain second defect data and categories, wherein the classification model can determine the defects existing in the banknote printing plate and the defect type to which each defect belongs based on the image information of the banknote printing plate. After obtaining the first defect data and category and the second defect data and category respectively, the first defect data and category and the second defect data and category are merged and combined to obtain the third defect data and category. It can be understood that the first defect data and category and the second defect data and category are both obtained directly from the original image information, but the technical means used are different. Therefore, the first defect data and category and the second defect data and category may be the same or may have some differences. Obtaining the third defect data and category based on the first defect data and category and the second defect data and category is to take the union of the first defect data and category and the second defect data and category as the third defect data and category, thereby ensuring the comprehensiveness of the defects.
[0010] Subsequently, after obtaining the third defect data and category, the third defect data and category are input into the grading model to obtain the defect level of the banknote printing plate. The grading model can determine the defect level of the banknote printing plate based on the image information of the banknote printing plate. For example, the defect level can be divided into two levels: those requiring processing and those not requiring processing. The number of defects contained in the first and second defect data and categories can be one or more. After obtaining the defect level and the third defect data and category of the banknote printing plate, the defect level and the third defect data and category are cross-validated to obtain the validation result, that is, to determine whether the defect level of the third defect data and category is the same as the defect level of the banknote printing plate. If the defect level of the third defect data and category is the same as the defect level of the banknote printing plate, it indicates that the grading model is correct and there is no false alarm. Therefore, the defect level of the banknote printing plate is directly used as the defect level of the target defect. The number of target defects can be one or more. If the defect level of the third defect data and its category is different from the defect level of the banknote printing plate, it indicates an error in the classification model. Therefore, the defect level of the third defect data and its category should be used as the defect level of the target defect. This invention first uses different methods to determine the defects of the banknote printing plate using image information. Then, it processes the union of defects obtained from the two methods to ensure the comprehensiveness of the identified defects and avoid missed detections. Subsequently, a classification model is used to determine the defects present in the banknote printing plate. Then, the previously obtained defects and defect levels are cross-validated to obtain the category and defect level of the target defect, thus avoiding false alarms.
[0011] In some technical solutions, optionally, the step of determining the first defect data and category based on the original image information and the template image information includes: determining a first grayscale image based on the original image information; determining a template grayscale image based on the template image information; comparing the first grayscale image and the template grayscale image to obtain a comparison result; and determining the first defect data and category based on the comparison result and a preset threshold.
[0012] In this technical solution, the steps of determining the first defect data and category based on the original image information and template image information include: firstly, scanning the original image information to obtain a first grayscale image; then, determining the template grayscale image corresponding to the template image information; subsequently, comparing the first grayscale image with the template grayscale image to determine the difference degree corresponding to each feature; and then comparing each difference degree with a corresponding preset threshold. When the difference degree is greater than the preset threshold, it indicates that the feature corresponding to the difference degree has a defect. Finally, the defects of multiple features are combined to obtain the first defect data and category. By comparing the grayscale images of the original image information and the template image information, the comprehensiveness of the first defect data and category is ensured.
[0013] In some technical solutions, optionally, the step of cross-validating the defect level of the banknote printing plate with the third defect data and category to obtain the verification result includes: obtaining a first data table, wherein the first data table includes all defect categories and the defect level to which each defect category belongs; determining the defect level to which the third defect data and category belongs based on the third defect data and category and the first data table; verifying the defect level to which the third defect data and category belongs with the defect level of the banknote printing plate to determine the verification result.
[0014] In this technical solution, the step of cross-validating the defect levels of banknote printing plates with third-party defect data and categories to obtain the verification result includes: firstly, obtaining a first data table, which includes all possible defect categories of banknote printing plates and the defect level of each defect category. After obtaining the first data table, comparing the third-party defect data and categories with the first data table to determine the defect level of the third-party defect data and categories, and then matching the defect level of the third-party defect data and categories with the defect level of the banknote printing plates to obtain the final verification result. By using the data table to determine the defect level of the defect category, the accuracy of the final matching is ensured.
[0015] In some technical solutions, optionally, before determining the second defect data and category based on the original image information and classification model, the defect detection method for banknote printing plates further includes: acquiring defect sample images of multiple banknote printing plates; constructing a defect category library based on the multiple defect sample images; determining the fourth defect category corresponding to each defect sample image in the defect category library; labeling the defect sample images in the defect category library according to the fourth defect category to obtain first text data; and training the first data model based on the multiple defect sample images in the defect category library and the first text data corresponding to each defect sample image to obtain a classification model.
[0016] In this technical solution, before determining the second defect data and category based on the original image information and classification model, the defect detection method for banknote printing plates further includes: firstly, acquiring multiple defect sample images of banknote printing plates; then, constructing a defect category library based on the multiple defect sample images; simultaneously, after obtaining the defect sample images, determining the fourth defect category corresponding to each defect sample image; and then, labeling the defect sample images in the defect category library according to the fourth defect category to obtain the first text data. In other words, after obtaining the defect sample images, it is also necessary to describe the defects present in the defect sample images using text and generate corresponding first text data. Then, the defect sample images and the first text data are associated and stored in the defect category library, so that the defect category library contains both text data and image data. After obtaining the defect category library, a first data model is trained based on multiple defect sample images and the corresponding first text data in the defect category library to obtain a classification model. The first data model can be a general-purpose deep learning model. During training, the defect category library is divided into a training set database, a test set database, and a validation set database. These databases are then used to train the deep learning model and its parameters, ultimately yielding the final classification model. This invention provides more specific feature information about defect samples through a multimodal data structure, accurately identifying edge and peeling defect features, thus solving the problem of missed detections caused by filtering algorithms in related technologies. Simultaneously, it utilizes a general-purpose deep learning model to identify typical defect features without relying on template information, thereby addressing the problems of weak generalization ability and low efficiency in related technologies.
[0017] In some technical solutions, optionally, before determining the defect level of the banknote printing plate based on the third defect data and the category and grading model, the banknote printing plate defect detection method further includes: determining the first defect level corresponding to each defect sample image in the defect category library; labeling the defect sample images in the defect category library according to the first defect level to obtain second text data; and training the second data model based on multiple defect sample images in the defect category library and the second text data corresponding to each defect sample image to obtain a grading model.
[0018] In this technical solution, before determining the defect level of the banknote printing plate based on the third defect data and the category and grading model, the defect detection method for banknote printing plates further includes: after obtaining the defect category library, it is also necessary to determine the defects present in each defect sample image and the first defect level to which each defect belongs. Then, the defect sample images are labeled in the defect category library according to the first defect level, thereby obtaining the second text data. That is, for each defect present in the defect sample image, its defect level needs to be labeled with text, and then the text data is combined with the defect sample image and placed into the defect category library. In other words, the defect category library includes multiple defect sample images and corresponding text data, where the text data includes the defects present in the defect sample image and the defect level to which each defect belongs; that is, the text data includes the first text data and the second text data. Finally, a second data model is trained based on multiple defect sample images from the defect category library and the corresponding second text data for each defect sample image to obtain a hierarchical model. This second data model can be a general-purpose deep learning model. During training, the defect category library is divided into a training set database, a test set database, and a validation set database. These databases are then used to train the deep learning model and its parameters, ultimately yielding the final hierarchical model. This invention provides more specific feature information about defect samples through a multimodal data structure, accurately identifying edge and peeling defect features, thus solving the problem of missed detections caused by filtering algorithms in related technologies. Simultaneously, it utilizes a general-purpose deep learning model to identify typical defect features without relying on template information, thereby addressing the problems of weak generalization ability and low efficiency in related technologies.
[0019] In some technical solutions, optionally, before the step of determining the second defect data and category based on the original image information and classification model, the defect detection method for banknote printing plates may further include: determining a preset detection time; and determining the computing power allocation parameters of the classification model and the grading model based on the preset detection time.
[0020] In this technical solution, before determining the second defect data and category based on the original image information and classification model, the defect detection method for banknote printing plates further includes: firstly, determining a preset detection time; then, adjusting the classification model and grading model according to the preset detection time, and determining the computing power allocation parameters for the classification model and the grading model. It is understood that in this invention, the classification model and grading model operate simultaneously, and both computing power and detection time are limited during operation. Therefore, it is necessary to adjust the computing power allocation parameters of the classification model and grading model according to the preset detection time, thereby ensuring both the accuracy of the detection by the classification model and the grading model and completing the detection of the banknote printing plate within the preset detection time.
[0021] In some technical solutions, the computing power allocation parameters may optionally include at least one of the following: the total number of threads in the hierarchical model, the total number of threads in the classification model, the execution strategy parameters of the hierarchical model, the execution strategy parameters of the classification model, and the resource allocation ratio between the graphics processors of the classification model and the graphics processors of the hierarchical model.
[0022] In this technical solution, the computing power allocation parameters include: the total number of threads in the hierarchical model, the total number of threads in the classification model, the execution strategy parameters of the hierarchical model, the execution strategy parameters of the classification model, and the resource allocation ratio between the graphics processing units (GPUs) of the classification model and the graphics processing units of the hierarchical model. By repeatedly debugging the computing power allocation parameters during deployment, such as the total number of threads, the GPU resource allocation ratio between the hierarchical and classification models, and the execution strategy parameters, when deploying the classification model and the hierarchical model to the printing plate inspection equipment, the printing plate inspection equipment can meet the quality requirements.
[0023] In some technical solutions, optionally, after determining the category and defect level of the target defect based on the third defect data and category, the defect detection method for banknote printing plates further includes: displaying the category and defect level of the target defect.
[0024] In this technical solution, after determining the category and defect level of the target defect based on the third defect data and category, the solution further includes displaying the category and defect level of the target defect. That is, after obtaining the category and defect level of the target defect, the category and defect level are displayed to the user so that the user can verify the detection results.
[0025] In some technical solutions, the banknote printing plate may optionally include: intaglio printing and / or offset printing plate.
[0026] In this technical solution, the banknote printing plates include: intaglio printing plates and / or offset printing plates. This invention can inspect both intaglio and offset printing plates, thus eliminating the need to create separate templates for different printing types and formats, thereby improving inspection efficiency.
[0027] According to a second aspect of the present invention, a defect detection system for banknote printing plates is proposed, mainly comprising: a first acquisition module for acquiring original image information of the banknote printing plate; a first determination module for determining template image information based on the banknote printing plate; a second determination module for determining first defect data and category based on the original image information and the template image information; a third determination module for determining second defect data and category based on the original image information and a classification model; a first processing module for combining the first defect data and category and the second defect data and category to obtain third defect data and category; a fourth determination module for determining the defect level of the banknote printing plate based on the third defect data and category and a classification model; a first matching module for cross-validating the defect level of the banknote printing plate and the third defect data and category to obtain a verification result; and a second processing module for determining the category and defect level of a target defect based on the defect level of the third defect data and category when the verification result indicates that the defect level of the third defect data and category is different from the defect level of the banknote printing plate.
[0028] The banknote printing plate defect detection system provided by this invention mainly includes: a first acquisition module, a first determination module, a second determination module, a third determination module, a first processing module, a fourth determination module, a first matching module, and a second processing module. The first acquisition module acquires the original image information of the banknote printing plate; exemplarily, a two-dimensional camera can be used to acquire the original image information of the banknote printing plate. Then, the first determination module determines template image information based on the banknote printing plate, where the template image information refers to the image information of the banknote printing plate without any defects. The second determination module then compares the original image information and the template image information to obtain first defect data and categories. Simultaneously, the third determination module inputs the original image information into a classification model to obtain second defect data and categories. The classification model can determine the defects present in the banknote printing plate and the defect type to which each defect belongs based on the image information of the banknote printing plate. After obtaining the first defect data and category and the second defect data and category respectively, the first processing module merges and combines the first defect data and category and the second defect data and category to obtain the third defect data and category. It can be understood that the first defect data and category and the second defect data and category are both obtained directly from the original image information, but the technical means used are different. Therefore, the first defect data and category and the second defect data and category may be the same or may have some differences. Obtaining the third defect data and category based on the first defect data and category and the second defect data and category is to take the union of the first defect data and category and the second defect data and category as the third defect data and category, thereby ensuring the comprehensiveness of the defects.
[0029] After obtaining the third defect data and category, the fourth determining module inputs the third defect data and category into the grading model to obtain the defect level of the banknote printing plate. The grading model can determine the defect level of the banknote printing plate based on the third defect data and category. For example, the defect level can be divided into two levels: those requiring processing and those not requiring processing. The number of defects contained in the first and second defect data and categories can be one or more. After obtaining the defect level and the third defect data and category of the banknote printing plate, the first matching module cross-validates the defect level and the third defect data and category to obtain a verification result, that is, to determine whether the defect level of the third defect data and category is the same as the defect level of the banknote printing plate. If the defect level of the third defect data and category is the same as the defect level of the banknote printing plate, it indicates that the grading model is correct and there is no false alarm. Therefore, the defect level of the banknote printing plate is directly used as the defect level of the target defect. The number of target defects can be one or more. If the defect level of the third defect data and category is different from the defect level of the banknote printing plate, it indicates an error in the classification model. Therefore, the second processing module needs to use the defect level of the third defect data and category as the defect level of the target defect. This invention first uses different methods to determine the defects of the banknote printing plate using image information, and then processes the union of defects obtained from the two methods to ensure the comprehensiveness of the identified defects and avoid missed detections. The classification model is used to determine the defect levels present in the banknote printing plate, and then the previously obtained defects and defect levels are cross-validated to obtain the target defect, thus avoiding false alarms.
[0030] In some technical solutions, optionally, the second determining module is specifically used for: determining a first grayscale image based on the original image information; determining a template grayscale image based on the template image information; comparing the first grayscale image and the template grayscale image to obtain a comparison result; and determining the first defect data and category based on the comparison result and a preset threshold.
[0031] In this technical solution, the second determining module is specifically used to first scan the original image information to obtain a first grayscale image, then determine the template grayscale image corresponding to the template image information, and then compare the first grayscale image with the template grayscale image to determine the difference degree corresponding to each feature. Each difference degree is then compared with a corresponding preset threshold. When the difference degree is greater than the preset threshold, it indicates that the feature corresponding to the difference degree has a defect. Finally, the defects of multiple features are combined to obtain the first defect data and category. By comparing the grayscale images of the original image information and the template image information, the comprehensiveness of the first defect data and category is ensured.
[0032] In some technical solutions, optionally, the first matching module is specifically used to: obtain a first data table, wherein the first data table includes all defect categories and the defect level to which each defect category belongs; determine the defect level to which the third defect data and category belong based on the third defect data and category and the first data table; verify the defect level to which the third defect data and category belong and the defect level of the banknote printing plate, and determine the verification result.
[0033] In this technical solution, the first matching module is specifically used to first obtain a first data table, which includes all possible defect categories of banknote printing plates and the defect level of each defect category. After obtaining the first data table, the third defect data and category are compared with the first data table to determine the defect level of the third defect data and category. Subsequently, the defect level of the third defect data and category is matched with the defect level of the banknote printing plate to obtain the final verification result. By using the data table to determine the defect level of the defect category, the accuracy of the final matching is ensured.
[0034] According to a third aspect of the present invention, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the banknote printing plate defect detection method as described above.
[0035] The electronic device provided by this invention, when the processor executes the computer program, implements the steps of the above-mentioned defect detection method for banknote printing plates, and can achieve the technical effects of any of the above technical solutions, which will not be elaborated here.
[0036] According to a fourth aspect of the present invention, a storage medium is provided on which a computer program is stored, wherein when the computer program is executed by a processor, the steps of the banknote printing plate defect detection method as described in any of the above claims are implemented.
[0037] The storage medium provided by this invention, when the computer program is executed by the processor, implements the steps of the above-mentioned defect detection method for banknote printing plates, and can achieve the technical effects of any of the above technical solutions, which will not be elaborated here.
[0038] Additional aspects and advantages of the invention will become apparent in the following description or may be learned by practice of the invention. Attached Figure Description
[0039] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which:
[0040] Figure 1A flowchart illustrating one embodiment of the defect detection method for banknote printing plates according to the present invention is shown.
[0041] Figure 2 The diagram illustrates a step in a banknote printing plate defect detection method according to an embodiment of the present invention, which involves determining the first defect data and category based on the original image information and the template image information.
[0042] Figure 3 This diagram illustrates a step in a banknote printing plate defect detection method according to an embodiment of the present invention, which involves cross-validating the defect level of the banknote printing plate with third defect data and category to obtain a verification result.
[0043] Figure 4 A second schematic flowchart of a defect detection method for banknote printing plates according to an embodiment of the present invention is shown.
[0044] Figure 5 The third flowchart illustrates a defect detection method for banknote printing plates according to an embodiment of the present invention.
[0045] Figure 6 This diagram illustrates a flowchart of a banknote printing plate defect detection method according to an embodiment of the present invention, prior to the step of determining the second defect data and category based on the original image information and a classification model.
[0046] Figure 7 The fourth flowchart illustrates a method for detecting defects in banknote printing plates according to an embodiment of the present invention.
[0047] Figure 8 A schematic diagram of a multimodal feature fusion network architecture in a banknote printing plate defect detection method according to an embodiment of the present invention is shown.
[0048] Figure 9 One of the schematic block diagrams of a defect detection system for banknote printing plates according to an embodiment of the present invention is shown;
[0049] Figure 10 A second schematic block diagram of a defect detection system for banknote printing plates according to an embodiment of the present invention is shown.
[0050] Figure 11 The third schematic block diagram shows a defect detection system for banknote printing plates according to an embodiment of the present invention;
[0051] Figure 12 A schematic block diagram of an electronic device according to an embodiment of the present invention is shown. Detailed Implementation
[0052] To better understand the above-mentioned objectives, features, and advantages of the present invention, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, unless otherwise specified, the embodiments of the present invention and the features thereof can be combined with each other.
[0053] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and therefore the scope of protection of the invention is not limited to the specific embodiments disclosed below.
[0054] Figure 1 This diagram illustrates one embodiment of a defect detection method for banknote printing plates according to the present invention. The defect detection method for banknote printing plates includes:
[0055] Step 102: Obtain the original image information of the banknote printing plate;
[0056] Step 104: Determine the template image information based on the banknote printing plate;
[0057] Step 106: Determine the first defect data and category based on the original image information and template image information;
[0058] Step 108: Determine the second defect data and category based on the original image information and classification model;
[0059] Step 110: Combine the first defect data and category with the second defect data and category to obtain the third defect data and category;
[0060] Step 112: Determine the defect level of the banknote printing plate based on the third defect data and the category and grading model;
[0061] Step 114: Cross-validate the defect level and third defect data and category of the banknote printing plate to obtain the verification results;
[0062] Step 116: If the verification result shows that the defect level of the third defect data and category is different from the defect level of the banknote printing plate, determine the category and defect level of the target defect according to the defect level of the third defect data and category.
[0063] The defect detection method for banknote printing plates provided by this invention mainly includes: firstly, acquiring the original image information of the banknote printing plate; exemplarily, a two-dimensional camera can be used to acquire the original image information of the banknote printing plate. Then, determining template image information based on the banknote printing plate, wherein the template image information refers to the image information of a banknote printing plate without any defects. Next, comparing the original image information and the template image information to obtain first defect data and categories. Simultaneously, inputting the original image information into a classification model to obtain second defect data and categories, wherein the classification model can determine the defects existing in the banknote printing plate and the defect type to which each defect belongs based on the image information of the banknote printing plate. After obtaining the first defect data and category and the second defect data and category respectively, the first defect data and category and the second defect data and category are merged and combined to obtain the third defect data and category. It can be understood that the first defect data and category and the second defect data and category are both obtained directly from the original image information, but the technical means used are different. Therefore, the first defect data and category and the second defect data and category may be the same or may have some differences. Obtaining the third defect data and category based on the first defect data and category and the second defect data and category is to take the union of the first defect data and category and the second defect data and category as the third defect data and category, thereby ensuring the comprehensiveness of the defects.
[0064] After obtaining the third defect data and category, the third defect data and category are input into the grading model to obtain the defect level of the banknote printing plate. The grading model can determine the defect level of the banknote printing plate based on its image information. For example, the defect level can be divided into two levels: those requiring processing and those not requiring processing. The first and second defect data and categories can contain one or more defects. Defect data and categories refer to the defect data and the category to which each defect data belongs. After obtaining the defect level and the third defect data and category of the banknote printing plate, the defect level and the third defect data and category are cross-validated to obtain the validation result, that is, to determine whether the defect level of the third defect data and category is the same as the defect level of the banknote printing plate. If the defect level of the third defect data and category is the same as the defect level of the banknote printing plate, it indicates that the grading model is correct and there is no false alarm. Therefore, the defect level of the banknote printing plate is directly used as the defect level of the target defect. The number of target defects can be one or more. If the defect level of the third defect data and its category is different from the defect level of the banknote printing plate, it indicates an error in the classification model. Therefore, the defect level of the third defect data and its category should be used as the defect level of the target defect. This invention first uses different methods to determine the defects of the banknote printing plate using image information. Then, it processes the union of defects obtained from the two methods to ensure the comprehensiveness of the identified defects and avoid missed detections. The classification model is used to determine the defect levels present in the banknote printing plate, and then the previously obtained defects and defect levels are cross-validated to obtain the target defect, thus avoiding false alarms.
[0065] Figure 2 The diagram illustrates a flowchart of a defect detection method for banknote printing plates according to an embodiment of the present invention, specifically the step of determining first defect data and category based on original image information and template image information; wherein, the step of determining the first defect data and category based on original image information and template image information includes:
[0066] Step 202: Determine the first grayscale image based on the original image information;
[0067] Step 204: Determine the template grayscale image based on the template image information;
[0068] Step 206: Compare the first grayscale image and the template grayscale image to obtain the comparison result;
[0069] Step 208: Determine the first defect data and category based on the comparison results and preset thresholds.
[0070] In this embodiment, the step of determining the first defect data and category based on the original image information and the template image information includes: firstly, scanning the original image information to obtain a first grayscale image; then, determining the template grayscale image corresponding to the template image information; subsequently, comparing the first grayscale image with the template grayscale image to determine the difference degree corresponding to each feature; and then comparing each difference degree with a corresponding preset threshold. When the difference degree is greater than the preset threshold, it indicates that the feature corresponding to the difference degree has a defect. Finally, the defects of multiple features are combined to obtain the first defect data and category. By comparing the grayscale images of the original image information and the template image information, the comprehensiveness of the first defect data and category is ensured.
[0071] Figure 3 This diagram illustrates a step in a banknote printing plate defect detection method according to an embodiment of the present invention: cross-validating the defect level and third defect data and category of the banknote printing plate to obtain a verification result. The step of cross-validating the defect level and third defect data and category of the banknote printing plate to obtain a verification result includes:
[0072] Step 302: Obtain the first data table, which includes all defect categories and the defect level of each defect category;
[0073] Step 304: Determine the defect level to which the third defect data and category belong based on the third defect data and category and the first data table;
[0074] Step 306: Verify the defect level of the third defect data and category and the defect level of the banknote printing plate to determine the verification result.
[0075] In this embodiment, the step of cross-validating the defect levels of banknote printing plates with third defect data and categories to obtain the verification result includes: firstly, obtaining a first data table, which includes all possible defect categories of banknote printing plates and the defect level of each defect category. After obtaining the first data table, comparing the third defect data and categories with the first data table to determine the defect level of the third defect data and categories, and then matching the defect level of the third defect data and categories with the defect levels to obtain the final verification result. By using the data table to determine the defect level of the defect category, the accuracy of the final matching is ensured.
[0076] Figure 4 This is a second schematic flowchart illustrating a defect detection method for banknote printing plates according to an embodiment of the present invention. Prior to the step of determining the second defect data and category based on the original image information and classification model, the defect detection method for banknote printing plates further includes:
[0077] Step 402: Collect defect sample images of multiple banknote printing plates;
[0078] Step 404: Construct a defect category library based on multiple defect sample images;
[0079] Step 406: Determine the fourth defect category corresponding to each defect sample image in the defect category library;
[0080] Step 408: Label the defect sample images in the defect category library according to the fourth defect category to obtain the first text data;
[0081] Step 410: Train the first data model based on multiple defect sample images in the defect category library and the first text data corresponding to each defect sample image to obtain a classification model.
[0082] In this embodiment, before determining the second defect data and category based on the original image information and classification model, the defect detection method for banknote printing plates further includes: firstly, acquiring multiple defect sample images of banknote printing plates; then, constructing a defect category library based on the multiple defect sample images; simultaneously, after obtaining the defect sample images, determining the fourth defect category corresponding to each defect sample image; and then, labeling the defect sample images in the defect category library according to the fourth defect category to obtain the first text data. In other words, after obtaining the defect sample images, it is necessary to describe the defects present in the defect sample images using text and generate corresponding first text data. Then, the defect sample images and the first text data are associated and stored in the defect category library, so that the defect category library contains both text data and image data. After obtaining the defect category library, a first data model is trained based on multiple defect sample images and the corresponding first text data in the defect category library to obtain a classification model. The first data model can be a general-purpose deep learning model. During training, the defect category library is divided into a training set database, a test set database, and a validation set database. These databases are then used to train the deep learning model and its parameters, ultimately yielding the final classification model. This invention provides more specific feature information about defect samples through a multimodal data structure, accurately identifying edge and peeling defect features, thus solving the problem of missed detections caused by filtering algorithms in related technologies. Simultaneously, it utilizes a general-purpose deep learning model to identify typical defect features without relying on template information, thereby addressing the problems of weak generalization ability and low efficiency in related technologies.
[0083] Figure 5The third schematic flowchart illustrates a defect detection method for banknote printing plates according to an embodiment of the present invention. Prior to the step of determining the defect level of the banknote printing plate based on third defect data and a category and grading model, the defect detection method for banknote printing plates further includes:
[0084] Step 502: Determine the first defect level corresponding to each defect sample image in the defect category library;
[0085] Step 504: Label the defect sample images in the defect category library according to the first defect level to obtain the second text data;
[0086] Step 506: Train the second data model based on multiple defect sample images in the defect category library and the second text data corresponding to each defect sample image to obtain the hierarchical model.
[0087] In this embodiment, before determining the defect level of the banknote printing plate based on the third defect data and the category and grading model, the defect detection method for the banknote printing plate further includes: after obtaining the defect category library, it is also necessary to determine the defects present in each defect sample image and the first defect level to which each defect belongs. Then, the defect sample images are labeled in the defect category library according to the first defect level to obtain the second text data. That is, for each defect present in the defect sample image, its defect level needs to be labeled with text, and then the text data is combined with the defect sample image and placed into the defect category library. In other words, the defect category library includes multiple defect sample images and text data corresponding to the defect sample images. The text data includes the defects present in the defect sample images and the defect level to which each defect belongs, i.e., the text data includes the first text data and the second text data. Finally, a second data model is trained based on multiple defect sample images from the defect category library and the corresponding second text data for each defect sample image to obtain a hierarchical model. This second data model can be a general-purpose deep learning model. During training, the defect category library is divided into a training set database, a test set database, and a validation set database. These databases are then used to train the deep learning model and its parameters, ultimately yielding the final hierarchical model. This invention provides more specific feature information about defect samples through a multimodal data structure, accurately identifying edge and peeling defect features, thus solving the problem of missed detections caused by filtering algorithms in related technologies. Simultaneously, it utilizes a general-purpose deep learning model to identify typical defect features without relying on template information, thereby addressing the problems of weak generalization ability and low efficiency in related technologies.
[0088] Figure 6The diagram illustrates a flowchart of a banknote printing plate defect detection method according to an embodiment of the present invention, prior to the step of determining second defect data and category using original image information and a classification model; wherein, prior to the step of determining second defect data and category using original image information and a classification model, the banknote printing plate defect detection method further includes:
[0089] Step 602: Determine the preset detection time;
[0090] Step 604: Determine the computing power allocation parameters for the classification model and the hierarchical model based on the preset detection time.
[0091] In this embodiment, before determining the second defect data and category based on the original image information and the classification model, the defect detection method for banknote printing plates further includes: firstly, determining a preset detection time, and then debugging the classification model and the grading model according to the preset detection time, and determining the computing power allocation parameters of the classification model and the grading model. It is understood that in this invention, the classification model and the grading model operate simultaneously, and both computing power and detection time are limited during operation. Therefore, it is necessary to adjust the computing power allocation parameters of the classification model and the grading model according to the preset detection time, so as to ensure both the accuracy of the detection by the classification model and the grading model and to complete the detection of the banknote printing plate within the preset detection time.
[0092] In some embodiments, the computing power allocation parameters may optionally include at least one of the following: the total number of threads in the hierarchical model, the total number of threads in the classification model, the execution strategy parameters of the hierarchical model, the execution strategy parameters of the classification model, and the resource allocation ratio between the graphics processors of the classification model and the graphics processors of the hierarchical model.
[0093] In this embodiment, the computing power allocation parameters include: the total number of threads in the hierarchical model, the total number of threads in the classification model, the execution strategy parameters of the hierarchical model, the execution strategy parameters of the classification model, and the resource allocation ratio between the graphics processing unit (GPU) of the classification model and the GPU of the hierarchical model. By repeatedly debugging the computing power allocation parameters during deployment, such as the total number of threads, the GPU resource allocation ratio between the hierarchical and classification models, and the execution strategy parameters, when deploying the classification model and the hierarchical model to the printing plate inspection equipment, the printing plate inspection equipment can meet the quality requirements.
[0094] In some embodiments, optionally, after determining the category and defect level of the target defect based on the third defect data and category, the defect detection method for banknote printing plates further includes displaying the category and defect level of the target defect.
[0095] In this embodiment, after determining the category and level of the target defect based on the third defect data and category, the defect detection method for banknote printing plates further includes displaying the category and level of the target defect. That is, after obtaining the category and level of the target defect, the category and level of the target defect are displayed to the user so that the user can verify the detection results.
[0096] In some embodiments, the banknote printing plate may optionally include: intaglio and / or offset printing plate.
[0097] In this embodiment, the banknote printing plate includes: intaglio printing and / or offset printing plate. This invention can inspect both intaglio and offset printing plates, thus eliminating the need to create different templates for different printing types and formats, thereby improving inspection efficiency.
[0098] Figure 7 The fourth schematic flowchart illustrates a defect detection method for banknote printing plates according to an embodiment of the present invention; the defect detection method for banknote printing plates includes:
[0099] Step 702: The 2D camera acquires data;
[0100] Step 704: Build the template;
[0101] Step 706: Template matching;
[0102] Step 708: Calculation using traditional algorithm;
[0103] Step 710: Build a defect database;
[0104] Step 712: Defect classification data annotation;
[0105] Step 714: Deep learning classification model;
[0106] Step 716: Detect defect data and take the union;
[0107] Step 718: Determine if there is a missed detection; if the result is yes, proceed to step 712; if the result is no, proceed to step 722.
[0108] Step 720: Defect classification data annotation;
[0109] Step 722: Deep learning hierarchical model;
[0110] Step 724: Hierarchical and categorical cross-validation;
[0111] Step 726: Determine if there is a classification error; if the result is yes, proceed to step 720; if the result is no, proceed to step 728.
[0112] Step 728: Visualize the search interface.
[0113] In this embodiment, firstly, defect sample images are acquired using a 2D camera. Then, defect category libraries for gravure and offset printing plates are constructed, and classification, grading, and labeling operations are performed on the defect categories. Training, testing, and validation set databases for classification and grading of gravure and offset printing plates are constructed respectively. Then, deep learning models for classification and grading of gravure and offset printing plates, along with their related parameters, are trained using the constructed training set database. The trained classification and grading models are deployed to the machine inspection equipment for finished gravure and offset printing plates, and the computing power allocation parameters (total number of threads, GPU resource allocation ratio for grading and classification models, execution strategy parameters, etc.) during deployment are repeatedly debugged. After acquiring defect sample images using a 2D camera, a template needs to be constructed. Then, the template image is matched with the defect sample image, and a traditional algorithm is used to output the defect category. The traditional algorithm compares the template image with the defect sample image, then compares the difference obtained after the comparison with a preset threshold. When the difference is greater than the preset threshold, the defect category corresponding to the difference is output. Simultaneously, the defect sample image is input into the previously trained classification model to obtain the defect category. Then, the union of the defect categories from the two methods is obtained, and the unioned defect categories are checked to determine if any were missed. If any were missed, the classification model is retrained. If no were missed, the unioned defect categories are input into the trained grading model for grading and classification cross-validation. If the defect grading is incorrect, i.e., the output of the grading model does not match the unioned defect categories, the grading model is retrained. If the defect grading is correct, i.e., the output of the grading model matches the unioned defect categories, the unioned defect categories are visualized.
[0114] Figure 8 This diagram illustrates a multimodal feature fusion network architecture in a banknote printing plate defect detection method according to an embodiment of the present invention. Figure 8As shown, the multimodal feature fusion network includes an image feature extraction subnetwork, a text feature extraction subnetwork, and a multimodal feature fusion subnetwork. The outputs of the image feature extraction subnetwork and the text feature extraction subnetwork are connected to the input of the multimodal feature fusion subnetwork, respectively. The input of the image feature extraction subnetwork is a 300-pixel × 300-pixel × 3-channel image of a printing plate. The image is sequentially processed through Conv4_3 (the 3rd convolutional layer of the 4th group), Conv7 (the 7th convolutional layer), and Conv8_2 (the 2nd convolutional layer of the 8th group) for multi-level feature extraction. Specifically, the Conv4_3 convolutional layer outputs a feature map with a size of 38 pixels × 38 pixels × 512 channels, the Conv7 convolutional layer outputs a feature map with a size of 19 pixels × 19 pixels × 1024 channels, and the Conv8_2 convolutional layer outputs a high-dimensional image feature map with a size of 10 pixels × 10 pixels × 512 channels. This high-dimensional image feature map is then input into the multimodal feature fusion subnetwork. The text feature extraction subnetwork takes the defect description text as input. The text data first passes through the Token Embedding layer to complete the token vectorization mapping and generate a text sequence vector. Then, the [CLS] Token (classification identifier token) is introduced to encode the text sequence and output a text feature sequence with dimensions of [sequence length, 768 dimensions]. Then, the average pooling operation is performed through the Avg Pooling layer to compress the text feature sequence into a text semantic feature vector with dimensions of (1, 768), and the text semantic feature vector is input into the multimodal feature fusion subnetwork. The multimodal feature fusion subnetwork receives high-dimensional feature maps of images and semantic feature vectors of text. First, it performs cross-modal feature fusion of images and text through Conv9_2 (the 2nd convolutional layer of the 9th group). The Conv9_2 convolutional layer outputs a fused feature map with a size of 5 pixels × 5 pixels × 526 channels. The fused feature map is then fed into a CNN (Convolutional Neural Network) to further refine the cross-modal defect features, outputting a feature map with a size of 3 pixels × 3 pixels × 256 channels. Finally, it undergoes global average pooling processing through an Avg_Pool (global average pooling layer) to obtain a final multimodal feature vector with a size of 1 pixel × 1 pixel × 256 channels. The final multimodal feature vector is output to the defect classification model and the defect grading model to complete the identification of banknote printing plate defect types and the determination of defect severity levels.
[0115] Figure 9 A schematic block diagram of a defect detection system for banknote printing plates according to an embodiment of the present invention is shown; wherein, the defect detection system 90 for banknote printing plates includes:
[0116] The first acquisition module 902 is used to acquire the original image information of the banknote printing plate;
[0117] The first determining module 904 is used to determine the template image information based on the banknote printing plate;
[0118] The second determining module 906 is used to determine the first defect data and category based on the original image information and the template image information;
[0119] The third determination module 908 is used to determine the second defect data and category based on the original image information and the classification model;
[0120] The first processing module 910 is used to combine the first defect data and category and the second defect data and category to obtain the third defect data and category;
[0121] The fourth determination module 912 is used to determine the defect level of the banknote printing plate based on the third defect data and the category and grading model;
[0122] The first matching module 914 is used to cross-validate the defect level of the banknote printing plate with the third defect data and category to obtain the verification result;
[0123] The second processing module 916 is used to determine the category and defect level of the target defect based on the defect level of the third defect data and category when the verification result shows that the defect level of the third defect data and category is different from the defect level of the banknote printing plate.
[0124] The banknote printing plate defect detection system 90 provided by this invention mainly includes: a first acquisition module 902, a first determination module 904, a second determination module 906, a third determination module 908, a first processing module 910, a fourth determination module 912, a first matching module 914, and a second processing module 916. The first acquisition module 902 can acquire the original image information of the banknote printing plate; exemplarily, a two-dimensional camera can be used to acquire the original image information of the banknote printing plate. Then, the first determination module 904 determines template image information based on the banknote printing plate, wherein the template image information refers to the image information of the banknote printing plate without any defects. Then, the second determination module 906 compares the original image information and the template image information to obtain first defect data and categories. Simultaneously, the third determination module 908 inputs the original image information into a classification model to obtain second defect data and categories, wherein the classification model can determine the defects existing in the banknote printing plate and the defect type to which each defect belongs based on the image information of the banknote printing plate. After obtaining the first defect data and category and the second defect data and category respectively, the first processing module 910 merges and combines the first defect data and category and the second defect data and category to obtain the third defect data and category. It can be understood that the first defect data and category and the second defect data and category are both obtained directly from the original image information, but the technical means used are different. Therefore, the first defect data and category and the second defect data and category may be the same or may have some differences. Obtaining the third defect data and category based on the first defect data and category and the second defect data and category is to take the union of the first defect data and category and the second defect data and category as the third defect data and category, thereby ensuring the comprehensiveness of the defects.
[0125] After obtaining the third defect data and category, the fourth determining module 912 inputs the third defect data and category into the grading model to obtain the defect level of the banknote printing plate. The grading model can determine the defect level of the banknote printing plate based on its image information. For example, the defect level can be divided into two levels: those requiring processing and those not requiring processing. The number of defects contained in the first and second defect data and categories can be one or more. After obtaining the defect level and the third defect data and category of the banknote printing plate, the first matching module 914 matches the defect level of the banknote printing plate with the third defect data and category to obtain a verification result, that is, to determine whether the defect level of the third defect data and category is the same as the defect level of the banknote printing plate. If the defect level of the third defect data and category is the same as the defect level of the banknote printing plate, it indicates that the grading model is correct and there is no false alarm. Therefore, the defect level of the banknote printing plate is directly used as the defect level of the target defect. The number of target defects can be one or more. If the defect level of the third defect data and category is different from the defect level of the banknote printing plate, it indicates an error in the classification model. Therefore, the second processing module 916 needs to use the defect level of the third defect data and category as the defect level of the target defect. This invention first uses different methods to determine the defects of the banknote printing plate using image information, and then processes the union of defects obtained from the two methods, thereby ensuring the comprehensiveness of the identified defects and avoiding missed detections. The classification model is used to determine the defect levels present in the banknote printing plate, and then the previously obtained defects and defect levels are cross-validated to obtain the target defect, thus avoiding false alarms.
[0126] In some embodiments, optionally, the second determining module 906 is specifically configured to: determine a first grayscale image based on the original image information; determine a template grayscale image based on the template image information; compare the first grayscale image and the template grayscale image to obtain a comparison result; and determine the first defect data and category based on the comparison result and a preset threshold.
[0127] In this embodiment, the second determining module 906 is specifically used to first scan the original image information to obtain a first grayscale image, then determine a template grayscale image corresponding to the template image information based on the template image information, then compare the first grayscale image with the template grayscale image to determine the difference degree corresponding to each feature, and then compare each difference degree with the corresponding preset threshold. When the difference degree is greater than the preset threshold, it indicates that the feature corresponding to the difference degree has a defect. Finally, the defects of multiple features are combined to obtain the first defect data and category. By comparing the grayscale image of the original image information with the grayscale image of the template image information, the comprehensiveness of the first defect data and category is ensured.
[0128] In some embodiments, optionally, the first matching module 914 is specifically used to obtain a first data table, wherein the first data table includes all defect categories and the defect level to which each defect category belongs; determine the defect level to which the third defect data and category belong based on the third defect data and category and the first data table; verify the defect level to which the third defect data and category belong and the defect level, and determine the verification result.
[0129] In this embodiment, the first matching module 914 is specifically used to first obtain a first data table, which includes all possible defect categories of banknote printing plates and the defect level of each defect category. After obtaining the first data table, the third defect data and category are compared with the first data table to determine the defect level of the third defect data and category. Then, the defect level of the third defect data and category is matched with the defect level to obtain the final verification result. By using the data table to determine the defect level of the defect category, the accuracy of the final matching is ensured.
[0130] Figure 10 The diagram below shows a second schematic block diagram of a defect detection system for banknote printing plates according to an embodiment of the present invention. The defect detection system 90 for banknote printing plates further includes:
[0131] The first acquisition module 918 is used to acquire defect sample images of multiple banknote printing plates;
[0132] The third processing module 920 is used to construct a defect category library based on multiple defect sample images;
[0133] The fifth determining module 922 is used to determine the fourth defect category corresponding to each defect sample image in the defect category library;
[0134] The fourth processing module 924 is used to annotate the defect sample image in the defect category library according to the fourth defect category to obtain the first text data;
[0135] The fifth processing module 926 is used to train the first data model based on multiple defect sample images in the defect category library and the first text data corresponding to each defect sample image to obtain a classification model.
[0136] In this embodiment, the banknote printing plate defect detection system 90 further includes: a first acquisition module 918, a third processing module 920, a fifth determination module 922, a fourth processing module 924, and a fifth processing module 926. The first acquisition module 918 acquires multiple defect sample images of banknote printing plates. The third processing module 920 then constructs a defect category library based on these images. Simultaneously, after obtaining the defect sample images, the fifth determination module 922 determines the fourth defect category corresponding to each image. The fourth processing module 924 then labels the defect sample images in the defect category library according to the fourth defect category, obtaining first text data. In other words, after obtaining the defect sample images, the defects present in the images need to be described using text, generating corresponding first text data. The defect sample images and the first text data are then associated and stored in the defect category library, ensuring that the defect category library contains both text and image data. After obtaining the defect category library, the fifth processing module 926 trains the first data model based on multiple defect sample images and the corresponding first text data in the defect category library to obtain a classification model. The first data model can be a general-purpose deep learning model. During training, the defect category library is divided into a training set database, a test set database, and a validation set database. The deep learning model and its parameters are then trained using these databases to obtain the final classification model. This invention provides more specific feature information about defect samples through a multimodal data structure, accurately identifying edge and peeling defect features, solving the problem of missed detections caused by filtering algorithms in related technologies. Simultaneously, it utilizes a general-purpose deep learning model to identify typical defect features without relying on template information, thus addressing the problems of weak generalization ability and low efficiency in related technologies.
[0137] Figure 11 The third schematic block diagram shows a defect detection system for banknote printing plates according to an embodiment of the present invention, wherein the defect detection system 90 for banknote printing plates further includes:
[0138] The sixth determining module 928 is used to determine the first defect level corresponding to each defect sample image in the defect category library;
[0139] The sixth processing module 930 is used to annotate the defect sample image in the defect category library according to the first defect level to obtain the second text data;
[0140] The seventh processing module 932 is used to train the second data model based on multiple defect sample images in the defect category library and the second text data corresponding to each defect sample image to obtain a hierarchical model.
[0141] In this embodiment, the banknote printing plate defect detection system 90 further includes a sixth determining module 928, a sixth processing module 930, and a seventh processing module 932. After obtaining the defect category library, the sixth determining module 928 needs to determine the defects present in each defect sample image and the first defect level to which each defect belongs. Then, the sixth processing module 930 annotates the defect sample images in the defect category library according to the first defect level, thereby obtaining second text data. That is, for each defect present in a defect sample image, its corresponding defect level needs to be annotated with text. Then, the text data is combined with the defect sample image and placed into the defect category library. In other words, the defect category library includes multiple defect sample images and corresponding text data. The text data includes the defects present in the defect sample image and the defect level to which each defect belongs; that is, the text data includes first text data and second text data. Finally, the seventh processing module 932 trains the second data model based on multiple defect sample images in the defect category library and the corresponding second text data for each defect sample image to obtain a hierarchical model. The second data model can be a general-purpose deep learning model. During training, the defect category library is divided into a training set database, a test set database, and a validation set database. These databases are then used to train the deep learning model and its parameters, ultimately yielding the final hierarchical model. This invention provides more specific feature information about defect samples through a multimodal data structure, accurately identifying edge and peeling defect features, thus solving the problem of missed detections caused by filtering algorithms in related technologies. Simultaneously, it utilizes a general-purpose deep learning model to identify typical defect features without relying on template information, thereby addressing the problems of weak generalization ability and low efficiency in related technologies.
[0142] In some embodiments, optionally, the banknote printing plate defect detection system 90 further includes: a seventh determining module for determining a preset detection time; and an eighth processing module for determining the computing power allocation parameters of the classification model and the grading model based on the preset detection time.
[0143] In this embodiment, the banknote printing plate defect detection system 90 further includes a seventh determining module and an eighth processing module. The seventh determining module determines a preset detection time, and the eighth processing module adjusts the classification model and the grading model according to the preset detection time, determining the computing power allocation parameters for the classification model and the grading model. It is understood that in this invention, the classification model and the grading model operate simultaneously, and both computing power and detection time are limited during operation. Therefore, it is necessary to adjust the computing power allocation parameters of the classification model and the grading model according to the preset detection time, thereby ensuring both the accuracy of the detection by the classification model and the grading model and completing the detection of the banknote printing plate within the preset detection time.
[0144] In some embodiments, the computing power allocation parameters may optionally include at least one of the following: the total number of threads in the hierarchical model, the total number of threads in the classification model, the execution strategy parameters of the hierarchical model, the execution strategy parameters of the classification model, and the resource allocation ratio between the graphics processors of the classification model and the graphics processors of the hierarchical model.
[0145] In this embodiment, the computing power allocation parameters include: the total number of threads in the hierarchical model, the total number of threads in the classification model, the execution strategy parameters of the hierarchical model, the execution strategy parameters of the classification model, and the resource allocation ratio between the graphics processing unit (GPU) of the classification model and the graphics processing unit of the hierarchical model.
[0146] In some embodiments, the banknote printing plate defect detection system 90 may optionally include a display module for displaying the category and defect level of the target defect.
[0147] In this embodiment, the banknote printing plate defect detection system 90 further includes a display module. The display module can display the category and defect level of the target defect. That is, after obtaining the category and defect level of the target defect, the system displays these information to the user so that the user can verify the detection results.
[0148] In some embodiments, the banknote printing plate may optionally include: intaglio and / or offset printing plate.
[0149] In this embodiment, the banknote printing plate includes: intaglio printing and / or offset printing plate. This invention can inspect both intaglio and offset printing plates, thus eliminating the need to create different templates for different printing types and formats, thereby improving inspection efficiency.
[0150] Figure 12A schematic block diagram of an electronic device according to an embodiment of the present invention is shown; wherein, the electronic device 120 includes a memory 1202, a processor 1204, and a computer program stored in the memory 1202 and executable on the processor 1204, wherein when the processor 1204 executes the computer program, it implements the steps of the banknote printing plate defect detection method as described above.
[0151] The electronic device 120 provided by the present invention, when the processor 1204 executes the computer program, implements the steps of the above-described method for detecting defects in banknote printing plates, and can achieve the technical effects of any of the above embodiments, which will not be repeated here.
[0152] One embodiment of the present invention provides a storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the banknote printing plate defect detection method as described above.
[0153] The storage medium provided by this invention, when the computer program is executed by the processor, implements the steps of the above-described defect detection method for banknote printing plates, and can achieve the technical effects of any of the above embodiments, which will not be repeated here.
[0154] In the description of this specification, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance, unless otherwise expressly specified and limited. The terms "connection," "installation," and "fixing," etc., should be interpreted broadly. For example, "connection" can mean a fixed connection, a detachable connection, or an integral connection; it can mean a direct connection or an indirect connection through an intermediate medium. Those skilled in the art can understand the specific meaning of the above terms in this invention according to the specific circumstances.
[0155] In the description of this specification, the terms "one embodiment," "some embodiments," "specific embodiment," etc., refer to a specific feature, structure, material, or characteristic described in connection with that embodiment or example, which is included in at least one embodiment or example of the present invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.
[0156] The above are merely preferred embodiments of the present invention and are not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for detecting defects in banknote printing plates, characterized in that, include: Obtain the original image information of the banknote printing plate; The template image information is determined based on the banknote printing plate; The first defect data and category are determined based on the original image information and the template image information; The second defect data and category are determined based on the original image information and the classification model. The first defect data and category are combined with the second defect data and category to obtain the third defect data and category; The defect level of the banknote printing plate is determined based on the third defect data, category, and grading model. The verification result is obtained by cross-validating the defect level of the banknote printing plate with the third defect data and category; When the verification result indicates that the defect level of the third defect data and category is different from the defect level of the banknote printing plate, the category and defect level of the target defect are determined according to the defect level of the third defect data and category.
2. The defect detection method for banknote printing plates according to claim 1, characterized in that, The step of determining the first defect data and category based on the original image information and the template image information includes: A first grayscale image is determined based on the original image information; Determine the template grayscale image based on the template image information; The first grayscale image and the template grayscale image are compared to obtain the comparison result; The first defect data and its category are determined based on the comparison results and the preset threshold.
3. The defect detection method for banknote printing plates according to claim 1, characterized in that, The step of cross-validating the defect level of the banknote printing plate with the third defect data and category to obtain the verification result includes: Obtain a first data table, wherein the first data table includes all defect categories and the defect level to which each defect category belongs; The defect level to which the third defect data and category belong is determined based on the third defect data and category and the first data table; The third defect data and its category, along with the defect level of the banknote printing plate, are verified to determine the verification result.
4. The method for detecting defects in banknote printing plates according to claim 1, characterized in that, Before the step of determining the second defect data and category based on the original image information and classification model, the defect detection method for banknote printing plates further includes: Collect defect sample images of multiple banknote printing plates; A defect category library is constructed based on multiple defect sample images; Determine the fourth defect category corresponding to each defect sample image in the defect category library; The defect sample image is labeled in the defect category library according to the fourth defect category to obtain the first text data; The first data model is trained based on multiple defect sample images in the defect category library and the first text data corresponding to each defect sample image to obtain the classification model.
5. The method for detecting defects in banknote printing plates according to claim 4, characterized in that, Before the step of determining the defect level of the banknote printing plate based on the third defect data and the category and grading model, the defect detection method for the banknote printing plate further includes: Determine the first defect level corresponding to each defect sample image in the defect category library; The defect sample image is labeled in the defect category library according to the first defect level to obtain the second text data; The second data model is trained based on multiple defect sample images in the defect category library and the second text data corresponding to each defect sample image to obtain the hierarchical model.
6. The method for detecting defects in banknote printing plates according to claim 1, characterized in that, Before the step of determining the second defect data and category based on the original image information and classification model, the defect detection method for banknote printing plates further includes: Determine the preset detection time; The computing power allocation parameters for the classification model and the hierarchical model are determined based on the preset detection time.
7. The method for detecting defects in banknote printing plates according to claim 6, characterized in that, The computing power allocation parameters include at least one of the following: the total number of threads in the hierarchical model, the total number of threads in the classification model, the execution strategy parameters of the hierarchical model, the execution strategy parameters of the classification model, and the resource allocation ratio between the graphics processor of the classification model and the graphics processor of the hierarchical model.
8. The method for detecting defects in banknote printing plates according to any one of claims 1 to 7, characterized in that, Following the step of determining the category and defect level of the target defect based on the third defect data and the defect level to which the category belongs, the defect detection method for banknote printing plates further includes: The category and level of the target defect are displayed.
9. The method for detecting defects in banknote printing plates according to any one of claims 1 to 7, characterized in that, The banknote printing plates include: intaglio printing and / or offset printing plates.
10. A defect detection system for banknote printing plates, characterized in that, include: The first acquisition module is used to acquire the original image information of the banknote printing plate; The first determining module is used to determine template image information based on the banknote printing plate; The second determining module is used to determine the first defect data and category based on the original image information and the template image information; The third determining module is used to determine the second defect data and category based on the original image information and the classification model. The first processing module is used to combine the first defect data and category and the second defect data and category to obtain the third defect data and category; The fourth determining module is used to determine the defect level of the banknote printing plate based on the third defect data and the category and grading model; The first matching module is used to cross-validate the defect level of the banknote printing plate with the third defect data and category to obtain the verification result; The second processing module is used to determine the category and defect level of the target defect based on the defect level of the third defect data and category when the verification result shows that the defect level of the third defect data and category is different from the defect level of the banknote printing plate.
11. The defect detection system for banknote printing plates according to claim 10, characterized in that, The second determining module is specifically used for: A first grayscale image is determined based on the original image information; Determine the template grayscale image based on the template image information; The first grayscale image and the template grayscale image are compared to obtain the comparison result; The first defect data and its category are determined based on the comparison results and the preset threshold.
12. The defect detection system for banknote printing plates according to claim 10, characterized in that, The first matching module is specifically used for: Obtain a first data table, wherein the first data table includes all defect categories and the defect level to which each defect category belongs; The defect level to which the third defect data and category belong is determined based on the third defect data and category and the first data table; The third defect data and its category, along with the defect level of the banknote printing plate, are verified to determine the verification result.
13. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the defect detection method for banknote printing plates as described in any one of claims 1 to 9.
14. A storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the defect detection method for banknote printing plates as described in any one of claims 1 to 9.