Updated API for computing classification accuracies