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

Async kserve samples #1641

Merged
merged 7 commits into from
Jan 9, 2023
Merged

Async kserve samples #1641

merged 7 commits into from
Jan 9, 2023

Conversation

bstrzele
Copy link
Collaborator

@bstrzele bstrzele commented Jan 2, 2023

No description provided.

@bstrzele bstrzele changed the title Async cpp samples Async kserve samples Jan 2, 2023
@dtrawins dtrawins requested a review from mzegla January 3, 2023 10:04
client/cpp/kserve-api/samples/grpc_async_infer_resnet.cpp Outdated Show resolved Hide resolved
client/cpp/kserve-api/samples/grpc_async_infer_resnet.cpp Outdated Show resolved Hide resolved
client/cpp/kserve-api/samples/http_async_infer_resnet.cpp Outdated Show resolved Hide resolved
client/cpp/kserve-api/samples/http_async_infer_resnet.cpp Outdated Show resolved Hide resolved
Comment on lines 154 to 160
data.append(triton_client.async_infer(
model_name=args.get(
'pipeline_name') if is_pipeline_request else args.get('model_name'),
inputs=inputs,
outputs=outputs))

output = data[x].get_result().as_numpy(args['output_name'])
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why for http there's a different approach than with grpc sample? This part calls async_infer method, but it looks like effectively it's synchronous as we call get_result() right after inference is scheduled.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right. Let's stick to this version then.

@bstrzele bstrzele merged commit b9c829a into develop Jan 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants