Rubber line recognition method based on machine vision
Through machine vision-based recognition methods, using RGB-D camera array and point cloud reconstruction technology, the rapid and accurate automatic identification of rubber textures is achieved, and the problems of low efficiency and poor accuracy in the existing technology are solved.
Patent Information
- Application Number
- CN202411464270.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-18
- Publication Date
- 2025-02-14
- Estimated Expiration
- 2044-10-18
AI Technical Summary
The prior art has low efficiency and poor accuracy in rubber texture recognition, making it difficult to achieve fast and accurate automated recognition.
Using machine vision-based recognition method, rubber image data and depth information are collected through the RGB-D camera array, the point cloud model is reconstructed and projected into two-dimensional images, and the pre-trained machine vision recognition model is input for recognition.
It improves the accuracy and efficiency of rubber texture recognition, ensures the accuracy of automated recognition, and avoids manual intervention and identification errors.
Smart Images

Figure CN119445546A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of image data processing, and in particular to a rubber grain recognition method based on machine vision, which realizes automatic rubber grain recognition based on a machine vision algorithm. Background Art
[0002] Rubber is widely used in transportation, water conservancy, construction, medical treatment, chemical industry, aerospace and other industrial fields, playing the role of sealing, isolation, shock absorption, buffering, flexible connection and other functions. There are many kinds of rubber products, which have very broad development prospects. In actual use, according to different needs, the friction coefficient between the rubber and the contact surface is adjusted by setting a texture structure on the rubber.
[0003] However, in the process of manufacturing and using rubber products, due to the process flow, improper operation of workers, excessive use and other reasons, the rubber surface texture defects, such as texture breakage and texture damage, will be caused, resulting in quality degradation, affecting the actual use of rubber products, and in serious cases endangering user safety. Therefore, the detection and identification of rubber texture is particularly important.
[0004] The recognition schemes currently used are roughly divided into two directions. The first is manual inspection, which has high detection accuracy, but has high requirements for the experience of the recognition personnel and low work efficiency; the second is the traditional algorithm based on digital image processing technology, which uses binarization and edge detection algorithms in image processing to recognize the collected rubber texture images, which improves the recognition efficiency to a certain extent. However, it is limited by the image processing algorithm and has low recognition accuracy.
[0005] In recent years, with the continuous development of computer technology, emerging technologies represented by machine vision have been widely used by researchers in various industries. In the field of digital image data processing, machine vision has also been applied, such as detecting relevant targets through image recognition and convolutional neural networks. Through convolutional neural networks, the acquired relevant data is input into the network model, which saves the tedious manual feature selection in the network model training process. At the same time, the model can be continuously optimized according to the actual application scenario to improve the detection efficiency and recognition efficiency of the model.
[0006] Therefore, how to achieve rapid, accurate and automatic recognition of rubber texture is a technical problem that needs to be solved urgently in this field. Summary of the invention
[0007] The purpose of the present invention is to provide a rubber texture recognition method based on machine vision, which realizes automatic recognition of rubber texture based on machine vision algorithm, and aims to utilize the advantage of machine vision algorithm that can automatically extract key features from data without human intervention, and apply machine vision to the recognition of rubber texture to solve the problems of low efficiency and poor accuracy of traditional recognition methods.
[0008] To achieve the above object, the present invention adopts the following technical solutions:
[0009] Step 1: Capture images of the rubber to be identified through an RGB-D camera array to obtain multiple rubber image data including textures and corresponding depth information;
[0010] Step 2: Reconstruct corresponding point cloud data based on each image and the corresponding depth information to obtain multiple point cloud data, and use the multiple point cloud data to perform point cloud fusion to obtain a point cloud model of the rubber;
[0011] Step 3: Project the point cloud model of the rubber into a two-dimensional image;
[0012] Step 4: Input the obtained two-dimensional image data into a pre-trained machine vision recognition model to obtain the rubber texture recognition result.
[0013] Furthermore, before point cloud reconstruction is performed, a process of preprocessing the collected images is also included, which is characterized by:
[0014] Collect rubber image data;
[0015] The collected image data is subjected to Gaussian filtering to obtain the filtered image. The specific calculation formula is as follows:
[0016] G(x,y)=f(x,y)*h(i,j)=∑ i ∑ j f(xi,yj)h(i,j)
[0017] Where h(i,j) represents the Gaussian kernel function of size i*j, f(x,y) is the original image data, (x,y) is the pixel point, and * represents the convolution operation.
[0018] Perform a contrast linear stretch on the filtered image.
[0019] Furthermore, the specific process of reconstructing the three-dimensional point cloud of the rubber image data is as follows:
[0020] Feature points are extracted from each image captured by the RGB-D camera array, and then feature point matching is performed between the captured images based on the feature points to determine the position of the same feature point in each image.
[0021] Based on the camera intrinsic parameter matrix and pixel depth, the pixel coordinates in the two-dimensional image are converted into point cloud coordinates. The calculation formula is as follows:
[0022]
[0023] Among them, P(u,v) is the point cloud coordinate of pixel point P, u and v are the pixel coordinates of pixel point P in the two-dimensional image, D(u,v) is the depth information of the corresponding pixel point P, K is the intrinsic parameter matrix of the camera, is the coordinate matrix.
[0024] Based on the feature points, point cloud fusion is performed to eliminate redundant and repeated point cloud data, thereby reconstructing the final rubber point cloud model.
[0025] Furthermore, the training process of the machine vision recognition model includes:
[0026] Rubber images with different texture states are collected, and classification labels are assigned to the rubber images with different texture states. The original data set is constructed, and the collected images are divided into a training set and a test set. The training set is enhanced, and the original image data is rotated, noise is added, brightness is adjusted, and downsampling is performed to obtain enhanced training data. The obtained label information is processed using the k-means algorithm to obtain a bounding box (i.e., anchor) suitable for the rubber texture image.
[0027] The training set is input into the feature extraction part of the preset machine vision recognition model to extract the multi-scale feature map of the rubber image.
[0028] The multi-scale feature map is input into the prediction layer of the machine vision recognition model to obtain the detection frame of the rubber image, and the recognition map of the rubber texture is output. After training, the machine vision recognition model is obtained;
[0029] Input the test set images into the trained machine vision recognition model and output the recognition results. Determine whether the training is completed based on the precision and recall rates. When the precision and recall rates do not meet the thresholds, adjust the parameter values in the model and retrain until the thresholds are met and the training is completed.
[0030] Furthermore, according to the different states of the rubber texture, it can be classified into intact, worn and broken.
[0031] Furthermore, the training set data is resized and normalized before training to speed up the convergence of the network in the subsequent training process.
[0032] Furthermore, when extracting multi-scale features, the channel attention mechanism is introduced. For the feature vector f obtained at each scale, global average pooling and global maximum pooling operations are performed respectively. The global average pooling results and the global maximum pooling results are weighted summed. Without reducing the dimension of the channel, a convolution kernel of size 3 is used to implement fast 1D convolution to obtain the attention channel weight, and finally the channel attention feature map F is obtained. The convolution kernel of size 3 represents the coverage of local cross-scale interactions, and the specific calculation formula is as follows:
[0033] F=w1P avg (f)+w2P max (f)
[0034] Among them, F is the output feature vector, P avg (f) is the global average pooling of feature vector f, P max (f) is the global maximum pooling of feature vector f.
[0035] Furthermore, the loss function in model training is defined as:
[0036] L total =a*BCE class +b*BCE conf +c*CIoU+d*MIoU
[0037] Among them, BCE class is the classification loss. For each predicted box, the loss is calculated as follows:
[0038]
[0039] C is the number of categories; p c It is the binary encoding of the true label. If the predicted box corresponds to a certain category, the value of the category position is 1, and the rest are 0; is the probability that the model predicts that the box belongs to category c.
[0040] BCE conf It is a confidence loss function used to determine whether the predicted box contains a rubber texture object. If the intersection of union (IoU) between the predicted box and any true value is greater than the preset threshold, the prediction is a positive sample, otherwise it is a negative sample. The intersection of union (IoU) is an indicator used to measure the performance of the target detection algorithm. It indicates the degree of overlap between the predicted box and the true bounding box. When IoU = 0, it means that the predicted box does not overlap with the true bounding box. When IoU = 1, it means that the predicted box completely overlaps with the true bounding box.
[0041] The loss is calculated as follows:
[0042]
[0043] p o is the true label (0 or 1) of the predicted box as a positive sample, It is the probability that the model judges the prediction box to be a positive sample.
[0044] CIoU is the prediction box regression loss function, which is calculated as follows:
[0045]
[0046] ρ u and ρ c are the center point distances between the predicted box and the true bounding box, Φ u and Φ c are the aspect ratios of the predicted box and the true box, respectively.
[0047] MIoU is a multi-scale adjustment loss function, which is calculated as follows:
[0048]
[0049] M=w*h+w t *h t -w i *h i
[0050] Among them, w and h are the width and height of the prediction box, w i 、h i is the width and height of the intersection area between the predicted box and the real box, w t 、h t is the width and height of the real box, w u 、h u is the width and height of the smallest rectangular area including the predicted box and the true box, x and y represent the horizontal and vertical coordinates of the center point of the predicted box, and x t ,y t Represents the horizontal and vertical coordinates of the center point of the ground truth box.
[0051] a, b, c, d are the total loss function L total The weights of each loss function in .
[0052] Compared with the prior art, the present invention has the following beneficial effects:
[0053] 1. The rubber image is collected through the RGB-D camera array to obtain multiple image data and corresponding depth information. Based on the multiple rubber image data and depth information, the point cloud model of the rubber is reconstructed, and then a suitable angle is selected for projection to obtain a two-dimensional image of the rubber. The accuracy of rubber recognition is improved, ensuring that the optimal rubber field of view angle can be obtained, avoiding the overlap of rubber and field of view obstruction caused by improper placement of the surveillance camera or improper setting of the surveillance angle, resulting in poor surveillance field of view.
[0054] 2. Introduce the channel attention mechanism in model training, so that the model focuses on the rubber texture part in the input image data and pays less attention to the background part, which helps the model better understand and classify the rubber texture data, improve the accuracy of model recognition, and improve recognition efficiency.
[0055] 3. Set a multi-scale adjustment loss function in the model to enhance the adaptability of the recognition model to rubbers of different sizes and improve the detection accuracy and adaptability. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, 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 creative work.
[0057] Figure 1 It is a flow chart of an embodiment of a method for identifying rubber grains based on machine vision of the present application;
[0058] Figure 2 It is a flowchart of an embodiment of preprocessing image data of the present application;
[0059] Figure 3 It is a flowchart of training a machine vision recognition model according to an embodiment of the present application. DETAILED DESCRIPTION
[0060] The technical scheme in the embodiment of the present invention will be clearly described below in conjunction with the accompanying drawings in the embodiment of the present invention. Obviously, the described embodiment is only a part of the embodiment of the present invention, rather than all the embodiments. Based on the embodiment of the present invention, all other embodiments obtained by those skilled in the art without making creative work belong to the scope of protection of this application.
[0061] Example 1
[0062] See also Figure 1 , Figure 11 is a flow chart of an embodiment of a method for identifying rubber grains based on machine vision of the present application. As shown in the figure, the method includes:
[0063] Step 1: Use an RGB-D camera array to collect images of the rubber to be identified, so as to obtain multiple rubber image data including textures and corresponding depth information.
[0064] Since the camera array can obtain multiple images of the rubber at different angles, the collected image data can completely cover the appearance details of the rubber to be identified, which is conducive to the subsequent identification of the rubber texture.
[0065] Step 2: Reconstruct the corresponding point cloud data based on each image and the corresponding depth information to obtain multiple point cloud data, and use the multiple point cloud data to perform point cloud fusion to obtain a point cloud model of the rubber.
[0066] Step 3: Project the point cloud model of the rubber into a two-dimensional image.
[0067] Although the point cloud model can accurately represent the geometric shape and texture details of the rubber, the point cloud is a three-dimensional data set composed of a large number of points. Directly processing the rubber point cloud model will take up a lot of computing resources. Therefore, in order to improve efficiency, the point cloud model of the rubber is reprojected into a two-dimensional image. Since the rubber may be stacked, the collected image may be blocked by other rubber structures. The projection angle of the rubber point cloud model can be selected manually or automatically to avoid image incompleteness caused by occlusion, thereby selecting the relevant data that best represents the current state of the rubber and improving the accuracy of subsequent model recognition.
[0068] Step 4: Input the obtained two-dimensional image data into a pre-trained machine vision recognition model to obtain the rubber texture recognition result.
[0069] Please refer to Figure 2 , Figure 2 It is a flowchart of another embodiment of the present application.
[0070] Specifically, in some embodiments, step one may include a process of preprocessing the image:
[0071] S21: collecting rubber image data;
[0072] S22: Perform Gaussian filtering on the collected image data to obtain a filtered image. The specific calculation formula is as follows:
[0073] G(x,y)=f(x,y)*h(i,j)=∑ i Σ j f(xi,yj)h(i,j)
[0074] Where h(i,j) represents the Gaussian kernel function of size i*j, f(x,y) is the original image data, (x,y) is the pixel point, and * represents the convolution operation.
[0075] S23: Perform contrast linear stretching on the filtered image.
[0076] In the above steps, the image data is firstly subjected to Gaussian filtering to remove the obvious random noise in the image data, so as to avoid mistaking the noise information in the image for useful information during subsequent model recognition, thereby reducing the recognition accuracy. In addition, since Gaussian filtering will produce a certain blurring effect on the image, the contrast and clarity of the image are improved by contrast linear stretching.
[0077] By preprocessing the images, the quality and usability of the acquired images can be improved, high-quality data can be provided for the recognition model, and the recognition accuracy and efficiency can be improved.
[0078] Furthermore, the specific process of reconstructing the three-dimensional point cloud of the rubber image data is as follows:
[0079] Feature points are extracted from each image captured by the RGB-D camera array, and then feature point matching is performed between the captured images based on the feature points to determine the position of the same feature point in each image.
[0080] Based on the camera intrinsic parameter matrix and pixel depth, the pixel coordinates in the two-dimensional image are converted into point cloud coordinates. The calculation formula is as follows:
[0081]
[0082] Among them, P(u,v) is the point cloud coordinate of pixel point P, u and v are the pixel coordinates of pixel point P in the two-dimensional image, D(u,v) is the depth information of the corresponding pixel point P, K is the intrinsic parameter matrix of the camera, is the coordinate matrix.
[0083] Based on the feature points, point cloud fusion is performed to eliminate redundant and repeated point cloud data, thereby reconstructing the final rubber point cloud model. The point cloud fusion can adopt any existing known technology, which will not be described in detail here.
[0084] Please refer to Figure 3 , Figure 3 It is a flowchart of the training machine vision recognition model of this application.
[0085] S31: Collect rubber images with different texture states, assign classification labels to the rubber images with different texture states, and construct an original data set. According to the different states of the rubber texture, the rubber images can be classified into intact, worn, and broken.
[0086] The collected images are divided into training sets and test sets, and the training sets are enhanced. The original image data is rotated, noise is added, brightness is adjusted, downsampled, etc. to obtain enhanced training data. In this way, when the original training data is small, the training data samples can be expanded, thereby improving the robustness and generalization ability of model training.
[0087] Preferably, the training set data may be subjected to size conversion and data normalization preprocessing before training to accelerate the convergence speed of the network in the subsequent training process.
[0088] The obtained label information is processed using the k-means algorithm to obtain a bounding box (i.e., anchor) suitable for the rubber texture image.
[0089] S32: Input the training set into the feature extraction part of the preset machine vision recognition model to extract the multi-scale feature map of the rubber image.
[0090] Multi-scale features can represent different receptive fields of an image, thereby enhancing the model's ability to detect objects of different sizes. The extraction of multi-scale features is achieved by constructing a pyramid network structure in the model. The specific method is as follows:
[0091] Use the basic network ResNet to extract the feature representation of the image; generate feature maps of different scales through continuous convolutional layers and pooling layers, and the spatial size of the feature map is halved after each pooling layer; in the feature pyramid network, lateral connections are used to combine high-level (low-resolution) feature maps with low-level (high-resolution) feature maps; use upsampling technology to upsample the high-level feature map to the same spatial size as the low-level feature map; fuse the upsampled high-level feature map with the low-level feature map; thus obtaining a series of feature maps of different scales.
[0092] S33: inputting the multi-scale feature map into the prediction layer part of the machine vision recognition model, obtaining a detection frame of the rubber image, outputting a recognition map of the rubber texture, and obtaining a machine vision recognition model after training;
[0093] S34: Input the test set images into the trained machine vision recognition model and output the recognition results. Determine whether the training is completed based on the precision and recall rates. When the precision and recall rates do not meet the thresholds, adjust the parameter values in the model and retrain until the thresholds are met. The training is completed.
[0094] Preferably, when extracting multi-scale features, a channel attention mechanism can be introduced so that the model focuses on the rubber part in the input image data and pays less attention to the background part, which helps the model better understand and classify the rubber texture data, thereby improving the performance of the model.
[0095] For the feature vector f obtained at each scale, global average pooling and global maximum pooling operations are performed respectively, and the weighted sum of the global average pooling results and the global maximum pooling results is performed. Without reducing the dimension of the channel, a convolution kernel of size 3 is used to implement fast 1D convolution to obtain the attention channel weight, and finally obtain the feature map F of the channel attention. The convolution kernel of size 3 represents the coverage of local cross-scale interactions, and the specific calculation formula is as follows:
[0096] F=w1P avg (f)+w2P max (f)
[0097] Among them, F is the output feature vector, P avg (f) is the global average pooling of feature vector f, P max (f) is the global maximum pooling of feature vector f.
[0098] Preferably, the loss function in model training is defined as:
[0099] L total =a*BCE class +b*BCE conf +c*CIoU+d*MIoU
[0100] Among them, BCE class is the classification loss. For each predicted box, the loss is calculated as follows:
[0101]
[0102] C is the number of categories; p c It is the binary encoding of the true label. If the predicted box corresponds to a certain category, the value of the category position is 1, and the rest are 0; is the probability that the model predicts that the box belongs to category c.
[0103] BCE conf It is a confidence loss function used to determine whether the predicted box contains the target rubber object. If the intersection of union (IoU) between the predicted box and any true value is greater than the preset threshold, the prediction is a positive sample, otherwise it is a negative sample. The intersection of union (IoU) is an indicator used to measure the performance of the target detection algorithm. It indicates the degree of overlap between the predicted box and the true bounding box. When IoU = 0, it means that the predicted box does not overlap with the true bounding box. When IoU = 1, it means that the predicted box completely overlaps with the true bounding box.
[0104] The loss is calculated as follows:
[0105]
[0106] po is the true label (0 or 1) of the predicted box as a positive sample, It is the probability that the model judges the prediction box to be a positive sample.
[0107] CIoU is the prediction box regression loss function, which is calculated as follows:
[0108]
[0109] ρ u and ρ c are the center point distances between the predicted box and the true bounding box, Φ u and Φ c are the aspect ratios of the predicted box and the true box, respectively.
[0110] MIoU is a multi-scale adjustment loss function. The calculation of the traditional loss function does not take into account the characteristics of the scale change of the detection target. However, due to different application scenarios, the size of rubber products will vary significantly. The use of a single-scale loss function will lead to inaccurate prediction frames for rubbers of different sizes. Therefore, a multi-scale adjustment loss function is proposed to enhance the adaptability of the model to different sizes, thereby improving the detection accuracy. The specific calculation method of the multi-scale adjustment loss function is as follows:
[0111]
[0112] M=w*h+w t *h t -w i *h i
[0113] Among them, w and h are the width and height of the prediction box, w i 、h i is the width and height of the intersection area between the predicted box and the real box, w t 、h t is the width and height of the real box, w u 、h u is the width and height of the smallest rectangular area including the predicted box and the true box, x and y represent the horizontal and vertical coordinates of the center point of the predicted box, and x t ,y t Represents the horizontal and vertical coordinates of the center point of the ground truth box.
[0114] According to the actual rubber texture image data, adjust the total loss function L total The weights a, b, c, and d of each loss function are used to obtain the optimal loss function and improve the model's adaptability to rubber texture recognition of different sizes.
[0115] The present invention provides a rubber grain recognition method based on machine vision, realizes the recognition of rubber grain based on machine vision algorithm, collects rubber images through RGB-D camera array to obtain multiple image data and corresponding depth information, reconstructs the point cloud model of rubber based on multiple rubber image data and depth information, and then selects a suitable angle for projection to obtain a two-dimensional image of rubber. The accuracy of rubber recognition is improved, ensuring that the optimal rubber field of view angle can be obtained, avoiding the overlap of rubber and field of view occlusion caused by improper placement of monitoring cameras or improper setting of monitoring angles, resulting in poor monitoring field of view. In addition, a channel attention mechanism is introduced in model training, so that the model focuses on the rubber grain part in the input image data, pays less attention to the background part, helps the model better understand and classify rubber grain data, improves the accuracy of model recognition, and improves monitoring recognition efficiency. At the same time, a multi-scale adjustment loss function is set in the model to enhance the adaptability of the recognition model to rubbers of different sizes, and improves recognition accuracy and adaptability.
[0116] The above is an explanation of the present disclosure and should not be considered as a limitation thereof. Although several exemplary embodiments of the present disclosure are described, it will be readily understood by those skilled in the art that many modifications may be made to the exemplary embodiments without departing from the novel teachings and advantages of the present disclosure. Therefore, all such modifications are intended to be included within the scope of the present disclosure as defined in the claims. It should be understood that the above is an explanation of the present disclosure and should not be considered to be limited to the specific embodiments disclosed, and modifications to the disclosed embodiments and other embodiments are intended to be included within the scope of the appended claims. The present disclosure is defined by the claims and their equivalents.
[0117] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "illustrative embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.
[0118] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0119] Finally, it should be noted that those skilled in the art will easily understand that the embodiments described above are only preferred embodiments of the present invention, which are used to illustrate the technical solutions of the present application rather than to limit them. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A rubber texture recognition method based on machine vision, characterized in that: The method comprises: Step 1: Capture images of the rubber to be identified through an RGB-D camera array to obtain multiple rubber image data including textures and corresponding depth information; Step 2: Reconstruct corresponding point cloud data based on each image and the corresponding depth information to obtain multiple point cloud data, and use the multiple point cloud data to perform point cloud fusion to obtain a point cloud model of the rubber; Step 3: Project the point cloud model of the rubber into a two-dimensional image; Step 4: Input the obtained two-dimensional image data into a pre-trained machine vision recognition model to obtain the rubber texture recognition result.
2. The method according to claim 1, characterized in that Before point cloud reconstruction, the acquired images are preprocessed, including: Collect rubber image data; The collected image data is subjected to Gaussian filtering to obtain the filtered image. The specific calculation formula is as follows: G(x,y)=f(x,y)*h(i,j)=Σ i ∑ j f(x-i,y-j)h(i,j) Where h(i,j) represents the Gaussian kernel function of size i*j, f(x,y) is the original image data, (x,y) is the pixel point, and * represents the convolution operation; Perform a contrast linear stretch on the filtered image.
3. The method according to claim 1, characterized in that Point cloud reconstruction of rubber image data, including: Extract feature points from each image captured by the RGB-D camera array, and then perform feature point matching between the captured images based on the feature points to determine the position of the same feature point in each image; Based on the camera intrinsic parameter matrix and pixel depth, the pixel coordinates in the two-dimensional image are converted into point cloud coordinates. The calculation formula is as follows: Among them, P(u,v) is the point cloud coordinate of pixel point P, u and v are the pixel coordinates of pixel point P in the two-dimensional image, D(u,v) is the depth information corresponding to pixel point P, K is the intrinsic parameter matrix of the camera, is the coordinate matrix; Based on the feature points, point cloud fusion is performed to eliminate redundant and repeated point cloud data, thereby reconstructing the final rubber point cloud model.
4. The method according to claim 1, characterized in that: The training process of the machine vision recognition model includes: Rubber images with different texture states are collected, and classification labels are assigned to the rubber images with different texture states. The original data set is constructed, and the collected images are divided into a training set and a test set. The training set is enhanced, and the original image data is rotated, noise is added, brightness is adjusted, and downsampling is performed to obtain enhanced training data. The obtained label information is processed using the k-means algorithm to obtain a bounding box (i.e., anchor) suitable for the rubber texture image. The training set is input into the feature extraction part of the preset machine vision recognition model to extract the multi-scale feature map of the rubber image. The multi-scale feature map is input into the prediction layer of the machine vision recognition model to obtain the detection frame of the rubber image, and the recognition map of the rubber texture is output. After training, the machine vision recognition model is obtained; Input the test set images into the trained machine vision recognition model and output the recognition results. Determine whether the training is completed based on the precision and recall rates. When the precision and recall rates do not meet the thresholds, adjust the parameter values in the model and retrain until the thresholds are met and the training is completed.
5. The method according to claim 4, characterized in that According to the different states of the rubber texture, it can be classified into intact, worn and broken.
6. The method according to claim 4, characterized in that Before training, the training set data is preprocessed by size conversion and data normalization.
7. The method according to claim 4, characterized in that When extracting multi-scale features, the channel attention mechanism is introduced. For the feature vector f obtained at each scale, global average pooling and global maximum pooling operations are performed respectively. The weighted sum of the global average pooling results and the global maximum pooling results is performed. Without reducing the dimension of the channel, a convolution kernel of size 3 is used to implement fast 1D convolution to obtain the attention channel weight, and finally the feature map F of the channel attention is obtained. The convolution kernel of size 3 represents the coverage of local cross-scale interactions. The specific calculation formula is as follows: F=w1P avg (f)+w2P max (f) Among them, F is the output feature vector, P avg (f) is the global average pooling of feature vector f, P max (f) is the global maximum pooling of feature vector f.
8. The method according to claim 4, characterized in that The loss function in model training is defined as: L total =a*BCE class +b*BCE conf +c*CIoU+d*MIOU Among them, BCE class is the classification loss. For each predicted box, the loss is calculated as follows: C is the number of categories; p c It is the binary encoding of the true label. If the predicted box corresponds to a certain category, the value of the category position is 1, and the rest are 0; is the probability that the model predicts that the box belongs to category c; BCE conf Is a confidence loss function, used to determine whether the predicted box contains the target rubber object. If the intersection of union (IoU) between the predicted box and any true value is greater than the preset threshold, it is predicted as a positive sample, otherwise it is a negative sample. The intersection of union (IoU) is an indicator used to measure the performance of the target detection algorithm. It indicates the degree of overlap between the predicted box and the true bounding box. When IoU = 0, it means that the predicted box does not overlap with the true bounding box. When IoU = 1, it means that the predicted box completely overlaps with the true bounding box. The loss is calculated as follows: p o is the true label (0 or 1) of the predicted box as a positive sample, is the probability that the model judges the prediction box to be a positive sample; CIoU is the prediction box regression loss function, which is calculated as follows: ρ u and ρ c are the center point distances between the predicted box and the true bounding box, Φ u and Φ c are the aspect ratios of the predicted box and the true box respectively; MIoU is a multi-scale adjustment loss function, which is calculated as follows: M=w*h+w t *h t -w i *h i Among them, w and h are the width and height of the prediction box, w i 、h i is the width and height of the intersection area between the predicted box and the real box, w t 、h t is the width and height of the real box, w u 、h u is the width and height of the smallest rectangular area including the predicted box and the real box, x and y represent the horizontal and vertical coordinates of the center point of the predicted box, and x t ,y t Represents the horizontal and vertical coordinates of the center point of the real box; a, b, c, d are the total loss function L total The weights of each loss function in .
Citation Information
Patent Citations
Texture fusion method for RGB-D camera real-time three-dimensional reconstruction
CN110827397A
Rubber sealing ring surface defect detection method based on machine vision
CN111145165A
Biometric identification method, device, system, and terminal device
CN111212598A
VR three-dimensional reconstruction technology based on improved texture mapping algorithm
CN112598778A
Steel rail welding seam polishing system
CN113118906A