eva_nyudepth script can not find cuda device
KimBenjaminTang opened this issue · 3 comments
Hello,
I am not sure if this is an error with my setup or the code, but when I execute "bash eval_nyudepth_cspn.sh" for testing, I receive following error:
I already tested if google colab has CUDA installed and if pytorch can detect it. And even executing that line outside the script in the cell before works without any errors, but when I try to run the script, it fails.
I appreciate any help or suggestion to fix this
Could you test the return value by adding "torch.cuda.is_available()" in our codes
Thanks for your advice, I inserted it and it returns "false". So the code can not detect it, even though it is available in the GoogleColab environment.
On the left side the file with the added line can be seen.
I don't quite understand why it can not be detected in the script but in the cells before it works without any issues.
I've put
os.environ["CUDA_VISIBLE_DEVICES"] = '0'
in beginning(after imports) of eval.py script, and put eval_error function inside:
if __name__ == "__main__": eval_error()