Sorting system and sorting method based on AI artificial intelligence recognition
Through the sorting system based on AI artificial intelligence, the vibration device and multiple coordinate convolution detection heads are used to solve the problem of low part recognition efficiency in complex scenarios in the existing technology, and the rapid and accurate automatic identification and classification are achieved, and the variety is adapted to The types of parts can be used to meet the needs of modern industry with high efficiency.
Patent Information
- Application Number
- CN202411056067.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-01
- Publication Date
- 2024-11-05
AI Technical Summary
Existing machine vision technologies have limitations when dealing with complex scenarios, especially in the identification of diverse and overlapping rubber parts, and are inefficient and difficult to meet the modern industry's demand for speed and accuracy.
Using a sorting system based on AI artificial intelligence, the AI module tiles parts evenly through the controller and vibration device. The AI module recognizes the original image, adds additional coordinate channels to improve detection accuracy, and combines multiple coordinate convolution detection heads to process different scales. The goal of achieving rapid and accurate automatic identification and classification.
It realizes the rapid and accurate identification and classification of a large number of parts, reduces labor costs, improves production efficiency and product quality, significantly improves adaptability and scalability, and the identification time does not exceed 10 seconds.
Smart Images

Figure CN118893004A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of industrial automation technology, and in particular relates to a sorting system and a sorting method based on AI artificial intelligence recognition. Background Art
[0002] In the existing technology, machine vision technology plays an important role in the field of industrial automation, especially in parts identification and classification. Conventional machine vision solutions for parts detection mostly rely on template matching and can only detect a single surface, which is not suitable for scenes with a large number of complex heterogeneous surfaces. In addition, the conventional one-by-one identification method is inefficient, complex in structure, and takes a long time to detect, which is difficult to meet the speed and accuracy requirements of modern industry.
[0003] For example, the process of the conventional parts sorting system in the prior art is mainly as follows: first, the parts are loaded onto the inspection tray. Due to the limitations of the lens and the detection algorithm, only 10 to 30 parts can be placed at a time; then the parts are vibrated and broken up, so that some parts are flipped to the expected inspection surface; after obtaining the top view of the parts through the industrial camera, template matching is used for comparative identification: if the identification is successful, a robot is used to grab and classify the parts; if there are parts that have not been inspected, they are vibrated again until a part is flipped to a matching surface for identification and grabbing; finally, after all the parts have been grabbed, a new round of loading and inspection is carried out.
[0004] That is to say, traditional machine vision systems have obvious limitations when dealing with complex scenes, such as the diversity and overlap of rubber parts. At the same time, as the number of parts increases, each part requires a separate template, which will also limit the adaptability and scalability of the system. Since templates need to be matched one by one, when there are a large number of parts, the entire inspection process takes a long time, making it difficult to achieve efficient automatic identification and classification. Summary of the invention
[0005] This technology proposes a sorting system and a sorting method based on AI artificial intelligence recognition to solve the defects mentioned in the background technology; the sorting system of the present application can not only adapt to a variety of parts types, but also greatly improve the recognition speed while ensuring the accuracy of identifying part features, and can realize full inspection of a large number of parts in a batch, meeting the high efficiency requirements of modern industrial production.
[0006] In a first aspect, an embodiment of the present application provides a sorting system based on AI artificial intelligence recognition, the system comprising a controller, a feeding mechanism, a sorting tray, and a shooting device; the sorting tray is configured with a vibration device; the shooting device is configured with an AI module;
[0007] The controller is used to start the vibration device to vibrate the sorting tray when detecting that the parts pile enters the sorting tray, so that the multiple parts to be tested in the parts pile are evenly spread in the sorting tray;
[0008] The photographing device is used to capture images of the sorting tray to obtain an original image containing a plurality of parts to be tested;
[0009] The AI module is used to identify the part features of each of the parts to be tested in the original image to obtain an identification result;
[0010] The controller is further configured to determine a low-confidence part from the recognition result, obtain coordinate information of the low-confidence part in the original image; intercept a target slice image in the original image based on the coordinate information, and verify and reason the target slice image to determine part features of the low-confidence part;
[0011] The controller is also used to control the sorting tray to pour the parts pile into the parts storage area when the part features of each part to be tested are determined.
[0012] In the embodiment of the present application, by integrating the automatic unloading device and the vibration plate, it is ensured that the parts are laid flat without overlap, and fast and accurate automatic identification and classification are achieved. The whole process of unloading and vibration identification does not exceed 10 seconds, which effectively improves the automation level of the production line. The system can quickly and accurately identify the characteristic information of the parts to be tested, ensure the correct classification and use of the parts, and reduce production defects caused by identification errors.
[0013] In one example, the system further includes a manipulator device;
[0014] The robot device is configured to take out the heterogeneous parts from the parts pile when there are heterogeneous parts in the recognition results.
[0015] In the embodiments of the present application, the automated recognition system reduces the reliance on manual operations, reduces labor costs, reduces human errors, and improves production efficiency and product quality.
[0016] In one example, the AI module is configured to add an additional coordinate channel to the input feature map of the convolutional layer, wherein the additional coordinate channel is used to represent the horizontal coordinate information and the vertical coordinate information of the pixels of the input feature map in the input feature map.
[0017] In the embodiment of the present application, by introducing the AI module, an additional coordinate channel is added to the convolution operation, so that the model can better understand the texture spatial position relationship of the parts in the image, thereby improving the detection accuracy.
[0018] In a second aspect, the present invention further proposes a sorting method based on AI artificial intelligence recognition, the sorting method is applied to a sorting system, and the method comprises:
[0019] When it is detected that a part pile enters a sorting tray, the sorting tray is vibrated so that a plurality of parts to be tested in the part pile are evenly spread in the sorting tray;
[0020] Capturing images of the sorting tray to obtain original images containing a plurality of parts to be tested;
[0021] Calling the target model to identify the part features of each of the parts to be tested in the original image to obtain an identification result;
[0022] Determine low-confidence parts from the recognition results, and obtain coordinate information of the low-confidence parts in the original image;
[0023] intercepting a target slice image in the original image based on the coordinate information, and calling the target model to verify and reason the target slice image to determine the part features of the low-confidence part;
[0024] When the part feature of each of the parts to be tested is determined, the sorting tray is controlled to pour each of the parts to be tested into the parts storage area.
[0025] In the embodiment of the present application, by integrating the automatic unloading device and the vibration plate, it is ensured that the parts are laid flat without overlap, and fast and accurate automatic identification and classification are achieved. The whole process of unloading and vibration identification does not exceed 10 seconds, which effectively improves the automation level of the production line. The system can quickly and accurately identify the characteristic information of the parts to be tested, ensure the correct classification and use of the parts, and reduce production defects caused by identification errors.
[0026] In one example, the calling of the target model to identify the part features of each of the parts to be tested in the original image to obtain the identification result includes:
[0027] Using the original image as an input feature map of a convolutional layer of a target model, adding an additional coordinate channel to the input feature map, wherein the additional coordinate channel is used to characterize the horizontal coordinate information and the vertical coordinate information of each pixel of the part to be tested in the original image;
[0028] Identify the part features of each of the parts to be tested in the original image according to the horizontal coordinate information and the vertical coordinate information of the pixels of each of the parts to be tested in the original image to obtain an identification result;
[0029] The target model includes sample feature information of various trained target part samples, and the sample feature information includes at least part type samples, part shape samples, and part angle offset samples.
[0030] In the embodiment of the present application, by adding an additional coordinate channel in the convolution operation, the model can better understand the texture space position relationship of the parts in the image, thereby improving the detection accuracy.
[0031] In one example, a detection head using multiple coordinate convolutions is used to identify the part features of each part to be tested in the original image, and the part features of each part to be tested in the original image are identified according to the horizontal coordinate information and the vertical coordinate information of the pixel of each part to be tested in the original image to obtain the identification result, including:
[0032] In the process of using the first detection head to identify the part features of the part to be tested, the original image is used as the first input feature map, and according to the first horizontal coordinate information and the first vertical coordinate information of each pixel of the part to be tested in the first input feature map, a first Euclidean distance from the pixel of the part to be tested to the center point in the first input feature map is calculated;
[0033] In the process of using the second detection head to identify the part features of the part to be tested, the original image is used as the second input feature map, and according to the second horizontal coordinate information and the second vertical coordinate information of each pixel of the part to be tested in the second input feature map, the second Euclidean distance from the pixel of the part to be tested to the center point in the second input feature map is calculated;
[0034] In the process of using the third detection head to identify the part features of the part to be tested, the original image is used as a third input feature map, and according to the third horizontal coordinate information and the third vertical coordinate information of each pixel of the part to be tested in the third input feature map, a third Euclidean distance from the pixel of the part to be tested to the center point of the third input feature map is calculated;
[0035] The first Euclidean distance, the second Euclidean distance and the third Euclidean distance are spliced in a specified dimension to obtain target part feature information and target coordinate information of the part to be measured.
[0036] In an embodiment of the present application, a detection head with multiple coordinate convolutions is used to identify the part features of each part to be tested in the original image, so that the model can process targets of different scales at the same time, improve the ability of multi-target detection, and more easily realize single-part multi-pose detection that is difficult to achieve with traditional machine vision.
[0037] In one example, calling the target model to perform verification reasoning on the target slice image to determine the part features of the low-confidence part includes:
[0038] Using the target slice image as an input feature map of a convolutional layer, adding an additional coordinate channel in the target slice image, wherein the additional coordinate channel is used to characterize the horizontal coordinate information and the vertical coordinate information of each pixel of the low-confidence part in the target slice image;
[0039] According to the horizontal coordinate information and the vertical coordinate information of the pixel of each low-confidence part in the target slice image, the part feature of each low-confidence part in the target slice image is identified to obtain an identification result.
[0040] In an embodiment of the present application, during the initial screening of batch parts, if the features of individual parts cannot be identified, they can be further inferred by adding additional coordinate channels in the convolution operation to determine the part features of each low-confidence part.
[0041] In one example, after the step of performing image acquisition on the sorting tray to obtain an original image containing a plurality of parts to be tested, the method further includes:
[0042] If there are heterogeneous parts in the recognition result, a robot device is called to take the heterogeneous parts out of the parts pile;
[0043] When the part feature of each of the parts to be tested is determined, controlling the sorting tray to pour each of the parts piles into the parts storage area comprises:
[0044] When the part features of each of the to-be-tested parts of the same type are determined, the sorting tray is controlled to pour each of the part piles into a part storage area.
[0045] In the embodiment of the present application, when a heterogeneous part is detected, the heterogeneous part can be automatically removed from the parts pile, thereby reducing the reliance on manual operation and lowering the labor cost.
[0046] In a third aspect, the present invention further proposes a computer device, comprising a memory, a controller, and a computer program stored in the memory, wherein the controller implements the method described in the first aspect when executing the computer program.
[0047] In a fourth aspect, the present invention further proposes a computer storage medium, which is a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a controller, the method described in the first aspect above is implemented. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0049] Figure 1 It is a structural block diagram of a sorting system based on AI artificial intelligence recognition provided by an embodiment of the present application;
[0050] Figure 2 This is a physical picture of a sorting system based on AI artificial intelligence recognition provided in an embodiment of the present application;
[0051] Figure 3 This is a flow chart of an embodiment of a sorting method based on AI artificial intelligence recognition provided by the present application;
[0052] Figure 4 This is a schematic diagram of the visual inspection results corresponding to the initial screening of a batch of rubber parts using conventional machine vision recognition methods;
[0053] Figure 5 A schematic diagram of the visual inspection results corresponding to the initial screening of a batch of rubber parts using the sorting method based on AI artificial intelligence recognition provided by an embodiment of the present application;
[0054] Figure 6 It is a structural block diagram of a computer device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0055] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.
[0056] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.
[0057] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0058] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0059] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0060] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0061] It is understandable that the sorting method of the traditional parts sorting system in the prior art is:
[0062] 1. The parts pile is loaded and then transferred to the inspection tray. Due to the limitations of the lens and inspection algorithm, only 10 to 30 parts can be placed at a time;
[0063] 2. Vibrate the parts to break them up and flip some of them to the expected inspection surface;
[0064] 3. After obtaining the top view of the part through the industrial camera, use template matching for comparative identification;
[0065] 4. If the recognition is successful, the robot is used to grab and classify;
[0066] 5. If there are parts that have not been inspected, the machine will vibrate again until a part is turned over to a matching surface for identification and grabbing;
[0067] 6. After all parts have been grabbed, a new round of loading inspection will be carried out.
[0068] The defects of the sorting method of the conventional system of the above prior art are: in the process of processing complex scenes, such as the diversity and overlap of rubber parts, it will show obvious limitations. At the same time, as the number of parts increases, each part requires a separate template, which will also limit the adaptability and scalability of the system. Since the templates need to be matched one by one, when the number of parts is large, the entire detection process takes a long time, and it is difficult to achieve efficient automatic identification and classification.
[0069] In response to the above problems, the present invention application proposes a sorting system and a sorting method based on AI artificial intelligence recognition. The technical solution of the embodiment of the present application can not only adapt to a variety of parts types, but also greatly improve the recognition speed while ensuring high accuracy, and realize full inspection of a large number of parts in one batch, meeting the high efficiency requirements of modern industrial production.
[0070] Embodiment 1
[0071] refer to Figure 1 , this embodiment 1 proposes a sorting system based on AI artificial intelligence recognition, such as Figure 1 As shown, the sorting system based on AI artificial intelligence recognition provided by this embodiment mainly includes a controller 01, a feeding mechanism 02, a sorting tray 03, a shooting device 04, and a manipulator device 05; wherein the sorting tray 03 is equipped with a vibration device 031, and the shooting device 04 is equipped with an AI module 041; in a specific implementation, as Figure 2 As shown, the controller 01 can be Figure 2 The CPU central controller of the computer device is connected with the vibration device 031, the sorting plate 03, the shooting device 04 (AI module 041), and the manipulator device 05 through electrical signals, wherein:
[0072] The feeding mechanism 02 is used to feed the parts pile into the sorting tray 03;
[0073] The controller 01 is used to start the vibration device 031 to vibrate the sorting tray 03 when detecting that the parts pile enters the sorting tray 03, so that the multiple parts to be tested in the parts pile are evenly spread in the sorting tray 03;
[0074] In a specific implementation, the parts pile is fed into the sorting tray 03 through a specific loading mechanism 03 (such as a conveying mechanism). The sorting tray 03 is equipped with a sensor. When the sensor senses that the sorting tray 03 changes from an empty state to a loaded state, the sensor transmits a signal to the controller 01. The controller 01 starts the vibration device 031 to vibrate the sorting tray 03. The vibration frequency of the vibration device 031 is used to make the parts pile evenly spread out in the sorting tray 03 without overlapping, which is the key to ensure the accuracy of subsequent visual inspection and avoid detection errors or omissions due to overlapping or aggregation of parts.
[0075] The photographing device 04 is used to collect images of the sorting tray 03 to obtain an original image containing a plurality of parts to be tested;
[0076] In a specific implementation, when the sensor senses that the sorting tray 03 changes from an empty state to a loaded state, it transmits a signal to the camera 04, which collects images of the sorting tray 03 to obtain an original image containing multiple parts to be tested; the camera 04 of the embodiment of the present application preferably uses a high-resolution industrial camera, which can capture clearer details of parts and improve the accuracy of detection. Each batch of detection can cover 100 to 150 rubber parts of different models, showing the efficiency and flexibility of the system.
[0077] AI module 041, used for identifying the part features of each part to be tested in the original image to obtain an identification result;
[0078] It is understandable that the AI module 041 can characterize the target model, which includes sample feature information of various trained target part samples, and the sample feature information includes at least part type samples, part shape samples, and part angle offset samples; the AI module 041 is configured to add an additional coordinate channel to the input feature map of the convolutional layer, and the additional coordinate channel is used to characterize the horizontal coordinate information and vertical coordinate information of the pixels of the input feature map in the input feature map.
[0079] In the specific implementation, the embodiment of the present application adopts a single-stage target detection algorithm and uses coordinate convolution to replace the original detection head. The algorithm adopted by the embodiment of the present application improves the path of gradient feedback in the deep learning model through the PGI (Programable Gradient Infomation) module to reduce the loss of network information during the training process.
[0080] The embodiments of the present application can divide the part sample set into a training set and a verification set required for model training. For example, the model training device can arrange the various part samples in the above-mentioned part sample set (each sample contains a sample image, and each sample image corresponds to the part type, the shape of the part at various angles and other related feature information) in random order, and divide each sample into a training set and a verification set according to the proportion. For example, 75% of the samples in a part sample set are divided into a training set, and the remaining 25% of the samples are divided into a verification set, wherein each sample in the training set is used to train to obtain a target model (the model training device can obtain the target model by training through a supervised machine learning algorithm), and each sample in the verification set is used to detect the accuracy of the target model.
[0081] It generates a "trusted gradient" by adding an auxiliary reversible branch, thereby improving the training efficiency and performance of the model. At the same time, because the auxiliary reversible branch is not needed in the reasoning stage, it does not increase unnecessary reasoning consumption. At the same time, the algorithm adopted in the embodiment of the present application can also achieve high precision while maintaining the lightweight and high speed of the network by using the GELAN (Generalized Efficient Layer Aggregation Network) network architecture, further improving the efficiency and accuracy of detection.
[0082] In addition, before the AI module 041 performs the recognition operation, the operator will pre-set the type of the part to be detected this time as the preset target type before running the sorting system; if the AI module 041 recognizes that the type of a part does not belong to the preset target type, the part is determined to be a heterogeneous part;
[0083] The controller 01 is further used to determine the low-confidence part from the recognition result, obtain the coordinate information of the low-confidence part in the original image; intercept the target slice image in the original image based on the coordinate information, and call the AI module 041 to verify and reason the target slice image to determine the part features of the low-confidence part;
[0084] It can be understood that the part features of the part to be tested may include at least features such as the shape, type, and model of the part. If there are parts whose part features cannot be effectively identified by the AI module 041, they are determined to be low-confidence parts. For these low-confidence parts, the system will capture a high-definition slice image in the original image based on its coordinate information, and call the AI module 041 again. By adding an additional coordinate channel in the convolution operation, the target model can better understand the texture spatial position relationship of the part to be tested in the target high-definition slice image, and use a detection head with multiple coordinate convolutions to identify the part features of the low-confidence parts in the target high-definition slice image, and perform more in-depth verification and reasoning to determine the accurate model of the low-confidence parts.
[0085] The robot device 05 is configured to take out the heterogeneous parts from the parts pile when there are heterogeneous parts in the recognition result;
[0086] The controller 01 is also used to control the sorting tray 03 to pour the currently contained parts pile into the parts storage area when the part features of each part to be tested are determined.
[0087] In the specific implementation, the controller 01 will control the robot device 05 to accurately screen out the heterogeneous parts (i.e., parts that do not conform to the model of the current inspection batch) according to the recognition results; the remaining parts of the same model will be automatically dumped into the parts storage area for subsequent processing or storage. At the same time, the system is ready to conduct the next batch of inspections, forming a continuous and automated production process.
[0088] In the process of identifying the parts to be tested in the sorting system of the embodiment of the present application, the AI module 041 is configured to add an additional coordinate channel to the input feature map of the convolutional layer, and the additional coordinate channel is used to represent the horizontal coordinate information and the vertical coordinate information of the pixels of the input feature map in the input feature map.
[0089] It is understandable that the embodiment of the present application adds an AI module 041 including coordinate convolution, adds coordinate information in the convolution operation, and improves the model's ability to understand spatial positions (the specific implementation of AI module 041 can be found in the introduction of the following embodiment 2). In the present invention, corresponding improvements are made to the adaptation of coordinate convolution, which enhances the model's global understanding of part details, so that AI module 041 achieves more efficient and accurate recognition effects in the identification task of the parts to be tested (especially the rubber parts identification task), cooperates with the feeding mechanism 02 to transfer the parts to be tested to the sorting tray 03, and vibrates the parts pile on the sorting tray 03 through the vibration device 031 so that the parts are laid flat and uncovered, thereby achieving automatic recognition and classification of at least one hundred types of parts each time.
[0090] The sorting system of the embodiment of the present application realizes efficient and accurate detection and classification of rubber parts through highly integrated automation equipment and advanced visual recognition technology, providing strong support for industrial automation production.
[0091] Embodiment 2
[0092] Corresponding to the sorting system of the above-mentioned embodiment 1, the second embodiment of the present application provides a sorting method based on AI artificial intelligence recognition, referring to Figure 3 , the method comprising:
[0093] Step S10, when it is detected that the parts pile enters the sorting tray, the sorting tray is vibrated so that the multiple parts to be tested in the parts pile are evenly spread in the sorting tray.
[0094] It should be noted that the execution subject of the sorting method of the second embodiment of the present application is the sorting system of the first embodiment above;
[0095] In a specific implementation, the embodiment of the present application is explained by taking the quality inspection line of processed parts as an example. When a pile of rubber parts to be tested are fed into a sorting tray through a specific loading mechanism, the sensor configured on the sorting tray will sense that the sorting tray has changed from an empty state to a loaded state. The sensor will transmit a signal to the controller of the sorting system. The sorting system starts the vibration device to vibrate the sorting tray. The vibration frequency of the vibration device is used to make the parts piled in the sorting tray evenly and without overlapping, which is the key to ensuring the accuracy of subsequent visual inspection and avoiding detection errors or omissions due to overlapping or aggregation of parts.
[0096] Step S20, performing image acquisition on the sorting plate to obtain an original image containing a plurality of parts to be tested;
[0097] In the specific implementation, when the sensor senses that the sorting plate changes from an empty state to a loaded state, it transmits a signal to the camera, which collects images of the sorting plate to obtain an original image containing multiple parts to be tested; the camera of the embodiment of the present application preferably uses a high-resolution industrial camera, which can capture clearer details of parts and improve the accuracy of detection. Each batch of detection can cover 100 to 150 rubber parts of different models, showing the efficiency and flexibility of the system.
[0098] Step S30, calling the target model to identify the part features of each of the parts to be tested in the original image to obtain a recognition result;
[0099] Specifically, the target model includes sample feature information of various trained target part samples, and the sample feature information includes at least part type samples, part shape samples, and part angle offset samples; the target model is configured to add an additional coordinate channel to the input feature map of the convolutional layer, and the additional coordinate channel is used to characterize the horizontal coordinate information and the vertical coordinate information of the pixels of the input feature map in the input feature map.
[0100] In a specific implementation, the embodiment of the present application needs to pre-build a neural network model to learn relevant part feature information such as the shapes of different types of parts at different angles; for example, the part sample set can be divided into a training set and a verification set required for model training. For example, the model training device can arrange the various part samples in the above-mentioned part sample set (each sample contains a sample image, and each sample image corresponds to the part type, the shape of the part at various angles and other relevant feature information) in random order, and divide each sample into a training set and a verification set according to the proportion. For example, 75% of the samples in a part sample set are divided into a training set, and the remaining 25% of the samples are divided into a verification set, wherein each sample in the training set is used to train to obtain the target model, and each sample in the verification set is used to detect the accuracy of the target model.
[0101] The embodiment of the present application automatically learns the characteristics of different parts (part type, various angle offsets when parts are placed, etc.) through a large amount of training data, and can automatically adapt to new types of parts without manual adjustment or redesign of templates. Compared with traditional visual inspection solutions, the embodiment of the present application uses this adaptive capability to enable the system to maintain efficient recognition performance when facing parts of different types and shapes, thereby reducing design costs.
[0102] Step S40, determining low-confidence parts from the recognition results, and obtaining coordinate information of the low-confidence parts in the original image;
[0103] In addition, before calling the target model to perform the recognition operation, the operator will pre-set the type of parts to be detected this time as the preset target type before running the sorting system; if the type of a part recognized by calling the target model does not belong to the preset target type, the part is determined to be a heterogeneous part;
[0104] Step S50, intercepting a target slice image in the original image based on the coordinate information, calling the target model to verify and reason the target slice image to determine the part features of the low-confidence part;
[0105] The algorithm used in the embodiment of the present application is based on a single-stage target detection algorithm. By converting the target detection task into a regression problem, a neural network is used to directly predict the bounding box and category of the target. The reasoning process mainly includes the following steps:
[0106] Input image preprocessing: Scale the input image to a fixed size and normalize it to meet the input requirements of the model;
[0107] Feature extraction: Extract image features through a series of convolutional layers, using deeper convolutional neural networks to capture more image details;
[0108] Detection head: Based on feature extraction, multiple detection heads using coordinate convolution are used to predict the bounding box and category of the object. Each detection head is responsible for object detection at different scales to improve the accuracy of detection. The detection head representation is an integral part of the algorithm and is responsible for identifying and locating the object in the input image. The detection head is usually composed of multiple convolutional layers and fully connected layers to extract features and perform object classification and location;
[0109] Non-maximum suppression: Post-process the predicted bounding boxes to remove overlapping boxes and keep only the most likely target boxes.
[0110] It should be noted that, during the execution of step S30, if there are heterogeneous parts in the identification result, the robot device is called to take the heterogeneous parts out of the parts pile;
[0111] It is understandable that part features may include at least features such as part shape, type, and model. If there are parts whose part features cannot be effectively identified by the target model, they are determined to be low-confidence parts. For these low-confidence parts, the system will capture high-definition slice images in the original image based on their coordinate information, and call the target model again. By adding additional coordinate channels in the convolution operation, the target model can better understand the texture space position relationship of the part to be tested in the target high-definition slice image, and use a detection head with multiple coordinate convolutions to identify the part features of the low-confidence parts in the target high-definition slice image, and perform more in-depth verification and reasoning to determine the accurate model of the low-confidence parts.
[0112] Step S60, when the part feature of each of the parts to be tested is determined, control the sorting tray to pour each of the parts to be tested into the parts storage area.
[0113] When the part features of each of the to-be-tested parts of the same type are determined, the sorting tray is controlled to pour each of the part piles into a part storage area.
[0114] Furthermore, based on the above single-stage target detection algorithm, the embodiment of the present application further improves the detection head of the coordinate convolution to enhance the model's ability to understand the spatial position. The specific improvements are as follows:
[0115] Improvement of AI module 041 (target model): By adding an additional coordinate channel to the input feature map of the convolution layer, the additional coordinate channel is used to characterize the horizontal coordinate information and vertical coordinate information of the pixels of the input feature map in the input feature map. That is, adding coordinate information to the convolution operation enables the convolution neural network model to better understand the spatial position relationship in the image. Coordinate convolution adds a coordinate channel to the input feature map, so that the convolution operation can perceive the absolute position of the pixel, thereby improving the detection accuracy.
[0116] Accordingly, the step S30 further includes:
[0117] Sub-step S301, using the original image as an input feature map of a convolutional layer, adding an additional coordinate channel to the input feature map, wherein the additional coordinate channel is used to characterize the horizontal coordinate information and the vertical coordinate information of each pixel of the part to be tested in the original image;
[0118] Sub-step S302: identifying the part features of each of the parts to be tested in the original image according to the horizontal coordinate information and the vertical coordinate information of the pixels of each of the parts to be tested in the original image to obtain a recognition result.
[0119] Accordingly, the step of verifying and reasoning the target slice image in step S50 to determine the part features of the low-confidence part includes:
[0120] Using the target slice image as an input feature map of a convolutional layer, adding an additional coordinate channel in the target slice image, wherein the additional coordinate channel is used to characterize the horizontal coordinate information and the vertical coordinate information of each pixel of the low-confidence part in the target slice image;
[0121] According to the horizontal coordinate information and the vertical coordinate information of the pixel of each low-confidence part in the target slice image, the part feature of each low-confidence part in the target slice image is identified to obtain an identification result.
[0122] Add detection heads: Three detection heads that require coordinate convolution are added to the single-stage target detection algorithm configuration file. These detection heads can better capture targets of different scales and improve detection accuracy and speed.
[0123] Accordingly, the sub-step S302 further includes:
[0124] In the process of using the first detection head to identify the part features of the part to be tested, the original image is used as the first input feature map, and according to the first horizontal coordinate information and the first vertical coordinate information of each pixel of the part to be tested in the first input feature map, a first Euclidean distance from the pixel of the part to be tested to the center point in the first input feature map is calculated;
[0125] In the process of using the second detection head to identify the part features of the part to be tested, the original image is used as the second input feature map, and according to the second horizontal coordinate information and the second vertical coordinate information of each pixel of the part to be tested in the second input feature map, the second Euclidean distance from the pixel of the part to be tested to the center point in the second input feature map is calculated;
[0126] In the process of using the third detection head to identify the part features of the part to be tested, the original image is used as a third input feature map, and according to the third horizontal coordinate information and the third vertical coordinate information of each pixel of the part to be tested in the third input feature map, a third Euclidean distance from the pixel of the part to be tested to the center point of the third input feature map is calculated;
[0127] The first Euclidean distance, the second Euclidean distance and the third Euclidean distance are spliced in a specified dimension to obtain target part feature information and target coordinate information of the part to be measured.
[0128] Through the above improvements, the sorting system of the embodiment of the present application can complete the identification of at least one hundred different rubber parts within one second. In the specific implementation:
[0129] Enhanced spatial position perception: Traditional convolution operations cannot perceive the absolute position of pixels, but the embodiment of the present application adds a coordinate channel to the convolution layer of the AI module 041, so that the convolution operation can perceive the absolute position of pixels:
[0130]
[0131] Among them, x_c is the horizontal coordinate channel generated by the part in the x-axis direction of the original image; y_c is the vertical coordinate channel generated by the part in the y-axis direction of the original image; x_dim is the dimension of the horizontal coordinate x, which indicates the dimension size of the input tensor in the x-axis direction; y_dim is the dimension of the vertical coordinate y, which indicates the dimension size of the input tensor in the y-axis direction; arange() represents the generation of a sequence, which means generating a sequence from 0 to a specified size;
[0132] This embodiment enhances the spatial position perception capability so that the model performs better when processing tasks with obvious spatial structures (such as target detection and image segmentation).
[0133] Multi-scale detection: The three added coordinate convolution detection heads can process objects of different scales at the same time, improving the accuracy and speed of detection. Each detection head can independently predict the bounding box and category of the target, thus achieving efficient multi-target detection and improving the detection accuracy and robustness of the model in complex scenes.
[0134] Fast reasoning: The introduction of AI module 041 does not significantly increase the computational complexity, and still maintains the single-stage detection architecture of YOLOv9, making the reasoning process very fast. By optimizing the model structure and introducing AI module 041, the sorting system of the embodiment of the present application can complete the processing of the input image within 1 second, and then can obtain the target part feature information and target coordinate information of the part to be tested within 1 second.
[0135]
[0136] output=cat([output,rr],dim=1)
[0137] Among them, dim is the dimension, output is the output tensor after model processing, which can represent the recognition result of the part to be tested in the original image; rr is the Euclidean distance from the pixel of the part to be tested to the center point in the input feature map; cat() means splicing multiple tensors in the specified dimension.
[0138] By introducing the AI module 041 in the embodiment of the present application, the model can better understand the spatial position relationship of the texture of the parts in the image, thereby improving the detection accuracy;
[0139] Compared with the current conventional image detection algorithms, the single-stage detection architecture provided in the embodiment of the present application, coupled with the optimized model structure, makes the reasoning process faster and can complete the identification of hundreds of different rubber parts within 1 second.
[0140] The three coordinate convolution detection heads added in the embodiment of the present application enable the model to process targets of different scales simultaneously, improve the ability of multi-target detection, and more easily realize single-part multi-posture detection that is difficult to achieve with traditional machine vision.
[0141] It should be noted that the embodiment of the present application automatically learns the characteristics of different parts (part types, various angle offsets when parts are placed, etc.) through a large amount of training data, and can automatically adapt to new types of parts without manual adjustment or redesign of templates. Compared with traditional visual inspection solutions, the embodiment of the present application uses this adaptive capability to enable the system to maintain efficient recognition performance when facing parts of different types and shapes, thereby reducing design costs and the required expert experience.
[0142] Furthermore, in some other embodiments, the model of the embodiment of the present application can learn the characteristics of parts under different lighting and background conditions by training on a variety of enhanced training data, and has a strong anti-interference effect in the environment, so as to perform better in practical applications. The introduction of AI module 041 further enhances the model's ability to understand spatial positions, allowing the system to maintain high-precision detection performance in complex environments.
[0143] Finally, it should be emphasized that the technical solution of the present application is particularly applicable to the quality inspection of rubber parts. It is understandable that the quality inspection of rubber parts by visual recognition technology has always been a technical problem to be solved. Since the color of most rubber parts is black, the gray-black color easily absorbs light and cannot shine during visual inspection, and it is very easy to detect some defects. Moreover, since rubber parts are large and irregular, surface defects cannot be detected. In addition, rubber parts generally do not stretch in their own characteristics, and it is not easy to detect internal structural cracks and particles, such as Figure 4 As shown, Figure 4 This is a schematic diagram of the visual inspection results when a batch of rubber parts are initially screened using conventional machine vision recognition methods: Figure 4 The parts enclosed by the rectangle are the target types (among the batch of parts to be tested) identified by the conventional machine vision recognition method, the parts enclosed by the ellipse are the heterogeneous parts (among the batch of parts to be tested) identified by the conventional machine vision recognition method, and the parts enclosed by the hexagon are the types of parts that are not identified by the conventional machine vision recognition method; Figure 4 It can be seen that the rubber parts have a low resolution due to their dark color. After the parts enter the sorting tray and are scattered, some heterogeneous parts will be tilted and placed on the sorting tray in an unconventional way. Since the parts are heterogeneous components, as long as there is an angle offset, the conventional machine vision recognition method mainly relies on template matching to identify the parts. When there are some new contours of the parts to be tested, it is relatively complicated to use conventional machine vision recognition methods to identify them, and it is easy to fail to identify the part type (such as Figure 4 The parts enclosed by the hexagon in the figure).
[0144] contrast Figure 5 , Figure 5 A schematic diagram of the visual inspection results corresponding to the initial screening of a batch of rubber parts using the machine vision recognition method of an embodiment of the present application; Figure 5 The parts enclosed by the rectangular frame are the target types in the batch of parts to be tested identified by the machine vision recognition method of the embodiment of the present application, and the parts enclosed by the ellipse frame are the heterogeneous parts in the batch of parts to be tested identified by the machine vision recognition method of the embodiment of the present application. Figure 5 and Figure 4 It can be seen that in Figure 4 There is no part type identified in Figure 5 However, it can be accurately identified. This is because the embodiment of the present application automatically learns the characteristics of different parts (part types, various angle offsets when parts are placed, etc.) through a large amount of training data. On this basis, by adding additional coordinate channels in the convolution operation, the target model can better understand the texture spatial position relationship of the rubber parts in the captured image to be inspected, and use a detection head with multiple coordinate convolutions to identify the part features of each rubber part in the image to be inspected, so that the target model can simultaneously process target rubber parts of different scales, thereby improving the ability of multi-target detection, and can more easily realize the multi-posture detection of a single rubber part that is difficult to achieve with traditional machine vision; the target model can automatically adapt to new types of parts without the need for manual adjustment or redesign of templates.
[0145] Embodiment 3
[0146] Figure 6 This is a schematic diagram of the structure of a computer device provided in one embodiment of the present application. Figure 6 As shown, the computer device of the third embodiment includes: at least one controller 01 (which is also the controller of the sorting system corresponding to the first embodiment), a memory 32, and a computer program 33 stored in the memory 32 and executable on the at least one controller 01. When the controller 01 executes the computer program 33, the steps in any of the above-mentioned method embodiments are implemented.
[0147] The server of the third embodiment is the server of the first embodiment of the method described above ( Figure 2 The computer device involved in the embodiment of the present application will be connected to the vibration device 031, the sorting plate 03, the shooting device 04 (AI module 041), and the manipulator device 05 of the system through electrical signals.
[0148] Those skilled in the art will understand that Figure 6 It is only an example of a computer device and does not constitute a limitation of the computer device. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, it may also include input and output devices, network access devices, etc.
[0149] The controller 01 may be a central processing unit (CPU), or other general controllers, digital signal processors (DSP), application specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general controller may be a microcontroller or any conventional controller.
[0150] In some embodiments, the memory 32 may be an internal storage unit of the server 3, such as a hard disk or memory of the server 3. In other embodiments, the memory 32 may also be an external storage device of the server 3, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the server 3. Further, the memory 32 may also include both an internal storage unit of the server 3 and an external storage device. The memory 32 is used to store an operating system, an application program, a boot loader (BootLoader), data, and other programs, such as the program code of the computer program. The memory 32 may also be used to temporarily store data that has been output or is to be output.
[0151] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.
[0152] In addition, an embodiment of the present application further provides a computer storage medium, which is a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a controller, the steps in the above-mentioned method embodiments can be implemented.
[0153] If the integrated unit is implemented in the form of 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 present application implements all or part of the processes in the above-mentioned embodiment method, which can be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the controller. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium can at least include: any entity or device that can carry the computer program code to the camera / terminal device, recording medium, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, RandomAccess Memory), electric carrier signal, telecommunication signal and software distribution medium. For example, a USB flash drive, a mobile hard disk, a magnetic disk or an optical disk. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electric carrier signals and telecommunication signals.
[0154] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0155] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0156] In the embodiments provided in the present application, it should be understood that the disclosed devices / network equipment and methods can be implemented in other ways. For example, the device / network equipment embodiments described above are merely schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0157] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0158] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. A sorting system based on AI artificial intelligence recognition, characterized in that: The system includes a controller, a feeding mechanism, a sorting tray, and a camera; the sorting tray is equipped with a vibration device; the camera is equipped with an AI module; The controller is used to start the vibration device to vibrate the sorting tray when detecting that the parts pile enters the sorting tray, so that the multiple parts to be tested in the parts pile are evenly spread in the sorting tray; The photographing device is used to capture images of the sorting tray to obtain an original image containing a plurality of parts to be tested; The AI module is configured to identify the part features of each of the parts to be tested in the original image to obtain an identification result; The controller is further used to determine low-confidence parts from the recognition results, and obtain coordinate information of the low-confidence parts in the original image; Based on the coordinate information, intercept a target slice image in the original image, and call the AI module to verify and reason the target slice image to determine the part features of the low-confidence part; The controller is also used to control the sorting tray to pour the parts pile into the parts storage area when the part features of each part to be tested are determined.
2. The sorting system according to claim 1, characterized in that: The system also includes a manipulator device; The robot device is configured to take out the heterogeneous parts from the parts pile when there are heterogeneous parts in the recognition results.
3. The sorting system according to claim 1, characterized in that: The AI module is configured to add an additional coordinate channel to the input feature map of the convolution layer, where the additional coordinate channel is used to represent the horizontal coordinate information and the vertical coordinate information of the pixels of the input feature map in the input feature map.
4. A sorting method based on AI artificial intelligence recognition, characterized in that: The sorting method is applied to a sorting system, and the method comprises: When it is detected that a part pile enters a sorting tray, the sorting tray is vibrated so that a plurality of parts to be tested in the part pile are evenly spread in the sorting tray; Capturing images of the sorting tray to obtain an original image containing a plurality of parts to be tested; Calling the target model to identify the part features of each of the parts to be tested in the original image to obtain an identification result; Determine low-confidence parts from the recognition results, and obtain coordinate information of the low-confidence parts in the original image; intercepting a target slice image in the original image based on the coordinate information, and calling the target model to perform verification reasoning on the target slice image to determine the part features of the low-confidence part; When the part feature of each of the parts to be tested is determined, the sorting tray is controlled to pour each of the parts to be tested into the parts storage area.
5. The sorting method according to claim 4, characterized in that: The calling target model recognizes the part features of each of the parts to be tested in the original image to obtain a recognition result, including: Using the original image as an input feature map of a convolutional layer of a target model, adding an additional coordinate channel to the input feature map, wherein the additional coordinate channel is used to characterize the horizontal coordinate information and the vertical coordinate information of each pixel of the part to be tested in the original image; Identify the part features of each of the parts to be tested in the original image according to the horizontal coordinate information and the vertical coordinate information of the pixels of each of the parts to be tested in the original image to obtain an identification result; The target model includes sample feature information of various trained target part samples, and the sample feature information includes at least part type samples, part shape samples, and part angle offset samples.
6. The sorting method according to claim 5, characterized in that: Using a detection head with multiple coordinate convolutions to identify the part features of each of the parts to be tested in the original image, identifying the part features of each of the parts to be tested in the original image according to the horizontal coordinate information and the vertical coordinate information of the pixels of each of the parts to be tested in the original image, and obtaining the identification result, including: In the process of using the first detection head to identify the part features of the part to be tested, the original image is used as the first input feature map, and according to the first horizontal coordinate information and the first vertical coordinate information of each pixel of the part to be tested in the first input feature map, a first Euclidean distance from the pixel of the part to be tested to the center point in the first input feature map is calculated; In the process of using the second detection head to identify the part features of the part to be tested, the original image is used as the second input feature map, and according to the second horizontal coordinate information and the second vertical coordinate information of each pixel of the part to be tested in the second input feature map, the second Euclidean distance from the pixel of the part to be tested to the center point in the second input feature map is calculated; In the process of using the third detection head to identify the part features of the part to be tested, the original image is used as a third input feature map, and according to the third horizontal coordinate information and the third vertical coordinate information of each pixel of the part to be tested in the third input feature map, a third Euclidean distance from the pixel of the part to be tested to the center point of the third input feature map is calculated; The first Euclidean distance, the second Euclidean distance and the third Euclidean distance are spliced in a specified dimension to obtain target part feature information and target coordinate information of the part to be measured.
7. The sorting method according to claim 6, characterized in that: The calling of the target model to verify and infer the target slice image to determine the part features of the low-confidence part includes: Using the target slice image as an input feature map of a convolutional layer, adding an additional coordinate channel in the target slice image, wherein the additional coordinate channel is used to characterize the horizontal coordinate information and the vertical coordinate information of each pixel of the low-confidence part in the target slice image; According to the horizontal coordinate information and the vertical coordinate information of the pixel of each low-confidence part in the target slice image, the part feature of each low-confidence part in the target slice image is identified to obtain an identification result.
8. The method according to any one of claims 4 to 7, characterized in that After the step of performing image acquisition on the sorting plate to obtain an original image containing a plurality of parts to be tested, the method further comprises: If there are heterogeneous parts in the recognition result, a robot device is called to take the heterogeneous parts out of the parts pile; When the part feature of each of the parts to be tested is determined, controlling the sorting tray to pour each of the parts piles into the parts storage area comprises: When the part features of each of the to-be-tested parts of the same type are determined, the sorting tray is controlled to pour each of the part piles into a part storage area.
9. A computer device, characterized in that: The computer device comprises a memory, a controller, and a computer program stored in the memory, and the controller implements the method according to any one of claims 4 to 8 when executing the computer program.
10. A computer storage medium, wherein the computer storage medium is a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, wherein: When the computer program is executed by a controller, the method according to any one of claims 1 to 8 is implemented.
