未验证 提交 4b95e7a2 编写于 作者: F Feng Ni 提交者: GitHub

fix truncated image reading (#4937)

上级 cba0345d
...@@ -17,7 +17,8 @@ from __future__ import division ...@@ -17,7 +17,8 @@ from __future__ import division
import os import os
import cv2 import cv2
import numpy as np import numpy as np
from PIL import Image, ImageDraw from PIL import Image, ImageDraw, ImageFile
ImageFile.LOAD_TRUNCATED_IMAGES = True
from collections import deque from collections import deque
......
...@@ -18,7 +18,8 @@ from __future__ import division ...@@ -18,7 +18,8 @@ from __future__ import division
import os import os
import cv2 import cv2
import numpy as np import numpy as np
from PIL import Image, ImageDraw from PIL import Image, ImageDraw, ImageFile
ImageFile.LOAD_TRUNCATED_IMAGES = True
import math import math
......
...@@ -22,7 +22,8 @@ import copy ...@@ -22,7 +22,8 @@ import copy
import time import time
import numpy as np import numpy as np
from PIL import Image, ImageOps from PIL import Image, ImageOps, ImageFile
ImageFile.LOAD_TRUNCATED_IMAGES = True
import paddle import paddle
import paddle.distributed as dist import paddle.distributed as dist
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册