A method and system for online detection of cigarette carton stamps based on AI vision and information integration

By integrating AI vision and information into an online inspection method, the problems of lag and low recognition rate in the quality inspection of steel stamps during cigarette packaging have been solved. This has enabled highly stable and automated quality monitoring, ensuring the efficient operation and quality safety of the production line.

CN122176737APending Publication Date: 2026-06-09CHINA TOBACCO JIANGXI IND CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHINA TOBACCO JIANGXI IND CO LTD
Filing Date
2026-03-23
Publication Date
2026-06-09

AI Technical Summary

Technical Problem

In the current cigarette packaging process, the quality inspection of steel stamps relies on manual sampling, which is lagging and random, and cannot achieve 100% online coverage. Furthermore, machine vision has low recognition rate, poor stability, and lacks intelligent linkage, resulting in blind spots in quality monitoring and batch quality accidents.

Method used

An online inspection method based on AI vision and information integration is adopted. The target process steel stamp code is generated by reading brand information, work order shift and system date through QR code. The OCR engine of industrial smart camera is used for real-time recognition and comparison. Combined with adaptive detection and hierarchical control, continuous anomaly detection and automatic shutdown are realized.

Benefits of technology

It improves the accuracy and stability of stamp recognition, eliminates human error, achieves 100% online detection coverage, quickly captures and intercepts batch quality defects, and improves production efficiency and quality control.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122176737A_ABST
    Figure CN122176737A_ABST
Patent Text Reader

Abstract

The application discloses a kind of based on AI vision and information integration's cigarette small box steel seal online detection method and system, it is related to tobacco equipment technical field, including according to the brand information of cigarette packet, system current date and work order shift information read by two-dimensional code code reader, determine production batch identification, and call target process steel seal code;Calculate the opportunity of cigarette packet to reach detection station and send trigger signal, collect steel seal image;Utilize the character recognition of steel seal image by built-in AI's OCR engine, obtain actual steel seal character sequence, compare actual steel seal character sequence with pre-stored target process steel seal code bit by bit;Adaptive detection and hierarchical control are carried out, and based on bit-by-bit comparison result carries out logical and operation determination steel seal quality, according to the different response results triggered by continuous abnormal quantity.The application can improve the recognition accuracy and stability, easy to be reformed and integrated on existing cigarette packaging equipment, deployment is fast, and maintenance is convenient.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of tobacco equipment technology, and in particular to an online detection method and system for the steel stamp on cigarette packs based on AI vision and information integration. Background Technology

[0002] In the cigarette packaging production process, the stamped seal on the small box is a crucial identifier for information such as the production date and shift. Currently, the industry generally relies on manual sampling for stamp quality inspection, which is significantly lagging and random, failing to achieve 100% online coverage. Due to equipment aging, debugging errors, or human negligence, continuous quality defects such as incorrect or missed stamping are prone to occur, creating significant blind spots in quality monitoring. Once these occur, they can easily lead to batch quality incidents, causing substantial quality risks and economic losses for enterprises.

[0003] While existing technologies have attempted to employ general machine vision or OCR (Optical Character Recognition) for inspection, they generally suffer from low recognition rates, poor stability, long customization development cycles, and high maintenance costs due to the complex working conditions in cigarette production sites (such as reflective packaging materials, high-speed movement, and variable embossed lettering). Furthermore, the lack of intelligent integration with production management systems (such as MES) prevents automatic matching and switching of process parameters, leaving the risk of human error in setting parameters. Therefore, there is an urgent need for an online automatic inspection solution that can adapt to complex environments, offer high stability, is intelligent, and can completely intercept batch defects. Summary of the Invention

[0004] In view of the problems existing in the current online detection method for cigarette box stamps based on AI vision and information integration, this invention is proposed. Addressing the shortcomings of existing equipment technology, this invention achieves automatic detection of cigarette box stamps by online identification and comparison with the stamps required by the process specifications, thereby improving packaging quality and production efficiency.

[0005] Therefore, the problem to be solved by this invention is how to provide an online detection method and system for the steel stamp of cigarette boxes based on AI vision and information integration.

[0006] To solve the above-mentioned technical problems, the present invention provides the following technical solution:

[0007] In a first aspect, the present invention provides an online detection method for the steel stamp of cigarette packs based on AI vision and information integration, which includes: the host computer determines the production batch identifier based on the cigarette pack brand information read by the QR code reader, the current date of the system and the work order shift information obtained from the data acquisition system, and retrieves the target process steel stamp code from the process database based on the production batch identifier, and sends it to the programmable logic controller for storage through the communication network;

[0008] The programmable logic controller receives signals from the original shaft encoder and the No. 8 wheel cigarette pack counter in real time. It calculates the timing of the cigarette pack arriving at the detection station through the logic combination of the shift register and sends a trigger signal. The image sensor acquires the stamp image under the control of the trigger signal and transmits the image to the industrial smart camera.

[0009] The industrial smart camera uses the built-in AI OCR engine to recognize characters in the stamp image, obtains the actual stamp character sequence, and sends it to the programmable logic controller. The programmable logic controller compares the actual stamp character sequence with the pre-stored target process stamp code bit by bit.

[0010] Adaptive detection and hierarchical control are implemented. The quality of the stamp is determined by logical AND operation based on the bit-by-bit comparison results. When the number of consecutive abnormalities reaches the preset first consecutive threshold, a level one alarm is triggered. When the number of consecutive abnormalities reaches the preset second consecutive threshold, a level two response control is triggered to automatically stop the production line.

[0011] As a preferred embodiment of the online detection method for cigarette box stamps based on AI vision and information integration described in this invention, the generation method of the target process stamp code is as follows:

[0012] Two sets of steel stamp coding rules associated with brand attributes are pre-built. The first coding rule applies to self-produced brands, and the coding sequence consists of shift identifier, year identifier, month identifier, date identifier and machine number identifier in sequence. The second coding rule applies to cooperative processing brands, and the coding sequence consists of year identifier, month identifier, date identifier, shift identifier, machine number identifier and factory code identifier in sequence.

[0013] The host computer selects the coding rule based on the acquired brand information, and fills in and splices the acquired year, month, day, shift, machine number and factory code according to the sequence of the coding rule to dynamically generate a unique target process stamp code for the current production batch.

[0014] As a preferred embodiment of the online detection method for cigarette pack stamps based on AI vision and information integration described in this invention, the calculation of the timing of the cigarette pack arriving at the detection station includes:

[0015] Create a shift register array with a length equal to the total number of cigarette packs at the camera station plus 1 from the eighth wheel counter and initialize it to zero;

[0016] When the phase of the counter on wheel number eight arrives, the first element of the array is assigned a value of 1 or 0 depending on whether a cigarette pack is detected, and then the array is shifted one bit to the right.

[0017] When the camera triggers the phase, check if the last element of the array is 1. If it is 1, trigger the camera to capture the data.

[0018] By using encoder signal synchronization shifting operation, the travel distance of the tobacco pack state in the array is kept synchronized with the actual tobacco pack conveying distance.

[0019] As a preferred embodiment of the online detection method for cigarette box stamps based on AI vision and information integration described in this invention, the OCR engine includes a continuous learning mechanism for model optimization.

[0020] The system automatically collects misidentified samples and builds an incremental dataset. When the accumulated samples reach a preset threshold, the model is incrementally trained in an offline environment using elastic weight consolidation or adapter mode. After training, the model is compressed and remotely deployed to a smart camera for periodic iterative updates.

[0021] As a preferred embodiment of the online detection method for cigarette box stamps based on AI vision and information integration described in this invention, the bit-by-bit comparison includes:

[0022] The actual steel stamp character sequence extracted by identification is compared with the target process steel stamp code sequence character by character. If each character is the same, the comparison result is assigned a value of 1; otherwise, it is assigned a value of 0.

[0023] Perform a logical AND operation on the comparison results of all bits. If the result is 1, the stamp quality is considered acceptable; if the result is 0, the stamp quality is considered unacceptable.

[0024] As a preferred embodiment of the online detection method for cigarette box stamps based on AI vision and information integration described in this invention, the adaptive detection and hierarchical control includes:

[0025] During continuous production, the system automatically starts a self-inspection once the set quantity is produced. After the self-inspection starts, it checks the steel stamp of the first small box. If the actual steel stamp is consistent with the target process steel stamp, the system pauses the inspection and waits for the next self-inspection cycle.

[0026] If the actual stamp does not match the target process stamp, continue to test subsequent small boxes until a match is detected, then stop this self-test.

[0027] If the comparison reveals that the actual stamp is inconsistent with the target process stamp, and this inconsistency continues to exceed the set first continuous threshold, the system will trigger a level one alarm, but the production line will continue to run.

[0028] If the abnormal state continues to occur and reaches the preset second continuous threshold, it is determined to be a valid defect, triggering a secondary response and controlling the production line to automatically stop.

[0029] Secondly, the present invention provides an online detection system for steel stamps on cigarette packs based on AI vision and information integration, which includes: an intelligent detection module deployed next to the cigarette pack conveying channel, including a dome lighting source, an image sensor and an industrial intelligent camera with a built-in AI OCR engine, used to acquire steel stamp images and identify the actual steel stamp character sequence under the control of a trigger signal;

[0030] The control and decision module, with a programmable logic controller as its core, is used to receive signals from the original machine shaft encoder and the No. 8 wheel cigarette pack counter, control the timing of taking pictures, receive the target process steel stamp and the identification results from the intelligent detection module sent by the host computer, compare and judge the quality, and control the operating status of the production equipment according to the judgment results.

[0031] The information management and interaction module includes a host computer and a human-machine interaction touch screen. The host computer communicates with the QR code reader and data acquisition system to generate and issue target process steel stamps based on brand information, system date, and work order shift. The touch screen is used for real-time display and parameter setting.

[0032] The communication network module integrates the intelligent detection module, control and decision-making module, information management and interaction module, QR code reader and data acquisition system into the same industrial local area network through an industrial switch.

[0033] Thirdly, the present invention provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of an online detection method for cigarette box stamps based on AI vision and information integration.

[0034] Fourthly, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein: when the computer program is executed by a processor, it implements the steps of an online detection method for the steel stamp of cigarette boxes based on AI vision and information integration.

[0035] The beneficial effects of this invention are as follows: High robustness and recognition rate: Utilizing a dedicated industrial intelligent camera with a built-in AIOCR engine, it adapts to complex on-site environments through machine learning, overcoming the shortcomings of traditional visual algorithms in terms of poor anti-interference capabilities, and significantly improving recognition accuracy and stability. By integrating information such as QR codes and data acquisition systems, it achieves automatic matching and distribution of target process stamps, completely eliminating errors that may be caused by manual settings and improving the accuracy and automation level of process execution. Innovatively, it adopts "continuous anomaly detection" logic to replace the theoretically extremely difficult "100% perfect package-by-package recognition." Through two-level alarms and continuous threshold judgment, it can quickly and accurately capture and intercept batch and continuous quality defects caused by equipment failures, etc., making it highly practical. The system architecture is clear, with well-defined module divisions. Through standard industrial network communication, it is easy to modify and integrate with existing cigarette packaging equipment, allowing for rapid deployment and convenient maintenance. Attached Figure Description

[0036] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0037] Figure 1 This is a flowchart of an online detection method for the steel stamp on cigarette packs based on AI vision and information integration. Detailed Implementation

[0038] To make the above-mentioned objects, features, and advantages of the present invention more readily understood, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the protection scope of the present invention.

[0039] 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 those skilled in the art can make similar extensions without departing from the spirit of the invention. Therefore, the invention is not limited to the specific embodiments disclosed below.

[0040] Secondly, the term "an embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in one embodiment" appearing in different places throughout this specification does not necessarily refer to the same embodiment, nor is it a single embodiment or an embodiment selectively excluded from other embodiments.

[0041] Reference Figure 1 This is the first embodiment of the present invention, which provides an online detection method for the steel stamp on cigarette packs based on AI vision and information integration, including:

[0042] S1: System initialization and intelligent setting of target process stamp: When production starts, the host computer automatically determines a unique production batch identifier based on the read QR code number information, the current system date, and the work order shift information provided by the data acquisition system. Based on this, it retrieves the "target process stamp" from the process database and sends it to the PLC for storage via the communication network.

[0043] Specifically, the generation of the target process stamp includes the following steps:

[0044] Step S1.1: Construct a steel stamp coding rule library; pre-construct two sets of steel stamp coding rules associated with brand attributes; the first coding rule applies to self-produced brands, and its coding sequence consists of shift identifier, year identifier, month identifier, date identifier, and machine number identifier in sequence; the second coding rule applies to cooperative processing brands, and its coding sequence consists of year identifier, month identifier, date identifier, shift identifier, machine number identifier, and factory code identifier in sequence.

[0045] Step S1.2: Obtain real-time production information; in online detection mode, the system collects the following multi-source data in parallel:

[0046] 1. Collect the brand information of the current cigarette pack, and obtain the brand information through a QR code reader to determine whether to call the first coding rule or the second coding rule;

[0047] 2. Read the current system date from the industrial control computer system and parse it to obtain the specific values ​​of year, month, and day;

[0048] 3. Obtain the current work order information from the data acquisition system and parse it to obtain the specific values ​​for the current shift;

[0049] 4. Read the preset machine number and the factory code required when calling the second encoding rule;

[0050] Step S1.3: Dynamically synthesize the target steel stamp code; Based on the brand information obtained in step S2, select the coding rule, fill and splice the specific values ​​of the obtained year, month, day, shift, machine number and factory code according to the sequence order of the selected rule, and dynamically generate a target process steel stamp that is unique to the current production batch.

[0051] S2: Precise Triggering and Image Acquisition: When the cigarette packs are running on the production line, the PLC receives the original shaft encoder signal and the cigarette pack counter signal of the No. 8 wheel in real time. Through the logical combination of the two, it calculates the timing of the cigarette packs arriving at the detection station and sends out a trigger signal.

[0052] Specifically, the image sensor of the intelligent inspection module acquires a clear image of the stamped seal under dome-shaped light source illumination, and the image is transmitted to the industrial intelligent camera. The timing of the cigarette pack arriving at the inspection station is calculated using the following PLC control logic:

[0053] Create a shift register array with a length equal to the total number of cigarette packs at the camera station plus 1 from the eighth wheel counter and initialize it to zero;

[0054] When the phase of the counter on wheel number eight arrives, the first element of the array is assigned a value of 1 or 0 depending on whether a cigarette pack is detected, and then the array is shifted one bit to the right.

[0055] When the camera triggers a phase, check if the last element of the array is 1. If it is 1, the camera will capture the image; otherwise, it will not.

[0056] By using encoder signal synchronization shifting operation, the travel distance of the tobacco pack state in the array is kept precisely synchronized with the actual tobacco pack conveying distance.

[0057] S3: AI Recognition and Information Comparison: The industrial intelligent camera uses its built-in AI OCR engine to recognize characters in the stamp image, obtain the string "actual stamp", and send it to the PLC. The PLC simultaneously receives the recognition result and the "target process stamp" sent by the host computer, and performs real-time comparison.

[0058] Specifically, the steps for industrial smart cameras to recognize stamped characters using their built-in AI OCR engine include:

[0059] The original image of the steel stamp is acquired and preprocessed for enhancement; a lightweight object detection network is used to accurately locate the character region of the steel stamp.

[0060] Perform character segmentation and normalization on the positioning region;

[0061] A single character image is input into a pre-trained deep learning recognition network for recognition. The network adopts a combination architecture of convolutional neural networks and recurrent neural networks.

[0062] The identified individual characters are concatenated in sequence to generate the actual stamped character sequence.

[0063] S4: Adaptive detection and hierarchical control. The system adopts an adaptive detection mode that includes two-level alarms and periodic self-checks to minimize the impact of false alarms on production.

[0064] Specifically, the two-level alarm mechanism: when an anomaly is detected, the system first triggers an alarm; if the anomaly persists, the system will automatically shut down, minimizing the impact of false alarms on production.

[0065] Anomaly detection involves comparing the actual stamped character sequence extracted from the identification with the target process stamped code sequence bit by bit. If each character is the same, the comparison result for that bit is assigned a value of "1"; otherwise, it is assigned a value of "0".

[0066] Perform a logical AND operation on the comparison results of all bits; if the result is "1", the stamp quality is deemed acceptable; if the result is "0", the stamp quality is deemed unacceptable, indicating an abnormality in the stamp.

[0067] Periodic self-check and fault tolerance mechanism: During continuous production, the system automatically starts a self-check after producing a set quantity (e.g., 100 packages).

[0068] When the self-test detects that the "actual stamp" of the first small box matches the "target process stamp" after the self-test is started, the system pauses the test and waits for the next cycle of self-test.

[0069] When the "actual stamp" on the first small box is inconsistent with the "target process stamp", the system continues to check the subsequent small boxes until the stamp on the small box is consistent with the "target process stamp". At this point, the self-inspection stops. If the PLC finds that the "actual stamp" and the "target process stamp" are inconsistent and this happens continuously for more than the first set continuous threshold (e.g., 5 consecutive boxes), the system will first trigger a level one alarm (e.g., an audible and visual alarm), but the production line will continue to run to avoid accidental shutdowns caused by momentary interference.

[0070] If the abnormal state continues to occur and reaches the preset second consecutive threshold (e.g., 30 consecutive packages), the PLC will determine it as a valid defect, trigger a secondary response, and control the production line to automatically stop, thereby intercepting a batch of defective products.

[0071] refer to Figure 1 After the system is powered on, the host computer begins operation. First, it retrieves the cigarette pack brand number from the QR code reader, then obtains the shift information of the current production work order from the workshop data acquisition system, and combines this with the system date to generate a unique production batch code. Based on this, the host computer queries the local process database, accurately matches and retrieves the "target process stamp" for that batch, and then sends it to the PLC for storage via the industrial network.

[0072] At the same time, the PLC continuously monitors the high-speed pulses from the "shaft encoder" of the cigarette packaging machine and the arrival signal from the "No. 8 wheel cigarette pack counter".

[0073] When the cigarette pack moves precisely to the detection station, the two signals are processed by the PLC logic to generate a precise synchronous trigger pulse.

[0074] The trigger pulse drives the intelligent detection module, instantly illuminating the dome-shaped shadowless light source to provide uniform illumination for the stamped area, while the image sensor simultaneously acquires high-definition images.

[0075] The image is transmitted via cable to an industrial camera with a built-in AIOCR engine. The engine quickly identifies the "actual stamp" characters. The PLC simultaneously receives the "actual stamp" identification result from the industrial camera and compares it in real time with the "target process stamp" stored during the initialization phase.

[0076] If the results are consistent, generation continues. If they are inconsistent, the PLC counts. When the condition of "continuous abnormal count >= 5" is met, the system triggers a Level 1 response with an audible and visual alarm, alerting the operator to the abnormal stamping. If no action is taken, and the "continuous abnormal count >= 30," the PLC determines that this is not an accidental interference but a continuous quality defect. The system immediately triggers a Level 2 response, issuing an emergency stop command to the packaging machine, thereby controlling defective products within a very small batch and achieving efficient interception of batch quality incidents. After the machine stops, manual intervention is required to troubleshoot the equipment. After resetting, the system restarts.

[0077] Furthermore, this embodiment also provides an online detection system for cigarette box stamps based on AI vision and information integration, including:

[0078] Intelligent detection module: Deployed next to the tobacco pack conveying channel, including a movable bracket, dome lighting source, image sensor, industrial camera cable, and industrial camera.

[0079] The fixed end of the mobile bracket is used to mount the image sensor, while the mobile end is used to mount it on the cigarette pack conveying channel of the cigarette packaging equipment. The dome lighting source is mounted on the image sensor to provide stable illumination when the image sensor acquires images. The image sensor receives trigger signals from the control and decision module and acquires images of the stamped boxes on the cigarette pack channel in real time. The industrial camera cable is responsible for connecting the image sensor and the industrial camera and transmitting the acquired images of the stamped boxes to the industrial camera.

[0080] The industrial camera has a built-in AI OCR engine that can intelligently recognize the stamps on small boxes in transmitted images through continuous learning. The built-in AI OCR engine uses a continuous learning mechanism to optimize the model: the system automatically collects misidentified samples and builds an incremental dataset; when the accumulated samples reach a threshold, the model is incrementally trained offline using elastic weight consolidation or adapter mode to effectively avoid catastrophic forgetting; after training, the model is compressed and remotely deployed to the smart camera to achieve periodic iterative updates; continuous learning is an offline update mode, rather than online real-time parameter adjustment, to ensure continuous and stable production processes.

[0081] Control and Decision Module: With a programmable logic controller (PLC) as its core, it serves as the control center of the system. The PLC receives synchronization signals from the original shaft encoder and the No. 8 wheel cigarette pack counter to precisely control the timing of the intelligent detection module's photo taking.

[0082] It receives the target process stamp instructions and brand information from the host computer, as well as the stamp recognition results from the intelligent detection module; it performs comparison and quality judgment based on preset logic, and controls the operating status of the production equipment (such as normal production, audible and visual alarm, and automatic shutdown) according to the judgment results.

[0083] Information Management and Interaction Module: This module includes a host computer (industrial control computer) and a human-machine interface (HMI touchscreen). The host computer communicates with the QR code reader and the workshop data acquisition system. Based on the read QR code information, it determines the actual production grade, combines it with the work order information read from the data acquisition system to obtain the shift information, and integrates the system's own date and time. These three elements together determine a unique "target process stamp," and based on this, intelligently queries and matches from the process database and sends the current batch's "target process stamp" string to the PLC. The HMI touchscreen is used to display the test results, system status, and alarm information in real time, and provides an interface for setting key parameters (such as self-test thresholds and alarm thresholds).

[0084] Communication network module: Through an industrial switch, the intelligent detection module, control and decision-making module, information management and interaction module, QR code reader, and data acquisition system are integrated into a stable and reliable industrial local area network, enabling high-speed and reliable data interaction between the modules.

[0085] This embodiment also provides a computer device applicable to an online detection method for cigarette box stamps based on AI vision and information integration, comprising: a memory and a processor; the memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions to implement all or part of the steps of the method described in the above embodiments of the present invention.

[0086] This embodiment also provides a storage medium on which a computer program is stored. When the computer program is executed by a processor, it performs the method in any optional implementation of the above embodiments. The storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Red-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.

[0087] The storage medium proposed in this embodiment and the data storage method proposed in the above embodiments belong to the same inventive concept. Technical details not described in detail in this embodiment can be found in the above embodiments, and this embodiment has the same beneficial effects as the above embodiments.

[0088] In summary, this method employs a dedicated industrial intelligent camera with a built-in AIOCR engine. Through machine learning, it adapts to complex on-site environments, overcoming the shortcomings of traditional visual algorithms in terms of poor anti-interference capabilities, and significantly improving recognition accuracy and stability. By integrating information such as QR codes and data acquisition systems, it achieves automatic matching and distribution of target process stamps, completely eliminating errors that may be caused by manual settings and improving the accuracy and automation level of process execution. It innovatively uses "continuous anomaly detection" logic to replace the theoretically extremely difficult "100% perfect package-by-package recognition." Through two-level alarms and continuous threshold judgment, it can quickly and accurately capture and intercept batch and continuous quality defects caused by equipment failures and other reasons, demonstrating strong practicality. The system architecture is clear, with well-defined module divisions. Through standard industrial network communication, it is easy to modify and integrate with existing cigarette packaging equipment, allowing for rapid deployment and convenient maintenance.

[0089] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.

Claims

1. An online detection method for the steel stamp on cigarette packs based on AI vision and information integration, characterized in that: include, The host computer determines the production batch identifier based on the cigarette pack brand information read by the QR code reader, the current system date, and the work order shift information obtained from the data acquisition system. Based on the production batch identifier, it retrieves the target process stamp code from the process database and sends it to the programmable logic controller for storage via the communication network. The programmable logic controller receives signals from the original shaft encoder and the No. 8 wheel cigarette pack counter in real time. It calculates the timing of the cigarette pack arriving at the detection station through the logic combination of the shift register and sends a trigger signal. The image sensor acquires the stamp image under the control of the trigger signal and transmits the image to the industrial smart camera. The industrial smart camera uses the built-in AI OCR engine to recognize characters in the stamp image, obtains the actual stamp character sequence, and sends it to the programmable logic controller. The programmable logic controller compares the actual stamp character sequence with the pre-stored target process stamp code bit by bit. Adaptive detection and hierarchical control are implemented. The quality of the stamp is determined by logical AND operation based on the bit-by-bit comparison results. When the number of consecutive abnormalities reaches the preset first consecutive threshold, a level one alarm is triggered. When the number of consecutive abnormalities reaches the preset second consecutive threshold, a level two response control is triggered to automatically stop the production line.

2. The online detection method for cigarette box stamps based on AI vision and information integration as described in claim 1, characterized in that: The method for generating the target process stamp code is as follows: Two sets of steel stamp coding rules associated with brand attributes are pre-built. The first coding rule applies to self-produced brands, and the coding sequence consists of shift identifier, year identifier, month identifier, date identifier and machine number identifier in sequence. The second coding rule applies to cooperative processing brands, and the coding sequence consists of year identifier, month identifier, date identifier, shift identifier, machine number identifier and factory code identifier in sequence. The host computer selects the coding rule based on the acquired brand information, and fills in and splices the acquired year, month, day, shift, machine number and factory code according to the sequence of the coding rule to dynamically generate a unique target process stamp code for the current production batch.

3. The online detection method for cigarette box stamps based on AI vision and information integration as described in claim 1, characterized in that: The calculation of when the cigarette pack arrives at the inspection station includes: Create a shift register array with a length equal to the total number of cigarette packs at the camera station plus 1 from the eighth wheel counter and initialize it to zero; When the phase of the counter on wheel number eight arrives, the first element of the array is assigned a value of 1 or 0 depending on whether a cigarette pack is detected, and then the array is shifted one bit to the right. When the camera triggers the phase, check if the last element of the array is 1. If it is 1, trigger the camera to capture the data. By using encoder signal synchronization shifting operation, the travel distance of the tobacco pack state in the array is kept synchronized with the actual tobacco pack conveying distance.

4. The online detection method for cigarette box stamps based on AI vision and information integration as described in claim 1, characterized in that: The OCR engine includes a continuous learning mechanism for model optimization; The system automatically collects misidentified samples and builds an incremental dataset. When the accumulated samples reach a preset threshold, the model is incrementally trained in an offline environment using elastic weight consolidation or adapter mode. After training, the model is compressed and remotely deployed to a smart camera for periodic iterative updates.

5. The online detection method for cigarette box stamps based on AI vision and information integration as described in claim 4, characterized in that: The bit-by-bit comparison includes: The actual steel stamp character sequence extracted by identification is compared with the target process steel stamp code sequence character by character. If each character is the same, the comparison result is assigned a value of 1; otherwise, it is assigned a value of 0. Perform a logical AND operation on the comparison results of all bits. If the result is 1, the stamp quality is considered acceptable; if the result is 0, the stamp quality is considered unacceptable.

6. The online detection method for cigarette box stamps based on AI vision and information integration as described in claim 1, characterized in that: The adaptive detection and hierarchical control includes: During continuous production, the system automatically starts a self-inspection once the set quantity is produced. After the self-inspection starts, it checks the steel stamp of the first small box. If the actual steel stamp is consistent with the target process steel stamp, the system pauses the inspection and waits for the next self-inspection cycle. If the actual stamp does not match the target process stamp, continue to test subsequent small boxes until a match is detected, then stop this self-test. If the comparison reveals that the actual stamp is inconsistent with the target process stamp, and this inconsistency continues to exceed the set first continuous threshold, the system will trigger a level one alarm, but the production line will continue to run. If the abnormal state continues to occur and reaches the preset second continuous threshold, it is determined to be a valid defect, triggering a secondary response and controlling the production line to automatically stop.

7. An online detection system for cigarette pack stamps based on AI vision and information integration, based on the online detection method for cigarette pack stamps based on AI vision and information integration as described in any one of claims 1 to 6, characterized in that: include, The intelligent detection module, deployed next to the cigarette pack conveying channel, includes a dome-shaped lighting source, an image sensor, and an industrial intelligent camera with a built-in AI OCR engine. It is used to acquire images of the stamped steel stamp and identify the actual stamped steel stamp character sequence under the control of a trigger signal. The control and decision module, with a programmable logic controller as its core, is used to receive signals from the original machine shaft encoder and the No. 8 wheel cigarette pack counter, control the timing of taking pictures, receive the target process steel stamp and the identification results from the intelligent detection module sent by the host computer, compare and judge the quality, and control the operating status of the production equipment according to the judgment results. The information management and interaction module includes a host computer and a human-machine interaction touch screen. The host computer communicates with the QR code reader and data acquisition system to generate and issue target process steel stamps based on brand information, system date, and work order shift. The touch screen is used for real-time display and parameter setting. The communication network module integrates the intelligent detection module, control and decision-making module, information management and interaction module, QR code reader and data acquisition system into the same industrial local area network through an industrial switch.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, it implements the steps of the online detection method for cigarette box stamps based on AI vision and information integration as described in any one of claims 1 to 6.

9. A computer-readable 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 online detection method for the steel stamp of cigarette boxes based on AI vision and information integration as described in any one of claims 1 to 6.