import torch


def evaluate_acc(model, images, labels):
    """Evaluate model's prediction accuracy on given batch of data."""
    outputs = model(images)
    _, predicted = torch.max(outputs.data, 1)
    total = labels.size(0)
    correct = (predicted == labels).sum().item()
    acc=(correct/total)
    return acc