Getting an error message ‘The layer has never been called and thus has no defined output shape’ while trying to print the layers in the sequential model.
This error message indicates that something went wrong while building a layer in the model. This may be because you did not provide all required parameters, such as input_shape for the ZeroPadding2D layer.
Unfortunately, the tensorflow documentation of tf.keras.layers.ZeroPadding2D does not include an example in which this parameter is used, but it can be included as a parameter.
Good luck. Let me know if it worked out.
Ok , I added input layer in the sequential model and it worked.
Great! Good luck with the rest of the course and don’t hesitate to ask if you run into issues.
Oh, and could you please remove the piece of code from your reply? Thanks!
Had the same problem and it worked when I added the input_shape parameter.
The TensorFlow official documentation does not even mention there is this parameter. So I wonder if there is a more complete Tensorflow documentation? Or am I missing something?
Thanks reinoudbosch. didn’t mean to be a lazy question. now i understand what **kwargs means ( that there are many other unespecified number of other keyworded arguments), the documentation made sense to me. still a newbie to python, thought there were only 3 kw params.
You’re welcome kleber. I didn’t mean to imply that you were lazy, just that you may be able to find something else, better, or clearer than what I found! Good luck with the rest of the course.
Hi I am not getting how to do it, please help
Please do not share coding solutions!