Closed mkcedward closed 7 years ago
In this example, there's a single category without onehot encoding, therefore the output layer is a single sigmoid and the loss is binary cross-entropy.
If you use more categories, categorical_crossentropy is the best choice, but the output layer must be softmax with onehot encoding for all categories.
Thank you for your great sample. It is good tutorial for classifying text.
Would like to know about the loss function of LSTM model. For multiclass problem, categorical_crossentropy should be used while Why do you use binary_crossentropy ?