我有这个大小为128 x 128像素的图像,RGBA作为字节值存储在我的内存中.但
from PIL import Image
image_data = ... # byte values of the image
image = Image.frombytes('RGBA', (128,128), image_data)
image.show()
Run Code Online (Sandbox Code Playgroud)
抛出异常
ValueError:没有足够的图像数据
为什么?我究竟做错了什么?