CN113408488A - Capsule network-based flame target identification method, device and medium - Google Patents

Capsule network-based flame target identification method, device and medium Download PDF

Info

Publication number
CN113408488A
CN113408488A CN202110813904.6A CN202110813904A CN113408488A CN 113408488 A CN113408488 A CN 113408488A CN 202110813904 A CN202110813904 A CN 202110813904A CN 113408488 A CN113408488 A CN 113408488A
Authority
CN
China
Prior art keywords
capsule
target
image
flame
network
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202110813904.6A
Other languages
Chinese (zh)
Other versions
CN113408488B (en
Inventor
岑丽辉
吴玉明
陈晓方
谢永芳
唐朝晖
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Central South University
Original Assignee
Central South University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Central South University filed Critical Central South University
Priority to CN202110813904.6A priority Critical patent/CN113408488B/en
Publication of CN113408488A publication Critical patent/CN113408488A/en
Application granted granted Critical
Publication of CN113408488B publication Critical patent/CN113408488B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Health & Medical Sciences (AREA)
  • Software Systems (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Biophysics (AREA)
  • Biomedical Technology (AREA)
  • Mathematical Physics (AREA)
  • Computational Linguistics (AREA)
  • Health & Medical Sciences (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Evolutionary Biology (AREA)
  • Image Analysis (AREA)

Abstract

The embodiment of the disclosure provides a method, equipment and medium for identifying a flame target based on a capsule network, which belong to the technical field of image processing and specifically comprise the following steps: performing second-order training by using the sample data set to obtain a target capsule network; inputting an image to be detected into a plurality of convolution layers, and extracting a feature map set containing spatial features; inputting the feature map set into a capsule conversion layer to obtain a primary capsule containing feature vectors; obtaining high-grade capsules; judging whether the vector modular length in the advanced capsule is greater than or equal to a threshold value; if so, judging that a flame target exists in the image to be detected; if not, judging that the flame target does not exist in the image to be detected. According to the scheme, the target capsule network is obtained through second-order training, and for the image to be detected input into the target capsule network, the vector modular length is calculated by using a combined dynamic routing algorithm of forward calculation of a multilayer capsule network so as to predict whether a flame target exists or not, so that the identification adaptability, the identification speed and the identification accuracy are improved.

Description

Capsule network-based flame target identification method, device and medium
Technical Field
The embodiment of the disclosure relates to the technical field of image processing, in particular to a method, equipment and medium for identifying a flame target based on a capsule network.
Background
At present, a flame target identification method based on images is an important component of intelligent security and forest fire prevention, and is also a mainstream method in the field of computer vision at present. The flame target identification method based on the image mainly comprises two main methods, namely an identification method based on traditional image processing and an identification method based on deep learning.
Flame identification based on traditional image processing is mainly a method combining manually extracted flame characteristics and a classifier model. Such as area size, texture features + bayesian classifiers, YCrCb features + K-means clustering, etc. The characteristics of the method are extracted by manual selection, and the method has the advantages of strong subjectivity, interference resistance, weaker adaptability and lack of generalization capability.
The flame recognition based on deep learning mainly refers to the fact that a Convolutional Neural Network (CNN for short) is utilized to directly extract deep abstract features which are difficult to intuitively understand by people from an image, the characterization capability of the deep abstract features is strong, the recognition and classification effect on flame targets is good, but the translation invariance of the CNN destroys the spatial features of the targets, so that the overall characteristic expression capability of the recognition targets is reduced, the training cost of the CNN is high, the calculated amount is huge, and the real-time performance of the flame recognition is poor.
Therefore, a flame target identification method based on a capsule network, which has high adaptability, identification speed and identification accuracy, is needed.
Disclosure of Invention
In view of the above, embodiments of the present disclosure provide a method, an apparatus, and a medium for identifying a flame target based on a capsule network, which at least partially solve the problems of poor adaptability, poor identification speed, and poor identification accuracy in the prior art.
In a first aspect, the disclosed embodiments provide a flame target identification method based on a capsule network, including:
performing second-order training by using a sample data set to obtain a target capsule network, wherein the sample data set comprises a plurality of images containing flame targets and a plurality of images without the flame targets, and the target capsule network comprises a plurality of convolution layers and a capsule conversion layer;
inputting an image to be detected into the plurality of convolution layers, and extracting a feature map set containing spatial features;
inputting the feature map set into the capsule conversion layer to obtain a primary capsule containing feature vectors;
forward calculation is carried out on the primary capsule according to a combined dynamic routing algorithm to obtain a high-grade capsule;
judging whether the vector modular length in the advanced capsule is larger than or equal to a threshold value;
if the vector mode length in the advanced capsule is larger than or equal to the threshold value, judging that a flame target exists in the image to be detected;
and if the vector mode length in the advanced capsule is smaller than the threshold value, judging that no flame target exists in the image to be detected.
According to a specific implementation manner of the embodiment of the present disclosure, the step of performing second-order training by using the sample data set to obtain the target capsule network includes:
training the initial capsule network according to the sample data set and the square error loss function to obtain an output vector;
and connecting a full-connection layer at the tail end of the initial capsule network, and training the full-connection layer by using the output vector to obtain a composite loss function so as to form the target capsule network.
According to a specific implementation manner of the embodiment of the present disclosure, the step of inputting the image to be detected into the plurality of convolutional layers and extracting the feature map set including the spatial features includes:
preprocessing the image to be detected to obtain a target image which is consistent with the input end specification of the target capsule network, wherein the preprocessing operation comprises at least one of stretching operation or zooming operation;
and inputting the target image into the plurality of convolution layers for convolution operation to obtain the feature map set.
According to a specific implementation manner of the embodiment of the present disclosure, the step of performing forward calculation on the primary capsule according to a joint dynamic routing algorithm to obtain an advanced capsule includes:
forward calculation is carried out on the primary capsule according to the combined dynamic routing algorithm to obtain a hidden layer capsule layer;
and obtaining the advanced capsule according to the hidden layer capsule layer forward calculation.
According to a specific implementation manner of the embodiment of the present disclosure, the formula of the composite loss function is
Figure BDA0003169492860000031
Figure BDA0003169492860000032
Wherein z isiIs a real tag at the advanced Capsule, y'iIs the real label of the output end of the full connection layer, y1|iVector modulo length, y, output for the advanced capsule2|iFor the prediction output of the fully-connected layer,
Figure BDA0003169492860000033
λ and μ are weights of two-part losses, which are indicators of consistency between the output of the advanced capsule and the output of the fully connected layer, and have initial values of λ -0 and μ -1.
In a second aspect, an embodiment of the present disclosure further provides an electronic device, including:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the capsule network based flame target identification method of the first aspect or any implementation of the first aspect.
In a third aspect, the disclosed embodiments also provide a non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform the capsule network-based flame target identification method of the first aspect or any implementation manner of the first aspect.
In a fourth aspect, the present disclosure also provides a computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions which, when executed by a computer, cause the computer to perform the capsule network based flame target identification method of the first aspect or any implementation of the first aspect.
The flame target identification scheme based on the capsule network in the embodiment of the disclosure comprises the following steps: performing second-order training by using a sample data set to obtain a target capsule network, wherein the sample data set comprises a plurality of images containing flame targets and a plurality of images without the flame targets, and the target capsule network comprises a plurality of convolution layers and a capsule conversion layer; inputting an image to be detected into the plurality of convolution layers, and extracting a feature map set containing spatial features; inputting the feature map set into the capsule conversion layer to obtain a primary capsule containing feature vectors; forward calculation is carried out on the primary capsule according to a combined dynamic routing algorithm to obtain a high-grade capsule; judging whether the vector modular length in the advanced capsule is larger than or equal to a threshold value; if the vector mode length in the advanced capsule is larger than or equal to the threshold value, judging that a flame target exists in the image to be detected; and if the vector mode length in the advanced capsule is smaller than the threshold value, judging that no flame target exists in the image to be detected.
The beneficial effects of the embodiment of the disclosure are: according to the scheme, the target capsule network is obtained through second-order training, and for the image to be detected input into the target capsule network, the vector modular length is calculated by using a combined dynamic routing algorithm of forward calculation of a multilayer capsule network so as to predict whether a flame target exists or not, so that the identification adaptability, the identification speed and the identification accuracy are improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings needed to be used in the embodiments will be briefly described below, and it is apparent that the drawings in the following description are only some embodiments of the present disclosure, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic flow chart of a flame target identification method based on a capsule network according to an embodiment of the present disclosure;
FIG. 2 is a structural diagram of feature extraction designed by a method for identifying a flame target based on a capsule network according to an embodiment of the present disclosure;
FIG. 3 is a partial schematic flow chart of a method for identifying a flame target based on a capsule network according to an embodiment of the present disclosure;
fig. 4 is a schematic view of an electronic device provided in an embodiment of the present disclosure.
Detailed Description
The embodiments of the present disclosure are described in detail below with reference to the accompanying drawings.
The embodiments of the present disclosure are described below with specific examples, and other advantages and effects of the present disclosure will be readily apparent to those skilled in the art from the disclosure in the specification. It is to be understood that the described embodiments are merely illustrative of some, and not restrictive, of the embodiments of the disclosure. The disclosure may be embodied or carried out in various other specific embodiments, and various modifications and changes may be made in the details within the description without departing from the spirit of the disclosure. It is to be noted that the features in the following embodiments and examples may be combined with each other without conflict. All other embodiments, which can be derived by a person skilled in the art from the embodiments disclosed herein without making any creative effort, shall fall within the protection scope of the present disclosure.
It is noted that various aspects of the embodiments are described below within the scope of the appended claims. It should be apparent that the aspects described herein may be embodied in a wide variety of forms and that any specific structure and/or function described herein is merely illustrative. Based on the disclosure, one skilled in the art should appreciate that one aspect described herein may be implemented independently of any other aspects and that two or more of these aspects may be combined in various ways. For example, an apparatus may be implemented and/or a method practiced using any number of the aspects set forth herein. Additionally, such an apparatus may be implemented and/or such a method may be practiced using other structure and/or functionality in addition to one or more of the aspects set forth herein.
It should be noted that the drawings provided in the following embodiments are only for illustrating the basic idea of the present disclosure, and the drawings only show the components related to the present disclosure rather than the number, shape and size of the components in actual implementation, and the type, amount and ratio of the components in actual implementation may be changed arbitrarily, and the layout of the components may be more complicated.
In addition, in the following description, specific details are provided to facilitate a thorough understanding of the examples. However, it will be understood by those skilled in the art that the aspects may be practiced without these specific details.
At present, a flame target identification method based on images is an important component of intelligent security and forest fire prevention, and is also a mainstream method in the field of computer vision at present. The flame target identification method based on the image mainly comprises two main methods, namely an identification method based on traditional image processing and an identification method based on deep learning.
Flame identification based on traditional image processing is mainly a method combining manually extracted flame characteristics and a classifier model. Such as area size, texture features + bayesian classifiers, YCrCb features + K-means clustering, etc. The characteristics of the method are extracted by manual selection, and the method has the advantages of strong subjectivity, interference resistance, weaker adaptability and lack of generalization capability.
The flame recognition based on deep learning mainly refers to the fact that a Convolutional Neural Network (CNN for short) is utilized to directly extract deep abstract features which are difficult to intuitively understand by people from an image, the characterization capability of the deep abstract features is strong, the recognition and classification effect on flame targets is good, but the translation invariance of the CNN destroys the spatial features of the targets, so that the overall characteristic expression capability of the recognition targets is reduced, the training cost of the CNN is high, the calculated amount is huge, and the real-time performance of the flame recognition is poor.
The embodiment of the disclosure provides a flame target identification method based on a capsule network, which can be applied to a flame target identification process in an image processing scene.
Referring to fig. 1, a schematic flow chart of a flame target identification method based on a capsule network is provided for an embodiment of the present disclosure. As shown in fig. 1, the method mainly comprises the following steps:
s101, performing second-order training by using a sample data set to obtain a target capsule network, wherein the sample data set comprises a plurality of images containing flame targets and a plurality of images without the flame targets, and the target capsule network comprises a plurality of convolutional layers and a capsule conversion layer;
in specific implementation, in consideration of the need for detecting a specific scene, such as a flame target, the sample data set may be established first, and specifically, 2500 image data sets including a flame target and 2500 image data sets not including a flame target may be selected to form the sample data set, and an image in the two image data sets corresponds to a label of the image data set, and the sample data set is trained to obtain the target capsule network. Considering that training loss exists in the training process, and the recognition accuracy of the trained target capsule network is reduced, second-order training can be performed to obtain the target capsule network.
S102, inputting an image to be detected into the plurality of convolution layers, and extracting a feature map set containing spatial features;
in specific implementation, after the electronic device receives the image to be detected, the image to be detected may be input to the plurality of convolution layers, and a plurality of feature maps including spatial features are obtained through layered convolution to form the feature map combination.
S103, inputting the feature map set into the capsule conversion layer to obtain a primary capsule containing feature vectors;
after the feature map set corresponding to the image to be detected is extracted, the feature map set can be input into the capsule conversion layer to obtain a primary capsule containing feature vectors for a subsequent calculation process.
S104, forward calculation is carried out on the primary capsule according to a combined dynamic routing algorithm to obtain a high-grade capsule;
considering that the generalization capability is weak when only the primary capsule is subjected to vector feature calculation, the primary capsule can be subjected to forward calculation according to the combined dynamic routing algorithm to obtain the advanced capsule, so that the accuracy of capsule network identification is improved, and the generalization capability and the anti-interference performance of the system are enhanced.
S105, judging whether the vector modular length in the advanced capsule is larger than or equal to a threshold value or not;
in specific implementation, the threshold value may be set according to a requirement of detection accuracy, after the advanced capsule is obtained, a vector modular length in the advanced capsule may be calculated, where the vector modular length represents a prediction probability that the target capsule network has a flame target in the image to be detected, and then the vector modular length is compared with the threshold value, so as to determine a next operation flow.
If the vector mode length in the advanced capsule is larger than or equal to the threshold value, executing a step S106, and judging that a flame target exists in the image to be detected;
in specific implementation, when the vector mode length in the advanced capsule is detected to be greater than or equal to the threshold value, it can be determined that a flame target exists in the image to be detected.
And if the vector mode length in the advanced capsule is smaller than the threshold value, executing a step S107, and judging that no flame target exists in the image to be detected.
In specific implementation, when the vector mode length in the advanced capsule is detected to be smaller than the threshold value, it can be determined that no flame target exists in the image to be detected.
According to the flame target identification method based on the capsule network, the target capsule network is obtained through second-order training, and for the image to be detected input into the target capsule network, the vector modular length is calculated by using a combined dynamic routing algorithm of forward calculation of a multilayer capsule network, so that whether the flame target exists or not is predicted, and the identification adaptability, the identification speed and the identification accuracy are improved.
On the basis of the foregoing embodiment, the step S101 of performing second-order training by using the sample data set to obtain the target capsule network includes:
training the initial capsule network according to the sample data set and the square error loss function to obtain an output vector;
in specific implementation, the sample data set may be input into the initial capsule network, and the parameters of the initial capsule network are trained by using the square error loss function, where the square error loss function is defined as:
Figure BDA0003169492860000081
wherein z isiRepresenting a genuine label, yiAn output value representing the advanced capsule, i.e., a predicted probability value of the initial capsule network for flame presence.
And connecting a full-connection layer at the tail end of the initial capsule network, and training the full-connection layer by using the output vector to obtain a composite loss function so as to form the target capsule network.
Further, the formula of the composite loss function is
Figure BDA0003169492860000082
Figure BDA0003169492860000083
Wherein z isiIs a real tag at the advanced Capsule, y'iIs the real label of the output end of the full connection layer, y1|iVector modulo length, y, output for the advanced capsule2|iFor the prediction output of the fully-connected layer,
Figure BDA0003169492860000084
λ and μ are weights of two-part losses, which are indicators of consistency between the output of the advanced capsule and the output of the fully connected layer, and have initial values of λ -0 and μ -1.
In specific implementation, after the output vector of the advanced capsule is obtained, the full-connection layer may be added at the end of the initial capsule network, then the composite loss function is obtained to train the parameters of the initial capsule network, each element value of the vector of the advanced capsule is used as the input of the full-connection layer, the network is further trained through the full-connection layer to form the target capsule network, so that the training loss of the capsule network is further reduced, and the identification accuracy of the network is improved.
On the basis of the above embodiment, the step S102 of inputting the image to be detected into the plurality of convolution layers and extracting a feature map set including spatial features includes:
preprocessing the image to be detected to obtain a target image which is consistent with the input end specification of the target capsule network, wherein the preprocessing operation comprises at least one of stretching operation or zooming operation;
and inputting the target image into the plurality of convolution layers for convolution operation to obtain the feature map set.
In specific implementation, considering that specifications of input images to be detected may be different and specifications of an input end of the target capsule network are fixed, after the images to be detected are received, stretching operation or scaling operation may be performed on the images to be detected to obtain the target images, so that the specifications of the images to be detected are consistent with the specifications of the input end of the target capsule network. Then, the target image is input into the plurality of convolution layers and is subjected to convolution operation to obtain the feature map set, the feature extraction structure of the plurality of convolution layers is shown in fig. 2, the output of the feature extraction layers is 256 feature maps with the size of 18 × 18, and the feature maps are packed by taking 8 feature maps as 1 group to obtain 32 groups of output feature tensors with the size of 8 × 18. There is no pooling layer between each convolution layer to prevent pooling operations from corrupting the spatial feature information of the target.
As shown in fig. 3, the step S104 of performing forward calculation on the primary capsule according to a joint dynamic routing algorithm to obtain an advanced capsule includes:
s301, forward calculation is carried out on the primary capsule according to the combined dynamic routing algorithm to obtain a hidden layer capsule layer;
for example, the primary capsule calculates the hidden capsule layer FeatureCaps forward through the joint dynamic routing algorithm, and the pseudo code of the calculation process is, for example, Function 1.
Figure BDA0003169492860000091
Figure BDA0003169492860000101
Function 1 is directed to the forward calculation process between the primary capsule and the hidden capsule, and the square Function in the algorithm is of the form:
Figure BDA0003169492860000102
wherein s isjIs an input vector, vjIs a compressed output vector whose modulo length is limited to between 0-1.
Wherein the softmax function is of the form:
Figure BDA0003169492860000103
matrix array
Figure BDA0003169492860000104
Is the vector u of the primary capsulei[8×1]And the vector of the advanced capsule
Figure BDA0003169492860000105
A transformation matrix between.
S302, the advanced capsule is obtained through forward calculation according to the hidden layer capsule layer.
In specific implementation, after the hidden layer capsule layer is obtained, the advanced capsule containing the prediction probability is obtained through forward calculation according to the hidden layer capsule layer, and the pseudo code of the calculation process is as Function 2.
Figure BDA0003169492860000106
The softmax Function in Function 2 is of the form:
Figure BDA0003169492860000107
unlike the softmax Function in Function 1, since the output number of the advanced capsules is 1, the softmax Function may need to be changed into this form to avoid the meaningless parameter training of the network.
Referring to fig. 4, an embodiment of the present disclosure also provides an electronic device 40, including: at least one processor and a memory communicatively coupled to the at least one processor. Wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the capsule network based flame target identification method of the method embodiments described above.
The disclosed embodiments also provide a non-transitory computer-readable storage medium storing computer instructions for causing the computer to perform the capsule network-based flame target identification method in the aforementioned method embodiments.
The disclosed embodiments also provide a computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions which, when executed by a computer, cause the computer to perform the capsule network based flame target identification method of the aforementioned method embodiments.
Referring now to FIG. 4, a block diagram of an electronic device 40 suitable for use in implementing embodiments of the present disclosure is shown. The electronic devices in the embodiments of the present disclosure may include, but are not limited to, mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), in-vehicle terminals (e.g., car navigation terminals), and the like, and fixed terminals such as digital TVs, desktop computers, and the like. The electronic device shown in fig. 4 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure.
As shown in fig. 4, the electronic device 40 may include a processing means (e.g., a central processing unit, a graphics processor, etc.) 401 that may perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)402 or a program loaded from a storage means 408 into a Random Access Memory (RAM) 403. In the RAM 403, various programs and data necessary for the operation of the electronic apparatus 40 are also stored. The processing device 401, the ROM 402, and the RAM 403 are connected to each other via a bus 404. An input/output (I/O) interface 405 is also connected to bus 404.
Generally, the following devices may be connected to the I/O interface 405: input devices 406 including, for example, a touch screen, touch pad, keyboard, mouse, image sensor, microphone, accelerometer, gyroscope, etc.; an output device 407 including, for example, a Liquid Crystal Display (LCD), a speaker, a vibrator, and the like; storage 408 including, for example, tape, hard disk, etc.; and a communication device 409. The communication device 409 may allow the electronic device 40 to communicate wirelessly or by wire with other devices to exchange data. While the figures illustrate an electronic device 40 having various means, it is to be understood that not all illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via the communication device 409, or from the storage device 408, or from the ROM 402. The computer program performs the above-described functions defined in the methods of the embodiments of the present disclosure when executed by the processing device 401.
It should be noted that the computer readable medium in the present disclosure can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In contrast, in the present disclosure, a computer readable signal medium may comprise a propagated data signal with computer readable program code embodied therein, either in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the foregoing.
The computer readable medium may be embodied in the electronic device; or may exist separately without being assembled into the electronic device.
The computer readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to perform the steps associated with the method embodiments.
Alternatively, the computer readable medium carries one or more programs which, when executed by the electronic device, enable the electronic device to perform the steps associated with the method embodiments.
Computer program code for carrying out operations for aspects of the present disclosure may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + +, and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present disclosure may be implemented by software or hardware.
It should be understood that portions of the present disclosure may be implemented in hardware, software, firmware, or a combination thereof.
The above description is only for the specific embodiments of the present disclosure, but the scope of the present disclosure is not limited thereto, and any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope of the present disclosure should be covered within the scope of the present disclosure. Therefore, the protection scope of the present disclosure shall be subject to the protection scope of the claims.

Claims (7)

1. A flame target identification method based on a capsule network is characterized by comprising the following steps:
performing second-order training by using a sample data set to obtain a target capsule network, wherein the sample data set comprises a plurality of images containing flame targets and a plurality of images without the flame targets, and the target capsule network comprises a plurality of convolution layers and a capsule conversion layer;
inputting an image to be detected into the plurality of convolution layers, and extracting a feature map set containing spatial features;
inputting the feature map set into the capsule conversion layer to obtain a primary capsule containing feature vectors;
forward calculation is carried out on the primary capsule according to a combined dynamic routing algorithm to obtain a high-grade capsule;
judging whether the vector modular length in the advanced capsule is larger than or equal to a threshold value;
if the vector mode length in the advanced capsule is larger than or equal to the threshold value, judging that a flame target exists in the image to be detected;
and if the vector mode length in the advanced capsule is smaller than the threshold value, judging that no flame target exists in the image to be detected.
2. The method of claim 1, wherein the step of performing a second-order training using the sample data set to obtain a target capsule network comprises:
training the initial capsule network according to the sample data set and the square error loss function to obtain an output vector;
and connecting a full-connection layer at the tail end of the initial capsule network, and training the full-connection layer by using the output vector to obtain a composite loss function so as to form the target capsule network.
3. The method according to claim 1, wherein the step of inputting the image to be detected into the plurality of convolutional layers and extracting a feature map set containing spatial features comprises:
preprocessing the image to be detected to obtain a target image which is consistent with the input end specification of the target capsule network, wherein the preprocessing operation comprises at least one of stretching operation or zooming operation;
and inputting the target image into the plurality of convolution layers for convolution operation to obtain the feature map set.
4. The method of claim 1, wherein said step of forward computing said primary capsule according to a joint dynamic routing algorithm to obtain an advanced capsule comprises:
forward calculation is carried out on the primary capsule according to the combined dynamic routing algorithm to obtain a hidden layer capsule layer;
and obtaining the advanced capsule according to the hidden layer capsule layer forward calculation.
5. The method of claim 2, wherein the composite loss function is formulated as
Figure FDA0003169492850000021
Figure FDA0003169492850000022
Wherein z isiIs a real tag at the advanced Capsule, y'iIs the real label of the output end of the full connection layer, y1|iVector modulo length, y, output for the advanced capsule2|iFor the prediction output of the fully-connected layer,
Figure FDA0003169492850000023
λ and μ are weights of two-part losses, which are indicators of consistency between the output of the advanced capsule and the output of the fully connected layer, and have initial values of λ -0 and μ -1.
6. An electronic device, characterized in that the electronic device comprises:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the capsule network based flame target identification method of any of the preceding claims 1-5.
7. A non-transitory computer readable storage medium storing computer instructions for causing a computer to perform the capsule network based flame target identification method of any of the preceding claims 1-5.
CN202110813904.6A 2021-07-19 2021-07-19 Capsule network-based flame target identification method, device and medium Active CN113408488B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110813904.6A CN113408488B (en) 2021-07-19 2021-07-19 Capsule network-based flame target identification method, device and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110813904.6A CN113408488B (en) 2021-07-19 2021-07-19 Capsule network-based flame target identification method, device and medium

Publications (2)

Publication Number Publication Date
CN113408488A true CN113408488A (en) 2021-09-17
CN113408488B CN113408488B (en) 2022-11-25

Family

ID=77686897

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110813904.6A Active CN113408488B (en) 2021-07-19 2021-07-19 Capsule network-based flame target identification method, device and medium

Country Status (1)

Country Link
CN (1) CN113408488B (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109063742A (en) * 2018-07-06 2018-12-21 平安科技(深圳)有限公司 Butterfly identifies network establishing method, device, computer equipment and storage medium
US20190370972A1 (en) * 2018-06-04 2019-12-05 University Of Central Florida Research Foundation, Inc. Capsules for image analysis
CN110598028A (en) * 2019-09-06 2019-12-20 阿里巴巴集团控股有限公司 Image classification method and device, storage medium and electronic equipment
CN111310690A (en) * 2020-02-25 2020-06-19 河南理工大学 Forest fire recognition method and device based on CN and three-channel capsule network
CN111353412A (en) * 2020-02-25 2020-06-30 河南理工大学 End-to-end 3D-CapsNet flame detection method and device
US20210090302A1 (en) * 2019-09-24 2021-03-25 Apple Inc. Encoding Three-Dimensional Data For Processing By Capsule Neural Networks
CN112766340A (en) * 2021-01-11 2021-05-07 中山大学 Depth capsule network image classification method and system based on adaptive spatial mode
US20210142081A1 (en) * 2019-11-11 2021-05-13 Coretronic Corporation Image recognition method and device

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190370972A1 (en) * 2018-06-04 2019-12-05 University Of Central Florida Research Foundation, Inc. Capsules for image analysis
CN109063742A (en) * 2018-07-06 2018-12-21 平安科技(深圳)有限公司 Butterfly identifies network establishing method, device, computer equipment and storage medium
CN110598028A (en) * 2019-09-06 2019-12-20 阿里巴巴集团控股有限公司 Image classification method and device, storage medium and electronic equipment
US20210090302A1 (en) * 2019-09-24 2021-03-25 Apple Inc. Encoding Three-Dimensional Data For Processing By Capsule Neural Networks
US20210142081A1 (en) * 2019-11-11 2021-05-13 Coretronic Corporation Image recognition method and device
CN111310690A (en) * 2020-02-25 2020-06-19 河南理工大学 Forest fire recognition method and device based on CN and three-channel capsule network
CN111353412A (en) * 2020-02-25 2020-06-30 河南理工大学 End-to-end 3D-CapsNet flame detection method and device
CN112766340A (en) * 2021-01-11 2021-05-07 中山大学 Depth capsule network image classification method and system based on adaptive spatial mode

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
ASAD ULLAH ET AL: "Empirical Investigation of Multimodal Sensors in Novel Deep Facial Expression Recognition In-the-Wild", 《JOURNAL OF SENSORS》 *
KAI QIAO ET AL: "Accurate reconstruction of image stimuli from human fMRI based on the decoding model with capsule network architectur", 《FRONTIERS IN NEUROINFORMATICS》 *
王琦: "基于CapsNet的图像分割及在医学图像中的应用", 《中国优秀博硕士学位论文全文数据库(硕士) 基础科学辑(月刊)》 *
陈靖雯: "基于胶囊网络的人脸检测与识别研究", 《中国优秀博硕士学位论文全文数据库(硕士) 信息科技辑(月刊)》 *

Also Published As

Publication number Publication date
CN113408488B (en) 2022-11-25

Similar Documents

Publication Publication Date Title
CN111476309B (en) Image processing method, model training method, device, equipment and readable medium
US20230394671A1 (en) Image segmentation method and apparatus, and device, and storage medium
WO2020228405A1 (en) Image processing method and apparatus, and electronic device
CN110287816B (en) Vehicle door motion detection method, device and computer readable storage medium
CN110674349B (en) Video POI (Point of interest) identification method and device and electronic equipment
CN112766284B (en) Image recognition method and device, storage medium and electronic equipment
CN112037223B (en) Image defect detection method and device and electronic equipment
CN112232311B (en) Face tracking method and device and electronic equipment
CN110399847A (en) Extraction method of key frame, device and electronic equipment
CN114359225A (en) Image detection method, image detection device, computer equipment and storage medium
CN115758282A (en) Cross-modal sensitive information identification method, system and terminal
CN110069997B (en) Scene classification method and device and electronic equipment
CN110197459B (en) Image stylization generation method and device and electronic equipment
CN110555861B (en) Optical flow calculation method and device and electronic equipment
CN113408488B (en) Capsule network-based flame target identification method, device and medium
CN116681765A (en) Method for determining identification position in image, method for training model, device and equipment
CN115424060A (en) Model training method, image classification method and device
CN117437516A (en) Semantic segmentation model training method and device, electronic equipment and storage medium
CN111340813A (en) Image instance segmentation method and device, electronic equipment and storage medium
CN111950572A (en) Method, apparatus, electronic device and computer-readable storage medium for training classifier
CN110263852B (en) Data processing method and device and electronic equipment
CN113140012B (en) Image processing method, device, medium and electronic equipment
CN110674348B (en) Video classification method and device and electronic equipment
CN110222590B (en) Image difference judgment method and device and electronic equipment
CN116580384A (en) Target detection method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant