SyntaxFix
Write A Post
Hire A Developer
Questions
In later versions (tested with TensorFlow 1.14) there's a more numpy-like way to get the shape of a tensor. You can use tensor.shape to get the shape of the tensor.
tensor.shape
tensor_shape = tensor.shape print(tensor_shape)