SourceForge logo
SourceForge logo
Menu

matplotlib-users

From: James C. <mr...@gm...> - 2006年06月28日 18:38:00
Hi I read on the py2exe wiki that the 0.83 line creates huge
distributions because of trouble excluding backends that are not
wanted.
 ( http://starship.python.net/crew/theller/moin.cgi/MatPlotLib )
I do need to have a small distribution on windows. Which version of
matplotlib was the last to play nicely with py2exe?
Has anyone had any luck with 0.83.3 and excluding tk and gtk backends?
(I'm using wx)
I'm also getting a strange dependancy on the unicode version of
wxPython, when I'm using the non-unicode version, and that's adding
another 5MB onto my distro.
Thanks,
-Jim
From: <gr...@nu...> - 2006年06月28日 19:37:42
Using Matplotlib 0.87.3 (wxAgg backend), NumPy 0.9.8, SciPy 0.4.9,
wxPython unicode.2.6.3.2, python 2.4.3 the following setup.py worked
well with py2exe 0.6.5 on Widows XP:
#--------------------------------------------------------------
from distutils.core import setup
import py2exe
import glob
data =3D glob.glob(r'C:Documents and Settings\Apa\.matplotlib\*')
data.append(r'C:\Documents and Settings\Apa\.matplotlib\matplotlibrc')
includes =3D ['matplotlib.numerix.random_array',
 'pytz.zoneinfo.UTC',
 'scipy.misc.info']
excludes =3D ['Tkinter']
opts =3D {
 "py2exe": {
 'skip_archive': 1,
 'includes': includes,
 'excludes': excludes,
 'packages': ['numpy'],
 }
}
setup(
 windows =3D [
 {
 "script": 'Wynne.py',
 "icon_resources": [(1, 'THz.ico')]
 }
 ],
 data_files =3D [('matplotlibdata', data)],
 options =3D opts
 )
#--------------------------------------------------------------
Regards,
G=E9za
--=20
G=E9za Groma
Institute of Biophysics
Biological Research Center of the Hungarian Academy of Sciences
Temesv=E1ri krt. 62.
6701 Szeged, Hungary
phone: +36 62 599 620 fax: +36 62 433 133 cellular: +36 20 5648 303
On 6/28/06, James Carroll <mr...@gm...> wrote:
> Hi I read on the py2exe wiki that the 0.83 line creates huge
> distributions because of trouble excluding backends that are not
> wanted.
> ( http://starship.python.net/crew/theller/moin.cgi/MatPlotLib )
>
> I do need to have a small distribution on windows. Which version of
> matplotlib was the last to play nicely with py2exe?
>
> Has anyone had any luck with 0.83.3 and excluding tk and gtk backends?
> (I'm using wx)
>
> I'm also getting a strange dependancy on the unicode version of
> wxPython, when I'm using the non-unicode version, and that's adding
> another 5MB onto my distro.
>
> Thanks,
> -Jim
>
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job ea=
sier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronim=
o
> http://sel.as-us.falkag.net/sel?cmd=3Dlnk&kid=3D120709&bid=3D263057&dat=
=3D121642
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
From: James C. <mr...@gm...> - 2006年06月28日 23:34:41
On 6/28/06, G=E9za Groma <gr...@nu...> wrote:
> Using Matplotlib 0.87.3 (wxAgg backend), NumPy 0.9.8, SciPy 0.4.9,
> wxPython unicode.2.6.3.2, python 2.4.3 the following setup.py worked
> well with py2exe 0.6.5 on Widows XP:
>
I followed your example, and had some luck. Thanks.
My final distribution is 47MB in 840 files. Does anyone have an example th=
at
does even better?
Last October, I used numarray + matplotlib in an almost identical
project, and managed to bundle it into 11MB and four files. But I
can't remember exactly the combination that I used.
If I try to use a zip file (comment out the skip_archive) to reduce
size and filecount, I get the error:
 File "matplotlib\backends\backend_wxagg.pyc", line 21, in ?
 File "matplotlib\figure.pyc", line 5, in ?
 File "matplotlib\artist.pyc", line 4, in ?
 File "matplotlib\transforms.pyc", line 215, in ?
 File "matplotlib\_transforms.pyc", line 1, in ?
 File "matplotlib\numerix\__init__.pyc", line 52, in ?
 File "numarray\__init__.pyc", line 42, in ?
 File "numarray\numarrayall.pyc", line 2, in ?
 File "numarray\generic.pyc", line 1120, in ?
 File "numarray\numarraycore.pyc", line 16, in ?
 File "numarray\_sort.pyc", line 12, in ?
 File "numarray\_sort.pyc", line 10, in __load
 File "numpy\__init__.pyc", line 35, in ?
 File "numpy\_import_tools.pyc", line 173, in __call__
 File "numpy\_import_tools.pyc", line 68, in _init_info_modules
 File "<string>", line 1, in ?
 File "numpy\random\__init__.pyc", line 3, in ?
 File "numpy\random\mtrand.pyc", line 12, in ?
 File "numpy\random\mtrand.pyc", line 10, in __load
 File "numpy.pxi", line 32, in mtrand
AttributeError: 'module' object has no attribute 'dtype'
and even in the working example where I do skip_archive, I get the warnings=
:
The following modules appear to be missing
['FFT', 'LinearAlgebra', 'MA', 'MLab', 'Matrix', 'Numeric', 'Pyrex', 'Pyrex=
.Comp
iler', 'RandomArray', 'backends.draw_if_interactive', 'backends.new_figure_=
manag
er', 'backends.pylab_setup', 'backends.show', 'cephes', 'fcompiler.FCompile=
r', '
fcompiler.show_fcompilers', 'genapi', 'lib.add_newdoc', 'numerix.ArrayType'=
, 'nu
merix.Complex', 'numerix.Complex32', 'numerix.Complex64', 'numerix.Float', =
'nume
rix.Float32', 'numerix.Float64', 'numerix.Int', 'numerix.Int16', 'numerix.I=
nt32'
, 'numerix.Int8', 'numerix.NewAxis', 'numerix.UInt16', 'numerix.UInt32', 'n=
umeri
x.UInt8', 'numerix.absolute', 'numerix.add', 'numerix.allclose', 'numerix.a=
lltru
e', 'numerix.arange', 'numerix.arccos', 'numerix.arccosh', 'numerix.arcsin'=
, 'nu
merix.arcsinh', 'numerix.arctan', 'numerix.arctan2', 'numerix.arctanh', 'nu=
merix
.argmax', 'numerix.argmin', 'numerix.argsort', 'numerix.around', 'numerix.a=
rray'
, 'numerix.arrayrange', 'numerix.asarray', 'numerix.asum', 'numerix.bitwise=
_and'
, 'numerix.bitwise_or', 'numerix.bitwise_xor', 'numerix.ceil', 'numerix.cho=
ose',
 'numerix.clip', 'numerix.compress', 'numerix.concatenate', 'numerix.conjug=
ate',
 'numerix.convolve', 'numerix.cos', 'numerix.cosh', 'numerix.cross_correlat=
e', '
numerix.cumproduct', 'numerix.cumsum', 'numerix.diagonal', 'numerix.divide'=
, 'nu
merix.dot', 'numerix.equal', 'numerix.exp', 'numerix.fabs', 'numerix.fft.ff=
t', '
numerix.fft.inverse_fft', 'numerix.floor', 'numerix.fmod', 'numerix.fromfun=
ction
', 'numerix.fromstring', 'numerix.greater', 'numerix.greater_equal', 'numer=
ix.hy
pot', 'numerix.identity', 'numerix.indices', 'numerix.innerproduct', 'numer=
ix.is
contiguous', 'numerix.less', 'numerix.less_equal', 'numerix.log', 'numerix.=
log10
', 'numerix.logical_and', 'numerix.logical_not', 'numerix.logical_or', 'num=
erix.
logical_xor', 'numerix.matrixmultiply', 'numerix.maximum', 'numerix.minimum=
', 'n
umerix.mlab.amax', 'numerix.mlab.amin', 'numerix.mlab.cov', 'numerix.mlab.d=
iff',
 'numerix.mlab.hanning', 'numerix.mlab.rand', 'numerix.mlab.std', 'numerix.=
mlab.
svd', 'numerix.multiply', 'numerix.negative', 'numerix.nonzero', 'numerix.n=
ot_eq
ual', 'numerix.nx', 'numerix.ones', 'numerix.outerproduct', 'numerix.pi', '=
numer
ix.power', 'numerix.product', 'numerix.put', 'numerix.putmask', 'numerix.ra=
nk',
'numerix.ravel', 'numerix.repeat', 'numerix.reshape', 'numerix.resize', 'nu=
merix
.searchsorted', 'numerix.shape', 'numerix.sin', 'numerix.sinh', 'numerix.si=
ze',
'numerix.sometrue', 'numerix.sort', 'numerix.sqrt', 'numerix.subtract', 'nu=
merix
.swapaxes', 'numerix.take', 'numerix.tan', 'numerix.tanh', 'numerix.trace',=
 'num
erix.transpose', 'numerix.typecode', 'numerix.typecodes', 'numerix.where', =
'nume
rix.which', 'numerix.zeros', 'numpy.Complex', 'numpy.Complex32', 'numpy.Com=
plex6
4', 'numpy.Float', 'numpy.Float32', 'numpy.Float64', 'numpy.Inf', 'numpy.In=
finit
y', 'numpy.Int', 'numpy.Int16', 'numpy.Int32', 'numpy.Int8', 'numpy.UInt16'=
, 'nu
mpy.UInt32', 'numpy.UInt8', 'numpy.absolute', 'numpy.add', 'numpy.amax', 'n=
umpy.
amin', 'numpy.arange', 'numpy.array', 'numpy.asarray', 'numpy.asarray_chkfi=
nite'
, 'numpy.cast', 'numpy.concatenate', 'numpy.conjugate', 'numpy.diag', 'nump=
y.dot
', 'numpy.exp', 'numpy.extract', 'numpy.eye', 'numpy.finfo', 'numpy.float_'=
, 'nu
mpy.floor', 'numpy.greater_equal', 'numpy.hstack', 'numpy.identity', 'numpy=
.imag
', 'numpy.inf', 'numpy.infty', 'numpy.insert', 'numpy.iscomplexobj', 'numpy=
.isfi
nite', 'numpy.log', 'numpy.log2', 'numpy.logical_not', 'numpy.matrix', 'num=
py.mg
rid', 'numpy.newaxis', 'numpy.ogrid', 'numpy.ones', 'numpy.outerproduct', '=
numpy
.pi', 'numpy.poly1d', 'numpy.product', 'numpy.r_', 'numpy.ravel', 'numpy.re=
al',
'numpy.reshape', 'numpy.sign', 'numpy.single', 'numpy.sqrt', 'numpy.subtrac=
t', '
numpy.sum', 'numpy.take', 'numpy.transpose', 'numpy.typecodes', 'numpy.type=
name'
, 'numpy.where', 'numpy.zeros', 'numpy_distutils', 'numpy_distutils.command=
.buil
d_flib', 'numpy_distutils.command.cpuinfo', 'numpy_distutils.cpuinfo', 'num=
py_di
stutils.fcompiler', 'pkg_resources', 'pre', 'setuptools', 'setuptools.comma=
nd',
'setuptools.command.egg_info', 'matplotlib.numerix.Float', 'matplotlib.nume=
rix.F
loat32', 'matplotlib.numerix.absolute', 'matplotlib.numerix.alltrue', 'matp=
lotli
b.numerix.asarray', 'matplotlib.numerix.ceil', 'matplotlib.numerix.equal', =
'matp
lotlib.numerix.fromstring', 'matplotlib.numerix.put', 'matplotlib.numerix.r=
avel'
, 'matplotlib.numerix.sqrt', 'matplotlib.numerix.take', 'matplotlib.numerix=
.tran
spose', 'matplotlib.numerix.where', 'numarray.Complex', 'numarray.Complex32=
', 'n
etc...
Help me please!
Thanks,
-Jim
From: Alan G I. <ai...@am...> - 2006年06月29日 00:23:20
On 2006年6月28日, James Carroll apparently wrote:=20
> My final distribution is 47MB in 840 files. Does anyone=20
> have an example that does even better?=20
I think PyInstaller is supposed to help with this problem:
http://pyinstaller.hpcf.upr.edu/
But I have not used it.
Cheers,
Alan Isaac
From: James C. <mr...@gm...> - 2006年06月29日 14:06:58
> > My final distribution is 47MB in 840 files. Does anyone
> > have an example that does even better?
>
> I think PyInstaller is supposed to help with this problem:
> http://pyinstaller.hpcf.upr.edu/
> But I have not used it.
>
> Cheers,
> Alan Isaac
Hi Alan, PyInstaller looks intriguing, but the traffic on their
mailing list makes me think that it doesn't have enough users (&
therefore developers) yet. I want to stay on the well-traveled-paths
where I can find them.
I think for now I'll use NSIS w/ py2exe to create a single executable
that unpacks to a temporary directory and launches itself when it's
double clicked. I've used this sucessfully in the past. ( something
like this: http://wiki.wxpython.org/index.cgi/SmallApp )
I think what I'm really hoping for is to find a way to include just
the core functionality of matplotlib, without pulling in numpy and
scipy and all the bells and whistles.
Of course, the real solution to my problem is to just start using all
the bells and whistles (I'm happy to see the mathtext module that will
work on systems that don't have TeX!)
-Jim
On 6/28/06, Alan G Isaac <ai...@am...> wrote:
> On 2006年6月28日, James Carroll apparently wrote:
>
>
>
>
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
From: Alan I. <ai...@am...> - 2006年06月29日 17:44:24
On 2006年6月29日, James Carroll wrote: 
> PyInstaller looks intriguing, but the traffic on their 
> mailing list makes me think that it doesn't have enough 
> users (& therefore developers) yet. I want to stay on the 
> well-traveled-paths where I can find them. 
Understood. But do not overlook that PyInstaller is really
the current life of Gordon McMillan's Python Installer,
so it really is not a new kid on the block.
Cheers,
Alan Isaac
From: James C. <mr...@gm...> - 2006年06月30日 20:19:02
> Understood. But do not overlook that PyInstaller is really
> the current life of Gordon McMillan's Python Installer,
> so it really is not a new kid on the block.
I gave PyInstaller a try, and it seemed to be smart and easy at first, and
created a single exe that was just 8MB. The problem is that
when I run the exe, It gives me the following errors before it
crashes:
 - Fatal Error: MSVCR71.DLL!
 - Fatal Error: colud not be extracted.
 - Fatal Error: Error loading Python DLL
 - a message box pointing to python24.dll in a temp dir.
 - Fatal Error:
 - "Please tell microsoft about this problem." [Don't send]
moving msvcr71.dll and python24.dll to the same directory
didn't change anything.
I'll put some more time into trying it, but my first impression isn't good.
Meanwhile, I've removed numarray entirely from the project, and am using
matplotlib.rcParams['numerix'] = 'numpy'
and py2exe + nsis is working pretty well. I have a working single
executable that is 12MB, but it takes about 18 seconds to decompress &
run. If I turn off the
NSIS lzw compression, then it it is a 46MB executable, and runs in about 12
seconds.
I might be trying to create my own C++ wxWidgets top level application
and embed wxPython & matplot lib in that. (has anyone ever had luck
doing this?)
Thanks,
-Jim
From: Alan G I. <ai...@am...> - 2006年06月30日 21:16:03
On 2006年6月30日, James Carroll apparently wrote:=20
> I gave PyInstaller a try, and it seemed to be smart and easy at first, an=
d=20
> created a single exe that was just 8MB. The problem is that=20
> when I run the exe, It gives me the following errors before it=20
> crashes:=20
> - Fatal Error: MSVCR71.DLL!=20
> - Fatal Error: colud not be extracted.=20
http://pyinstaller.hpcf.upr.edu/cgi-bin/trac.cgi/ticket/36
hth,
Alan Isaac
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.
Thanks for helping keep SourceForge clean.
X





Briefly describe the problem (required):
Upload screenshot of ad (required):
Select a file, or drag & drop file here.
Screenshot instructions:

Click URL instructions:
Right-click on the ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)

More information about our ad policies

Ad destination/click URL:

AltStyle によって変換されたページ (->オリジナル) /