Fast Style Transfer Upsample Dimension error

Hi there, trying to implement Fast Style transfer but there is this an issue iam stuck for two days. Dimension error while calculating total loss which i think arises from not properly implementing Upsampling. I have even look at Jeremy code and tried to implement that as well but getting same error. Keras Version 2.0.2. Any help would be appreciated. Here is my code link on Github


I don’t know if you solved it, but just in case, the only thing you need to do is to simply change the method name:




at the custom layer ReflectionPadding2D

This is more or less explicit in the error message you get when you run ReflectionPadding2D:

_.ReflectionPadding2D defines get_output_shape_for but does not override compute_output_shape. If this is a Keras 1 layer, please implement compute_output_shape to support Keras 2. output_shape = self.compute_output_shape(input_shape)

Hope it helps!