when to use to_categorical in keras

Viewed 13202

Please someone explain when keras.utils.np_utils.to_categorical is to be used?
I understand that it converts class vector to binary matrix, probably used in Deep Learning model.
But if we still go ahead and use the class vector itself, and probably use model.predict_classes - what is the drawback?

2 Answers
Related