我在Google cloud上训练了一个Pet数据集,使用gcloud将训练好的模型下载到本地PC上。任务:使用训练好的模型对测试集进行本地分类
A)如果我使用像这样的gcloud
$ gcloud ml-engine local predict --model-dir=saved_model/ --json-instances=inputs.json错误: prediction_lib.PredictionError:(4,“运行图形时出现异常:基数为10的long()的无效文本:'\xff\xd8\xff\xe0'")
发布于 2017-10-27 23:34:20
您的模型接受图像的数组,而不是JPG字符串。请参阅tensorflow serving prediction not working with object detection pets example的答案
如果要使用当前输入,可以使用-- input _type encoded_image_string_tensor重新导出模型。
https://stackoverflow.com/questions/46952766
复制相似问题