Home > other >  How to custom in Keras custom evaluation function accuracy? Such as the definition of conditional pr
How to custom in Keras custom evaluation function accuracy? Such as the definition of conditional pr

Time:05-11

This is a three classification problem,

Knock on the code also found another problem in the process, y_true, y_pred in the process of training is how to update? As shown in figure, why do I direct return y_pred [2] the returned 0.33333, has always been not updated?

Eventually to solve the problem is, how to custom in Keras custom evaluation function accuracy? Such as the definition of conditional probability "accuracy=P (A | B)/PA"?

Thank you for your bosses to solve!!!!!!



 def categorical_accuracy (y_true, y_pred) : 
The return that final ast (Kevin Everett sat qual (K.a rgmax (y_true, axis=1),
K.a rgmax (y_pred, axis=1)),
K.f loatx ())
  • Related