ImportError: DLL load failed: %1 is not a valid Win32 application for Python Matplotlib <pre><code>&gt;&gt;&gt; from matplotlib import pyplot as plt Traceback (most recent call last): File "&lt;pyshell#4&gt;", line 1, in &lt;module&gt; from matplotlib import pyplot as plt File "C:\Python27\lib\site-packages\matplotlib\pyplot.py", line 24, in &lt;module&gt; import matplotlib.colorbar File "C:\Python27\lib\site-packages\matplotlib\colorbar.py", line 27, in &lt;module&gt; import matplotlib.artist as martist File "C:\Python27\lib\site-packages\matplotlib\artist.py", line 8, in &lt;module&gt; from transforms import Bbox, IdentityTransform, TransformedBbox, \ File "C:\Python27\lib\site-packages\matplotlib\transforms.py", line 35, in &lt;module&gt; from matplotlib._path import (affine_transform, count_bboxes_overlapping_bbox, ImportError: DLL load failed: %1 is not a valid Win32 application. </code></pre> <p>I am getting this error. I have tried <code>activepython</code>, <code>python xy</code>, but the error still persists. </p>