I have bytes of length 24707. I have a function to create an image out of bytes
bytes
24707
def generate_image(data, num): resolution = (1,