I am trying to train a deep learning algorithm in Keras with a Tensorflow backend. I am trying to do the following:
x = tf.reshape(theta, [-1])[K.argmax(image)]
Where image is the input and eta is a coordinate. I am trying to flatten theta, but I get the error
Only integers, slices (`:`), ellipsis (`...`), tf.newaxis (`None`) and scalar tf.int32/tf.int64 tensors are valid indices, got <tf.Tensor 'loss_42/dense_264_loss/ArgMax:0' shape=(25,) dtype=int64>