Flame detector sensitivity setting method based on BP neural network
By adopting the sensitivity setting method based on BP neural network in the flame detector, combined with the characteristics of infrared and ultraviolet sensors, the problem that traditional flame detector algorithms cannot fully utilize the advantages of red and ultraviolet sensors is solved, and higher flame detection accuracy and sensitivity are achieved.
Patent Information
- Application Number
- CN202111155581.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-09-29
- Publication Date
- 2025-05-16
- Estimated Expiration
- 2041-09-29
AI Technical Summary
The traditional flame detector developed based on pyroelectric infrared sensors and ultraviolet pulse sensors has better algorithm performance than a single sensor, but the simple linear classification and fusion strategy cannot fully utilize the advantages of the combination of red and ultraviolet sensors, resulting in a large room for improvement in flame detection algorithms.
The flame detector sensitivity setting method based on BP neural network is used to construct the flame detector through sample recording, feature extraction and BP neural network model training. The method includes combining and extracting infrared and ultraviolet features, and using the BP neural network model to identify flame and classified flame signal sizes, and output fire warnings.
Through the application of the BP neural network model, the advantages of combining red and ultraviolet sensors can be better utilized, the flame detection accuracy can be improved, and the alarm performance can be met with different sensitivity requirements.
Smart Images

Figure CN113869232B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of flame detectors, and in particular to a flame detector sensitivity setting method based on a BP neural network. Background Art
[0002] In flame detectors, pyroelectric infrared sensors and ultraviolet sensors have been used successively and integrated with each other. Based on pyroelectric infrared sensors (referred to as IR in this article), different filters can be selected to detect different object signals. The filters of the infrared channel are generally selected around 3.8um (detection of artificial heat source interference signals), around 5.0um (detection of background noise interference signals), around 2.95um (detection of hydrogen flame signals), and around 4.4um (detection of traditional carbon hydrogen flame signals); ultraviolet sensors (referred to as UV in this article) output pulse signals. The greater the density of the pulse signal, the stronger the signal. The ultraviolet sensor has a detection effect on both carbon hydrogen flames and hydrogen flames. The disadvantage is that the detection distance is not as good as that of infrared sensors. Based on the above IR and UV, different types of flame detectors can be combined, such as IR carbon hydrogen, IR hydrogen, IR\UV carbon hydrogen, IR\UV hydrogen, IR4 carbon hydrogen (select two around 4.4um), IR4 carbon hydrogen + hydrogen, IR3\UV carbon hydrogen, IR3\UV hydrogen, IR4\UV carbon hydrogen + hydrogen, etc.
[0003] However, the traditional flame detectors developed based on pyroelectric infrared sensors and ultraviolet pulse sensors mostly use threshold methods combined with the fusion strategy of AND or relationship, which has better performance than a single sensor, but the simple linear classification and fusion strategy cannot fully play the advantages of the combination of red and ultraviolet sensors. There is still a lot of room for improvement in flame detection algorithms. Therefore, it is necessary to propose a flame detector sensitivity setting method based on BP neural network to solve the above problems. Summary of the invention
[0004] The invention provides a flame detector sensitivity setting method based on BP neural network to solve the problem that the prior art cannot fully bring into play the advantages of combining red and ultraviolet sensors.
[0005] The present invention provides a flame detector sensitivity setting method based on BP neural network, comprising:
[0006] Sample recording, wherein the types of samples include flames and interference sources, and each sample is recorded in combination at different distances and angles from the flame detector;
[0007] Crop the recorded samples to obtain a sample set of fixed length;
[0008] Extracting infrared features and ultraviolet features from the sample set, and merging the extracted infrared features and ultraviolet features to obtain a feature sample set;
[0009] Using the feature sample set as a first training set, training a first BP neural network model;
[0010] Only infrared flame channel features and ultraviolet features are used to trim the feature sample set, and the trimmed feature sample set is used as a second training set to train a second BP neural network model;
[0011] A flame detector is constructed based on the first BP neural network model and the second BP neural network model, and the flame detector is configured to: perform feature extraction on the detection data collected by the ultraviolet sensor and the infrared sensor; input the result of the feature extraction into the first BP neural network model to identify whether the detection target is a flame; if the detection target is a flame, input the result of the feature extraction into the second BP neural network model to classify the size of the flame signal; if the size of the flame signal meets the set sensitivity requirement, the second BP neural network model outputs a fire warning, and the flame detector issues a flame alarm.
[0012] Furthermore, sample recording, wherein the types of samples include flames and interference sources, each sample is recorded in combination at different distances and angles from the flame detector, the host computer writes the GUI, the slave computer writes the corresponding driver, and finally the sample recording is started and ended by the host computer instruction, the data is transmitted from the slave computer to the host computer via Modbus, and saved as a txt or bin file on the host computer
[0013] Furthermore, in the step of trimming the recorded samples to obtain a sample set of fixed duration, the sampling frequency is Fs=128 Hz, and one of the samples to be trimmed is the matrix X 4×1280 , indicating 4-channel data, the duration is Second.
[0014] Further, in the step of performing infrared feature extraction and ultraviolet feature extraction on the sample set, and merging the extracted infrared features and ultraviolet features to obtain a feature sample set, the infrared feature extraction includes:
[0015] The matrix of the cropped sample set is Y 4×256×N , N is the length of the pruned sample set, for one of the samples y 4×256 Perform feature extraction, the first 3 channels are y IR,3×256 , the last channel is y UV,1×256 ; Infrared feature extraction uses Fourier transform, infrared 1 channel y IR1,1×256 The Fourier transform process is as follows:
[0016]
[0017] f(k) is the frequency domain value of Fourier transform, i is the accumulated index, j is the complex sign, and k is the frequency domain sequence;
[0018] The minimum frequency domain resolution is |f(0)| corresponds to the DC component, |f(1)| corresponds to the 0.5 Hz amplitude in the frequency domain, and so on. If the DC component and symmetric data are removed, the number of frequency domain amplitude features is 128, recorded as {|f(1)|, |f(2)|, ..., |f(128)|}.
[0019] Furthermore, in the step of performing infrared feature extraction and ultraviolet feature extraction on the sample set, and merging the extracted infrared features and ultraviolet features to obtain a feature sample set, the ultraviolet feature extraction includes:
[0020] Each discrete UV signal represents the The number of internal UV pulses, the number of pulses extracted from the UV channel f_UV1, the density f_UV2, and the maximum value f_UV3 are as follows:
[0021]
[0022]
[0023]
[0024] Wherein, β=256, count_nonzero is the number of non-zero values in the 256 ultraviolet pulse counting signals.
[0025] Furthermore, in the step of extracting infrared features and ultraviolet features from the sample set, and merging the extracted infrared features and ultraviolet features to obtain the feature sample set, the step of merging the extracted infrared features and ultraviolet features comprises:
[0026] The infrared features are taken from 0 to 20 Hz in the frequency domain. The infrared features of the three channels are:
[0027] {|f(1)| / α, |f(2)| / α, ..., |f(40)| / α}, α = 10, is the normalization coefficient, 3 channels total 40*3 = 120 infrared features, after normalization, the infrared 3 channel features are {f_IR1, f_IR2, ..., f_IR 120}, 1~40 are the first channel features, 41~80 are the second channel features, 81~120 are the third channel features, plus the ultraviolet 3 features {f_UV1, f_UV2, f_UV3}, a total of 123 features constitute the feature sample set:
[0028] N represents the length of the feature sample set, which is equal to the number of cropped samples.
[0029] Furthermore, in the step of training a first BP neural network model using the feature sample set as the first training set, the first BP neural network model adopts F N×123 As a training set, the number of input nodes of the first BP neural network model is 123, and the number of output nodes of the first BP neural network model is 2, including fire and non-fire.
[0030] Furthermore, only infrared flame channel features and ultraviolet features are used to trim the feature sample set, and the trimmed feature sample set is used as the second training set. In the step of training the second BP neural network model, F N×123 The sample set is cropped out:
[0031] As the second training set, the number of input nodes of the second BP neural network model is 43, and the number of output nodes of the second BP neural network model is 3; the second BP neural network model sets 3 sensitivity levels: 1 for low, 2 for medium, and 3 for high; among them, for the samples at an angle of 0 degrees in the second training set, the samples of 0-25 meters are marked as 1, the samples of 26-40 meters are marked as 2, and the samples of 41-40 meters are marked as 3.
[0032] Furthermore, the number of hidden layer nodes hide_len of the first BP neural network model and the second BP neural network model is determined according to the following formula, and the simulation optimization is performed to select the r value corresponding to the highest cross-validation accuracy:
[0033] γ∈{0, 1, 2, ..., 10}; where in_len is the number of nodes in the model input layer, out_len is the number of nodes in the model output layer, and γ is 0-10, which is an adjustable parameter;
[0034] The hidden layer activation functions are all sigmoid functions, as shown in the following formula:
[0035]
[0036] f(hi) represents the hidden layer activation function, h i is the output of the i-th node in the hidden layer;
[0037] The output layer activation function is the softmax function, as shown in the following formula:
[0038]
[0039] Among them, h i is the output of the i-th node in the hidden layer, o i is the output of the i-th node in the output layer.
[0040] Furthermore, the flame detection alarm model is configured as follows: if the size of the flame signal meets the set sensitivity requirement, the flame detection alarm model outputs a fire warning; determines whether the number of fire warnings output by the flame detection alarm model exceeds a consecutive fire warning number threshold; if the number of fire warnings output by the flame detection alarm model exceeds a consecutive fire warning number threshold, a flame alarm is issued.
[0041] The beneficial effects of the present invention are as follows: a flame detector sensitivity setting method based on a BP neural network provided by the present invention, through sample recording, the recorded samples are cropped to obtain a sample set of fixed time length; infrared feature extraction and ultraviolet feature extraction are performed on the sample set, and the extracted infrared features and ultraviolet features are merged to obtain a feature sample set; the feature sample set is used as a first training set to train a first BP neural network model; only infrared flame channel features and ultraviolet features are used to crop the feature sample set, and the cropped feature sample set is used as a second training set to train a second BP neural network model; a flame detector is constructed based on the first BP neural network model and the second BP neural network model, and feature extraction of detection data collected by the ultraviolet sensor and the infrared sensor can be realized; the result of feature extraction is input into the first BP neural network model to identify whether the detection target is a flame; if the detection target is a flame, the result of feature extraction is input into the second BP neural network model to classify the size of the flame signal; if the size of the flame signal meets the set sensitivity requirement, the second BP neural network model outputs a fire warning, and the flame detector sends a flame alarm, which can better give play to the advantages of the combination of red and ultraviolet sensors, and the detection accuracy of the flame is significantly improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] In order to more clearly illustrate the technical solution of the present invention, the drawings required for use in the embodiments are briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0043] Figure 1 It is a flow chart of the method for setting the sensitivity of flame detector based on BP neural network;
[0044] Figure 2 GUI interface for real-time data observation and storage on the host computer;
[0045] Figure 3 Calculate timing diagrams for algorithm models;
[0046] Figure 4 To tailor the logic diagram;
[0047] Figure 5 It is the logic diagram of whether to alarm in the algorithm;
[0048] Figure 6 It is a schematic diagram of the continuous alarm strategy;
[0049] Figure 7 Schematic diagram of a flame detector. DETAILED DESCRIPTION
[0050] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described in conjunction with the specific embodiments of the present invention and the corresponding drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention. The technical solutions provided by the embodiments of the present invention are described in detail below in conjunction with the drawings.
[0051] To overcome the shortcomings of the prior art, the present invention uses smoke videos captured in the visual domain by low-cost cameras and improves smoke detection by implementing a powerful classifier. The smoke regions are classified using a deep belief network (DBN) to obtain the probability of smoke and no smoke in the studied frame. The DBN uses a combination of three selected features: smoke color, motion, and image energy.
[0052] See also Figure 1 The present invention provides a flame detector sensitivity setting method based on BP neural network, comprising:
[0053] Step S101, sample recording, wherein the types of samples include flames and interference sources, and each sample is recorded in combination at different distances and angles from the flame detector.
[0054] Specifically, the upper computer can be used to write the GUI, the lower computer can be used to write the corresponding driver, and finally the upper computer commands can be used to start and end sample recording. The data is transmitted from the lower computer to the upper computer through Modbus and saved in txt or bin files on the upper computer. The GUI interface for real-time data observation and storage on the upper computer is as follows: Figure 2 The specific types of samples are shown in Table 1.
[0055] Table 1 Sample types
[0056]
[0057] Note: Each sample needs to be recorded at different distances and angles from the flame detector to make the sample set as complete as possible, which is conducive to improving the flame alarm accuracy of the model and the ability to resist false alarms from interference sources. The farthest distance of the flame sample at different angles is when the flame characteristics of the fire signal cannot be seen on the GUI.
[0058] Step S102, cropping the recorded samples to obtain a sample set of fixed duration.
[0059] like Figure 2 The samples recorded in this way are continuous, ranging from tens of seconds to tens of minutes. The input of the algorithm model is often data of fixed length, such as Figure 3 The algorithm model calculation timing diagram is shown in Figure 1 (assuming that the algorithm model input time window is 2 seconds long and is called once per second). Therefore, it is necessary to trim the long samples into a sample set before using it for feature extraction and training of the algorithm model.
[0060] In order to make full use of continuous samples, the following logic is used for sample clipping. The sampling frequency is Fs = 128 Hz, and one of the samples to be clipped is the matrix X 4×1280 , indicating 4-channel data, the duration is seconds. Then the trimming logic is as follows Figure 4 (This paper uses the m language to implement it.) Among them, cut_times can adjust the utilization rate of continuous samples, and count_num is the number of small fixed samples of size 4×256 that are finally cut from the long sample.
[0061] Step S103, performing infrared feature extraction and ultraviolet feature extraction on the sample set, and merging the extracted infrared features and ultraviolet features to obtain a feature sample set.
[0062] Specifically, infrared feature extraction includes:
[0063] The matrix of the cropped sample set is Y 4×256×N , N is the length of the pruned sample set, for one of the samples y 4×256 Perform feature extraction, the first 3 channels are y IR,3×256 , the last channel is y UV,1×256 ; Infrared feature extraction uses Fourier transform, infrared 1 channel y IR1,1×256 The Fourier transform (FFT) process is as follows (other channels are similar):
[0064]
[0065] f(k) is the frequency domain value of Fourier transform, i is the accumulated index, j is the complex sign, and k is the frequency domain sequence;
[0066] The minimum frequency domain resolution is |f(0)| corresponds to the DC component, |f(1)| corresponds to the 0.5 Hz amplitude in the frequency domain, and so on. If the DC component and symmetric data are removed, the number of frequency domain amplitude features is 128, recorded as {|f(1)|, |f(2)|, ..., |f(128)|}.
[0067] Specifically, UV feature extraction includes:
[0068] Each discrete UV signal represents the The number of internal UV pulses, the number of pulses extracted from the UV channel f_UV1, the density f_UV2, and the maximum value f_UV3 are as follows:
[0069]
[0070]
[0071]
[0072] Among them, β = 256, ensuring the ultraviolet feature f_UV∈[0, 1], achieving the normalization effect, and count_nonzero is the number of non-zero values in the 256 ultraviolet pulse counting signals.
[0073] Specifically, the extracted infrared features and ultraviolet features are combined including:
[0074] The infrared features are taken from 0 to 20 Hz in the frequency domain. The infrared features of the three channels are:
[0075] {|f(1)| / α, |f(2)| / α, ..., |f(40)| / α}, α = 10, is the normalization coefficient, 3 channels total 40*3 = 120 infrared features, after normalization, the infrared 3 channel features are {f_IR1, f_IR2, ..., f_IR 120}, 1~40 are the first channel features, 41~80 are the second channel features, 81~120 are the third channel features, plus the ultraviolet 3 features {f_UV1, f_UV2, f_UV3}, a total of 123 features constitute the feature sample set:
[0076] N represents the length of the feature sample set, which is equal to the number of cropped samples.
[0077] Step S104: using the feature sample set as a first training set to train a first BP neural network model.
[0078] Specifically, the first BP neural network model (BP1) adopts F N×123 As a training set, the number of input nodes of the first BP neural network model is 123, and the number of output nodes of the first BP neural network model is 2, including fire and non-fire.
[0079] Step S105, using only the infrared flame channel features and the ultraviolet features to trim the feature sample set, and using the trimmed feature sample set as a second training set to train a second BP neural network model.
[0080] Specifically, the second BP neural network model (BP2) is used to classify the size of the flame signal and determine whether it meets the set sensitivity requirements. The size of the flame signal is mainly reflected in the infrared flame channel (4.4um or 2.95um) and the ultraviolet channel. N×123 The sample set is cropped out:
[0081] As the second training set, the number of input nodes of the second BP neural network model is 43, and the number of output nodes of the second BP neural network model is 3; the second BP neural network model sets 3 sensitivity levels: 1 is low, 2 is medium, and 3 is high; among them, for the samples under 0 degree angle in the second training set, the samples of 0-25 meters are marked as 1, the samples of 26-40 meters are marked as 2, and the samples of 41-meter are marked as 3. The logic of whether to alarm in the algorithm is as follows Figure 5 .
[0082] The sample recorded when the flame is facing the detector is because the samples recorded with other angles cannot be reasonably trained with the second BP neural network model due to the nonlinear attenuation of the signal under the angle. The second BP neural network model realizes the detection distance under different sensitivities in the following way: let the sensitivity of the detector be δ, and the classification result of the second BP neural network model be σ, then when the condition σ≤δ, σ, δ∈{1, 2, 3} is met, the flame detector alarms.
[0083] Step S106, constructing a flame detector based on the first BP neural network model and the second BP neural network model, the flame detector is configured to: perform feature extraction on the detection data collected by the ultraviolet sensor and the infrared sensor; input the result of the feature extraction into the first BP neural network model to identify whether the detection target is a flame; if the detection target is a flame, input the result of the feature extraction into the second BP neural network model to classify the size of the flame signal; if the size of the flame signal meets the set sensitivity requirement, the second BP neural network model outputs a fire warning, and the flame detector issues a flame alarm.
[0084] In order to reduce false alarms caused by sunlight and artificial interference sources, a continuous alarm strategy is added on the basis of setting the sensitivity (the lower the sensitivity setting, the greater the flame signal energy required for the alarm, and the stronger the detector's anti-false alarm performance against interference sources). That is, the model considers it a fire only after multiple consecutive fire alarms, which can further improve the anti-false alarm performance. Here, a threshold of the number of consecutive alarms needs to be set, such as Figure 6 ,Since the model is called once per second, assuming that the fire starts at 0 seconds, when the threshold is 3, the flame detector starts to alarm at around the 4th second, that is, the theoretical minimum alarm delay of the flame detector within the effective range is about 4 seconds.
[0085] Furthermore, the number of hidden layer nodes hide_len of the first BP neural network model and the second BP neural network model is determined according to the following formula, and the simulation optimization is performed to select the r value corresponding to the highest cross-validation accuracy:
[0086] γ∈{0, 1, 2, ..., 10}; where in_len is the number of nodes in the model input layer, out_len is the number of nodes in the model output layer, and γ is 0-10, which is an adjustable parameter;
[0087] The hidden layer activation functions are all sigmoid functions, as shown in the following formula:
[0088]
[0089] f(hi) represents the hidden layer activation function, h i is the output of the i-th node in the hidden layer;
[0090] The output layer activation function is the softmax function, as shown in the following formula:
[0091]
[0092] Among them, h i is the output of the i-th node in the hidden layer, o i is the output of the i-th node in the output layer.
[0093] Furthermore, the flame detection alarm model is configured as follows: if the size of the flame signal meets the set sensitivity requirement, the flame detection alarm model outputs a fire warning; determines whether the number of fire warnings output by the flame detection alarm model exceeds a consecutive fire warning number threshold; if the number of fire warnings output by the flame detection alarm model exceeds a consecutive fire warning number threshold, a flame alarm is issued.
[0094] In the present invention, the number of neurons in the hidden layer of the first BP neural network model is determined to be The number of hidden layer neurons in the second BP neural network model is determined after optimization: The total duration of flame samples in the test sample set is about 300 minutes, and the duration of interference source samples is about 600 minutes. The sample set is a uniform combination of different distances and angles within the performance indicators of the flame detector. The entire test sample set is recorded in different batches, and the entire sample set does not participate in model training. It has been verified that the simulation test results are consistent with the actual instrument test results.
[0095] The flame detector is set to the highest sensitivity (i.e. the output condition of the second BP neural network model is always established). At this time, the test accuracy is shown in Table 2. When the continuous number threshold reaches 3 times, the flame alarm rate decreases to about 97.2%, the interference source false alarm rate is 0, and the total prediction accuracy is about 98.6%. Further analysis found that the flame samples that did not alarm were all recorded when the fuel was about to run out and the flame was weak. The weak flame signal caused the classification accuracy to decrease. From the test results, the accuracy of the algorithm model meets the performance requirements of our company's flame meter.
[0096] Table 2 Test results
[0097]
[0098] In order to test the detection distance of the flame detector under different sensitivity settings, the continuous threshold is set to 1, and the test results are shown in Table 3. Since the critical distance is affected by the fuel combustion state and wind speed, it is impossible to achieve completely accurate classification. The test results in Table 3 can reflect that the detection distance of the low-sensitivity flame meter is about 0-25m, the detection distance of the medium-sensitivity flame meter is about 0-40m, and the detection distance of the high-sensitivity flame meter is about 0-55m. The detector in this article can still alarm at a distance of 65m under the highest sensitivity, which exceeds the maximum effective detection distance of 55m in the product manual.
[0099] Table 3 Test accuracy at different distances
[0100] Sensitivity 10m 15m 20m 25m 30m 35m 40m 45m 50m 55m Low 99.63% 99.54% 98.46% 96.48% 26.68% 2.46% 0.0% 0.0% 0.0% 0.0% middle 99.72% 99.63% 99.58% 98.55% 97.91% 96.73% 95.79% 23.37% 1.69% 0.0% high 99.86% 99.72% 99.78% 99.71% 99.65% 99.49% 98.79% 98.13% 97.67% 96.88%
[0101] like Figure 7 As shown, a flame detector based on BP neural network is set by the flame detector sensitivity setting method based on BP neural network described in the present invention, including: ultraviolet sensor 100, infrared sensor 200 and micro control unit 300. An amplifier circuit 400 is also connected between the ultraviolet sensor 100 and the micro control unit 300. The micro control unit 300 also has an analog-to-digital conversion chip ADS1115, and the micro control unit 300 can use STM32F429. The ultraviolet sensor and the infrared sensor are used to collect detection data. The micro control unit is used to receive the detection data; perform feature extraction on the detection data; input the result of the feature extraction into the first BP neural network model to identify whether the detection target is a flame; if the detection target is a flame, input the result of the feature extraction into the second BP neural network model to classify the size of the flame signal; if the size of the flame signal meets the set sensitivity requirement, the second BP neural network model outputs a fire warning, and the flame detector issues a flame alarm.
[0102] The embodiment of the present invention further provides a storage medium, and the embodiment of the present invention further provides a storage medium, wherein a computer program is stored in the storage medium, and when the computer program is executed by a processor, some or all of the steps in each embodiment of the method for setting the sensitivity of a flame detector based on a BP neural network provided by the present invention are implemented. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM).
[0103] Those skilled in the art can clearly understand that the technology in the embodiments of the present invention can be implemented by means of software plus a necessary general hardware platform. Based on this understanding, the technical solution in the embodiments of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which can be stored in a storage medium such as ROM / RAM, a disk, an optical disk, etc., and includes a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present invention or some parts of the embodiments.
[0104] The above-described embodiments of the present invention do not limit the protection scope of the present invention.
Claims
1. A flame detector sensitivity setting method based on BP neural network, characterized in that: include: Sample recording, wherein the types of samples include flames and interference sources, and each sample is recorded in combination at different distances and angles from the flame detector; The recorded samples are cropped to obtain a sample set of fixed length; the sampling frequency is Fs = 128 Hz, and one of the samples to be cropped is the matrix X 4×1280 , indicating 4-channel data, the duration is Infrared feature extraction and ultraviolet feature extraction are performed on the sample set, and the extracted infrared features and ultraviolet features are merged to obtain a feature sample set; infrared feature extraction includes: the matrix of the cropped sample set is Y 4×256×N , N is the length of the pruned sample set, for one of the samples y 4×256 Perform feature extraction, the first 3 channels are y IR,3×256 , the last channel is y UV,1×256 ; Infrared feature extraction uses Fourier transform to obtain the Fourier transform frequency domain value f(k), where k is a frequency domain sequence; after removing the DC component and symmetrical data, the number of frequency domain amplitude features is 128, recorded as {|f(1)|, |f(2)|, ..., |f(128)|}; Ultraviolet feature extraction includes: ultraviolet channel extraction of pulse number f_UV1, density f_UV2, and maximum value f_UV3; The extracted infrared features and ultraviolet features are merged, including: infrared features take 0 to 20 Hz in the frequency domain as infrared features, and the infrared features of the three channels are: {|f(1)| / α, |f(2)| / α, ..., |f(40)| / α}, α = 10, is the normalization coefficient, 3 channels have a total of 40*3 = 120 infrared features, after normalization, the infrared 3-channel features are {f_IR1, f_IR2, ..., f_IR 120 }, 1-40 are the first channel features, 41-80 are the second channel features, 81-120 are the third channel features, plus the ultraviolet 3 features {f_UV1, f_UV2, f_UV3}, a total of 123 features constitute the feature sample set; Using the feature sample set as a first training set, training a first BP neural network model; Only the third channel feature and the ultraviolet feature of the infrared feature are used to trim the feature sample set, and the trimmed feature sample set is used as the second training set to train the second BP neural network model; A flame detector is constructed based on the first BP neural network model and the second BP neural network model, and the flame detector is configured to: perform feature extraction on the detection data collected by the ultraviolet sensor and the infrared sensor; input the result of the feature extraction into the first BP neural network model to identify whether the detection target is a flame; if the detection target is a flame, input the result of the feature extraction into the second BP neural network model to classify the size of the flame signal; if the size of the flame signal meets the set sensitivity requirement, the second BP neural network model outputs a fire warning, and the flame detector sends out a flame alarm.
2. The method according to claim 1, characterized in that Sample recording, where the types of samples include flames and interference sources. Each sample is recorded in combination at different distances and angles from the flame detector. The upper computer writes the GUI, the lower computer writes the corresponding driver, and finally the sample recording is started and ended through the upper computer instructions. The data is transmitted from the lower computer to the upper computer via Modbus and saved as a txt or bin file on the upper computer.
3. The method according to claim 1, characterized in that In the step of extracting infrared features and ultraviolet features from the sample set and merging the extracted infrared features and ultraviolet features to obtain a feature sample set, the infrared feature extraction includes: infrared 1 channel y IR1,1×256 The Fourier transform process is as follows: f(k) is the frequency domain value of Fourier transform, i is the accumulated index, j is the complex sign, and k is the frequency domain sequence; The minimum frequency domain resolution is |f(0)| corresponds to the DC component, |f(1)| corresponds to the 0.5Hz amplitude in the frequency domain, and so on.
4. The method according to claim 3, characterized in that In the step of performing infrared feature extraction and ultraviolet feature extraction on the sample set, and merging the extracted infrared features and ultraviolet features to obtain a feature sample set, the ultraviolet feature extraction includes: Each discrete UV signal represents the The number of internal UV pulses, the number of pulses extracted by the UV channel f_UV1, the density f_UV2, and the maximum value f_UV3 are as follows: Wherein, β=256, count_nonzero is the number of non-zero values in the 256 ultraviolet pulse counting signals.
5. The method according to claim 4, characterized in that In the step of extracting infrared features and ultraviolet features from the sample set and merging the extracted infrared features and ultraviolet features to obtain a feature sample set, merging the extracted infrared features and ultraviolet features includes: 123 features make up the feature sample set: N represents the length of the feature sample set, which is equal to the number of pruned samples.
6. The method according to claim 5, characterized in that In the step of training the first BP neural network model using the feature sample set as the first training set, the first BP neural network model adopts F N×123 As a training set, the number of input nodes of the first BP neural network model is 123, and the number of output nodes of the first BP neural network model is 2, including fire and non-fire.
7. The method according to claim 6, characterized in that Only infrared flame channel features and ultraviolet features are used to trim the feature sample set, and the trimmed feature sample set is used as the second training set. In the step of training the second BP neural network model, F N×123 The sample set is cropped out: As the second training set, the number of input nodes of the second BP neural network model is 43, and the number of output nodes of the second BP neural network model is 3; the second BP neural network model sets 3 sensitivity levels: 1 for low, 2 for medium, and 3 for high; among them, for the samples at an angle of 0 degrees in the second training set, the samples of 0-25 meters are marked as 1, the samples of 26-40 meters are marked as 2, and the samples of 41-40 meters are marked as 3.
8. The method according to claim 7, characterized in that The number of hidden layer nodes hide_len of the first BP neural network model and the second BP neural network model is determined according to the following formula, and the simulation optimization is performed to select the r value corresponding to the highest cross-validation accuracy: Among them, in_len is the number of nodes in the model input layer, out_len is the number of nodes in the model output layer, and γ is 0-10, which is an adjustable parameter; The hidden layer activation functions are all sigmoid functions, as shown in the following formula: f(hi) represents the hidden layer activation function, h i is the output of the i-th node in the hidden layer; The output layer activation function is the softmax function, as shown in the following formula: Among them, σ(o i ) represents the output layer activation function, o i is the output of the i-th node in the output layer.
9. The method according to claim 8, characterized in that The flame detection alarm model is configured as follows: if the size of the flame signal meets the set sensitivity requirement, the flame detection alarm model outputs a fire warning; determines whether the number of fire warnings output by the flame detection alarm model exceeds the consecutive fire warning threshold; if the number of fire warnings output by the flame detection alarm model exceeds the consecutive fire warning threshold, a flame alarm is issued.
Citation Information
Patent Citations
Infrared ultraviolet flame detector control system and control method thereof
CN107170173A
Flame detection method, flame detection model training method, storage medium and system
CN110334685A