layumi / 2016_super_resolution

ICCV2015 Image Super-Resolution Using Deep Convolutional Networks
MIT License
86 stars 43 forks source link

When I look at your code in train_SRnet.m, I knew that you used 3 GPU or 2 GPU because of "opts.train.gpus = 3;". #6

Open star4s opened 7 years ago

star4s commented 7 years ago

When I look at your code in train_SRnet.m, I knew that you used 3 GPU or 2 GPU because of "opts.train.gpus = 3;". Do you use multipul GPU for CUDA? How can you use multipul GPU? Your GPU is supported by multipul GPU? What kind of GPU do you use? Or your mainboad is supported multipul GPU Slot? I think your training time is so fast because you use multipul GPU, isn't it? I am so curious.

layumi commented 7 years ago

Hi @star4s I just use one GTX1080 GPU card although there are 4 GPU cards on my school machine. I use opts.train.gpus=3 to select the third card to run rather than use three GPUs. If you want to use multiple card, you may write like opts.train.gpus=[1,2] to use the first and second card together.

star4s commented 7 years ago

I got it. Thank you for your help and answer. After I try color image training, the Mat file works well for super resolution for my grayscale image. However after I try grayscale image training, the Mat file does not work well for super resolution for my grayscale image. I do not know why it does not work well. I am trying control pts.train.learningRate.

I have one more small question. What is opts.train.weightDecay? If I change the parameter, the result is changed? You used opts.train.weightDecay = 0.0005. Anyhow, thank you for your help, every time.

layumi commented 7 years ago

weightDecay is regularization term. If you have learned SVM, you will know the loss function is: (y-Wx)^2 + gama*||W|| weightDecay is gama. In CNN, it works in a similar way on the weight learning.