-
Notifications
You must be signed in to change notification settings - Fork 159
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
import RKNN inside Jupiter fails with the message 'NameError: name 'exit' is not defined' #342
Comments
Has this question been solved? I meet the same situation when I use “from rknn.api import RKNN” in google colab! |
I am also facing this question. Has a solution been determined? |
It's tricky. This problem only happens on jupyter notbook. If I run the same code on .py file, everything is good. |
What is even trickier, is that I run BUT if I open ipython the second time, it will raise exactly this error. --force-reinstall , |
Deepseek gave me this solution:
将处理逻辑封装进一个脚本,脚本启动后只执行一次“导入 + 构建 + 推理”,然后退出 Python 进程。 Python 3.7~3.11 是官方文档更常见的兼容范围; |
I had this problem in jupyter but not when executing a python script. I added this to my notebook and the import worked fine.
|
I am using the last version with Python 3.12
The import works well in a Python file but fail in the Jupiter Notebook
The text was updated successfully, but these errors were encountered: