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

ImportError: cannot import name 'get_all_providers' in importing onnxruntime #7887

Open
abhishirk opened this issue May 29, 2021 · 3 comments
Labels
stale issues that have not been addressed in a while; categorized by a bot

Comments

@abhishirk
Copy link

Describe the bug
I have installed the onnxruntime==1.5.2 (cpu) on my machine but while importing the library I am getting error " ImportError: cannot import name 'get_all_providers' "

Urgency
This is a production related issue, need to fix this as soon as possible

System information

  • OS Platform and Distribution (e.g., Linux Ubuntu 16.04):Linux
  • ONNX Runtime installed from (source or binary): using pip
  • ONNX Runtime version:1.5.2
  • Python version:3.7
  • Visual Studio version (if applicable):
  • GCC/Compiler version (if compiling from source):
  • CUDA/cuDNN version: N/A
  • GPU model and memory:N/A

To Reproduce

  • Describe steps/code to reproduce the behavior.
  • Attach the ONNX model to the issue (where applicable) to expedite investigation.

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.
image

Additional context
Add any other context about the problem here. If the issue is about a particular model, please share the model details as well to facilitate debugging.

I have faced this error before and solved it by including " vcruntime140_1.dll " in the bin folder of the environment. But this time it is not solved by this fix as well

@snnn
Copy link
Member

snnn commented Jun 1, 2021

Please describe steps/code to reproduce the behavior. And when possible, would you please try the latest ONNX Runtime release instead? If not, please check if you have installed GCC OpenMP runtime.

@joshuacwnewton
Copy link

I also faced this error with onnxruntime==1.5.x (#5344), and found that onnxruntime>=1.7.0 fixes the issue for me, because that is when OpenMP was removed as a dependency: https://github.com/microsoft/onnxruntime/releases/tag/v1.7.0

@faxu faxu removed the type:support label Aug 18, 2021
@stale
Copy link

stale bot commented Apr 19, 2022

This issue has been automatically marked as stale due to inactivity and will be closed in 7 days if no further activity occurs. If further support is needed, please provide an update and/or more details.

@stale stale bot added the stale issues that have not been addressed in a while; categorized by a bot label Apr 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale issues that have not been addressed in a while; categorized by a bot
Projects
None yet
Development

No branches or pull requests

5 participants