Device and method for detecting mouth defects of cylindrical stamping products based on machine vision

Through an inspection device based on machine vision, combined with an annular conveyor line and a sorting mechanism, the existing technology problems of low detection accuracy, slow speed and unsuitability for continuous mold production of cylindrical stamping products are solved, and efficient and accurate defect detection is achieved. Detection and sorting are suitable for continuous mold production, and the impact of saponification liquid on detection is dealt with.

CN116637837BActive Publication Date: 2024-09-13WILD SC NINGBO INTELLIGENT TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310789472.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-06-30
Publication Date
2024-09-13
Estimated Expiration
2043-06-30

AI Technical Summary

Technical Problem

The existing technology has defects in defect detection of cylindrical metal stamping products, such as low detection accuracy, slow speed, low real-time performance and unsuitability for continuous mold production. In particular, the presence of saponification liquid affects the detection accuracy.

Method used

A device for detecting mouth defects of cylindrical stamping products based on machine vision is designed, including an inspection bench, a circular conveyor line, a loading/unloading station, a preprocessing station, an inspection station and a sorting station. Using The visual components and controller compare grayscale images to detect defects, and spray saponification liquid after the detection. Combined with the sorting mechanism, automatic detection and sorting are realized.

Benefits of technology

It achieves efficient and accurate defect detection and sorting of cylindrical structures, improves detection speed and accuracy, is suitable for continuous mold production processes, and maintains detection accuracy in the presence of saponification liquid.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116637837B
    Figure CN116637837B
Patent Text Reader

Abstract

The present invention discloses a device and method for detecting defects at the mouth of a cylindrical stamping product based on machine vision, aiming to provide a high-speed, precise and automated detection device and method for detecting defects at the mouth of a cylindrical stamping product based on machine vision, which has a defect detection function and has accurate detection results and fast speed. The device and method comprise: a detection stand, on which a circular conveyor line is arranged, and the circular conveyor line is provided with a positioning sleeve for vertically placing the port of a cylindrical structure facing upward; the detection stand is provided with a loading / unloading station, a pretreatment station, a detection station and a sorting station in sequence along the circular conveyor line, and the circular conveyor line conveys the positioning sleeve through the loading / unloading station, the pretreatment station, the detection station and the sorting station in sequence; the loading / unloading station is used for loading or unloading the cylindrical structure; the present invention relates to the technical field of automated detection equipment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of automated detection equipment, and more specifically to a device and method for detecting mouth defects of cylindrical stamping products based on machine vision. Background Art

[0002] Cylindrical metal stamping products are widely used, but due to poor stamping materials, improper stamping process, stamping equipment performance, stamping die defects and other reasons, the mouth of cylindrical metal stamping products may have cracks, breakage, inner concave, outer convex and other defects. On the one hand, such defects will have an adverse effect on product quality. On the other hand, in the continuous die stamping process, the stamping defects of the upper die may cause damage to the stamping machine or mold during the next stamping, so they need to be detected and eliminated. In the relatively backward manual production process, such defects are manually judged and eliminated. However, with the development of stamping automation technology, especially the mature application of continuous die stamping technology, it has become difficult to achieve manual online defect detection, and the defect detection function must be completed through specially designed automatic detection devices.

[0003] The current similar existing technologies include: a stamping surface defect detection method based on a small sample disclosed in Application No. 202211507477.X. The disadvantages of this existing technology are: low detection accuracy, many errors in the detection results, and slow detection speed. The reason for this disadvantage is that the technology only uses a small sample that is difficult to cover all types of defects, and the improved SSD-Net detection network technology used is more complex and slow to calculate.

[0004] The hardware stamping parts quality inspection method based on computer vision disclosed in the application number 202310084181.X has the disadvantage that the real-time detection is not high. The reason for this disadvantage is that the method uses a stereo camera to obtain point cloud features and realizes defect detection by matching point cloud templates. However, the point cloud template and the actual product point cloud image data volume are large, and a large amount of matching calculations are required, resulting in low real-time detection.

[0005] Application No. 202111252374.9 discloses an online detection device for defects in stamped parts. The disadvantage of this prior art is that this technology is aimed at the detection of finished products after stamping production, and is not suitable for continuous detection of semi-finished products in the intermediate process of stamping in continuous die production. The reason for this shortcoming is that this technology is only designed with one inspection station, which cannot be applied to the production process of continuous multi-pass stamping process. In addition, saponified liquid and the like are widely used in the stamping process to improve the surface properties of the stamped workpiece. The presence of saponified liquid on the stamped workpiece will affect the accuracy of visual inspection. However, the equipment described in the prior art lacks equipment for processing the saponified liquid, and also lacks a saponified liquid spraying mechanism before stamping again after detection. Therefore, the practicality of this prior art still needs to be improved. Summary of the invention

[0006] In view of the shortcomings and defects of the prior art, a high-speed, precise and automated detection device and method for mouth defects of cylindrical stamping products based on machine vision are provided, which has a defect detection function and has accurate detection results and fast speed.

[0007] To achieve the above object, the present invention provides the following technical solutions:

[0008] A machine vision-based cylindrical stamping product mouth defect detection device comprises a detection stand, on which a ring conveyor line is arranged, and the ring conveyor line is provided with a positioning sleeve for vertically placing the cylindrical structure with the port facing upward;

[0009] The testing stand is provided with a loading / unloading station, a pre-processing station, a testing station and a sorting station in sequence along the circular conveyor line, and the positioning sleeve of the circular conveyor line passes through the loading / unloading station, the pre-processing station, the testing station and the sorting station in sequence;

[0010] The loading / unloading station is used for loading or unloading of cylindrical structures;

[0011] The pretreatment station is provided with a high-pressure air blowing pipe, and the output end of the high-pressure air blowing pipe blows air to the cylindrical structure on the positioning sleeve to remove debris at the port of the cylindrical structure;

[0012] The inspection station is provided with an inspection module, which includes a visual component and a controller. The visual component is used to take grayscale pictures of the inner side and the outer side of the port of the cylindrical structure, respectively. The visual component is electrically connected to the controller, and the controller stores pictures of qualified samples. The controller compares the grayscale pictures of the inner side and the outer side of the port of the cylindrical structure with the pictures of the qualified samples to detect whether they are qualified.

[0013] The sorting station is equipped with a sorting mechanism, and the sorting mechanism is used to remove unqualified cylindrical structures;

[0014] The cylindrical structures that are qualified after being detected by the controller are unloaded at the loading / unloading station.

[0015] After adopting the above structure, the machine vision-based cylindrical stamping product mouth defect detection device of the present invention has the following advantages compared with the prior art: the device has the function of automatically completing defect detection and sorting, can realize qualified detection of cylindrical structures, and can sort products according to the test results (qualified or unqualified), without the need for manual judgment and sorting, has a defect detection function, and has the characteristics of accurate detection results and fast speed.

[0016] As an improvement of the present invention, the visual component includes a column, a camera, and a light source, the column is vertically arranged at the detection station, and the camera and the light source are respectively connected to the column through a bracket;

[0017] The light source is located above the port of the cylindrical structure and is used to illuminate the port of the cylindrical structure. The camera is located above the light source and is provided with an inner hole for the irradiation end of the camera to photograph the port under illumination.

[0018] As an improvement of the present invention, a positioning mechanism is further provided at the detection station, the positioning mechanism comprising two clamping jaws arranged opposite to each other, notches are respectively provided on the inner sides of the two clamping jaws, the two clamping jaws are connected to a first cylinder, and the first cylinder drives the two clamping jaws to be relatively close to or away from each other;

[0019] The detection bench is provided with a second cylinder, the moving end of the second cylinder is connected to the first cylinder, and the moving end of the second cylinder moves to drive the first cylinder to move, so that the two clamping jaws move until the cylindrical structure is between the two clamping jaws, or the two clamping jaws move until the cylindrical structure leaves between the two clamping jaws;

[0020] When the two clamping jaws move to the point where the cylindrical structure is between the two clamping jaws, the first cylinder drives the two clamping jaws to move relatively close to each other so that the notches are clamped on the peripheral side of the cylindrical structure.

[0021] As an improvement of the present invention, the sorting mechanism adopts a sorting robot, and the sorting robot is used to take out unqualified products from the positioning sleeve and transfer them to a defective product material compartment.

[0022] As an improvement of the present invention, the annular conveyor line is further provided with a post-processing station, and the post-processing station is located between the sorting station and the loading / unloading station;

[0023] The post-processing station is provided with a saponification liquid spray pipe, and the output end of the saponification liquid spray pipe sprays the saponification liquid to the cylindrical structure in the positioning sleeve on the conveying line.

[0024] As an improvement of the present invention, a cover plate is provided at the post-processing station, and the cover plate covers the annular conveyor line at the post-processing station in a relatively closed space;

[0025] The cover plate is provided with an opening corresponding to the port of the cylindrical structure at the post-processing station, and the output end of the saponification liquid spray pipe extends from the opening to the top of the cylindrical structure.

[0026] As an improvement of the present invention, the annular conveyor line is arranged on the plate surface of the bottom plate of the detection stand;

[0027] The loading / unloading station is arranged at the front end of the circular conveyor line, the sorting station is arranged at the rear end of the circular conveyor line, the pre-processing station and the inspection station are arranged at the left side of the circular conveyor line, and the post-processing station is arranged at the right end of the circular conveyor line;

[0028] A driving mechanism for driving the annular conveyor line for conveying is arranged inside the annular conveyor line;

[0029] The positioning sleeve is vertically provided with a cylindrical groove, and an opening facing outward is formed by cutting the side wall of the groove;

[0030] The cylindrical structure enters from the opening and fits into the groove.

[0031] As an improvement of the present invention, a baffle is arranged on the bottom plate, the baffle is connected to the outside of the annular conveyor line, a break is arranged on the baffle corresponding to the loading / unloading station, and the port is connected to the water tank through a liquid collecting pipe.

[0032] A method for detecting defects at the mouth of a cylindrical stamping product based on machine vision, using a device for detecting defects at the mouth of a cylindrical stamping product based on machine vision, the method for detecting cylindrical structures comprising the following steps:

[0033] SS01, place the cylindrical structure vertically on the positioning sleeve of the loading / unloading station;

[0034] SS02, the ring conveyor line transports the positioning sleeve with the cylindrical structure to the pre-treatment station;

[0035] The output end of the high-pressure air blowing pipe of the pretreatment station blows air to the cylindrical structure on the positioning sleeve to remove debris such as saponification liquid;

[0036] SS03, the circular conveyor line transports the positioning sleeve with the cylindrical structure from the pre-treatment station to the inspection station;

[0037] The visual component arranged at the inspection station takes grayscale pictures of the inner side and the outer side of the port of the cylindrical structure respectively;

[0038] The grayscale image taken by the visual component is transmitted to the controller, which stores the image of the qualified sample. The controller compares the grayscale images of the inner side and the outer side of the port of the cylindrical structure with the image of the qualified sample to detect whether it is qualified;

[0039] Among them, the detection method of the detection module for detecting defects of the cylindrical structure is:

[0040] S1, template image creation and adaptive detection information extraction;

[0041] S2, hierarchical region of interest creation;

[0042] S3, take a photo to obtain the image to be detected;

[0043] S4, target adaptive traversal detection;

[0044] S5. Generate calculation test results

[0045] SS04, the circular conveyor line transports the positioning sleeve with the cylindrical structure from the inspection station to the sorting station.

[0046] If the controller detects that the material is unqualified, the incoming material at the sorting station is judged to be defective material, and the sorting mechanism removes the unqualified cylindrical structure from the positioning sleeve;

[0047] If the controller detects that the material is qualified, the incoming material at the sorting station is considered good, and the sorting mechanism does not operate;

[0048] SS05, the cylindrical structure that has been tested as qualified by the controller and sprayed with saponification liquid is unloaded at the loading / unloading station.

[0049] After adopting the above structure, the method for detecting mouth defects of cylindrical stamping products based on machine vision of the present invention has the following advantages compared with the prior art: the above detection method can realize efficient and accurate defect detection and sorting of cylindrical structures.

[0050] As an improvement of the high-speed and accurate detection method of the mouth defects of cylindrical stamping products based on machine vision of the present invention, the annular conveyor line is further provided with a post-processing station, which is located between the sorting station and the loading / unloading station;

[0051] The post-processing station is provided with a saponification liquid spray pipe, and the output end of the saponification liquid spray pipe sprays the saponification liquid to the cylindrical structure in the positioning sleeve on the conveying line;

[0052] After step SS04, step SS04.1 is further provided.

[0053] SS04.1. The circular conveyor line conveys the positioning sleeves that have passed through the sorting station to the post-processing station. The output end of the saponification liquid spray pipe of the post-processing station sprays the saponification liquid on the cylindrical structure on the positioning sleeve. BRIEF DESCRIPTION OF THE DRAWINGS

[0054] Figure 1 It is a structural schematic diagram of the present invention.

[0055] Figure 2 It is a structural schematic diagram of the annular conveyor line of the present invention.

[0056] Figure 3 It is a three-dimensional structural schematic diagram of the present invention.

[0057] Figure 4 The present invention Figure 3 A schematic diagram of the enlarged structure in the middle.

[0058] Figure 5 The present invention Figure 3 Enlarged schematic diagram of the structure at point B in the middle.

[0059] Figure 6 It is a schematic diagram of the structure of the visual component of the present invention after the external protective cover is hidden.

[0060] Figure 7 It is a schematic diagram of the cover plate structure of the post-processing station of the present invention.

[0061] Figure 8 It is a main structural schematic diagram of the present invention.

[0062] As shown in the figure: 1. Inspection stand; 1.1. Circular conveyor line; 1.11. Loading / unloading station; 1.12. Pre-processing station; 1.13. Inspection station; 1.14. Sorting station; 1.15. Post-processing station; 1.2. Bottom plate; 1.3. Driving mechanism; 2. Positioning sleeve; 2.1. Groove; 2.11. Opening; 3. High-pressure air blow pipe; 4. Visual component; 4.1. Column; 4.2, camera; 4.3, light source; 4.31, inner hole; 5, sorting mechanism; 6, positioning mechanism; 6.1, clamping claw; 6.11, notch; 6.2, first cylinder; 6.3, second cylinder; 7, defective material compartment; 8, saponification liquid spray pipe; 9, cover plate; 9.1, opening; 10, baffle; 10.1, fracture; 11, water tank; 11.1, liquid collecting pipe; 12, cylindrical structure. DETAILED DESCRIPTION

[0063] The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments.

[0064] See also Figure 1-8As shown, a machine vision-based cylindrical stamping product mouth defect detection device comprises a detection stand 1, on which a ring conveyor line 1.1 is arranged, and the ring conveyor line 1.1 is provided with a positioning sleeve 2 for vertically placing a cylindrical structure 12 with its port facing upward;

[0065] The testing stand 1 is provided with a loading / unloading station 1.11, a pre-processing station 1.12, a testing station 1.13 and a sorting station 1.14 in sequence along the circular conveyor line 1.1, and the circular conveyor line 1.1 conveys the positioning sleeve 2 through the loading / unloading station 1.11, the pre-processing station 1.12, the testing station 1.13 and the sorting station 1.14 in sequence;

[0066] The loading / unloading station 1.11 is used for loading or unloading the cylindrical structure 12;

[0067] The pretreatment station 1.12 is provided with a high-pressure air blowing pipe 3, and the output end of the high-pressure air blowing pipe 3 blows air to the cylindrical structure 12 on the positioning sleeve 2 to remove debris at the end of the cylindrical structure 12;

[0068] The inspection station 1.13 is provided with an inspection module, which includes a visual component 4 and a controller. The visual component 4 is used to take grayscale pictures of the inner side and the outer side of the port of the cylindrical structure 12, respectively. The visual component 4 is electrically connected to the controller, and the controller stores pictures of qualified samples. The controller compares the grayscale pictures of the inner side and the outer side of the port of the cylindrical structure 12 with the pictures of qualified samples to detect whether they are qualified.

[0069] The detection method of the detection module for detecting defects of the cylindrical structure 12 is as follows:

[0070] S1, template image creation and adaptive detection information extraction;

[0071] S2, hierarchical region of interest creation;

[0072] S3, take a photo to obtain the image to be detected;

[0073] S4, target adaptive traversal detection;

[0074] S5, generating calculation and detection results;

[0075] The sorting station 1.14 is provided with a sorting mechanism 5, and the sorting mechanism 5 is used to remove unqualified cylindrical structures 12;

[0076] The cylindrical structure 12 that is qualified after being detected by the controller is unloaded at the loading / unloading station 1.11.

[0077] After adopting the above structure, the machine vision-based cylindrical stamping product mouth defect detection device of the present invention has the following advantages compared with the prior art: the device has the function of automatically completing defect detection and sorting, can realize qualified detection of the cylindrical structure 12, and can sort the products according to the test results (qualified or unqualified), without the need for manual judgment and sorting, has a defect detection function, and the detection results are accurate and fast.

[0078] As an improvement of the present invention, the visual component 4 includes a column 4.1, a camera 4.2, and a light source 4.3, the column 4.1 is vertically arranged at the detection station 1.13, and the camera 4.2 and the light source 4.3 are respectively connected to the column 4.1 through a bracket;

[0079] The light source 4.3 is located above the port of the cylindrical structure 12 and is used to illuminate the port of the cylindrical structure 12. The camera 4.2 is located above the light source 4.3. The light source 4.3 is provided with an inner hole 4.31 for the irradiation end of the camera 4.2 to photograph the port under illumination.

[0080] As an improvement of the present invention, a positioning mechanism 6 is further provided at the detection station 1.13, and the positioning mechanism 6 comprises two clamping jaws 6.1 arranged opposite to each other, and notches 6.11 are respectively arranged on the inner sides of the two clamping jaws 6.1, and the two clamping jaws 6.1 are connected to a first cylinder 6.2, and the first cylinder 6.2 drives the two clamping jaws 6.1 to move relatively closer or farther away;

[0081] The detection bench 1 is provided with a second cylinder 6.3, the moving end of the second cylinder 6.3 is connected to the first cylinder 6.2, and the moving end of the second cylinder 6.3 moves to drive the first cylinder 6.2 to move, so that the two clamping jaws 6.1 move to the cylindrical structure 12 between the two clamping jaws 6.1, or the two clamping jaws 6.1 move to the cylindrical structure 12 away from the two clamping jaws 6.1;

[0082] When the two clamping jaws 6.1 move to the point where the cylindrical structure 12 is between the two clamping jaws 6.1, the first cylinder 6.2 drives the two clamping jaws 6.1 to move relatively close to each other, so that the notch 6.11 is clamped on the peripheral side of the cylindrical structure 12.

[0083] As an improvement of the present invention, the sorting mechanism 5 adopts a sorting robot, which is used to take out unqualified products from the positioning sleeve 2 and transfer them to the defective product compartment 7.

[0084] As an improvement of the present invention, the annular conveyor line 1.1 is further provided with a post-processing station 1.15, and the post-processing station 1.15 is located between the sorting station 1.14 and the loading / unloading station 1.11;

[0085] The post-processing station 1.15 is provided with a saponification liquid spray pipe 8, and the output end of the saponification liquid spray pipe 8 sprays the saponification liquid to the cylindrical structure 12 in the positioning sleeve 2 on the conveying line.

[0086] As an improvement of the present invention, a cover plate 9 is provided at the post-processing station 1.15, and the cover plate 9 covers the annular conveyor line 1.1 at the post-processing station 1.15 in a relatively closed space;

[0087] The cover plate 9 is provided with an opening 9.1 corresponding to the port of the cylindrical structure 12 at the post-processing station 1.15, and the output end of the saponified liquid spray pipe 8 extends from the opening 9.1 to the top of the cylindrical structure 12.

[0088] As an improvement of the present invention, the annular conveyor line 1.1 is arranged on the plate surface of the bottom plate 1.2 of the detection stand 1;

[0089] The loading / unloading station 1.11 is arranged at the front end of the circular conveyor line 1.1, the sorting station 1.14 is arranged at the rear end of the circular conveyor line 1.1, the pre-processing station 1.12 and the inspection station 1.13 are arranged at the left side of the circular conveyor line 1.1, and the post-processing station 1.15 is arranged at the right end of the circular conveyor line 1.1;

[0090] A driving mechanism 1.3 for driving the circular conveyor line 1.1 for conveying is arranged inside the circular conveyor line 1.1;

[0091] The positioning sleeve 2 is vertically provided with a cylindrical groove 2.1, and an opening 2.11 facing outward is formed by cutting the side wall of the groove 2.1;

[0092] The cylindrical structure 12 enters through the opening 2.11 and fits into the groove 2.1.

[0093] As an improvement of the present invention, a baffle 10 is provided on the bottom plate 1.2, and the baffle 10 is connected to the outside of the annular conveyor line 1.1. The baffle 10 is provided with a break 10.1 corresponding to the loading / unloading station 1.11, and the port is connected to the water tank 11 through a liquid collecting pipe 11.1.

[0094] A method for detecting defects at the mouth of a cylindrical stamping product based on machine vision, using a device for detecting defects at the mouth of a cylindrical stamping product based on machine vision, the method for detecting a cylindrical structure 12 comprises the following steps:

[0095] SS01, vertically place the cylindrical structure 12 on the positioning sleeve 2 of the loading / unloading station 1.11;

[0096] SS02, the annular conveyor line 1.1 conveys the positioning sleeve 2 with the cylindrical structure 12 to the pre-treatment station 1.12;

[0097] The output end of the high-pressure air blowing pipe 3 of the pretreatment station 1.12 blows air to the cylindrical structure 12 on the positioning sleeve 2 to remove debris such as saponified liquid;

[0098] SS03, the circular conveyor line 1.1 conveys the positioning sleeve 2 with the cylindrical structure 12 from the pre-treatment station 1.12 to the inspection station 1.13;

[0099] The detection module set at the detection station 1.13 detects the inner side and the outer side of the port of the cylindrical structure 12, wherein the visual component 4 takes grayscale pictures of the inner side and the outer side of the port of the cylindrical structure 12 respectively;

[0100] The grayscale image taken by the visual component 4 is transmitted to the controller, which stores the image of the qualified sample. The controller compares the grayscale images of the inner side and the outer side of the port of the cylindrical structure 12 with the image of the qualified sample to detect whether it is qualified;

[0101] SS04, the circular conveyor line 1.1 transports the positioning sleeve 2 with the cylindrical structure 12 from the detection station 1.13 to the sorting station 1.14.

[0102] If the controller detects that the material is unqualified, the incoming material from the sorting station 1.14 is judged to be defective material, and the unqualified cylindrical structure 12 is removed from the positioning sleeve 2 by the sorting mechanism 5;

[0103] If the controller detects that the material is qualified, the incoming material from the sorting station 1.14 is judged to be good, and the sorting mechanism 5 does not act;

[0104] SS05, the cylindrical structure 12 which has been detected as qualified by the controller and sprayed with saponification liquid is unloaded at the loading / unloading station 1.11.

[0105] After adopting the above structure, the method for detecting the mouth defects of cylindrical stamping products based on machine vision of the present invention has the following advantages compared with the prior art: the above detection method can realize efficient and accurate defect detection and sorting of the cylindrical structure 12.

[0106] As an improvement of the high-speed and accurate detection method of the mouth defects of cylindrical stamping products based on machine vision of the present invention, the annular conveyor line 1.1 is further provided with a post-processing station 1.15, which is located between the sorting station 1.14 and the loading / unloading station 1.11;

[0107] The post-processing station 1.15 is provided with a saponification liquid spray pipe 8, and the output end of the saponification liquid spray pipe 8 sprays the saponification liquid to the cylindrical structure 12 in the positioning sleeve 2 on the conveying line;

[0108] After step SS04, step SS04.1 is further provided.

[0109] SS04.1, the circular conveyor line 1.1 conveys the positioning sleeve 2 passing through the sorting station 1.14 to the post-processing station 1.15, and the output end of the saponification liquid spray pipe 8 of the post-processing station 1.15 sprays the saponification liquid on the cylindrical structure 12 on the positioning sleeve 2.

[0110] Since the production of the cylindrical structure 12 involves a continuous stamping process, the device can also be provided with a plurality of annular conveyor lines 1.1, referring to the sequence of the continuous stamping processes, wherein the first annular conveyor line 1.1 can be used to inspect the incoming cylindrical structure 12 and spray saponification liquid before the stamping process begins; the last annular conveyor line 1.1 can be used to inspect the finished cylindrical structure 12 and spray saponification liquid after the continuous stamping is completed; the remaining annular conveyor lines 1.1 can be used to inspect the semi-finished cylindrical structure 12 and spray saponification liquid between the stamping processes.

[0111] In this application, only two annular conveyor lines 1.1 are shown as references, wherein the annular conveyor line 1.1 on the left side detects the semi-finished cylindrical structure 12 after a stamping and sprays the saponification liquid;

[0112] The semi-finished cylindrical structure 12 that has been tested and sprayed with saponification liquid is transferred by the transfer mechanism to the next stamping process for processing into a finished cylindrical structure 12. After the processing is completed, the finished cylindrical structure 12 is transferred by the transfer mechanism to the right circular conveyor line 1.1. The right circular conveyor line 1.1 tests the finished cylindrical structure 12. This circular conveyor line 1.1 does not need to spray saponification liquid on the finished cylindrical structure 12.

[0113] The detection method of the detection module for detecting defects of the cylindrical structure 12 is as follows:

[0114] S1, template image creation and adaptive detection information extraction;

[0115] S2, hierarchical region of interest creation;

[0116] S3, take a photo to obtain the image to be detected;

[0117] S4, target adaptive traversal detection;

[0118] S5. Generate calculation and detection results.

[0119] Specifically in this embodiment:

[0120] S1. Template image creation and adaptive detection information extraction: prepare n1 qualified product images of the cylindrical structure 12, and n1 is preferably greater than 50 and less than 100. For the first qualified product image, by adjusting the threshold parameters ch1 and cl1, the pixels of the points with pixels smaller than ch1 and larger than cl1 in the first image are replaced with 255, and the pixels of other points are replaced with 0, and the pixels of the mouth of the cylindrical structure 12 in the first qualified product image are guaranteed to be 255. Adjust the threshold parameters ch2 and cl2, so that the pixels of the points with pixels smaller than ch2 and larger than cl2 in the second qualified product image are replaced with 255, and the pixels of other points are replaced with 0, and the pixels of the mouth of the cylindrical structure 12 in the second qualified product image are guaranteed to be 255... Adjust the threshold parameters chn1 and cln1, so that the pixels of the points with pixels smaller than chn1 and larger than cln1 in the n1th qualified product image are replaced with 255, and the pixels of other points are replaced with 0, and the pixels of the mouth of the cylindrical structure 12 in the n1th qualified product image are guaranteed to be 255.

[0121] The average value of ch1, ch2, ..., chn1 is chmean = (ch1 + ch2 + ... + chn1) / n1, and chmean is used to calculate the derivative value chmean_1 = chmean + fix ((255-chmean) × 0.1), and the derivative value chmean_2 = chmean + fix ((255-chmean) × 0.2), where the above fix indicates rounding the calculated value. The average value of cl1, cl2, ..., cln1 is clmean = (cl1 + cl2 + ... + cln1) / n1, and clmean is used to calculate the derivative value clmean_1 = clmean - fix ((clmean - 0) × 0.1), and the derivative value clmean_2 = clmean - fix ((clmean - 0) × 0.2), where the above fix indicates rounding the calculated value.

[0122] The position sequence of the pixels outside the mouth of the cylindrical structure 12 in the first qualified product image is expressed as Po1 = (Po1_1, Po1_2...Po1_m), the position sequence of the pixels outside the mouth of the cylindrical structure 12 in the second qualified product image is expressed as Po2 = (Po2_1, Po2_2...Po2_m)... The position sequence of the pixels outside the mouth of the cylindrical structure 12 in the n1th qualified product image is expressed as Pon1 = (Pon1_1, Pon1_2...Pon1_m), and the average value of the above position sequence is Pomean = (Po1+Po2+...+Pon1) / n1.

[0123] The position sequence of the pixels on the inner side of the mouth of the cylindrical structure 12 in the first qualified product image is expressed as Pi1 = (Pi1_1, Pi1_2...Pi1_m), the position sequence of the pixels on the inner side of the mouth of the cylindrical structure 12 in the second qualified product image is expressed as Pi2 = (Pi2_1, Pi2_2...Pi2_m)... The position sequence of the pixels on the inner side of the mouth of the cylindrical structure 12 in the n1th qualified product image is expressed as Pin1 = (Pin1_1, Pin1_2...Pin1_m), and the average value Pimean = (Pi1+Pi2+...+Pin1) / n1 is taken for the above position sequences.

[0124] S2. Layered region of interest creation: Use the template image created in step S1 to further create three layers of regions of interest. The first layer is a deep credible region of interest layer, and the region is the region [Pimean, Pomean] formed by the average value of the sequence of the positions of the pixels on the outside and the average value of the sequence of the positions of the pixels on the inside of the mouth of the cylindrical structure 12 in step S1, and the credible weight parameter in this region is w1. The second layer is a moderately credible region of interest layer, and correspondingly, its region is [Pimean-fix((Pomean-Pimean)×0.1), Pomean+fix((Pomean-Pimean)×0.1)], and the credible weight parameter in this region is w2. The third layer is a low credible region of interest layer, and correspondingly, its region is [Pimean-fix((Pomean-Pimean)×0.2), Pomean+fix((Pomean-Pimean)×0.2)], and the credible weight parameter in this region is w3.

[0125] S3, take a picture to obtain the image to be tested: the cylindrical structure 12 to be tested is transferred to the positioning sleeve 2, and is transported to the testing station 1.13 by the circular conveyor line 1.1,

[0126] The movement of the moving end of the second cylinder 6.3 drives the first cylinder 6.2 to move, so that the two clamping jaws 6.1 move until the cylindrical structure 12 is between the two clamping jaws 6.1;

[0127] The first cylinder 6.2 drives the two clamping jaws 6.1 to move relatively close to each other, so that the notch 6.11 is clamped on the peripheral side of the cylindrical structure 12 to position the cylindrical structure 12 to be inspected;

[0128] The light source 4.3 turns on the lighting, and after the cylindrical structure 12 to be detected is stable, the camera 4.2 takes a photo of the port of the cylindrical structure 12 to be detected to obtain a grayscale image, and transmits the photo to the controller via an Ethernet data cable.

[0129] S4, target adaptive traversal detection: call the chmean, chmean1, chmean2, clmean, clmean1, clmean2 parameters and three-layer region of interest parameters generated by the template image in step S1 and step S2, and perform target adaptive traversal detection in the corresponding region of interest of the image to be detected obtained by taking a photo in step S3.

[0130] Among them, in the depth trusted region of interest layer, all pixels in the area of ​​the image to be detected obtained by taking pictures in step S3 are traversed, and the total number of all pixel values ​​sum0 is calculated, the total number of pixel values ​​sum1 whose pixel values ​​are between clmean and chmean is calculated, the total number of pixel values ​​sum2 whose pixel values ​​are between clmean_1 and chmean_1 is calculated, and the total number of pixel values ​​sum3 whose pixel values ​​are between clmean_2 and chmean_2 is calculated.

[0131] In the moderately credible region of interest layer, all pixels in the region of the image to be detected obtained by taking the photo in step S3 are traversed, and the total number of all pixel values ​​sum4 is calculated, the total number of pixel values ​​whose pixel values ​​are between clmean and chmean sum5 is calculated, the total number of pixel values ​​whose pixel values ​​are between clmean_1 and chmean_1 sum6 is calculated, and the total number of pixel values ​​whose pixel values ​​are between clmean_2 and chmean_2 sum7 is calculated.

[0132] In the low-confidence region of interest layer, all pixels in the region of the image to be detected obtained by taking the photo in step S3 are traversed, and the total number of all pixel values ​​sum8 is calculated, the total number of pixel values ​​whose pixel values ​​are between clmean and chmean sum9 is calculated, the total number of pixel values ​​whose pixel values ​​are between clmean_1 and chmean_1 sum10 is calculated, and the total number of pixel values ​​whose pixel values ​​are between clmean_2 and chmean_2 sum11 is calculated.

[0133] S5. Generate and calculate the detection results: call the trusted weight parameters w1, w2, w3 of each area generated by the template image in step S2, and the image data to be detected sum0, sum1...sum11 obtained in step S4, and perform further calculations according to the following process.

[0134] Calculate the intermediate result value 1 in the depth credible region of interest layer, result1 = sum1 / sum0×w1×k1;

[0135] Calculate the intermediate result value 2 in the depth credible region of interest layer, result2 = sum2 / sum0×w1×k2;

[0136] Calculate the intermediate result value 3 in the depth credible region of interest layer, result3 = sum3 / sum0×w1×k3;

[0137] Calculate the intermediate result value 4 in the moderately credible region of interest layer, result4 = sum5 / sum4×w2×k4;

[0138] Calculate the intermediate result value 5 in the moderately credible region of interest layer, result5 = sum6 / sum4×w2×k5;

[0139] Calculate the intermediate result value 6 in the moderately credible region of interest layer, result6 = sum7 / sum4×w2×k6;

[0140] Calculate the intermediate result value 7 in the low-confidence region of interest layer, result7 = sum9 / sum8×w3×k7;

[0141] Calculate the intermediate result value 8 in the low-confidence region of interest layer, result8 = sum10 / sum8×w3×k8;

[0142] Calculate the intermediate result value 9 in the low-confidence region of interest layer, result9=sum11 / sum8×w3×k9;

[0143] The maximum value of the above result values ​​is taken as result=max(result1,result2,result3,result4,result5,result6,result7,result8,result9). If the maximum value result is greater than or equal to the manually preset comparison value result', the cylindrical structure 12 to be inspected is considered to be a qualified product, otherwise it is a defective product.

[0144] In the above calculations, k1, k2, k3, k4, k5, k6, k7, k8, and k9 are on-site artificial adjustment coefficients aimed at reducing the impact of disturbances.

[0145] In the above steps S1-S5, steps S1 and S2 are for processing the template image, which are performed offline and do not participate in real-time detection; steps S3, S4, and S5 are for processing the image to be detected, which are performed online and participate in the real-time detection process. When the product to be detected, working conditions, etc. do not change, the parameters generated by the process of steps S1 and S2 are completed once for the template image, which can be used cyclically by steps S3, S4, and S5 to process and calculate the image to be detected.

[0146] The above are only preferred embodiments of the present invention. The protection scope of the present invention is not limited to the above embodiments. All technical solutions under the concept of the present invention belong to the protection scope of the present invention. It should be pointed out that for ordinary technicians in this technical field, some improvements and modifications without departing from the principle of the present invention should also be regarded as the protection scope of the present invention.

Claims

1. A machine vision-based device for detecting defects at the mouth of a cylindrical stamping product. It is characterized in that It comprises a testing stand (1), on which a ring-shaped conveyor line (1.1) is arranged, and the ring-shaped conveyor line (1.1) is provided with a positioning sleeve (2) for vertically placing a cylindrical structure (12) with its port facing upwards; The detection stand (1) is provided with a loading / unloading station (1.11), a pre-processing station (1.12), a detection station (1.13) and a sorting station (1.14) in sequence along the circular conveyor line (1.1), and the circular conveyor line (1.1) conveys the positioning sleeve (2) through the loading / unloading station (1.11), the pre-processing station (1.12), the detection station (1.13) and the sorting station (1.14) in sequence; The loading / unloading station (1.11) is used for loading or unloading the cylindrical structure (12); The pretreatment station (1.12) is provided with a high-pressure air blowing pipe (3), and the output end of the high-pressure air blowing pipe (3) blows air to the cylindrical structure (12) on the positioning sleeve (2) to remove debris at the end of the cylindrical structure (12); The inspection station (1.13) is provided with an inspection module, the inspection module comprising a visual component (4) and a controller, the visual component (4) being used to take grayscale images of the inner side and the outer side of the port of the cylindrical structure (12), respectively, the visual component (4) being electrically connected to the controller, the controller storing images of qualified samples, and the controller comparing the grayscale images of the inner side and the outer side of the port of the cylindrical structure (12) with the images of the qualified samples, respectively, to detect whether the sample is qualified; The sorting station (1.14) is provided with a sorting mechanism (5), and the sorting mechanism (5) is used to remove unqualified cylindrical structures (12); The cylindrical structure (12) that is qualified after being detected by the controller is unloaded at the loading / unloading station (1.11); The annular conveyor line (1.1) is further provided with a post-processing station (1.15), and the post-processing station (1.15) is located between the sorting station (1.14) and the loading / unloading station (1.11); The post-processing station (1.15) is provided with a saponification liquid spray pipe (8), and the output end of the saponification liquid spray pipe (8) sprays the saponification liquid onto the cylindrical structure (12) in the positioning sleeve (2) on the conveying line; A cover plate (9) is provided at the post-processing station (1.15), and the cover plate (9) covers the annular conveyor line (1.1) at the post-processing station (1.15) in a relatively closed space; The cover plate (9) is provided with an opening (9.1) corresponding to the port of the cylindrical structure (12) at the post-processing station (1.15), and the output end of the saponified liquid spray pipe (8) extends from the opening (9.1) to the top of the cylindrical structure (12).

2. According to claim 1, a cylindrical stamping product mouth defect detection device based on machine vision, Features: The visual component (4) comprises a column (4.1), a camera (4.2), and a light source (4.3); the column (4.1) is vertically arranged at a detection station (1.13); and the camera (4.2) and the light source (4.3) are respectively connected to the column (4.1) via brackets; The light source (4.3) is located above the port of the cylindrical structure (12) and is used to illuminate the port of the cylindrical structure (12). The camera (4.2) is located above the light source (4.3). The light source (4.3) is provided with an inner hole (4.31) for the irradiation end of the camera (4.2) to photograph the port under illumination.

3. According to claim 2, a cylindrical stamping product mouth defect detection device based on machine vision, Features: A positioning mechanism (6) is also provided at the detection station (1.13), the positioning mechanism (6) comprising two clamping jaws (6.1) arranged opposite to each other, notches (6.11) being provided on the inner sides of the two clamping jaws (6.1), the two clamping jaws (6.1) being connected to a first cylinder (6.2), and the first cylinder (6.2) driving the two clamping jaws (6.1) to move relatively closer or farther away; The detection bench (1) is provided with a second cylinder (6.3), the moving end of the second cylinder (6.3) is connected to the first cylinder (6.2), and the movement of the moving end of the second cylinder (6.3) drives the first cylinder (6.2) to move, so that the two clamping jaws (6.1) move to the cylindrical structure (12) between the two clamping jaws (6.1), or the two clamping jaws (6.1) move to the cylindrical structure (12) away from between the two clamping jaws (6.1); When the two clamping jaws (6.1) move to the point where the cylindrical structure (12) is between the two clamping jaws (6.1), the first cylinder (6.2) drives the two clamping jaws (6.1) to move relatively close to each other, so that the notch (6.11) is clamped on the peripheral side of the cylindrical structure (12).

4. According to claim 1, a cylindrical stamping product mouth defect detection device based on machine vision, Features: The sorting mechanism (5) adopts a sorting robot, and the sorting robot is used to remove unqualified products from the positioning sleeve (2) and transfer them to a defective product compartment (7).

5. According to claim 1, a cylindrical stamping product mouth defect detection device based on machine vision, Features: The annular conveyor line (1.1) is arranged on the surface of the bottom plate (1.2) of the detection stand (1); The loading / unloading station (1.11) is arranged at the front end of the circular conveyor line (1.1), the sorting station (1.14) is arranged at the rear end of the circular conveyor line (1.1), the pre-processing station (1.12) and the inspection station (1.13) are arranged on the left side of the circular conveyor line (1.1), and the post-processing station (1.15) is arranged at the right end of the circular conveyor line (1.1); A driving mechanism (1.3) for driving the annular conveyor line (1.1) to convey is provided inside the annular conveyor line (1.1); The positioning sleeve (2) is vertically provided with a cylindrical groove (2.1), and an opening (2.11) arranged toward the outside is formed by cutting out the side wall of the groove (2.1); The cylindrical structure (12) enters through the opening (2.11) and fits into the groove (2.1).

6. The machine vision-based cylindrical stamping product mouth defect detection device according to claim 5, Features: A baffle (10) is arranged on the bottom plate (1.2), the baffle (10) is connected to the outside of the annular conveyor line (1.1), a break (10.1) is arranged on the baffle (10) at a position corresponding to the loading / unloading station (1.11), and the port is connected to the water tank (11) via a liquid collecting pipe (11.1).

7. A method for detecting mouth defects of cylindrical stamping products based on machine vision. Features: The cylindrical stamping product mouth defect detection device based on machine vision as described in any one of claims 1 to 4 is adopted, and the cylindrical structure (12) detection method comprises the following steps: SS01, vertically placing the cylindrical structure (12) on the positioning sleeve (2) of the loading / unloading station (1.11); SS02, the annular conveyor line (1.1) conveys the positioning sleeve (2) on which the cylindrical structure (12) is placed to the pre-treatment station (1.12); The output end of the high-pressure air blowing pipe (3) of the pretreatment station (1.12) blows air to the cylindrical structure (12) on the positioning sleeve (2) to remove impurities in the saponified liquid; SS03, the annular conveyor line (1.1) conveys the positioning sleeve (2) on which the cylindrical structure (12) is placed from the pretreatment station (1.12) to the inspection station (1.13); The visual component (4) provided at the detection station (1.13) takes grayscale images of the inner side and the outer side of the port of the cylindrical structure (12); The grayscale image captured by the visual component (4) is transmitted to the controller, which stores the image of the qualified sample. The controller compares the grayscale images of the inner side and the outer side of the port of the cylindrical structure (12) with the image of the qualified sample to detect whether the sample is qualified. The detection module detects defects of the cylindrical structure (12) in the following method: S1, template image creation and adaptive detection information extraction; S2, hierarchical region of interest creation; S3, take a photo to obtain the image to be detected; S4, target adaptive traversal detection; S5, generating calculation and detection results; SS04, the circular conveyor line (1.1) conveys the positioning sleeve (2) on which the cylindrical structure (12) is placed from the inspection station (1.13) to the sorting station (1.14). If the detection result of the controller is unqualified, the incoming material of the sorting station (1.14) is judged to be defective material, and the sorting mechanism (5) removes the unqualified cylindrical structure (12) from the positioning sleeve (2); If the controller detects that the material is qualified, the incoming material of the sorting station (1.14) is judged to be good, and the sorting mechanism (5) does not operate; SS05, the cylindrical structure (12) which has been detected as qualified by the controller and sprayed with saponification liquid is unloaded at the loading / unloading station (1.11).

8. According to claim 7, a method for detecting defects at the mouth of a cylindrical stamping product based on machine vision, Features: The annular conveyor line (1.1) is further provided with a post-processing station (1.15), and the post-processing station (1.15) is located between the sorting station (1.14) and the loading / unloading station (1.11); The post-processing station (1.15) is provided with a saponification liquid spray pipe (8), and the output end of the saponification liquid spray pipe (8) sprays the saponification liquid onto the cylindrical structure (12) in the positioning sleeve (2) on the conveying line; After step SS04, step SS04.1 is further provided. SS04.1, the annular conveyor line (1.1) conveys the positioning sleeve (2) passing through the sorting station (1.14) to the post-processing station (1.15), and the output end of the saponification liquid spray pipe (8) of the post-processing station (1.15) sprays the saponification liquid on the cylindrical structure (12) on the positioning sleeve (2).