def compute_metrics(eval_pred):
        """Computes accuracy on a batch of predictions"""
        predictions = np.argmax(eval_pred.predictions, axis=1)
        return metric.compute(predictions=predictions, references=eval_pred.label_ids)
Computes accuracy on a batch of predictions
dpkd/transformers/examples/pytorch/audio-classification/run_audio_classification.py