def horizontal_flip(img, p):
    if (np.random.sample() <= p):
        return img.transpose(Image.FLIP_LEFT_RIGHT)
    else:
        return img
def horizontal_flip(img, p):
    if (np.random.sample() <= p):
        return img.transpose(Image.FLIP_LEFT_RIGHT)
    else:
        return img