用的python3.5,tf.gfile.FastGFile函数打开图片,路径中包含中文就打不开,试过更改编码方式,都失败了。
求打开中文路径图片的方法。
from tensorflow.python.platform import gfile
image_data = gfile.FastGFile('/Users/.../文档/.../flower_photos/daisy/5547758_eea9edfd54_n.jpg', 'rb').read()
print(image_data)
使用的mac os python3.6.3,可以打开