Skip to content
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

gRPC example in the quick start guide is yields an error #67

Closed
crobby opened this issue Oct 27, 2021 · 2 comments · Fixed by #322
Closed

gRPC example in the quick start guide is yields an error #67

crobby opened this issue Oct 27, 2021 · 2 comments · Fixed by #322
Labels
bug Something isn't working

Comments

@crobby
Copy link
Contributor

crobby commented Oct 27, 2021

While running through the quick start guide, I get an error when trying to run the gRPC example under the "perform an inference test" section.

Running the command as written in the guide gives an error:

MODEL_NAME=example-mnist-predictor
grpcurl \
  -plaintext \
  -proto fvt/proto/kfs_inference_v2.proto \
  -d '{ "model_name": "'"${MODEL_NAME}"'", "inputs": [{ "name": "predict", "shape": [1, 64], "datatype": "FP32", "contents": { "fp32_contents": [0.0, 0.0, 1.0, 11.0, 14.0, 15.0, 3.0, 0.0, 0.0, 1.0, 13.0, 16.0, 12.0, 16.0, 8.0, 0.0, 0.0, 8.0, 16.0, 4.0, 6.0, 16.0, 5.0, 0.0, 0.0, 5.0, 15.0, 11.0, 13.0, 14.0, 0.0, 0.0, 0.0, 0.0, 2.0, 12.0, 16.0, 13.0, 0.0, 0.0, 0.0, 0.0, 0.0, 13.0, 16.0, 16.0, 6.0, 0.0, 0.0, 0.0, 0.0, 16.0, 16.0, 16.0, 7.0, 0.0, 0.0, 0.0, 0.0, 11.0, 13.0, 12.0, 1.0, 0.0] }}]}' \
  localhost:8033 \
  inference.GRPCInferenceService.ModelInfer

To Reproduce
Steps to reproduce the behavior:

  1. Install via the quick start guide instructions
  2. Try to do an inference with the sample given for gRPC
  3. See the following error
Failed to process proto source files.: could not parse given files: open fvt/proto/kfs_inference_v2.proto: no such file or directory

Expected behavior
I expect the inference to be returned as documented.

Client Version: 4.5.0-202005291417-9933eb9
Server Version: 4.9.0-rc.5
Kubernetes Version: v1.22.0-rc.0+8719299

When I run the REST example, I do get the expected results for the inference.

@crobby crobby added the bug Something isn't working label Oct 27, 2021
@crobby
Copy link
Contributor Author

crobby commented Oct 27, 2021

I have solved my issue by grabbing the file from: https://github.com/kserve/kserve/blob/master/docs/predict-api/v2/grpc_predict_v2.proto I then changed the command line to reference it from where I downloaded it to rather than the path given in the example.
Root cause: perhaps a slightly inaccurate doc combined with my unfamiliarity with gRPC.

@SebastianScherer88
Copy link

@crobby 's solution worked for me, too - thanks!

kserve-oss-bot pushed a commit that referenced this issue Feb 3, 2023
#### Motivation
New users with limited exposure to gRPC or `grpcurl` can run into trouble using the inference request example provided in the quickstart example.

#### Modifications
Add information regarding where exactly to run the gRPC inference request so that the `--proto` path used in the request finds the file and works.

#### Result
Closes #67 

Signed-off-by: Rafael Vasquez <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants