on the effectiveness of spectral discriminators for perceptual quality improvement

Xin Luo, Yunan Zhu, Shunxin Xu, Dong LiuOpenReview 2023

Introduction

Generative Adversarial Networks (GANs) have become the standard for Image Super-Resolution (SR), primarily due to their ability to generate high-frequency details that traditional mean-squared error (MSE) based methods often smooth over. However, a persistent challenge remains: the "frequency problem." While GAN-generated images appear sharp, their mathematical spectra often deviate significantly from real-world data, frequently manifesting as "checkerboard" artifacts or unnatural high-frequency noise.

This research investigates the underlying causes of these spectral discrepancies and proposes DualFormer, a novel discriminator architecture that combines spatial and spectral analysis using Transformers to achieve superior perceptual quality and spectral alignment.

The Frequency Problem in Super-Resolution

Standard spatial discriminators operate directly on pixel values. While effective at capturing local textures, they often struggle to distinguish between genuine high-frequency details and artificial noise. Previous attempts to incorporate spectral discriminators—which analyze images in the frequency domain via Fourier Transforms—were often limited by poor scalability and a lack of theoretical understanding regarding their specific contributions.

The authors address this by first conducting a robustness analysis to determine how different discriminator types react to frequency-domain perturbations. They identified two primary forms of interference:

  1. Frequency Masking: The removal of data within specific frequency bands.
  2. Frequency Noise: The addition of unwanted artifacts or "junk" data.

Methodology: SpecFormer and DualFormer

To bridge the gap between spatial and spectral analysis, the researchers introduced two key architectural innovations:

SpecFormer

Traditional spectral discriminators often apply a global Fourier Transform, which can lose local structural information. SpecFormer solves this by adopting a patch-based approach. The input image is divided into patches (at least 32x32 to capture meaningful frequency data), and a 2D Discrete Fourier Transform (DFT) is applied to each. These spectral patches are then processed by a Vision Transformer (ViT) style backbone, allowing the model to learn complex relationships between local frequency components.

DualFormer

DualFormer serves as the final ensemble architecture. It operates two branches in parallel:

  • SpatFormer: A Spatial Transformer that focuses on pixel-level details.
  • SpecFormer: The aforementioned Spectral Transformer.

The "realness" scores from both branches are averaged to guide the generator. This dual-pathway ensures the model receives feedback on both spatial consistency and spectral integrity.

Key Insights: The Expert Complementarity

The most significant finding of this research is the complementary nature of spatial and spectral discriminators. The authors discovered a "Three-Range Phenomenon" where the spectrum is divided into:

  • Low Frequency: Dominated by structural distortions.
  • Middle Frequency: The transition zone where tradeoffs occur.
  • High Frequency: Dominated by perceptual details and noise.

The analysis revealed that spatial discriminators act as "experts" at identifying missing data in low frequencies (masking), while spectral discriminators are "experts" at identifying unwanted artifacts in high frequencies (noise). As the super-resolution scaling factor increases (e.g., 4x to 8x), these boundaries shift, making high-frequency noise increasingly difficult for traditional spatial models to detect. By combining both, DualFormer covers the entire spectrum's vulnerabilities.

Furthermore, the study demonstrates that a well-designed discriminator can serve as an effective No-Reference Image Quality Assessment (NR-IQA) tool. The discriminator’s internal "realness" score correlates more strongly with human perception than many specialized IQA algorithms.

Experimental Results

The DualFormer model was evaluated on standard benchmarks, including DF2K for training and BSD100, DIV2K, and Urban100 for evaluation.

  • Performance Metrics: On the Urban100 dataset (4x SR), DualFormer achieved a PSNR of 25.68, significantly outperforming ESRGAN (24.62). More importantly, it achieved an LPIPS score of 0.1147, indicating a substantial improvement in perceptual quality.
  • Spectral Alignment: Visual analysis of spectral density confirms that DualFormer’s outputs closely match the Ground Truth spectra. Unlike models like Real-ESRGAN, which often "overshoot" in high frequencies and create artificial grain, DualFormer maintains a natural spectral profile.
  • Efficiency: Despite the use of Transformers, the model remains efficient. By utilizing large patch sizes and a lightweight configuration (10 blocks, 96 hidden dimensions), DualFormer requires significantly fewer FLOPs than traditional VGG or U-Net based discriminators.

Conclusion and Future Work

DualFormer demonstrates that spectral information is not just a supplementary feature but a critical component for high-fidelity image synthesis. By leveraging the complementary strengths of spatial and spectral Transformers, the model achieves a new state-of-the-art in perceptual super-resolution.

Future research will focus on reducing the training overhead associated with dual-branch architectures and exploring earlier fusion methods to integrate spatial and spectral features more deeply within the network layers.

Summary updated

BibTeX
@misc{luo2023effectiveness,
  author = {Xin Luo and Yunan Zhu and Shunxin Xu and Dong Liu},
  title = {{on the effectiveness of spectral discriminators for perceptual quality improvement}},
  year = {2023},
  eprint = {2307.12027},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2307.12027},
  howpublished = {OpenReview},
}
Figure