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

Add support for sessions to share a global threadpool #4962

Closed
dashesy opened this issue Aug 28, 2020 · 2 comments
Closed

Add support for sessions to share a global threadpool #4962

dashesy opened this issue Aug 28, 2020 · 2 comments
Assignees

Comments

@dashesy
Copy link

dashesy commented Aug 28, 2020

Is your feature request related to a problem? Please describe.
We have to run 2 sessions, but not in parallel.
Does that mean we may also benefit from this PR?

System information

  • ONNX Runtime version (you are using): 1.4

Describe the solution you'd like
Expose the threadpool sharing to C#, so we can test

Describe alternatives you've considered
Use C++ code

Additional context
The design discussion does not explain the rationale, or exactly how it helps OCR. So we do not know if this also benefits us.
Is it possible to discuss this in open and explain the issue?

@pranavsharma
Copy link
Contributor

pranavsharma commented Aug 28, 2020

If you don't intend to run the sessions in parallel, there's no strong reason to share the threadpool between sessions. The global threadpool feature addresses the case where you would be running multiple sessions in parallel in which case you don't want to create a separate threadpool for each session.

@dashesy
Copy link
Author

dashesy commented Aug 28, 2020

what about concurrent requests? would that benefit from shared threadpool? it is same session called by different threads.

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

No branches or pull requests

3 participants