def _get_pil_image_dimensions(pil_image):
    """Gets the dimensions of the Pillow Image.

    Args:
        pil_image: Image. A file in the Pillow Image format.

    Returns:
        tuple(int, int). Returns height and width of the image.
    """
    width, height = pil_image.size
    return height, width