can anyone help me solve this error:
Warning: Precision and F-score are ill-defined and being set to 0.0 in labels with no predicted samples. Use
zero_divisionparameter to control this behavior. _warn_prf(average, modifier, msg_start, len(result))
the error appears when I add Adam's tuning parameter.
#tunning parameter from keras.optimizers import Adam
optimize = Adam(learning_rate=0.00001,beta_1=0.9,beta_2=0.99)
model.compile(optimizer=optimize,loss='categorical_crossentropy', metrics=['accuracy'])
does anyone understand the error of this code?
from sklearn.metrics import confusion_matrix, classification_report
prediksi = model.predict(test_data_generator)
y_pred = np.argmax(prediksi, axis=1)
print(confusion_matrix(test_data_generator.classes,y_pred))
print(classification_report(test_data_generator.classes,y_pred))
I've also tried using labels=np.unique(y_pred) but the results do not show the value of the accuracy of