Accuracy Score Function In Python