Online detection method and device for diamond saw wire wear based on machine vision

Through the online detection method based on machine vision, the number of diamond saw wire abrasive particles is detected in real time by using YOLOv5 and DeepSORT models, which solves the problem of difficult detection of diamond saw wire wear and improves processing efficiency and surface quality.

CN114049340BActive Publication Date: 2025-05-13JIANGSU UNIV OF SCI & TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111385848.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-11-22
Publication Date
2025-05-13
Estimated Expiration
2041-11-22

AI Technical Summary

Technical Problem

When diamond sawing wire is used to process brittle hard materials, the wear of diamond abrasive particles is difficult to detect in real time, affecting processing efficiency and surface quality.

Method used

Using an online detection method based on machine vision, abrasive particles images during diamond sawing work were collected through a high-speed camera, and target detection was performed using the YOLOv5 algorithm, and multi-object tracking was performed in combination with the DeepSORT model, counting the number of abrasive particles in real time, and adjusting and replacing the sawing wire in time.

Benefits of technology

Real-time detection of diamond saw wire wear is achieved, processing efficiency and surface quality is improved, and the uncertainty of replacing saw wires in traditional experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114049340B_ABST
    Figure CN114049340B_ABST
Patent Text Reader

Abstract

The invention discloses an online detection method for diamond saw wire wear based on machine vision, including S1: collecting diamond abrasive grain sample images of diamond saw wire in operation by a high-speed camera; S2: processing image samples, data enhancement, making data sets, and dividing them into training sets and verification sets; S3: using the Pytorch deep learning framework to build a YOLOv5 algorithm model, loading the data set to train the algorithm model; S4: after the diamond saw wire cuts each workpiece, shooting a 20-30 second long diamond saw wire working video; S5: using the YOLOv5+DeepSORT model to track multiple targets on the video in S4, and counting the number of abrasive grains on the diamond saw wire; S6: timely adjusting and replacing the diamond saw wire according to the change in the number of diamond abrasive grains. A detection device thereof is also provided. The invention can directly observe the change in saw wire wear, and from a quantitative perspective, it is more intuitive and convincing. The saw wire can be replaced in time, thereby improving processing efficiency and ensuring accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the field of detection of brittle and hard material processing workpieces, and in particular to a method and a device for online detection of diamond saw wire wear based on machine vision. Background Art

[0002] Nowadays, brittle and hard materials (photoelectric materials, sapphire, ceramic materials) have important applications in various industries. Among the methods of processing these materials, diamond wire saw cutting has the advantages of high cutting efficiency and low surface loss. It is currently the main method for processing brittle and hard materials. The working ability of diamond wire depends on the diamond abrasive grains attached to it, which are usually consolidated by electroplating. During the slicing process of brittle and hard materials, diamond abrasive grains will wear and fall off. Due to the high cutting speed and small abrasive grains, we cannot observe the abrasive wear with the naked eye, which will affect the surface quality and processing efficiency of the workpiece.

[0003] With the development of computer technology and digital image processing and analysis, deep learning, neural network and other technologies have been widely used in the industrial field, and target detection and defect detection have developed rapidly, which can effectively improve work efficiency and save manpower. However, there are not many examples of using machine vision in diamond wire wear detection. Summary of the invention

[0004] Purpose of the invention: In view of the above problems, the purpose of the present invention is to provide an online detection method for diamond wire wear based on machine vision, which can timely discover and understand the wear of diamond abrasive grains on the wire during the diamond wire saw processing, improve the processing efficiency of wire saw cutting, and improve the surface quality of the processed workpiece. A detection device is also provided.

[0005] Technical solution: A method for online detection of diamond wire wear based on machine vision, comprising the following steps:

[0006] S1: The image of diamond abrasive sample of diamond saw wire in operation is collected by high-speed camera;

[0007] S2: process image samples, enhance data, create datasets, and divide them into training and validation sets;

[0008] S3: Use the Pytorch deep learning framework to build the YOLOv5 algorithm model and load the dataset to train the algorithm model;

[0009] S4: After the diamond saw wire cuts each workpiece, a 20-30 second video of the diamond saw wire working is shot;

[0010] S5: Use the YOLOv5+DeepSORT model to track multiple targets in the video in S4 and count the number of abrasive particles on the diamond saw wire;

[0011] S6: Adjust and replace the diamond saw wire in time according to the changes in the number of diamond grains.

[0012] Furthermore, in S1, the acquisition of the diamond abrasive sample image includes the following steps:

[0013] S1.1: Build a testing platform and use a high-speed camera equipped with a 5x telecentric lens to photograph the diamond saw wire in working condition;

[0014] S1.2: During the process of the diamond wire cutting the material multiple times, images of the diamond wire cutting work are obtained, and the number of sample images obtained is 3000 to 3500.

[0015] Furthermore, in S2, the method of data enhancement and data set preparation includes the following steps:

[0016] S2.1: Use the YOLO format of the labelimg annotation tool to annotate the sample images obtained in S1, and classify the abrasive grains on the diamond saw wire into three categories: complete abrasive grains, worn abrasive grains, and grinding marks;

[0017] S2.2: The datasets were enhanced by randomly flipping, cropping, and randomly adjusting the hue, brightness, and saturation of the images. The location information of the three types of wear particles in these datasets was manually annotated. The images were then uniformly converted to a resolution of 608×608, and 80% of them were used as training sets and 20% as validation sets.

[0018] S2.3: Select to load pre-trained weights for network training, and select the pre-trained weights of the dataset as YOLOv5s.pt.

[0019] The best,parameter settings of YOLOv5 in S3 include selecting the adam optimizer,,the number of input images per batch is 8, the initial learning rate is 1e-5, and the,number of training rounds is 200.

[0020] Furthermore, in S5, the DeepSORT target tracking model construction and training process includes the following steps:

[0021] S5.1: Take the candidate box size and position information output by YOLOv5 as input;

[0022] S5.2: Perform multi-target tracking, the steps include: obtaining an original video frame; detecting the target in the video frame using a target detector; extracting features from the frame of the detected target; calculating the matching degree between the targets in the previous and next frames; and assigning an ID to each tracked target;

[0023] S5.3: Detect whether the target in the current frame passes through the specified counting line, and then count the number of complete abrasive particles, worn abrasive particles, and flattened marks in the video.

[0024] The best,DeepSORT includes a position predictor based on the Kalman filter algorithm, a feature extractor based on the small residual network, and a feature matcher based on the Hungarian algorithm.

[0025] Furthermore, in S6, during the entire life cycle of the diamond saw wire, the diamond abrasive grains are divided into three states in sequence: emerging from the coating, the cutting edge being passivated, and the abrasive grains being greatly flattened with a small amount of falling off. When the ratio of the number of flattened grains to the sum of the number of grains in the three states is greater than 30%, the diamond saw wire is replaced.

[0026] A detection device using the above-mentioned online detection method for diamond saw wire wear based on machine vision includes a wire cutting machine, a diamond saw wire, a point light source, a telecentric lens, and a high-speed camera. The diamond saw wire is installed on the wire cutting machine, and the high-speed camera is arranged above the diamond saw wire. The high-speed camera is equipped with a telecentric lens, and the telecentric lens and the diamond saw wire are kept perpendicular to each other with a vertical height of 65 to 70 mm. The point light source is arranged on one side of the telecentric lens, and the light source falls within the shooting range of the telecentric lens.

[0027] Beneficial effect: Compared with the prior art, the advantages of the present invention are: first, the YOLOv5 model is used to perform target detection on the diamond abrasive grains on the diamond saw wire, and then the DeepSORT model is used to track the multiple targets detected by the YOLOv5 model, and the number of complete diamond abrasive grains, worn abrasive grains, and grinding marks on the saw wire are counted. The wear of the diamond saw wire can be detected in real time, providing a reference for whether the saw wire needs to be replaced. Compared with the traditional practice of replacing the saw wire based on experience, the present invention can directly observe the changes in saw wire wear, and from a quantitative perspective, it is more intuitive and convincing. Timely replacement of the saw wire can improve processing efficiency and ensure processing accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Figure 1 A flow chart of online wear detection of diamond saw wire based on machine vision provided by the present invention;

[0029] Figure 2 It is a schematic diagram of the diamond wire wear detection device in the present invention. DETAILED DESCRIPTION

[0030] The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments. It should be understood that these embodiments are only used to illustrate the present invention and are not used to limit the scope of the present invention.

[0031] A method for online detection of diamond wire wear based on machine vision, such as Figure 1 As shown, the following steps are included:

[0032] S1: Collecting sample images of diamond abrasive grains of diamond saw wire in operation by high-speed camera: First, build a detection platform and use a high-speed camera equipped with a 5x telecentric lens to photograph the diamond saw wire in operation. Then, during the process of multiple cutting of the material by the diamond saw wire, obtain images of the diamond saw wire cutting operation, and the number of sample images obtained is 3000-3500.

[0033] S2: Process image samples. Use the YOLO format (txt format) of the labelimg annotation tool to annotate the collected photos with the sample images obtained in S1, and divide the abrasive particles on the diamond saw wire into three categories: complete abrasive particles, worn abrasive particles, and grinding marks. Enhance the data set by randomly flipping and cropping, randomly adjusting the hue, brightness, and saturation of the images, manually annotate the location information of the three abrasive particle categories in these data sets, and then uniformly change the images to a resolution of 608×608, and use 80% of them as training sets and 20% as validation sets.

[0034] In order to shorten the training time of the network, the pre-training weights are loaded for network training. The larger the pre-training weights, the higher the training accuracy, but the detection speed decreases. The pre-training weights of the data set selected by the present invention are YOLOv5s.pt.

[0035] S3: Use the Pytorch deep learning framework to build the YOLOv5 algorithm model and load the dataset to train the algorithm model.

[0036] The YOLOv5 network mainly consists of three parts: Backbone, Neck, and output;

[0037] Backbone refers to the backbone network, including Focus, Conv, Bottleneckcsp, and SPP. The Focus layer copies the input image four times and divides it into four slices through slicing operations and splices them using the contact layer. This can merge the number of channels, increase the features of the image, keep the information under the features unchanged, and use the conv convolution layer to extract features. The residual structure of the Bottleneckcsp layer and the 1×1 convolution layer are used to improve the learning ability of the model. Through the downsampling of the SPP spatial pyramid pooling layer, the output results are fused and spliced ​​to make the output consistent with the input.

[0038] Neck refers to a series of network layers that mix and combine image features and pass them to the prediction layer.

[0039] Output refers to predicting image features, generating bounding boxes and predicting categories. GIOU is used as the loss function, and non-maximum suppression (NMS) is used to filter target boxes.

[0040] The backbone network Backbone of the YOLOv5 model framework is mainly composed of the following parts: (1) The Focus layer copies the input four times and divides it into four slices through slicing operation, and then splices them through the concat layer. Splicing here refers to the merging of the number of channels, increasing the number of features of the image, while the information under each feature remains unchanged; (2) The Bottleneckcsp layer uses a 1x1 convolution layer, which greatly reduces the amount of calculation and improves the learning ability of the model; (3) The SPP layer is downsampled through three maximum pooling layers with different kernel_sizes, and the output results are spliced ​​and fused and added to their initial features. Finally, the output is restored to the same as the initial input through convolution conv.

[0041] The loss function of the bounding box of previous versions of YOLOv5 is IoU, while YOLOv5 uses GIOU as the loss function of the bounding box:

[0042]

[0043]

[0044] Where A is the predicted box, B is the real box, C is the minimum closed box that can contain A and B, and C\(A∪B) is expressed as the area of ​​C minus the area of ​​A∪B. GIoU overcomes the problem in IoU that when the two boxes do not intersect, the gradient cannot be returned and learning and training cannot be performed.

[0045] The present invention selects the pre-trained weights of YOLOv5s for training, and selects the Adam optimizer; the learning rate is set to 1e-5; the number of training rounds is 200 times; each batch is 8. According to the average precision AP and the average AP value MAP, it is judged whether the requirements are met. The trained weights are obtained.

[0046] S4: After the diamond saw wire cuts each workpiece, a 20-30 second video of the diamond saw wire working is shot;

[0047] S5: Use the YOLOv5+DeepSORT model to track multiple targets in the video in S4, take the candidate box size and position information output by YOLOv5 as input, and count the number of abrasive particles on the diamond saw wire.

[0048] DeepSORT mainly consists of three parts: Kalman filter algorithm as position predictor, small residual network as feature extractor training and prediction, and Hungarian algorithm as feature matcher;

[0049] The main steps of multi-target tracking include: obtaining the original video frame; using the target detector to detect the target in the video frame; extracting the features in the frame of the detected target, which include appearance features (to facilitate feature comparison and avoid ID switch) and motion features (motion features facilitate Kalman filtering to predict it); calculating the degree of matching between the targets in the previous and next frames (using the Hungarian algorithm and cascade matching), and assigning an ID to each tracked target.

[0050] By detecting whether the target in the current frame passes through a designated counting line, the number of complete abrasive particles, worn abrasive particles, and flattened marks in the video is counted.

[0051] S6: Adjust and replace the diamond saw wire in time according to the changes in the number of diamond grains.

[0052] As the working time of diamond saw wire increases, the number of intact diamond abrasive grains will gradually decrease, and a large number of worn abrasive grains and grinding marks will appear. When a large number of grinding marks appear after the saw wire has been working for a long time, it is determined that the saw wire is seriously worn and needs to be replaced in time to achieve the purpose of real-time detection. During the entire life cycle of diamond saw wire, the diamond abrasive grains are divided into three states: emerging from the coating, the cutting edge is passivated, and the abrasive grains are greatly flattened and a small amount of them fall off. When the ratio of the number of grinding marks to the sum of the number of the three states is greater than 30%, the diamond saw wire should be replaced.

[0053] The detection platform constructed by the above-mentioned diamond wire wear online detection method, that is, the detection device, is as follows Figure 2 As shown, it includes a wire cutting machine 201, a diamond saw wire 202, a point light source 203, a telecentric lens 204, and a high-speed camera 205. The diamond saw wire 202 is installed on the wire cutting machine 201, and the high-speed camera 205 is arranged above the diamond saw wire 202. The high-speed camera 205 is equipped with a telecentric lens 204. The telecentric lens 204 and the diamond saw wire 202 are kept perpendicular to each other, and the vertical height is 65 to 70 mm. The point light source 203 is arranged on one side of the telecentric lens 204, and its light source falls within the shooting range of the telecentric lens 204.

[0054] Since the saw wire is the saw wire morphology in the shooting work, the fastest linear speed of the diamond saw wire in the present invention is 0.8m / s when working, and a high-speed industrial camera needs to be selected. Since the diamond abrasive grains on the saw wire are small, a 4x coaxial telecentric lens is selected. The lens is perpendicular to the saw wire on the workbench, and the vertical height is 65-70mm. Due to the small field of view, a point light source needs to be installed on the telecentric lens, so that it can be aligned with the shooting area, improve the brightness, and make the photos clearer. The camera bracket should be placed on the ground to reduce the impact of the wire cutting machine vibration on the shooting.

[0055] By using the above device, images of the saw wire throughout its entire life cycle can be captured as much as possible, and a video can be captured at the end of its life cycle.

Claims

1. A method for online detection of diamond wire wear based on machine vision, characterized in that The following steps are involved: S1: The image of diamond abrasive sample of diamond saw wire in operation is collected by high-speed camera; S2: process image samples, enhance data, create datasets, and divide them into training and validation sets; S3: Use the Pytorch deep learning framework to build the YOLOv5 algorithm model and load the dataset to train the algorithm model; S4: After the diamond saw wire cuts each workpiece, a 20-30 second video of the diamond saw wire working is shot; S5: Use the YOLOv5+DeepSORT model to track multiple targets in the video in S4 and count the number of abrasive particles on the diamond saw wire; S6: Adjust and replace the diamond saw wire in time according to the changes in the number of diamond grains.

2. The method for online detection of diamond wire wear based on machine vision according to claim 1, characterized in that: In S1, the acquisition of the diamond abrasive sample image includes the following steps: S1.1: Build a testing platform and use a high-speed camera equipped with a 5x telecentric lens to photograph the diamond saw wire in working condition; S1.2: During the process of the diamond wire cutting the material multiple times, images of the diamond wire cutting work are obtained, and the number of sample images obtained is 3000 to 3500.

3. The on-line detection method for diamond wire wear based on machine vision according to claim 1, characterized in that: In S2, the way of data augmentation and making datasets includes the following steps: S2.1: Use the YOLO format of the labelimg annotation tool to annotate the sample images obtained in S1, and classify the abrasive grains on the diamond saw wire into three categories: complete abrasive grains, worn abrasive grains, and grinding marks; S2.2: The datasets were enhanced by randomly flipping, cropping, and randomly adjusting the hue, brightness, and saturation of the images. The location information of the three types of wear particles in these datasets was manually annotated. The images were then uniformly converted to a resolution of 608×608, and 80% of them were used as training sets and 20% as validation sets. S2.3: Select to load pre-trained weights for network training, and select the pre-trained weights of the dataset as YOLOv5s.pt.

4. The method for online detection of diamond wire wear based on machine vision according to claim 1, characterized in that: In S3, the parameter settings of YOLOv5 include selecting the adam optimizer, the number of input images per batch is 8, the initial learning rate is 1e-5, and the number of training rounds is 200.

5. The method for online detection of diamond wire wear based on machine vision according to claim 1, characterized in that: In S5, the DeepSORT target tracking model construction and training process includes the following steps: S5.1: Take the candidate box size and position information output by YOLOv5 as input; S5.2: Perform multi-target tracking, the steps include: obtaining an original video frame; detecting the target in the video frame using a target detector; extracting features from the frame of the detected target; calculating the matching degree between the targets in the previous and next frames; and assigning an ID to each tracked target; S5.3: Detect whether the target in the current frame passes through the specified counting line, and then count the number of complete abrasive particles, worn abrasive particles, and flattened marks in the video.

6. The method for online detection of diamond wire wear based on machine vision according to claim 5, characterized in that: DeepSORT includes a position predictor based on the Kalman filter algorithm, a feature extractor based on a small residual network, and a feature matcher based on the Hungarian algorithm.

7. The method for online detection of diamond wire wear based on machine vision according to claim 1, characterized in that: In S6, during the entire life cycle of the diamond saw wire, the diamond abrasive grains are divided into three states in sequence: emerging from the coating, the cutting edge is passivated, and the abrasive grains are greatly flattened with a small amount of shedding. When the ratio of the number of flattened grains to the sum of the number of grains in the three states is greater than 30%, the diamond saw wire is replaced.

8. A detection device using the online detection method for diamond wire wear based on machine vision according to any one of claims 1 to 7, characterized in that: The invention comprises a wire cutting machine (201), a diamond saw wire (202), a point light source (203), a telecentric lens (204), and a high-speed camera (205). The diamond saw wire (202) is installed on the wire cutting machine (201), the high-speed camera (205) is arranged above the diamond saw wire (202), the high-speed camera (205) is equipped with a telecentric lens (204), the telecentric lens (204) and the diamond saw wire (202) are kept vertically, and the vertical height is 65 to 70 mm. The point light source (203) is arranged on one side of the telecentric lens (204), and the light source falls within the shooting range of the telecentric lens (204).

Citation Information

Patent Citations

  • Diamond saw wire fracture prediction method based on image processing

    CN112164060A

  • Human body detection tracking method in ground interactive projection system based on YoloV5 and DeepSort

    CN112668432A