未验证 提交 b5871048 编写于 作者: T Teng Xi 提交者: GitHub

change scipy.misc.imread() to imageio.imread() (#324)

上级 56cd1eca
......@@ -13,7 +13,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
import numpy as np
import scipy.misc
import imageio
import os
import paddle
from paddle import fluid
......@@ -54,7 +54,7 @@ class CASIA_Face(object):
target = self.label_list[index]
try:
img = scipy.misc.imread(img_path)
img = imageio.imread(img_path)
except:
continue
......
......@@ -13,8 +13,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
import numpy as np
import scipy.misc
import imageio
import paddle
from paddle import fluid
......@@ -33,10 +32,10 @@ class LFW(object):
return
index = self.shuffle_idx.pop(0)
imgl = scipy.misc.imread(self.imgl_list[index])
imgl = imageio.imread(self.imgl_list[index])
if len(imgl.shape) == 2:
imgl = np.stack([imgl] * 3, 2)
imgr = scipy.misc.imread(self.imgr_list[index])
imgr = imageio.imread(self.imgr_list[index])
if len(imgr.shape) == 2:
imgr = np.stack([imgr] * 3, 2)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册