-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How do you send the request if you have two input nodes? #9
Comments
Nvm I figured it out, it was because when creating the serving dictionary I used the name prediction_signature, I rebuilt it using serving_default and it matched up. That being said though, I think it would be a good option if we can define the signature name in the client side app? I took a quick look through the code and am not sure where I can change it or make it an option. I think it would be a good feature to have. I don't mind forking and adding to it myself but not sure I have the time or know-how :P |
I want to know you how to deal with that problem in detail.
|
Hi,
In my normal model I need to dict.feed two placeholders into the model to run. I've also defined it as such in my tensorflow serving
prediction_signature = (
tf.saved_model.signature_def_utils.build_signature_def(
inputs={'image': tensor_info_x1, 'im_info': tensor_info_x2},
outputs={'cls_score': tensor_info_y1, 'cls_prob': tensor_info_y2, 'bbox_pred': tensor_info_y3,
'rois_l3': tensor_info_y4},
method_name=tf.saved_model.signature_constants.PREDICT_METHOD_NAME
)
)
How do I put that in the req_data list? I'm currently doing
[{'in_tensor_name': 'Placeholder:0', 'in_tensor_dtype': 'DT_FLOAT', 'data': blobs['data']},
{'in_tensor_name': 'Placeholder_1:0', 'in_tensor_dtype': 'DT_FLOAT', 'data': blobs['im_info']}
]
but I keep getting the error
<_Rendezvous of RPC that terminated with (StatusCode.FAILED_PRECONDITION, Serving signature key "serving_default" not found.)>
Prediction failed!
I'm suspect its because the request data isn't being formatted correctly.
Help!
Thanks
The text was updated successfully, but these errors were encountered: