Calculates how often predictions match one-hot labels.

Inherits From: Mean, Metric, Layer, Module

Used in the notebooks

Used in the guide

You can provide logits of classes as y_pred, since argmax of logits and probabilities are same.

This metric creates two local variables, total and count that are used to compute the frequency with which y_pred matches y_true. This frequency is ultimately r