keras-adversarial
keras-adversarial copied to clipboard
AttributeError: 'Model' object has no attribute 'internal_input_shapes'
I am using Python 3.6 and install keras_adversarial with the master branch, it seems that Model has no attribute 'internal_input_shapes' BUT '_internal_input_shapes'. Also Model has no attribute 'internal_output_shapes' either.
Traceback (most recent call last):
File "example_gan.py", line 118, in
After I correct the 'internal_input_shapes' and 'internal_output_shapes' to '_internal_input_shapes' and '_internal_output_shapes', it still got errors with example_gan.py:
Traceback (most recent call last):
File "example_gan.py", line 118, in
I am using Python 3.6, Keras 2.1.3 and Tensorflow 1.5
I also have the same problems
I'm stuck in the same situation. Any update?
I had the same error and on Keras 2.1.3, I tried downgrade keras to 2.1.2 and it works. So this maybe a temp solution.
same with 2.1.4 only 2.1.2 works
The first error appears to have happened because of a change in Keras, internal_input_shapes and internal_output_shapes were changed to be private variables in the keras/engine/topology.py file, reference this commit
As far as a fix for the second error goes, I'm still not sure. But the example_gan.py file is running a legacy version of fit, and I'm not sure what ought to be done to fix it.
I have same problem with Keras 2.1.3 on one machine but works fine with Keras 2.1.2 on other machine. I might need to downgrade 2.1.3 to 2.1.2.
my keras version was 2.1.6 and i was getting the same error.... downgrading solved the issue
do you have any suggestions about how to use the keras-adversarial examples without downgrading the keras, i.e. with newer versions?
with newer keras versions try K.int_shape(model.inputs[0])
with newer keras versions try
K.int_shape(model.inputs[0])
Where to use this?