def pil_image() -> Img:
    """Get an image.

    Returns:
        A random PIL image.
    """
    rng = np.random.default_rng()
    imarray = rng.random((100, 100, 3)) * 255
    return PIL.Image.fromarray(imarray.astype("uint8")).convert("RGBA")  # pyright: ignore [reportAttributeAccessIssue]
Get an image.

    Returns:
        A random PIL image.
    
tests/units/components/media/test_image.py