jiangsutx / SRN-Deblur

Repository for Scale-recurrent Network for Deep Image Deblurring
http://www.xtao.website/projects/srndeblur/srndeblur_cvpr18.pdf
MIT License
714 stars 184 forks source link

crop_size #44

Closed Flyzzz closed 5 years ago

Flyzzz commented 5 years ago

hi, could anyone tell me that what the scripts do with the crop_size(at model.py). when I run training. it shows <img_in, img_gt (4, 128, 128, 1) (4, 128, 128, 1)>, 4 is my batchsize,I set the crop_size = 128, but I don not know what is it means? Does it means input placeholders? thank you

jiangsutx commented 5 years ago

When doing training, a common routine is to crop a batch of images into the same size. And then concatenate them together to form a training batch. In image processing tasks, crop is usually done in a random crop manner. That is to choose a random position in each image and then crop a size of 128*128 square patch.

Flyzzz commented 5 years ago

thank you for you reply. for a 400400 image, only 128128 of it is used to train?

jiangsutx commented 5 years ago

It is `random crop'. During training, the same image will be used multiple times with different location chosen.