Spray gun nozzle part conveying equipment and visual counting method
Through the deep learning training object detection model, the problem of counting errors in traditional technology in speed changes and complex scenarios is solved, and the accurate identification and tracking count of spray gun nozzle parts of different models and postures is achieved, which improves the accuracy of the automated transmission process. Sex and efficiency.
Patent Information
- Application Number
- CN202411961610.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-30
- Publication Date
- 2025-02-07
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
In the existing automation of spray gun nozzle parts, the traditional frame difference method and line crossing method are prone to counting errors in speed changes or complex scenarios, and it is difficult to deal with large changes in target scale and shape.
The object detection model trained by deep learning is adopted, combined with the vision system and transmission equipment, to realize the object detection and tracking count of spray gun nozzle parts of different models and postures.
Accurate identification and counting of spray gun nozzle parts of different models and postures on the conveyor belt is achieved, which improves the detection effect, prevents mixing and improves work efficiency.
Smart Images

Figure CN119389717A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of spray guns, and in particular to a spray gun nozzle parts conveying device and a visual counting method. Background Art
[0002] In the automated process of spray gun nozzle part transmission, the existing methods are mostly traditional frame difference method and line passing method. The traditional frame difference method and line passing method must ensure that the object passes through the field of view at a uniform speed. If the speed changes, the counting will be wrong, and the posture of the workpiece cannot undergo too much relative movement. Figure 1 The three workpieces shown on the conveyor belt exhibit a wide variety of postures, making them challenging to detect using traditional template matching algorithms. Traditional area-based counting methods can also cause inaccuracies when overlapping workpieces are present. Traditional algorithms often struggle with complex scenes, especially when the objects vary in scale and shape, or when occlusions occur. Traditional algorithms also struggle with object detection due to the varying scale of objects appearing on the left, center, or right sides of the field of view. Summary of the Invention
[0003] The purpose of the present invention is to solve the problems raised in the above background technology and provide a material needle ventilation structure in a paint gun.
[0004] To achieve the above-mentioned purpose, the technical solution of the present invention is: a spray gun nozzle parts conveying equipment, characterized in that: it includes a host computer, a slave computer, a loading device, a vibration disk device, a conveying device, a visual system, and a unloading device; the slave computer controls the loading device, the vibration disk device, the conveyor belt, the visual system, and the unloading device, the host computer includes a human-computer interaction interface, an image acquisition module, and a system status monitoring, the host computer trains different spray gun nozzle parts target detection models through deep learning, uses the trained model to perform target detection, and performs target tracking and counting on the detection results.
[0005] The present invention also discloses a method for visually counting spray gun nozzle parts, which uses the above-mentioned spray gun nozzle part conveying device and includes the following steps: S1, system startup, connecting PLC and camera, and proceed to step 2; S2, read the PLC start signal, the conveyor belt, vibrating plate, and elevator start, and go to step 3; S3, read the count setting value n, the recipe number, and go to step 4; S4. Initialize variables track_id1 (previous frame ID information), track_id2 (current frame ID information), track_history_id (historical count ID information), track_history (historical track coordinate information), and execute step 5. S5. Read the camera image through the camera SDK and go to step 6. S6: The image is fed into the target detection algorithm and step 7 is executed; S7. If the target detected contains a spray gun nozzle part, execute step 8; otherwise, add the count value to the number of target detections in the previous frame and execute step 12; S8. Send the detected spray gun nozzle part detection frame, category, and confidence information to the target tracking algorithm for tracking, and execute step 9; determine whether there is material mixing. If there is material mixing, immediately send a stop signal and a material mixing alarm signal to the PLC and jump to step 2; S9. Traverse the track_id1 and find that the id does not exist in track_id2, and the horizontal coordinate value of the track_history corresponding id is greater than the set value t, and the id does not exist in track_history_id; if the condition meets step 10, otherwise execute step 5; S10, count value + 1, go to step 11; S11, send the count value to PLC, and execute step 12; S12, determine whether the count value is equal to n, if less than, execute step 5; if the count value is equal to n, execute step 13; S13, send a stop signal to the PLC, and execute step 14; S14, the counting process ends and the process 15 is executed; S15: The elevator and vibrating plate stop, and the conveyor belt stops after moving xmm; go to step 2.
[0006] By adopting the above technical solution, the present invention has the following beneficial effects: This invention uses deep learning to train a target detection model for various types of spray gun nozzle parts. The trained model is then used for target detection, and the detection results are used for target tracking and counting. The method designed by the invention can accurately identify and count spray gun nozzles of different types and postures on a conveyor belt, effectively preventing material mixing, improving detection effectiveness, and increasing work efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0007] Figure 1 This is a schematic diagram of the parts of various types of spray gun nozzles available; Figure 2 It is a schematic diagram of the device of the present invention; Figure 3 It is a schematic diagram of the algorithm flow of the present invention; Figure 4 It is a schematic diagram of the recognition area operation of the present invention. DETAILED DESCRIPTION
[0008] The present invention will be further described with reference to the accompanying drawings.
[0009] See also Figures 1 to 4 The present invention provides a spray gun nozzle parts conveying device, which is characterized by: comprising a host computer, a slave computer, a loading device 1, a vibration disk device 2, a conveying device 3, a visual system 4, and a discharge device 5; the slave computer controls the loading device, the vibration disk device, the conveyor belt, the visual system, and the discharge device; the host computer includes a human-computer interaction interface, an image acquisition module, and a system status monitoring; the host computer trains different spray gun nozzle parts target detection models through deep learning, uses the trained model to perform target detection, and performs target tracking and counting on the detection results.
[0010] The present invention also provides a method for visually counting spray gun nozzle parts, which uses the above-mentioned spray gun nozzle part conveying device and specifically includes the following steps: S1, system startup, connecting PLC and camera, and proceed to step 2; S2, read the PLC start signal, the conveyor belt, vibrating plate, and elevator start, and go to step 3; S3, read the count setting value n, the recipe number, and go to step 4; S4. Initialize variables track_id1 (previous frame ID information), track_id2 (current frame ID information), track_history_id (historical count ID information), track_history (historical track coordinate information), and execute step 5. S5. Read the camera image through the camera SDK and go to step 6. S6: The image is fed into the target detection algorithm and step 7 is executed; S7. If the target detected contains a spray gun nozzle part, execute step 8; otherwise, add the count value to the number of target detections in the previous frame and execute step 12; S8. Send the detected spray gun nozzle part detection frame, category, and confidence information to the target tracking algorithm for tracking, and execute step 9; determine whether there is material mixing. If there is material mixing, immediately send a stop signal and a material mixing alarm signal to the PLC and jump to step 2; S9. Traverse the track_id1 and find that the id does not exist in track_id2, and the horizontal coordinate value of the track_history corresponding id is greater than the set value t, and the id does not exist in track_history_id; if the condition meets step 10, otherwise execute step 5; S10, count value + 1, go to step 11; S11, send the count value to PLC, and execute step 12; S12, determine whether the count value is equal to n, if less than, execute step 5; if the count value is equal to n, execute step 13; S13, send a stop signal to the PLC, and execute step 14; S14, the counting process ends and the process 15 is executed; S15: The elevator and vibrating plate stop, and the conveyor belt stops after moving xmm; go to step 2.
[0011] After collecting, marking and training images of various postures of three types of workpieces A, B and C on the conveyor belt, the present invention can achieve an average target detection accuracy of 99.5%, which can well distinguish the three types of workpieces A, B and C and prevent the existence of mixed materials. Target tracking and counting are not limited by factors such as conveyor belt speed fluctuations and posture changes. Tracking and counting can also be performed well during the conveyor belt startup acceleration stage and stop deceleration stage. Figure 4 As shown, the effective area in the field of view is the green area. When the workpiece enters the field of view from the left side of the green area, the algorithm starts target recognition, multi-target tracking, and prediction of the workpiece's motion trajectory and posture changes. After the workpiece crosses the yellow line and disappears from the field of view, it is counted. The large conveyor belt workpiece will immediately fall into the material box after disappearing. The small conveyor belt workpiece needs to complete a fixed offset xmm after reaching the target number before it can fall into the material box. The above is a detailed introduction to the material needle ventilation structure in a paint gun provided by an embodiment of the present invention. Specific examples are used herein to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the technical solutions disclosed by the present invention. At the same time, for those skilled in the art, according to the ideas of the present invention, there will be changes in the specific implementation methods and application scopes. In summary, the contents of this specification should not be understood as limiting the present invention.
Claims
1. A spray gun nozzle parts conveying device, characterized in that: It includes a host computer, a slave computer, a loading device (1), a vibration plate device (2), a conveying device (3), a visual system (4), and a unloading device (5); the slave computer controls the loading device, the vibration plate device, the conveyor belt, the visual system, and the unloading device; the host computer includes a human-computer interaction interface, an image acquisition module, and a system status monitoring module; the host computer trains target detection models for different spray gun nozzle parts through deep learning, uses the trained models to perform target detection, and performs target tracking and counting on the detection results.
2. A method for visually counting spray gun nozzle parts, characterized in that: The spray gun nozzle parts conveying device according to claim 1 comprises the following steps: S1, system startup, connecting PLC and camera, and proceed to step 2; S2, read the PLC start signal, the conveyor belt, vibrating plate, and elevator are started, and step 3 is executed; S3, read the count setting value n, the recipe number, and execute step 4; S4, initialize variables track_id1 (previous frame id information), track_id2 (current frame id information), track_history_id (historical count id information), track_history (historical track coordinate information), and execute step 5; S5, read the camera image through the camera SDK and execute step 6; S6, the image is sent to the target detection algorithm, and step 7 is executed; S7, if the target detection has a spray gun nozzle part, execute step 8; otherwise, add the count value to the number of target detections in the previous frame, and execute step 12; S8, sending the detected spray gun nozzle part detection frame, category, and confidence information to the target tracking algorithm for tracking, and executing step 9; determining whether there is mixing, if there is mixing, immediately sending a stop signal and a mixing alarm signal to the PLC, and jumping to step 2; S9, traverse track_id1, and the id does not exist in track_id2, and the horizontal coordinate value of the id corresponding to track_history is greater than the set value t, and the id does not exist in track_history_id; if the condition meets step 10, otherwise execute step 5; S10, count value +1, execute step 11; S11, sending the count value to PLC, and executing step 12; S12, determine whether the count value is equal to n, if less than, execute step 5; if the count value is equal to n, execute step 13; S13, sending a stop signal to the PLC, and executing step 14; S14, the counting process ends, and the process 15 is executed; S15, the elevator and vibrating plate stop, and the conveyor belt stops after moving xmm; execute step 2.