In PyCharm (community edition 2016.2.3), using anaconda2 + ubuntu 14.04, import matplotlib
causes a signal 11 error during the debug mode. There is no problem when executing the script in release mode.
The python code:
import matplotlib as pt
The debug console:
Connected to pydev debugger (build 162.1967.10) GLib-GIO-Message: Using the 'memory' GSettings backend. Your settings will not be saved or shared with other applications. Backend Qt4Agg is interactive backend. Turning interactive mode on.
Process finished with exit code 139 (interrupted by signal 11: SIGSEGV)
A quick and dirty work-around is to switch out the Qt backend for another one. For example, add this immediately after importing Matplotlib:
matplotlib.use('TkAgg')
You may want to use another one of the available backends.
If you have various modules with Matplotlib dependencies and you don't want to pollute your code, or if you're on a team, it would be better to change the backend in your matplotlibrc
. You can find which matplotlibrc you're using with:
import matplotlib
print(matplotlib.matplotlib_fname())
A bit late but it might help some googler.
Qt can cause this Problem. PyCharm runs with --qt-support=auto by default. If you have python bindings for Qt4 and Qt5 installed the auto function might not choose the correct version of Qt. Try to set the correct Qt bindings in PyCharm Settings (Build, Ex... -> Python Debugger - PyQt Compatible)
Setting from Auto to PyQt4 worked for me in conda environment, without removing anything.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With