Spyder is just black

Ubuntu 16.04 fresh install, CUDA 9.1, cuDNN 7.0.5, driver 390.59. I tested everything while installing it seemed fine, but the Spyder display in Anaconda is just a black rectangle. I can see the header thing that says Spyder (Python 3.5), but nothing else. Anyone seen this before? It’s only in my PyTorch environment – in a fresh environment Spyder works fine.

I think this might be a Spyder/Qt issue.
Could you check, which pyqt version Spyder is using?
In pyqt5.7 some issues were reported of blank screens.
Sometimes you can resolve it by unplugging your external monitor, if you are working on a laptop, but it’s not a really useful workaround in my opinion.

Could you try to downgrade pyqt to 5.6 and try Spyder again?

Ya Jupyter works fine, so it’s definitely isolated to Spyder. I don’t see pyqt on pip list…there’s a QtPy? 1.4.1? Doesn’t sound like what you’re after. I’ll install it. I found I could import PyQt 5 from command line python. Which version…ok. So I searched and found two slightly different versions of 5.9 (35 and 36, for python 3.5 and 3.6) in anaconda3/pkgs, as well as two of 5.6. I deleted the two 5.9 and restarted conda navigator, but…same problem. I downloaded a fresh version of 5.6 and deleted the other two and…same problem.

Ok, thanks for the update. The naming of pyqt and qtpy is a little weird, but I meant pyqt 5.6.

Is your internal console showing any errors or is it black as well?
Could you check if you have qtawesome installed? (conda list | grep qtawesome)
If not, could you install it and try it again?

qtawesome 0.4.4 py35hd68ff89_0 fdsf

No other obvious problems in any other part of the navigator or other programs. When I run jupyterlab though, torch.cuda.is_available() gives “True”, but if I run the PyTorch transfer learning demo I get error CUDNN_STATUS_MAPPING_ERROR. Sometimes one or two others. If I comment out the cuda test and just tell it to run on CPU it works fine. Something to do with the drivers or build is still off.

Is this error thrown every time you run the demo or randomly?
Could you try to run the script with CUDA_LAUNCH_BLOCKING=1 python your_script.py and post the stack trace?
I’m not sure, what’s wrong with your installation, but maybe a re-install of anaconda might help.

Thank you so much for this post! It worked, I just typed in the Anaconda Prompt: conda install pyqt=5.6. It worked! Nobody knew what was worng and why I got the black screen. You have my regards, thank you very much!

2 Likes

Oh god! Finally, this worked! :smiley:

Thanks for this post. I could also overcome this same issue.
Issue was getting black blank page in spider post installation.

Then I just read this post, and did below command in Anaconda prompt. And then I launched spider, its worked as expected…Thanks a lot for this post.

(base) C:\Users\nice>conda install pyqt=5.6
Solving environment: done

Package Plan

environment location: C:\Users\nice\Anaconda3

added / updated specs:
- pyqt=5.6

The following packages will be downloaded:

package                    |            build
---------------------------|-----------------
qt-5.6.2                   |  vc14h6f8c307_12        55.8 MB
matplotlib-2.2.2           |   py37had4c4a9_2         6.5 MB
pyqt-5.6.0                 |   py37ha878b3d_6         4.5 MB
certifi-2018.10.15         |           py37_0         138 KB
qtconsole-4.4.2            |           py37_0         200 KB
sip-4.18.1                 |   py37h6538335_2         269 KB
------------------------------------------------------------
                                       Total:        67.5 MB

The following packages will be REMOVED:

anaconda:   5.3.0-py37_0

The following packages will be UPDATED:

certifi:    2018.8.24-py37_1      --> 2018.10.15-py37_0
qtconsole:  4.4.1-py37_0          --> 4.4.2-py37_0

The following packages will be DOWNGRADED:

matplotlib: 2.2.3-py37hd159220_0  --> 2.2.2-py37had4c4a9_2
pyqt:       5.9.2-py37h6538335_2  --> 5.6.0-py37ha878b3d_6
qt:         5.9.6-vc14h1e9a669_2  --> 5.6.2-vc14h6f8c307_12
sip:        4.19.8-py37h6538335_0 --> 4.18.1-py37h6538335_2

Proceed ([y]/n)? y

Downloading and Extracting Packages
qt-5.6.2 | 55.8 MB | #################################### | 100%
matplotlib-2.2.2 | 6.5 MB | #################################### | 100%
pyqt-5.6.0 | 4.5 MB | #################################### | 100%
certifi-2018.10.15 | 138 KB | #################################### | 100%
qtconsole-4.4.2 | 200 KB | #################################### | 100%
sip-4.18.1 | 269 KB | #################################### | 100%
Preparing transaction: done
Verifying transaction: done
Executing transaction: done

(base) C:\Users\nice>

Thank you sooooo much…pyqt=5.6 worked…really helpful…I had tried almost everything available on the internet to fix this black screen issue of spyder…finally this worked for me.