Gas leakage detection method and device, electronic equipment and storage medium

By combining infrared imaging and gas concentration detectors to analyze gas leaks in oil pipelines, the team solved the problem of insufficient detection methods in existing technologies and achieved accurate gas leakage rate calculation in most scenarios.

CN118654815BActive Publication Date: 2025-10-10GUANGZHOU KEII ELECTRO OPTICS TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410795157.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-19
Publication Date
2025-10-10
Estimated Expiration
2044-06-19

AI Technical Summary

Technical Problem

In the existing technology, there are few methods for detecting gas leaks in oil pipelines and the operating conditions are strict, so they cannot be effectively applied in most scenarios.

Method used

The infrared imager is used to collect infrared images, analyze the leaking gas image area, determine the gas concentration information and optical flow field, and calculate the gas leakage rate by combining the gas concentration detector data.

Benefits of technology

The applicability and comprehensiveness of gas leak detection have been improved, and the gas leakage rate can be accurately determined in most scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118654815B_ABST
    Figure CN118654815B_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose a gas leakage detection method and device, electronic equipment and storage medium, comprising: acquiring a first infrared image and a second infrared image collected by an infrared imager; analyzing the first infrared image to determine a leakage gas image area in the first infrared image and gas concentration information corresponding to the leakage gas image area; determining a light flow field corresponding to the leakage gas image area according to the first infrared image and the second infrared image; and determining a gas leakage speed corresponding to the leakage gas image area according to the light flow field corresponding to the leakage gas image area and the gas concentration information. The embodiments of the present application can improve the applicability and comprehensiveness of gas leakage detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of gas detection technology, and in particular to a gas leakage detection method, device, electronic equipment and storage medium. Background Art

[0002] An oilfield refers to a specific area where crude oil is produced. Oilfields typically produce oilfield gas, which is typically transported to its destination, such as a liquefied petroleum gas storage and distribution station, via a pipeline system. An oil pipeline system, primarily composed of pipelines, transfer stations, and other ancillary equipment, is a key component of the crude oil storage and transportation industry and the primary means of transporting crude oil and crude oil products. Compared to other land-based transportation methods, such as rail and road transportation, pipeline transportation offers advantages such as high capacity, enhanced containment, lower costs, and a higher level of safety.

[0003] However, gas leaks in oil pipelines can cause environmental pollution and safety risks. To ensure their safe operation, regular inspections are necessary. Currently, gas leak detection typically relies on specialized gas measuring instruments to determine the current leaked gas volume and concentration. However, existing methods for determining gas leakage velocity are limited, and these methods are often difficult to use under stringent conditions, making them unusable in most scenarios. Summary of the Invention

[0004] The embodiments of the present application disclose a gas leakage detection method, device, electronic device, and storage medium, which can improve the applicability and comprehensiveness of gas leakage detection.

[0005] The present application discloses a gas leakage detection method, comprising:

[0006] Acquire a first infrared image and a second infrared image captured by an infrared imager;

[0007] Analyze the first infrared image to determine a leaking gas image region in the first infrared image and gas concentration information corresponding to the leaking gas image region, where the gas concentration information is used to represent an integral of the gas concentration in the leaking gas image region in an image acquisition direction;

[0008] determining an optical flow field corresponding to the leaking gas image area according to the first infrared image and the second infrared image;

[0009] The gas leakage velocity corresponding to the leaking gas image area is determined according to the optical flow field and gas concentration information corresponding to the leaking gas image area.

[0010] In one embodiment, before determining the gas leakage velocity corresponding to the leaking gas image area based on the optical flow field and gas concentration information corresponding to the leaking gas image area, the method further includes:

[0011] Acquiring gas concentration data collected by at least one gas concentration detector;

[0012] Correcting the gas concentration information corresponding to the leaked gas image area according to the gas concentration data respectively collected by the at least one gas concentration detector to obtain corrected gas concentration information corresponding to the leaked gas image area;

[0013] The determining of the gas leakage velocity corresponding to the leaking gas image area according to the optical flow field and gas concentration information corresponding to the leaking gas image area includes:

[0014] The gas leakage velocity corresponding to the leaking gas image region is determined according to the optical flow field corresponding to the leaking gas image region and the corrected gas concentration information.

[0015] In one embodiment, the gas concentration information corresponding to the leaked gas image area is corrected based on the gas concentration data respectively collected by the at least one gas concentration detector to obtain the corrected gas concentration information corresponding to the leaked gas image area, including:

[0016] According to the gas concentration data respectively collected by the at least one gas concentration detector, the weight corresponding to each of the gas concentration detectors, and the weight of the gas concentration information corresponding to the gas concentration information, a weighted sum calculation is performed on the gas concentration data respectively collected by the at least one gas concentration detector and the gas concentration information to obtain the corrected gas concentration information corresponding to the leakage gas image area.

[0017] In one embodiment, before determining the gas leakage velocity corresponding to the leaking gas image area based on the optical flow field and gas concentration information corresponding to the leaking gas image area, the method further includes:

[0018] Acquiring environmental data, the environmental data including one or more of an ambient temperature collected by a temperature sensor, an ambient humidity collected by a humidity sensor, and a target distance corresponding to the infrared imager, where the target distance is the distance between the infrared imager and the area to be detected;

[0019] If the environmental data satisfies a preset condition, the optical flow field corresponding to the leaking gas image area is compensated according to the compensation parameter to obtain a compensated optical flow field corresponding to the leaking gas image area; wherein the preset condition includes one or more of the following: the ambient temperature is less than a temperature threshold, the ambient humidity is greater than a humidity threshold, and the target distance is greater than a distance threshold;

[0020] The determining of the gas leakage velocity corresponding to the leaking gas image area according to the optical flow field and gas concentration information corresponding to the leaking gas image area includes:

[0021] The gas leakage velocity corresponding to the leaking gas image area is determined according to the compensated optical flow field and gas concentration information corresponding to the leaking gas image area.

[0022] In one embodiment, the first infrared image and the second infrared image are two adjacent frames of infrared images captured by an infrared imager;

[0023] Before determining the gas leakage velocity corresponding to the leaked gas image area based on the optical flow field and gas concentration information corresponding to the leaked gas image area, the method further includes:

[0024] Obtaining camera parameters, target distance, and acquisition frequency corresponding to the infrared imager;

[0025] Determining a spatial area corresponding to each pixel in the first infrared image according to the camera parameters and the target distance;

[0026] The determining of the gas leakage velocity corresponding to the leaking gas image area according to the optical flow field and gas concentration information corresponding to the leaking gas image area includes:

[0027] Calculating a moving speed of the optical flow corresponding to each pixel in the leaking gas image area in three-dimensional space according to the acquisition frequency, the spatial area, and the optical flow field;

[0028] determining a gas leakage speed corresponding to each pixel in the leaking gas image area according to gas concentration information corresponding to the leaking gas image area and a movement speed corresponding to each pixel in the leaking gas image area;

[0029] The gas leakage speed corresponding to the leaking gas image area is determined according to the gas leakage speed corresponding to each pixel in the leaking gas image area.

[0030] In one embodiment, determining the gas leakage rate corresponding to the leaking gas image area according to the gas leakage rate corresponding to each pixel in the leaking gas image area includes:

[0031] In the leaking gas image area, determining a plurality of target pixels corresponding to a target cross section perpendicular to a gas leakage direction;

[0032] The gas leakage rates corresponding to the plurality of target pixels are accumulated to obtain the gas leakage rate corresponding to the leaking gas image area.

[0033] In one embodiment, analyzing the first infrared image to determine a leaking gas image area in the first infrared image and a gas concentration corresponding to the leaking gas image area includes:

[0034] Analyzing the first infrared image to determine a leaking gas image area and a background image area in the first infrared image;

[0035] Determining a gas temperature corresponding to the leaking gas image area and a background temperature corresponding to the background image area;

[0036] Calculating a temperature difference and a radiation intensity difference corresponding to the gas temperature and the background temperature according to the gas temperature and the background temperature;

[0037] determining a transmittance of the leaked gas image area according to the temperature difference and the radiation intensity difference;

[0038] Gas concentration information corresponding to the leaked gas image area is determined according to the transmittance of the leaked gas image area.

[0039] The present application discloses a gas leakage detection device, comprising:

[0040] A data acquisition module, configured to acquire a first infrared image and a second infrared image captured by an infrared imager;

[0041] a region analysis module, configured to analyze the first infrared image to determine a gas leakage image region in the first infrared image and gas concentration information corresponding to the gas leakage image region, wherein the gas concentration information is used to represent an integral of the gas concentration in the gas leakage image region in an image acquisition direction;

[0042] an optical flow determination module, configured to determine an optical flow field corresponding to the leaking gas image area based on the first infrared image and the second infrared image;

[0043] The speed determination module is used to determine the gas leakage speed corresponding to the leaking gas image area according to the optical flow field and gas concentration information corresponding to the leaking gas image area.

[0044] The present application discloses an electronic device, including:

[0045] a memory storing executable program code;

[0046] a processor coupled to the memory;

[0047] The processor calls the executable program code stored in the memory to execute the method described in any one of the above embodiments.

[0048] An embodiment of the present application discloses a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the processor executes the method described in any one of the above embodiments.

[0049] Through the gas leak detection method, device, electronic device, and storage medium disclosed in the embodiments of the present application, the electronic device can obtain a first infrared image and a second infrared image captured by an infrared imager, analyze the first infrared image, determine the leaking gas image region in the first infrared image, and the gas concentration information corresponding to the leaking gas image region. The gas concentration information can represent the integral of the gas concentration in the leaking gas image region along the image acquisition direction. The electronic device can also determine the optical flow field corresponding to the leaking gas image region based on the first infrared image and the second infrared image, and then determine the gas leakage rate corresponding to the leaking gas image region based on the optical flow field and the gas concentration information corresponding to the leaking gas image region. Through this embodiment, the electronic device can analyze the infrared image to analyze gas concentration information, gas leakage rate, and other information, thereby improving the comprehensiveness of gas leak detection. The gas leakage rate can be determined by analyzing the infrared image, allowing gas leakage rate detection in most scenarios, thereby improving the applicability of gas leak detection. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0051] Figure 1 This is a schematic diagram of an application scenario of a gas leakage detection method disclosed in an embodiment of the present application;

[0052] Figure 2 This is a flow chart of a gas leak detection method disclosed in an embodiment of the present application;

[0053] Figure 3 This is a flow chart of another gas leak detection method disclosed in an embodiment of the present application;

[0054] Figure 4 This is a flow chart of another gas leak detection method disclosed in an embodiment of the present application;

[0055] Figure 5 This is a flowchart of a method for an electronic device to determine a gas leakage velocity corresponding to a gas leakage image area disclosed in an embodiment of the present application;

[0056] Figure 6 This is a modular schematic diagram of a gas leakage detection device disclosed in an embodiment of the present application;

[0057] Figure 7 This is a structural block diagram of an electronic device disclosed in an embodiment of the present application. DETAILED DESCRIPTION

[0058] The following will be combined with the accompanying drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0059] It should be noted that the terms "including" and "having" in the embodiments of the present application and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or are inherent to these processes, methods, products or devices.

[0060] It will be understood that the terms "first," "second," and so forth, as used herein, may be used to describe various elements herein, but these elements are not limited by these terms. These terms are used solely to distinguish a first element from another element. For example, a first infrared image may be referred to as a second infrared image, and similarly, a second infrared image may be referred to as a first infrared image, without departing from the scope of this application. The first infrared image and the second infrared image are both infrared images, but they are not the same infrared image.

[0061] The embodiments of the present application disclose a gas leakage detection method, device, electronic device, and storage medium, which can improve the applicability and comprehensiveness of gas leakage detection.

[0062] The following is a detailed description with reference to the accompanying drawings.

[0063] like Figure 1 As shown, Figure 1This is a schematic diagram of an application scenario of a gas leakage detection method disclosed in an embodiment of the present application. The application scenario may include a gas leakage detection device 110 and leaked gas 120. The gas leakage detection device 110 may include an infrared imager, which can be used to collect the leaked gas 120 to obtain an infrared image containing the leaked gas 120. The infrared image may include a leaked gas image area and a background image area. The leaked gas image area refers to the area occupied by the leaked gas 120 in the infrared image, and the background image area refers to the area in the infrared image other than the leaked gas image area.

[0064] Optionally, the gas leak detection device 110 may also include a gas concentration detector, an environmental data sensor, and the like, without limitation. The environmental data sensor may include a temperature sensor, a humidity sensor, and the like. It is understood that the gas concentration detector and the environmental data sensor may also be separate devices, each measuring data for transmission to the electronic device. Optionally, the leaked gas may include, but is not limited to, carbon dioxide, fluoride, carbon monoxide, methane, and other gases, or other gases not mentioned, and this is not limited in the present embodiment.

[0065] It is understood that the gas leak detection device 110 can process the captured infrared image independently, or it can send the infrared image to an electronic device that is communicatively connected to the gas leak detection device 110 for processing. For ease of explanation, this application uses an electronic device as the execution entity of the gas leak detection method. The electronic device can be the gas leak detection device 110 or other devices, without limitation.

[0066] In one embodiment, the electronic device can obtain a first infrared image and a second infrared image captured by an infrared imager, and analyze the first infrared image to determine the leakage gas image area in the first infrared image and the gas concentration information corresponding to the leakage gas image area. The electronic device can also determine the optical flow field corresponding to the leakage gas image area based on the first infrared image and the second infrared image, and then determine the gas leakage rate corresponding to the leakage gas image area based on the optical flow field and gas concentration information corresponding to the leakage gas image area.

[0067] like Figure 2 As shown, Figure 2 : is a flow chart of a gas leakage detection method disclosed in an embodiment of the present application. The gas leakage detection method can be applied to the electronic device in the above embodiment. The gas leakage detection method may include the following steps:

[0068] Step 210: Acquire a first infrared image and a second infrared image captured by an infrared imager.

[0069] The infrared imager can capture multiple frames of infrared images at a preset capture frame rate and send the captured multiple frames of infrared images to an electronic device. Optionally, the electronic device can determine two adjacent frames of images from the multiple frames of infrared images as the first infrared image and the second infrared image. Optionally, the electronic device can also determine the two most recently captured frames of images from the multiple frames of infrared images as the first infrared image and the second infrared image. Optionally, the electronic device can also randomly determine two frames of images from the multiple frames of infrared images as the first infrared image and the second infrared image. The embodiments of the present application are not limited to this.

[0070] Optionally, the electronic device may preprocess the first and second infrared images to improve image quality. Preprocessing may include, but is not limited to, noise removal, image enhancement, and image smoothing. Noise removal methods may include median filtering, mean filtering, or Gaussian filtering to remove random noise from the image. Image enhancement methods may include histogram equalization or adaptive histogram equalization. Image enhancement adjusts contrast and brightness to enhance the distinction between the leaking gas image area and the background image area.

[0071] Step 220 : Analyze the first infrared image to determine the leaking gas image area in the first infrared image and the gas concentration information corresponding to the leaking gas image area.

[0072] It's important to understand that infrared imagers capture images using infrared imaging technology, which utilizes infrared radiation. Infrared radiation refers to electromagnetic waves with wavelengths exceeding those of visible light, ranging from 0.75 to 1000 microns. Infrared imagers detect infrared radiation emitted by objects, convert it into electronic signals, and then process these signals to form infrared images. Due to the varying surface temperatures and radiation characteristics of different objects, infrared images appear with varying brightness and color.

[0073] Therefore, the brightness and color corresponding to the leaked gas image region included in the first infrared image are different from the brightness and color corresponding to the background region included in the first infrared image. The electronic device can determine the leaked gas image region in the first infrared image by analyzing the brightness and color features in the first infrared image. Optionally, the electronic device can determine pixels whose brightness exceeds a height threshold and whose color falls within a color range as pixels in the leaked gas image region, thereby obtaining the leaked gas image region in the first infrared image. Optionally, the electronic device can also perform edge detection on the first infrared image to determine the boundaries of the leaked gas image region, thereby determining the leaked gas image region. This edge detection algorithm can include Sobel, Canny, etc. Optionally, the electronic device can also use a machine learning or deep learning algorithm to train a classifier to identify the leaked gas image region in the first infrared image, such as a support vector machine, random forest, or convolutional neural network. The embodiments of the present application do not limit the method for identifying the leaked gas image region.

[0074] As can be seen from the above, the leaked gas image area can characterize the radiation intensity of the infrared radiation corresponding to the leaked gas. The electronic device can determine the gas concentration information corresponding to the leaked gas image area based on the radiation intensity corresponding to the leaked gas image area and the absorption coefficient of the leaked gas to the infrared radiation. The gas concentration information can be used to characterize the integral of the gas concentration in the leaked gas image area in the image acquisition direction. It can be understood that the gas length of the leaked gas in the image acquisition direction is the gas thickness. The gas concentration information refers to the integral of the gas concentration in the leaked gas image area over the gas thickness, that is, the integral of the gas concentration of each pixel in the leaked gas image area in the direction of the gas thickness of each pixel. Specifically, according to the Beer-Lambert law, the absorption process of infrared radiation when passing through the leaked gas can be expressed as formula (1),

[0075] I=I0e -kCL Formula (1);

[0076] Where I is the radiation intensity of infrared radiation after passing through the leaked gas, I0 is the radiation intensity of the initial infrared radiation, k is the absorption coefficient of the leaked gas to infrared radiation, C is the gas concentration of the leaked gas, that is, the gas concentration corresponding to the leaked gas image area, L is the gas thickness of the leaked gas, that is, the gas thickness corresponding to the leaked gas image area, and CL can represent the integral of the gas concentration of the leaked gas image area and the gas thickness, that is, the gas concentration information corresponding to the leaked gas image area. Transforming formula (1) can obtain formula (2),

[0077]

[0078] Where T is the transmittance of the leaked gas image area, and T is the ratio of the intensity of the infrared radiation after passing through the leaked gas to the intensity of the initial infrared radiation. Therefore, as shown in equation (2), the electronic device can first determine the transmittance of the leaked gas image area based on the first infrared image, and then calculate the gas concentration information corresponding to the leaked gas image area.

[0079] In one embodiment, the electronic device can analyze the first infrared image, determine the leakage gas image area and the background image area in the first infrared image, and determine the gas temperature corresponding to the leakage gas image area and the background temperature corresponding to the background image area. Then, based on the gas temperature and the background temperature, calculate the temperature difference and radiation intensity difference corresponding to the gas temperature and the background temperature. Based on the temperature difference and the radiation intensity difference, determine the transmittance of the leakage gas image area, and thus determine the gas concentration information corresponding to the leakage gas image area based on the transmittance of the leakage gas image area.

[0080] The gas temperature corresponding to the leaked gas image area can refer to the average temperature corresponding to the leaked gas image area, or can refer to the gas temperature corresponding to each pixel in the leaked gas image area, without limitation. It should be understood that although the background image area is the area surrounding the leaked gas image area, generally speaking, the temperatures at adjacent locations in space are similar or identical. Therefore, the background temperature corresponding to the background image area can be used as the temperature behind the leaked gas in the image acquisition direction. Based on the gas temperature and the background temperature, the radiation intensity difference corresponding to the gas temperature and the background temperature can be determined. This radiation intensity difference can refer to the difference between the radiation intensity of the infrared radiation after passing through the leaked gas and the radiation intensity of the initial infrared radiation.

[0081] Optionally, based on Wien's law, the electronic device can calculate the wavelength of the maximum radiation corresponding to the background temperature and the gas temperature, respectively. Then, based on Planck's blackbody radiation law, the electronic device can calculate the emissivity corresponding to the wavelength of the maximum radiation corresponding to the background temperature and the gas temperature, respectively, to obtain the radiation intensity difference corresponding to the gas temperature and the background temperature. Implementing this embodiment can improve the accuracy of the determined gas concentration information.

[0082] As an optional embodiment, the electronic device can acquire multiple frames of first infrared images, each frame corresponding to a different wavelength band of infrared radiation. Thus, based on equations (1) and / or (2), a set of equations related to the gas concentration and gas thickness corresponding to the leaked gas image region can be established and solved to obtain the gas concentration and gas thickness corresponding to the leaked gas image region, thereby determining the gas concentration information corresponding to the leaked gas image region. Implementing this embodiment increases the diversity of methods for determining gas concentration information, and can obtain the gas concentration and gas thickness corresponding to the leaked gas image region, thereby improving the comprehensiveness of leaked gas detection.

[0083] Step 230 : determining the optical flow field corresponding to the leaking gas image area according to the first infrared image and the second infrared image.

[0084] The optical flow field refers to the motion vector field of pixel positions over time as the image progresses from the first infrared image to the second infrared image. The optical flow field corresponding to the leaking gas image region reflects the movement of the leaking gas in the first infrared image. Electronic devices can process the first and second infrared images using sparse and / or dense optical flow methods to determine the image optical flow field of the first infrared image, and then segment the image to obtain the optical flow field corresponding to the leaking gas image region.

[0085] As an example, the electronic device can use a dense optical flow algorithm to calculate the optical flow of each pixel in the first infrared image based on the first and second infrared images to obtain an optical flow field corresponding to the leaking gas image region. Dense optical flow algorithms may include the Farneback method, the Horn-Schunck method, and others. Optionally, the electronic device can first perform image registration on the first and second infrared images, and then determine the optical flow field corresponding to the leaking gas image region based on the registered first and second infrared images.

[0086] Step 240 : determining the gas leakage velocity corresponding to the leaking gas image region according to the optical flow field and gas concentration information corresponding to the leaking gas image region.

[0087] Based on the optical flow field and gas concentration information corresponding to the leaking gas image region, the electronic device can analyze the concentration changes of the gas concentration information, thereby determining the gas leakage velocity corresponding to the leaking gas image region. Optionally, the gas concentration information can represent the amount of leaked gas in each pixel within the leaking gas image region. The electronic device can combine the gas concentration information with the optical flow field to determine the velocity of the leaked gas in each pixel in three-dimensional space, thereby determining the gas leakage velocity corresponding to the leaking gas image region.

[0088] In an embodiment of the present application, an electronic device can acquire a first infrared image and a second infrared image captured by an infrared imager, analyze the first infrared image, determine a leaking gas image region in the first infrared image, and gas concentration information corresponding to the leaking gas image region. The gas concentration information can represent the integral of the gas concentration in the leaking gas image region along the image acquisition direction. The electronic device can also determine an optical flow field corresponding to the leaking gas image region based on the first infrared image and the second infrared image, and then determine a gas leakage velocity corresponding to the leaking gas image region based on the optical flow field and gas concentration information corresponding to the leaking gas image region. Through this embodiment, the electronic device can analyze information such as gas concentration information and gas leakage velocity by analyzing infrared images, thereby improving the comprehensiveness of gas leak detection. Since the gas leakage velocity can be determined by analyzing infrared images, gas leakage velocity detection can be performed in most scenarios, thereby improving the applicability of gas leak detection.

[0089] like Figure 3 As shown, Figure 3 FIG1 is a flow chart of another gas leakage detection method disclosed in an embodiment of the present application. The gas leakage detection method can be applied to the electronic device in the above embodiment. The gas leakage detection method may include the following steps:

[0090] Step 310: Acquire a first infrared image and a second infrared image captured by an infrared imager.

[0091] Step 320 : Analyze the first infrared image to determine the leaking gas image area in the first infrared image and the gas concentration information corresponding to the leaking gas image area.

[0092] Step 330 : Determine the optical flow field corresponding to the leaking gas image area based on the first infrared image and the second infrared image.

[0093] Step 340: Acquire gas concentration data collected by at least one gas concentration detector.

[0094] Optionally, the gas leak detection device may further include at least one gas concentration detector, which can be used to detect gas concentration data to determine a target location. The target location is a position within the leaking gas image region, such as a center position. The present embodiment of the application does not limit the location of the target location within the leaking gas image region. The target locations corresponding to the various gas concentration detectors may be different.

[0095] Step 350 : Correcting the gas concentration information corresponding to the leaking gas image area according to the gas concentration data respectively collected by at least one gas concentration detector to obtain corrected gas concentration information corresponding to the leaking gas image area.

[0096] Optionally, the electronic device can determine whether the difference between the gas concentration data collected by at least one gas concentration detector and the gas concentration information corresponding to the leakage gas image area is within a range. If not, the gas concentration information corresponding to the leakage gas image area can be corrected based on the gas concentration data collected by at least one gas concentration detector to obtain the corrected gas concentration information corresponding to the leakage gas image area.

[0097] Depending on the device type of the gas concentration detector, corresponding weights may be preset. The electronic device may correct the gas concentration information corresponding to the leaked gas image region based on the gas concentration data collected by at least one gas concentration detector and the weights corresponding to each gas concentration detector, thereby obtaining corrected gas concentration information corresponding to the leaked gas image region. The gas concentration information corresponding to the leaked gas image region may refer to the average value of gas concentration information corresponding to multiple pixels included in the leaked gas image region. The gas concentration information corresponding to the leaked gas image region is corrected using the gas concentration data at the target location, and the corrected gas concentration information corresponding to the leaked gas image region is the corrected average value.

[0098] In one embodiment, the electronic device can perform a weighted summation calculation on the gas concentration data collected by at least one gas concentration detector and the gas concentration information corresponding to the leaked gas image region based on the gas concentration data collected by at least one gas concentration detector, the weights corresponding to each gas concentration detector, and the weights of the gas concentration information, to obtain corrected gas concentration information corresponding to the leaked gas image region. The weights corresponding to each gas concentration detector and the weights of the gas concentration information are pre-set, and the weight of the gas concentration information can be greater than the weights corresponding to each gas concentration detector. Implementing this embodiment, the gas concentration information is corrected through the weighted summation calculation, thereby improving the accuracy of the gas concentration information.

[0099] Step 360 : determining the gas leakage velocity corresponding to the leaking gas image region according to the optical flow field corresponding to the leaking gas image region and the corrected gas concentration information.

[0100] In an embodiment of the present application, the electronic device can also obtain gas concentration data collected by at least one gas concentration detector, and correct the gas concentration information corresponding to the leakage gas image area based on the gas concentration data collected by at least one concentration detector to obtain the corrected gas concentration information corresponding to the leakage gas image area, thereby improving the accuracy of the gas concentration information and avoiding large deviations in the gas concentration information determined by the infrared image. The gas leakage rate corresponding to the leakage gas image area can be determined based on the optical flow field corresponding to the leakage gas image area and the corrected gas concentration information, thereby improving the accuracy of the determined gas leakage rate.

[0101] like Figure 4 As shown, Figure 4 FIG. 1 is a flow chart of another gas leakage detection method disclosed in an embodiment of the present application. The gas leakage detection method can be applied to the electronic device in the above embodiment. The gas leakage detection method may include the following steps:

[0102] Step 410: Acquire a first infrared image and a second infrared image captured by an infrared imager.

[0103] Step 420 : Analyze the first infrared image to determine the leaking gas image area in the first infrared image and the gas concentration information corresponding to the leaking gas image area.

[0104] Step 430 : Determine the optical flow field corresponding to the leaking gas image area based on the first infrared image and the second infrared image.

[0105] Step 440: Obtain environmental data.

[0106] Optionally, the gas leak detection device may further include a temperature sensor and a humidity sensor. The environmental data may include one or more of the ambient temperature collected by the temperature sensor, the ambient humidity collected by the humidity sensor, and the target distance corresponding to the infrared imager. The ambient temperature may refer to the temperature of the area to be detected, the ambient humidity may refer to the humidity of the area to be detected, the target distance is the distance between the infrared imager and the area to be detected, the area to be detected refers to the spatial area where the leaking gas is located, and the target distance may refer to the spatial distance. Figure 1 As shown, the target distance may refer to the distance between the gas leak detection device 110 and the leaking gas 120. Optionally, the ambient temperature and humidity may also be at the gas leak detection device 110. The embodiment of the present application does not limit the collection position of the temperature sensor and the collection position of the humidity sensor.

[0107] Step 450 : If the environmental data meets the preset conditions, the optical flow field corresponding to the leaking gas image area is compensated according to the compensation parameters to obtain a compensated optical flow field corresponding to the leaking gas image area.

[0108] The preset conditions include one or more of the following: ambient temperature less than a temperature threshold, ambient humidity greater than a humidity threshold, and target distance greater than a distance threshold. Compensation parameters can be pre-set, with different preset conditions corresponding to different compensation parameters. The electronic device can compensate the optical flow field corresponding to the leaked gas image area based on the compensation parameters to obtain a compensated optical flow field corresponding to the leaked gas image area. For example, when the ambient temperature is less than the temperature threshold and the target distance is greater than the distance threshold, the compensation coefficient can be greater than 1, resulting in a larger value corresponding to the compensated optical flow field.

[0109] Step 460 : determining the gas leakage velocity corresponding to the leaking gas image region according to the compensated optical flow field and gas concentration information corresponding to the leaking gas image region.

[0110] In an embodiment of the present application, the electronic device can also obtain environmental data, and when the environmental data meets preset conditions, compensate the optical flow field corresponding to the leakage gas image area according to the compensation parameters to obtain the compensated optical flow field corresponding to the leakage gas image area, thereby improving the accuracy of the gas concentration information and avoiding large deviations in the optical flow field caused by factors such as humidity, temperature, and shooting distance. The gas leakage rate corresponding to the leakage gas image area is then determined based on the compensated optical flow field and gas concentration information corresponding to the leakage gas image area, which also improves the accuracy of the determined gas leakage rate.

[0111] It can be understood that the above embodiments can be used in combination, that is, the electronic device can execute steps 340-350 and steps 440-450 in one embodiment, so as to determine the gas leakage rate corresponding to the leakage gas image area based on the compensated optical flow field and the corrected gas concentration information corresponding to the leakage gas image area, so as to improve the accuracy of the determined gas leakage rate.

[0112] like Figure 5 As shown, Figure 5 This is a flow chart of a method for an electronic device to determine a gas leakage velocity corresponding to a leaking gas image area disclosed in an embodiment of the present application. The method may include the following steps:

[0113] Step 510: Obtain camera parameters and acquisition frequency of the infrared imager.

[0114] The camera parameters may include camera resolution, field of view, etc., and the acquisition frequency may refer to the frequency at which the infrared imager acquires infrared images.

[0115] Step 520 : Determine the spatial area corresponding to each pixel in the first infrared image according to the camera parameters and the target distance.

[0116] The electronic device can calculate the width and height of the field of view based on the field of view angle and the shooting distance, and then calculate the width and height corresponding to each pixel in three-dimensional space based on the camera resolution, thereby calculating the spatial area corresponding to each pixel. Optionally, the field of view angle may include a horizontal field of view angle and a vertical field of view angle. The electronic device can calculate the width of the field of view based on the horizontal field of view angle and the shooting distance, and calculate the height of the field of view based on the vertical field of view angle and the shooting distance based on trigonometric functions.

[0117] Step 530 : Calculate the moving speed of the optical flow corresponding to each pixel in the leaking gas image area in the three-dimensional space according to the acquisition frequency, the spatial area, and the optical flow field.

[0118] The optical flow field includes the optical flow corresponding to each pixel in the leaked gas image region, which includes a motion vector representing the direction and speed of movement of each pixel. The electronic device can calculate the movement speed of the optical flow corresponding to each pixel in the leaked gas image region in three-dimensional space based on the motion vector, acquisition frequency, and spatial area included in the optical flow corresponding to each pixel in the leaked gas image region.

[0119] In one embodiment, the electronic device can determine the time difference between the first infrared image and the second infrared image based on the acquisition frequency. The first infrared image and the second infrared image can be two adjacent infrared image frames captured by an infrared imager. Therefore, the electronic device can determine the time difference between each two infrared images based on the acquisition frequency as the time difference between the first infrared image and the second infrared image. For example, if the acquisition frequency is 100 Hz, then the infrared imager captures 100 infrared images per second, and the time difference between each two infrared images is 0.01 seconds, meaning that the time difference between the first infrared image and the second infrared image is 0.01 seconds. Alternatively, the electronic device can multiply the motion vector corresponding to each pixel in the leaking gas image region by the spatial area, and divide the result by the time difference, to obtain the movement speed of the optical flow corresponding to each pixel in the leaking gas image region in three-dimensional space.

[0120] Step 540 : determining the gas leakage speed corresponding to each pixel in the leaking gas image area according to the gas concentration information corresponding to the leaking gas image area and the movement speed corresponding to each pixel in the leaking gas image area.

[0121] Optionally, the electronic device may multiply the gas concentration information corresponding to the leaking gas image area by the movement speed corresponding to each pixel in the leaking gas image area, thereby obtaining the gas leakage speed corresponding to each pixel in the leaking gas image area.

[0122] At step 550, the gas leakage speed corresponding to the gas leakage image region is determined according to the gas leakage speed corresponding to each pixel in the gas leakage image region.

[0123] It should be understood that, in an ideal case, the gas amount of the leakage gas contained in any two cross sections perpendicular to the gas leakage direction is equal in the area close to the leakage position, and thus the gas leakage speed of only one cross section needs to be solved, which can be used as the gas leakage speed corresponding to the gas leakage image region.

[0124] In an embodiment, the electronic device can determine a plurality of target pixels corresponding to a target cross section perpendicular to the gas leakage direction in the gas leakage image region, and accumulate the gas leakage speeds corresponding to the plurality of target pixels to obtain the gas leakage speed corresponding to the gas leakage image region. The electronic device can determine the gas leakage direction according to the shape of the gas leakage image region, the distribution of the gas concentration information, and other information, and then determine the target cross section perpendicular to the gas leakage direction, so as to determine the plurality of target pixels corresponding to the target cross section perpendicular to the gas leakage direction in the gas leakage image region. Optionally, the electronic device can also determine the leakage position, and the target cross section can be a cross section with an image distance from the leakage position not greater than an image distance threshold. Implementing this embodiment can improve the accuracy of the determined gas leakage speed.

[0125] In the embodiments of the present application, the electronic device can obtain the camera parameters and the acquisition frequency of the infrared imager, determine the spatial area corresponding to each pixel in the first infrared image according to the camera parameters, calculate the moving speed of the optical flow corresponding to each pixel in the gas leakage image region in the three-dimensional space according to the acquisition frequency, the spatial area, and the optical flow field, and determine the gas leakage speed corresponding to each pixel in the gas leakage image region according to the gas concentration information corresponding to the gas leakage image region and the moving speed corresponding to each pixel in the gas leakage image region, so as to determine the gas leakage speed corresponding to the gas leakage image region according to the gas leakage speed corresponding to each pixel in the gas leakage image region. The change of the optical flow of each pixel in the gas leakage image region in the first infrared image is converted to the three-dimensional space, so as to determine the gas leakage corresponding to each pixel, and then the gas leakage speed corresponding to the entire gas leakage image region is obtained. The gas leakage detection does not need to be assisted by other props, the applicability of the gas leakage detection is improved, and the accuracy of the gas leakage detection is improved.

[0126] As shown in FIG. 6, the electronic device can determine the gas leakage speed corresponding to the gas leakage image region according to the gas leakage speed corresponding to each pixel in the gas leakage image region. Figure 6 Figure 6 ​6 is a modular schematic diagram of a gas leakage detection device disclosed in an embodiment of the present application. The gas leakage detection device 600 may include a data acquisition module 610, a region analysis module 620, an optical flow determination module 630, and a speed determination module 640, wherein:

[0127] The data acquisition module 610 is configured to acquire a first infrared image and a second infrared image captured by an infrared imager;

[0128] A region analysis module 620 is configured to analyze the first infrared image to determine a gas leakage image region in the first infrared image and gas concentration information corresponding to the gas leakage image region, where the gas concentration information is used to represent the integral of the gas concentration in the gas leakage image region in the image acquisition direction;

[0129] An optical flow determination module 630 is configured to determine an optical flow field corresponding to the leaking gas image region based on the first infrared image and the second infrared image;

[0130] The speed determination module 640 is configured to determine the gas leakage speed corresponding to the leaking gas image region according to the optical flow field and gas concentration information corresponding to the leaking gas image region.

[0131] In one embodiment, the data acquisition module 610 is further used to acquire gas concentration data collected by at least one gas concentration detector; the regional analysis module 620 is further used to correct the gas concentration information corresponding to the leakage gas image area based on the gas concentration data respectively collected by at least one gas concentration detector, and obtain the corrected gas concentration information corresponding to the leakage gas image area; the speed determination module 640 is further used to determine the gas leakage speed corresponding to the leakage gas image area based on the optical flow field corresponding to the leakage gas image area and the corrected gas concentration information.

[0132] In one embodiment, the regional analysis module 620 is also used to perform weighted sum calculation on the gas concentration data respectively collected by at least one gas concentration detector and the gas concentration information corresponding to the leakage gas image area based on the gas concentration data respectively collected by at least one gas concentration detector, the weights corresponding to the respective gas concentration data, and the weights of the gas concentration information corresponding to the leakage gas image area, so as to obtain the corrected gas concentration information corresponding to the leakage gas image area.

[0133] In one embodiment, the data acquisition module 610 is also used to acquire environmental data, which includes one or more of the ambient temperature collected by the temperature sensor, the ambient humidity collected by the humidity sensor, and the target distance corresponding to the infrared imager, where the target distance is the distance between the infrared imager and the area to be detected; the area analysis module 620 is also used to compensate the optical flow field corresponding to the leakage gas image area according to the compensation parameters if the environmental data meets the preset conditions, so as to obtain the compensated optical flow field corresponding to the leakage gas image area; wherein the preset conditions include one or more of the ambient temperature being less than the temperature threshold, the ambient humidity being greater than the humidity threshold, and the target distance being greater than the distance threshold; the speed determination module 640 is also used to determine the gas leakage speed corresponding to the leakage gas image area based on the compensated optical flow field corresponding to the leakage gas image area and the gas concentration information.

[0134] In one embodiment, the first infrared image and the second infrared image are two adjacent frames of infrared images captured by an infrared imager; the data acquisition module 610 is further used to obtain camera parameters, target distance and acquisition frequency corresponding to the infrared imager; the area analysis module 620 is further used to determine the spatial area corresponding to each pixel in the first infrared image based on the camera parameters and target distance; the speed determination module 640 is further used to calculate the moving speed of the optical flow corresponding to each pixel in the leakage gas image area in three-dimensional space based on the acquisition frequency, spatial area and optical flow field; determine the gas leakage speed corresponding to each pixel in the leakage gas image area based on the gas concentration information corresponding to the leakage gas image area and the moving speed corresponding to each pixel in the leakage gas image area; determine the gas leakage speed corresponding to the leakage gas image area based on the gas leakage speed corresponding to each pixel in the leakage gas image area.

[0135] In one embodiment, the speed determination module 640 is further used to determine a plurality of target pixels corresponding to a target cross section perpendicular to the gas leakage direction in the leaking gas image area; and to accumulate the gas leakage speeds corresponding to the plurality of target pixels to obtain the gas leakage speed corresponding to the leaking gas image area.

[0136] In one embodiment, the regional analysis module 620 is also used to analyze the first infrared image to determine the leakage gas image area and the background image area in the first infrared image; determine the gas temperature corresponding to the leakage gas image area and the background temperature corresponding to the background image area; calculate the temperature difference and radiation intensity difference corresponding to the gas temperature and the background temperature based on the gas temperature and the background temperature; determine the transmittance of the leakage gas image area based on the temperature difference and the radiation intensity difference; and determine the gas concentration information corresponding to the leakage gas image area based on the transmittance of the leakage gas image area.

[0137] In an embodiment of the present application, an electronic device can acquire a first infrared image and a second infrared image captured by an infrared imager, analyze the first infrared image, determine a leaking gas image region in the first infrared image, and gas concentration information corresponding to the leaking gas image region. The gas concentration information can represent the integral of the gas concentration in the leaking gas image region along the image acquisition direction. The electronic device can also determine an optical flow field corresponding to the leaking gas image region based on the first infrared image and the second infrared image, and then determine a gas leakage velocity corresponding to the leaking gas image region based on the optical flow field and gas concentration information corresponding to the leaking gas image region. Through this embodiment, the electronic device can analyze information such as gas concentration information and gas leakage velocity by analyzing infrared images, thereby improving the comprehensiveness of gas leak detection. Since the gas leakage velocity can be determined by analyzing infrared images, gas leakage velocity detection can be performed in most scenarios, thereby improving the applicability of gas leak detection.

[0138] like Figure 7 As shown, in one embodiment, an electronic device is provided, which may include:

[0139] A memory 710 storing executable program code;

[0140] a processor 720 coupled to the memory 710;

[0141] The processor 720 calls the executable program code stored in the memory 710 to implement the gas leakage detection method provided in the above embodiments.

[0142] The memory 710 may include a random access memory (RAM) or a read-only memory (ROM). The memory 710 may be used to store instructions, programs, codes, code sets, or instruction sets. The memory 710 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc. The data storage area may also store data created by the electronic device during use.

[0143] The processor 720 may include one or more processing cores. The processor 720 utilizes various interfaces and circuits to connect various components within the electronic device. It executes instructions, programs, code sets, or instruction sets stored in the memory 710, as well as accesses data stored in the memory 710, to perform various functions of the electronic device and process data. Optionally, the processor 720 may be implemented using at least one of the following hardware forms: a digital signal processing (DSP), a field-programmable gate array (FPGA), or a programmable logic array (PLA). The processor 720 may integrate one or a combination of a central processing unit (CPU), a graphics processing unit (GPU), and a modem. The CPU primarily processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing display content; and the modem handles wireless communications. It is understood that the modem may not be integrated into the processor 720 and may be implemented separately via a communications chip.

[0144] It is understandable that the electronic device may include more or fewer structural elements than those in the above structural block diagram, for example, a power module, physical buttons, WiFi (Wireless Fidelity) module, speakers, Bluetooth modules, sensors, etc., and is not limited here.

[0145] An embodiment of the present application discloses a computer-readable storage medium storing a computer program, wherein the computer program enables a computer to execute the methods described in the above embodiments.

[0146] In addition, an embodiment of the present application further discloses a computer program product. When the computer program product is run on a computer, the computer can execute all or part of the steps in any one of the gas leakage detection methods described in the above embodiments.

[0147] Those skilled in the art will appreciate that all or part of the steps in the various methods of the above embodiments can be completed by a program instructing related hardware. The program can be stored in a computer-readable storage medium, and the storage medium includes a read-only memory (ROM), a random access memory (RAM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), a one-time programmable read-only memory (OTPROM), an electronically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, magnetic disk storage, magnetic tape storage, or any other computer-readable medium capable of carrying or storing data.

[0148] The above is a detailed introduction to a gas leak detection method, device, electronic device, and storage medium disclosed in the embodiments of the present application. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only intended to help understand the method and core ideas of the present application. At the same time, for those skilled in the art, based on the ideas of the present application, there may be changes in the specific implementation methods and application scopes. In summary, the contents of this specification should not be understood as limiting the present application.

Claims

1. A gas leak detection method, characterized in that: include: Acquire a first infrared image and a second infrared image captured by an infrared imager; Analyzing the first infrared image to determine a leaking gas image region in the first infrared image and gas concentration information corresponding to the leaking gas image region; determining an optical flow field corresponding to the leaking gas image area according to the first infrared image and the second infrared image; determining a gas leakage velocity corresponding to the leaking gas image region according to the optical flow field and gas concentration information corresponding to the leaking gas image region; The determining of the gas leakage velocity corresponding to the leaking gas image area according to the optical flow field and gas concentration information corresponding to the leaking gas image area includes: Calculating a moving speed of the optical flow corresponding to each pixel in the leaking gas image area in three-dimensional space based on an acquisition frequency of the infrared imager, a spatial area corresponding to each pixel in the first infrared image, and the optical flow field; determining a gas leakage speed corresponding to each pixel in the leaking gas image area according to gas concentration information corresponding to the leaking gas image area and a movement speed corresponding to each pixel in the leaking gas image area; In the leaking gas image area, determining a plurality of target pixels corresponding to a target cross section perpendicular to a gas leakage direction; The gas leakage rates corresponding to the plurality of target pixels are accumulated to obtain the gas leakage rate corresponding to the leaking gas image area.

2. The method according to claim 1, characterized in that Before determining the gas leakage velocity corresponding to the leaked gas image area based on the optical flow field and gas concentration information corresponding to the leaked gas image area, the method further includes: Acquiring gas concentration data collected by at least one gas concentration detector; Correcting the gas concentration information corresponding to the leaked gas image area according to the gas concentration data respectively collected by the at least one gas concentration detector to obtain corrected gas concentration information corresponding to the leaked gas image area; The determining of the gas leakage velocity corresponding to the leaking gas image area according to the optical flow field and gas concentration information corresponding to the leaking gas image area includes: The gas leakage velocity corresponding to the leaking gas image region is determined according to the optical flow field corresponding to the leaking gas image region and the corrected gas concentration information.

3. The method according to claim 2, characterized in that The step of correcting the gas concentration information corresponding to the leaked gas image area based on the gas concentration data respectively collected by the at least one gas concentration detector to obtain the corrected gas concentration information corresponding to the leaked gas image area includes: According to the gas concentration data respectively collected by the at least one gas concentration detector, the weight corresponding to each gas concentration detector and the weight of the gas concentration information, a weighted sum calculation is performed on the gas concentration data respectively collected by the at least one gas concentration detector and the gas concentration information to obtain the corrected gas concentration information corresponding to the leakage gas image area.

4. The method according to claim 1, wherein Before determining the gas leakage velocity corresponding to the leaked gas image area based on the optical flow field and gas concentration information corresponding to the leaked gas image area, the method further includes: Acquiring environmental data, the environmental data including one or more of an ambient temperature collected by a temperature sensor, an ambient humidity collected by a humidity sensor, and a target distance corresponding to the infrared imager, where the target distance is the distance between the infrared imager and the area to be detected; If the environmental data satisfies a preset condition, the optical flow field corresponding to the leaking gas image area is compensated according to the compensation parameter to obtain a compensated optical flow field corresponding to the leaking gas image area; wherein the preset condition includes one or more of the following: the ambient temperature is less than a temperature threshold, the ambient humidity is greater than a humidity threshold, and the target distance is greater than a distance threshold; The determining of the gas leakage velocity corresponding to the leaking gas image area according to the optical flow field and gas concentration information corresponding to the leaking gas image area includes: The gas leakage velocity corresponding to the leaking gas image area is determined according to the compensated optical flow field and gas concentration information corresponding to the leaking gas image area.

5. The method according to claim 1, wherein The first infrared image and the second infrared image are two adjacent frames of infrared images captured by an infrared imager; Before determining the gas leakage velocity corresponding to the leaked gas image area based on the optical flow field and gas concentration information corresponding to the leaked gas image area, the method further includes: Obtaining camera parameters, target distance, and acquisition frequency corresponding to the infrared imager; The spatial area corresponding to each pixel in the first infrared image is determined according to the camera parameters and the target distance.

6. The method according to claim 1, characterized in that Analyzing the first infrared image to determine a leaking gas image area in the first infrared image and a gas concentration corresponding to the leaking gas image area includes: Analyzing the first infrared image to determine a leaking gas image region and a background image region in the first infrared image; Determining a gas temperature corresponding to the leaking gas image area and a background temperature corresponding to the background image area; Calculating a temperature difference and a radiation intensity difference corresponding to the gas temperature and the background temperature according to the gas temperature and the background temperature; determining a transmittance of the leaked gas image area according to the temperature difference and the radiation intensity difference; The gas concentration information corresponding to the leaked gas image area is determined according to the transmittance of the leaked gas image area.

7. A gas leak detection device, characterized in that: include: A data acquisition module, configured to acquire a first infrared image and a second infrared image captured by an infrared imager; a region analysis module, configured to analyze the first infrared image to determine a leaking gas image region in the first infrared image and gas concentration information corresponding to the leaking gas image region; an optical flow determination module, configured to determine an optical flow field corresponding to the leaking gas image area based on the first infrared image and the second infrared image; a speed determination module, configured to determine the gas leakage speed corresponding to the leaking gas image area according to the optical flow field and gas concentration information corresponding to the leaking gas image area; The speed determination module is further configured to calculate, based on the acquisition frequency of the infrared imager, the spatial area corresponding to each pixel in the first infrared image, and the optical flow field, a moving speed of the optical flow corresponding to each pixel in the leaking gas image area in three-dimensional space; and determine, based on the gas concentration information corresponding to the leaking gas image area and the moving speed corresponding to each pixel in the leaking gas image area, a gas leakage speed corresponding to each pixel in the leaking gas image area; The speed determination module is further used to determine, in the leaking gas image area, a plurality of target pixels corresponding to a target cross section perpendicular to the gas leakage direction; and accumulate the gas leakage speeds corresponding to the plurality of target pixels to obtain the gas leakage speed corresponding to the leaking gas image area.

8. An electronic device, characterized in that: include: a memory storing executable program code; a processor coupled to the memory; The processor calls the executable program code stored in the memory to execute the method according to any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, wherein when the computer program is executed by a processor, the processor is caused to perform the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • System and method for quantifying a gas leak

    CN111033231A

  • Air leakage detection method and device, electronic equipment, system and storage medium

    CN116630252A