Structs

  • | Accuracy takes two inputs- predictions | and labels, and returns a float accuracy | value for the batch. | | Predictions are expected in the form | of 2-D tensor containing a batch of scores | for various classes, and labels are | expected in the form of 1-D tensor containing | true label indices of samples in the | batch. | | If the score for the label index in the | predictions is the highest among all | classes, it is considered a correct | prediction. |