Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistent Shape of Generator output #4

Open
malzantot opened this issue Nov 22, 2016 · 2 comments
Open

Inconsistent Shape of Generator output #4

malzantot opened this issue Nov 22, 2016 · 2 comments

Comments

@malzantot
Copy link

Hi,

Thanks for the example. I tried running it using Keras v1.1.1 , However the code generates an an inconsistent shape of the generator output. The output I get is [None, 400, 28, 1] instead of [None, 1, 28, 28] Therefore, it fails to stack the two models together.

Problem happens with both Theano and Tensorflow backends. any hints ?

@malzantot
Copy link
Author

Seems like the issues comes from the Keras Convolution2D which requires to specify which dimension of input image stands for the depth.
Problem solved by adding the following
, dim_ordering='th' to the Convolution2D and Sampling2D layers.

@malzantot
Copy link
Author

Apparently the problem is still there. Although it could successfully stack the two models after I added the dim_ordering flag. It now fails when I try to run the generative model.

It gives me the following error message
ValueError: CorrMM images and kernel must have the same stack size

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant