Python程序中PIL Image “image file is truncated“问题分析与解决

错误代码

OSError: image file is truncated (54 bytes not processed)

解决方法

第一种:找到丢失内容的图片

第二种:在运行的程序中添加代码

from PIL import ImageFile
ImageFile.LOAD_TRUNCATED_IMAGES = True

猜你喜欢

转载自blog.csdn.net/Hi_one_two_three/article/details/130306278
今日推荐