I’m not sure why we need the argument axis = -1 for tf.math.argmax and tf.math.reduce_max. Hoping someone can explain this to me.
-1 tells argmax() to return the results for each value of the final index. The last index in the box_scores variable is the class identifier. So we’re finding the boxes with the highest scores for each class.
It’s a little difficult to intuit because it’s a 4D data set.