productner icon indicating copy to clipboard operation
productner copied to clipboard

Error classifier

Open andersonscherrer opened this issue 4 years ago • 0 comments

Error when running: python train_classifier.py data/products.normalized.trimmed.supplemented.tagged.csv ValueError: You are passing a target array of shape (0, 1) while using as loss categorical_crossentropy. categorical_crossentropy expects targets to be binary matrices (1s and 0s) of shape (samples, classes). If your targets are integer classes, you can convert them to the expected format via: from keras.utils import to_categorical y_binary = to_categorical(y_int)`

andersonscherrer avatar May 18 '20 15:05 andersonscherrer