question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

new UserWarning introduced by torch 1.7.0

See original GitHub issue

Our application started to get UserWarning from ax after the new torch 1.7.0 release

$ python example/banana.py -m 'banana.x=int(interval(-5, 5))' 'banana.y=interval(-5, 10.1)'
/private/home/jieru/.conda/envs/jh-test/lib/python3.8/site-packages/torch/cuda/__init__.py:52: UserWarning: Error instantiating/calling 'hydra_plugins.hydra_ax_sweeper.ax_sweeper.AxSweeper' : CUDA initialization: Found no NVIDIA driver on your system. Please check that you have an NVIDIA GPU and installed a driver from http://www.nvidia.com/Download/index.aspx (Triggered internally at  /pytorch/c10/cuda/CUDAFunctions.cpp:100.)
  return torch._C._cuda_getDeviceCount() > 0

The torch warning was introduced in this torch PR and raise in ax in here

This warning is not relevant to my application and as a result it would be awesome if ax could suppress it.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
lena-kashtelyancommented, Nov 4, 2020

This warning is now removed on master and will be removed in the imminent stable version release.

2reactions
lena-kashtelyancommented, Oct 28, 2020

@jieru-hu, @shagunsodhani, hi! You could probably leverage the warnings library to suppress these in your application?

Something like this could work (I also advise you to look into making it more granular so you are not just suppressing any UserWarning, but that’s up to you):

import warnings
warnings.filterwarnings("ignore", category=UserWarning)

We’ll also look into what is causing these, but you should be unblocked by the above in the meantime.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Could not find a version that satisfies the requirement torch ...
I'm (a NLP newbie) trying to use the zero-shot models on a system without a GPU. None of the models seem to work....
Read more >
PyTorch 1.7.0 Now Available | Exxact Blog
Based on Torch, PyTorch has become a powerful machine learning framework favored by esteemed researchers around the world. The newest stable ...
Read more >
How does one use Pytorch (+ cuda) with an A100 GPU?
I've got an A100 and have had success with conda install pytorch torchvision torchaudio cudatoolkit=11.1 ...
Read more >
Introduction to Pytorch Lightning - Read the Docs
pip install --quiet "pandas" "ipython[notebook]" "torchvision" "setuptools==59.5.0" "torch>=1.8" "torchmetrics>=0.7" "seaborn" ...
Read more >
PyTorch
LibTorch. Source. Language. Python. C++ / Java. Compute Platform ... Using PyTorch's flexibility to efficiently research new algorithmic approaches.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found