I should check the accuracy. However. what do you mean by target should contain the class indices and have the shape [batch_size]? Sorry, but I am beginner. To my understanding, the class indices sounds like it should have integer value which matches up with the class name. Could you please clarify for me?