Method for automatically generating electronic fence based on risk level of mine marker
Through the automatic generation of electronic fence method based on the risk level of mine markers, image classification and AI recognition technology are used to solve the problem of insufficient generalization of electronic fence area identification, adaptive adjustment of electronic fences in the mining environment, and the intelligence and automation level of safety management are improved.
Patent Information
- Application Number
- CN202510413636.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-03
- Publication Date
- 2025-07-08
- Estimated Expiration
- 2045-04-03
AI Technical Summary
The electronic fence area identification method in the prior art lacks generalization, and big data analysis and artificial intelligence technology still have shortcomings in data quality, privacy protection, processing capabilities and algorithm models, which are difficult to meet the complex and changeable security management needs of the mining environment.
The automatic generation of electronic fence method based on the risk level of mine markers is adopted. The image classification data set is marked and trained through image classification data sets, combined with image semantic segmentation and object detection technology, and the closed electronic fence area is adaptively formed, and the image transformation and feature point extraction technology are used for fine-tuning to realize the automatic generation of electronic fences.
It improves the flexibility and accuracy of electronic fences, can adapt to changes in the mining environment, reduces dependence on data and computing resources, improves the efficiency and accuracy of security management, and reduces false positive rates.
Smart Images

Figure CN120279486A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of mine safety monitoring, and particularly to an automatic generation method of an electronic fence based on the risk level of mine markers. Background Art
[0002] In the mining field, work safety has always been of utmost importance. Due to the complexity and danger of the mine environment, traditional safety protection means such as manual patrols and video surveillance can no longer meet the safety management requirements of modern mines. These methods have problems such as incomplete coverage, lagging response, and high false alarm rates, and it is difficult to effectively deal with the complex and changeable mine environment. With the rapid development of technology, electronic fence technology has gradually become the new favorite in mine safety management with its high intelligence, accuracy, and real-time performance.
[0003] An electronic fence is a safety protection system that constructs an invisible "safety net" through advanced sensing technology, Internet of Things technology, and big data analysis technology. It can not only monitor the perimeter area in real time but also immediately trigger an alarm in case of abnormal intrusion, achieving all-weather and non-blind-spot safety protection. The introduction of the electronic fence system marks the advancement of mine safety management towards the direction of intelligence and automation. The mine electronic fence system is widely used in key underground dangerous areas such as heading faces, coal bunkers, airtight walls, and belt conveyors. Through a precise personnel positioning system, safety warnings are realized when operators enter dangerous areas, and audible and visual alarms are promptly issued or equipment shutdowns are triggered to avoid accidents.
[0004] However, the electronic fence area recognition method in the prior art lacks generalization, and there are still deficiencies in big data analysis and artificial intelligence technologies in terms of data quality, privacy protection, processing capabilities, and algorithm models. Summary of the Invention
[0005] The purpose of the present invention is to provide an automatic generation method of an electronic fence based on the risk level of mine markers, aiming to solve the technical problems that the electronic fence area recognition method in the prior art lacks generalization, and there are still deficiencies in big data analysis and artificial intelligence technologies in terms of data quality, privacy protection, processing capabilities, and algorithm models.
[0006] To achieve the above purpose, an automatic generation method of an electronic fence based on the risk level of mine markers adopted by the present invention includes the following steps:
[0007] Firstly, collect environmental images with potential safety hazards during the work and production of mine workers, form an image classification data set and perform annotation, and the annotation standards are high-risk images, medium-risk images, and low-risk images;
[0008] Use the formed image classification data set for division and train an image classification model;
[0009] Use an alternative production environment image for annotation to form a test set, and use this test set to infer the image classification model to display and evaluate the model results;
[0010] Deploy the image classification model to the edge server and connect to the on-site video stream. With a fixed frame extraction interval, realize online image detection to obtain the detection results of image classification;
[0011] Based on the results of image classification, use different AI recognition models to detect various objects in the image;
[0012] Select corresponding calibration objects according to the types of various objects in the image;
[0013] According to the shape contour of the calibration object in the image, use the method of image transformation to adaptively fine-tune around it to form a closed electronic fence area.
[0014] Among them, when constructing and annotating the image classification dataset, use deep learning image label annotation software (such as Labelme, Labelimg) for annotation, and the annotation type is text txt or xml file. For example, create a category label file flags.txt for the dataset to be annotated, and write the categories of the dataset to be annotated line by line in flags.txt, such as high risk, medium risk, and low risk.
[0015] Among them, when using the constructed image classification dataset to divide and train the image classification model: divide 20% of the images from the image classification dataset as the validation set and 80% of the images as the training set;
[0016] The constructed image classification model is a model based on a convolutional neural network (CNN). It automatically extracts the features of the image by learning a large number of image datasets and classifies the image according to these features;
[0017] The specific process includes: data preprocessing, feature extraction, fully connected layer classification, and output prediction;
[0018] The image classification model structure includes an input layer, a convolutional layer, an activation function, a pooling layer, a fully connected layer, an output layer, and a loss function.
[0019] Among them, when using different AI recognition models to detect various objects in the image based on the results of image classification:
[0020] For high-risk images, use image semantic segmentation to segment the edge contours of each object. For medium- and low-risk images, use object detection to detect the positions and confidences of various objects;
[0021] The image semantic segmentation adopted assigns a semantic label to each pixel in the image to achieve the precise division and classification of each object area in the image;
[0022] The object detection adopted not only identifies the main objects in the image but also determines their specific positions in the image through bounding boxes.
[0023] Among them, when selecting the corresponding calibration object according to the types of various objects in the image, the selected calibration object is one that can represent the main objects or features in the image;
[0024] The selected calibration object can be easily and accurately identified in the image; the selected calibration object has a clear contour, obvious features, and sufficient contrast.
[0025] Among them, when adaptively forming a closed electronic fence area around it by means of image transformation according to the shape contour of the calibration object in the image:
[0026] The adopted method of image transformation is scaling or linear transformation;
[0027] And there is a distance between the formed electronic fence area and the edge of the marker, and this distance is configured or fine-tuned manually;
[0028] For the situation in the image where the calibration object is not obvious or the contour of the calibration object is difficult to detect, on the basis of AI recognition, an edge feature point extraction method is introduced to form feature points around the calibration object, combine them into a closed polygon to wrap the object inside, and then introduce an image transformation formula to automatically form an electronic fence area;
[0029] Finally, according to the ratio of the generated electronic fence area to the position area of the calibration object, combined with the initially manually input tolerance coefficient, adaptive area fine-tuning is realized.
[0030] Among them, the distance between the formed electronic fence area and the edge of the marker is directly measured in pixels, and an additional safety margin is set to ensure safety or avoid false alarms.
[0031] Among them, the specific method for automatically generating an electronic fence area according to the calibration object is as follows:
[0032] First, draw the contour area or positioning area A of the calibration object, and obtain the coordinate position P(x p ,y p ) of the center pixel point of the calibration object as a feature point, and this position is obtained through the centroid calculation formula,
[0033] The centroid calculation formula is as follows:
[0034]
[0035] In the formula, x i and y i are the positions of each pixel within the calibration object contour region; then, find the four corner vertices in the region, which are X1(x min ,y), X2(x,y max ), X3(x max ,y), X4(x,y max ), where x min , y min , x max , y max represent the nearest and farthest pixel positions in the two directions of the X-axis and Y-axis of the region in the image;
[0036] Then, find the two pixels with the farthest distance in the calibration object contour region or the positioning region, and calculate their Euclidean distance on the image, denoted as d,
[0037]
[0038] After that, artificially define a tolerance coefficient r for the image risk level, such as r = 1.5 for high risk, r = 1.2 for medium risk, and r = 1 for low risk. This configuration can be used as an adaptive fine-tuning optimization option;
[0039] Subsequently, determine whether a segmented or detected region is a regular shape. A shape fitting algorithm (such as the least squares method) fits the extracted contour to a standard shape (such as a circle, rectangle, etc.);
[0040] If it is an irregular contour, then for the electronic fence area:
[0041]
[0042] If it is a regular circular contour, then for the electronic fence area:
[0043]
[0044] If it is a regular rectangular or trapezoidal contour, then for the electronic fence area:
[0045]
[0046] Among them, the method for fine-tuning the generated electronic fence area is as follows:
[0047] Calculate the ratio R of the area of the generated electronic fence area to the calibration object,
[0048]
[0049] Among them, the vertex coordinates of the electronic fence area are:
[0050] ((x1,y1),(x2,y2),…,(x m ,y m ));
[0051] The vertex coordinates of the calibration object are:
[0052] ((x′1,y′1),(x′2,y′2),…,(x′ n ,y′ n ));
[0053] According to R, the tolerance coefficient r^* = r / R is updated at this time. At this time, the electronic fence area is scaled proportionally, and the offset correction parameters are configured manually. The left - right translation parameter is set to a, and the up - down translation parameter is set to b. Under the condition that the calibration object is still included in the boundary, the new electronic fence area S^* = r^**((S - a)+b) to achieve adaptive area fine - tuning.
[0054] Among them, when specifically detecting, the image field of view should include the areas or equipment with potential safety hazards in the working production environment, and the image resolution is not less than 1920*1080;
[0055] The image classification dataset should include images of various dangerous areas in the mining field.
[0056] An apparatus for automatically generating an electronic fence based on the risk level of mining markers, including an image acquisition device, a communication transmission device, a data processing device, and a data storage device;
[0057] The image acquisition device is a close - range high - definition camera, which can collect high - definition images of various working conditions in the mining field. Anti - dust materials are used on the surface of the camera to avoid the attachment of dust in the mine and affect the imaging quality of the image;
[0058] The communication transmission device includes a 5G transmitter, a wifi transmitter, a USB transmitter, and an Ethernet transmitter;
[0059] The data processing device is an AI edge - computing server, which has a certain computing power and memory to complete AI image segmentation detection based on SAM2 and calibration object area detection based on Yolo;
[0060] The data storage device is an SD card or a hard disk, which is used to store the images for identifying image classification and calibration object positioning.
[0061] An automatic electronic fence generation method based on the risk level of mine markers. In the present invention, through a close-range high-definition camera, images of various dangerous areas are pre-collected to establish an image data set. Through a detection method of image classification + AI recognition + feature point calculation + image transformation, the risk level of the image and the existing dangerous areas are intelligently judged, and by positioning the image markers, an electronic fence with a certain range is automatically generated around the markers. This electronic fence is flexible and variable, not affected by external environments, etc., and at the same time has the advantages of being stable, efficient, safe and reliable.
[0062] The present invention solves the problem of insufficient generalization of the artificially set electronic fence area and the complexity and accuracy problems of the algorithm model in the adaptive adjustment of the electronic fence position by artificial intelligence technology. And in view of the difficult data acquisition, difficult algorithm deployment, slow model iteration, etc. in the mine field, a set of methods for automatically generating an electronic fence based on risk grading rules is designed. This method systematically realizes the automatic adjustment of the electronic fence by introducing image classification + visual large model AI recognition + feature point extraction + formulaic processing templates. It avoids key problems such as poor model accuracy and regional failure caused by factors such as changes in the external environment and working conditions. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.
[0064] Figure 1 It is a flow chart of the present invention.
[0065] Figure 2 It is a schematic diagram of the contour of the rule calibrator and the automatically generated electronic fence area of the present invention.
[0066] Figure 3 It is a schematic diagram of the contour of the irregular calibrator and the automatically generated electronic fence area of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0067] The following will describe in detail the embodiments of the present invention. The examples of the embodiments are shown in the drawings. The embodiments described below with reference to the drawings are exemplary and are intended to explain the present invention, and should not be construed as a limitation to the present invention.
[0068] Please refer to Figures 1 to 3 where Figure 1 is a flow chart of the present invention. Figure 2It is a schematic diagram of the regular calibration object contour and the automatically generated electronic fence area of the present invention. Figure 3 It is a schematic diagram of the irregular calibration object contour and the automatically generated electronic fence area of the present invention.
[0069] The present invention provides an automatic electronic fence generation method based on the risk level of mine markers, including the problems solved by the foregoing solutions.
[0070] S1. First, collect environmental images with potential safety hazards during the work and production of mine field personnel, form an image classification data set and perform annotation. The annotation standards are high-risk images, medium-risk images, and low-risk images.
[0071] For this specific embodiment, when forming the image classification data set and performing annotation, use deep learning image label annotation software (such as Labelme, Labelimg) for annotation, and the annotation type is text txt or xml file. For example, create a category label file flags.txt for the data set to be annotated, and write the categories of the data set to be annotated line by line in flags.txt, such as high risk, medium risk, and low risk.
[0072] S2. Use the formed image classification data set to divide and train an image classification model.
[0073] For this specific embodiment, the selected image classification model uses the YoloV8-s algorithm for running detection. Specifically, input the image to be detected into the YoloV8-s model. Then perform an affine transformation on the image to adjust it to the input size specified by the model. Select an appropriate model loading method according to the hardware and framework used. Input the preprocessed image into the YoloV8-s model for forward propagation calculation. The model will output a series of prediction results, and each prediction result contains information such as the category and confidence of the image. Distinguish the images according to different degrees of danger.
[0074] Moreover, when using the formed image classification data set to divide and train an image classification model: divide 20% of the images from the image classification data set as the validation set, and 80% of the images as the training set.
[0075] The constructed image classification model is a model based on a convolutional neural network (CNN). It automatically extracts the features of images by learning a large number of image data sets and classifies the images according to these features.
[0076] The specific process includes: data preprocessing, feature extraction, full connection layer classification, and output prediction.
[0077] The image classification model structure includes an input layer, a convolutional layer, an activation function, a pooling layer, a full connection layer, an output layer, and a loss function.
[0078] S3. Use an alternative production environment image for annotation to form a test set, and use this test set to perform inference on the image classification model, display and evaluate the model results;
[0079] S4. Deploy the image classification model to the edge server, connect to the on-site video stream, and use a fixed frame extraction interval to achieve online image detection and obtain the detection results of image classification;
[0080] S5. Based on the results of image classification, use different AI recognition models to detect various objects in the image;
[0081] For this specific embodiment, the AI recognition models used are YoloV8-s and SAM2. Specifically, the image to be detected is input into the YoloV8-s / SAM2 model. Then, an affine transformation is performed on the image to adjust it to the input size specified by the model. Select an appropriate model loading method according to the hardware and framework used. Input the preprocessed image into the YoloV8-s / SAM2 model for forward propagation calculation. The model will output a series of prediction results, and each prediction result contains information such as the category, annotation box, and confidence of each object. It should be noted that SAM2 will also return the region mask for object segmentation, which can locate or segment the objects in the image.
[0082] For high-risk images, use image semantic segmentation to segment the edge contours of each object. For medium- and low-risk images, use object detection to detect the positions and confidences of various objects;
[0083] The image semantic segmentation used assigns a semantic label to each pixel in the image to achieve precise division and classification of each object region in the image;
[0084] The object detection used not only identifies the main objects in the image but also determines their specific positions in the image through bounding boxes.
[0085] S6. Select corresponding calibration objects according to the types of various objects in the image;
[0086] For this specific embodiment, the selected calibration objects are those that can represent the main objects or features in the image;
[0087] The selected calibration objects can be easily and accurately recognized in the image; the selected calibration objects have clear contours, obvious features, and sufficient contrast. For high-risk images of belt conveyors, the calibration objects are roller idlers and motors. They have clear edges and obvious texture features in the image. For high-risk images of tunneling faces, the calibration objects are roadheaders and various support equipment such as anchor bolts, cable bolts, and shed frames. They are the key elements to ensure the safety of tunneling operations. Using these devices as calibration objects can ensure that the calibration results can accurately reflect the actual situation of the tunneling face.
[0088] S7. According to the shape contour of the calibration object in the image, adopt the method of image transformation to adaptively fine-tune around it to form a closed electronic fence area;
[0089] For this specific embodiment, the method of image transformation adopted is proportional stretching or linear transformation;
[0090] And there is a distance between the formed electronic fence area and the edge of the marker, and this distance is configured or fine-tuned manually;
[0091] For the situation where the calibration object in the image is not obvious or the contour of the calibration object is difficult to detect, based on AI recognition, introduce the edge feature point extraction method to form feature points around the calibration object, combine them into a closed polygon to wrap the object inside, and then introduce the image transformation formula to automatically form an electronic fence area;
[0092] Finally, according to the ratio of the generated electronic fence area to the position area of the calibration object, combined with the initially manually input tolerance coefficient, realize adaptive area fine-tuning.
[0093] The distance between the formed electronic fence area and the edge of the marker is specifically: on the image plane, the distance can be directly measured in pixels. In this case, "a certain distance" may be a fixed pixel value, such as 5 pixels, 10 pixels, etc. In some applications, in order to ensure safety or avoid false alarms, an additional safety margin may be set. This margin can be determined based on experience, industry standards, or user requirements. This distance can be configured or fine-tuned manually.
[0094] The specific method for automatically generating an electronic fence area according to the calibration object is as follows:
[0095] First, draw the contour area or positioning area A of the calibration object, and obtain the coordinate position P(x p , y p ) of the center pixel point of the calibration object as a feature point, and this position is obtained through the centroid calculation formula,
[0096] The centroid calculation formula is as follows:
[0097]
[0098] In the formula, x i and y i are the positions of each pixel within the calibration object contour area; then find the four corner vertices in the area, which are X1(x min , y), X2(x, y max ), X3(x max , y), X4(x, y max ), where x min , y min , x max , y max represent the nearest and farthest pixel positions in the two directions of the X-axis and Y-axis of the area in the image;
[0099] Then, find the two pixels with the farthest distance in the calibration object contour area or the positioning area, and calculate their Euclidean distance on the image, denoted as d.
[0100]
[0101] After that, artificially define a tolerance coefficient r for the image risk level. For example, for high risk, r = 1.5; for medium risk, r = 1.2; for low risk, r = 1. This configuration can be used as an adaptive fine-tuning optimization option.
[0102] Subsequently, determine whether a segmented or detected area is a regular shape. The shape fitting algorithm (such as the least squares method) fits the extracted contour with a standard shape (such as a circle, rectangle, etc.).
[0103] If it is an irregular contour, then for the electronic fence area:
[0104]
[0105] If it is a regular circular contour, then for the electronic fence area:
[0106]
[0107] If it is a regular rectangular or trapezoidal contour, then for the electronic fence area:
[0108]
[0109] The method for fine-tuning the generated electronic fence area is as follows:
[0110] Calculate the ratio R of the area of the generated electronic fence area to the calibration object.
[0111]
[0112] Among them, the vertex coordinates of the electronic fence area are:
[0113] ((x1,y1),(x2,y2),…,(x m ,y m ));
[0114] The vertex coordinates of the calibration object are:
[0115] ((x′1,y′1),(x′2,y′2),…,(x′ n ,y′ n ));
[0116] According to R, at this time, update the tolerance coefficient r^* = r / R. At this time, scale the electronic fence area proportionally, and at the same time, manually configure the offset correction parameters. Set the left and right translation parameter to a and the up and down translation parameter to b. Under the condition that the boundary still contains the calibration object, the new electronic fence area S^* = r^**((S - a)+b) to achieve adaptive area fine-tuning.
[0117] Among them, when specifically performing detection, the image field of view should include the areas or equipment with potential safety hazards in the working production environment, and the image resolution should not be lower than 1920*1080;
[0118] The image classification dataset should include images of various dangerous areas in the mining field.
[0119] Among them, when implementing online detection, collect videos through a camera, extract frames into images, and then enter the image classification model and AI recognition model. Since the production environment and the camera position angle will not change significantly, it can be generated once every 10 minutes according to the actual situation.
[0120] An apparatus for automatically generating an electronic fence based on the risk level of mine markers, including an image acquisition device, a communication transmission device, a data processing device, and a data storage device;
[0121] The image acquisition device is a close-range high-definition camera, which can collect high-definition images of various working conditions in the mining field. Anti-dust materials are used on the surface of the camera to avoid the attachment of dust in the mine and affect the imaging quality of the image;
[0122] The communication transmission device includes a 5G transmitter, a wifi transmitter, a USB transmitter, and an Ethernet transmitter;
[0123] The data processing device is an AI edge computing server, which has a certain computing power and memory to complete AI image segmentation detection based on SAM2 and calibration object area detection based on Yolo;
[0124] The data storage device is an SD card or a hard disk, which is used to store the images for identifying image classification and calibration object positioning.
[0125] When using the automatic electronic fence generation method based on the risk level of mine markers of the present invention, during specific use, first collect images of the working environment of mine field personnel, especially the points with potential safety hazards, such as at the tail motor of the belt conveyor, on both sides of the protective net, at the contact point between the drum and the idler, the mining area of the coal bunker, the explosive area, etc., to form an image classification training data set and perform annotation, and label them as high-risk, medium-risk, and low-risk environments; divide these image classification data sets and train an image classification model, select 80% of the images for training, and 20% of the images for verification. Then select some other images of the production environment for annotation as
[0126] the test set. After the classification model is trained, use the labeled test set for inference, implement online detection, and display the results of the classification model; for the classified images, then enter different AI recognition models. For example, for the images of high-risk areas, introduce an image semantic segmentation model to segment the edge contours of the objects in the image, such as the drum, draw the existing dangerous areas through the object contours, and then automatically form an electronic fence area around the object according to the image transformation formula. The image transformation formula is different for different types and shapes of objects. For those images with a low risk level, choose to introduce an object detection model to roughly locate the positions of all objects in the image, select a suitable object as a calibration object according to the object type, and automatically generate an electronic fence area by performing image transformation around the detection frame of the calibration object. For those calibration objects that are not closed, open, or have incomplete edge contours, choose to fix feature points around the calibration object to form a closed polygon to enclose the calibration object inside, and then automatically form an electronic fence area outside the closed polygon through the image transformation formula.
[0127] The present invention has the following innovations:
[0128] 1. Automatic generation of risk grading:
[0129] When adjusting the position of the electronic fence in the prior art, it often relies on complex artificial intelligence models, which require a large amount of data and computing resources for training and updating. However, this technical solution realizes the automatic generation and adjustment of the electronic fence position by introducing risk grading rules. These rules are based on the specific environment and working conditions in the mining field, and can more accurately identify potential safety risks, thereby dynamically adjusting the position and scope of the electronic fence. This innovation not only reduces the dependence on a large amount of data, but also improves the accuracy and adaptability of the model. For example, through image classification means, the dangerous areas of several mining field scenarios such as the heading face, coal bunker, airtight wall, and belt conveyor can be graded based on potential risk factors, the likelihood of accidents occurring, and the severity of accident consequences. Taking the belt conveyor as an example, the high-risk areas are at the head and tail of the machine, the contact points between the conveyor belt and the rollers and idlers, where mechanical injury accidents such as entanglement and squeezing are likely to occur. The medium-risk areas may be in the areas along the conveyor belt and the maintenance channels below the conveyor belt, where there may be potential hazards of personnel falling.
[0130] 2. Integrated application of image classification + visual large model AI recognition + feature extraction + formulaic processing template:
[0131] After understanding the real production scenarios in the mining field through image classification and combining visual large model AI recognition means such as object detection or semantic segmentation, the system can quickly identify different areas and objects in the mining environment.
[0132] Feature extraction technology can extract key information to guide the adjustment of the electronic fence; and the formulaic processing template, such as defining the image linear transformation relationship under different levels and different object shapes, ensures the repeatability and consistency of the whole process.
[0133] 3. Solved the problems of difficult data acquisition and difficult algorithm deployment in the mining field:
[0134] Due to its special environment and working conditions, it is often difficult to obtain data in the mining field. However, this technical solution effectively reduces the demand and dependence on data by introducing risk grading rules and an integrated technical processing flow. At the same time, by optimizing the algorithm design and simplifying the deployment process, the problem of difficult algorithm deployment in the mining field is solved. This enables this technical solution to be better applied and promoted in complex environments such as mines.
[0135] The present invention has the following beneficial effects:
[0136] Improve safety and risk warning capabilities: By automatically identifying high-risk, medium-risk, and low-risk areas in the mine environment, this method can quickly respond and mark potential safety hazards, thus improving the safety of mine operations. For high-risk areas, the dangerous areas are accurately divided through an image semantic segmentation model, and an electronic fence is automatically generated around them, effectively preventing safety accidents caused by personnel straying or equipment failures.
[0137] Enhance the level of intelligence and automation: This method uses AI technology for image classification, semantic segmentation, and object detection, realizing the intelligence and automation of mine safety management and reducing the need for manual intervention and judgment. In the past, the electronic fence area needed to be manually identified, that is, manually draw frames, which lacked generalization and could not be applied to multiple scenarios. The automatically generated electronic fence can be updated in real time and dynamically adjusted according to changes in the mine environment, improving the efficiency and accuracy of safety management.
[0138] The above-disclosed is only a preferred embodiment of the present invention. Of course, it cannot be used to limit the scope of the rights of the present invention. Those of ordinary skill in the art can understand all or part of the processes of implementing the above embodiments, and the equivalent changes made according to the claims of the present invention still fall within the scope covered by the invention.
Claims
1. An automatic electronic fence generation method based on the risk level of mine markers, characterized in that it includes the following steps: First, collect environmental images with potential safety hazards during the work and production of mine field personnel, form an image classification data set and label it. The labeling standards are high-risk images, medium-risk images, and low-risk images; Use the formed image classification data set for division and train an image classification model; Select another production environment image for labeling to form a test set, and use this test set to infer the image classification model, display and evaluate the model results; Deploy the image classification model to the edge server, connect to the on-site video stream, and use a fixed frame extraction interval to achieve online image detection and obtain the detection results of image classification; Based on the results of image classification, use different AI recognition models to detect various objects in the image; Select corresponding calibration objects according to the types of various objects in the image; According to the shape contour of the calibration object in the image, use the method of image transformation to adaptively fine-tune around it to form a closed electronic fence area.
2. The automatic electronic fence generation method based on the risk level of mine markers according to claim 1, characterized in that When forming the image classification data set and labeling it, use deep learning image label annotation software for labeling, and the labeling type is text txt or xml file.
3. The automatic electronic fence generation method based on the risk level of mine markers according to claim 2, characterized in that When using the formed image classification data set for division and training the image classification model: divide 20% of the images from the image classification data set as the validation set, and 80% of the images as the training set; The constructed image classification model is a model based on convolutional neural network (CNN). It automatically extracts the features of the image by learning a large number of image data sets, and classifies the image according to these features; The specific process includes: data preprocessing, feature extraction, full connection layer classification and output prediction; The image classification model structure includes an input layer, a convolutional layer, an activation function, a pooling layer, a full connection layer, an output layer and a loss function.
4. The automatic electronic fence generation method based on the risk level of mine markers according to claim 3, characterized in that Based on the results of image classification, when using different AI recognition models to detect various objects in the image: For high-risk images, use image semantic segmentation to segment the edge contours of each object. For medium- and low-risk images, use object detection to detect the positions and confidences of various objects; The adopted image semantic segmentation assigns a semantic label to each pixel in the image to achieve precise division and classification of each object area in the image; The adopted object detection not only identifies the main objects in the image, but also determines their specific positions in the image through bounding boxes.
5. The automatic electronic fence generation method based on the risk level of mine markers according to claim 4, characterized in that When selecting corresponding calibration objects according to the types of various objects in the image, the selected calibration objects are those that can represent the main objects or features in the image; The selected calibration object can be easily and accurately recognized in the image; the selected calibration object has a clear contour, obvious features, and sufficient contrast.
6. The method for automatically generating an electronic fence based on the risk level of mine markers as claimed in claim 5, wherein When adaptively forming a closed electronic fence area around the calibration object in the image according to the shape contour of the calibration object in the image by means of image transformation: The image transformation method adopted is proportional stretching or linear transformation; And there is a distance between the formed electronic fence area and the edge of the marker, and this distance is configured or fine-tuned manually; For the situation in the image where the calibration object is not obvious or the contour of the calibration object is difficult to detect, on the basis of AI recognition, an edge feature point extraction method is introduced to form feature points around the calibration object, and a closed polygon is combined to wrap the object inside, and then an image transformation formula is introduced to automatically form an electronic fence area; Finally, according to the ratio of the generated electronic fence area to the position area of the calibration object, combined with the tolerance coefficient input manually initially, adaptive area fine-tuning is realized.
7. The method for automatically generating an electronic fence based on the risk level of mine markers as claimed in claim 6, wherein The distance between the formed electronic fence area and the edge of the marker is directly measured in pixels, and an additional safety margin is set to ensure safety or avoid false alarms.
8. The method for automatically generating an electronic fence based on the risk level of mine markers as claimed in claim 7, wherein The specific method for automatically generating an electronic fence area according to the calibration object is as follows: First, draw the contour area or positioning area A of the calibration object, and obtain the coordinate position P(x p , y p ) of the center pixel point of the calibration object as the feature point, and this position is obtained through the centroid calculation formula. The centroid calculation formula is as follows: In the formula, x i and y i are the positions of each pixel within the calibration object contour area; then find the four corner vertices in the area, which are X1(x min ,y), X2(x,y max ), X3(x max ,y), X4(x,y max ), where x min , y min , x max , y max represent the nearest and farthest pixel positions of the area in the two directions of the X-axis and Y-axis of the image; Then, find the two pixels with the farthest distance in the contour area or positioning area of the calibration object, and calculate their Euclidean distance in the image and record it as d. After that, a tolerance coefficient r for the image risk level is defined manually, such as r = 1.5 for high risk, r = 1.2 for medium risk, and r = 1 for low risk, and this configuration can be used as an adaptive fine-tuning optimization option. Subsequently, judge whether a segmented or detected area is a regular shape, and a shape fitting algorithm (such as the least squares method) fits the extracted contour with a standard shape (such as a circle, rectangle, etc.). If it is an irregular contour, then the electronic fence area: If it is a regular circular contour, then the electronic fence area: If it is a regular rectangular or trapezoidal contour, then the electronic fence area:
9. The method for automatically generating an electronic fence based on the risk level of mine markers as claimed in claim 8, wherein The method for fine-tuning the generated electronic fence area is as follows: Calculate the ratio R of the generated electronic fence area to the area of the calibration object. Wherein the vertex coordinates of the electronic fence area are: ((x1,y1),(x2,y2),…,(x m ,y m )); The vertex coordinates of the calibration object are: ((x′1,y′1),(x′2,y′2),…,(x′ n ,y′ n )); According to R, at this time, update the tolerance coefficient r^* = r / R, and at this time, scale the electronic fence area proportionally, and configure the offset correction parameters manually. Set the left and right translation parameter to a and the up and down translation parameter to b. Under the condition that the boundary still contains the calibration object, the new electronic fence area S^* = r^**((S - a) + b) to realize adaptive area fine-tuning.
10. The method for automatically generating an electronic fence based on the risk level of mine markers as claimed in claim 9, wherein When specifically conducting the detection, the image field of view should cover the areas or equipment with potential safety hazards in the working production environment, and the image resolution should not be lower than 1920*1080; The image classification data set should include images of various dangerous areas in the mining field.
Citation Information
Patent Citations
Method, system and device for generating electronic fence and storage medium
CN111866722A
Electronic fence area generation system based on hazard source monitoring and personnel positioning
CN113115225A
Personnel safety risk silent monitoring method
CN115829324A
Electronic fence automatic generation method, real-time detection method and device
CN116416291A
Safety warning system of outdoor electric power facility and control method
CN117392793A