1

I'm trying to create an executable file for a simple plot on matplotlib using pyinstaller. How ever, I just cant seem to get it right. Heres my code,

import matplotlib.pyplot as plt
plt.plot([1],[1],'rs')
plt.plot([2],[2],'rs')
plt.plot([1],[4],'ro')
plt.axis([0,5,0,5])
plt.axvline(x=0)
plt.axhline(y=0)
plt.ylabel('some numbers')
plt.show()

This is what its supposed to look like, ![enter image description here][1]

This is what I get when I use the exe pyinstaller generated, ![enter image description here][2]

Looks like I'm missing a toolbar!

Here's a snapshot of the directory pyinstaller created,

03/07/2012 12:22 PM <DIR> .
03/07/2012 12:22 PM <DIR> ..
07/15/2011 11:15 PM 3,072 API-MS-Win-Core-Debug-L1-1-0.dll
07/15/2011 11:15 PM 3,072 API-MS-Win-Core-ErrorHandling-L1-1-0.dll
07/15/2011 11:15 PM 3,072 API-MS-Win-Core-Fibers-L1-1-0.dll
07/15/2011 11:15 PM 5,120 API-MS-Win-Core-File-L1-1-0.dll
07/15/2011 11:15 PM 3,072 API-MS-Win-Core-Handle-L1-1-0.dll
07/15/2011 11:15 PM 3,584 API-MS-Win-Core-Heap-L1-1-0.dll
07/15/2011 11:15 PM 3,072 API-MS-Win-Core-IO-L1-1-0.dll
07/15/2011 11:15 PM 3,584 API-MS-Win-Core-LibraryLoader-L1-1-0.dll
07/15/2011 11:15 PM 4,096 API-MS-Win-Core-Localization-L1-1-0.dll
07/15/2011 11:15 PM 3,584 API-MS-Win-Core-Memory-L1-1-0.dll
07/15/2011 11:15 PM 4,096 API-MS-Win-Core-Misc-L1-1-0.dll
07/15/2011 11:15 PM 3,584 API-MS-Win-Core-NamedPipe-L1-1-0.dll
07/15/2011 11:15 PM 3,584 API-MS-Win-Core-ProcessEnvironment-L1-1-0.dll
07/15/2011 11:15 PM 4,608 API-MS-Win-Core-ProcessThreads-L1-1-0.dll
07/15/2011 11:15 PM 3,072 API-MS-Win-Core-Profile-L1-1-0.dll
07/15/2011 11:15 PM 3,072 API-MS-Win-Core-RtlSupport-L1-1-0.dll
07/15/2011 11:15 PM 3,072 API-MS-Win-Core-String-L1-1-0.dll
07/15/2011 11:15 PM 4,096 API-MS-Win-Core-Synch-L1-1-0.dll
07/15/2011 11:15 PM 4,096 API-MS-Win-Core-SysInfo-L1-1-0.dll
07/15/2011 09:17 PM 4,608 API-MS-Win-Core-ThreadPool-L1-1-0.dll
07/15/2011 09:17 PM 3,072 API-MS-Win-Core-Util-L1-1-0.dll
07/15/2011 09:17 PM 6,144 API-MS-Win-Security-Base-L1-1-0.dll
06/12/2011 03:06 PM 76,800 bz2.pyd
03/07/2012 12:03 PM <DIR> eggs
07/15/2011 11:24 PM 1,114,112 kernel32.dll
07/15/2011 11:24 PM 272,384 KERNELBASE.dll
10/06/2011 06:13 AM 216,064 matplotlib.backends._backend_agg.pyd
10/06/2011 06:13 AM 9,216 matplotlib.backends._backend_gdk.pyd
10/06/2011 06:13 AM 71,168 matplotlib.backends._gtkagg.pyd
10/06/2011 06:13 AM 63,488 matplotlib.backends._tkagg.pyd
10/06/2011 06:12 AM 498,688 matplotlib.ft2font.pyd
10/06/2011 06:12 AM 11,776 matplotlib.nxutils.pyd
10/06/2011 06:12 AM 44,544 matplotlib.ttconv.pyd
10/06/2011 06:12 AM 18,944 matplotlib._cntr.pyd
10/06/2011 06:12 AM 47,616 matplotlib._delaunay.pyd
10/06/2011 06:13 AM 146,432 matplotlib._image.pyd
10/06/2011 06:13 AM 135,680 matplotlib._path.pyd
10/06/2011 06:13 AM 197,632 matplotlib._png.pyd
10/06/2011 06:13 AM 123,904 matplotlib._tri.pyd
10/06/2011 06:13 AM 6,656 matplotlib._windowing.pyd
09/04/2011 02:46 PM 1,857 Microsoft.VC90.CRT.manifest
03/07/2012 12:08 PM <DIR> mpl-data
09/04/2011 02:46 PM 224,768 msvcm90.dll
09/04/2011 02:46 PM 568,832 msvcp90.dll
09/04/2011 02:46 PM 655,872 msvcr90.dll
03/05/2012 07:49 PM 1,093,467 numpy.core.multiarray.pyd
03/05/2012 07:49 PM 177,416 numpy.core.scalarmath.pyd
03/05/2012 07:49 PM 389,046 numpy.core.umath.pyd
03/05/2012 07:49 PM 127,559 numpy.core._sort.pyd
03/05/2012 07:49 PM 49,073 numpy.fft.fftpack_lite.pyd
03/05/2012 07:49 PM 39,360 numpy.lib._compiled_base.pyd
03/05/2012 07:49 PM 768,285 numpy.linalg.lapack_lite.pyd
03/05/2012 07:49 PM 505,062 numpy.random.mtrand.pyd
03/07/2012 12:03 PM 3,749,201 plot.exe
03/07/2012 12:03 PM 731 plot.exe.manifest
06/12/2011 03:06 PM 152,576 pyexpat.pyd
06/12/2011 03:09 PM 2,206,720 python27.dll
02/07/2012 11:35 AM 110,080 pywintypes27.dll
06/12/2011 03:06 PM 11,776 select.pyd
11/07/2008 01:19 PM 1,172,993 tcl85.dll
03/07/2012 12:22 PM 0 temp.txt
11/07/2008 01:23 PM 1,759,233 tk85.dll
06/12/2011 03:06 PM 688,128 unicodedata.pyd
02/07/2012 11:37 AM 98,816 win32api.pyd
02/07/2012 11:36 AM 24,064 win32pdh.pyd
02/07/2012 11:36 AM 24,064 win32pipe.pyd
06/12/2011 03:06 PM 106,496 _ctypes.pyd
06/12/2011 03:06 PM 287,232 _hashlib.pyd
06/12/2011 03:09 PM 38,400 _socket.pyd
06/12/2011 03:09 PM 720,896 _ssl.pyd
06/12/2011 03:06 PM 30,208 _tkinter.pyd

Please help. I've been on this for quite sometime. It may be possible that the pyinstaller has forgotten a few DLLs?

Joe Kington
  • 275,208
  • 71
  • 604
  • 463
kiran.gilvaz
  • 7,137
  • 2
  • 15
  • 11
  • see my post here: http://stackoverflow.com/questions/17095180/building-python-pylab-matplotlib-exe-using-pyinstaller perhaps you are suffering the same problem as me. – panofish Jun 19 '13 at 21:29

0 Answers0