What's the threshold value of binary_accuracy
in keras Metrices is used to predicted one sample as positive and negative cases? is that threshold value 0.5? how to adjust it? I want to set the threshold value 0.80, if the predicted value is 0.79, then it is considered a negative sample,otherwise,if the predicted value is 0.81, then it is considered a positive sample.
To answer the initial question, keras uses the round function to assign classes, so the threshold is 0.5.
https://github.com/fchollet/keras/blob/master/keras/metrics.py
def binary_accuracy(y_true, y_pred):
return K.mean(K.equal(y_true, K.round(y_pred)))