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

Question about the get_response() function in the Python API's HTTP/REST Client #7354

Open
jackylu0124 opened this issue Jun 16, 2024 · 0 comments

Comments

@jackylu0124
Copy link

Hey all, I have a question regarding the get_response() function in the Python API's HTTP/REST Client, I see that in the client script for the pytorch and add_sub examples, we have a result = response.get_response() call (see https://github.com/triton-inference-server/python_backend/blob/c8b188f26a4e80c7204baaf73e27f11c33f52f57/examples/pytorch/client.py#L58 and https://github.com/triton-inference-server/python_backend/blob/c8b188f26a4e80c7204baaf73e27f11c33f52f57/examples/add_sub/client.py#L58) before we extract the outputs with response.as_numpy("OUTPUT0") for example.

My question is: what is the purpose of the result = response.get_response() call before we extract the outputs with as_numpy(), and whether the result = response.get_response() call is necessary before we extract the outputs with as_numpy(); because I have tried removing the response.get_response() call, and have tried directly extracting the outputs with as_numpy() right after infer(), and I was able to extract the expected outputs.

Thank you very much for your time and help in advance!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant