Image defogging method based on unsupervised framework and auxiliary driving system

By employing an unsupervised image dehazing method, utilizing recurrent generative adversarial networks and a comprehensive loss function, the problem of insufficient generalization ability of existing image dehazing models in hazy scenes is solved, achieving high-quality image restoration under severe weather conditions.

CN116362999BActive Publication Date: 2026-04-17JIANGNAN UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
JIANGNAN UNIV
Filing Date
2023-03-01
Publication Date
2026-04-17

AI Technical Summary

Technical Problem

Existing image dehazing models have poor generalization ability in real-world hazy scenes, resulting in poor image quality under adverse weather conditions, which affects the accuracy of vehicle detection and scene understanding.

Method used

An image dehazing method based on an unsupervised framework is adopted. A recurrent generative adversarial network consisting of a generator and a discriminator is used to train the model through a comprehensive loss function to generate hazy images, including adversarial loss, recurrent consistency loss, identity loss and color reconstruction loss. This avoids using real images to calculate perceptual similarity and directly generates hazy images.

Benefits of technology

It exhibits better blur robustness and image detail recovery on small datasets, improves the generalization ability of real foggy images, and achieves end-to-end dehazing processing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116362999B_ABST
    Figure CN116362999B_ABST
Patent Text Reader

Abstract

This application discloses an image dehazing method and an assisted driving system based on an unsupervised framework, relating to the field of transportation technology. This method uses a regularized recurrent generative adversarial network framework and implements a novel method for calculating the comprehensive loss function through adversarial loss, cycle consistency loss, identity loss, and color reconstruction loss. This allows for the full utilization of blurred samples in real foggy images without relying on real foggy images, directly generating fog-free images end-to-end using a cycle consistency approach, and improving generalization ability to real foggy images. The assisted driving system based on the dehazing method can perform image dehazing processing on the original foggy environment image of the vehicle's location, and then display the fog-free environment image on a flexible transparent display screen installed on the vehicle's windshield. This provides the driver with a more accurate view of the vehicle's environment, thus achieving assisted driving.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of transportation technology, and in particular to an image dehazing method based on an unsupervised framework and an assisted driving system. Background Technology

[0002] Image acquisition, monitoring, and display systems based on digital image recognition have a wide range of applications, such as in-vehicle monitoring and display systems for autonomous vehicles and highway image capture systems. However, vehicle driving environments are highly variable. In adverse weather conditions such as fog and haze with low visibility, the acquired images are blurry, have dull colors, and poor visibility, which affects image quality and reduces the accuracy of subsequent high-level vision tasks such as vehicle detection and scene understanding.

[0003] With the development of machine learning technology, machine learning has been gradually applied to image dehazing. However, it is difficult to train image dehazing networks by capturing pairs of foggy and fog-free images from the real world. Due to obvious domain transfer, most existing dehazing models learned from synthetically generated haze images have poor generalization ability in real-world haze scenes, and the dehazing effect is not ideal. Summary of the Invention

[0004] To address the aforementioned problems and technical requirements, this applicant proposes an image dehazing method and an assisted driving system based on an unsupervised framework. The technical solution of this application is as follows:

[0005] An image dehazing method based on an unsupervised framework, the method comprising:

[0006] A model framework for image dehazing, comprising a first recurrent network and a second recurrent network, is constructed. The first recurrent network, consisting of generator Ga, generator Gb, and discriminator Da, is a recurrent generative adversarial network for hazy images. The second recurrent network, consisting of generator Gb, generator Ga, and discriminator Db, is a recurrent generative adversarial network for hazy images. The structures of each generator are identical.

[0007] The model framework based on the image dehazing model involves training the model using a sample dataset according to a comprehensive loss function to obtain the trained image dehazing model. A sample hazy-free image x from the sample dataset is input into the first recurrent network. Generator Ga maps the sample hazy-free image x to a hazy image Ga(x), and generator Gb maps the hazy image Ga(x) to the reconstructed sample hazy image and updates the sample dataset. Similarly, a sample hazy image y from the sample dataset is input into the second recurrent network. Generator Gb maps the sample hazy image y to a hazy image Gb(y), and generator Ga maps the hazy image Gb(y) to the reconstructed sample hazy image and updates the sample dataset. Discriminators Da and Db are used to discriminate the images processed by the image dehazing model.

[0008] The trained image dehazing model is used to perform image dehazing on the foggy image to be processed, and the corresponding fog-free image is obtained.

[0009] Among them, the comprehensive loss function is based on adversarial loss L adv Cyclic consistency loss L cyc Identity loss L ide and color reconstruction loss L col The calculated adversarial loss L adv Cyclic consistency loss L is used to characterize the deviation between the data distribution of the generator's output image and the target data distribution. cyc Identity loss L is used to characterize the deviation between the output image and the input image of a recurrent network. ide The color reconstruction loss L is used to characterize the semantic content deviation between the generator's output image and the input image. col Used to characterize the visual difference between the generator's output image and the input image.

[0010] An image-based defogging-based driver assistance system includes an image acquisition device, an image processing device, and a flexible transparent display screen. The image processing device is electrically connected to the image acquisition device and the flexible transparent display screen. The image acquisition device is installed on the vehicle, and the flexible transparent display screen is installed on the vehicle's windshield.

[0011] The image acquisition device is used to acquire a raw environmental image of the vehicle's location with fog; the image processing device is used to execute the image dehazing method based on the unsupervised framework provided in the first aspect to perform image dehazing processing on the raw environmental image to obtain a fog-free environmental image; the image processing device displays the fog-free environmental image through a flexible transparent display screen.

[0012] The beneficial technical effects of this application are:

[0013] This application discloses an image dehazing method and an assisted driving system based on an unsupervised framework. It uses a regularized recurrent generative adversarial network framework and provides a novel method for calculating the comprehensive loss function. By utilizing a new recurrent self-aware loss algorithm, it avoids using real images to calculate perceptual similarity. Through adversarial loss, recurrent consistency loss, identity loss, and color reconstruction loss, it can optimize the dehazing effect from different dimensions. Thus, it can make full use of blurred samples in real foggy images without relying on real foggy images. It directly generates fog-free images end-to-end using a recurrent consistency method, realizing the dehazing function and improving the generalization ability to real foggy images.

[0014] Both visual and numerical experimental results demonstrate that, even on very small datasets, the proposed method outperforms existing mainstream methods in terms of blur robustness and image detail recovery.

[0015] This application also provides an assisted driving system based on the defogging method of this application, which can perform image defogging processing on the original foggy environment image of the vehicle's location to obtain a fog-free environment image, and then display the fog-free environment image through a flexible transparent display screen installed on the vehicle's windshield, thereby providing the driver with a more accurate view of the vehicle's environment and achieving assisted driving. Attached Figure Description

[0016] Figure 1 This is a structural diagram of the image dehazing model used in the unsupervised framework-based image dehazing method of this application.

[0017] Figure 2 This is a schematic diagram of the information flow for calculating the comprehensive loss function during model training in this application.

[0018] Figure 3 This is a structural diagram of the generator in one embodiment.

[0019] Figure 4 This is a structural diagram of the residual module included in the generator in one embodiment.

[0020] Figure 5 This is a structural diagram of the discriminator in one embodiment. Detailed Implementation

[0021] The specific embodiments of this application will be further described below with reference to the accompanying drawings.

[0022] This application discloses an image dehazing method based on an unsupervised framework, which includes the following steps:

[0023] Step 1: Build the model framework for the image dehazing model. Please refer to [reference needed]. Figure 1 The image dehazing model framework in this application includes a first recurrent network and a second recurrent network.

[0024] The first recurrent network consists of a generator Ga, a generator Gb, and a discriminator Da, and is a recurrent generative adversarial network for fog-free images. The second recurrent network consists of a generator Gb, a generator Ga, and a discriminator Db, and is a recurrent generative adversarial network for foggy images.

[0025] The generator Ga in the first recurrent network is the same as the generator Ga in the second recurrent network; both are used to map the hazy image to the corresponding hazy image. Similarly, the generator Gb in the second recurrent network is also the same as the generator Gb in the second recurrent network; both are used to map the hazy image to the corresponding hazy image. The structures of all generators in both recurrent networks are identical. The discriminator Da in the first recurrent network and the discriminator Db in the second recurrent network also have identical structures.

[0026] Step 2: Based on the established image dehazing model framework, and using the sample dataset according to the comprehensive loss function L... total The trained image dehazing model is obtained by training the model.

[0027] The initial sample dataset includes several hazy images x and hazy images y. The hazy images x and hazy images y can be unpaired, meaning that there is no need to use paired hazy images and hazy images for training, which reduces the difficulty of obtaining the sample dataset.

[0028] The sample haze-free image x and sample haze image y from the sample dataset are simultaneously fed into the image dehazing model. The sample haze-free image x is input into the first recurrent network. In the first recurrent network, the generator Ga maps the sample haze-free image x to the haze image Ga(x), and the generator Gb maps the haze image Ga(x) to the reconstructed sample haze-free image Gb(Ga(x)).

[0029] The sample hazy image y is input into the second recurrent network. In the second recurrent network, the generator Gb maps the sample hazy image y to the hazy image Gb(y), and the generator Ga maps the hazy image Gb(y) to the reconstructed sample hazy image Ga(Gb(y)).

[0030] Discriminators Da and Db are used to discriminate images processed by the image dehazing model. Specifically, discriminator Da discriminates the input sample hazy image y to obtain discriminant result Da(y) and the hazy image Ga(x) to obtain discriminant result Da(Ga(x)). Discriminator Db discriminates the input sample hazy image x to obtain discriminant result Db(x) and the hazy image Gb(y) to obtain discriminant result Db(Gb(y)).

[0031] Based on the image processed by the first recurrent network and the discrimination result of discriminator Da, combined with the image processed by the second recurrent network and the discrimination result of discriminator Db, the comprehensive loss function L is calculated. total When based on the comprehensive loss function L total Upon completion of training, the trained image dehazing model is obtained. This is then determined based on the comprehensive loss function L. totalWhen training is not yet complete, the sample dataset is updated using the reconstructed hazy-free image Gb(Ga(x)) obtained from the first recurrent network. This reconstructed hazy-free image Gb(Ga(x)) serves as the new hazy-free image x in the sample dataset. Simultaneously, the sample dataset is updated using the reconstructed hazy image Ga(Gb(y)) obtained from the second recurrent network. This reconstructed hazy image Ga(Gb(y)) serves as the new hazy image y in the sample dataset. Then, the updated hazy-free image x and hazy image y are simultaneously fed into the image dehazing model, and the above recurrent training process is repeated. From the second recurrent iteration onwards, the sample dataset includes not only the initial hazy-free and hazy images but also the reconstructed hazy and hazy images obtained during previous recurrent iterations.

[0032] This application improves the comprehensive loss function L. total The calculation method, the comprehensive loss function L total Based on adversarial loss L adv Cyclic consistency loss L cyc Identity loss L ide and color reconstruction loss L col Calculated. In one embodiment, the comprehensive loss function L total The calculation method is as follows:

[0033] L total =λ1L adv +λ2L cyc +λ3L ide +λ4L col ;

[0034] Where λ1, λ2, λ3, and λ4 are weighting coefficients, and λ1+λ2+λ3+λ4=1. The four types of losses are described below for reference. Figure 2 Calculation diagram:

[0035] (1) Countering loss L adv The deviation between the data distribution of the generator's output image and the target data distribution is characterized by the adversarial loss L. adv During iterative training, the data distribution of the generator's output image can be matched with the target data distribution in the target domain.

[0036] In one embodiment, combating loss L adv The adversarial loss L is calculated based on the discrimination results Da(y) and Da(Ga(x)) of discriminator Da in the first recurrent network, and the discrimination results Db(x) and Db(Gb(y)) of discriminator Db in the second recurrent network. adv The calculation method is as follows:

[0037] L adv =L adv (G)+L adv (Da)+L adv (Db);

[0038]

[0039] Specifically, when the discriminator Da determines that the foggy image Ga(x) is included in the initialized sample dataset, that is, when the foggy image Ga(x) is a real image contained in the initialized sample dataset, Da(Ga(x)) = 1 is determined; otherwise, Da(Ga(x)) = 0. This represents the calculation of (Da(Ga(x))-1) for all samples of the haze-free image x. 2 The mathematical expectation, This represents the calculation of (Da(Ga(x))) for all samples of the haze-free image x. 2 The mathematical expectation.

[0040] When the discriminator Da determines that the foggy image y is included in the initialized sample dataset, Da(y) = 1; otherwise, Da(y) = 0. This represents the calculation of (Da(y)-1) for all sample foggy images y. 2 The mathematical expectation.

[0041] When the discriminator Db determines that the fog-free image Gb(y) is included in the initialized sample dataset, it determines that Db(Gb(y)) = 1; otherwise, Db(Gb(y)) = 0. This represents the calculation of (Db(Gb(y))-1) for all sample fogged images y. 2 The mathematical expectation, This represents the calculation of (Db(Gb(y))) for all samples of the fogged image y. 2 The mathematical expectation.

[0042] If the discriminator Db determines that the sample haze-free image x is included in the initialized sample dataset, then Db(x) = 1; otherwise, Db(x) = 0. This represents the calculation of (Db(x)-1) for all samples of the haze-free image x. 2 The mathematical expectation.

[0043] (2) Cycle consistency loss L cyc The deviation between the output image and the input image of a recurrent network is characterized by the recurrent consistency loss L. cycDuring iterative training, the output image of the recurrent network can be closely matched with the input image, that is, the reconstructed sample haze image Gb(Ga(x)) output by the first recurrent network approximates the input sample haze image x, and the reconstructed sample haze image Ga(Gb(y)) output by the second recurrent network approximates the input sample haze image y.

[0044] In one embodiment, the cycle consistency loss L cyc The cycle consistency loss L is calculated based on the sample haze-free image x input to the first recurrent network and the corresponding reconstructed sample haze-free image Gb(Ga(x)) output, and the sample haze-bearing image y input to the second recurrent network and the corresponding reconstructed sample haze-bearing image Ga(Gb(y)) output. cyc The calculation method is as follows:

[0045]

[0046] Where ||Gb(Ga(x))-x||1 is the L1 loss between the reconstructed hazy image Gb(Ga(x)) and the input hazy image x. Let ||Gb(Ga(x))-x||1 be the mathematical expectation of the hazy image x. ||Ga(Gb(y))-y||1 is the L1 loss between the reconstructed hazy image Ga(Gb(y)) and the input hazy image y. Let ||Ga(Gb(y))-y||1 be the mathematical expectation of the hazy image y for all samples.

[0047] (3) Identity loss L ide The semantic content deviation between the generator's output image and the input image is characterized by identity loss L. ide During iterative training, the generator's output image can be made to have the same structure as the input image, thus ensuring that the fog-free image output by the generator can retain the semantic content of the original fog-bearing image, thereby improving image quality.

[0048] In one embodiment, identity loss L ide The identity loss L is calculated based on the sample hazy image x input to the first recurrent network and the hazy image Ga(x) obtained after mapping by the generator Ga, and the sample hazy image y input to the second recurrent network and the hazy image Gb(y) obtained after mapping by the generator Gb. ide The calculation method is as follows:

[0049]

[0050] Where ||Gb(y)-y||1 represents the L1 loss calculated between the output image Gb(y) of the generator Gb in the second recurrent network and the input sample fogged image y. Let ||Gb(y)-y||1 represent the mathematical expectation of calculating the hazy image y for all samples. Let ||Ga(x)-x||1 represent the L1 loss of the output image Ga(x) of the generator Ga in the first recurrent network compared to the input hazy image x. Let ||Ga(x)-x||1 be the mathematical expectation of the hazy image x for all samples.

[0051] (4) Color reconstruction loss L col Used to characterize the visual difference between the generator's output image and the input image. This is achieved through color reconstruction loss L. col During iterative training, the generator's output image can be made to have the same visual effect as the input image, thereby improving image quality.

[0052] In one embodiment, the color reconstruction loss L col Based on the sample hazy image x input to the generator Ga in the first recurrent network, the hazy image Ga(x) output by the generator Ga in the first recurrent network, the sample hazy image y input to the generator Gb in the second recurrent network, and the hazy image Gb(y) output by the generator Gb in the second recurrent network.

[0053] Furthermore, to compensate for the dark color of the generator's output images, each image is converted to the LAB color space, and the color reconstruction loss L is constructed and calculated using the color components of the three channels of each image in the LAB color space. col Furthermore, L1 loss is calculated for the L channel, and Huber loss is calculated for the A and B channels. Color reconstruction loss L... col The calculation method is as follows:

[0054]

[0055] Where ||L(Gb(y))-L(y)||1 represents the L1 loss calculated between the L-channel component L(Gb(y)) of the hazy image Gb(y) in the LAB color space and the L-channel component L(y) of the sample hazy image y in the LAB color space. ||A(Gb(y)-A(y))|| H This represents the Huber loss calculated by comparing the A-channel component A(Gb(y)) of the hazy image Gb(y) in the LAB color space with the A-channel component A(y) of the sample hazy image y in the LAB color space. ||B(Gb(y)-B(y))|| HThis represents the Huber loss calculated between the B channel component B(Gb(y)) of the hazy image Gb(y) in the LAB color space and the B channel component B(y) of the sample hazy image y in the LAB color space.

[0056] ||L(Ga(x))-L(x)||1 represents the L1 loss of the L-channel component L(Ga(x)) of the hazy image Ga(x) in the LAB color space and the L-channel component L(x) of the sample hazy image x in the LAB color space. ||A(Ga(x)-A(x))|| H This represents the Huber loss calculated by comparing the A-channel component A(Ga(x)) of the hazy image Ga(x) in the LAB color space with the A-channel component A(x) of the sample hazy image x in the LAB color space. ||B(Ga(x)-B(x))|| H This represents the Huber loss calculated for the B channel component B(Ga(x)) of the hazy image Ga(x) in the LAB color space and the B channel component B(x) of the sample hazy image x in the LAB color space.

[0057] E y~Pdata(y) [||L(Gb(y))-L(y)||1+||A(Gb(y)-A(y))|| H +||B(Gb(y)-B(y))|| H The expression ] represents the calculation of ||L(Gb(y))-L(y)||1+||A(Gb(y)-A(y))|| for all sample fogged images y. H +||B(Gb(y)-B(y))|| H The mathematical expectation of E. x~Pdata(x) [||L(Ga(x))-L(x)||1+||A(Ga(x)-A(x))|| H +||B(Ga(x)-B(x))|| H ] represents the calculation of ||L(Ga(x))-L(x)||1+||A(Ga(x)-A(x))|| for all samples of the haze-free image x. H +||B(Ga(x)-B(x))|| H The mathematical expectation.

[0058] This application, in addition to specifying the comprehensive loss function L used, total In addition to the improvements, the structure of the generator used in the image dehazing model was also optimized. Please refer to [link / reference]. Figure 3Each generator comprises an encoding module, a feature extraction module, and a decoding module cascaded sequentially from input to output. The encoding module includes a cascaded initial layer, a first downsampling layer, and a second downsampling layer. The decoding module includes a cascaded first upsampling layer, a second upsampling layer, and an activation layer. The feature extraction module includes several cascaded residual modules; the output of the second downsampling layer is connected to the first upsampling layer via the feature extraction module. The activation layer is constructed based on the Tanh activation function and includes a cascaded convolutional layer with a 7x7 kernel and the Tanh activation function. The output of the second downsampling layer is also connected to the input of the first upsampling layer, and the output of the first downsampling layer is also connected to the input of the second upsampling layer. The output of the initial layer is also connected to the input of the activation layer.

[0059] In one embodiment, the first downsampling layer, the second downsampling layer, the first upsampling layer, and the second upsampling layer each embed a GAM module at their output terminals. Please refer to [the relevant documentation / reference]. Figure 3 The initial layer consists of cascaded convolutional layers with 7x7 kernels, a normalization function, and ReLU, arranged sequentially from input to output. The first downsampling layer consists of cascaded convolutional layers with 3x3 kernels, a normalization function, ReLU, and a GAM module, arranged sequentially from input to output. The second downsampling layer consists of cascaded convolutional layers with 3x3 kernels, a normalization function, ReLU, and a GAM module, arranged sequentially from input to output. The first upsampling layer consists of cascaded convolutional layers with 3x3 kernels, a normalization function, ReLU, and a GAM module, arranged sequentially from input to output. The second upsampling layer consists of cascaded convolutional layers with 3x3 kernels, a normalization function, ReLU, and a GAM module, arranged sequentially from input to output.

[0060] Each residual module is built upon the res2net module. The residual module is obtained by embedding a GAM module after a 1x1 convolutional layer at the output of the res2net module. Please refer to [reference needed]. Figure 4 The standard Res2net module features hierarchical residual connections, allowing for finer-grained representation of multi-scale features and increasing the receptive field of each network layer. The standard Res2net module performs a 1x1 convolution on the input image and then divides it into multiple blocks based on the number of feature channels. For example... Figure 4 Taking the image as an example of dividing the image into four equal parts, feature extraction is performed, and finally, after passing through a 1*1 convolution, the image is combined with the input image of the res2net module to generate the output. This application adds a GAM module after the 1*1 convolution at the output end of the res2net module, so that the image output from the 1*1 convolution at the output end is then passed through the GAM module and combined with the input image of the residual module as the output of the residual module.

[0061] This application embeds a GAM module in the downsampling layer, upsampling layer, and residual module of the generator, enabling the image dehazing model to adaptively learn weights from different feature maps, thereby improving the dehazing capability of the image dehazing model.

[0062] In one embodiment, a discriminator is constructed using full convolution, employing a spectral normalization convolutional layer instead of a traditional convolutional layer to make the training process more stable. Please refer to [reference needed]. Figure 5 The structure of each discriminator shown comprises, from input to output, a cascaded sequence of a 6x6 kernel spectral normalization convolutional layer, ReLU, a 6x6 kernel spectral normalization convolutional layer, an instantiation normalization layer, ReLU, a 3x3 kernel spectral normalization convolutional layer, an instantiation normalization layer, ReLU, a 3x3 kernel spectral normalization convolutional layer, an instantiation normalization layer, ReLU, a 3x3 kernel spectral normalization convolutional layer, and a Sigmoid activation function. Four non-linear ReLUs, three instantiation normalization layers, and one Sigmoid activation function are used to output a 64x64 block. Finally, the values ​​of these blocks are used to determine whether the image is included in the initialized sample dataset or was generated by the generator, thus achieving discrimination. A soft likelihood estimation method is employed to encourage the discriminator to focus on detailed features of the input image, causing it to pay more attention to changes in low-probability regions. The generator produces images with rich detail, thereby improving the overall quality of the final dehazed image. The weight matrix is ​​obtained by calculating the proximity of each block to the lowest likelihood block. While solving for the weight matrix, the SoftMax / SoftMin functions are used to smooth the max / min objective function. The weight matrix is ​​multiplied by the probability of each block and summed to produce the final output. The formula for calculating the discriminator's final output P is as follows: W represents the weight of each block i, and the total weight of all blocks i. i Construct a weight matrix. i α represents the patch-region likelihood of block i, and α represents the SoftMax or SoftMin operation in the weight matrix calculation process. Set α = 1 to calculate the SoftMax function, and set α = -1 to calculate the SoftMin function.

[0063] Based on the image dehazing method based on the unsupervised framework of this application, this application also provides an image dehazing-based driver assistance system, which can be used to assist driving using the image dehazing method of this application. The driver assistance system includes an image acquisition device, an image processing device, and a flexible transparent display screen. The image processing device is electrically connected to the image acquisition device and the flexible transparent display screen. The image acquisition device is installed on the vehicle, and the flexible transparent display screen is installed on the windshield of the vehicle.

[0064] The image acquisition device is used to acquire a raw image of the vehicle's surroundings, which is foggy. The image processing device is used to execute the unsupervised frame-based image dehazing method provided in this application to dehaze the raw image, resulting in a fog-free image. This fog-free image is then displayed on a flexible transparent display screen and projected onto the windshield to assist the driver in understanding the vehicle's environment and thus provide driving assistance.

[0065] The above descriptions are merely preferred embodiments of this application, and this application is not limited to the above embodiments. It is understood that other improvements and variations that can be directly derived or conceived by those skilled in the art without departing from the spirit and concept of this application should be considered to be included within the protection scope of this application.

Claims

1. An image defogging method based on an unsupervised framework, characterized in that, The method includes: Construct a model framework for image dehazing that includes a first recurrent network and a second recurrent network, and a generator. Generator and discriminator The first recurrent network is a recurrent generative adversarial network for fog-free images, with the generator... Generator and discriminator The second recurrent network is a recurrent generative adversarial network for fogged images, with each generator having the same structure. Based on the model framework of the image dehazing model, the trained image dehazing model is obtained by training the model using a sample dataset according to a comprehensive loss function, and the sample dataset contains haze-free images. After inputting the first recurrent network, the generator haze-free image of the sample Mapped to a foggy image generator Foggy images Mapped to reconstructed hazy-free sample images and the sample dataset is updated; the sample dataset contains hazy sample images. After inputting the second recurrent network, the generator Sample with fog image Mapped to a fog-free image generator Haze-free image Mapped to the reconstructed sample hazy image and the sample dataset updated, discriminator and discriminator Used to identify images processed by the image dehazing model; The trained image dehazing model is used to perform image dehazing on the foggy image to be processed, and the corresponding fog-free image is obtained. The comprehensive loss function is based on adversarial loss. Cyclic consistency loss Loss of identity and color reconstruction loss Calculations show that the resistance loss Cycle consistency loss is used to characterize the deviation between the data distribution of the generator's output image and the target data distribution. Identity loss is used to characterize the deviation between the output image and the input image of a recurrent network. Color reconstruction loss is used to characterize the semantic content deviation between the generator's output image and the input image. Used to characterize the visual effect deviation between the generator's output image and the input image; Color reconstruction loss Based on the generator in the first recurrent network Haze-free sample images The generator in the first recurrent network Output image with fog Input the generator in the second recurrent network Sample foggy images The generator in the second recurrent network output haze-free image The color components of the three channels in the LAB color space were calculated; color reconstruction loss. The calculation method is as follows: ; in, Indicates the calculation of foggy images L channel components in the LAB color space With sample fogged images L channel components in the LAB color space L1 loss; Indicates the calculation of foggy images A channel component in LAB color space With sample fogged images A channel component in LAB color space Huber's losses; Indicates the calculation of foggy images B channel component in LAB color space With sample fogged images B channel component in LAB color space Huber's losses; Indicates the calculation of foggy images L channel components in the LAB color space Compared with the haze-free image of the sample L channel components in the LAB color space L1 loss; Indicates the calculation of foggy images A channel component in LAB color space Compared with the haze-free image of the sample A channel component in LAB color space Huber's losses; Indicates the calculation of foggy images B channel component in LAB color space Compared with the haze-free image of the sample B channel component in LAB color space Huber's losses; This indicates the calculation of all sample fogged images. of The mathematical expectation, This indicates the calculation of all sample haze-free images. of The mathematical expectation.

2. The method according to claim 1, characterized in that, The comprehensive loss function for: ; in, , , , All are weighted coefficients and .

3. The method according to claim 1, characterized in that, Loss of identity The calculation method is as follows: ; in, Represents a computation generator Output image Compared with the input sample foggy image L1 loss, This indicates the calculation of all sample fogged images. of The mathematical expectation; Represents a computation generator Output image Compared with the input sample haze image L1 loss, This indicates the calculation of all sample haze-free images. of The mathematical expectation.

4. The method according to claim 1, characterized in that, Combating losses and cycle consistency loss The calculation method is as follows: ; ; Among them, when the discriminator Identify and determine foggy images When included in the initialized sample dataset, determine ,otherwise ; This indicates the calculation of all sample haze-free images. of The mathematical expectation, This indicates the calculation of all sample haze-free images. of The mathematical expectation; When the discriminator Identify and determine fog-free images When included in the initialized sample dataset, determine ,otherwise ; This indicates the calculation of all sample fogged images. of The mathematical expectation, This indicates the calculation of all sample fogged images. of The mathematical expectation; When the discriminator Identify and determine the image of the sample with fog When included in the initialized sample dataset, determine ,otherwise , This indicates the calculation of all sample fogged images. of The mathematical expectation; When the discriminator Identify and determine the image of the sample without fog When included in the initialized sample dataset, determine ,otherwise , This indicates the calculation of all sample haze-free images. of The mathematical expectation; This represents the reconstructed, fog-free sample image output by the first recurrent network. The sample haze image input to the first recurrent network L1 loss, This indicates the calculation of all sample haze-free images. of The mathematical expectation; This represents the reconstructed sample hazy image calculated from the output of the second recurrent network. Sample foggy images input to the second recurrent network L1 loss, This indicates the calculation of all sample fogged images. of The mathematical expectation.

5. The method according to claim 1, characterized in that, Each generator includes an encoding module, a feature extraction module, and a decoding module that are cascaded from input to output; The encoding module includes an initial layer, a first downsampling layer, and a second downsampling layer cascaded in sequence; the decoding module includes a first upsampling layer, a second upsampling layer, and an activation layer cascaded in sequence; the feature extraction module includes several residual modules cascaded in sequence; the output of the second downsampling layer is connected to the first upsampling layer through the feature extraction module; the activation layer is constructed based on the Tanh activation function. The output of the second downsampling layer is also connected to the input of the first upsampling layer, the output of the first downsampling layer is also connected to the input of the second upsampling layer, and the output of the initial layer is also connected to the input of the activation layer.

6. The method according to claim 5, characterized in that, Each residual module is constructed based on the res2net module. The residual module has a GAM module embedded after the 1*1 convolutional layer at the output of the res2net module, and the output of the GAM module and the input of the res2net module are combined as the output of the res2net module.

7. The method according to claim 5, characterized in that, The first downsampling layer, the second downsampling layer, the first upsampling layer, and the second upsampling layer each have a GAM module embedded at their output terminals.

8. A driver assistance system based on image dehazing, characterized in that, The driver assistance system includes an image acquisition device, an image processing device, and a flexible transparent display screen. The image processing device is electrically connected to the image acquisition device and the flexible transparent display screen. The image acquisition device is installed on the vehicle, and the flexible transparent display screen is installed on the windshield of the vehicle. The image acquisition device is used to acquire a foggy original environmental image of the environment in which the vehicle is located; the image processing device is used to perform image dehazing processing on the original environmental image by executing any of the unsupervised frame-based image dehazing methods described in claims 1-7 to obtain a fog-free environmental image; the image processing device displays the fog-free environmental image through the flexible transparent display screen.

Citation Information

Patent Citations

  • Image defogging method based on cyclic generative adversarial network

    CN115330620A