one-hot encoding on the labels should be done when parsing before being fed to the CNN, isnt that so? If not an error occurs when building the model?
If the labels are not one-hot encoded you can still sued them but with sparse categorical cross entropy loss rather than categorical cross entropy loss.
1 Like
Thank you. Tried to_categorical method also.
Is there a difference?
There are a few differences between them but thats the main one I mentioned above.