brade31919 / SRGAN-tensorflow

Tensorflow implementation of the SRGAN algorithm for single image super-resolution
MIT License
848 stars 282 forks source link

Issue with perceptual loss #51

Open seemaywang opened 5 years ago

seemaywang commented 5 years ago

Hi,I have a question when using perceptual loss, what kind of input data does the function VGG19_slim accept?

elif FLAGS.perceptual_mode == 'VGG22': with tf.name_scope('vgg19_1') as scope: extracted_feature_gen = VGG19_slim(gen_output, FLAGS.perceptual_mode, reuse=False, scope=scope) with tf.name_scope('vgg19_2') as scope: extracted_feature_target = VGG19_slim(targets, FLAGS.perceptual_mode, reuse=True, scope=scope)

In this part of code , should I normalize gen_output and targets to [-1,1], or [0, 1], or [0, 255]? The code only told me to resize input to (224*224), but didn't show the type of input data. And it seems important how to normalize the input data.

Looking forward to your response, thanks a lot!

liyuett commented 5 years ago

hello, i have the same confusion as yours. Have you resolved this issue now?