Closed Jim61C closed 7 years ago
Never seen a 5 tuple output shape like that. I think it's not a problem with the theano version but isntead the dim ordering in Keras.
Please ensure you are using 'th' dim ordering in Keras 1.2.2, which is what I am currently using. When I was developing this code I used 1.1.1, bit have tested it on 1.2.2 correctly as well.
My thank was 0.8.2 at that time (the master version, not the pip install 0.8.2).
Hi,
It seems that the original sr_resnet_weights.h5 is out of dated and if I load from SRGAN.h5 with only layers with same name, the testing runs fine now.
Hmm I don't think I updated the code anytime recently, but that would explain the incorrect weight dimension.
Thanks for to heads up. I'll look into it when I have a bit more time.
Sure, no problem!
Hi,
Firstly, thanks for open source your work. I am trying to run benchmark.py with the provided weights, however I keep running into this error of
ValueError: could not broadcast input array from shape (1,256,64,1,64) into shape (1,128,64,2,64)
at the line ofoutput_image_batch = model.predict_on_batch(x_generator)
it seems to be a problem with the input output shape matching at
x = UpSampling2D(name='sr_res_upscale_%d' % id)(x)
in function ` def _upscale_block(self, ip, id):I am suspecting that this might an issue with the Theano backend version I am using? I have tested on both 0.9.0 and 0.8.2 with Keras 1.2.1 but in both cases, the error preserves. Thus, may I know which version of Theano and Keras are you currently using? Thanks!