Search

CN-121982289-A - Fire detection method and system based on anchor-free framework

CN121982289ACN 121982289 ACN121982289 ACN 121982289ACN-121982289-A

Abstract

The invention relates to a fire detection method and a fire detection system based on an Anchor-Free framework, wherein the method comprises the steps of obtaining a fire data set, dividing the fire data set into a training set and a testing set according to a preset proportion, constructing a fire detection network based on the Anchor-Free framework, comprising a main network for feature extraction, a neck network for feature fusion and a detection network for fire monitoring, reconstructing a residual module in the main network into a multi-branch structure, embedding an adaptive attention mechanism for enhancing the feature extraction capability, constructing the neck network based on an improved feature pyramid network, training the fire detection network by utilizing the training set to obtain a fire detection network after training, obtaining the fire data set to be detected, and inputting the fire detection network after training to obtain a detection result.

Inventors

  • ZHAO JIANHUA
  • ZHAO DONGDONG
  • HUANG ZHONG
  • Gao Jiumian
  • HU RUOLIN
  • WANG XINGXING
  • XIA SHUJUN
  • YE SIYI

Assignees

  • 四川华能太平驿水电有限责任公司
  • 四川九洲北斗导航与位置服务有限公司

Dates

Publication Date
20260505
Application Date
20260127

Claims (10)

  1. 1. A fire detection method based on an anchor-free framework, the method comprising: acquiring a fire disaster data set, and dividing the fire disaster data set into a training set and a testing set according to a preset proportion; An Anchor-Free framework based fire detection network is constructed, and comprises a main network for feature extraction, a neck network for feature fusion and a detection network for fire monitoring, wherein a residual error module in the main network is reconstructed into a multi-branch structure and an adaptive attention mechanism is embedded for enhancing the feature extraction capability; training the fire detection network by using the training set to obtain a trained fire detection network; And acquiring a fire disaster data set to be detected, and inputting the fire disaster data set to a fire disaster detection network with training completed to obtain a detection result.
  2. 2. The fire detection method based on the anchor-free framework according to claim 1, wherein the backbone network adopts ResNet to reconstruct each residual module in ResNet to a multi-branch structure, and the multi-branch structure is specifically that sub-modules with the same structure are stacked in parallel.
  3. 3. The fire detection method based on the anchor-free framework of claim 2, wherein the 3 x3 convolution layer in ResNet is replaced by an adaptive attention mechanism, wherein: The adaptive attention mechanism comprises two parallel branches, wherein the first branch is a3×3 convolution layer, and the second branch is a5×5 convolution layer; The self-adaptive attention mechanism carries out secondary feature extraction on the extracted input features based on the first branch and the second branch, and fuses the features after the secondary extraction to obtain intermediate features; the intermediate features after global average pooling are processed through convolution kernel size as follows Is adjacent to one another Performing cross-channel interaction among the channels to obtain intermediate characteristics after the cross-channel interaction; normalizing the intermediate features after cross-channel interaction by using a Softmax function to generate weight coefficients of all channels; and multiplying the weight coefficient by the intermediate characteristic after cross-channel interaction channel by channel, and adding the multiplied weight coefficient to the characteristic after secondary characteristic extraction to obtain the output characteristic of the self-adaptive attention mechanism.
  4. 4. The fire detection method based on an anchor-free framework according to claim 1, wherein the improved feature pyramid network is specifically based on a feature pyramid network, and upsampling by sub-pixel convolution is introduced; the sub-pixel convolution is realized specifically through pixel recombination, and the size is as follows Is of the order of the recombination dimension Is provided with an output characteristic of (a), wherein, the Representing the height of the input feature(s), The width of the input feature is indicated, The number of channels representing the input characteristics is indicated, Representing the expansion rate of the input feature.
  5. 5. The fire detection method based on the anchor-free framework of claim 4, wherein the self-adaptive feature enhancement module comprises a plurality of convolution branches with different convolution kernel sizes and is used for extracting feature information under different sensing fields, output features of the convolution branches are subjected to global average pooling, and corresponding weight coefficients are generated through one-dimensional convolution and Softmax functions and are used for representing importance degrees of all scale features in a current image.
  6. 6. The fire detection method based on the anchor-free framework of claim 5, wherein the characteristic enhancement module is specifically a multi-layer parallel cavity convolution branch, and each cavity convolution branch is provided with an expansion rate which increases gradually from top to bottom; If the current cavity convolution branch is the first cavity convolution branch, the output characteristic of the current cavity convolution branch is obtained by adding the sampling characteristic of the first level and the fusion characteristic, otherwise, the output characteristic of the current cavity convolution branch is obtained by adding the sampling characteristic of the corresponding level and the output characteristic of the cavity convolution branch of the last level; and outputting the output characteristics of the cavity convolution branch of the last level, namely the enhancement characteristics.
  7. 7. The method of claim 1, wherein the detection network comprises a classification branch and a regression branch: the classification branches output confidence degrees of the current position as a fire center area based on a plurality of convolution layers with preset sizes; The regression branch outputs a predicted fire position target boundary frame and a corresponding fire position centrality, wherein the fire position centrality represents a normalized distance between a current fire position and a preset target center.
  8. 8. A fire detection system based on an anchor-free frame construction, the system comprising: the data acquisition module is used for acquiring a fire disaster data set and dividing the fire disaster data set into a training set and a testing set according to a preset proportion; The system comprises a training module, a built-in anchor-free framework, a neck network, a detection network, a self-adaptive attention mechanism and a fire detection module, wherein the built-in anchor-free framework is used for building a fire detection network, the fire detection network comprises a main network for feature extraction, a neck network for feature fusion and a detection network for fire monitoring, and the residual error module in the main network is reconstructed into a multi-branch structure and is embedded into the self-adaptive attention mechanism for enhancing the feature extraction capability; training the fire detection network by using the training set to obtain a trained fire detection network; The detection module is used for acquiring a fire disaster data set to be detected, inputting the fire disaster data set to the fire disaster detection network after training is completed, and obtaining a detection result.
  9. 9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the method of any one of claims 1 to 7 when the program is executed by the processor.
  10. 10. A computer readable storage medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements the method according to any one of claims 1 to 7.

Description

Fire detection method and system based on anchor-free framework Technical Field The invention relates to the technical field of target detection, in particular to a fire detection method and system based on an anchor-free framework. Background Fire disasters are common disasters, and it is important to quickly and accurately detect and early warn in the early stage of the disasters. Early sensor-based detection methods were significantly limited by environment and space and had slow responses. With the development of computer vision technology, image-based flame detection methods have become a mainstream solution because of their high speed, high precision and accurate positioning capabilities. The current flame detection method is usually trained on a specific data set, has higher recognition precision on similar backgrounds and flame forms in the data set, but is difficult to generalize to complex real scenes, for example, has poor robustness on interference objects (such as sunset and neon lights) similar to flame colors, combustibles (such as liquid, solid and gas flames) with different textures and dynamic backgrounds (such as crowd and vehicle movement), mainly results from the fact that differences exist between the distribution of training data and the complex and changeable physical environment of the real world, so that the environmental background adaptability of a model is insufficient, and secondly, the main network and the feature pyramid structure of the existing detection algorithm still have insufficient feature extraction and fusion capabilities on extreme sizes (especially small target flames at a distance or large-area flames after the flame spread), so that the detection recall rate and the positioning precision of multi-scale flames, especially small-scale flames, are low due to the fact that the distance and the degree of the monitoring cameras are different from the fire points and the fire. The Chinese patent application with publication number of CN117593625A discloses an intelligent detection method for fire without anchor frame. According to the technical scheme, a fire detection model is built based on an improved YOLOv model, the improved YOLOv model comprises a backbone network for achieving feature extraction, a neck network for carrying out multi-scale fusion on different levels of features extracted by the backbone network and a detection head module for executing target detection and classification, a C3 module is replaced by a C2f module for a structure in the backbone network, the neck network comprises an FPN-PAN bottleneck structure, the FPN structure is used for transmitting strong semantic features from top to bottom, the PAN structure is used for transmitting strong locating features from bottom to top, the target detection head module adopts a multi-stage decoupling head, a dataset is collected and divided into a training set, a verification set and a testing set, the fire detection model is subjected to multi-round training according to preset training parameters, a detected image is input into the trained fire detection model, and a detection result is output, however, the improvement of the technical scheme replaces the C2f module, only improves the channel utilization rate and gradient transmission efficiency, cannot adapt to the characteristics of a fire target dimension, irregular and edge, the characteristic of the fire target dimension, the characteristic is not suitable for being well-fuzzy, the target dimension, the characteristic is not suitable for being well-covered by a frame, and the characteristic of a fire Anchor is not suitable for being well-designed, and the dynamic situation is large in a scale, and the situation is not suitable for being well-stressed, and the fire Anchor has a large-scale-frame is required to be well-by a dynamic, and has the characteristics that the characteristics of a fire Anchor frame is in a large-scale. Therefore, there is a need for a multi-scale fire detection method that can be adapted to practical situations. Disclosure of Invention In order to solve the problems in the prior art, the invention provides a fire detection method and a fire detection system based on an anchor-free framework. The technical scheme of the invention is as follows: In one aspect, the invention provides a fire detection method based on an anchor-free framework, which comprises the following steps: acquiring a fire disaster data set, and dividing the fire disaster data set into a training set and a testing set according to a preset proportion; An Anchor-Free framework based fire detection network is constructed, and comprises a main network for feature extraction, a neck network for feature fusion and a detection network for fire monitoring, wherein a residual error module in the main network is reconstructed into a multi-branch structure and an adaptive attention mechanism is embedded for enhancing the feature extraction capability; training