问题描述
我确保我的数据集包含jpeg格式的所有图像。我读过某个地方使用tf.image.decode_jpeg(),但即使所有文件都是jpeg格式,我仍然需要它吗?如果是,该怎么办?为我的学校项目做这件事。谢谢。
<ipython-input-29-c6c91b75df2e> in <module>()
----> 1 model = image_classifier.create(train_data)
11 frames
/usr/local/lib/python3.6/dist-packages/tensorflow/python/eager/execute.py in quick_execute(op_name,num_outputs,inputs,attrs,ctx,name)
58 ctx.ensure_initialized()
59 tensors = pywrap_tfe.TFE_Py_Execute(ctx._handle,device_name,op_name,---> 60 inputs,num_outputs)
61 except core._NotOkStatusException as e:
62 if name is not None:
InvalidArgumentError: 2 root error(s) found.
(0) Invalid argument: Unknown image file format. One of JPEG,PNG,GIF,BMP required.
[[{{node cond/else/_1/cond/DecodePng}}]]
[[IteratorGetNext]]
(1) Invalid argument: Unknown image file format. One of JPEG,BMP required.
[[{{node cond/else/_1/cond/DecodePng}}]]
[[IteratorGetNext]]
[[IteratorGetNext/_2]]
0 successful operations.
0 derived errors ignored. [Op:__inference_train_function_23384]
Function call stack:
train_function -> train_function```
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)