Abstract
This paper proposes a novel deep learning approach for single image defocus deblurring based on inverse kernels. In a defocused image, the blur shapes are similar among pixels although the blur sizes can spatially vary. To utilize the property with inverse kernels, we exploit the observation that when only the size of a defocus blur changes while keeping the shape, the shape of the corresponding inverse kernel remains the same and only the scale changes. Based on the observation, we propose a kernel-sharing parallel atrous convolutional (KPAC) block specifically designed by incorporating the property of inverse kernels for single image defocus deblurring. To effectively simulate the invariant shapes of inverse kernels with different scales, KPAC shares the same convolutional weights among multiple atrous convolution layers. To efficiently simulate the varying scales of inverse kernels, KPAC consists of only a few atrous convolution layers with different dilations and learns per-pixel scale attentions to aggregate the outputs of the layers. KPAC also utilizes the shape attention to combine the outputs of multiple convolution filters in each atrous convolution layer, to deal with defocus blur with a slightly varying shape. We demonstrate that our approach achieves state-of-the-art performance with a much smaller number of parameters than previous methods.
The Challenge of Spatially Varying Blur
Defocus blur is a common optical phenomenon occurring when scene points fall outside the camera's depth of field, resulting in a "circle of confusion." For single-image deblurring, this presents a significant challenge because the blur is spatially varying: its size depends on the depth of objects, and its shape can shift due to lens optics.
Traditional restoration methods often rely on simplified assumptions about blur kernels, which fail to capture the complexity of real-world optics. While recent deep learning models like DPDNet have improved performance, they often require massive parameter counts and struggle with artifacts like ringing or residual blur because their architectures do not explicitly account for the underlying physics of spatially varying kernels.
Methodology: The KPAC Block
The core innovation of this work is the Kernel-Sharing Parallel Atrous Convolutional (KPAC) block. It is grounded in a mathematical observation: if a blur kernel's shape remains constant while its size changes, the shape of its corresponding inverse kernel (the operator that reverses the blur) also remains constant, with only its scale changing.
To implement this, the KPAC block utilizes three key mechanisms:
- Weight-Sharing Atrous Convolutions: Instead of learning separate filters for every possible blur size, the block uses parallel atrous (dilated) convolution layers that share the same weights. Different dilation rates effectively "scale" the kernel's receptive field, allowing a single learned "inverse kernel shape" to be applied at multiple scales.
- Scale Attention: Since blur size varies per pixel, the network learns a per-pixel scale attention map. This map determines how to aggregate the outputs of the parallel atrous branches, effectively selecting or blending the appropriate scales for each region.
- Shape Attention: To account for minor variations in blur shape across the image, a channel-wise shape attention module is included to refine the combination of filters.
Key Insights: Physics-Informed Efficiency
- The Inverse Kernel Shortcut: By proving that scaling a blur kernel scales its inverse kernel identically, the researchers constrained the network's search space, leading to a more robust and interpretable model.
- Dilation as Scaling: Using atrous convolutions as a proxy for kernel scaling allows the model to simulate large deconvolution kernels with minimal parameters, avoiding the computational cost of large receptive fields.
- Regularization through Sharing: Weight sharing acts as a powerful regularizer. It prevents overfitting and forces the network to focus on the fundamental geometry of the blur rather than memorizing specific patterns.
Experimental Results
The model was evaluated on the DPDD (Dual-Pixel Defocus Deblurring) dataset and the CUHK blur detection dataset.
- Performance: The KPAC-based model achieved a PSNR of 25.24 dB on the DPDD dataset, surpassing the previous state-of-the-art DPDNet (24.42 dB).
- Efficiency: The model is remarkably lightweight. A 2-level version uses only 1.58 million parameters, a 20x reduction compared to DPDNet’s 32.25 million.
- Speed: Processing a 720p image takes approximately 0.07 to 0.09 seconds, making it suitable for real-time mobile applications.
Conclusion and Future Work
The KPAC architecture demonstrates that incorporating physical priors into deep learning can lead to both higher performance and significantly greater efficiency. While the model excels at standard defocus, challenges remain in handling extreme blur, highly irregular bokeh shapes, and sharp depth boundaries. Future research may explore stacking additional KPAC blocks or refining attention mechanisms to address these complex optical scenarios.
Summary updated