def accuracy(pred_labels, true_labels, test_vs):
    """
    Computes classification accuracy on test vertices.

    Args:
        pred_labels: A dict of predicted labels for each node.
        true_labels: A dict of ground-truth labels for each node.
        test_vs: A list of test node ids (int) over which the accuracy
            will be measured.

    Returns:
        acc: (int) classification accuracy on test_vs.
    """
    acc = sum([pred_labels[i] == true_labels[i] for i in test_vs])/len(test_vs)

    return acc