-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
Avoid runtime exception when file doesn't exist #2441
Conversation
I think there is a check for that the tophub package has been downloaded: |
The trace is: File "/data/users/feisun/tvm/venv/lib/python2.7/site-packages/nnvm-0.8.0-py2.7.egg/nnvm/compiler/build_module.py", line 245, in build [0/1821] |
That is interesting; did you see the |
Yes, I saw: INFO:autotvm:Download pre-tuned parameters package llvm_v0.03.log |
We'd better move the error handling to a place within TopHub. Because we want to hide this error for TopHub but we don't want to hide this error for other cases. "cannot find file" is a fatal error that worth an exception. We can move the error handling to |
* Avoid runtime exception when file doesn't exist * Update the check based on feedback * Revert the old fix
* Avoid runtime exception when file doesn't exist * Update the check based on feedback * Revert the old fix
* Avoid runtime exception when file doesn't exist * Update the check based on feedback * Revert the old fix
* Avoid runtime exception when file doesn't exist * Update the check based on feedback * Revert the old fix
When running auto-tuning, autoTVM tries to read from history run logs. However, if the log file doesn't exist, and cannot download from the web, the run would fail. That is because
load_from_file(records)
returns a generator, which is guaranteed to be not None. So it would fail in line 279 when iterating the
records
.I believe we need to return in case the
records
does not exist.