OSError: image file is truncated (7 bytes not processed) 添加2行代码即可 from PIL import ImageFile ImageFile.LOAD_TRUNCATED_IMAGES = True