Coal mine conveying belt foreign matter detection method based on lightweight model

Through the improved YOLOv7-tiny algorithm and step feature fusion module, the accuracy and generalization issues of foreign body detection in coal mine conveyor belts under weak lighting conditions were solved, and the rapid and accurate identification of gangue and anchor rods was achieved, which improved the performance of the detection model and the intelligent management of conveyor belts.

CN120689286APending Publication Date: 2025-09-23TIANDI CHANGZHOU AUTOMATION +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510741077.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-05
Publication Date
2025-09-23

AI Technical Summary

Technical Problem

Under weak lighting conditions, the existing lightweight target detection model has low accuracy in detecting foreign objects on coal mine conveyor belts and lacks generalization, making it difficult to effectively identify abnormal objects such as gangue and anchor rods.

Method used

An improved YOLOv7-tiny target detection algorithm is used. Through the stair fusion module and multi-scale training, image enhancement and data augmentation are combined to build a stair-YOLOv7-tiny model for feature extraction and target localization, thereby improving detection accuracy and robustness.

Benefits of technology

It achieves fast and accurate detection of gangue and anchor rods in low visibility and complex scenarios, improves detection accuracy and robustness, and supports automated control of conveyor belts.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120689286A_ABST
    Figure CN120689286A_ABST
Patent Text Reader

Abstract

The invention relates to a coal mine conveying belt foreign matter detection method based on a lightweight model in the technical field of coal mine conveying belt detection. The method comprises the following steps: performing data acquisition on working states of a coal mine conveying belt in different scenes, and making an image initial data set of foreign matters; obtaining a final foreign matter sample data set; performing category and position labeling on the final foreign matter sample data set; according to the configuration file of the YOLOv7-tiny, a YOLOv7-tiny target detection model is constructed; obtaining a stair-YOLOv7-tiny target detection model based on the lightweight model; and a stair-YOLOv7-tiny target detection model is trained. By means of the method for detecting the foreign matter on the conveying belt, gangue and anchor rods on the conveying belt can be rapidly and accurately recognized, and an accurate scientific basis is provided for follow-up corresponding operation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of coal mine conveyor belt detection, and in particular to a coal mine conveyor belt foreign body detection method based on a lightweight model. Background Art

[0002] Conveyor belts are essential equipment for coal transportation, and their operational status directly impacts coal mine production and transportation. However, during long transport periods, the coal often becomes contaminated with objects such as gangue and anchors. These foreign objects can easily become lodged between the conveyor belt, trough, and rollers, causing wear, scratches, and even tears. This can disrupt normal coal mine production and lead to significant economic losses. Therefore, accurately and quickly identifying and locating foreign objects on conveyor belts and promptly addressing them is of vital importance.

[0003] Currently, foreign object detection methods for coal mine conveyor belts are primarily categorized into two types: those based on traditional detection algorithms and those based on deep convolutional neural networks. However, there are relatively few studies examining how to use lightweight object detection models to detect foreign objects on conveyor belts under low-light conditions using existing open-source datasets. The primary challenge in this research lies in maintaining high detection accuracy with lightweight detection models. Summary of the Invention

[0004] In response to the above problems, the present invention proposes a coal mine conveyor belt foreign body detection method based on a lightweight model to solve the problems of low detection efficiency, low robustness and weak generalization in the existing technology. Even in scenes with low visibility, poor contrast and certain interference, foreign bodies such as gangue and anchors can be detected quickly and accurately using the improved YOLOv7-tiny target detection algorithm.

[0005] In order to overcome the shortcomings of scarce foreign body images and data imbalance in coal flow foreign body detection, the present invention provides a coal mine conveyor belt foreign body detection method based on a lightweight model, comprising the following steps: S1, in order to implement a detection algorithm for foreign objects such as anchors and gangue on coal conveyor belts, data on the working status of coal mine conveyor belts in different scenarios is collected and an initial image dataset containing foreign objects such as coal gangue and gangue is generated; S2, performing preprocessing operations such as image augmentation and image enhancement on the images of the initial dataset obtained in step S1 to obtain a final foreign body sample dataset; S3, labeling the final foreign body sample dataset obtained in step S2 by category and location, and dividing it into a training set, a validation set, and a test set; S4, builds the YOLOv7-tiny target detection model according to the YOLOv7-tiny configuration file for feature extraction and prediction of object category and location information; S5: Because the YOLOv7-tiny detection model was not ideal for detecting foreign objects such as anchors and gangue on conveyor belts, we improved the detection network by integrating the diversity of features at different levels. Through the stair fusion module, we developed the lightweight stair-YOLOv7-tiny object detection model. In step S6, the stair-YOLOv7-tiny object detection model is trained on the conveyor belt training set. If the predetermined number of training cycles is reached or the object detection model overfits on the validation set, training is stopped. After training, the final detection model is selected and the detection performance of the stair-YOLOv7-tiny model is tested on the test set.

[0006] As a further optimization of the above solution, step S1 specifically includes: selecting a set of image sequences of the conveyor belt under different scenes, different time periods, different angles and different lighting conditions to obtain an initial data set of conveyor belt foreign matter samples.

[0007] As a further optimization of the above solution, step S2 specifically includes: performing preprocessing operations on the initial sample data obtained in step S1 to expand the data set, and then obtain the final conveyor belt foreign matter sample data set, wherein the preprocessing includes image flipping, translation, rotation and cropping operations.

[0008] As a further optimization of the above scheme, step S3 specifically includes: using Lambeling image annotation software to annotate the category and location information of the final foreign body sample dataset. There are two categories in total, namely anchor rods and gangue, and making it into the standard VOC2007 dataset format. Then, the final conveyor belt dataset is divided into training set, validation set and test set in a ratio of 8:1:1.

[0009] As a further optimization of the above solution, step S4 specifically includes: S41, read the YOLOv7-tiny.cfg file, build the network layers in sequence according to the network layer parameter information in the configuration file, and finally form the YOLOv7-tiny target detection model; S42, the YOLOv7-tiny detection model uses the ELAN module as the neck for feature fusion and uses YOLO as the head for predicting target location and category information.

[0010] As a further optimization of the above solution, step S5 specifically includes: S51, build a network (concat) layer, stack the convolutions with indexes 2 and 4 in the elan module; build a convolution layer with a convolution kernel of 3*3, and use the output data of the above network layer as the input data of the convolution; use the output of the above 3*3 convolution and the convolutions with indexes 1, 2, and 3 in the elan module as the input data of the function with index 5; S52, optimize the detection head of the YOLOv7-tiny detection model obtained in step S4, construct a convolution with a convolution kernel of 3*3, the input of which is the output of the detection head with an index of 1; construct a network layer, the input of which is the output of the above-mentioned 3*3 convolution kernel and the output of the detection head with an index of 2; construct a convolution layer with a convolution kernel of 3*3, the input of which is the output of the above-mentioned network layer; construct a convolution layer with a convolution kernel of 3*3, the input of which is the output of the above-mentioned convolution layer; construct a network layer, the input of which is the output of the above-mentioned convolution layer and the output of the detection head with an index of 3; construct a convolution with a convolution kernel of 3*3, the input of which is the output of the above-mentioned network layer.

[0011] As a further optimization of the above solution, step S6 specifically includes: S61, clustering the anchor and gangue sizes in the training set using the Kmeans clustering algorithm to obtain the clustered anchor frames; S62: Initialize the weight parameters, then train the improved YOLOv7-tiny detection model on the training set, and use the anchor box obtained in S61 to assist the detection network in locating the target object to improve positioning accuracy and speed. S63, during the training process, the size of the input image is changed to perform multi-scale training. The pixel values ​​of the image height and width must be consistent and must be divisible by 32. In theory, the larger the pixel value of the image size, the better the detection effect and the slower the detection speed; S64: The detection model is trained on the training set. After each training of the entire training set, the mean average precision (mAP) of the current detection model is verified on the validation set. When the preset number of training times is reached or the mean average precision of the current detection model on the validation set decreases compared to the previous mean average precision, the training is stopped and the final detection model weight is saved. S65. After the training is completed, the final detection model weights in step S64 are loaded into the improved YOLOv7-tiny detection model and the mean average precision of the detection model is tested on the test set.

[0012] The coal mine conveyor belt foreign body detection method based on the lightweight model of the present invention produces the following beneficial effects: Effect 1: This detection model improves the detection accuracy of the detection model and meets the accuracy requirements of foreign body detection in coal conveyor belts; Effect 2: This detection model is highly robust and can perform effective detection even in the presence of certain interference. Effect 3: Using the method for detecting foreign matter on the conveyor belt proposed in this application, the gangue and anchor rods on the conveyor belt can be quickly and accurately identified, providing an accurate scientific basis for subsequent corresponding operations. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] Figure 1 The figure is a flow chart of the coal mine conveyor belt foreign body detection method based on the lightweight model of the present invention. DETAILED DESCRIPTION

[0014] The following will be combined with the embodiments of the present invention and the accompanying drawings to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. The following description of at least one exemplary embodiment is actually only illustrative and is in no way intended to limit the present invention and its application or use. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.

[0015] like Figure 1 As shown, the present invention provides a coal mine conveyor belt foreign body detection method based on a lightweight model, comprising the following steps: S1, in order to implement a detection algorithm for foreign objects such as anchors and gangue on coal conveyor belts, data on the working status of coal mine conveyor belts in different scenarios is collected and an initial image dataset containing foreign objects such as coal gangue and gangue is generated; Specifically, a camera is first placed near the conveyor belt, with the camera at a height of about 1 to 2 meters from the conveyor belt, a horizontal distance of about 1 meter from the conveyor belt, and a viewing angle of about 45 to 90 degrees to the plane on which the conveyor belt is located, so as to be able to capture the overall outline of the conveyor belt and obtain working videos of the conveyor belt in different scenes and time periods, so as to realize multi-scene control of different conveyor belts by a detection algorithm; the obtained conveyor belt working video is subjected to video frame processing, the image of each frame is segmented and a conveyor belt image sequence set is obtained; the above-obtained sequence set is screened, and the image sequence sets of the conveyor belt in different scenes, different time periods, different angles and different lighting are selected to obtain an initial conveyor belt foreign body sample data set.

[0016] S2, preprocessing the initial sample data obtained in step S1 to expand the data set, thereby obtaining the final conveyor belt foreign matter sample data set. The preprocessing specifically includes image flipping, translation, rotation, cropping, and contrast enhancement.

[0017] S3, annotating the final foreign body sample dataset obtained in step S2 by category and location, and dividing it into a training set, a validation set, and a test set; Specifically, Lambeling image annotation software was used to annotate the final foreign body sample dataset with category and location information. There were two categories in total, namely anchor rods and gangue, and the dataset was made into the standard VOC2007 dataset format. The final conveyor belt dataset was then divided into training set, validation set, and test set in a ratio of 8:1:1.

[0018] S4, builds the YOLOv7-tiny target detection model according to the YOLOv7-tiny configuration file, which is mainly used for feature extraction and prediction of object category and location information; Specifically, the entire detection network is mainly divided into three parts: the backbone network, the feature fusion layer, and the detection head. The backbone network is mainly used to extract low-dimensional corner and texture features, gradually obtaining relatively rich high-dimensional semantic information; the feature fusion layer is mainly used to fuse the low-dimensional feature information in the backbone network with the high-dimensional feature information to enrich the information of the decision layer; and the detection head mainly extracts the position and category information of the target object to be detected from the high-dimensional decision feature information to achieve object positioning and recognition; First, the YOLOv7-tiny.cfg file is read and the backbone network is constructed in sequence according to the network layer parameters in the configuration file, ultimately forming the YOLOv7-tiny target detection model. Next, the YOLOv7-tiny detection model uses the ELAN module as the neck for feature fusion and uses YOLO as the head to predict target position and category information.

[0019] S5: Because the YOLOv7-tiny detection model was not ideal for detecting foreign objects such as anchors and gangue on conveyor belts, we improved the detection network by integrating the diversity of features at different levels. Through the stair fusion module, we developed the lightweight stair-YOLOv7-tiny object detection model. Specifically, first, build a network (concat) layer and stack the convolutions with indexes (conv) of 2 and 4 in the elan module; build a convolution layer with a convolution kernel of 3*3 and use the output data of the above network layer as the input data of the convolution; use the output of the above 3*3 convolution and the convolutions with indexes 1, 2, and 3 in the elan module as the input data of the function with index 5; Next, the detection head of the YOLOv7-tiny detection model obtained in step S4 is optimized, and a convolution with a convolution kernel of 3*3 is constructed, the input of which is the output of the detection head with index 1; a network layer is constructed, the input of which is the output of the above 3*3 convolution kernel and the output of the detection head with index 2; a convolution layer with a convolution kernel of 3*3 is constructed, the input of which is the output of the above network layer; a convolution layer with a convolution kernel of 3*3 is constructed, the input of which is the output of the above convolution layer; a network layer is constructed, the input of which is the output of the above convolution layer and the output of the detection head with index 3; a convolution with a convolution kernel of 3*3 is constructed, the input of which is the output of the above network layer.

[0020] S6: Train the stair-YOLOv7-tiny object detection model on the conveyor belt training set. Stop training if the predetermined number of training times is reached or the object detection model overfits on the validation set. After training, select the final detection model and test the detection performance of the stair-YOLOv7-tiny model on the test set. First, on the training data set obtained in S3, the Kmeans clustering algorithm is used to cluster the sizes of anchor rods and gangue in the training set to obtain clustered anchor frames, and 12 anchor frames of different sizes are obtained. The annotated conveyor belt training data set is read, and the width and height values ​​of a target object are randomly selected as the center of the initial cluster. The K-mean clustering method is then used to iterate the calculation until the number of iterations ends or the cluster size no longer changes, thereby obtaining six anchor frames of different sizes; the six anchor frame values ​​obtained after algorithm processing are {[12, 16], [19, 36], [40, 28], [36, 75], [76, 55], [72, 146], [142, 110], [192, 243], [459, 401]}; the hardware and software configuration of the present invention is Intel(R) Core(TM) i9-10980XE CPU @ A 3.00GHz processor, a 48GB NVIDIA RTX A6000 GPU, and an Ubuntu 20.04 operating system were used. PyTorch was used for training and inference. The model training hyperparameters were configured as follows: 500 training epochs, an initial learning rate of 0.01, and a final learning rate of 0.1. Parameters were updated using momentum gradient descent with a weight decay coefficient of 0.005. Image data augmentation was performed using the mosaic data algorithm. During testing, the model confidence threshold was set to 0.5, and the intersection-over-union threshold was set to 0.65. Subsequently, the weight parameters are initialized, and then the improved YOLOv7-tiny detection model is trained on the training set. The anchor box-assisted detection network obtained above is used to locate the target object to improve positioning accuracy and speed. Subsequently, during the training process, the input image size is randomly changed for multi-scale training to increase the robustness of the detection model to the input image size. The pixel values ​​of the image height and width must be consistent and divisible by 32. The input image size can be selected in the range of [352, 384, 416, 448, 480, 512, 544, 576, 608, 640]. In theory, the larger the pixel value of the image size, the better the detection effect and the slower the detection speed. Subsequently, the detection model is trained on the training set. After each training session, the mean average precision (mAP) of the current detection model is verified on the validation set. When the preset number of training times is reached or the mAP of the current detection model on the validation set decreases compared to the previous mAP, training is stopped and the final detection model weights are saved. After the training is completed, the final detection model weights are loaded into the improved YOLOv7-tiny detection model, and the mean average precision of the detection model is tested on the test set.

[0021] Each class of objects in the above-obtained prediction results is subjected to non-maximum suppression processing to eliminate redundant prediction bounding boxes, thereby obtaining the final prediction results. The non-maximum suppression processing process is as follows: first, an intersection-over-union ratio threshold is set. The threshold selected by the present invention is 0.5. Second, the multi-scale prediction results output by the detection model are classified by category. Each class of prediction results is sorted in descending order according to the confidence of its bounding box. Then, the following operation is repeated for each class of predicted objects until all classes of objects have been processed. (1) Select the prediction value with the highest confidence level that is not marked as a candidate value in the prediction result list of this type and mark it as a candidate value; (2) Then calculate the intersection-over-union ratio (IoU) of the prediction result and all the prediction results in the class that are not marked as candidate values. If the IoU of the prediction result that is not marked as a candidate value and the candidate value in (1) is greater than the IoU threshold, we will remove the unmarked prediction result from the list of prediction results of this class; otherwise, no processing will be performed.

[0022] (3) Repeat operations (1) to (2) until the number of unmarked candidate values ​​in the prediction results of this category is less than 1; Calculate the accuracy of each object category, then sum and average the precision of all categories to obtain the mean average precision (mAP) of the detection network on the conveyor belt test set. Both AP and mAP are values ​​between [0, 1]. The larger the value, the better the performance of the model. The calculation formulas of AP and mAP are as follows: , , , Among them, TP represents the number of positive samples detected correctly by the model; FP represents the number of positive samples detected incorrectly; FN represents the number of negative samples detected incorrectly; Precision and Recall represent the precision rate and recall rate, respectively; P(R) represents a function of a certain type of object with recall rate as the independent variable and precision rate as the dependent variable; N represents a total of N types of objects, and the index of each type of object is i.

[0023] The coal mine conveyor belt foreign body detection method based on the lightweight model proposed in the present invention has high robustness and strong generalization ability. It can realize effective detection of the conveyor belt and provide scientific and effective guarantee for the subsequent control of foreign bodies on the conveyor belt. While realizing automated detection, it saves labor and improves the intelligence level of the coal washing plant.

[0024] The above description is only a preferred specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any technician familiar with the technical field, within the technical scope disclosed by the present invention, who makes equivalent replacements or changes based on the technical solution and inventive concept of the present invention, should be covered by the scope of protection of the present invention.

Claims

1. A coal mine conveyor belt foreign body detection method based on a lightweight model, characterized in that: The steps include: S1, collects data on the working status of coal mine conveyor belts in different scenarios and creates an initial dataset of foreign body images; S2, performing preprocessing operations on the images of the initial data set obtained in step S1 to obtain a final foreign body sample data set; S3, labeling the final foreign body sample dataset obtained in step S2 by category and location, and dividing it into a training set, a validation set, and a test set; S4, builds the YOLOv7-tiny target detection model according to the YOLOv7-tiny configuration file for feature extraction and prediction of object category and location information; S5, through the ladder feature fusion module, obtains the stair-YOLOv7-tiny target detection model based on the lightweight model; In step S6, the stair-YOLOv7-tiny object detection model is trained on the conveyor belt training set. If the predetermined number of training cycles is reached or the object detection model overfits on the validation set, training is stopped. After training, the final detection model is selected and the detection performance of the stair-YOLOv7-tiny model is tested on the test set.

2. The method for detecting foreign matter in a coal mine conveyor belt based on a lightweight model according to claim 1, characterized in that: Step S1 specifically includes: selecting a set of image sequences of the conveyor belt under different scenes, different time periods, different angles and different lighting conditions to obtain an initial dataset of conveyor belt foreign matter samples.

3. The method for detecting foreign matter in a coal mine conveyor belt based on a lightweight model according to claim 2, characterized in that: In step S2, the preprocessing includes image flipping, translation, rotation and cropping operations.

4. The method for detecting foreign matter in a coal mine conveyor belt based on a lightweight model according to claim 3 is characterized in that: Step S3 specifically includes: using Lambeling image annotation software to annotate the final foreign body sample dataset with category and location information. There are two categories in total, namely anchor rods and gangue, and making it into the standard VOC2007 dataset format. Then, the final conveyor belt dataset is divided into training set, validation set and test set in a ratio of 8:1:

1.

5. The method for detecting foreign matter in a coal mine conveyor belt based on a lightweight model according to claim 4, characterized in that: Step S4 specifically includes: S41, read the YOLOv7-tiny.cfg file, build the network layers in sequence according to the network layer parameter information in the configuration file, and finally form the YOLOv7-tiny target detection model; S42, the YOLOv7-tiny detection model uses the ELAN module as the neck for feature fusion and uses YOLO as the head for predicting target location and category information.

6. The method for detecting foreign matter in a coal mine conveyor belt based on a lightweight model according to claim 5, characterized in that: Step S5 specifically includes: S51, construct a network layer, stack the convolutions with indexes 2 and 4 in the elan module; construct a convolution layer with a convolution kernel of 3*3, and use the output data of the above network layer as the input data of the convolution; use the above 3*3 convolution output and the convolutions with indexes 1, 2, and 3 in the elan module as the input data of the function with index 5; S52, optimize the detection head of the YOLOv7-tiny detection model obtained in step S4, construct a convolution with a convolution kernel of 3*3, the input of which is the output of the detection head with an index of 1; construct a network layer, the input of which is the output of the above-mentioned 3*3 convolution kernel and the output of the detection head with an index of 2; construct a convolution layer with a convolution kernel of 3*3, the input of which is the output of the above-mentioned network layer; construct a convolution layer with a convolution kernel of 3*3, the input of which is the output of the above-mentioned convolution layer; construct a network layer, the input of which is the output of the above-mentioned convolution layer and the output of the detection head with an index of 3; construct a convolution with a convolution kernel of 3*3, the input of which is the output of the above-mentioned network layer.

7. The method for detecting foreign matter in a coal mine conveyor belt based on a lightweight model according to claim 6, characterized in that: Step S6 specifically includes: S61, clustering the anchor and gangue sizes in the training set using the Kmeans clustering algorithm to obtain the clustered anchor frames; S62: Initialize the weight parameters, then train the improved YOLOv7-tiny detection model on the training set, and use the anchor box obtained in S61 to assist the detection network in locating the target object to improve positioning accuracy and speed. S63, during the training process, the size of the input image is changed for multi-scale training. The pixel values ​​of the image height and width must be consistent and divisible by 32. S64, the detection model is trained on the training set. After each training of the entire training set, the mean average precision of the current detection model is verified on the validation set. When the preset number of training times is reached or the mean average precision of the current detection model on the validation set decreases compared to the previous mean average precision, the training is stopped and the final detection model weight is saved. S65. After the training is completed, the final detection model weights in step S64 are loaded into the improved YOLOv7-tiny detection model and the mean average precision of the detection model is tested on the test set.