-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
[Build] ModuleNotFoundError: No module named 'onnxruntime.capi' #21317
Comments
This is my pip list after installation from WHL.
|
I had the same problem when running python scripts from the onnxruntime git checkout, because it contains a folder named "onnxruntime" which gets confused with the onnxruntime package. |
Thanks for the response. I changed the name of the onnxruntime folder under the git repo, and it won't give me "onnxruntime.capi" error. But now it says "Module onnx is not installed". According to the error log, "onnx" is called under "torch". For "torch", I manually installed it by "pip install" after installing the WHL file. So for "onnx", do I need to manually install it by "pip install onnx"? Btw "onnx" is not installed after installing the WHL.
|
Describe the issue
Hi team,
I'm using CPU build from source.
The build is successfully done. Now I'm using conda with python 3.11.
The WHL file is under build\Windows\RelWithDebInfo\RelWithDebInfo\dist.
However, when I'm running onnxruntime-python-api.py
It presents:
So I checked the site-packages of onnxruntime under conda envs, it does exist.
![image](https://private-user-images.githubusercontent.com/102374003/347802351-fd08a6a5-7fc6-4732-b49c-7e505113b31a.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjMwNzQwMzMsIm5iZiI6MTcyMzA3MzczMywicGF0aCI6Ii8xMDIzNzQwMDMvMzQ3ODAyMzUxLWZkMDhhNmE1LTdmYzYtNDczMi1iNDljLTdlNTA1MTEzYjMxYS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwODA3JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDgwN1QyMzM1MzNaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0yZWZiZDM3OGI5YjU1MTdkZjdlNjliNjZlZGM5NjcxMjdhOWRjZjg3NmY1Nzc2NzVjMzQ4OTllYzhhYTFlYzlkJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.5ytxHK947RHDKLwITu2D_d3bUbV3nLBv23GUvsQMhOY)
Please help, I'm not sure whether some packages are lost during the installation from whl.
Urgency
No response
Target platform
Onnxruntime CPU
Build script
Error / output
Visual Studio Version
No response
GCC / Compiler Version
No response
The text was updated successfully, but these errors were encountered: