Search

CN-121981996-A - Card mixed goods detection method and system based on visual characteristics

CN121981996ACN 121981996 ACN121981996 ACN 121981996ACN-121981996-A

Abstract

The invention discloses a card mixed goods detection method and a card mixed goods detection system based on visual characteristics, which belong to the technical field of machine visual detection, wherein the method comprises the steps of acquiring images of the front side and the side of a card in a coordinated manner through multi-station image acquisition; the method comprises the steps of extracting multi-level semantic features to obtain global layout, local patterns, character content and edge texture features, sequentially executing series-level coarse screening, variety-level fine screening and version-level fine screening by hierarchical mixed goods judgment, identifying non-visual mixed goods by material heterogeneous detection through near infrared and polarization imaging, and generating a traceable report by mixed goods traceable analysis and matching with original attribution batches.

Inventors

  • YANG CHAO

Assignees

  • 广东望京卡牌科技有限公司

Dates

Publication Date
20260505
Application Date
20260126

Claims (10)

  1. 1. The card mixed goods detection method based on the visual characteristics is characterized by comprising the following steps of: step S1, multi-station image collaborative acquisition, namely acquiring a complete image of the front face of a card through a front-station area array camera, and acquiring thickness and incision characteristic images of the side edge of the card through a rear-station line scanning camera to obtain multi-dimensional original image data of the card to be detected; s2, extracting multi-level semantic features, namely inputting the acquired card front image into a pre-trained visual basic model, extracting multi-level semantic feature vectors comprising global layout features, local pattern features, character content features and edge texture features, inputting the acquired side image into a feature extraction network to acquire thickness contour feature vectors; Step S3, hierarchical mixing judgment, namely comparing the extracted multi-level semantic feature vector with a standard feature library of a current production batch, and sequentially executing three layers of judgment of series level coarse screening, variety level fine screening and version level fine screening, wherein the series level coarse screening judges whether a card belongs to the current production series, the variety level fine screening judges whether the card belongs to the current production variety, the version level fine screening judges whether the card belongs to the current printing version, each layer of judgment is realized by calculating cosine similarity of feature vectors and Wasserstein distance, and mixing alarm is triggered when the difference degree of any level exceeds a corresponding dynamic threshold; s4, material heterogeneous mixed goods detection, namely acquiring paper gram weight and fiber structure information of a card material through near infrared imaging, acquiring film type and coating process information of the card surface through polarization imaging, comparing the acquired physical characteristics of the material with a standard material library, and identifying a non-visual material heterogeneous mixed goods type; And S5, tracing and alarming output, namely when the mixed goods are detected, tracing analysis is carried out on the feature vector of the mixed goods card, the feature vector is matched with a historical batch feature library, the original attribution batch of the mixed goods card is determined, a tracing report containing the mixed goods type, the confidence coefficient and the original attribution batch information is generated, and the production line alarming is triggered.
  2. 2. The card mixing detection method based on visual features according to claim 1, wherein in the step S1, the resolution of the area array camera is not lower than 4096×4096 pixels, the line frequency of the line scanning camera is not lower than 20kHz, the transmission distance between the front station and the rear station is 80mm to 150mm, and the detection period of a single card is not more than 300ms.
  3. 3. The card mixing detection method based on visual features according to claim 1, wherein in the step S2, the dimension of the global layout feature vector is 256 dimensions, the dimension of the local pattern feature vector is 512 dimensions, the dimension of the character content feature vector is 128 dimensions, the dimension of the edge texture feature vector is 256 dimensions, the pre-trained visual basic model adopts a variety feature encoder based on contrast learning, and the encoder obtains feature representation capability which is robust to variation of the same variety and sensitive to variation across varieties through self-supervision pre-training learning of a large number of card image pairs.
  4. 4. The card mixing detection method based on the visual characteristics according to claim 1, wherein in the step S3, the range of values of the series level judgment threshold is 0.70 to 0.90, the range of values of the variety level judgment threshold is 0.85 to 0.95, the range of values of the version level judgment threshold is 0.92 to 0.98, and the dynamic threshold is adaptively adjusted according to the illumination intensity, the temperature and the humidity of the current production environment and the running state of the equipment.
  5. 5. The card mixing detection method based on the visual characteristics according to claim 1, wherein the training process of the contrast learning variety characteristic encoder adopted in the step S2 comprises the steps of constructing a positive sample pair and a negative sample pair, wherein the positive sample pair consists of image pairs of the same variety of cards under different illumination conditions, position offset and slight deformation, the negative sample pair consists of image pairs of different varieties of cards, and performing self-supervision pre-training by adopting InfoNCE contrast loss functions with adjustable temperature parameters, so that the encoder learns to map the positive sample pair to adjacent positions of a characteristic space and map the negative sample pair to distant positions.
  6. 6. The card mix detection method based on visual features of claim 1, wherein in the step S3, cosine similarity is used for measuring direction consistency of feature vectors, wasperstein distance is used for measuring structural differences of feature distribution, the cosine similarity is preferentially used for rapid screening during hierarchical determination, and wasperstein distance is further used for fine determination on samples with cosine similarity in boundary intervals.
  7. 7. The method according to claim 1, wherein in the step S4, near infrared imaging uses a near infrared light source with a wavelength range of 850nm to 950nm, polarization imaging uses image acquisition with four polarization angles of 0 degrees, 45 degrees, 90 degrees and 135 degrees, and material heterogeneous detection can identify different film types including bright film, matte film and laser film.
  8. 8. The card stock mixing detection method based on the visual features according to claim 1, wherein in the step S5, the stock mixing tracing matching uses a nearest neighbor searching algorithm based on feature vector retrieval to search the historical lot feature library for the lot record closest to the feature vector of the card stock mixing, and when the nearest neighbor distance is smaller than the tracing matching threshold, the valid matching is determined, and the corresponding lot is marked as the stock mixing source lot.
  9. 9. The method for detecting card mixing according to claim 1, further comprising a step of dynamically updating a feature library, wherein feature vectors of standard sample cards are collected at the beginning of each production batch, a standard feature library of the current batch is established, the standard feature library is updated in an increment mode according to detection feedback in the production process, and the current batch feature library is archived to a historical batch feature library for subsequent mixing traceability analysis at the end of the batch.
  10. 10. A card mixing detection system based on visual characteristics for implementing the card mixing detection method based on visual characteristics as set forth in any one of claims 1 to 9, comprising: the multi-station image collaborative acquisition module comprises an area array camera arranged at a front station and a line scanning camera arranged at a rear station, wherein the area array camera is used for acquiring a complete image of the front surface of the card, and the line scanning camera is used for acquiring thickness and incision characteristic images of the side edge of the card; the multi-level semantic feature extraction module comprises a pre-trained visual basic model and is used for extracting global layout features, local pattern features, character content features and edge texture features from the front image of the card and extracting thickness contour features from the side image; The hierarchical mixed goods judging module is used for comparing the extracted feature vector with a standard feature library, sequentially executing three layers of judgment of series-level coarse screening, variety-level fine screening and version-level fine screening, and judging whether mixed goods exist or not through cosine similarity and Wasserstein distance calculation; The material heterogeneous detection module comprises a near infrared imaging unit and a polarization imaging unit and is used for acquiring physical characteristic information of card materials and comparing the physical characteristic information with a standard material library to identify non-visual material heterogeneous mixed goods; And the mixed goods tracing and alarming output module is used for carrying out characteristic comparison and positioning on the detected mixed goods cards, matching the original attribution batches of the mixed goods cards, generating a tracing report and triggering the production line alarming.

Description

Card mixed goods detection method and system based on visual characteristics Technical Field The invention relates to the technical field of machine vision detection, in particular to a card mixed goods detection method and system based on visual characteristics. Background In the packaging production line of card products, the problem of mixing is always a key factor affecting the quality of the products. The mixing refers to the situation that cards of different varieties, different series or different printing versions are mixed into the current production product by mistake in the same production batch. Because card products often have highly similar designs, there may be differences between different varieties in only partial patterns, character content, or color details, which makes it difficult for manual visual inspection to accurately identify mixes, especially in a high-speed production line environment. The problem of mixed goods not only affects the use experience of consumers, but also can lead to serious consequences such as product recall, customer complaints and the like, and brings huge economic loss and brand reputation damage to production enterprises. The existing card detection technology mainly relies on bar code or two-dimensional code recognition to carry out variety verification. The method comprises the steps of printing a unique identification code on the back or the edge of the card, reading coded information by using scanning equipment, and comparing the coded information with a preset variety database, so as to judge whether the card belongs to the current production batch. However, the code-based detection mode has the obvious defects that firstly, the bar code or the two-dimensional code can only identify the category information of the card and cannot reflect the actual state of the front printed content of the card, when different versions of the same variety of cards are mixed, the code detection cannot identify the fine difference, secondly, the bar code is easily influenced by factors such as printing quality, abrasion and shielding, and when the bar code is damaged or covered, the detection system cannot work normally, so that mixed goods are missed, and thirdly, special coding areas are reserved when the card is designed for bar code detection, so that the constraint conditions of product design are increased. The Chinese patent application with the application number of CN120355906A discloses an image feature extraction and identification integrated system, which comprises a conversion module, a setting module, an analysis module, a selection module, an identification module and an output module. The image processing device comprises a conversion module, an analysis module, a selection module, an output module and an output module, wherein the conversion module is used for converting an image to be processed into a multi-type image data set comprising a gray image, a contour image, a relief image and a binary image, the setting module is used for setting a specification of a feature recognition window and controlling the window to continuously move on the surface of the image to obtain an area image, the analysis module is used for carrying out feature value calculation on the area images of various types of images under the feature recognition window, the selection module is used for selecting the area image based on an analysis result, the recognition module is used for recognizing whether an intersection area exists in the selected area image, and the output module is used for determining the feature area according to a central pixel and a feature area radius of the intersection area. According to the scheme, the key feature areas of the image are positioned through multi-dimensional fusion analysis and an iterative verification mechanism, so that the comprehensiveness of feature extraction and the accuracy of identification are improved. However, the above prior art solutions are mainly directed to feature region extraction of a general image, and the purpose of the prior art solutions is to locate key feature regions in an image, rather than to determine whether the image belongs to a specific category. The technology is applied to a card mixed detection scene, and has the following technical problems that firstly, the scheme adopts a traditional image processing method such as gradient calculation, texture entropy analysis, edge density calculation and the like to perform feature extraction, the manually designed features are difficult to capture high-level semantic information in card images, the distinguishing capability of different types of cards with highly similar appearance is insufficient, secondly, the scheme lacks a feature learning mechanism aiming at specific products, the characteristic representation which is robust to variation of the same variety and is sensitive to cross-variety difference cannot be established, thirdly, the scheme does not cons