A foreign body monitoring method and system for automatic laminating machine based on machine vision

Through an automatic stacker based on machine vision, combined with pixel dispersion algorithm and grayscale analysis, the problem of foreign object detection in lithium-ion battery manufacturing is solved, and accurate, real-time and economical detection effects are achieved, improving the safety of battery production and Quality control.

CN118628985BActive Publication Date: 2024-12-17DONGGUAN PENGLONG OPTOELECTRONICS LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411103162.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-13
Publication Date
2024-12-17
Estimated Expiration
2044-08-13

AI Technical Summary

Technical Problem

During the manufacturing process of lithium-ion batteries, foreign objects generated during loose parts or cutting during the lamination process are difficult to detect effectively, which affects battery performance and safety. Traditional deep learning methods have high calculation costs and long training cycles, which limit the flexibility of the production environment Sex and practicality.

Method used

Using an automatic lamination machine based on machine vision, the precision, real-time and cost-effectiveness of foreign object detection is achieved through precise matching of reference images, dynamic update of reference standards, efficient pixel-level analysis and comprehensive data integration, and the use of pixel discreteness The algorithm combines grayscale deviation analysis, gradient information extraction and distance weighting strategies to build an efficient and accurate detection method.

Benefits of technology

It significantly improves the quality control level of battery production, enhances the safety and reliability of the lithium-ion battery manufacturing industry, realizes the accuracy and real-time foreign object detection, reduces equipment costs, and ensures stability and accuracy in complex environments. Inspection forms a closed-loop monitoring system, supporting the efficient operation of the automated monitoring system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118628985B_ABST
    Figure CN118628985B_ABST
Patent Text Reader

Abstract

The present invention discloses a foreign body monitoring method and system for an automatic laminating machine based on machine vision, the method comprising: obtaining a first-layer reference image from a reference database based on the type of pole piece corresponding to the first layer, and obtaining an image to be detected in the current layer; detecting whether the image to be detected in the current layer is an image to be detected in the first layer, and determining a reference image; inputting the image to be detected in the current layer and the reference image into a preset foreign body monitoring algorithm based on pixel analysis, and obtaining single-layer foreign body monitoring data; when all layers are monitored, integrating all the single-layer foreign body monitoring data to obtain a foreign body monitoring report. The present invention effectively overcomes the limitations of traditional monitoring methods by accurately matching reference images, dynamically updating reference standards, efficient pixel-level analysis, and comprehensive data integration, and realizes accurate, real-time, and cost-effective foreign body detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of machine vision monitoring, and in particular to a foreign matter monitoring method and system of an automatic stacking machine based on machine vision. Background Art

[0002] In the manufacturing process of lithium-ion batteries, the lamination process is a crucial step, which involves precisely stacking the cathode sheets, anode sheets and separators in a specific order to form the main structure of the battery. However, this process is not without challenges. There are some problems that are difficult to ignore during the lamination process, especially the loose and falling parts or the debris generated during the cutting of the pole sheets, which may lead to the generation of foreign matter. The presence of foreign matter not only affects the performance of the battery, such as capacity, cycle life and safety, but also may cause serious safety hazards, such as short circuit or thermal runaway events.

[0003] Traditionally, the detection and identification of foreign objects relies on advanced artificial intelligence technologies such as deep learning to identify anomalies in images by training neural network models. However, this approach faces a series of challenges in practical applications, including high computing costs, long model training cycles, and reliance on large data sets, which limit its flexibility and practicality in production environments. Summary of the invention

[0004] In order to solve at least one of the technical problems mentioned above, the present invention provides a foreign body monitoring method for an automatic stacking machine based on machine vision, which effectively overcomes the limitations of traditional monitoring methods by accurately matching reference images, dynamically updating reference standards, efficient pixel-level analysis and comprehensive data integration, and realizes precise, real-time and cost-effective foreign body detection.

[0005] In one aspect, the present invention provides a foreign body monitoring method for an automatic stacking machine based on machine vision, the method comprising:

[0006] Based on the type of the electrode corresponding to the first layer, the first layer reference image is obtained from the reference database, and the image of the electrode diaphragm of the current layer is collected to obtain the image to be detected of the current layer;

[0007] Detect whether the current layer of the image to be detected is the first layer of the image to be detected. If so, determine the first layer of the reference image as the reference image. If not, determine the image covered by the last layer of the electrode diaphragm as the reference image.

[0008] Inputting the current layer to-be-detected image and the reference image into a preset foreign body monitoring algorithm based on pixel analysis to obtain single-layer foreign body monitoring data;

[0009] When all layers are monitored, all the single-layer foreign matter monitoring data are integrated to obtain a foreign matter monitoring report.

[0010] As a preferred solution, the current layer to-be-detected image and the reference image are input into a preset foreign body monitoring algorithm based on pixel analysis to obtain single-layer foreign body monitoring data, including:

[0011] Grayscale the current layer image to be detected and the reference image;

[0012] Calculating the difference between the current layer image to be detected and the reference image after grayscale processing pixel by pixel to obtain a difference image;

[0013] Calculating the discreteness of the difference image based on a preset pixel discreteness algorithm to obtain the difference discreteness;

[0014] The difference dispersion and a preset first foreign body dispersion threshold are compared and analyzed to obtain the single-layer foreign body monitoring data.

[0015] As a preferred solution, the calculation process of the pixel discreteness algorithm is as follows:

[0016] ,

[0017] ,

[0018] in, For the The discreteness of the layer difference image, For the The number of pixels in the layer difference image, For the The average gray value of all pixels in the layer difference image, For the Layer Difference Image Reconstruction The gray value of a pixel, Indicates The gradient amplitude of the pixel with the largest gradient amplitude on the line segment connecting the pixel point and the central pixel point, Indicates The Euclidean distance between each pixel and the center pixel is Indicates Layer Difference Image Reconstruction The position weight of each pixel.

[0019] As a preferred solution, after calculating the difference between the current layer image to be detected and the reference image after the grayscale processing pixel by pixel, the method further comprises:

[0020] Perform clustering processing on the calculated difference data to obtain multiple category clusters;

[0021] The average grayscale value of the pixels in the category cluster is calculated, and the average grayscale value is used as the grayscale value of the pixels in the category cluster.

[0022] As a preferred solution, the comparison and analysis of the difference discreteness and a preset first foreign body discreteness threshold to obtain the single-layer foreign body monitoring data includes:

[0023] Monitoring whether the difference dispersion is less than the first foreign body dispersion threshold;

[0024] If so, determining that there is a foreign object in the current layer of the image to be detected;

[0025] If not, it is determined that there is no foreign matter in the current layer of the image to be detected.

[0026] As a preferred solution, when it is detected that there is a foreign object in the current layer of the image to be detected, the lamination process is stopped and a foreign object alarm is triggered.

[0027] As a preferred solution, the integration of all the single-layer foreign body monitoring data to obtain a foreign body monitoring report includes:

[0028] Counting the number of difference images corresponding to the difference discreteness being less than a preset second foreign body discreteness threshold, where the second foreign body discreteness threshold is greater than the first foreign body discreteness threshold;

[0029] If the counted number is greater than the preset number threshold, after the current stacking process is completed, the current automatic stacking machine is suspended and equipment maintenance is performed.

[0030] In a second aspect, the present invention provides a foreign body monitoring system for an automatic stacking machine based on machine vision, the system comprising:

[0031] The data acquisition module to be detected is used to obtain the first layer reference image from the reference database based on the electrode type corresponding to the first layer, collect the image of the current layer after the electrode diaphragm is covered, and obtain the image to be detected of the current layer;

[0032] A reference data acquisition module is used to detect whether the current layer of the image to be detected is the first layer of the image to be detected. If so, the first layer of the reference image is determined as the reference image. If not, the image covered by the last layer of the electrode diaphragm is determined as the reference image.

[0033] A data processing module, used for inputting the current layer to-be-detected image and the reference image into a preset foreign body monitoring algorithm based on pixel analysis to obtain single-layer foreign body monitoring data;

[0034] The data integration module is used to integrate all the single-layer foreign body monitoring data after all layers are monitored to obtain a foreign body monitoring report.

[0035] As a preferred solution, the data processing module includes:

[0036] An image graying unit, used for graying the current layer image to be detected and the reference image;

[0037] An image difference unit is used to calculate the difference between the current layer to be detected image and the reference image after grayscale processing pixel by pixel to obtain a difference image;

[0038] An image discreteness calculation unit, used to calculate the discreteness of the difference image based on a preset pixel discreteness algorithm to obtain a difference discreteness;

[0039] The image discreteness comparison unit is used to compare and analyze the difference discreteness and a preset first foreign body discreteness threshold to obtain the single-layer foreign body monitoring data.

[0040] As a preferred solution, the data integration module includes:

[0041] a discreteness value statistical unit, used for counting the number of difference images corresponding to the difference discreteness being less than a preset second foreign body discreteness threshold, where the second foreign body discreteness threshold is greater than the first foreign body discreteness threshold;

[0042] The equipment early warning unit is used to suspend the operation of the current automatic stacking machine and perform equipment maintenance after completing the current stacking process if the statistical quantity is greater than a preset quantity threshold.

[0043] The beneficial effects of the present invention are:

[0044] (1) The present invention effectively overcomes the limitations of traditional monitoring methods by accurately matching reference images, dynamically updating reference standards, efficient pixel-level analysis, and comprehensive data integration, achieving accurate, real-time, and cost-effective foreign body detection, forming a closed-loop monitoring system, significantly improving the quality control level of battery production, and providing a strong guarantee for the safety and reliability of the lithium-ion battery manufacturing industry;

[0045] (2) The present invention constructs an efficient and accurate foreign body detection method by cleverly combining grayscale deviation analysis, gradient information extraction and distance weighting strategy through pixel discreteness algorithm design. It not only enhances the perception of changes in the central area of ​​the image and improves edge sensitivity, but also enhances the adaptability and robustness of the algorithm by comprehensively considering grayscale and gradient information, ensuring that the algorithm can stably and accurately detect foreign bodies in various complex environments, significantly improving the efficiency and quality of image analysis, and providing strong technical support for automated monitoring systems;

[0046] (3) The present invention constructs an effective equipment operation status monitoring and maintenance decision-making process through statistical analysis of difference discreteness and a threshold-based decision-making mechanism. From the early identification of minor abnormalities (such as diaphragm wrinkles or diaphragm bubbles, which are not sufficient to immediately trigger a foreign object alarm, but may have a negative impact on equipment performance due to long-term accumulation) to the execution of preventive maintenance, a closed loop is formed between each step, which ensures the healthy operation of the equipment and the production quality and efficiency. This data-based decision-making mechanism not only improves the accuracy and timeliness of equipment maintenance, but also promotes the continuous optimization of the production process. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the background technology, the drawings required for use in the embodiments of the present invention or the background technology will be described below.

[0048] The drawings herein are incorporated into the specification and constitute a part of the specification. These drawings illustrate embodiments consistent with the present disclosure and, together with the specification, are used to illustrate the technical solutions disclosed in the present invention.

[0049] Figure 1 A schematic flow chart of a method for detecting foreign matter in an automatic stacking machine based on machine vision provided by an embodiment of the present invention;

[0050] Figure 2 A schematic diagram of a flow chart of a foreign body monitoring algorithm provided by an embodiment of the present invention;

[0051] Figure 3 A schematic diagram of a flow chart of a discreteness threshold comparison method provided in an embodiment of the present invention;

[0052] Figure 4 A schematic structural diagram of a foreign matter monitoring system for an automatic stacking machine based on machine vision provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0053] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0054] The terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units that are not listed, or may optionally include other steps or units that are inherent to these processes, methods, products or devices.

[0055] The term "and / or" herein is only a description of the association relationship of the associated objects, indicating that there may be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the term "at least one" herein represents any combination of at least two of any one or more of a plurality of. For example, including at least one of A, B, and C can represent including any one or more elements selected from the set consisting of A, B, and C.

[0056] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present invention. The appearance of the phrase in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.

[0057] In addition, in order to better illustrate the present invention, numerous specific details are provided in the following specific embodiments. It should be understood by those skilled in the art that the present invention can be implemented without certain specific details. In some examples, methods, means, components and circuits well known to those skilled in the art are not described in detail in order to highlight the subject matter of the present invention.

[0058] In the critical stacking process of lithium-ion battery manufacturing, the generation of foreign matter due to loose components or cutting debris becomes a major hidden danger affecting battery performance and safety. Currently, traditional deep learning detection methods are powerful but limited by high costs and lack of flexibility.

[0059] Embodiment 1, the present invention provides a foreign body monitoring method of an automatic stacking machine based on machine vision, referring to Figure 1 , the method comprising:

[0060] S100, obtaining a first-layer reference image from a reference database based on the type of electrode corresponding to the first layer, collecting an image of the current layer of electrode after being covered by a diaphragm, and obtaining an image to be detected of the current layer;

[0061] S200, detecting whether the current layer of the image to be detected is the first layer of the image to be detected, if so, determining the first layer of the reference image as the reference image, if not, determining the image covered by the last layer of the electrode diaphragm as the reference image;

[0062] S300, inputting the current layer to-be-detected image and the reference image into a preset foreign body monitoring algorithm based on pixel analysis to obtain single-layer foreign body monitoring data;

[0063] S400, when all layers are monitored, all single-layer foreign matter monitoring data are integrated to obtain a foreign matter monitoring report.

[0064] In this embodiment, when the automatic laminating machine processes the cathode and anode sheets, due to the differences in materials and colors between the two, it is necessary to ensure that the monitoring algorithm can adapt to such changes. Before the laminating process begins, the corresponding reference image is obtained from the pre-established reference database according to the type of the first-layer electrode sheet (cathode or anode). The reference database contains standard images of cathode and anode sheets under various conditions to ensure that the subsequent comparison is targeted and accurate. Among them, the reference database is a collection of standard images of cathode and anode sheets under various conditions, which is used to compare the real-time images collected during the monitoring process to determine whether there are foreign objects. Further, it is determined whether the electrode sheet currently being processed is the first layer. If so, the first-layer reference image obtained from the database is used as a reference; if not, the image covered by the diaphragm of the previous layer of electrode sheets is used as a new reference image for real-time comparison. It should be noted that the reference image is dynamically adjusted according to the actual situation of the current layer to ensure that each comparison is based on the closest background conditions. Dynamic update of the reference image can adapt to environmental changes that may occur during the laminating process in real time, such as light, position fine-tuning, etc., thereby ensuring the stability and reliability of the monitoring results. Then, a foreign body monitoring algorithm based on pixel analysis is used. This algorithm directly compares the difference between the current layer image to be detected and the reference image at the pixel level, and determines whether there is a foreign body by setting a threshold. The foreign body monitoring algorithm based on pixel analysis is a method that does not require a deep learning model and directly identifies foreign bodies by comparing the pixel values ​​of the image. It relies more on image processing technology and mathematical statistics. Compared with deep learning, the method based on pixel analysis has a small amount of calculation and a fast response speed. It is especially suitable for real-time monitoring scenarios, reducing the cost and maintenance difficulty of the equipment, while avoiding the complexity of deep learning model training and optimization. After completing the monitoring of all layers, the system summarizes and analyzes the foreign body monitoring data of each layer and generates a final foreign body monitoring report. The report records the monitoring results of each layer in detail, including the location, size and type of foreign bodies. The integration of all single-layer foreign body monitoring data can not only provide a comprehensive distribution of foreign bodies, but also help engineers quickly locate problem areas and take timely measures to improve production quality and efficiency.

[0065] This embodiment effectively overcomes the limitations of traditional monitoring methods by accurately matching reference images, dynamically updating reference standards, efficient pixel-level analysis, and comprehensive data integration, achieving precise, real-time, and cost-effective foreign body detection, forming a closed-loop monitoring system, and significantly improving the quality control level of battery production, providing a strong guarantee for the safety and reliability of the lithium-ion battery manufacturing industry.

[0066] As a preferred solution, the current layer to be detected image and the reference image are input into the preset foreign body monitoring algorithm based on pixel analysis to obtain the single layer foreign body monitoring data. Figure 2 ,include:

[0067] S310, graying the current layer image to be detected and the reference image;

[0068] S320, calculating the difference between the current layer image to be detected and the reference image after grayscale processing pixel by pixel, and obtaining a difference image;

[0069] S330, calculating the discreteness of the difference image based on a preset pixel discreteness algorithm to obtain the difference discreteness;

[0070] S340, comparing and analyzing the difference discreteness and a preset first foreign body discreteness threshold to obtain single-layer foreign body monitoring data.

[0071] Grayscale processing is a process of converting a color image into a grayscale image, the purpose of which is to simplify image information and reduce computational complexity. In this embodiment, grayscale is achieved by weighted averaging of the RGB color channels, for example, , where R, G, and B represent the intensity of the three color channels of red, green, and blue, respectively. After the grayscale processing, the difference between the current layer of the image to be detected and the reference image will be calculated pixel by pixel to generate a difference image. This process involves the numerical subtraction of the corresponding pixel points of the two grayscale images, and the result reflects the pixel difference between the images. The discreteness of the difference image is calculated based on the preset pixel discreteness algorithm to obtain the difference discreteness. The pixel discreteness algorithm can be the standard deviation or variance in statistics, etc., which is used to quantify the degree of fluctuation of the pixel value in the image. The process of calculating the difference discreteness is to quantify the discreteness of all pixel values ​​in the difference image, so as to evaluate the overall change amplitude of the image. The calculated difference discreteness is compared and analyzed with the preset first foreign body discreteness threshold. If the difference discreteness exceeds the threshold, it indicates that there may be foreign matter in the layer, otherwise it is considered that there is no foreign matter. This threshold is determined based on historical data and experiments, and is intended to distinguish normal variation from abnormal changes to ensure the accuracy and sensitivity of foreign body monitoring.

[0072] In this embodiment, the generation of the difference image intuitively shows the difference between the current layer image and the reference image, which facilitates the subsequent discreteness calculation to focus on the truly meaningful change area and avoids the interference of background noise. Furthermore, the calculation of the difference discreteness quantifies the degree of image difference, which helps to objectively evaluate whether the image change is caused by foreign matter and avoids the uncertainty of subjective judgment. Compared with the complex deep learning model, the algorithm based on pixel analysis has a small amount of calculation and a fast response time, which is suitable for real-time monitoring scenarios. At the same time, it also reduces the demand for computing resources and improves economy. In general, this embodiment effectively removes irrelevant variables through precise grayscale processing; accurately captures the signal of potential foreign matter through the calculation and discreteness analysis of the difference image; and finally ensures the reliability and effectiveness of the monitoring results through threshold comparison. This process not only improves the efficiency and accuracy of foreign matter detection, but also takes into account real-time and economy, providing strong technical support for foreign matter monitoring on automated production lines and significantly improving product quality and production efficiency.

[0073] As a preferred solution, the calculation process of the pixel discreteness algorithm is as follows:

[0074] ,

[0075] ,

[0076] in, For the The discreteness of the layer difference image, For the The number of pixels in the layer difference image, For the The average gray value of all pixels in the layer difference image, For the Layer Difference Image Reconstruction The gray value of a pixel, Indicates The gradient amplitude of the pixel with the largest gradient amplitude on the line segment connecting the pixel point and the central pixel point, Indicates The Euclidean distance between each pixel and the center pixel is Indicates Layer Difference Image Reconstruction The position weight of each pixel.

[0077] In this embodiment, first, each pixel is calculated Relative to the average gray value The absolute deviation of the jth pixel and the center pixel is found to obtain the maximum gradient value on the line connecting the jth pixel and the center pixel. , and multiply by the position weight , position weight As the distance between the pixel and the center point increases The increase of , ensures that the change contribution of the central area is greater, and then, the above two items are added, that is, , sum all pixels and divide by the total number of pixels , and the final discreteness is obtained This algorithm combines the absolute deviation of the pixel gray value and the maximum gradient of the position weight, and obtains the first Discreteness of layer difference images .

[0078] Among them, The gradient amplitude of the pixel with the largest gradient amplitude on the line segment connecting the pixel and the central pixel The calculation process is as follows:

[0079] Determine the center pixel of the block and calculate the pixel The straight line path to the center pixel of the block is used to calculate the gradient amplitude for each pixel on this path. The gradient amplitude can be obtained by calculating the gradient of the gray value of the pixel. A common method is to use the Sobel operator or the Prewitt operator to find the pixel with the largest gradient amplitude among all the pixels on the path. The gradient amplitude is ,in, , where Indicates location The image gradient at can be estimated by calculating the difference between the grayscale value of the point in the x direction and the y direction. It's a pixel The set of pixels on the straight line path to the center pixel of the block. The above formula can be used to calculate the The maximum gradient magnitude on the path to the block center , and then evaluate the local clutter level of the image.

[0080] In this embodiment, a pixel discreteness algorithm is designed to cleverly combine grayscale deviation analysis, gradient information extraction and distance weighting strategy to construct an efficient and accurate foreign body detection method. It not only enhances the perception of changes in the central area of ​​the image and improves edge sensitivity, but also enhances the adaptability and robustness of the algorithm by comprehensively considering grayscale and gradient information, ensuring that the algorithm can stably and accurately detect foreign bodies in various complex environments, significantly improving the efficiency and quality of image analysis, and providing strong technical support for automated monitoring systems.

[0081] As a preferred solution, after calculating the difference between the current layer image to be detected and the reference image after grayscale processing pixel by pixel, it includes:

[0082] Perform clustering processing on the calculated difference data to obtain multiple category clusters;

[0083] Calculate the average gray value of the pixels in the category cluster and use the average gray value as the gray value of the pixels in the category cluster.

[0084] The purpose of clustering is to classify pixels with similar grayscale values ​​into the same group, i.e., a category cluster, so as to reduce the complexity of subsequent processing and improve the efficiency of the algorithm and the accuracy of recognition. In this embodiment, an appropriate clustering algorithm (such as K-means) is selected, and the number of category clusters is determined based on experience or preset parameters. The grayscale value of each pixel in the calculated difference data is used as its feature and assigned to the nearest category cluster. The center point of the category cluster is adjusted iteratively until the pixels in the category cluster are no longer redistributed or the predetermined number of iterations is reached. After clustering is completed, the average grayscale value of the pixels in each category cluster is calculated, and then the original grayscale values ​​of all pixels in the cluster are replaced with this average value to reduce noise and enhance the stability of foreign body detection. By averaging the grayscale values ​​of all pixels in each category cluster, the calculated average grayscale value is assigned to each pixel in the category cluster, replacing the original grayscale value. Among them, clustering processing can classify pixels with similar grayscale values ​​into one category. In this way, even if some pixels are affected by noise, by calculating the average grayscale value, this influence can be offset to a certain extent, thereby improving the signal-to-noise ratio of the image. The average grayscale value replacement makes the grayscale values ​​of pixels in the image more consistent, reducing the fluctuation of grayscale values. For those foreign objects that are difficult to identify in a noisy environment, the recognition stability is improved by enhancing the consistency of their features.

[0085] In this embodiment, noise suppression is achieved through clustering processing and average gray value calculation, which improves the stability and efficiency of foreign object recognition and enhances the expression of image features. Clustering processing first classifies pixels according to gray values, reducing the complexity of processing, while the calculation of average gray value further improves the signal-to-noise ratio and feature consistency of the image, making foreign objects more prominent in the image and easier to identify.

[0086] As a preferred solution, the difference dispersion and the preset first foreign body dispersion threshold are compared and analyzed to obtain the single-layer foreign body monitoring data. Figure 3 ,include:

[0087] S341, monitoring whether the difference dispersion is less than a first foreign body dispersion threshold;

[0088] S342, if yes, determine that there is foreign matter in the current layer of the image to be detected;

[0089] S343: If not, determine that there is no foreign matter in the current layer of the image to be detected.

[0090] In a normal lamination process, there should be a certain difference in the pixel values ​​between layers to reflect the natural changes in the material. Therefore, when the discreteness of a certain layer is monitored to be abnormally low, it is actually an abnormal phenomenon, indicating that the pixel values ​​of the image of this layer are abnormally consistent and exceed the normal range. This abnormally low discreteness is likely due to occlusion or interference from foreign objects, causing the pixel values ​​of a certain part of the image to be forced to be flattened, thereby losing the due difference. Therefore, the lower the discreteness, the more it deviates from normal expectations, and the greater the probability of the presence of foreign objects, indicating that further inspection and processing are needed to ensure production quality and safety.

[0091] In the above processing, the difference image between the current layer of the image to be detected and the reference image has been calculated through the pixel analysis algorithm, and the discreteness describing the degree of pixel difference has been further obtained. A first foreign body discreteness threshold is preset, which is based on a large amount of experimental data and historical case analysis, and is used to distinguish normal changes from abnormal changes caused by foreign bodies. The calculated difference discreteness is compared with the first foreign body discreteness threshold. If the difference discreteness is less than the first foreign body discreteness threshold, it is considered that the current layer of the image to be detected has changes beyond the norm, and there may be foreign bodies; conversely, if the difference discreteness is greater than or equal to the threshold, it is considered that the image changes are within a reasonable range and no foreign bodies are detected.

[0092] In this embodiment, by presetting the first foreign matter discreteness threshold, the pixel differences caused by normal process changes and the abnormal changes caused by foreign matter can be effectively distinguished, thereby improving the accuracy of foreign matter detection. The steps of comparing and analyzing the difference discreteness and the threshold are simple and clear, and the conclusion of whether there are foreign matters in the current layer of the image to be detected can be drawn in a short time, thereby accelerating the decision-making process of foreign matter monitoring.

[0093] As a preferred solution, when it is detected that there is a foreign object in the current layer of the image to be detected, the lamination process is stopped and a foreign object alarm is triggered.

[0094] In this embodiment, during the lamination process, once foreign matter is detected in the current layer of images to be inspected, measures are immediately taken to prevent potential production defects from continuing to spread, thereby ensuring product quality and production safety. Each layer of images to be inspected is continuously monitored, and the presence of foreign matter is evaluated in real time through the aforementioned pixel analysis algorithm and discreteness threshold judgment. Once the difference discreteness of a certain layer is found to exceed the preset first foreign matter discreteness threshold, the system immediately confirms the presence of foreign matter, sends instructions to the laminating machine, and immediately stops the current lamination process to prevent foreign matter from being further encapsulated in the battery assembly. At the same time, the foreign matter alarm system is activated, and an alarm is issued to the on-site operator through sound, light or screen prompts, indicating the specific location of the foreign matter so that quick action can be taken. In this embodiment, by real-time monitoring and immediate stopping of the lamination process, components with foreign matter are effectively prevented from entering the subsequent production stage, avoiding the continuous occurrence of defective products on the production line, and reducing production waste and cost losses.

[0095] As a preferred solution, all single-layer foreign body monitoring data are integrated to obtain a foreign body monitoring report, including:

[0096] The number of difference images corresponding to the statistical difference dispersion being less than a preset second foreign body dispersion threshold, and the second foreign body dispersion threshold being greater than the first foreign body dispersion threshold;

[0097] If the counted number is greater than the preset number threshold, after the current stacking process is completed, the current automatic stacking machine is suspended and equipment maintenance is performed.

[0098] During the lamination process, the number of difference images with difference discreteness less than the second foreign matter discreteness threshold is counted to evaluate the operating status of the lamination machine, and potential problems that may affect production quality, such as diaphragm wrinkles or diaphragm bubbles, are discovered in time to decide whether the equipment needs to be suspended for maintenance.

[0099] During the stacking process, each layer of images to be detected is continuously monitored, and the number of all difference images whose difference discreteness is less than the second foreign body discreteness threshold is recorded. The second foreign body discreteness threshold is set higher than the first foreign body discreteness threshold, which means that it is used to identify those minor anomalies that do not constitute direct foreign bodies but may indicate poor equipment operation. The number of difference images counted is compared with the preset number threshold. The number threshold is set based on historical data and equipment operation experience, and is used to determine whether the equipment needs maintenance. If the number of difference images counted exceeds the preset number threshold, the system will automatically pause the operation of the stacking machine after the current stacking process ends, and trigger the equipment maintenance procedure. This step ensures that production will not be suddenly interrupted without completing the current batch, and also avoids greater losses caused by the operation of the equipment with problems.

[0100] In this embodiment, by counting the number of difference images whose difference discreteness is less than the second foreign body discreteness threshold, minor anomalies that may affect product quality, such as membrane wrinkles or membrane bubbles, can be identified in advance. Although these anomalies are not enough to immediately trigger a foreign body alarm, long-term accumulation may have a negative impact on equipment performance. The decision-making mechanism based on the quantity threshold enables the equipment to be maintained in time before the problem worsens, avoiding unplanned downtime caused by sudden failures and reducing the risk of production interruption. By timely identifying and handling minor anomalies that may affect product quality, the continuity of the lamination process and the high quality of the product are ensured, and the increase in the defective rate is avoided. In general, this embodiment constructs an effective equipment operation status monitoring and maintenance decision-making process through statistical analysis of difference discreteness and a decision-making mechanism based on thresholds. From the early identification of minor anomalies to the execution of preventive maintenance, a closed loop is formed between each step, which not only ensures the healthy operation of the equipment, but also guarantees production quality and efficiency. This data-based decision-making mechanism not only improves the accuracy and timeliness of equipment maintenance, but also promotes the continuous optimization of the production process.

[0101] Embodiment 2, the present invention provides a foreign body monitoring system for an automatic stacking machine based on machine vision, referring to Figure 4 , the system includes:

[0102] The module 100 for acquiring data to be detected is used to acquire the reference image of the first layer from the reference database based on the type of the electrode piece corresponding to the first layer, collect the image of the electrode piece of the current layer after being covered by the diaphragm, and obtain the image of the current layer to be detected;

[0103] The reference data acquisition module 200 is used to detect whether the current layer of the image to be detected is the first layer of the image to be detected. If so, the first layer of the reference image is determined as the reference image. If not, the image covered by the last layer of the electrode diaphragm is determined as the reference image.

[0104] The data processing module 300 is used to input the current layer to-be-detected image and the reference image into a preset foreign body monitoring algorithm based on pixel analysis to obtain single-layer foreign body monitoring data;

[0105] The data integration module 400 is used to integrate all the single-layer foreign matter monitoring data after all layers are monitored to obtain a foreign matter monitoring report.

[0106] As a preferred solution, the data processing module includes:

[0107] An image graying unit, used for graying the current layer of the image to be detected and the reference image;

[0108] The image difference unit is used to calculate the difference between the current layer image to be detected and the reference image after grayscale processing pixel by pixel to obtain a difference image;

[0109] An image discreteness calculation unit, used to calculate the discreteness of the difference image based on a preset pixel discreteness algorithm to obtain the difference discreteness;

[0110] The image discreteness comparison unit is used to compare and analyze the difference discreteness and the preset first foreign body discreteness threshold to obtain single-layer foreign body monitoring data.

[0111] As a preferred solution, the data integration module includes:

[0112] A discreteness value statistical unit, used for counting the number of difference images corresponding to a difference discreteness less than a preset second foreign body discreteness threshold, where the second foreign body discreteness threshold is greater than the first foreign body discreteness threshold;

[0113] The equipment early warning unit is used to suspend the operation of the current automatic stacking machine and perform equipment maintenance after completing the current stacking process if the statistical quantity is greater than a preset quantity threshold.

[0114] The above is only a specific embodiment of the present invention, so that those skilled in the art can understand or implement the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but should conform to the widest scope consistent with the principles and novel features applied herein.

Claims

1. A foreign body monitoring method for an automatic stacking machine based on machine vision, characterized in that: The method comprises: Based on the type of the electrode corresponding to the first layer, the first layer reference image is obtained from the reference database, and the image of the electrode of the current layer after being covered by the diaphragm is collected to obtain the image to be detected in the current layer. The electrode type is cathode or anode, and the reference database contains standard images of cathode and anode under various conditions; Detect whether the current layer of the image to be detected is the first layer of the image to be detected. If so, determine the first layer of the reference image as the reference image. If not, determine the image covered by the last layer of the electrode diaphragm as the reference image. Grayscale the current layer image to be detected and the reference image; Calculating the difference between the current layer image to be detected and the reference image after grayscale processing pixel by pixel to obtain a difference image; Calculating the discreteness of the difference image based on a preset pixel discreteness algorithm to obtain the difference discreteness; Comparing and analyzing the difference discreteness and a preset first foreign body discreteness threshold, to obtain single-layer foreign body monitoring data; When all layers are monitored, all the single-layer foreign body monitoring data are integrated to obtain a foreign body monitoring report, which includes the location, size and type information of the foreign body; The step of calculating the difference between the grayscale processed image of the current layer to be detected and the reference image pixel by pixel includes: Perform clustering on the calculated difference data to obtain multiple category clusters; Calculating the average grayscale value of the pixels in the category cluster, and using the average grayscale value as the grayscale value of the pixels in the category cluster; The comparing and analyzing the difference discreteness and a preset first foreign body discreteness threshold to obtain the single-layer foreign body monitoring data includes: Monitoring whether the difference dispersion is less than the first foreign body dispersion threshold; If so, determining that there is a foreign object in the current layer of the image to be detected; If not, determining that there is no foreign matter in the current layer of the image to be detected; Wherein, the integration of all the single-layer foreign body monitoring data to obtain a foreign body monitoring report includes: Counting the number of difference images corresponding to the difference discreteness being less than a preset second foreign body discreteness threshold, where the second foreign body discreteness threshold is greater than the first foreign body discreteness threshold; If the counted number is greater than the preset number threshold, after the current stacking process is completed, the current automatic stacking machine is suspended and equipment maintenance is performed.

2. The foreign body monitoring method of the automatic stacking machine based on machine vision according to claim 1 is characterized in that: The calculation process of the pixel discreteness algorithm is as follows: , , in, For the The discreteness of the layer difference image, For the The number of pixels in the layer difference image, For the The average gray value of all pixels in the layer difference image, For the Layer difference image The gray value of a pixel, Indicates The gradient amplitude of the pixel with the largest gradient amplitude on the line segment connecting the pixel point and the central pixel point, Indicates The Euclidean distance between each pixel and the center pixel is Indicates Layer difference image The position weight of each pixel.

3. The foreign body monitoring method of the automatic stacking machine based on machine vision according to claim 2 is characterized in that: When it is detected that there is a foreign object in the image to be detected in the current layer, the lamination process is stopped and a foreign object alarm is triggered.

4. A foreign body monitoring system for an automatic stacking machine based on machine vision, using a foreign body monitoring method for an automatic stacking machine based on machine vision as claimed in any one of claims 1 to 3, characterized in that: The system comprises: The data acquisition module to be detected is used to obtain the first layer reference image from the reference database based on the electrode type corresponding to the first layer, collect the image of the current layer after the electrode diaphragm is covered, and obtain the image to be detected of the current layer; A reference data acquisition module is used to detect whether the current layer of the image to be detected is the first layer of the image to be detected. If so, the first layer of the reference image is determined as the reference image. If not, the image covered by the last layer of the electrode diaphragm is determined as the reference image. A data processing module, used for inputting the current layer to-be-detected image and the reference image into a preset foreign body monitoring algorithm based on pixel analysis to obtain single-layer foreign body monitoring data; The data integration module is used to integrate all the single-layer foreign body monitoring data after all layers are monitored to obtain a foreign body monitoring report.

5. The foreign body monitoring system of the automatic stacking machine based on machine vision according to claim 4 is characterized in that: The data processing module comprises: An image graying unit, used for graying the current layer image to be detected and the reference image; An image difference unit is used to calculate the difference between the current layer to be detected image and the reference image after grayscale processing pixel by pixel to obtain a difference image; An image discreteness calculation unit, used to calculate the discreteness of the difference image based on a preset pixel discreteness algorithm to obtain a difference discreteness; The image discreteness comparison unit is used to compare and analyze the difference discreteness and a preset first foreign body discreteness threshold to obtain the single-layer foreign body monitoring data.

6. The foreign body monitoring system of the automatic stacking machine based on machine vision according to claim 5, characterized in that: The data integration module includes: a discreteness value statistical unit, used for counting the number of difference images corresponding to the difference discreteness being less than a preset second foreign body discreteness threshold, where the second foreign body discreteness threshold is greater than the first foreign body discreteness threshold; The equipment early warning unit is used to suspend the operation of the current automatic stacking machine and perform equipment maintenance after completing the current stacking process if the statistical quantity is greater than a preset quantity threshold.