linux - anaconda python: could not find or load the Qt platform plugin "xcb" -


on os(linux mint debian edition 2), except system python(/usr/bin/python) installed apt, installed anaconda. i've encounterd problem running following code anaconda python

# test.py import matplotlib.pyplot plt import numpy np x = np.array([0, 1]) plt.scatter(x, x) plt.show() 

the error is

this application failed start because not find or load qt platform plugin "xcb".

reinstalling application may fix problem.

aborted

but if try system python, i.e., /usr/bin/python test.py, works correctly.

then tried ipythons, of system , of anaconda, result same before: anaconda ipython kernel died.

and tried add ipython magic %matplotlib inline code, anaconda ipython works correctly now. if replace %matplotlib inline %pylab, anaconda ipython died again.

note: use python 2.7. system ipython's version 2.3, anaconda ipython's version 3.2.

same problem linux mint 17, 64 bit. solved after 4h searching on net! need give these commands on terminal folder /anaconda2/bin

sudo ./conda remove qt sudo ./conda remove pyqt sudo ./conda install qt sudo ./conda install pyqt 

hope helps!


Comments

Popular posts from this blog

html - Difficulties with background-image property -

visual studio code - What does the isShellCommand property actually do and how should you use it? -

ios - Segue not passing data between ViewControllers -