A cigarette fly identification system based on dynamic double-frame trajectory comparison

The cigarette droplet identification system, which uses dynamic dual-frame trajectory comparison, distinguishes cigarette droplets from real defects by taking two photos and using deep learning algorithms. This solves the problem of false rejection caused by droplet interference in traditional detection, and achieves accurate classification and cost reduction.

CN224933908UActive Publication Date: 2026-11-03HONGYUN HONGHE TOBACCO (GRP) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202522560110.X
Authority / Receiving Office
CN · China
Patent Type
Utility models(China)
Current Assignee / Owner
Filing Date
2025-12-02
Publication Date
2026-11-03
Estimated Expiration
2035-12-02

AI Technical Summary

Technical Problem

In traditional cigarette defect detection, droplet interference makes it impossible to distinguish between cigarette droplets and actual defects, resulting in qualified cigarettes being mistakenly rejected and increasing production costs.

Method used

The cigarette droplet identification system, which uses dynamic dual-frame trajectory comparison, judges cigarette droplets and real defects by taking two dynamic shots, dividing the area, and using deep learning algorithms. Combined with review analysis, it ensures accuracy, reduces hardware costs, and meets the needs of high-speed cigarette rolling production lines.

Benefits of technology

It achieves accurate classification of cigarette droplets and actual defects, reduces waste of qualified cigarettes, lowers production costs, is applicable to existing equipment without the need for additional hardware, adapts to different cigarette specifications, and has broad scalability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN224933908U_ABST
    Figure CN224933908U_ABST
Patent Text Reader

Abstract

The utility model discloses a kind of cigarette fly identification system and method based on dynamic double frame trajectory comparison, the system includes imaging module, processing module and decision module connected in sequence signal;The imaging module includes high-speed camera, stroboscopic light source and signal trigger unit;The processing module includes ROI region division unit and double frame image analysis unit;The decision module includes review analysis unit and signal output unit.The utility model is aimed at the problem that cigarette fly cannot be distinguished from other real defects of cigarette in existing cigarette defect detection due to fly interference, and the problem of removing qualified cigarette, by twice dynamic shooting, region division and deep learning algorithm distinguish cigarette fly and real defect (piercing / clip fly / soil stain spot and the like defect), while through review double mechanism improves the precision of cigarette fly classification, reduces classification misjudgment and defect cigarette leak, reduces qualified cigarette waste, reduces production cost.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This utility model belongs to the field of cigarette production technology, specifically relating to a cigarette droplet identification system and method based on dynamic dual-frame trajectory comparison. Background Technology

[0002] In the cigarette production process, visual inspection systems for cigarette surface defects (such as cigarette punctures and foam inclusions) rely on high-speed cameras to capture cigarette images and combine them with traditional image processing algorithms for defect identification. However, random cigarette droplets (not actual cigarette defects) generated during cigarette transmission due to factors such as drum rotation and airflow disturbances are located between the camera and the cigarette. In cigarette imaging, these droplets are highly similar to the texture and grayscale features of actual cigarette defects. Figure 1 This leads to traditional static image analysis algorithms (such as threshold segmentation and morphological operations) misjudging cigarette droplets as actual defects such as cigarette punctures or droplets, resulting in qualified cigarettes being incorrectly rejected and increasing cigarette production costs. Therefore, the analysis of the judgment between cigarette droplets and non-droplets is of great significance for improving cigarette efficiency and reducing production costs.

[0003] like Figure 1 As shown, Figure 1 a, Figure 1 b represents a genuine defect in the cigarette and needs to be discarded; Figure 1 c represents cigarette droplets; the cigarette itself is a valid cigarette and does not need to be rejected. However, in image analysis and recognition, c is highly similar to a / b (real defects such as cigarette punctures / droplets). Traditional detection methods cannot distinguish between cigarette droplets and other real defects (punctures / droplets / stains, etc.), leading to false detections and rejections of valid cigarettes, increasing production costs.

[0004] Current research on cigarette appearance interference from cigarette manufacturing machines mainly involves using dual detection modules to capture single-frame images of the same cigarette at different drum positions, and then using overlapping areas and dynamic displacement analysis to distinguish between droplets and defects. However, this approach relies heavily on hardware layout (dual cameras, air blowing device) and static single-frame image comparison analysis for droplet detection, placing high demands on the hardware for cigarette appearance inspection. For cigarette manufacturers, this increases production costs and maintenance complexity.

[0005] Another method involves taking multiple photos of the cigarette's appearance at various workstations and synthesizing the images. Morphological analysis of the consistency of defects across different workstations is used to determine whether they are cigarette droplets. However, this approach requires multiple workstations and multiple light sources for photography, and places high demands on the light source and image positioning. Furthermore, the image processing algorithm uses multi-frame synthesis and spectral analysis, resulting in a large computational load. For high-speed cigarette rolling production lines, its real-time performance is insufficient, making it difficult to meet the high-speed requirements of these lines.

[0006] Therefore, there is an urgent need for a detection system and method to solve the problem of being unable to distinguish cigarette droplets from other real defects in traditional cigarette defect detection due to droplet interference, as well as the problem of rejecting qualified cigarettes.

[0007] To address the above problems, this utility model is proposed. Utility Model Content

[0008] The purpose of this invention is to address the shortcomings of existing technologies by providing a solution to the problem of traditional cigarette defect detection, which fails to distinguish between cigarette droplets and other real defects due to droplet interference, and also results in the rejection of qualified cigarettes. This invention utilizes a dynamic trajectory analysis method, employing two dynamic imaging sessions, region segmentation, and deep learning algorithms to distinguish between cigarette droplets and real defects (such as punctures, trapped droplets, and stains), thereby reducing waste of qualified cigarettes, lowering production costs, and requiring no additional hardware costs. It also offers high real-time performance and is suitable for high-speed cigarette rolling production lines.

[0009] This utility model is achieved through the following technical solution:

[0010] The first aspect of this utility model provides a cigarette droplet identification system based on dynamic dual-frame trajectory comparison, which includes an imaging module, a processing module and a decision module connected in sequence.

[0011] The imaging module includes a high-speed camera, a strobe light source, and a signal triggering unit;

[0012] The processing module includes an ROI region segmentation unit and a dual-frame image analysis unit;

[0013] The decision-making module includes a review and analysis unit and a signal output unit.

[0014] Preferably, the high-speed camera and the stroboscopic light source are positioned on the cigarette conveying path of the cigarette rolling unit. The signal triggering unit is connected to the pulse signal output terminal of the cigarette rolling unit, and the output terminal of the signal triggering unit is connected to the trigger terminal of the high-speed camera. This is used to receive the pulse signal from the cigarette rolling unit and trigger the high-speed camera to continuously capture two images of the same cigarette passing through the shooting area, thereby obtaining a double-frame cigarette image.

[0015] Preferably, the ROI region division unit has a built-in cigarette template and a dynamic ROI division algorithm, which is used to divide the cigarette in the dual-frame cigarette image into three fixed regions: the filter segment, the cigarette stick segment, and the junction of the cigarette stick and the filter, according to the cigarette template, and select the cigarette stick segment region and the junction region as the target analysis region.

[0016] The dual-frame image analysis unit has a built-in dual-channel convolutional neural network model, which is used to extract and fuse features of the target analysis area in the dual-frame cigarette images, and to determine whether there are droplet and non-droplet defects in the cigarette by comparing the two frames.

[0017] Preferably, the review and analysis unit has a built-in conventional defect identification algorithm, which is used to perform a secondary analysis based on displacement change and deformation rate on cigarettes that the processing module determines need further review, and to confirm the classification result.

[0018] The signal output unit is used to output a corresponding signal according to the review result: if the review confirms that it is cigarette droplets, no NG signal is issued; if the review confirms that it is a non-droplet defect, an NG signal is issued to the rejection mechanism of the cigarette making unit.

[0019] Preferably, the overall system architecture of the cigarette droplet identification system based on dynamic dual-frame trajectory comparison includes a cigarette testing section, a cigarette appearance detection section, a signal transmission section, and a cigarette rolling and sealing unit section. The cigarette appearance detection section includes an I / O control board, a camera, and an industrial computer. The signal transmission section includes a signal converter and an optocoupler. The cigarette rolling and sealing unit section includes a cigarette rolling and sealing unit and a rejection valve.

[0020] The IO control board receives pulse signals from the cigarette rolling unit through the signal converter, thereby controlling the camera to capture images of cigarettes. The camera then transmits the image data to the industrial computer for appearance defect analysis.

[0021] The industrial control computer sends the analysis results (whether there are defects) to the IO control board. When a defective cigarette is detected, the IO control board sends a signal to the cigarette rolling unit via the optocoupler. Finally, the cigarette rolling unit triggers the rejection valve to remove the defective cigarette. The entire process achieves automatic detection of whether the cigarette's appearance is droplets or a defect, and automatic rejection of defective cigarettes.

[0022] The second aspect of this utility model provides a method for identifying cigarette droplets based on dynamic dual-frame trajectory comparison, using the system described in the first aspect of this utility model, which includes the following steps:

[0023] S1, the pulse signal of the cigarette rolling unit triggers the imaging module through the signal triggering unit, and the imaging module starts the strobe light source and high-speed industrial camera through the triggering module to complete the dual-frame acquisition of the cigarette.

[0024] S2. After the acquired image is transmitted to the processing module, it will first perform dynamic ROI division to determine the detection area. At the same time, it will combine the Dual-Channel CNN model to calculate the probability of region change and obtain the data calculation result through two-frame comparison. The processing result enters the decision module, and after the review process, the result is output. The final output result is synchronized to the HMI (human-machine interface) on the one hand, and controls the original cigarette making machine rejection mechanism on the other hand to achieve the precise rejection of defective cigarettes.

[0025] Preferably, the process in step S1 is to acquire two-frame images of the cigarette through dual-frame acquisition;

[0026] Step S2 involves performing dynamic ROI region division to determine the key areas to be detected, then performing differential analysis on the two-frame cigarette images to compare differences and identify anomalies, then using a CNN classification model to determine the defect category of the difference areas, and finally making a decision on whether to remove the cigarette based on the classification results.

[0027] Preferably, in step S2, the ROI dynamic region division process includes: first, image acquisition is completed using a high-speed camera combined with pulse counting; then, the image is preprocessed with noise reduction, enhancement, and Canny edge detection, while simultaneously defining the ROI as fixed at the junction of the cigarette stick and the filter rod; then, preliminary ROI division is performed, firstly finding five edge positioning lines of the cigarette stick, namely the upper edge positioning line, the lower edge positioning line, the filter edge line, the edge line of the cigarette ignition end, and the edge positioning line of the tipping paper in the junction area of ​​the cigarette stick and the filter rod. Using the edge positioning line of the tipping paper in the junction area of ​​the cigarette stick and the filter rod as the starting line and the edge positioning line of the cigarette ignition end as the ending line, the area between the starting line and the ending line is divided into equal-volume sector areas to complete static sector segmentation. Then, dynamic adjustments are made based on the sector areas (fluctuation of ±2% for cigarette stick segments and 5% for the junction area), and finally, the dynamic division result of the cigarette ROI is output. The edge line of the area where the tipping paper meets the cigarette stick is the tipping paper edge positioning line; the edge positioning line of the cigarette's ignition end is the cigarette's ignition end edge positioning line; the area from the tipping paper edge positioning line to the cigarette's ignition end edge line is statically divided. The cigarette has five edge positioning lines: the upper edge positioning line, the lower edge positioning line, the filter edge line, the cigarette's ignition end edge line, and the tipping paper edge positioning line of the area where the cigarette stick meets the filter stick (i.e., the tipping paper positioning line). The upper edge positioning line, the lower edge positioning line, the filter edge line, and the cigarette's ignition end edge line are the edges that encircle the entire cigarette.

[0028] Preferably, in step S2, the differential analysis process includes: firstly, feature extraction is performed based on the differential map, and the displacement offset ΔD (unit: pixels) and similarity ΔS (unit: %) are calculated simultaneously; then, the threshold judgment stage is entered, where the threshold for displacement offset ΔD0 is set as A and the threshold for similarity ΔS0 is set as B; subsequently, if ΔD>A or ΔS>B, the cigarette is marked as a "droplet candidate"; if the condition is not met, the CNN review stage is entered for further verification.

[0029] Preferably, in step S2, the CNN classification decision process includes: First, the inputs of channel 1 and channel 2 are processed by “3×3 convolution + ReLU activation + pooling” (repeated 3 times) to extract features; then, the absolute value of the feature difference between the two channels is calculated, weighted by the SE attention module, and fed into the fully connected layer, and the “difference result (ΔD, ΔS)” is obtained through the Softmax output layer, including ΔD>A, ΔS>B, ΔD<A, ΔS<B, and the difference result is divided into two categories: “droplets” and “others”.

[0030] Next, the classification results are judged:

[0031] If the classification is "droplets" and the conditions ΔD>A or ΔS>B or ΔD>A and ΔS>B are met, then it is determined to be "droplets" and an instruction to not output or not remove is given;

[0032] If the classification is "Other" and satisfies the conditions ΔD>A or ΔS>B or ΔD>A and ΔS>B, then it needs to be reviewed by the traditional grayscale algorithm.

[0033] If the classification is "Other" and satisfies the conditions ΔD < A or ΔS < B or ΔD < A and ΔS < B, then it is determined as "Other", and an NG output is given, triggering a rejection instruction.

[0034] This utility model relates to a cigarette droplet identification system based on dynamic dual-frame trajectory comparison, which includes an imaging module, a processing module, and a decision module.

[0035] Imaging module: Utilizing the cigarette appearance inspection equipment (high-speed camera, stroboscopic light source) of the original cigarette rolling and splicing unit, the pulse signal of the rolling and splicing unit serves as the trigger signal for the high-speed camera, enabling continuous two-shot imaging of the cigarette passing through the camera.

[0036] Processing module: Employs a dynamic ROI segmentation algorithm to divide fixed regions such as the filter segment, cigarette stick segment, and the junction of the cigarette stick and filter based on the cigarette template. Only the cigarette stick region and the junction region (high-incidence areas such as droplets / defects / clamping / punctures) are compared in two frames. Simultaneously, for the two input images, a dual-channel convolutional neural network model is used to determine the type of cigarette droplets and non-droplets through feature fusion.

[0037] Decision Module: To prevent misjudgment and omissions, identified cigarette droplets are re-analyzed using conventional algorithms. Displacement change and deformation rate are used to determine the accuracy of the classification result, thus re-examining cigarette droplets and other non-droplet defects. If the re-examination confirms cigarette droplets, no NG signal is issued, reducing the production cost of rejecting cigarette droplets (but acceptable cigarette body). If the re-examination confirms non-droplet defects, the traditional algorithm is used for analysis and an NG signal is issued, rejecting the unqualified cigarette.

[0038] This invention employs a dynamic dual-frame trajectory comparison and judgment principle. By taking two consecutive photos of the same cigarette, it utilizes the random displacement characteristics of cigarette droplets (significant positional change in the two images) and the static nature of actual cigarette defects (complete positional overlap) and deformation rate ΔS for joint classification and judgment. This achieves direct classification and judgment between cigarette droplets and actual cigarette defects without relying on complex hardware or multispectral analysis. In this embodiment, the threshold judgment rule is set to ΔD0=5px and ΔS0=30%, which determines it as droplets. In actual production, this can be adjusted according to the quality accuracy requirements of different product specifications and actual production conditions.

[0039] This invention employs an adaptive dynamic region division method. Based on the cigarette template area, it automatically locates the cigarette and divides the detection area (the cigarette stick area and the joint area, dynamically dividing it into 6 droplet-prone areas). It eliminates interference from dark areas such as the filter tip, focuses on droplet-prone areas, and combines morphological and Canny edge detection to dynamically adjust the ROI boundary, reduce the amount of computation, and adapt to high-speed rolling production lines.

[0040] This invention employs a dual-channel CNN network structure. After extracting features from two photographed images through convolutional layers (3x3 convolution operations), feature differences are calculated. The classification probability result is output through the Softmax function. The number of computational parameters is small, edge computing is supported, and real-time processing is improved. Through feature fusion, cigarette droplets and non-droplets are accurately classified, thus improving classification accuracy.

[0041] This invention performs a secondary review and verification of CNN classification results. It combines traditional algorithms with CNN algorithms to perform secondary verification of classification results, thereby improving classification accuracy and preventing missed detections and false detections.

[0042] This invention is based on existing cigarette appearance inspection equipment. It uses pulse synchronization of the cigarette rolling unit to trigger the camera and stroboscopic light source to ensure that the conditions for taking two images are consistent. Through embedded edge computing, it achieves real-time processing throughout the entire process.

[0043] Compared with the prior art, the present invention has the following beneficial effects:

[0044] 1. This utility model addresses the problem in existing cigarette defect detection methods that fail to distinguish cigarette droplets from other real defects due to droplet interference, and also prevents the rejection of qualified cigarettes. It distinguishes cigarette droplets from real defects (such as punctures, trapped droplets, or stains) through two dynamic imaging processes, region segmentation, and deep learning algorithms. At the same time, it improves the accuracy of cigarette droplet classification, reduces misclassification and missed rejection of defective cigarettes, reduces waste of qualified cigarettes, and lowers production costs through a dual review mechanism.

[0045] 2. This utility model is based on the principle that the position of cigarette droplets changes significantly in two images due to random displacement, while the actual defect position of the cigarette completely overlaps. It determines whether it is cigarette droplets by comparing displacement and deformation, thus achieving accurate classification of cigarette droplets and non-droplets.

[0046] 3. This utility model is based on existing cigarette appearance inspection equipment. It uses existing high-speed industrial cameras and stroboscopic light sources, eliminating the need for multi-camera coordination or multi-light source equipment and reducing additional hardware costs. It is compatible with all existing cigarette appearance inspection equipment on the rolling production line.

[0047] 4. This utility model adopts adaptive ROI partitioning, dynamically excludes fixed areas such as filters and seams by matching cigarette templates, reduces the amount of calculation, improves processing efficiency, enhances real-time processing capabilities, and meets the needs of high-speed rolling production lines.

[0048] 5. This utility model adopts a dual-channel CNN model with parameters controlled within 1MB. It is deployed on the edge computing unit and supports the cigarette detection speed of existing ZJ17, ZJ116, ZJ116A, ZJ116B, ZJ118, ZJ119, M5 and other cigarette rolling machines, meeting the needs of high-speed rolling production lines.

[0049] 6. This utility model automatically filters image noise caused by light fluctuations, vibrations, etc. through a differential algorithm, retaining only the real change areas of droplets or defects, thus enhancing the robustness of the algorithm and improving its resistance to environmental interference.

[0050] 7. The algorithm and framework of this utility model can be adapted to different cigarette specifications (such as cigarette length, filter color, etc.), and no recalibration is required when switching specifications, making maintenance convenient.

[0051] 8. The algorithm model of this utility model can be extended to other high-speed production lines. Only the ROI region division rules and training data need to be adjusted. The technology transfer cost is low and it has wide scalability. Attached Figure Description

[0052] Figure 1 This is a diagram comparing cigarette droplets and non-droplet droplets.

[0053] Figure 2-3 The diagram shows the structure and examples of the device. Figure 2 This is a diagram of the overall system architecture for visual inspection of cigarette appearance. Figure 3 This is an architecture diagram of the image processing module.

[0054] Figure 4-5 This is a schematic diagram comparing the trajectory of cigarette droplets with the actual defects of a cigarette. Figure 4 This is a schematic diagram of the trajectory of cigarette droplets. Figure 5 This is a schematic diagram of the actual defect trajectory of a cigarette and a test example.

[0055] Figure 6-12 This is a flowchart of the detection and processing procedure, in which... Figure 6 Here is the overall flowchart for dynamic dual-frame detection and processing. Figure 7 Flowchart for dynamic ROI partitioning of cigarettes. Figure 8 This is a schematic diagram illustrating an example of dynamic ROI partitioning for cigarettes. Figure 9 Here is a flowchart of the differential analysis process. Figure 10 This is a schematic diagram of a difference analysis example. Figure 11 A flowchart of the CNN classification decision process. Figure 11 This is a schematic diagram of a CNN classification decision example. Detailed Implementation

[0056] The present invention will be further described in detail below with reference to the embodiments.

[0057] Those skilled in the art will understand that the following embodiments are for illustrative purposes only and should not be construed as limiting the scope of the present invention. Where specific techniques or conditions are not specified in the embodiments, they are performed in accordance with the techniques or conditions described in the literature in the field or according to the product instructions. Materials or equipment whose manufacturers are not specified are all conventional products that can be obtained by purchase.

[0058] Those skilled in the art will understand that, unless specifically stated otherwise, the singular forms “a,” “an,” “the,” and “the” used herein may also include the plural forms. It should be further understood that the word “comprising” as used in this specification means the presence of the stated features, integers, steps, operations, elements, and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof. It should be understood that when we say an element is “connected” to another element, it can be directly connected to the other element, or there may be an intermediate element. Furthermore, the term “connected” as used herein can include wireless connections.

[0059] In the description of this utility model, unless otherwise stated, "a plurality of" means two or more. The terms "inner", "upper", "lower", etc., indicate the orientation or state relationship based on the orientation or state relationship shown in the drawings, and are only for the convenience of describing this utility model and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this utility model.

[0060] In the description of this utility model, it should be noted that, unless otherwise explicitly specified and limited, the terms "installation," "connection," and "equipped with" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium. Those skilled in the art will understand the specific meaning of the above terms in this utility model according to the specific circumstances.

[0061] It will be understood by those skilled in the art that, unless otherwise defined, all terms used herein, including technical and scientific terms, have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. It should also be understood that terms such as those defined in general dictionaries should be understood to have the same meaning as in the context of the prior art, and should not be interpreted in an idealized or overly formal sense unless defined as herein.

[0062] Example

[0063] This embodiment provides a cigarette droplet identification system based on dynamic dual-frame trajectory comparison, which includes an imaging module, a processing module, and a decision module connected in sequence.

[0064] The imaging module includes a high-speed camera, a strobe light source, and a signal triggering unit;

[0065] The processing module includes an ROI region segmentation unit and a dual-frame image analysis unit;

[0066] The decision-making module includes a review and analysis unit and a signal output unit.

[0067] The high-speed camera and strobe light source are positioned on the cigarette conveying path of the cigarette rolling unit. The signal triggering unit is connected to the pulse signal output terminal of the cigarette rolling unit, and the output terminal of the signal triggering unit is connected to the trigger terminal of the high-speed camera. It is used to receive the pulse signal of the cigarette rolling unit and trigger the high-speed camera to take two consecutive pictures of the same cigarette passing through the shooting area to obtain a double-frame cigarette image.

[0068] The ROI region division unit has a built-in cigarette template and a dynamic ROI division algorithm, which is used to divide the cigarette in the dual-frame cigarette image into three fixed regions: the filter segment, the cigarette stick segment, and the junction of the cigarette stick and the filter. The cigarette stick segment region and the junction region are selected as the target analysis regions.

[0069] The dual-frame image analysis unit has a built-in dual-channel convolutional neural network model, which is used to extract and fuse features of the target analysis area in the dual-frame cigarette images, and to determine whether there are droplet and non-droplet defects in the cigarette by comparing the two frames.

[0070] The review and analysis unit has a built-in conventional defect identification algorithm, which is used to perform secondary analysis on cigarettes that the processing module determines need further review, based on displacement change and deformation rate, to confirm the classification result.

[0071] The signal output unit is used to output a corresponding signal according to the review result: if the review confirms that it is cigarette droplets, no NG signal is issued; if the review confirms that it is a non-droplet defect, an NG signal is issued to the rejection mechanism of the cigarette making unit.

[0072] The overall system architecture of the cigarette droplet identification system based on dynamic dual-frame trajectory comparison includes a cigarette testing section, a cigarette appearance detection section, a signal transmission section, and a cigarette rolling and sealing unit section. The cigarette appearance detection section includes an I / O control board, a camera, and an industrial computer. The signal transmission section includes a signal converter and an optocoupler. The cigarette rolling and sealing unit section includes a cigarette rolling and sealing unit and a rejection valve.

[0073] The IO control board receives pulse signals from the cigarette rolling unit through the signal converter, thereby controlling the camera to capture images of cigarettes. The camera then transmits the image data to the industrial computer for appearance defect analysis.

[0074] The industrial control computer sends the analysis results (whether there are defects) to the IO control board. When a defective cigarette is detected, the IO control board sends a signal to the cigarette rolling unit via the optocoupler. Finally, the cigarette rolling unit triggers the rejection valve to remove the defective cigarette. The entire process achieves automatic detection of whether the cigarette's appearance is droplets or a defect, and automatic rejection of defective cigarettes. Figure 2 This illustrates the overall system architecture for visual inspection of cigarette appearance.

[0075] This embodiment is a cigarette droplet identification method based on dynamic dual-frame trajectory comparison, using the system described in the first aspect of this utility model, which includes the following steps:

[0076] S1, the pulse signal of the cigarette rolling unit triggers the imaging module through the signal triggering unit, and the imaging module starts the strobe light source and high-speed industrial camera through the triggering module to complete the dual-frame acquisition of the cigarette.

[0077] S2. After the acquired image is transmitted to the processing module, it will first perform dynamic ROI division to determine the detection area. At the same time, it will combine the Dual-Channel CNN model to calculate the probability of region change and obtain the data calculation result through two-frame comparison. The processing result enters the decision module, and after the review process, the result is output. The final output result is synchronized to the HMI (human-machine interface) on the one hand, and controls the original cigarette making machine rejection mechanism on the other hand to achieve the precise rejection of defective cigarettes. Figure 3 The image processing module architecture is illustrated.

[0078] Preferably, the process in step S1 is to acquire two-frame images of the cigarette through dual-frame acquisition;

[0079] Step S2 involves performing dynamic ROI region division to determine the key areas to be detected, then performing differential analysis on the two-frame cigarette images to compare differences and identify anomalies, then using a CNN classification model to determine the defect category of the difference areas, and finally making a decision on whether to remove the cigarette based on the classification results. Figure 6 The overall process of dynamic dual-frame detection and processing is illustrated.

[0080] In step S2, the ROI dynamic region division process includes: first, image acquisition is completed using a high-speed camera combined with pulse counting; then, the image is preprocessed with noise reduction, enhancement, and Canny edge detection, while the ROI is fixed at the junction of the cigarette stick and the filter stick; then, the ROI is initially divided, starting from the edge line of the junction between the tipping paper and the cigarette stick, the area from the tipping paper positioning line to the edge positioning line of the cigarette stick is divided into equal-volume sector regions, completing the static sector segmentation; then, dynamic adjustments are made based on the sector regions (fluctuation of ±2% for cigarette stick segments and 5% for the junction), and finally, the dynamic division result of the cigarette ROI is output. Figure 7 The process of dynamically dividing the ROI region is illustrated, and Figure 8 It demonstrates the actual effect from the original image, location to division, and intuitively presents the process of determining the ROI region.

[0081] In step S2, the differential analysis process includes: first, feature extraction based on the differential map, and simultaneous calculation of displacement offset ΔD (unit: pixels) and similarity ΔS (unit: %); then, the threshold judgment stage, where the threshold for displacement offset ΔD0 is set as A and the threshold for similarity ΔS0 is set as B; subsequently, if ΔD>A or ΔS>B, the cigarette is marked as a "droplet candidate"; if the condition is not met, the process proceeds to the CNN review stage for further verification. Figure 9 The flowchart of difference analysis is illustrated. Figure 10 It also shows the threshold setting for droplet detection (the threshold is 0.5 in the example) to help clarify the judgment criteria.

[0082] In step S2, the CNN classification decision process includes: First, the inputs of channel 1 and channel 2 are processed by “3×3 convolution + ReLU activation + pooling” (repeated 3 times) to extract features; then, the absolute value of the feature difference between the two channels is calculated, weighted by the SE attention module and passed into the fully connected layer, and the “difference result (ΔD, ΔS)” is obtained through the Softmax output layer, including ΔD>A, ΔS>B, ΔD<A, ΔS<B, and the difference result is divided into two categories: “droplets” and “other”.

[0083] Next, the classification results are judged:

[0084] If the classification is "droplets" and the conditions ΔD>A or ΔS>B or ΔD>A and ΔS>B are met, then it is determined to be "droplets" and an instruction to not output or not remove is given;

[0085] If the classification is "Other" and satisfies the conditions ΔD>A or ΔS>B or ΔD>A and ΔS>B, then it needs to be reviewed by the traditional grayscale algorithm.

[0086] If the classification is "Other" and satisfies the conditions ΔD < A or ΔS < B or ΔD < A and ΔS < B, then it is determined as "Other", and an NG output is given, triggering a rejection instruction. Figure 11 A flowchart of the CNN classification decision process. Figure 12 An example diagram is shown.

[0087] To make the above-mentioned objectives, features and advantages of the utility model more apparent and understandable, the following description is provided in conjunction with... Figures 2-12 The specific embodiments of this utility model are described in detail.

[0088] The embodiments of this utility model are described in detail below, with examples of the embodiments shown in the appendix. Figures 2-12 As shown, the same or similar reference numerals throughout denote the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.

[0089] Figure 2-3 A schematic diagram of the device structure described in this utility model is shown. Figure 4-5 This diagram illustrates a comparison between the trajectory of cigarette droplets described in this invention and the actual defect trajectory of a cigarette. Figure 6-12 The flowchart and example illustration of the detection process described in this utility model are shown. The technical solution of this utility model is further explained below through specific embodiments.

[0090] like Figure 2-3 The diagram shown is a schematic of the device structure. Figure 2 The system architecture for the cigarette appearance inspection device of the cigarette rolling unit is to realize online photographic inspection of cigarettes through the pulse signal of the rolling machine; Figure 3 The present invention describes a method and module architecture for identifying cigarette droplets based on dynamic dual-frame trajectory comparison. After photographing online cigarettes using a camera and light source, the photographed images undergo dynamic ROI region segmentation and dual-channel convolutional neural network processing to calculate the regional change rate of high-droplet-occurrence areas. The calculation results are then reviewed by a decision module to reduce missed and false detections. Finally, a decision is given: if the cigarette is found to be droplets, no rejection signal is issued; if it is a genuine defect, an NG signal is issued and the cigarette is rejected. This improves real-time detection performance and reduces production costs.

[0091] like Figure 4 This is a schematic diagram of the trajectory of cigarette droplets. The green box represents cigarette droplets, and the red box represents actual defects in the cigarette. Due to the randomness of the droplet trajectory, the horizontal and vertical coordinates of the cigarette droplet positions D1 and D2 change significantly in the two images, and the displacement ΔD increases significantly; at the same time, the droplet similarity offset ΔS% also changes.

[0092] Figure 5 The red part in the figure represents the actual defects of the cigarette (such as punctures, foam, etc.). Since the actual defects are static, their positions D1 and D2 remain unchanged, and the displacement ΔD=0. At the same time, the defect similarity S1=S2, and there is basically no defect deformation (similarity offset ΔS=0).

[0093] Therefore, based on the randomness of cigarette droplets in two images of the same cigarette and the static nature of the actual defects, dynamic dual-frame trajectory comparison calculation is used to calculate in the droplet-prone area (cigarette stick, filter and cigarette stick joint).

[0094] As above Figure 6 This is a schematic diagram of the overall processing flow of the detection module. Figure 7 Flowchart for dynamic ROI partitioning of cigarettes. Figure 8 A schematic diagram of dynamic ROI region division for cigarettes is provided. Image 8(1) after being captured by the camera is preprocessed. The preprocessing mainly involves Canny calculation on image 8(2) to find the five edge positioning lines of the cigarette. Figure 8 (2) The area within the red box is the junction between the tipping paper and the cigarette stick. Locate the five edge positioning lines of the cigarette stick, such as... Figure 8 (2) As shown in the yellow box, the five edge positioning lines of the cigarette are the upper edge positioning line, the lower edge positioning line, the filter edge line, the ignition end edge line, and the tipping paper edge positioning line (i.e., the tipping paper positioning line) at the junction of the cigarette stick and the filter stick. The upper edge positioning line, the lower edge positioning line, the filter edge line, and the ignition end edge line are the edge lines that enclose the entire cigarette. After completing the cigarette edge positioning, using... Figure 8(2) The edge line of the tipping paper in the red-framed area serves as a reference point for the static division of the cigarette stick area and the joint area in the high-incidence area of ​​cigarette droplets, which is divided into 6 segments, such as... Figure 8 (3) The five yellow boxes (cigarette stick area) and one red box (the area where the cigarette stick and filter rod meet) indicate the region. For each cigarette, since there is some fluctuation in the cigarette within the roller groove, dynamic adjustments are made based on the static area. The ROI area after dynamic adjustment is the droplet determination area. After the original image of the cigarette is collected, the cigarette edge positioning calculation is performed first to find the five edges of the cigarette. After finding the above five edges of the cigarette (the above edges serve as the baseline for subsequent static area division), the cigarette stick area and the joint area in the high-droplet area of ​​the cigarette are then statically divided. Figure 8 (3) is divided into 5 yellow boxes (cigarette stick area) + 1 red box (joint area).

[0095] like Figure 9 Here is a flowchart of the differential analysis process. Figure 10 This is a schematic diagram of a differential analysis example. After dynamically dividing the ROI region, differential parallel analysis is performed in 6 single regions to calculate the physical motion features (ΔD, ΔS) in each region to achieve coarse screening, reduce the computational load of CNN, and improve the real-time performance of detection. Threshold judgment analysis is performed on the calculated ΔD and ΔS. If the displacement offset ΔD is greater than the set threshold A or the similarity ΔS is greater than the set threshold B, it is judged as cigarette droplets; otherwise, CNN re-judgment is performed.

[0096] like Figure 11 A flowchart of the CNN classification decision process. Figure 12 This diagram illustrates a CNN classification decision example. First, two 64×64 pixel grayscale images (corresponding to the cigarette regions at different time points) are input into a dual-channel network. The network undergoes three repeated convolution operations (each using a 3×3 convolution kernel with ReLU activation and pooling layers). After extracting features from both paths, the absolute difference between the feature maps is calculated. Then, a SE attention mechanism is used to enhance and filter key features. Next, dimensionality reduction is achieved through fully connected layers and randomly deactivated layers. Finally, the Softmax function outputs the probability distribution of "droplets" and "non-droplets," completing the classification decision. If the defect is non-droplets (other defect types), it is reviewed again using traditional algorithms (grayscale detection, etc.) to improve detection and classification accuracy and prevent false positives and false negatives.

Claims

1. A cigarette droplet identification system based on dynamic dual-frame trajectory comparison, characterized in that, It includes an imaging module, a processing module, and a decision module connected in sequence; The imaging module includes a high-speed camera, a strobe light source, and a signal triggering unit; The processing module includes an ROI region segmentation unit and a dual-frame image analysis unit; The decision-making module includes a review and analysis unit and a signal output unit.

2. The cigarette droplet identification system based on dynamic dual-frame trajectory comparison according to claim 1, characterized in that, The high-speed camera and strobe light source are positioned on the cigarette conveying path of the cigarette rolling unit. The signal triggering unit is connected to the pulse signal output terminal of the cigarette rolling unit, and the output terminal of the signal triggering unit is connected to the trigger terminal of the high-speed camera. It is used to receive the pulse signal of the cigarette rolling unit and trigger the high-speed camera to take two consecutive pictures of the same cigarette passing through the shooting area to obtain a double-frame cigarette image.

3. The cigarette droplet identification system based on dynamic dual-frame trajectory comparison according to claim 1, characterized in that, The ROI region division unit has a built-in cigarette template and a dynamic ROI division algorithm, which is used to divide the cigarette in the dual-frame cigarette image into three fixed regions: the filter segment, the cigarette stick segment, and the junction of the cigarette stick and the filter. The cigarette stick segment region and the junction region are selected as the target analysis regions. The dual-frame image analysis unit has a built-in dual-channel convolutional neural network model, which is used to extract and fuse features of the target analysis area in the dual-frame cigarette images, and to determine whether there are droplet and non-droplet defects in the cigarette by comparing the two frames.

4. The cigarette droplet identification system based on dynamic dual-frame trajectory comparison according to claim 1, characterized in that, The review and analysis unit has a built-in conventional defect identification algorithm, which is used to perform secondary analysis on cigarettes that the processing module determines need further review, based on displacement change and deformation rate, to confirm the classification result. The signal output unit is used to output a corresponding signal according to the review result: if the review confirms that it is cigarette droplets, no NG signal is issued; if the review confirms that it is a non-droplet defect, an NG signal is issued to the rejection mechanism of the cigarette making unit.

5. The cigarette droplet identification system based on dynamic dual-frame trajectory comparison according to claim 1, characterized in that, The overall system architecture of the cigarette droplet identification system based on dynamic dual-frame trajectory comparison includes a cigarette testing section, a cigarette appearance detection section, a signal transmission section, and a cigarette rolling and sealing unit section. The cigarette appearance detection section includes an I / O control board, a camera, and an industrial computer. The signal transmission section includes a signal converter and an optocoupler. The cigarette rolling and sealing unit section includes a cigarette rolling and sealing unit and a rejection valve. The IO control board receives pulse signals from the cigarette rolling unit through the signal converter, thereby controlling the camera to capture images of cigarettes. The camera then transmits the image data to the industrial computer for appearance defect analysis. The industrial control computer sends the analysis results to the IO control board. When a defective cigarette is detected, the IO control board sends a signal to the cigarette rolling unit through the optocoupler. Finally, the cigarette rolling unit triggers the rejection valve to reject the defective cigarette.