Machine vision driven telescopic pipe defect intelligent identification method and system
By combining an arched light source with a deep learning model, the efficiency and accuracy issues in the detection of telescopic straws are solved, achieving efficient and accurate automated detection. This adapts to the reflective and curved structures of straws, providing a complete intelligent recognition solution.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-29
- Publication Date
- 2026-04-10
AI Technical Summary
Existing technologies suffer from low detection efficiency, insufficient accuracy, and low level of intelligence when inspecting telescopic straws. In particular, they have limited ability to identify minute defects in complex backgrounds and are difficult to adapt to the reflective and curved structures of straws.
An arched light source is used for uniform illumination. Combined with a deep learning model and mean filtering technology, the arched light source enables multi-directional light incidence, reducing blind spots in detection. The deep learning model is used to intelligently identify defects in straws, including building a lightweight real-time detection model and a semi-supervised active learning mechanism, to achieve efficient identification of complex defects.
It achieves efficient, accurate, and automated detection of telescopic straws, reduces false alarms and false negatives, improves detection efficiency and robustness, and provides a complete intelligent identification solution that adapts to the special structure and defect patterns of telescopic straws.
Smart Images

Figure CN121830699A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of automated quality inspection technology for light industrial consumer goods, and in particular to a machine vision-driven intelligent identification method and system for defects in telescopic tubes. Background Technology
[0002] In the food packaging and consumer goods manufacturing sector, retractable straws made of materials such as plastic and silicone, commonly used in collapsible water cups and beverage packaging, are a common accessory. Their hygiene and surface quality directly affect consumers' health and user experience. During the production process, straws are prone to various defects such as stains, black spots, foreign matter adhesion, deformation, and burrs at the joints of the retractable structure.
[0003] Currently, the quality inspection of this type of straw faces the following challenges, which need to be addressed.
[0004] I. High reliance on manual visual inspection
[0005] At the end of the production line, sorting relies mainly on workers' visual inspection. This method has inherent drawbacks such as low efficiency, high cost, and inconsistent standards. Prolonged work can easily lead to visual fatigue, making it easy to miss tiny stains or internal contaminants, thus failing to guarantee consistent product quality.
[0006] II. Limitations of Traditional Machine Vision Inspection
[0007] To overcome the shortcomings of manual inspection, existing technologies employ online visual inspection processes on high-speed production lines to automatically and quickly identify surface defects such as black spots, single tubes, horizontal tubes, and deformations on the straw surface, replacing inefficient and inconsistent manual visual inspection. These online visual inspection processes primarily utilize industrial cameras and image processing algorithms; however, they still face significant bottlenecks in the following aspects.
[0008] 1. Material and shape challenges: Straws are usually made of plastic or silicone, and their surfaces are prone to reflection; their slender, hollow tubular structure and stretchable characteristics pose great difficulties in achieving imaging with no blind spots and uniform illumination.
[0009] 2. Defect diversity: Defects may appear on the outer surface, inner wall or expansion and contraction folds, and vary in shape, color and size. Traditional image processing algorithms based on fixed thresholds have poor adaptability and high false alarm and false negative rates.
[0010] 3. Lack of targeted solutions: Existing general-purpose visual inspection equipment is difficult to optimize for small, curved, flexible objects like straws. For example, Chinese invention patent CN211085433U, entitled "A straw defect detection device," uses simple transmitted light to detect blockages or macroscopic defects, but it is difficult to effectively deal with complex surface oil stains, scratches, and morphological defects, and it does not involve intelligent recognition for the special structure of "telescopic" straws.
[0011] Furthermore, in the field of academic research, such as "Machine vision inspection of plastic straws for quality control" (Journal of Food Engineering, 2021), although the application of machine vision in straw inspection is demonstrated, its core still relies on traditional image processing algorithms (such as edge detection and threshold segmentation), which have limited ability to identify complex defects with small and low contrast, and the algorithm is not robust enough.
[0012] In summary, the existing technology mainly has the following problems and defects:
[0013] 1. Low detection efficiency and automation: Manual detection methods cannot meet the needs of large-scale production in modern industry.
[0014] 2. Insufficient detection accuracy and robustness: Traditional machine vision methods have weak ability to identify small defects and low-contrast defects in complex backgrounds, and are easily affected by changes in lighting and workpiece pose.
[0015] 3. Fragmented technical solutions and low level of intelligence: Existing solutions either only solve imaging problems or only improve a single recognition algorithm. There is a lack of a complete and intelligent technical solution that deeply integrates dedicated imaging hardware and intelligent recognition software and is specifically designed for the geometry and surface characteristics of telescopic straws.
[0016] Therefore, there is an urgent need for a system and method that can adapt to the special structure of telescopic straws and achieve efficient, accurate, and automated intelligent detection of surface defects. Summary of the Invention
[0017] The technical problem to be solved by the present invention is to address the shortcomings of the prior art by providing a machine vision-driven intelligent identification method and system for defects in telescopic tubes. This machine vision-driven intelligent identification method and system for defects in telescopic tubes can perform automated intelligent detection of appearance defects in telescopic straws. By using an arched light source, it can solve the problems of low detection accuracy and poor robustness caused by the reflection of straw surface, tubular curved surface structure and diverse defect morphologies in traditional machine vision inspection schemes.
[0018] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is as follows:
[0019] A machine vision-driven intelligent identification method for defects in telescopic pipes includes the following steps.
[0020] Step 1: Position and transport the pipette to be inspected to the inspection station. During the transport process, the pipette to be inspected can vibrate or rotate in a circumferential direction.
[0021] Step 2: Use an arched light source to uniformly illuminate the pipette to be inspected at the inspection station.
[0022] Step 3: Collect N images of different sides of each pipette to be inspected located at the inspection station;
[0023] Step 4: Perform noise reduction, enhancement, and feature extraction preprocessing on each side image of the straw to be inspected.
[0024] Step 5: Divide straw defects into wrinkled and leaking defects and non-wrinkled and leaking defects; among them, wrinkled and leaking defects include wrinkled seal, wrinkled ball head, and leaking.
[0025] Step 6: Detect straw defects such as wrinkles and leaks using a deep learning model for straw defects. Specifically, this includes:
[0026] Step 6-1: Construct and train a deep learning model for straw defects. Its input is the image of the region of interest of the straw, and its output is the specific type of straw defects.
[0027] Step 6-2: Extract the region of interest (ROI) from each different side image of each preprocessed straw.
[0028] Step 6-3: Input the straw region of interest image extracted in Step 6-2 into the straw defect deep learning model constructed in Step 6-1, and output the specific type of straw defect.
[0029] Step 7: Use mean filtering to extract non-wrinkled or leaky tube appearance defects from N different side images of each tube after preprocessing, and analyze and calculate the specific type and location of non-wrinkled or leaky tube appearance defects.
[0030] In step 2, the arched opening angle α of the arched light source is 120°-180°, and the formula for calculating the coverage angle Ω of the arched light source is:
[0031] Ω = 2π(1 - cos(α / 2)).
[0032] A single arched light source can achieve multi-directional light incidence, reduce detection blind spots, achieve a ring-like lighting effect, and enable each point on the straw surface to obtain approximately uniform illumination, avoiding highlight spots and shadows.
[0033] In step 2, the arched light source ensures a uniform θ angle distribution across the surface of the straw, resulting in a nearly uniform I_diffuse value and avoiding the uneven brightness caused by variations in the θ angle in traditional light sources. Here, θ is the angle between the incident ray and the normal to the straw surface; I_diffuse is the intensity of diffused light received at the observation point, calculated using the following formula:
[0034]
[0035] In the formula, I0 is the incident light intensity.
[0036] k_d is the diffuse reflection coefficient of the straw.
[0037] In step 2, the arched light source can make the axial illuminance uniformity of the straw reach 95% or more.
[0038] In step 2, the arched light source increases the aperture value N, thereby enhancing the depth of field (DOF) and adapting to changes in the height of the eyedropper. The formula for calculating the depth of field (DOF) is:
[0039] DOF = 2·u²·N·c / f².
[0040] In the formula, u is the distance from the camera to the surface of the straw.
[0041] c is the diameter of the permissible circle of confusion.
[0042] f is the focal length of the camera lens.
[0043] In step 2, the arched light source, through uniform illumination, can increase the defect contrast C to 0.6~0.8.
[0044] In step 1, the straw to be inspected is a transparent telescopic tube, a semi-transparent semi-milky white telescopic tube, a drinking straw, or a completely milky white telescopic tube; in step 5, non-wrinkled tube appearance defects include disordered tubes, single inner tube, single outer tube, stacked tubes, horizontal tubes, inner tube not shrinking properly, empty tubes, ball head not protruding, constricted opening, foreign objects, black spots, and oil stains.
[0045] In step 7, mean filtering uses dynamic thresholding to extract non-wrinkled and leaky pipe appearance defects, and Blob analysis is used to calculate the specific type and location of non-wrinkled and leaky pipe appearance defects.
[0046] In step 1, a straw conveying unit is used to position and transport the straw to be inspected to the inspection station. The straw conveying unit includes a screw, a screw rotation drive device, and a baffle plate. There are several screws arranged in parallel, and each screw can rotate under the drive of the screw rotation drive device. The threaded groove of the screw can accommodate the straw to be inspected. The baffle plate is set on the outside of the screw and can limit the lateral position of the straw to be inspected.
[0047] A machine vision-driven intelligent identification system for defects in telescopic pipes includes a storage medium, wherein a computer program stored in the storage medium executes a machine vision-driven intelligent identification method for defects in telescopic pipes during runtime.
[0048] The present invention has the following beneficial effects:
[0049] 1. High efficiency and high automation: It realizes online, high-speed and fully automatic detection of telescopic straws, completely replacing inefficient manual visual inspection, and significantly improving production cycle and efficiency.
[0050] 2. High precision and robustness: The targeted multi-mode composite illumination scheme effectively overcomes the challenges of reflection and curved surface imaging; by utilizing a deep learning model, it can adaptively learn complex defect features, and has extremely high recognition accuracy and robustness for small, low-contrast defects and various defect types, significantly reducing false alarm and false negative rates.
[0051] 3. Systematic and specialized: It provides a complete technical solution from accurate imaging and intelligent recognition to automatic sorting. This solution is specifically optimized for the physical characteristics and defect patterns of telescopic straws, solving the problem of poor adaptability of general solutions.
[0052] 4. Data-driven management: The system can record the test results of each straw, enabling traceability and analysis of quality data, and providing data support for production process improvement. Attached Figure Description
[0053] Figure 1 The flowchart of a machine vision-driven intelligent identification method for defects in telescopic pipes according to the present invention is shown.
[0054] Figure 2 The image shows a physical diagram of a machine vision-driven intelligent identification system for defects in telescopic pipes according to the present invention.
[0055] Figure 3 An enlarged schematic diagram of the straw delivery unit in this invention is shown.
[0056] Figure 4 An enlarged schematic diagram of the arched light source in this invention is shown.
[0057] Figure 5 The diagram shows the interface schematic of the three-dimensional simulation identification of straw defects in this invention.
[0058] Figure 6 This diagram shows a statistical analysis interface for the straw defect types identified in this invention.
[0059] Among them are:
[0060] 10. Camera; 20. Arched light source;
[0061] 30. Straw conveying unit; 31. Screw; 32. Baffle plate;
[0062] 40. Material ejection mechanism; 50. Inspected suction tube. Detailed Implementation
[0063] The present invention will now be described in further detail with reference to the accompanying drawings and specific preferred embodiments.
[0064] In the description of this invention, it should be understood that the terms "left side," "right side," "upper part," "lower part," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. "First," "second," etc., do not indicate the importance of the components, and therefore should not be construed as a limitation of this invention. The specific dimensions used in this embodiment are only for illustrating the technical solution and do not limit the scope of protection of this invention.
[0065] like Figure 2 As shown, a machine vision-driven intelligent identification system for defects in telescopic tubes includes a camera 10, an arched light source 20, a suction tube conveying unit 30, a material kicking mechanism 40, and a computer.
[0066] The straw conveying unit described above can position and transport the straws to be inspected, and has an inspection station. The straw conveying unit preferably includes a screw 31, a screw rotation drive device, and a baffle plate 32.
[0067] The screw has several screws arranged in parallel, and each screw can rotate under the drive of the screw rotation drive device; the screw thread groove can accommodate the suction tube 50 to be inspected.
[0068] In this embodiment, the straw conveying unit has two sets arranged in parallel, and each set of straw conveying units includes two screws, such as... Figure 3 As shown, the screw pitch is preferably 16, 19, or 20 mm, and the screw thread diameter is preferably 30 mm.
[0069] A baffle plate is installed at the detection station outside the screw to limit the lateral position of the suction tube to be inspected. The length L of the suction tube 50 to be inspected is preferably 91 mm. One end of the suction tube is aligned with the baffle plate, and the other end preferably extends beyond the screw by 91-77=14 mm.
[0070] When the screw rotates around its own axis, the suction tube to be inspected, located in the thread groove, can vibrate or rotate circumferentially along its own axis while being conveyed forward, under the action of the baffle plate.
[0071] The aforementioned camera 10 and arched light source 20 (such as...) Figure 4 (As shown) All are positioned directly above the inspection station, with the arched light source slightly higher than or below the camera. The camera is connected to the computer. The computer has a built-in image acquisition module, image preprocessing module, straw defect detection module, and storage medium. The computer program stored on the storage medium executes a machine vision-driven intelligent identification method for telescopic tube defects during runtime.
[0072] like Figure 1 As shown, a machine vision-driven intelligent identification method for defects in telescopic pipes includes the following steps.
[0073] Step 1: Position and transport the straw to be inspected to the inspection station. During the transport process, the straw can vibrate or rotate circumferentially. The straw to be inspected can be a transparent telescopic tube, a semi-transparent semi-milky white telescopic tube, a drinking straw, or a completely milky white telescopic tube.
[0074] Step 2: Use an arched light source to uniformly illuminate the pipette to be inspected at the inspection station.
[0075] A. The arched opening angle α of the arched light source is 120°-180°, and the formula for calculating the coverage angle Ω of the arched light source is:
[0076] Ω = 2π(1 - cos(α / 2)).
[0077] A single arched light source can achieve multi-directional light incidence, reduce detection blind spots, achieve a ring-like lighting effect, and enable each point on the straw surface to obtain approximately uniform illumination, avoiding highlight spots and shadows.
[0078] B. An arched light source ensures a uniform θ angle distribution across the surface of the straw, resulting in a nearly uniform I_diffuse value and avoiding uneven brightness caused by variations in the θ angle in traditional light sources. Here, θ is the angle between the incident ray and the normal to the straw surface; I_diffuse is the intensity of diffused light received at the observation point, calculated using the following formula:
[0079]
[0080] In the formula, I0 is the incident light intensity.
[0081] k_d is the diffuse reflection coefficient of the straw.
[0082] C. The arched light source can make the axial illuminance uniformity of the straw reach 95% or more.
[0083] D. Arched light source illumination increases the aperture value N, thereby enhancing the depth of field (DOF) and adapting to changes in the height of the eyedropper; the formula for calculating the depth of field (DOF) is:
[0084] DOF = 2·u²·N·c / f².
[0085] In the formula, u is the distance from the camera to the surface of the straw.
[0086] c is the diameter of the permissible circle of confusion.
[0087] f is the focal length of the camera lens.
[0088] In this embodiment, the aperture value N can be increased from f / 16 to f / 8, thereby increasing the depth of field (DOF) by 30% to 50%.
[0089] E. An arched light source, through uniform illumination, can increase the defect contrast C to 0.6~0.8. The preferred formula for calculating the defect contrast C is:
[0090] C = (Imax - Imin) / (Imax + Imin);
[0091] In the formula, Imax and Imin are the maximum and minimum brightness values of the defect area, respectively.
[0092] The arched light source of this invention can enhance surface texture and increase defect contrast by 2-3 times.
[0093] Step 3: Collect N images of different sides of each pipette to be inspected located at the inspection station.
[0094] By capturing multiple frames of images of different sides of a straw under the same light source, from the same angle, and at different times, ensuring that a straw is photographed five times (N=5), the problem of partial occlusion or poor lighting caused by the curved surface of the straw under a single fixed viewpoint is overcome, and the effect of simulating "multi-view imaging" with the lowest hardware cost is achieved.
[0095] In this embodiment, a single camera captures at least five tumbling straws, ensuring that each straw is captured five times, thus maximizing the capture of straws without any blind spots.
[0096] Step 4: Perform noise reduction, enhancement, and feature extraction preprocessing on each side image of the straw to be inspected.
[0097] Step 5: Divide straw defects into wrinkled and leaking defects and non-wrinkled and leaking defects; among them, wrinkled and leaking defects include wrinkled seal, wrinkled ball head, and leaking.
[0098] Non-wrinkled or leaking pipe appearance defects include 13 categories of defects such as messy pipes, single inner pipes, single outer pipes, stacked pipes, horizontal pipes, incomplete inner pipe shrinkage, empty pipes, ball heads not leaking out, constricted openings, and hygiene defects. Among them, hygiene defects include foreign objects, black spots, and oil stains.
[0099] Step 6: Detect straw defects such as wrinkles and leaks using a deep learning model for straw defects. Specifically, this includes:
[0100] Step 6-1: Construct and train a deep learning model for straw defects. Its input is the image of the region of interest of the straw, and its output is the specific type of straw defects.
[0101] The aforementioned straw defect deep learning model is a lightweight real-time detection model. It employs depthwise separable convolution and channel pruning techniques, keeping the model parameter size within 5MB and achieving an inference speed of 30 FPS (30 frames per second). It enables real-time detection on embedded devices, reducing hardware costs by 60%.
[0102] In addition, the straw defect deep learning model of the present invention has the following advantages.
[0103] 1. A few-shot transfer learning strategy is adopted to establish a pre-training-fine-tuning framework for cross-domain knowledge transfer. Pre-training is performed on a general industrial defect dataset, and a small number of actual pipette samples are used for domain-adaptive fine-tuning. Meta-learning techniques are used to optimize the few-shot learning effect, reducing the training data requirement by 80% and improving the model convergence speed by 3 times.
[0104] 2. A semi-supervised active learning mechanism is used to construct a closed loop of human-machine collaborative data annotation and model iteration. The initial model automatically selects uncertain samples for expert annotation, dynamically updates the training set and iteratively optimizes the model, and establishes an adaptive sampling strategy based on confidence, reducing annotation costs by 70% and continuously improving model performance.
[0105] 3. Defect interpretability analysis: Develop a deep learning-based defect cause diagnosis system, combine gradient class activation graph technology to visualize the model decision basis and regions of interest, establish the correlation analysis between defect characteristics and production processes, provide interpretable detection results, and guide process improvement.
[0106] 4. Adaptive threshold adjustment algorithm: Implements dynamic judgment criteria based on environmental adaptation. The judgment threshold is automatically adjusted according to changes in production batches and raw materials. A parameter optimization model driven by historical data is established, and an online learning mechanism is introduced to continuously optimize the threshold. The false judgment rate is reduced to below 0.1%, and the adaptability is improved.
[0107] 5. A multi-task joint learning framework constructs an integrated model for defect detection, classification, and segmentation. It shares a backbone network to extract common features, while parallel branches complete different detection tasks. Weighted optimization of the loss function balances multiple tasks, enabling a single inference to complete the entire analysis process, improving efficiency by 50%.
[0108] 6. Physics simulation data generation, based on synthetic data augmentation technology using a physics engine, to establish... Figure 5 and Figure 6The optical simulation model of the straw material shown simulates defect imaging under different lighting conditions, generating a large amount of synthetic training data with precise annotations. The diversity of training data is increased by 5 times, and the generalization ability of the model is enhanced.
[0109] 7. Adversarial sample enhancement: Adversarial training is introduced to improve model robustness. Generative Adversarial Networks (GANs) create challenging samples, and adversarial training enhances the model's ability to resist interference. A model security evaluation system is established to maintain an accuracy of over 95% under interference such as noise and lighting changes.
[0110] 8. Model Compression and Acceleration: Model optimization schemes for edge computing, knowledge distillation technology to maintain the performance of small models, quantization-aware training to achieve low-precision deployment, hardware-aware neural network architecture search, achieving millisecond-level inference on edge devices, and reducing power consumption by 40%.
[0111] Step 6-2: Extract the region of interest (ROI) from each different side image of each preprocessed straw.
[0112] Step 6-3: Input the straw region of interest image extracted in Step 6-2 into the straw defect deep learning model constructed in Step 6-1, and output the specific type of straw defect.
[0113] Step 7: Use mean filtering to extract non-wrinkled or leaky tube appearance defects from N different side images of each tube after preprocessing, and analyze and calculate the specific type and location of non-wrinkled or leaky tube appearance defects.
[0114] Furthermore, the mean filtering described above uses dynamic thresholding to extract non-wrinkled and leaky pipe appearance defects, and Blob analysis is used to calculate the specific type and location of non-wrinkled and leaky pipe appearance defects.
[0115] The machine vision-driven intelligent defect identification method for telescopic tubes of the present invention has a false alarm rate of no more than 2 times per 10,000 tubes.
[0116] The present invention also provides a storage medium, wherein a computer program stored in the storage medium, when running, executes the aforementioned machine vision-driven intelligent identification method for defects in telescopic tubes. The present invention also provides an electronic device, including a storage medium, a processor, and a computer program stored on the storage medium and executable on the processor, wherein the processor executes the aforementioned machine vision-driven intelligent identification method for defects in telescopic tubes through the computer program.
[0117] The sequence numbers of the above embodiments of the present invention are merely for description and do not represent the superiority or inferiority of the embodiments. In the above embodiments of the present invention, the descriptions of each embodiment have their own emphasis; for parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments. In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of units can be a logical functional division, and in actual implementation, there can be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Furthermore, the displayed or discussed mutual coupling or direct coupling or communication connection can be through some interfaces; the indirect coupling or communication connection of units or modules can be electrical or other forms. The units described as separate components may or may not be physically separated; the components shown as units may or may not be physical units, that is, they can be located in one place or distributed across multiple units. Some or all of the units can be selected according to actual needs to achieve the purpose of this embodiment. Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes: USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, optical disks, and other media capable of storing program code.
[0118] The chip anomaly defect identification method based on multi-template fusion provided by this invention uses a multi-image fusion approach to obtain standard chip images. The fusion process can use both qualified and defective samples, significantly reducing the need for standard samples in synthesizing standard chip images. It also effectively reduces the impact and interference of imaging noise on the standard image, improving the robustness of the standard image. Secondly, this invention utilizes a differential method to retain only the anomalies in the image as much as possible, reducing the impact of differences between chips on the detection effect. Furthermore, a sliding image cropping method is introduced to make the defect detection model compatible with chip image inputs of various sizes without affecting image resolution. Finally, this invention performs frozen training on a target detection model pre-trained on a large general dataset to achieve model transfer, resulting in a defect detection model suitable for chips.
[0119] The preferred embodiments of the present invention have been described in detail above. However, the present invention is not limited to the specific details in the above embodiments. Within the scope of the technical concept of the present invention, various equivalent transformations can be made to the technical solutions of the present invention, and these equivalent transformations all fall within the protection scope of the present invention.
Claims
1. A machine vision-driven intelligent identification method for defects in telescopic pipes, characterized in that: Includes the following steps: Step 1: Position and transport the pipette to be inspected to the inspection station. During the transport process, the pipette to be inspected can vibrate or rotate in the circumferential direction. Step 2: Use an arched light source to uniformly illuminate the pipette to be inspected at the inspection station; Step 3: Collect N images of different sides of each pipette to be inspected located at the inspection station; Step 4: Perform noise reduction, enhancement, and feature extraction preprocessing on each side image of the straw to be inspected; Step 5: Categorize straw defects into wrinkled and leaky defects and non-wrinkled and leaky appearance defects; among them, wrinkled and leaky defects include wrinkled seal, wrinkled ball head, and leaks. Step 6: Detect straw defects such as wrinkles and leaks using a deep learning model for straw defects. Specifically, this includes: Step 6-1: Construct and train a deep learning model for straw defects. Its input is the image of the region of interest of the straw, and its output is the specific type of straw defects. Step 6-2: Extract the region of interest (ROI) from each different side image of each preprocessed straw. Step 6-3: Input the straw region of interest image extracted in Step 6-2 into the straw defect deep learning model constructed in Step 6-1, and output the specific type of straw defect. Step 7: Use mean filtering to extract non-wrinkled or leaky tube appearance defects from N different side images of each tube after preprocessing, and analyze and calculate the specific type and location of non-wrinkled or leaky tube appearance defects.
2. The machine vision-driven intelligent identification method for defects in telescopic pipes according to claim 1, characterized in that: In step 2, the arched opening angle α of the arched light source is 120°-180°, and the formula for calculating the coverage angle Ω of the arched light source is: ; A single arched light source can achieve multi-directional light incidence, reduce detection blind spots, achieve a ring-like lighting effect, and enable each point on the straw surface to obtain approximately uniform illumination, avoiding highlight spots and shadows.
3. The machine vision-driven intelligent identification method for defects in telescopic pipes according to claim 2, characterized in that: In step 2, the arched light source ensures a uniform θ angle distribution across the surface of the straw, resulting in a nearly uniform I_diffuse value and avoiding the uneven brightness caused by variations in the θ angle in traditional light sources. Here, θ is the angle between the incident ray and the normal to the straw surface; I_diffuse is the intensity of diffused light received at the observation point, calculated using the following formula: ; In the formula, I0 is the incident light intensity; k_d is the diffuse reflection coefficient of the straw.
4. The machine vision-driven intelligent identification method for defects in telescopic pipes according to claim 1, characterized in that: In step 2, the arched light source can make the axial illuminance uniformity of the straw reach 95% or more.
5. The machine vision-driven intelligent identification method for defects in telescopic pipes according to claim 1, characterized in that: In step 2, the arched light source increases the aperture value N, thereby enhancing the depth of field (DOF) and adapting to changes in the height of the eyedropper. The formula for calculating the depth of field (DOF) is: ; In the formula, u is the distance from the camera to the surface of the straw; c is the diameter of the allowable circle of confusion; f is the focal length of the camera lens.
6. The machine vision-driven intelligent identification method for defects in telescopic pipes according to claim 1, characterized in that: In step 2, the arched light source, through uniform illumination, can increase the defect contrast C to 0.6~0.
8.
7. The machine vision-driven intelligent identification method for defects in telescopic pipes according to claim 1, characterized in that: In step 1, the straw to be inspected is a transparent telescopic tube, a semi-transparent semi-milky white telescopic tube, a drinking straw, or a completely milky white telescopic tube; in step 5, non-wrinkled tube appearance defects include disordered tubes, single inner tube, single outer tube, stacked tubes, horizontal tubes, inner tube not shrinking properly, empty tubes, ball head not protruding, constricted opening, foreign objects, black spots, and oil stains.
8. The machine vision-driven intelligent identification method for defects in telescopic pipes according to claim 1, characterized in that: In step 7, mean filtering uses dynamic thresholding to extract non-wrinkled and leaky pipe appearance defects, and Blob analysis is used to calculate the specific type and location of non-wrinkled and leaky pipe appearance defects.
9. The machine vision-driven intelligent identification method for defects in telescopic pipes according to claim 1, characterized in that: In step 1, a straw conveying unit is used to position and transport the straw to be inspected to the inspection station. The straw conveying unit includes a screw, a screw rotation drive device, and a baffle plate. There are several screws arranged in parallel, and each screw can rotate under the drive of the screw rotation drive device. The threaded groove of the screw can accommodate the straw to be inspected. The baffle plate is set on the outside of the screw and can limit the lateral position of the straw to be inspected.
10. A machine vision-driven intelligent identification system for defects in telescopic pipes, characterized in that: It includes a storage medium, and the computer program stored in the storage medium, when running, executes the machine vision-driven intelligent identification method for defects in telescopic tubes as described in any one of claims 1-9.
Citation Information
Patent Citations
Quantitative tobacco shred weighing equipment
CN211085433U