Learnable Blur Kernel for Single-Image Defocus Deblurring in the Wild

Jucai Zhai, Pengcheng Zeng, Chihao Ma, Jie Chen, Yong ZhaoAAAI 2023 · DOI

Introduction

Defocus blur is a common artifact in photography, occurring when objects fall outside the camera's depth-of-field. Mathematically, this is represented by a "Circle of Confusion" (CoC) where a single point in a scene projects as a blurry disc on the sensor. Restoring these images is a classic ill-posed problem: estimating the blur requires knowing the scene's depth, yet depth estimation from a single image is significantly easier when the image is already sharp.

Example of severe defocus blur on text, showcasing the loss of high-frequency details.

While modern dual-pixel (DP) sensors offer a hardware-based solution by providing two slightly offset views for depth estimation, processing this data is computationally heavy for mobile devices. This paper introduces a framework that uses DP data as a "supervisory signal" during training to learn a defocus map, but operates using only a single standard image during inference.

Methodology

The proposed approach bridges the gap between high-quality training data and efficient deployment through a two-stage architecture:

  1. Learnable Blur Kernel (BK): Instead of using fixed mathematical models, the authors developed an unsupervised method to estimate a defocus map. They utilize a Learnable BK—initially based on a Butterworth high-pass filter—that evolves during training to simulate real-world lens characteristics (the Point Spread Function).
  2. DefocusGAN: The core engine is a Generative Adversarial Network featuring a Defocus Map Guide Block (DGB). This block divides the image into four branches based on blur intensity, allowing the network to apply specialized processing to different regions.
  3. Annealing Strategy: To ensure the model remains practical for single-image use, the authors employ an annealing process. The reliance on the defocus map is phased out over the course of training, teaching the network to perform high-quality deblurring without the auxiliary DP data at inference time.

Results and Discussion

The framework was evaluated on the DPDD dataset and real-world images from the CUHK and Google PixelDP sets. Quantitatively, the model achieved a PSNR of 25.56 dB and an LPIPS of 0.111, outperforming state-of-the-art models like MDPNet while being significantly more efficient (4.59M parameters vs. 46.86M).

Qualitative comparison showing the original scene and the ground truth (GT) restoration of text, demonstrating the model's ability to recover fine details.

Qualitatively, the model excels at restoring high-frequency textures, such as text and fine patterns, which are often lost or smoothed over by competing deblurring networks. By weighting the adversarial loss based on the defocus map, the model is forced to prioritize the restoration of the most heavily blurred regions.

Conclusion

By "training with crutches"—leveraging complex dual-pixel data during the learning phase and discarding it for inference—the authors have created a lightweight yet powerful solution for single-image deblurring. This approach effectively models the physics of camera lenses while maintaining the speed required for mobile deployment. Future work may extend this learnable kernel strategy to other forms of degradation, such as motion blur or atmospheric haze.

Summary updated

BibTeX
@inproceedings{zhai2023learnable,
  author = {Jucai Zhai and Pengcheng Zeng and Chihao Ma and Jie Chen and Yong Zhao},
  title = {{Learnable Blur Kernel for Single-Image Defocus Deblurring in the Wild}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2023},
  doi = {10.1609/aaai.v37i3.25446},
}
Figure