Papers
Topics
Authors
Recent
Search
2000 character limit reached

DFDNet: Frequency-Guided Nighttime Deflare

Updated 5 July 2026
  • The paper introduces a de-flare network that leverages frequency discrepancies to decouple flare artifacts from scene content in nighttime images.
  • It integrates a global dynamic frequency-domain guidance module with a local detail guidance mechanism to suppress large-scale flares while repairing fine details.
  • Experimental results demonstrate significant improvements in PSNR and SSIM, surpassing state-of-the-art methods on both synthetic and real-world datasets.

Searching arXiv for the specified paper to ground the article in the cited source. Dynamic Frequency-Guided De-Flare Network (DFDNet) is a nighttime image restoration method for removing flare artifacts produced by strong light sources while preserving scene content and repairing structural damage near the light source. It is presented as a de-flare network that exploits the observation that challenging flare artifacts exhibit more significant discrepancies from reference images in the frequency domain than in the spatial domain. On that basis, DFDNet decouples content information from flare artifacts in the frequency domain and combines a global dynamic frequency-domain guidance mechanism with a local detail guidance mechanism to address both large-scale flare suppression and fine-grained restoration (Xue et al., 23 Jul 2025).

1. Problem setting and motivating observation

Nighttime photography is frequently degraded by flare artifacts caused by strong light sources. These artifacts significantly reduce visual quality and also affect downstream tasks. Existing methods are described as continuing to struggle with two specific difficulties: removing large-scale flare artifacts and repairing structural damage in regions near the light source (Xue et al., 23 Jul 2025).

The central observation behind DFDNet is that these difficult flare artifacts show more significant discrepancies from reference images in the frequency domain than in the spatial domain. This motivates a restoration strategy that does not rely exclusively on spatial-domain processing, but instead explicitly models frequency characteristics in order to separate flare information from content information. In this formulation, flare removal is treated not merely as local artifact suppression but as a frequency-guided disentanglement problem.

This suggests that DFDNet is positioned within a broader class of restoration models that use spectral structure to distinguish degradations from semantic content, while also recognizing that frequency-domain filtering alone is insufficient for preserving the delicate structure around intense light sources. The addition of local feature alignment addresses that second requirement.

2. Network architecture

DFDNet is built on a U-shaped Transformer (Uformer) backbone augmented with two complementary components: Global Dynamic Frequency-Domain Guidance (GDFG) modules and a Local Detail Guidance Module (LDGM) (Xue et al., 23 Jul 2025). The architecture follows an encoder–bottleneck–decoder topology with GDFG inserted throughout the hierarchy.

The input flare-corrupted image is denoted by I∈R3×H×WI\in\mathbb{R}^{3\times H\times W}. It is first passed through a 3×33\times 3 convolution followed by LeakyReLU to produce low-level features E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}. The encoding path contains four stages. At stage ii, the incoming feature Ei−1E_{i-1} is processed by GDFG and then downsampled to form EiE_i, where downsampling is implemented using a 4×44\times 4 convolution with stride $2$. In the bottleneck, another GDFG module isolates flare signatures in latent space. The decoding path mirrors the encoder: each stage upsamples with a 2×2\times transposed convolution, concatenates the result with the corresponding encoder feature, applies GDFG, and produces Di−1D_{i-1}. A final 3×33\times 30 convolution outputs both the restored image 3×33\times 31 and an estimated flare map 3×33\times 32 (Xue et al., 23 Jul 2025).

LDGM is applied on top of the final output and operates on small patches near the light source between 3×33\times 33 and the ground-truth clean image 3×33\times 34. In architectural terms, DFDNet therefore combines global frequency-domain guidance distributed across the backbone with local patch-level supervision at the output stage. The division of labor is explicit: GDFG targets flare/content separation, whereas LDGM targets preservation of local details that are vulnerable to over-smoothing during flare removal.

3. Global Dynamic Frequency-Domain Guidance

The GDFG module dynamically learns per-channel Fourier filters to suppress flare frequencies while preserving content (Xue et al., 23 Jul 2025). Its construction consists of three parts: discrete Fourier analysis and synthesis, learnable multichannel frequency weighting, and residual feature transformation.

For a feature map 3×33\times 35, GDFG first uses the discrete Fourier transform and inverse discrete Fourier transform: 3×33\times 36

3×33\times 37

The module initializes 3×33\times 38 complex filters 3×33\times 39, each in E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}0. Given input features E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}1, it computes per-channel global averages

E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}2

The resulting vector E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}3 is then passed through a two-layer MLP with LayerNorm and StarReLU: E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}4 After reshaping E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}5 into logits E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}6, a softmax is applied across the filter index E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}7: E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}8 This yields a dynamic channel-specific frequency weight

E0∈RC×H×WE_0\in\mathbb{R}^{C\times H\times W}9

Frequency filtering is then performed channel-wise: ii0 The final GDFG output is formed through residual addition followed by LayerNorm and MLP: ii1

The functional role of GDFG is to guide the network to perceive the frequency characteristics of flare artifacts by dynamically optimizing global frequency-domain features, thereby separating flare information from content information (Xue et al., 23 Jul 2025). A plausible implication is that the dynamic weighting over a small bank of complex filters allows the module to adapt to different flare patterns without fixing a single global frequency prior.

4. Local Detail Guidance Module

The Local Detail Guidance Module is designed via a contrastive learning strategy that aligns local features of the light source with the reference image, reduces local detail damage from flare removal, and improves fine-grained image restoration (Xue et al., 23 Jul 2025). It addresses the failure mode in which aggressive artifact suppression can damage structures in the vicinity of bright sources.

LDGM operates on local patches around the light source in the restored image ii2 and the clean reference ii3. A set of ii4 patches is randomly cropped from the same spatial region. The query ii5 is a patch feature from ii6, the positive ii7 is the same-position patch from ii8, and the negatives ii9 are all other patches, including background and halos. These are mapped to unit-normalized vectors Ei−1E_{i-1}0, and cosine similarity is defined as

Ei−1E_{i-1}1

The contrastive objective is the InfoNCE loss with temperature Ei−1E_{i-1}2: Ei−1E_{i-1}3

In effect, LDGM enforces correspondence between restored and reference local patches while pushing the restored representation away from mismatched local structures. This suggests that the module is intended to preserve discriminative detail specifically in regions where flare corruption is most severe, rather than uniformly over the full image.

5. Training objective and optimization

During training, the flare-corrupted image is decomposed as Ei−1E_{i-1}4, and the network Ei−1E_{i-1}5 predicts Ei−1E_{i-1}6 (Xue et al., 23 Jul 2025). The training objective combines three losses: perceptual/content reconstruction, frequency-domain consistency, and local detail guidance.

The perceptual/content reconstruction loss is

Ei−1E_{i-1}7

The frequency-domain consistency loss applies the Fourier transform Ei−1E_{i-1}8 to the restored and ground-truth images, decomposes them into amplitude and phase, and penalizes both: Ei−1E_{i-1}9

EiE_i0

Together with the local detail guidance term EiE_i1, the combined loss is

EiE_i2

with default EiE_i3 and EiE_i4.

The implementation details specify a Uformer backbone with four down/up stages and feature dimension EiE_i5 per stage, commonly EiE_i6. The GDFG filter count is EiE_i7, and the MLP hidden size is EiE_i8. Training uses input size EiE_i9, batch size 4×44\times 40, and Adam with 4×44\times 41, initial learning rate 4×44\times 42, halved at iterations 4×44\times 43 and 4×44\times 44, with a total of 4×44\times 45 iterations (Xue et al., 23 Jul 2025).

The data augmentation protocol follows Flare7K++ and includes inverse gamma correction with 4×44\times 46 on both scene and flare; random rotation in 4×44\times 47; translation of 4×44\times 48 px; shear of 4×44\times 49; scale in $2$0; blur with $2$1; horizontal and vertical flip; global color shift of $2$2; per-channel RGB scaling in $2$3; and additive Gaussian noise with $2$4 (Xue et al., 23 Jul 2025).

6. Experimental findings

The reported experimental results show that DFDNet outperforms existing state-of-the-art methods in performance (Xue et al., 23 Jul 2025). On Flare7K++ real and synthetic paired tests, PSNR increases from $2$5 dB to $2$6 dB on real data and from $2$7 dB to $2$8 dB on synthetic data. SSIM reaches $2$9 on real data and 2×2\times0 on synthetic data. G-PSNR improves by approximately 2×2\times1 dB on real data and approximately 2×2\times2 dB on synthetic data, while S-PSNR improves by approximately 2×2\times3 dB on real data and approximately 2×2\times4 dB on synthetic data (Xue et al., 23 Jul 2025).

Qualitative comparisons indicate stronger suppression of large glare and streak artifacts and superior preservation of light-source details, including in spatial and frequency-spectrum comparisons. Relative to WaveDM and FPro, identified as FFT-based methods, DFDNet is reported to preserve mid- and high-frequency textures while suppressing low-frequency flare noise more effectively (Xue et al., 23 Jul 2025).

On unpaired real-world tests, DFDNet achieves the best NIQE, MUSIQ, and PI on two challenging consumer and real flare datasets, which is presented as evidence of robust generalization to varying camera hardware and unseen flare patterns (Xue et al., 23 Jul 2025). For downstream tasks, pre- versus post-deflare evaluation with YOLOv7 and SAM shows markedly improved detection recall and segmentation accuracy in nighttime scenes.

The ablation studies isolate the contribution of the architectural and loss components. GDFG alone yields PSNR 2×2\times5 dB versus a baseline of 2×2\times6 dB. LDGM alone gives an S-PSNR gain of 2×2\times7 dB. Adding 2×2\times8 yields PSNR 2×2\times9 dB. The full model reaches Di−1D_{i-1}0 dB. The optimal filter count is reported as Di−1D_{i-1}1, the best LDGM temperature is Di−1D_{i-1}2, and the preferred loss weights are Di−1D_{i-1}3 and Di−1D_{i-1}4 (Xue et al., 23 Jul 2025).

Setting Reported result
Baseline PSNR Di−1D_{i-1}5 dB
GDFG alone PSNR Di−1D_{i-1}6 dB
LDGM alone S-PSNR Di−1D_{i-1}7 dB
Adding Di−1D_{i-1}8 PSNR Di−1D_{i-1}9 dB
Full model PSNR 3×33\times 300 dB

These results situate DFDNet as a method whose effectiveness depends on the interaction of global spectral guidance and local contrastive alignment rather than on either component alone.

7. Interpretation, scope, and relation to neighboring approaches

DFDNet is defined by the combination of a learnable, dynamic frequency-domain filter bank in GDFG and local contrastive feature alignment in LDGM (Xue et al., 23 Jul 2025). Within the de-flaring literature, its distinguishing premise is that flare removal benefits from explicit frequency-domain decoupling of artifacts from content, especially for large-scale degradations that are difficult to separate in purely spatial representations.

A common oversimplification would be to view DFDNet as only a Fourier filtering method. The reported design does not support that reduction. GDFG performs dynamic per-channel weighting in the Fourier domain, but its output is embedded inside a U-shaped Transformer with residual processing, and LDGM adds patch-wise contrastive supervision near the light source. Conversely, it would also be incomplete to interpret the method as purely local restoration, because the architecture repeatedly applies frequency-guided processing at every encoding and decoding stage and again in the bottleneck.

The reported comparisons with WaveDM and FPro specifically emphasize preservation of mid/high-frequency textures together with suppression of low-frequency flare noise (Xue et al., 23 Jul 2025). This suggests that DFDNet is intended to mediate between two competing restoration demands: elimination of broad, diffuse flare structures and retention of fine local signal. The inclusion of both amplitude and phase in 3×33\times 301 further indicates that the method treats frequency information as structurally informative rather than as a magnitude-only regularizer.

The paper also states that code is available at the project repository, indicating an implementation pathway for reproduction and extension (Xue et al., 23 Jul 2025). A plausible implication is that subsequent work may examine whether dynamic frequency guidance generalizes beyond de-flaring to adjacent restoration problems in which degradations exhibit clearer separability in the spectral domain than in the spatial domain.

Definition Search Book Streamline Icon: https://streamlinehq.com
References (1)

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Dynamic Frequency-Guided Deflare Network (DFDNet).