How can I find the max value in each element so that I get 2, 4, 6, 8?
import tensorflow as tf
a = tf.constant([
[[1, 2]], [[3, 4]],
[[5, 6]], [[7, 8]]])
I tried the following code:
tf.reduce_max(a, keepdims=True)
but that just gives me 8 as output whilst ignoring the rest.