[Matplotlib-users] ImportError on Anaconda Win64 system

Jonno jonnojohnson at gmail.com
Wed Nov 4 11:59:21 EST 2015


FYI I updated anaconda to 2.4 and still had the same issues. Note that I
had installed Anaconda for all users.
I decided to wipe Anaconda completely and do a fresh install just for my
user and now the issue is gone.

On Fri, Oct 30, 2015 at 4:07 PM, Benjamin Root <ben.v.root at gmail.com> wrote:

> import matplotlib
> matplotlib.get_backend()
>
> On Fri, Oct 30, 2015 at 4:24 PM, Jonno <jonnojohnson at gmail.com> wrote:
>
>> Argh this is what I get from trying to do too many things at once.
>>
>> Correction, if I try to do:
>> from pylab import *  - with either WxAgg or Qt4Agg set in matplotlibrc I
>> get:
>>
>> Python 2.7.10 |Anaconda 2.3.0 (64-bit)| (default, Oct 21 2015, 19:35:23)
>> [MSC v.
>> 1500 64 bit (AMD64)] on win32
>> Type "help", "copyright", "credits" or "license" for more information.
>> Anaconda is brought to you by Continuum Analytics.
>> Please check out: http://continuum.io/thanks and https://anaconda.org
>> >>> from pylab import *
>> Traceback (most recent call last):
>>   File "<stdin>", line 1, in <module>
>>   File
>> "C:\Users\marnj\AppData\Local\Continuum\Anaconda\lib\site-packages\pylab.
>> py", line 1, in <module>
>>     from matplotlib.pylab import *
>>   File
>> "C:\Users\marnj\AppData\Local\Continuum\Anaconda\lib\site-packages\matplo
>> tlib\pylab.py", line 231, in <module>
>>     import matplotlib.finance
>>   File
>> "C:\Users\marnj\AppData\Local\Continuum\Anaconda\lib\site-packages\matplo
>> tlib\finance.py", line 38, in <module>
>>     from matplotlib.collections import LineCollection, PolyCollection
>>   File
>> "C:\Users\marnj\AppData\Local\Continuum\Anaconda\lib\site-packages\matplo
>> tlib\collections.py", line 27, in <module>
>>     import matplotlib.backend_bases as backend_bases
>>   File
>> "C:\Users\marnj\AppData\Local\Continuum\Anaconda\lib\site-packages\matplo
>> tlib\backend_bases.py", line 56, in <module>
>>     import matplotlib.textpath as textpath
>>   File
>> "C:\Users\marnj\AppData\Local\Continuum\Anaconda\lib\site-packages\matplo
>> tlib\textpath.py", line 22, in <module>
>>     from matplotlib.mathtext import MathTextParser
>>   File
>> "C:\Users\marnj\AppData\Local\Continuum\Anaconda\lib\site-packages\matplo
>> tlib\mathtext.py", line 63, in <module>
>>     import matplotlib._png as _png
>> ImportError: DLL load failed: The specified module could not be found.
>>
>> How do I check the selected backend from within a python session?
>>
>>
>> On Fri, Oct 30, 2015 at 2:41 PM, Benjamin Root <ben.v.root at gmail.com>
>> wrote:
>>
>>> Then I suspect that the backend isn't really set properly, or matplotlib
>>> is picking up the parameter from somewhere else. I just don't see how
>>> having WxAgg as your backend could possibly trigger an import of the Qt
>>> libraries.
>>>
>>> On Fri, Oct 30, 2015 at 3:35 PM, Jonno <jonnojohnson at gmail.com> wrote:
>>>
>>>> Both.
>>>>
>>>> On Fri, Oct 30, 2015 at 1:08 PM, Benjamin Root <ben.v.root at gmail.com>
>>>> wrote:
>>>>
>>>>> Doing that from IPython or Python?
>>>>>
>>>>> On Fri, Oct 30, 2015 at 1:55 PM, Jonno <jonnojohnson at gmail.com> wrote:
>>>>>
>>>>>> I also get the same import error DLL load failed if I set the backend
>>>>>> to WXAgg in matplotlibrc then try from pylab import *
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Fri, Oct 30, 2015 at 7:50 AM, Jens Nielsen <jenshnielsen at gmail.com
>>>>>> > wrote:
>>>>>>
>>>>>>> If that fails that is a bug in PyQt/Qt or in your anaconda
>>>>>>> installation and not a Matplotlib bug. You could try reinstall QT and PyQt.
>>>>>>>
>>>>>>> As a workaround you can tell Matplotlib to use a different backend
>>>>>>> http://matplotlib.org/faq/usage_faq.html#what-is-a-backend
>>>>>>>
>>>>>>> BTW the matplotlib mailing list has changed to
>>>>>>> matplotlib-users at python.org.
>>>>>>>
>>>>>>> best
>>>>>>> Jens
>>>>>>>
>>>>>>> fre. 30. okt. 2015 kl. 12.43 skrev Jonno <jonnojohnson at gmail.com>:
>>>>>>>
>>>>>>>> Traceback (most recent call last):
>>>>>>>>   File "<stdin>", line 1, in <module>
>>>>>>>> ImportError: DLL load failed: The specified module could not be
>>>>>>>> found.
>>>>>>>>
>>>>>>>> On Fri, Oct 30, 2015 at 2:26 AM, Jens Nielsen <
>>>>>>>> jenshnielsen at gmail.com> wrote:
>>>>>>>>
>>>>>>>>> It sounds like your PyQt package is broken.
>>>>>>>>>
>>>>>>>>> What happens if you do:
>>>>>>>>>
>>>>>>>>> from PyQt4 import QtCore, QtGui
>>>>>>>>>
>>>>>>>>> in a python shell
>>>>>>>>>
>>>>>>>>> /Jens
>>>>>>>>>
>>>>>>>>> fre. 30. okt. 2015 kl. 03.06 skrev Jonno <jonnojohnson at gmail.com>:
>>>>>>>>>
>>>>>>>>>> Not sure where to post this.
>>>>>>>>>>
>>>>>>>>>> I have a fresh Anaconda Win64 python 2.7.10 install which I then
>>>>>>>>>> updated using conda update --all.
>>>>>>>>>>
>>>>>>>>>> If it try to:
>>>>>>>>>> from pylab import *
>>>>>>>>>> I get the following:
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> File
>>>>>>>>>> "~\Anaconda\lib\site-packages\matplotlib\backends\qt_compat.py", line 91,
>>>>>>>>>> in <module>
>>>>>>>>>>   from PyQt4 import QtCore, QtGui
>>>>>>>>>> ImportError: DLL load failed: The specified module could not be
>>>>>>>>>> found.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> I have the following installed:
>>>>>>>>>> qt: 4.8.7
>>>>>>>>>> pyqt 4.11.4
>>>>>>>>>> matplotlib 1.4.3
>>>>>>>>>>
>>>>>>>>>> Should I open an issue on matplotlib github?
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Matplotlib-users mailing list
>>>>>>>>>> Matplotlib-users at lists.sourceforge.net
>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>
>>>>>> _______________________________________________
>>>>>> Matplotlib-users mailing list
>>>>>> Matplotlib-users at python.org
>>>>>> https://mail.python.org/mailman/listinfo/matplotlib-users
>>>>>>
>>>>>>
>>>>>
>>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/matplotlib-users/attachments/20151104/6ef6a5d8/attachment-0001.html>


More information about the Matplotlib-users mailing list