VinAIResearch / blur-kernel-space-exploring

Exploring Image Deblurring via Blur Kernel Space (CVPR'21)
Apache License 2.0
147 stars 34 forks source link

How to create file "warmup_k_path"? #3

Closed viet24dung closed 3 years ago

viet24dung commented 3 years ago

Thank you for this repo is really awesome. But I have a small question: how is the "warmup_k_path" file created, what is it used for in the deblur process.

P0lyFish commented 3 years ago

Hi, thanks for your interest. If you mean the "warmup_k.pth", it is a random kernel extracted by the kernel extractor. Before doing image deblurring, we initialize the blur kernel with a random kernel to stabilize the optimization process. To generate a warmup_k.pth, you can modify the "data_augmentation.py"., for example, add `torch.save("kernel.pth", kernel) before L119.