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

eva_nyudepth script can not find cuda device #34

Open
KimBenjaminTang opened this issue Dec 9, 2019 · 3 comments
Open

eva_nyudepth script can not find cuda device #34

KimBenjaminTang opened this issue Dec 9, 2019 · 3 comments

Comments

@KimBenjaminTang
Copy link

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

@XinJCheng
Copy link
Owner

Could you test the return value by adding "torch.cuda.is_available()" in our codes

@KimBenjaminTang
Copy link
Author

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.

@PatrykTerechowicz
Copy link

PatrykTerechowicz commented Jan 14, 2021

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()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants