Defogging image generation method and device
By acquiring and processing photon echo data and polarization information, calculating the atmospheric transmittance and scattered light values, and generating high-quality defogging images, the transmittance estimation deviation problem of polarization imaging technology in complex atmospheric environments is solved, and the defogging effect is improved.
Patent Information
- Application Number
- CN202511322144.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-16
- Publication Date
- 2025-10-17
- Estimated Expiration
- 2045-09-16
AI Technical Summary
Existing polarization imaging technology is susceptible to ambient light interference and insufficient signal-to-noise ratio in weak texture areas in complex atmospheric environments, resulting in transmittance estimation deviations and affecting the authenticity and consistency of the dehazing effect.
By acquiring the original photon echo data and the four-channel polarization intensity image, the target echo time and distance are calculated after noise filtering. The atmospheric transmittance and scattered light value are calculated by combining the backscattering intensity map, calibration constant and atmospheric scattering scale factor, and finally a defogging image is generated.
The quality of dehazed images is improved, image contrast and clarity are enhanced, and the accuracy and consistency of the dehazed effect are ensured.
Smart Images

Figure CN120807367A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of image processing, in particular to a fog image generation method and device. BACKGROUND
[0002] The polarization fog-penetrating imaging technology utilizes the difference between the scattered light and the target reflected light in the polarization state in the fog and haze environment, and separates the target signal and the scattered interference by analyzing the polarization information. The core of this kind of passive imaging method lies in the accurate estimation of the atmospheric transmittance.
[0003] In the related art, the atmospheric transmittance is estimated based on the inversion of the transmittance distribution map according to the change of the polarization parameter. However, in the actual complex atmospheric environment, the passive polarization observation is easily limited by the environmental light interference and the insufficient signal-to-noise ratio in the weak texture area, resulting in deviation of the transmittance estimation and affecting the authenticity and consistency of the fog removal effect. SUMMARY
[0004] Therefore, the present application provides a fog image generation method and device for generating a fog image.
[0005] The purpose of the present application can be achieved by the following technical solutions: The first aspect of the present application provides a fog image generation method, comprising: obtaining original photon echo data and a four-channel polarization intensity image; performing noise filtering on the original photon echo data to obtain denoised photon echo data, the original photon echo data including photon counts in each time window in each pixel; based on the denoised photon echo data, calculating a target echo time of each pixel; based on the speed of light and the target echo time, calculating a target distance of each pixel; based on the denoised photon echo data, the target echo time of each pixel and a preset buffer interval, calculating a backscattering intensity image; based on the backscattering intensity image, a first calibration constant and the target distance of each pixel, calculating a target scattering coefficient; based on the target scattering coefficient and a preset atmospheric scattering scale factor, calculating an atmospheric transmittance of each pixel; based on the four-channel polarization intensity image, calculating a polarization initial atmospheric transmittance; based on the atmospheric transmittance and the polarization initial atmospheric transmittance, calculating a target atmospheric transmittance parameter of each pixel; based on the target atmospheric transmittance parameter, calculating an atmospheric scattering light value of each pixel; based on the target image, the target atmospheric transmittance parameter and the atmospheric scattering light value, calculating a fog image.
[0006] In an alternative embodiment, the polarized initial atmospheric transmittance is calculated based on the four-channel polarized intensity image, comprising: The Stokes parameters are calculated based on the four-channel polarized intensity image, the Stokes parameters comprising a first Stokes parameter, a second Stokes parameter and a third Stokes parameter; The polarized initial atmospheric transmittance is calculated based on the Stokes parameters.
[0007] In an alternative embodiment, the Stokes parameters are calculated based on the four-channel polarized intensity image, comprising: The Stokes parameters are calculated based on the four-channel polarized intensity image, by using the following formula: ; Wherein, S1 represents the first Stokes parameter, I0 represents the polarized intensity image of the 0° polarization direction, I45 represents the polarized intensity image of the 45° polarization direction, I90 represents the polarized intensity image of the 90° polarization direction, I135 represents the polarized intensity image of the 135° polarization direction. ; Wherein, S2 represents the second Stokes parameter, I0 represents the polarized intensity image of the 0° polarization direction, I90 represents the polarized intensity image of the 90° polarization direction. ; Wherein, S3 represents the third Stokes parameter, I45 represents the polarized intensity image of the 45° polarization direction, I135 represents the polarized intensity image of the 135° polarization direction.
[0008] In an alternative embodiment, the target atmospheric transmittance parameter of each pixel is calculated based on the atmospheric transmittance and the polarized initial atmospheric transmittance, comprising: The target atmospheric transmittance parameter of each pixel is calculated based on the atmospheric transmittance and the polarized initial atmospheric transmittance, by using the following formula: ; Wherein, Tij represents the target atmospheric transmittance parameter of the pixel in the i-th row and the j-th column, W represents the adaptive weight, T represents the atmospheric transmittance, T0 represents the polarized initial atmospheric transmittance.
[0009] In an alternative embodiment, before calculating the target atmospheric transmittance parameter of each pixel based on the atmospheric transmittance and the initial atmospheric transmittance of polarization, further comprising: determining a target time window based on the target echo time of each pixel and a preset buffer interval; calculating the adaptive weight using the following formula: ; wherein, is the adaptive weight, denotes the first signal-to-noise ratio, denotes the second signal-to-noise ratio; ; wherein, denotes the first signal-to-noise ratio, denotes the first calibration coefficient, denotes the maximum photon count in the target time window; ; wherein, denotes the second signal-to-noise ratio, denotes the second calibration coefficient, denotes the median filtering, is the gradient operator, denotes the gradient of , and denotes the calculation of the Frobenius norm.
[0010] In an alternative embodiment, the target echo time of each pixel is calculated based on the denoised photon echo data, comprising: ; wherein, denotes the target echo time of the i-th row and j-th column pixel, denotes the maximum value of the formula in the parentheses, denotes the photon count in the t-th time window of the i-th row and j-th column pixel in the denoised photon echo data, denotes the system impulse response function.
[0011] In an alternative embodiment, the backscattering intensity map is calculated based on the denoised photon echo data, the target echo time of each pixel, and the preset buffer interval, comprising: The backscattering intensity map is calculated based on the denoised photon echo data, the target echo time of each pixel, and the preset buffer interval, using the following formula: ; wherein, a backscatter intensity map representing a pixel in the i th row and the j th column, a target echo time representing a pixel in the i th row and the j th column, a preset buffer interval, a photon count in a t th time window in a pixel in the i th row and the j th column in the de-noised photon echo data.
[0012] In an optional embodiment, based on the backscatter intensity map, the first calibration constant, and the target distance of each pixel, the target scattering coefficient is calculated, including: Based on the backscatter intensity map, the first calibration constant, and the target distance of each pixel, the target scattering coefficient is calculated by using the following formula: ; wherein, a target scattering coefficient of a pixel in the i th row and the j th column, a first calibration constant, a backscatter intensity map representing a pixel in the i th row and the j th column, a target distance representing a pixel in the i th row and the j th column.
[0013] In an optional embodiment, based on the target scattering coefficient and a preset atmospheric scattering proportion factor, the atmospheric transmittance of each pixel is calculated, including: Based on the target scattering coefficient and a preset atmospheric scattering proportion factor, the atmospheric transmittance of each pixel is calculated by using the following formula: ; wherein, an atmospheric transmittance of a pixel in the i th row and the j th column, a target scattering coefficient of a pixel in the i th row and the j th column, a preset atmospheric scattering proportion factor, a target distance representing a pixel in the i th row and the j th column.
[0014] The second aspect of the present application provides a fog image generation device, including: an acquisition module configured to acquire original photon echo data and a four-channel polarization intensity image; a filtering module configured to perform noise filtering on the original photon echo data to obtain de-noised photon echo data, the original photon echo data including a photon count in each time window in each pixel; a first calculation module configured to calculate a target echo time of each pixel based on the de-noised photon echo data; a second calculation module configured to calculate a target distance of each pixel according to a speed of light and the target echo time; The third calculation module is configured to calculate a backscattering intensity map based on the de-noised photon echo data, the target echo time of each pixel, and a preset buffer interval. The fourth calculation module is configured to calculate a target scattering coefficient based on the backscattering intensity map, a first calibration constant, and the target distance of each pixel. The fifth calculation module is configured to calculate an atmospheric transmittance of each pixel based on the target scattering coefficient and a preset atmospheric scattering proportion factor. The sixth calculation module is configured to calculate a polarization initial atmospheric transmittance based on a four-channel polarization intensity image. The seventh calculation module is configured to calculate a target atmospheric transmittance parameter of each pixel based on the atmospheric transmittance and the polarization initial atmospheric transmittance. The eighth calculation module is configured to calculate an atmospheric scattering light value of each pixel based on the target atmospheric transmittance parameter. The ninth calculation module is configured to calculate a de-fogging image based on the target image, the target atmospheric transmittance parameter, and the atmospheric scattering light value.
[0015] The third aspect of the present application provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements the method of the first aspect when executing the computer program.
[0016] The fourth aspect of the present application provides a computer readable storage medium, which stores a computer program, and the computer program is executable on a processor to implement the method of the first aspect.
[0017] Compared with the prior art, the de-fogging image generation method provided by the present application calculates the target echo time based on the de-noised photon echo data filtered by noise; calculates the target distance according to the speed of light and the target echo time; calculates the backscattering intensity map based on the above data and a preset buffer interval; calculates the target scattering coefficient based on the backscattering intensity map, a first calibration constant, and the target distance; calculates the atmospheric transmittance based on the target scattering coefficient and a preset atmospheric scattering proportion factor; calculates the polarization initial atmospheric transmittance based on a four-channel polarization intensity image; calculates the target atmospheric transmittance parameter based on the atmospheric transmittance and the polarization initial atmospheric transmittance; calculates the atmospheric scattering light value based on the target atmospheric transmittance parameter; and calculates the de-fogging image based on the target image, the target atmospheric transmittance parameter, and the atmospheric scattering light value. In this way, the image quality of the de-fogging image is improved. BRIEF DESCRIPTION OF DRAWINGS
[0018] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, the drawings in the following description only constitute some of the embodiments of the present application, and for those skilled in the art, other drawings can also be obtained without creative labor on the basis of these drawings.
[0019] Figure 1 A flowchart of a dehazing image generation method provided by an embodiment of the present application; Figure 2 A flowchart of a method for obtaining original photon echo data and four-channel polarization intensity images based on a laser source and a single-photon detector provided by an embodiment of the present application; Figure 3 Another flowchart of a dehazing image generation method provided by an embodiment of the present application; Figure 4 A structural block diagram of a dehazing image generation device provided by an embodiment of the present application; Figure 5 A structural block diagram of an electronic device for implementing a dehazing image generation method provided by an embodiment of the present application. DETAILED DESCRIPTION
[0020] In order to make the person skilled in the art better understand the present application, the technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments only constitute some of the embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor should belong to the scope of protection of the present application.
[0021] It should be noted that the terms "first", "second" and the like in the specification and claims of the present application and the above-described drawings are used to distinguish similar objects, and do not necessarily indicate a specific order or a chronological sequence. It should be understood that the data thus used can be interchanged under appropriate circumstances, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device including a series of steps or units does not necessarily have to include those steps or units clearly listed, but can include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0022] It should be understood that in the embodiments of the present application, "at least one" refers to one or more, and "more than one" refers to two or more. "And / or" is merely a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the previous and subsequent associated objects are in an "or" relationship. "Including A, B and / or C" means including any one, any two, or any three of A, B, and C.
[0023] It should be understood that in the embodiments of the present application, "B corresponding to A," "B corresponding to A," "A corresponds to B," or "B corresponds to A" means that B is associated with A and B can be determined based on A. Determining B based on A does not mean determining B based solely on A; B can also be determined based on A and / or other information.
[0024] In order to solve the technical problems existing in the related art, the embodiments of the present application provide a defogging image generation method and device.
[0025] The dehazed image generation method provided in the embodiments of the present application can be executed by an electronic device, which can be a terminal or a server. The terminal can be a terminal device such as a smartphone, a tablet computer, or a laptop computer. The server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers. It can also be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms. It is understandable that the present application does not specifically limit the execution entity of the dehazed image generation method.
[0026] The technical solution of the present application is described in detail below through specific embodiments. It should be noted that the following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments described below are used to explain the technical solution of the present application and are not intended to be used as limitations for actual use.
[0027] In order to solve the technical problems existing in the related art, the embodiment of the present application provides a method for generating a defogging image, such as Figure 1 As shown, Figure 1 This is a flowchart of a method for generating a defogging image according to an embodiment of the present application. It should be noted that the steps shown may be performed in a different logical order than that shown in the flowchart of the method. The method may include the following steps S101 to S111.
[0028] Step S101: acquiring raw photon echo data and four-channel polarization intensity images.
[0029] It should be noted that the original photon echo data is a three-dimensional matrix, including the echo appearance time and photon count collected by the single photon detector.
[0030] In an optional embodiment, the four-channel polarization intensity image includes a polarization intensity image in a 0° polarization direction, a polarization intensity image in a 45° polarization direction, a polarization intensity image in a 90° polarization direction, and a polarization intensity image in a 135° polarization direction.
[0031] Figure 2 A schematic diagram of a process for obtaining raw photon echo data and four-channel polarization intensity images based on a laser source and a single photon detector provided in an embodiment of the present application is shown as follows: Figure 2 As shown, a laser source emits a laser pulse, which is then emitted onto the imaging target. Upon encountering the imaging target, the laser pulse emitted by the laser source is reflected, forming an echo signal. The echo signal contains information such as the shape and distance of the imaging target. The synchronization module is responsible for coordinating the timing relationship between the laser source and the single-photon detector to ensure that the emission of the laser pulse and the reception of the echo signal are precisely matched. After receiving the echo signal, the single-photon detector can record the time and position information of the arrival of each photon, thereby constructing three-dimensional point cloud data of the imaging target, that is, the raw photon echo data. The raw photon echo data presents the three-dimensional structure of the imaging target. A four-channel polarization intensity image is obtained through the polarization sensor, and the four-channel polarization intensity image is used to display the polarization characteristics of the imaging target.
[0032] Step S102: performing noise filtering on the original photon echo data to obtain denoised photon echo data.
[0033] It should be noted that the raw photon echo data includes the photon counts in each time window in each pixel.
[0034] In an optional embodiment, performing noise filtering on the original photon echo data to obtain denoised photon echo data specifically includes the following steps: The following formula is used to perform noise filtering on the original photon echo data to obtain denoised photon echo data: (1); in, represents the photon count in the t-th time window in the pixel in the i-th row and j-th column of the denoised photon echo data, Represents the filtering threshold set based on Poisson distribution, Indicates the pixel in the i-th row and j-th column of the original photon echo data. Photon counts in a time window.
[0035] By noise filtering on the original photon echo data, the de-noised photon echo data is obtained, which significantly enhances the contrast between the photon echo signal and noise, making the echo peak clearer. Moreover, the filtered echo signal is smoother, and the determined target echo time is more accurate, which is beneficial to high-precision time synchronization.
[0036] Step S103: Based on the de-noised photon echo data, the target echo time of each pixel is calculated.
[0037] In an optional embodiment, based on the de-noised photon echo data, the target echo time of each pixel is calculated, including: (2); Wherein, represents the target echo time of the i-th row and j-th column pixel, represents the maximum value of the formula in the parentheses, represents the photon count in the t-th time window of the i-th row and j-th column pixel in the de-noised photon echo data, represents the system impulse response function.
[0038] In an optional embodiment, is set according to the actual situation.
[0039] Step S104: According to the speed of light and the target echo time, the target distance of each pixel is calculated.
[0040] In an optional embodiment, the target distance of each pixel is calculated according to the speed of light and the target echo time, including: According to the speed of light and the target echo time, the target distance of each pixel is calculated by using the following formula: (3); Wherein, represents the target distance of the i-th row and j-th column pixel, represents the speed of light, represents the target echo time of the i-th row and j-th column pixel.
[0041] Step S105: Based on the de-noised photon echo data, the target echo time of each pixel, and the preset buffer interval, the backscattering intensity map is calculated.
[0042] In an optional embodiment, based on the de-noised photon echo data, the target echo time of each pixel, and the preset buffer interval, the backscattering intensity map is calculated, including: Based on the de-noised photon echo data, the target echo time of each pixel, and the preset buffer interval, the backscatter intensity map is calculated by using the following formula: (4); wherein, the backscatter intensity map of the i-th row and j-th column pixel, the target echo time of the i-th row and j-th column pixel, the preset buffer interval, the photon count in the t-th time window of the i-th row and j-th column pixel in the de-noised photon echo data.
[0043] In a more specific embodiment, the preset buffer interval can be set according to actual conditions.
[0044] Step S106: Based on the backscatter intensity map, the first calibration constant, and the target distance of each pixel, the target scattering coefficient is calculated.
[0045] In an optional embodiment, based on the backscatter intensity map, the first calibration constant, and the target distance of each pixel, the target scattering coefficient is calculated, including: Based on the backscatter intensity map, the first calibration constant, and the target distance of each pixel, the target scattering coefficient is calculated by using the following formula: (5); wherein, the target scattering coefficient of the i-th row and j-th column pixel, the first calibration constant, the backscatter intensity map of the i-th row and j-th column pixel, the target distance of the i-th row and j-th column pixel.
[0046] Step S107: Based on the target scattering coefficient and the preset atmospheric scattering proportion factor, the atmospheric transmittance of each pixel is calculated.
[0047] In an optional embodiment, based on the target scattering coefficient and the preset atmospheric scattering proportion factor, the atmospheric transmittance of each pixel is calculated, including: Based on the target scattering coefficient and the preset atmospheric scattering proportion factor, the atmospheric transmittance of each pixel is calculated by using the following formula: (6); wherein, the atmospheric transmittance of the i-th row and j-th column pixel, the target scattering coefficient of the i-th row and j-th column pixel, the preset atmospheric scattering proportion factor, target distance of an i-th row and a j-th column pixel.
[0048] Step S108: calculating the polarization initial atmospheric transmittance based on the four-channel polarization intensity image.
[0049] In an alternative embodiment, the polarization initial atmospheric transmittance is calculated based on the four-channel polarization intensity image, comprising: The Stokes parameters are calculated based on the four-channel polarization intensity image, the Stokes parameters comprising a first Stokes parameter, a second Stokes parameter and a third Stokes parameter; and the polarization initial atmospheric transmittance is calculated based on the Stokes parameters.
[0050] In a specific embodiment, the Stokes parameters are calculated based on the four-channel polarization intensity image, comprising: The Stokes parameters are calculated based on the four-channel polarization intensity image by using the following formulas: (7); wherein, the first Stokes parameter is represented by S1, the polarization intensity image of the 0° polarization direction is represented by I0, the polarization intensity image of the 45° polarization direction is represented by I45, the polarization intensity image of the 90° polarization direction is represented by I90, the polarization intensity image of the 135° polarization direction is represented by I135. (8); wherein, the second Stokes parameter is represented by S2, the polarization intensity image of the 0° polarization direction is represented by I0, the polarization intensity image of the 90° polarization direction is represented by I90. (9); wherein, the third Stokes parameter is represented by S3, the polarization intensity image of the 45° polarization direction is represented by I45, the polarization intensity image of the 135° polarization direction is represented by I135.
[0051] In a specific embodiment, the polarization initial atmospheric transmittance is calculated based on the Stokes parameters, comprising: The polarization initial atmospheric transmittance is calculated based on the Stokes parameters by using the following formula: (10); wherein, the polarization initial atmospheric transmittance is represented by T, the first Stokes parameter is represented by S1, denotes a second Stokes parameter, denotes a third Stokes parameter.
[0052] Step S109: based on the atmospheric transmittance and the polarized initial atmospheric transmittance, the target atmospheric transmittance parameter of each pixel is calculated.
[0053] In an optional embodiment, based on the atmospheric transmittance and the polarized initial atmospheric transmittance, the target atmospheric transmittance parameter of each pixel is calculated, comprising: Based on the atmospheric transmittance and the polarized initial atmospheric transmittance, the target atmospheric transmittance parameter of each pixel is calculated by the following formula: (11); wherein, denotes the target atmospheric transmittance parameter of the pixel in the i-th row and the j-th column, denotes an adaptive weight, denotes the atmospheric transmittance, denotes the polarized initial atmospheric transmittance.
[0054] In another optional embodiment, the dehazing image generation method provided by the present application further comprises: determining a target time window based on the target echo time of each pixel and a preset buffer interval; using the following formula, the adaptive weight is calculated: (12); wherein, is the adaptive weight, denotes a first signal-to-noise ratio, denotes a second signal-to-noise ratio; (13); wherein, denotes the first signal-to-noise ratio, denotes a first calibration coefficient, denotes a maximum value of photon counting in the target time window; (14); wherein, denotes the second signal-to-noise ratio, denotes a second calibration coefficient, denotes a median filter, and ∇ is a gradient operator, denotes a gradient of , and denotes calculating the Frobenius norm.
[0055] Step S110: based on the target atmospheric transmittance parameter, the atmospheric scattering light value of each pixel is calculated.
[0056] In an alternative embodiment, the atmospheric scattering light value of each pixel is calculated based on the target atmospheric transmittance parameter, including: The atmospheric scattering light value of each pixel is calculated based on the target atmospheric transmittance parameter by using the following formula: (15); Wherein, represents the atmospheric scattering light value of the pixel in the i-th row and the j-th column, represents the first Stokes parameter of the pixel in the i-th row and the j-th column, represents the target atmospheric transmittance parameter of the pixel in the i-th row and the j-th column.
[0057] Step S111: Calculate the defogging image based on the target image, the target atmospheric transmittance parameter and the atmospheric scattering light value.
[0058] In an alternative embodiment, the defogging image is calculated based on the target image, the target atmospheric transmittance parameter and the atmospheric scattering light value, including: (16); Wherein, represents the defogging image, represents the atmospheric scattering light value of the pixel in the i-th row and the j-th column, represents the first Stokes parameter of the pixel in the i-th row and the j-th column, represents the target atmospheric transmittance parameter of the pixel in the i-th row and the j-th column.
[0059] In another alternative embodiment, the defogging image generation method provided by the embodiments of the present application further includes: Generating a target distance map based on the target distance; Extracting edge features of the target distance map; Performing normalization processing on the edge features to obtain a normalized depth edge image; and performing detail enhancement processing on the defogging image based on the normalized depth edge image to obtain an enhanced defogging image.
[0060] In a more specific embodiment, the target distance map is generated based on the target distance, specifically including the following steps: creating a two-dimensional grid, each grid cell representing a pixel position; filling the target distance calculated for each point into the corresponding grid cell to form a distance matrix, and performing visualization processing on the distance matrix to obtain the target distance map.
[0061] In a more specific embodiment, the normalized depth edge image is obtained by using the following formula: (17); (18); wherein, denotes a normalized depth edge image, denotes a target distance map, denotes a horizontal Sobel operator, denotes a vertical Sobel operator, denotes normalization.
[0062] In another more specific embodiment, based on the normalized depth edge image, the defogged image is subjected to a detail enhancement processing by using the following formula to obtain an enhanced defogged image: (19); wherein, denotes the i-th channel of the enhanced defogged image, denotes the i-th channel of the defogged image, denotes the normalized depth edge image.
[0063] The embodiment of the present application also provides a flowchart of a defogged image generation method, as shown in Figure 3 , which specifically includes the following steps: Step one: performing noise reduction preprocessing on the original photon echo data to obtain denoised photon echo data; Step two: calculating a backscattering intensity map based on the denoised photon echo data; Step three: calculating an atmospheric transmittance based on the backscattering intensity map; Step four: calculating a polarization initial atmospheric transmittance based on the four-channel polarization intensity image; Step five: calculating a target atmospheric transmittance parameter based on the atmospheric transmittance and the polarization initial atmospheric transmittance; Step six: calculating an atmospheric scattering light value based on the target atmospheric transmittance parameter, and calculating a defogged image based on the target atmospheric transmittance parameter and the atmospheric scattering light value; Step seven: calculating a target distance map based on the denoised photon echo data; Step eight: calculating a depth edge image based on the target distance map; Step nine: performing a detail enhancement processing on the defogged image based on the depth edge image to obtain an enhanced defogged image.
[0064] Corresponding to the defogged image generation method provided by the embodiment of the present application, the embodiment of the present application also provides a defogged image generation device, as shown in Figure 4 , which includes: An acquisition module 401 is configured to acquire original photon echo data and a four-channel polarization intensity image. The filtering module 402 is configured to perform noise filtering on the original photon echo data to obtain denoised photon echo data, wherein the original photon echo data comprises photon counts in each time window of each pixel. The first calculation module 403 is configured to calculate target echo time of each pixel based on the denoised photon echo data. The second calculation module 404 is configured to calculate target distance of each pixel based on the speed of light and the target echo time. The third calculation module 405 is configured to calculate a backscattering intensity map based on the denoised photon echo data, the target echo time of each pixel, and a preset buffer interval. The fourth calculation module 406 is configured to calculate a target scattering coefficient based on the backscattering intensity map, a first calibration constant, and the target distance of each pixel. The fifth calculation module 407 is configured to calculate an atmospheric transmittance of each pixel based on the target scattering coefficient and a preset atmospheric scattering proportion factor. The sixth calculation module 408 is configured to calculate a polarized initial atmospheric transmittance based on the four-channel polarized intensity image. The seventh calculation module 409 is configured to calculate a target atmospheric transmittance parameter of each pixel based on the atmospheric transmittance and the polarized initial atmospheric transmittance. The eighth calculation module 410 is configured to calculate an atmospheric scattering light value of each pixel based on the target atmospheric transmittance parameter. The ninth calculation module 411 is configured to calculate a defogged image based on the target image, the target atmospheric transmittance parameter, and the atmospheric scattering light value.
[0065] Corresponding to the defogged image generation method provided by the embodiments of the present application, the embodiments of the present application also provide an electronic device for executing the defogged image generation method, as shown in Figure 5 The electronic device includes a processor 501 and a memory 502 for storing the program of the defogged image generation method. After the device is powered on and the program of the defogged image generation method is run by the processor, the following steps are performed: Obtain the original photon echo data and the four-channel polarized intensity image. Perform noise filtering on the original photon echo data to obtain denoised photon echo data, wherein the original photon echo data comprises photon counts in each time window of each pixel. Calculate target echo time of each pixel based on the denoised photon echo data. Calculate target distance of each pixel based on the speed of light and the target echo time. Calculate a backscattering intensity map based on the denoised photon echo data, the target echo time of each pixel, and a preset buffer interval. calculate a target scattering coefficient of each pixel based on the backscattering intensity map, a first calibration constant and the target distance of each pixel; calculate an atmospheric transmittance of each pixel based on the target scattering coefficient and a preset atmospheric scattering proportion factor; calculate a polarized initial atmospheric transmittance based on the four-channel polarized intensity image; calculate a target atmospheric transmittance parameter of each pixel based on the atmospheric transmittance and the polarized initial atmospheric transmittance; calculate an atmospheric scattering light value of each pixel based on the target atmospheric transmittance parameter; calculate a defogging image based on the target image, the target atmospheric transmittance parameter and the atmospheric scattering light value.
[0066] Corresponding to the defogging image generation method provided by the embodiments of the present application, the embodiments of the present application also provide a computer readable storage medium, which stores a program of the defogging image generation method, and the program is run by a processor to execute the following steps: obtain original photon echo data and a four-channel polarized intensity image; perform noise filtering on the original photon echo data to obtain denoised photon echo data, and the original photon echo data includes photon counts in each time window of each pixel; calculate a target echo time of each pixel based on the denoised photon echo data; calculate a target distance of each pixel according to the speed of light and the target echo time; calculate a backscattering intensity map based on the denoised photon echo data, the target echo time of each pixel and a preset buffer interval; calculate a target scattering coefficient of each pixel based on the backscattering intensity map, a first calibration constant and the target distance of each pixel; calculate an atmospheric transmittance of each pixel based on the target scattering coefficient and a preset atmospheric scattering proportion factor; calculate a polarized initial atmospheric transmittance based on the four-channel polarized intensity image; calculate a target atmospheric transmittance parameter of each pixel based on the atmospheric transmittance and the polarized initial atmospheric transmittance; calculate an atmospheric scattering light value of each pixel based on the target atmospheric transmittance parameter; calculate a defogging image based on the target image, the target atmospheric transmittance parameter and the atmospheric scattering light value.
[0067] Corresponding to the defogging image generation method provided by the embodiments of the present application, the embodiments of the present application also provide a computer program containing instructions, when the program is executed by a computer, the instructions make the computer execute the following steps: acquire raw photon echo data and a four-channel polarization intensity image; perform noise filtering on the raw photon echo data to obtain denoised photon echo data, the raw photon echo data including photon counts in each time window in each pixel; calculate a target echo time of each pixel based on the denoised photon echo data; calculate a target distance of each pixel based on the speed of light and the target echo time; calculate a backscatter intensity map based on the denoised photon echo data, the target echo time of each pixel, and a preset buffer interval; calculate a target scattering coefficient based on the backscatter intensity map, a first calibration constant, and the target distance of each pixel; calculate an atmospheric transmittance of each pixel based on the target scattering coefficient and a preset atmospheric scattering proportion factor; calculate a polarization initial atmospheric transmittance based on the four-channel polarization intensity image; calculate a target atmospheric transmittance parameter of each pixel based on the atmospheric transmittance and the polarization initial atmospheric transmittance; calculate an atmospheric scattering light value of each pixel based on the target atmospheric transmittance parameter; calculate a defogged image based on the target image, the target atmospheric transmittance parameter, and the atmospheric scattering light value.
[0068] It should be noted that the detailed description of the defogged image generation apparatus, the electronic device, the computer readable storage medium, and the computer program provided in the embodiments of the present application can refer to the related description of the defogged image generation method provided in the embodiments of the present application, which will not be repeated here.
[0069] The present application discloses the above preferred embodiments, but it is not intended to limit the present application. Any person skilled in the art can make possible changes and modifications without departing from the spirit and scope of the present application. Therefore, the protection scope of the present application should be subject to the scope defined by the claims of the present application.
[0070] In a typical configuration, the electronic device includes one or more processors (Central Processing Unit), input / output interfaces, network interfaces, and memories.
[0071] The memory can include non-persistent memory, random access memory (Random Access Memory), and / or non-volatile memory in the form of computer readable media, such as read only memory (Read Only Memory) or flash memory. The memory is an example of computer readable media.
[0072] Computer-readable media includes permanent and non-permanent, movable and non-movable media, which can be implemented by any method or technology to store information. The information can be computer-readable operations, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, programmable analog modules, static random access memory, dynamic random access memory, other types of random access memory, read-only memory, electrically erasable programmable read-only memory, flash memory or other memory technologies, compact disc read-only memory, digital video disc or other optical storage, magnetic cassette, magnetic tape disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. According to the definition herein, computer-readable media does not include non-transitory computer-readable media such as modulated data signals and carriers.
[0073] Those skilled in the art will appreciate that embodiments of the present application can be provided as methods, systems or computer program products. Therefore, the present application can take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including, but not limited to, disk storage, compact disc read-only memory, optical storage, etc.) containing computer-usable program code.
[0074] Although the present application is disclosed with reference to the preferred embodiments above, it is not intended to limit the present application, and any person skilled in the art can make possible changes and modifications without departing from the spirit and scope of the present application. Therefore, the scope of protection of the present application should be determined by the scope defined in the present application.
Claims
1. A method for generating a defogging image, characterized in that: include: Acquire raw photon echo data and four-channel polarization intensity images; performing noise filtering on the raw photon echo data to obtain denoised photon echo data, the raw photon echo data including photon counts in each time window in each pixel; Calculating a target echo time for each pixel based on the denoised photon echo data; Calculating the target distance for each pixel based on the speed of light and the target echo time; Calculating a backscatter intensity map based on the denoised photon echo data, a target echo time for each pixel, and a preset buffer interval; Calculating a target scattering coefficient based on the backscatter intensity map, a first calibration constant, and a target distance for each pixel; Calculating the atmospheric transmittance of each pixel based on the target scattering coefficient and a preset atmospheric scattering scaling factor; The polarization initial atmospheric transmittance is calculated based on the four-channel polarization intensity image; Calculating a target atmospheric transmittance parameter for each pixel based on the atmospheric transmittance and the polarized initial atmospheric transmittance; Based on the target atmospheric transmittance parameter, the atmospheric scattered light value of each pixel is calculated; A defogging image is obtained by calculation based on the target image, the target atmospheric transmittance parameter and the atmospheric scattered light value.
2. The defogging image generation method according to claim 1, characterized in that: The calculating the polarization initial atmospheric transmittance based on the four-channel polarization intensity image includes: Calculating Stokes parameters based on the four-channel polarization intensity image, wherein the Stokes parameters include a first Stokes parameter, a second Stokes parameter, and a third Stokes parameter; Based on the Stokes parameters, the polarization initial atmospheric transmittance is calculated.
3. The defogging image generation method according to claim 2, characterized in that: The calculating and obtaining Stokes parameters based on the four-channel polarization intensity image includes: Based on the four-channel polarization intensity image, the Stokes parameters are calculated using the following formula: ; Among them, the represents the first Stokes parameter, represents the polarization intensity image of the 0° polarization direction, represents the polarization intensity image of the 45° polarization direction, represents the polarization intensity image of the 90° polarization direction, Represents the polarization intensity image of 135° polarization direction; ; Among them, the represents the second Stokes parameter, the represents the polarization intensity image of the 0° polarization direction, Represents the polarization intensity image of the 90° polarization direction; ; Among them, the represents the third Stokes parameter, the represents the polarization intensity image of the 45° polarization direction, Polarization intensity image showing the 135° polarization direction.
4. The defogging image generation method according to claim 1, characterized in that: The calculating of a target atmospheric transmittance parameter for each pixel based on the atmospheric transmittance and the polarization initial atmospheric transmittance includes: Based on the atmospheric transmittance and the polarization initial atmospheric transmittance, the target atmospheric transmittance parameter of each pixel is calculated using the following formula: ; Among them, the represents the target atmospheric transmittance parameter of the pixel at row i and column j, represents the adaptive weight, represents the atmospheric transmittance, the represents the polarization initial atmospheric transmittance.
5. The defogging image generation method according to claim 4, characterized in that: Before calculating the target atmospheric transmittance parameter of each pixel based on the atmospheric transmittance and the polarized initial atmospheric transmittance, the method further includes: determining a target time window based on the target echo time of each pixel and a preset buffer interval; The adaptive weight is calculated using the following formula: ; Among them, the is the adaptive weight, represents the first signal-to-noise ratio, the represents the second signal-to-noise ratio; ; Among them, the represents the first signal-to-noise ratio, the represents the first calibration coefficient, represents the maximum photon count within the target time window; ; Among them, the represents the second signal-to-noise ratio, the represents the second calibration coefficient, represents median filtering, is the gradient operator, Express Find the gradient, Indicates calculation of the Frobenius norm.
6. The defogging image generation method according to claim 1, characterized in that: The step of calculating a target echo time for each pixel based on the denoised photon echo data includes: ; Among them, the represents the target echo time of the pixel in the i-th row and j-th column, Indicates the maximum value of the formula in the brackets. represents the photon count in the t-th time window in the i-th row and j-th column pixel in the denoised photon echo data, represents the system impulse response function.
7. The defogging image generation method according to claim 6, characterized in that: The backscatter intensity map is calculated based on the denoised photon echo data, the target echo time of each pixel, and the preset buffer interval, including: Based on the denoised photon echo data, the target echo time of each pixel, and the preset buffer interval, the backscatter intensity map is calculated using the following formula: ; Among them, the represents the backscatter intensity map of the pixel in row i and column j, represents the target echo time of the pixel in the i-th row and the j-th column, Indicates the preset buffer interval, the represents the photon count in the tth time window in the pixel in the i-th row and j-th column in the denoised photon echo data.
8. The defogging image generation method according to claim 7, characterized in that: The calculating the target scattering coefficient based on the backscattering intensity map, the first calibration constant and the target distance of each pixel includes: Based on the backscatter intensity map, the first calibration constant, and the target distance of each pixel, the target scattering coefficient is calculated using the following formula: ; Among them, the represents the target scattering coefficient of the pixel in the i-th row and j-th column, represents the first calibration constant, the represents the backscatter intensity map of the pixel in row i and column j, Indicates the target distance of the pixel in the i-th row and j-th column.
9. The defogging image generation method according to claim 8, characterized in that: The calculating the atmospheric transmittance of each pixel based on the target scattering coefficient and a preset atmospheric scattering scaling factor includes: Based on the target scattering coefficient and the preset atmospheric scattering scale factor, the atmospheric transmittance of each pixel is calculated using the following formula: ; Among them, the represents the atmospheric transmittance of the pixel in the i-th row and the j-th column, represents the target scattering coefficient of the pixel in the i-th row and j-th column, Represents the preset atmospheric scattering scale factor, Indicates the target distance of the pixel in the i-th row and j-th column.
10. A defogging image generating device, characterized in that: include: An acquisition module, used to acquire raw photon echo data and four-channel polarization intensity images; a filtering module, configured to perform noise filtering on the raw photon echo data to obtain denoised photon echo data, wherein the raw photon echo data includes a photon count in each time window in each pixel; A first calculation module is used to calculate the target echo time of each pixel based on the denoised photon echo data; A second calculation module is used to calculate the target distance of each pixel according to the speed of light and the target echo time; a third calculation module, configured to calculate a backscatter intensity map based on the denoised photon echo data, a target echo time of each pixel, and a preset buffer interval; a fourth calculation module, configured to calculate a target scattering coefficient based on the backscattering intensity map, a first calibration constant, and a target distance of each pixel; a fifth calculation module, configured to calculate the atmospheric transmittance of each pixel based on the target scattering coefficient and a preset atmospheric scattering scaling factor; A sixth calculation module, configured to calculate a polarization initial atmospheric transmittance based on the four-channel polarization intensity image; a seventh calculation module, configured to calculate a target atmospheric transmittance parameter for each pixel based on the atmospheric transmittance and the polarization initial atmospheric transmittance; an eighth calculation module, configured to calculate an atmospheric scattered light value for each pixel based on the target atmospheric transmittance parameter; A ninth calculation module is configured to calculate a defogging image based on the target image, the target atmospheric transmittance parameter, and the atmospheric scattered light value.
Citation Information
Patent Citations
Image defogging method and device based on polarization characteristics and atmospheric transmission model
CN115393216A
Non-uniform image polarization defogging method based on fog concentration estimation
CN118279192A
Polarization image defogging method based on dark channel principle and multi-scale fusion
CN120634913A
Method for identification of a noise point used for lidar, and lidar system
US20210048515A1